OpenMD 3.0
Molecular Dynamics in the Open
Loading...
Searching...
No Matches
OpenMD::Token Class Reference

#include <SelectionToken.hpp>

Public Member Functions

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

Public Attributes

int tok {unknown}
 
int intValue {}
 
std::any value {}
 

Static Public Attributes

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

Detailed Description

Todo
document
Note
translate from jmol

Definition at line 57 of file SelectionToken.hpp.

Constructor & Destructor Documentation

◆ Token() [1/4]

OpenMD::Token::Token ( int myTok)
inlineexplicit

Definition at line 64 of file SelectionToken.hpp.

◆ Token() [2/4]

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

Definition at line 65 of file SelectionToken.hpp.

◆ Token() [3/4]

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

Definition at line 66 of file SelectionToken.hpp.

◆ Token() [4/4]

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

Definition at line 67 of file SelectionToken.hpp.

Member Data Documentation

◆ all

constexpr int OpenMD::Token::all = expression | 9
staticconstexpr

Definition at line 118 of file SelectionToken.hpp.

◆ alphahull

constexpr int OpenMD::Token::alphahull = expression | dynamic | 13
staticconstexpr

Definition at line 122 of file SelectionToken.hpp.

◆ asterisk

constexpr int OpenMD::Token::asterisk = expression | 7
staticconstexpr

Definition at line 116 of file SelectionToken.hpp.

◆ atomno

constexpr int OpenMD::Token::atomno = atomproperty | 9
staticconstexpr

Definition at line 140 of file SelectionToken.hpp.

◆ atomproperty

constexpr int OpenMD::Token::atomproperty = (1 << 12) | expression | negnums
staticconstexpr

Definition at line 95 of file SelectionToken.hpp.

◆ charge

constexpr int OpenMD::Token::charge = atomproperty | dynamic | 1
staticconstexpr

Definition at line 132 of file SelectionToken.hpp.

◆ command

constexpr int OpenMD::Token::command = (1 << 8)
staticconstexpr

Definition at line 82 of file SelectionToken.hpp.

◆ comment

constexpr int OpenMD::Token::comment = 8
staticconstexpr

Definition at line 78 of file SelectionToken.hpp.

◆ comparator

constexpr int OpenMD::Token::comparator = (1 << 13) | expression
staticconstexpr

Definition at line 97 of file SelectionToken.hpp.

◆ decimal

constexpr int OpenMD::Token::decimal = 3
staticconstexpr

Definition at line 73 of file SelectionToken.hpp.

◆ define

constexpr int OpenMD::Token::define = command | expressionCommand | 1
staticconstexpr

Definition at line 102 of file SelectionToken.hpp.

◆ dot

constexpr int OpenMD::Token::dot = expression | 8
staticconstexpr

Definition at line 117 of file SelectionToken.hpp.

◆ dynamic

constexpr int OpenMD::Token::dynamic = (1 << 12)
staticconstexpr

Definition at line 92 of file SelectionToken.hpp.

◆ embeddedExpression

constexpr int OpenMD::Token::embeddedExpression = (1 << 15)
staticconstexpr

Definition at line 99 of file SelectionToken.hpp.

◆ endofline

constexpr int OpenMD::Token::endofline = 9
staticconstexpr

Definition at line 79 of file SelectionToken.hpp.

◆ endofstatement

constexpr int OpenMD::Token::endofstatement = 10
staticconstexpr

Definition at line 80 of file SelectionToken.hpp.

◆ expression

constexpr int OpenMD::Token::expression = (1 << 10)
staticconstexpr

Definition at line 84 of file SelectionToken.hpp.

◆ expressionBegin

constexpr int OpenMD::Token::expressionBegin = expression | 100
staticconstexpr

Definition at line 128 of file SelectionToken.hpp.

◆ expressionCommand

constexpr int OpenMD::Token::expressionCommand = (1 << 9)
staticconstexpr

Definition at line 83 of file SelectionToken.hpp.

◆ expressionEnd

constexpr int OpenMD::Token::expressionEnd = expression | 101
staticconstexpr

Definition at line 129 of file SelectionToken.hpp.

◆ hull

constexpr int OpenMD::Token::hull = expression | dynamic | 12
staticconstexpr

Definition at line 121 of file SelectionToken.hpp.

◆ identifier

constexpr int OpenMD::Token::identifier = 1
staticconstexpr

Definition at line 71 of file SelectionToken.hpp.

◆ index

constexpr int OpenMD::Token::index = (1 << 16) | expression
staticconstexpr

Definition at line 100 of file SelectionToken.hpp.

◆ integer

constexpr int OpenMD::Token::integer = 2
staticconstexpr

Definition at line 72 of file SelectionToken.hpp.

◆ intValue

int OpenMD::Token::intValue {}

Definition at line 60 of file SelectionToken.hpp.

◆ keyword

constexpr int OpenMD::Token::keyword = 6
staticconstexpr

Definition at line 76 of file SelectionToken.hpp.

◆ leftparen

constexpr int OpenMD::Token::leftparen = expression | 0
staticconstexpr

Definition at line 109 of file SelectionToken.hpp.

