BRIEFS Information Extraction
Appendix A. BRIEFS Common Pattern Specification Language Grammar
- Rules:
- Rule:
- NameDecl Constraints --> Actions
- NameDecl PriorityDecl Constraints --> Actions
- NameDecl:
- PriorityDecl:
- Constraints:
- PreCondition ConstraintGroup PostCondition
- PreCondition:
- PostCondition:
- ConstraintGroup:
- PatternElements | ConstraintGroup
- PatternElements
- PatternElements:
- PatternElement
- PatternElement PatternElements
- PatternElement:
- BasicPatternElement
- ( ConstraintGroup ) KleeneOp Binding
- ( ConstraintGroup )
- ( ConstraintGroup ) KleeneOp
- ( ConstraintGroup ) Binding
- KleeneOp:
- Binding:
- BasicPatternElement:
- { CExpression }
- FunctionCall
- CExpression:
- Constraint
- Constraint , CExpression
- IndexOp:
- Index:
- Constraint:
- Anno TestOp Value
- Anno TestOp (for unary operators)
- AnnoType
- Anno:
- AnnoType:
- AttrName:
- TestOp:
- == (equal)
- != (not equal)
- < (less)
- > (greater)
- <= (less or equal)
- >= (greater or equal)
- =~ (regular expression match)
- !~ (regular expression does not match)
- EX (attribute exists, unary operator)
- NX (attribute does not exist, unary operator)
- Value:
- NUMBER
- QUOTED_STRING
- SYMBOL
- TK_TRUE
- TK_FALSE
- Annotation
- Actions:
- ActionExp MoreActions
- ActionExp
- MoreActions:
- , ActionExp MoreActions
- , ActionExp
- ActionExp:
- ( IF ACExpression THEN Actions )
- ( IF ACExpression THEN Actions ELSE Actions )
- Action
- ACExpression:
- AConstraint
- AConstraint BooleanOp ACExpression
- BooleanOp:
- AConstraint:
- IndexExpression TestOp Value
- IndexExpression TestOp (for unary operators)
- Action:
- Assignment:
- IndexExpression = @
- IndexExpression = Value
- IndexExpression = IndexExpression
- IndexExpression = FunctionCall
- IndexExpression += Value
- IndexExpression += IndexExpression
- IndexExpression += FunctionCall
- IndexExpression:
- Field:
- . AnnoType . AttrName
- . AnnoType
- FunctionCall:
- FunctionName:
- ArgList:
- IndexExpression
- ^ IndexExpression
- Value
- Value , ArgList
- IndexExpression , ArgList
- ^ IndexExpression , ArgList
HUT/TAI Research Centre
Lauri Seitsonen
Last modified 3.1.2002