OpenMD  2.5
Molecular Dynamics in the Open
OpenMD::Token Class Reference

#include <SelectionToken.hpp>

Public Member Functions

 Token ()
 
 Token (const Token &token)
 
 Token (int MyTok, int myIntValue, const boost::any &myValue)
 
 Token (int myTok, int myIntValue)
 
 Token (int myTok)
 
 Token (int myTok, const boost::any &myValue)
 

Public Attributes

int tok
 
boost::any value
 
int intValue
 

Static Public Attributes

static const int nada = 0
 
static const int identifier = 1
 
static const int integer = 2
 
static const int decimal = 3
 
static const int string = 4
 
static const int unknown = 5
 
static const int keyword = 6
 
static const int whitespace = 7
 
static const int comment = 8
 
static const int endofline = 9
 
static const int endofstatement = 10
 
static const int command = (1 << 8)
 
static const int expressionCommand = (1 << 9)
 
static const int expression = (1 << 10)
 
static const int negnums = (1 << 11)
 expression term More...
 
static const int dynamic = (1 << 12)
 
static const int atomproperty = (1 << 12) | expression | negnums
 
static const int comparator = (1 << 13) | expression
 
static const int predefinedset = (1 << 14) | expression
 
static const int embeddedExpression = (1 << 15)
 
static const int index = (1 << 16) | expression
 
static const int define = command | expressionCommand | 1
 
static const int select = command | expressionCommand | 2
 
static const int leftparen = expression | 0
 
static const int rightparen = expression | 1
 
static const int to = expression | 2
 
static const int opAnd = expression | 3
 
static const int opOr = expression | 4
 
static const int opNot = expression | 5
 
static const int within = expression | dynamic | 6
 
static const int asterisk = expression | 7
 
static const int dot = expression | 8
 
static const int all = expression | 9
 
static const int none = expression | 10
 
static const int name = expression | 11
 
static const int hull = expression | dynamic | 12
 
static const int expressionBegin = expression | 100
 
static const int expressionEnd = expression | 101
 
static const int mass = atomproperty | 0
 
static const int charge = atomproperty | dynamic | 1
 
static const int x = atomproperty | dynamic | 2
 
static const int y = atomproperty | dynamic | 3
 
static const int z = atomproperty | dynamic | 4
 
static const int r = atomproperty | dynamic | 5
 
static const int wrappedX = atomproperty | dynamic | 6
 
static const int wrappedY = atomproperty | dynamic | 7
 
static const int wrappedZ = atomproperty | dynamic | 8
 
static const int opGT = comparator | dynamic | 0
 
static const int opGE = comparator | dynamic | 1
 
static const int opLE = comparator | dynamic | 2
 
static const int opLT = comparator | dynamic | 3
 
static const int opEQ = comparator | dynamic | 4
 
static const int opNE = comparator | dynamic | 5
 
static Token tokenExpressionBegin = Token(Token::expressionBegin, std::string("expressionBegin"))
 
static Token tokenExpressionEnd = Token(Token::expressionEnd, std::string("expressionEnd"))
 

Detailed Description

Todo:
document
Note
translate from jmol

Definition at line 59 of file SelectionToken.hpp.

Constructor & Destructor Documentation

◆ Token() [1/6]

OpenMD::Token::Token ( )
inline

Definition at line 68 of file SelectionToken.hpp.

References unknown.

◆ Token() [2/6]

OpenMD::Token::Token ( const Token token)
inline

Definition at line 70 of file SelectionToken.hpp.

◆ Token() [3/6]

OpenMD::Token::Token ( int  MyTok,
int  myIntValue,
const boost::any myValue 
)
inline

Definition at line 74 of file SelectionToken.hpp.

◆ Token() [4/6]

OpenMD::Token::Token ( int  myTok,
int  myIntValue 
)
inline

Definition at line 80 of file SelectionToken.hpp.

◆ Token() [5/6]

OpenMD::Token::Token ( int  myTok)
inline

Definition at line 85 of file SelectionToken.hpp.

◆ Token() [6/6]

OpenMD::Token::Token ( int  myTok,
const boost::any myValue 
)
inline

Definition at line 89 of file SelectionToken.hpp.

Member Data Documentation

◆ all

const int OpenMD::Token::all = expression | 9
static

◆ asterisk

const int OpenMD::Token::asterisk = expression | 7
static

Definition at line 139 of file SelectionToken.hpp.

Referenced by OpenMD::SelectionCompiler::clausePrimitive().

◆ atomproperty

const int OpenMD::Token::atomproperty = (1 << 12) | expression | negnums
static

Definition at line 118 of file SelectionToken.hpp.

Referenced by OpenMD::SelectionCompiler::clausePrimitive().

◆ charge

const int OpenMD::Token::charge = atomproperty | dynamic | 1
static

◆ command

const int OpenMD::Token::command = (1 << 8)
static

Definition at line 106 of file SelectionToken.hpp.

Referenced by OpenMD::SelectionCompiler::internalCompile().

◆ comment

const int OpenMD::Token::comment = 8
static

Definition at line 102 of file SelectionToken.hpp.

◆ comparator

const int OpenMD::Token::comparator = (1 << 13) | expression
static

Definition at line 120 of file SelectionToken.hpp.

Referenced by OpenMD::SelectionCompiler::clauseComparator().

◆ decimal

◆ define

