// motivated by the Kerf project by Jay Aslam et al. import edu.neu.ccs.demeter.dj.*; Main = String. Examples = List(SawQL) EOF. SawQL = "{" Element List(RelTimeElement) "}" . Element : SubQuery . RelTimeElement = [RelTime] Element. SubQuery : Simple | Compound. Simple = Keyword Parameter. Keyword : Hosts | Service | IPAddress. Hosts = "HOSTS". Service = "SERVICE". IPAddress = "IPADDRESS". Compound = "(" Op List(SubQuery) ")". Op : And | Or . And = "and". Or = "or". RelTime : Minutes | Anytime. Minutes = "+" int. Anytime = "ANYTIME". Parameter : Constant | Variable | RegularExp . Constant = String. Variable = "%" VariableName. RegularExp = "*". VariableName = Ident. List(S) ~ {S}. CList(S) ~ "(" S {"," S} ")".