Open
Graph Drawing
Framework

 v. 2022.02 (Dogwood)
 

ogdf::tlp::Token Struct Reference

#include <ogdf/fileformats/TlpLexer.h>

Public Types

enum  Type { Type::leftParen, Type::rightParen, Type::identifier, Type::string }
 

Public Member Functions

 Token (const Type &type, size_t line, size_t column)
 
bool identifier () const
 
bool identifier (const char *str) const
 
bool leftParen () const
 
bool rightParen () const
 
bool string () const
 
bool string (const char *str) const
 

Public Attributes

size_t column
 
size_t line
 
enum ogdf::tlp::Token::Type type
 
std::string * value
 

Friends

std::ostream & operator<< (std::istream &os, const Token &token)
 

Detailed Description

Definition at line 44 of file TlpLexer.h.

Member Enumeration Documentation

◆ Type

Enumerator
leftParen 
rightParen 
identifier 
string 

Definition at line 46 of file TlpLexer.h.

Constructor & Destructor Documentation

◆ Token()

ogdf::tlp::Token::Token ( const Type type,
size_t  line,
size_t  column 
)

Member Function Documentation

◆ identifier() [1/2]

bool ogdf::tlp::Token::identifier ( ) const
inline

Definition at line 67 of file TlpLexer.h.

◆ identifier() [2/2]

bool ogdf::tlp::Token::identifier ( const char *  str) const
inline

Definition at line 71 of file TlpLexer.h.

◆ leftParen()

bool ogdf::tlp::Token::leftParen ( ) const
inline

Definition at line 59 of file TlpLexer.h.

◆ rightParen()

bool ogdf::tlp::Token::rightParen ( ) const
inline

Definition at line 63 of file TlpLexer.h.

◆ string() [1/2]

bool ogdf::tlp::Token::string ( ) const
inline

Definition at line 75 of file TlpLexer.h.

◆ string() [2/2]

bool ogdf::tlp::Token::string ( const char *  str) const
inline

Definition at line 79 of file TlpLexer.h.

Friends And Related Function Documentation

◆ operator<<

std::ostream& operator<< ( std::istream &  os,
const Token token 
)
friend

Member Data Documentation

◆ column

size_t ogdf::tlp::Token::column

Definition at line 54 of file TlpLexer.h.

◆ line

size_t ogdf::tlp::Token::line

Definition at line 54 of file TlpLexer.h.

◆ type

enum ogdf::tlp::Token::Type ogdf::tlp::Token::type

◆ value

std::string* ogdf::tlp::Token::value

Definition at line 53 of file TlpLexer.h.


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