◆ dot

const int OpenMD::Token::dot = expression | 8
static

Definition at line 140 of file SelectionToken.hpp.

Referenced by OpenMD::TokenMap::TokenMap().

◆ dynamic

const int OpenMD::Token::dynamic = (1 << 12)
static

Definition at line 115 of file SelectionToken.hpp.

Referenced by OpenMD::SelectionEvaluator::containDynamicToken().

◆ embeddedExpression

const int OpenMD::Token::embeddedExpression = (1 << 15)
static

Definition at line 122 of file SelectionToken.hpp.

Referenced by OpenMD::SelectionCompiler::compileExpression().

◆ endofline

const int OpenMD::Token::endofline = 9
static

Definition at line 103 of file SelectionToken.hpp.

◆ endofstatement

const int OpenMD::Token::endofstatement = 10
static

Definition at line 104 of file SelectionToken.hpp.

◆ expression

const int OpenMD::Token::expression = (1 << 10)
static

Definition at line 108 of file SelectionToken.hpp.

Referenced by OpenMD::SelectionCompiler::internalCompile().

◆ expressionBegin

const int OpenMD::Token::expressionBegin = expression | 100
static

Definition at line 150 of file SelectionToken.hpp.

Referenced by OpenMD::SelectionEvaluator::expression().

◆ expressionCommand

const int OpenMD::Token::expressionCommand = (1 << 9)
static

Definition at line 107 of file SelectionToken.hpp.

Referenced by OpenMD::SelectionCompiler::compileCommand().

◆ expressionEnd

const int OpenMD::Token::expressionEnd = expression | 101
static

Definition at line 151 of file SelectionToken.hpp.

Referenced by OpenMD::SelectionEvaluator::expression().

◆ hull

const int OpenMD::Token::hull = expression | dynamic | 12
static

◆ identifier

◆ index

const int OpenMD::Token::index = (1 << 16) | expression
static

◆ integer

◆ intValue

int OpenMD::Token::intValue

◆ keyword

const int OpenMD::Token::keyword = 6
static

Definition at line 100 of file SelectionToken.hpp.

◆ leftparen

◆ mass

const int OpenMD::Token::mass = atomproperty | 0
static

◆ nada

const int OpenMD::Token::nada = 0
static

Definition at line 94 of file SelectionToken.hpp.

Referenced by OpenMD::SelectionCompiler::internalCompile().

◆ name

const int OpenMD::Token::name = expression | 11
static

◆ negnums

const int OpenMD::Token::negnums = (1 << 11)
static

expression term

Definition at line 112 of file SelectionToken.hpp.

◆ none

const int OpenMD::Token::none = expression | 10
static

◆ opAnd

const int OpenMD::Token::opAnd = expression | 3
static

◆ opEQ

const int OpenMD::Token::opEQ = comparator | dynamic | 4
static

◆ opGE

const int OpenMD::Token::opGE = comparator | dynamic | 1
static

◆ opGT

const int OpenMD::Token::opGT = comparator | dynamic | 0
static

◆ opLE

const int OpenMD::Token::opLE = comparator | dynamic | 2
static

◆ opLT

const int OpenMD::Token::opLT = comparator | dynamic | 3
static

◆ opNE

const int OpenMD::Token::opNE = comparator | dynamic | 5
static

◆ opNot

const int OpenMD::Token::opNot = expression | 5
static

◆ opOr

◆ predefinedset

const int OpenMD::Token::predefinedset = (1 << 14) | expression
static

◆ r

const int OpenMD::Token::r = atomproperty | dynamic | 5
static

◆ rightparen

const int OpenMD::Token::rightparen = expression | 1
static

◆ select

◆ string

const int OpenMD::Token::string = 4
static

Definition at line 98 of file SelectionToken.hpp.

Referenced by OpenMD::SelectionCompiler::internalCompile().

◆ to

const int OpenMD::Token::to = expression | 2
static

◆ tok

◆ tokenExpressionBegin

Token OpenMD::Token::tokenExpressionBegin = Token(Token::expressionBegin, std::string("expressionBegin"))
static

Definition at line 170 of file SelectionToken.hpp.

Referenced by OpenMD::SelectionCompiler::compileExpression().

◆ tokenExpressionEnd

Token OpenMD::Token::tokenExpressionEnd = Token(Token::expressionEnd, std::string("expressionEnd"))
static

Definition at line 171 of file SelectionToken.hpp.

Referenced by OpenMD::SelectionCompiler::compileExpression().

◆ unknown

const int OpenMD::Token::unknown = 5
static

Definition at line 99 of file SelectionToken.hpp.

Referenced by Token().

◆ value

◆ whitespace

const int OpenMD::Token::whitespace = 7
static

Definition at line 101 of file SelectionToken.hpp.

◆ within

◆ wrappedX

const int OpenMD::Token::wrappedX = atomproperty | dynamic | 6
static

◆ wrappedY

const int OpenMD::Token::wrappedY = atomproperty | dynamic | 7
static

◆ wrappedZ

const int OpenMD::Token::wrappedZ = atomproperty | dynamic | 8
static

◆ x

const int OpenMD::Token::x = atomproperty | dynamic | 2
static

◆ y

const int OpenMD::Token::y = atomproperty | dynamic | 3
static

◆ z

const int OpenMD::Token::z = atomproperty | dynamic | 4
static

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