templates.cpp.MultiNode.template Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of ph-javacc-maven-plugin Show documentation
Show all versions of ph-javacc-maven-plugin Show documentation
Maven 3 Plugin for processing JavaCC grammar files.
class ${NODE_TYPE} : public ${NODE_CLASS:-SimpleNode} {
public:
${NODE_TYPE}(int id) : ${NODE_CLASS:-SimpleNode}(id){
}
${NODE_TYPE}(${PARSER_NAME} *p, int id) : ${NODE_CLASS:-SimpleNode}(p, id) {
}
#if VISITOR
/** Accept the visitor. **/
${VISITOR_RETURN_TYPE} jjtAccept(${PARSER_NAME}Visitor *visitor, ${VISITOR_DATA_TYPE:-void *} data) const {
#if !VISITOR_RETURN_TYPE_VOID
return
#fi
#if VISITOR_METHOD_NAME_INCLUDES_TYPE_NAME
visitor->visit${NODE_TYPE}(this, data);
#else
visitor->visit(this, data);
#fi
}
public: virtual ~${NODE_TYPE}(){
}
#fi
};