low-level parser that extracts but does not interpret ACL options More...

Collaboration diagram for Acl::OptionExtractor:

Public Member Functions

bool extractOne ()
 
const SBufvalue () const
 extracted option value (requires hasValue) More...
 

Public Attributes

SBuf name
 extracted option name, including dash(es) More...
 
bool hasValue = false
 whether the option has a value (-x=value) More...
 

Protected Member Functions

bool advance ()
 extracts a token with the next option/flag(s) or returns false More...
 
void extractWhole ()
 handles -x[=option] or –foo[=option] More...
 
void extractShort ()
 handles one flag letter inside an -xyx[=option] or +xyz[=option] sequence More...
 

Private Attributes

SBuf prefix_
 option name(s), including leading dash(es) More...
 
SBuf value_
 the last seen value of some option More...
 
SBuf::size_type letterPos_ = 0
 letter position inside an -xyz sequence More...
 
bool sawValue_ = false
 the current option sequence had a value More...
 

Detailed Description

Definition at line 21 of file Options.cc.

Member Function Documentation

bool Acl::OptionExtractor::advance ( )
protected
bool Acl::OptionExtractor::extractOne ( )

parses the next option and fills public members with its details

Returns
whether option extraction was successful

Definition at line 86 of file Options.cc.

References TexcHere, and ToSBuf().

Referenced by Acl::OptionsParser::parse().

void Acl::OptionExtractor::extractShort ( )
protected

Definition at line 156 of file Options.cc.

References debugs.

void Acl::OptionExtractor::extractWhole ( )
protected

Definition at line 146 of file Options.cc.

References debugs.

const SBuf & Acl::OptionExtractor::value ( ) const

Definition at line 79 of file Options.cc.

References Must.

Referenced by Acl::OptionsParser::parse().

Member Data Documentation

bool Acl::OptionExtractor::hasValue = false

Definition at line 30 of file Options.cc.

Referenced by Acl::OptionsParser::parse().

SBuf::size_type Acl::OptionExtractor::letterPos_ = 0
private

Definition at line 41 of file Options.cc.

SBuf Acl::OptionExtractor::name

Definition at line 29 of file Options.cc.

Referenced by Acl::OptionsParser::parse().

SBuf Acl::OptionExtractor::prefix_
private

Definition at line 39 of file Options.cc.

bool Acl::OptionExtractor::sawValue_ = false
private

Definition at line 42 of file Options.cc.

SBuf Acl::OptionExtractor::value_
private

Definition at line 40 of file Options.cc.


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

 

Introduction

Documentation

Support

Miscellaneous

Web Site Translations

Mirrors