Skip to content

Latest commit

 

History

History
67 lines (43 loc) · 2.16 KB

File metadata and controls

67 lines (43 loc) · 2.16 KB

URI interpreter C++

URI stands for Uniform Resource Identifier.

This interpreter is used to perform lexical and grammatical analysis (lex and parse) for URIs in order to identify its components, specially to distinguish whether the host is IPv4, IPv6, or Registered Name.

Components

URI components:

  • Scheme
  • Authority
  • Path
  • Query
  • Fragment

Where the authority's components are:

  • Userinfo
  • Host
  • Port

And the host can be:

  • IPv6
  • IPv4
  • Registered Name

The minimum required components are:

  • Scheme
  • Host ?
  • Path

Syntax

URI generic syntax:

URI = scheme:[//authority]path[?query][#fragment]

where the authority component divides into three subcomponents:

authority = [userinfo@]host[:port]

img

See the Wiki for URI

Requirements

  • CMake > 3.24
  • c++20 compliant compiler
  • conan 2
  • Catch2