libgpac
Documentation of the core library of GPAC
Loading...
Searching...
No Matches
url.c File Reference
#include <gpac/network.h>

Macros

#define URL_SEP_LENGTH   3
 

Enumerations

enum  {
  GF_URL_TYPE_FILE_PATH = 0 , GF_URL_TYPE_FILE_URI , GF_URL_TYPE_RELATIVE , GF_URL_TYPE_ANY_URI ,
  GF_URL_TYPE_INVALID
}
 

Functions

static u32 URL_GetProtocolType (const char *pathName)
 
GF_EXPORT Bool gf_url_is_local (const char *pathName)
 URL local test.
 
GF_EXPORT Bool gf_url_is_relative (const char *pathName)
 check relative URL
 
GF_EXPORT char * gf_url_get_absolute_path (const char *pathName, const char *parentPath)
 gets absolute file path
 
static char * gf_url_concatenate_ex (const char *parentName, const char *pathName, Bool relative_to_parent)
 
GF_EXPORT char * gf_url_concatenate (const char *parentName, const char *pathName)
 URL concatenation.
 
GF_EXPORT char * gf_url_concatenate_parent (const char *parentName, const char *pathName)
 URL concatenation.
 
GF_EXPORT void gf_url_to_fs_path (char *sURL)
 URL to file system.
 
char * gf_url_percent_encode (const char *path)
 URL encoding.
 
char * gf_url_percent_decode (const char *path)
 URL decoding.
 
GF_EXPORT const char * gf_url_get_resource_name (const char *sURL)
 Extract resource name from URL.
 
GF_EXPORT const char * gf_url_get_path (const char *sURL)
 Gets resource path from URL.
 
GF_EXPORT void gf_url_free (char *sURL)
 

Variables

const char * pce_special = " %"
 
const char * pce_encoded = "0123456789ABCDEFabcdef"
 

Macro Definition Documentation

◆ URL_SEP_LENGTH

#define URL_SEP_LENGTH   3

Enumeration Type Documentation

◆ anonymous enum

anonymous enum
Enumerator
GF_URL_TYPE_FILE_PATH 
GF_URL_TYPE_FILE_URI 
GF_URL_TYPE_RELATIVE 
GF_URL_TYPE_ANY_URI 
GF_URL_TYPE_INVALID 

Function Documentation

◆ URL_GetProtocolType()

static u32 URL_GetProtocolType ( const char *  pathName)
static

◆ gf_url_concatenate_ex()

static char * gf_url_concatenate_ex ( const char *  parentName,
const char *  pathName,
Bool  relative_to_parent 
)
static

◆ gf_url_free()

GF_EXPORT void gf_url_free ( char *  sURL)

Variable Documentation

◆ pce_special

const char* pce_special = " %"

◆ pce_encoded

const char* pce_encoded = "0123456789ABCDEFabcdef"