Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- private def withModifier(req: Requirement): Parser[Any] = {
- if(req.isInstanceOf[DegreeRequirement]) {
- err("_with_ modifiers may not be applied to Degree requirements")
- } |
- (("with"~>determiner)^^{
- //In here I would like to check if req isInstanceOf[RelationshipRequirement]
- //If it is, I would then like to do case d => req.asInstanceOf[RelationshipRequirement].related = d.provtype
- }) |
- ("with"~>"probability"~>numericLit^^{
- case p => req.probability = p.toDouble
- })
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement