Compartilhar via


uri_builder Class

Builder for constructing URIs incrementally.

Warning

This topic contains information for the C++ REST SDK 1.0 (codename "Casablanca"). If you are using a later version from the Codeplex Casablanca web page, then use the local documentation at http://casablanca.codeplex.com/documentation.

class uri_builder;

Members

Public Constructors

Name

Description

uri_builder::uri_builder Constructor

Overloaded. Creates a builder with an initially empty URI.

Public Methods

Name

Description

uri_builder::append Method

Appends an relative uri (Path, Query and fragment) at the end of the current uri.

uri_builder::append_path Method

Appends another path to the path of this uri_builder.

uri_builder::append_query Method

Overloaded. Appends another query to the query of this uri_builder.

uri_builder::clear Method

Clears all components of the underlying URI in this uri_builder.

uri_builder::fragment Method

Get the fragment component of the URI as an encoded string.

uri_builder::host Method

Get the host component of the URI as an encoded string.

uri_builder::is_valid Method

Validate the generated URI from all existing components of this uri_builder.

uri_builder::path Method

Get the path component of the URI as an encoded string.

uri_builder::port Method

Get the port component of the URI. Returns -1 if no port is specified.

uri_builder::query Method

Get the query component of the URI as an encoded string.

uri_builder::scheme Method

Get the scheme component of the URI as an encoded string.

uri_builder::set_fragment Method

Set the fragment component of the URI.

uri_builder::set_host Method

Set the host component of the URI.

uri_builder::set_path Method

Set the path component of the URI.

uri_builder::set_port Method

Set the port component of the URI.

uri_builder::set_query Method

Set the query component of the URI.

uri_builder::set_scheme Method

Set the scheme of the URI.

uri_builder::set_user_info Method

Set the user info component of the URI.

uri_builder::to_string Method

Combine and validate the URI components into a encoded string. An exception will be thrown if the URI is invalid.

uri_builder::to_uri Method

Combine and validate the URI components into a URI class instance. An exception will be thrown if the URI is invalid.

uri_builder::user_info Method

Get the user information component of the URI as an encoded string.

Requirements

Header: base_uri.h, uri_builder.h

Namespace: web::http

See Also

Reference

web::http Namespace