dbp::url Class Reference

URL parser. More...

#include <url.h>

List of all members.

Public Member Functions

 url ()
 Constructor.
 url (const std::string &value)
 Constructor.
 url (const char *value)
 Constructor.
void parse (const std::string &value)
 Parse the URL.
void copy_from (const url &u)
 URL copy.
std::string get_full_path () const
 Full path getter.
void normalize (const std::string &base_path)
 Normalize the URL.
std::string encode (const std::string &value) const
 Encode a URL with escape characters.
std::string decode (const std::string &value) const
 Decode a URL from escape characters.
std::string str () const
 Reconstruct of a string representation of URL.

Public Attributes

std::string scheme
 URL scheme - http, https, ftp and so on.
std::string user
 Username.
std::string password
 Password.
std::string host
 Host.
int port
 Port number.
std::string path
 URL path.
std::string query
 URL query.
std::string fragment
 URL fragment.
std::string parameters
 URL parameters.

Detailed Description

URL parser.

This class parses Uniform Resource Locator into its parts:

scheme://[user[:password]@]host[:port]/full_path

where full_path is: path[?query][fragment][;parameters]


Constructor & Destructor Documentation

dbp::url::url ( const std::string &  value  ) 

Constructor.

Splits a given URL into its parts.

Parameters:
value a URL to parse
dbp::url::url ( const char *  value  ) 

Constructor.

Splits a given URL into its parts.

Parameters:
value a URL to parse

Member Function Documentation

void dbp::url::copy_from ( const url u  ) 

URL copy.

Copying one URL to another, inheriting missing URL parts.

void dbp::url::parse ( const std::string &  value  ) 

Parse the URL.

Splits a given URL into its parts.

Parameters:
value a URL to parse

The documentation for this class was generated from the following file:

 
Support This Project
SourceForge.net Logo