Gazebo Common

API Reference

3.17.0

A complete URI. More...

#include <URI.hh>

Public Member Functions

 URI ()
 Default constructor. More...
 
 URI (const std::string &_str)
 Construct a URI object from a string. More...
 
 URI (const URI &_uri)
 Copy constructor. More...
 
 ~URI ()
 Destructor. More...
 
void Clear ()
 Remove all components of the URI. More...
 
URIFragmentFragment ()
 Get a mutable version of the fragment component. More...
 
const URIFragmentFragment () const
 Get a const reference of the fragment component. More...
 
URIoperator= (const URI &_uri)
 Assignment operator. More...
 
bool operator== (const URI &_uri) const
 Return true if the two URIs match. More...
 
bool Parse (const std::string &_str)
 Parse a string as URI. More...
 
URIPathPath ()
 Get a mutable version of the path component. More...
 
const URIPathPath () const
 Get a const reference of the path component. More...
 
URIQueryQuery ()
 Get a mutable version of the query component. More...
 
const URIQueryQuery () const
 Get a const reference of the query component. More...
 
std::string Scheme () const
 Get the URI's scheme. More...
 
void SetScheme (const std::string &_scheme)
 Set the URI's scheme. More...
 
std::string Str () const
 Get the URI as a string, which has the form: More...
 
bool Valid () const
 Validate this URI. More...
 

Static Public Member Functions

static bool Valid (const std::string &_str)
 Validate a string as URI. More...
 

Detailed Description

A complete URI.

Constructor & Destructor Documentation

◆ URI() [1/3]

URI ( )

Default constructor.

◆ URI() [2/3]

URI ( const std::string _str)
explicit

Construct a URI object from a string.

Parameters
[in]_strA string.

◆ URI() [3/3]

URI ( const URI _uri)

Copy constructor.

Parameters
[in]_uriAnother URI.

◆ ~URI()

~URI ( )

Destructor.

Member Function Documentation

◆ Clear()

void Clear ( )

Remove all components of the URI.

◆ Fragment() [1/2]

URIFragment& Fragment ( )

Get a mutable version of the fragment component.

Returns
A reference to the fragment.

◆ Fragment() [2/2]

const URIFragment& Fragment ( ) const

Get a const reference of the fragment component.

Returns
A const reference of the fragment.

◆ operator=()

URI& operator= ( const URI _uri)

Assignment operator.

Parameters
[in]_uriAnother URI.
Returns
Itself.

◆ operator==()

bool operator== ( const URI _uri) const

Return true if the two URIs match.

Parameters
[in]_uriAnother URI to compare.
Returns
True if the two URIs match.

◆ Parse()

bool Parse ( const std::string _str)

Parse a string as URI.

Parameters
[in]_strA string.
Returns
True if the string can be parsed as a URI.

◆ Path() [1/2]

URIPath& Path ( )

Get a mutable version of the path component.

Returns
A reference to the path

◆ Path() [2/2]

const URIPath& Path ( ) const

Get a const reference of the path component.

Returns
A const reference of the path.

◆ Query() [1/2]

URIQuery& Query ( )

Get a mutable version of the query component.

Returns
A reference to the query

◆ Query() [2/2]

const URIQuery& Query ( ) const

Get a const reference of the query component.

Returns
A const reference of the query.

◆ Scheme()

std::string Scheme ( ) const

Get the URI's scheme.

Returns
The scheme

◆ SetScheme()

void SetScheme ( const std::string _scheme)

Set the URI's scheme.

Parameters
[in]_schemeNew scheme.

◆ Str()

std::string Str ( ) const

Get the URI as a string, which has the form:

scheme://path?query

Returns
The full URI as a string

◆ Valid() [1/2]

bool Valid ( ) const

Validate this URI.

Returns
True if this can be parsed as a URI.

◆ Valid() [2/2]

static bool Valid ( const std::string _str)
static

Validate a string as URI.

Parameters
[in]_strThe string to validate.
Returns
True if the string can be parsed as a URI.

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