clipp::subrange Class Reference

(start,size) index range More...

#include <clipp.h>

Public Types

using size_type = arg_string::size_type
 

Public Member Functions

constexpr subrange () noexcept
 default: no match More...
 
constexpr subrange (size_type pos, size_type len) noexcept
 match length & position within subject string More...
 
constexpr size_type at () const noexcept
 position of the match within the subject string More...
 
constexpr size_type length () const noexcept
 length of the matching subsequence More...
 
constexpr bool prefix () const noexcept
 returns true, if query string is a prefix of the subject string More...
 
constexpr operator bool () const noexcept
 returns true, if query is a substring of the query string More...
 

Detailed Description

(start,size) index range

Definition at line 83 of file clipp.h.

Member Typedef Documentation

◆ size_type

using clipp::subrange::size_type = arg_string::size_type

Definition at line 85 of file clipp.h.

Constructor & Destructor Documentation

◆ subrange() [1/2]

constexpr clipp::subrange::subrange ( )
inlineexplicitconstexprnoexcept

default: no match

Definition at line 89 of file clipp.h.

◆ subrange() [2/2]

constexpr clipp::subrange::subrange ( size_type  pos,
size_type  len 
)
inlineexplicitconstexprnoexcept

match length & position within subject string

Definition at line 95 of file clipp.h.

Member Function Documentation

◆ at()

constexpr size_type clipp::subrange::at ( ) const
inlineconstexprnoexcept

position of the match within the subject string

Definition at line 100 of file clipp.h.

◆ length()

constexpr size_type clipp::subrange::length ( ) const
inlineconstexprnoexcept

length of the matching subsequence

Definition at line 102 of file clipp.h.

◆ operator bool()

constexpr clipp::subrange::operator bool ( ) const
inlineexplicitconstexprnoexcept

returns true, if query is a substring of the query string

Definition at line 110 of file clipp.h.

◆ prefix()

constexpr bool clipp::subrange::prefix ( ) const
inlineconstexprnoexcept

returns true, if query string is a prefix of the subject string

Definition at line 105 of file clipp.h.


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