diff -r bd3829c2e9c9 -r 265cdb1c59e3 mythtv_plugin/myth_uri.h --- a/mythtv_plugin/myth_uri.h Wed Sep 20 23:59:48 2006 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,63 +0,0 @@ -/** - * - * MythURI utils - * - Extracts and parses a URI char string, in according with the RFC 2396 - * [http://www.ietf.org/rfc/rfc2396.txt] - * - * @author Rosfran Borges (rosfran.borges@indt.org.br) - * - */ - -#ifndef _MYTH_URI_H_ -#define _MYTH_URI_H_ - -#include - -/**************************************** -* Define -****************************************/ - -#define MYTH_URI_KNKOWN_PORT (-1) -#define MYTH_URI_DEFAULT_HTTP_PORT 80 -#define MYTH_URI_DEFAULT_FTP_PORT 21 -#define MYTH_URI_DEFAULT_PATH "/" -#define MYTH_URI_MAXLEN 256 - -#define MYTH_URI_PROTOCOL_DELIM "://" -#define MYTH_URI_USER_DELIM "@" -#define MYTH_URI_COLON_DELIM ":" -#define MYTH_URI_SLASH_DELIM "/" -#define MYTH_URI_SBLACET_DELIM "[" -#define MYTH_URI_EBLACET_DELIM "]" -#define MYTH_URI_SHARP_DELIM "#" -#define MYTH_URI_QUESTION_DELIM "?" -#define MYTH_URI_ESCAPING_CHAR "%" - -#define MYTH_URI_PROTOCOL_MYTH "myth" -#define MYTH_URI_PROTOCOL_HTTP "http" -#define MYTH_URI_PROTOCOL_FTP "ftp" - -/**************************************** -* Data Type -****************************************/ - -typedef struct _MythURI { - GString *uri; - GString *host; - gint port; - GString *protocol; - GString *path; - GString *fragment; - GString *user; - GString *password; - GString *query; -} MythURI; - -const MythURI *myth_uri_new( gchar *value ); - -#define myth_uri_gethost(urip) (urip->host->str) -#define myth_uri_getport(urip) (urip->port) -#define myth_uri_getprotocol(urip) (urip->protocol->str) -#define myth_uri_getpath(urip) (urip->path->str) - -#endif