◆ mass

constexpr int OpenMD::Token::mass = atomproperty | 0
staticconstexpr

Definition at line 131 of file SelectionToken.hpp.

◆ nada

constexpr int OpenMD::Token::nada = 0
staticconstexpr

Definition at line 70 of file SelectionToken.hpp.

◆ name

constexpr int OpenMD::Token::name = expression | 11
staticconstexpr

Definition at line 120 of file SelectionToken.hpp.

◆ negnums

constexpr int OpenMD::Token::negnums = (1 << 11)
staticconstexpr

expression term

Definition at line 88 of file SelectionToken.hpp.

◆ none

constexpr int OpenMD::Token::none = expression | 10
staticconstexpr

Definition at line 119 of file SelectionToken.hpp.

◆ opAnd

constexpr int OpenMD::Token::opAnd = expression | 3
staticconstexpr

Definition at line 112 of file SelectionToken.hpp.

◆ opEQ

constexpr int OpenMD::Token::opEQ = comparator | dynamic | 4
staticconstexpr

Definition at line 146 of file SelectionToken.hpp.

◆ opGE

constexpr int OpenMD::Token::opGE = comparator | dynamic | 1
staticconstexpr

Definition at line 143 of file SelectionToken.hpp.

◆ opGT

constexpr int OpenMD::Token::opGT = comparator | dynamic | 0
staticconstexpr

Definition at line 142 of file SelectionToken.hpp.

◆ opLE

constexpr int OpenMD::Token::opLE = comparator | dynamic | 2
staticconstexpr

Definition at line 144 of file SelectionToken.hpp.

◆ opLT

constexpr int OpenMD::Token::opLT = comparator | dynamic | 3
staticconstexpr

Definition at line 145 of file SelectionToken.hpp.

◆ opNE

constexpr int OpenMD::Token::opNE = comparator | dynamic | 5
staticconstexpr

Definition at line 147 of file SelectionToken.hpp.

◆ opNot

constexpr int OpenMD::Token::opNot = expression | 5
staticconstexpr

Definition at line 114 of file SelectionToken.hpp.

◆ opOr

constexpr int OpenMD::Token::opOr = expression | 4
staticconstexpr

Definition at line 113 of file SelectionToken.hpp.

◆ predefinedset

constexpr int OpenMD::Token::predefinedset = (1 << 14) | expression
staticconstexpr

Definition at line 98 of file SelectionToken.hpp.

◆ r

constexpr int OpenMD::Token::r = atomproperty | dynamic | 5
staticconstexpr

Definition at line 136 of file SelectionToken.hpp.

◆ rightparen

constexpr int OpenMD::Token::rightparen = expression | 1
staticconstexpr

Definition at line 110 of file SelectionToken.hpp.

◆ select

constexpr int OpenMD::Token::select = command | expressionCommand | 2
staticconstexpr

Definition at line 103 of file SelectionToken.hpp.

◆ string

constexpr int OpenMD::Token::string = 4
staticconstexpr

Definition at line 74 of file SelectionToken.hpp.

◆ to

constexpr int OpenMD::Token::to = expression | 2
staticconstexpr

Definition at line 111 of file SelectionToken.hpp.

◆ tok

int OpenMD::Token::tok {unknown}

Definition at line 59 of file SelectionToken.hpp.

◆ tokenExpressionBegin

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

Definition at line 149 of file SelectionToken.hpp.

◆ tokenExpressionEnd

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

Definition at line 150 of file SelectionToken.hpp.

◆ unknown

constexpr int OpenMD::Token::unknown = 5
staticconstexpr

Definition at line 75 of file SelectionToken.hpp.

◆ value

std::any OpenMD::Token::value {}

Definition at line 61 of file SelectionToken.hpp.

◆ whitespace

constexpr int OpenMD::Token::whitespace = 7
staticconstexpr

Definition at line 77 of file SelectionToken.hpp.

◆ within

constexpr int OpenMD::Token::within = expression | dynamic | 6
staticconstexpr

Definition at line 115 of file SelectionToken.hpp.

◆ wrappedX

constexpr int OpenMD::Token::wrappedX = atomproperty | dynamic | 6
staticconstexpr

Definition at line 137 of file SelectionToken.hpp.

◆ wrappedY

constexpr int OpenMD::Token::wrappedY = atomproperty | dynamic | 7
staticconstexpr

Definition at line 138 of file SelectionToken.hpp.

◆ wrappedZ

constexpr int OpenMD::Token::wrappedZ = atomproperty | dynamic | 8
staticconstexpr

Definition at line 139 of file SelectionToken.hpp.

◆ x

constexpr int OpenMD::Token::x = atomproperty | dynamic | 2
staticconstexpr

Definition at line 133 of file SelectionToken.hpp.

◆ y

constexpr int OpenMD::Token::y = atomproperty | dynamic | 3
staticconstexpr

Definition at line 134 of file SelectionToken.hpp.

◆ z

constexpr int OpenMD::Token::z = atomproperty | dynamic | 4
staticconstexpr

Definition at line 135 of file SelectionToken.hpp.


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