wget2 2.1.0
Loading...
Searching...
No Matches
wget_iri_st Struct Reference

#include <wget.h>

Data Fields

const char * uri
 
const char * display
 
const char * userinfo
 
const char * password
 
const char * host
 
const char * path
 
const char * query
 
const char * fragment
 
const char * connection_part
 
size_t dirlen
 
size_t msize
 size of memory to hold the parsed URI, it contains 0 bytes
 
uint16_t port
 Port number.
 
wget_iri_scheme scheme
 URI/IRI scheme (http or https).
 
bool port_given: 1
 If set, port was explicitly given.
 
bool uri_allocated: 1
 If set, free uri in iri_free()
 
bool host_allocated: 1
 If set, free host in iri_free()
 
bool path_allocated: 1
 If set, free path in iri_free()
 
bool query_allocated: 1
 If set, free query in iri_free()
 
bool fragment_allocated: 1
 If set, free fragment in iri_free()
 
bool is_ip_address: 1
 If set, the hostname part is a literal IPv4/IPv6 address.
 

Detailed Description

Internal representation of a URI/IRI.

Field Documentation

◆ uri

const char* wget_iri_st::uri

Pointer to the original URI string, unescaped and converted to UTF-8.

◆ display

const char* wget_iri_st::display

Display part, if present.

◆ userinfo

const char* wget_iri_st::userinfo

Username, if present.

◆ password

const char* wget_iri_st::password

Password, if present.

◆ host

const char* wget_iri_st::host

Hostname (or literal IP address). Lowercase and unescaped.

◆ path

const char* wget_iri_st::path

Path, if present. Unescaped.

◆ query

const char* wget_iri_st::query

Query part, if present. Unescaped.

◆ fragment

const char* wget_iri_st::fragment

Fragment part, if present. Unescaped.

◆ connection_part

const char* wget_iri_st::connection_part

Connection part. This is not specified by the spec, it's just a helper.

The connection part is formed by the scheme, the hostname and the port together. Example:

https://www.example.com:8080

◆ dirlen

size_t wget_iri_st::dirlen

Length of the directory part in path.

This is the length from the beginning up to the last slash (/).


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