--- trunk/src/mdParser/MDParser.g 2005/12/16 02:57:00 814 +++ trunk/src/mdParser/MDParser.g 2008/07/14 12:35:58 1277 @@ -32,10 +32,12 @@ tokens BOND = "bond"; BEND = "bend"; TORSION = "torsion"; + INVERSION = "inversion"; RIGIDBODY = "rigidBody"; CUTOFFGROUP = "cutoffGroup"; FRAGMENT = "fragment"; MEMBERS = "members"; + CENTER = "center"; POSITION = "position"; ORIENTATION = "orientation"; ENDBLOCK; @@ -74,6 +76,7 @@ moleculestatement : assignment | bondblock | bendblock | torsionblock + | inversionblock | rigidbodyblock | cutoffgroupblock | fragmentblock @@ -107,6 +110,13 @@ torsionstatement : assignment torsionstatement : assignment | MEMBERS^ LPAREN! inttuple RPAREN! SEMICOLON! + ; + +inversionblock : INVERSION^ (LBRACKET! intConst! RBRACKET!)? LCURLY!(inversionstatement)* RCURLY {#RCURLY->setType(ENDBLOCK);} + ; + +inversionstatement : assignment + | CENTER^ LPAREN! intConst RPAREN! SEMICOLON! ; rigidbodyblock : RIGIDBODY^ LBRACKET! intConst RBRACKET! LCURLY!(rigidbodystatement)* RCURLY {#RCURLY->setType(ENDBLOCK);} @@ -457,7 +467,7 @@ EXPONENT // a couple protected methods to assist in matching floating point numbers protected EXPONENT - : ('e'|'E') ('+'|'-')? ('0'..'9')+ + : ('e'|'E'|'d'|'D') ('+'|'-')? ('0'..'9')+ ; protected