Package oms3.nap
Interface AnnotationHandler
-
- All Known Implementing Classes:
NetLogo
public interface AnnotationHandlerAnnotation Handler. Implement this interface to handle annotations. The processor will call this handler once with start(), then handle(..) n-times for n annotated lines, and finally done() when done with this file.- Author:
- od
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voiddone()Done with file processing.voidhandle(Map<String,Map<String,String>> ann, String srcLine)Handles a single line of annotated code.voidlog(String msg)Logging during parsingvoidstart(String src)Called by the processor when starting processing annotations for a file.
-
-
-
Field Detail
-
VALUE
static final String VALUE
- See Also:
- Constant Field Values
-
-
Method Detail
-
start
void start(String src)
Called by the processor when starting processing annotations for a file.- Parameters:
file- the file that is processed as String.
-
handle
void handle(Map<String,Map<String,String>> ann, String srcLine)
Handles a single line of annotated code.- Parameters:
annValue- annotations KVPs in a map. It is empty if there is no annotation argument (tagging annotation), annValue.get("value") will return a single value argument.rcLine- the source line that follows the annotations, if there is none (e.g. another annotation follows), the value will be null.
-
log
void log(String msg)
Logging during parsing- Parameters:
msg-
-
-