summaryrefslogtreecommitdiffstats
path: root/config-model/src/main/javacc/SDParser.jj
diff options
context:
space:
mode:
Diffstat (limited to 'config-model/src/main/javacc/SDParser.jj')
-rw-r--r--config-model/src/main/javacc/SDParser.jj11
1 files changed, 7 insertions, 4 deletions
diff --git a/config-model/src/main/javacc/SDParser.jj b/config-model/src/main/javacc/SDParser.jj
index b6a9ab789bf..5b7721c0fe9 100644
--- a/config-model/src/main/javacc/SDParser.jj
+++ b/config-model/src/main/javacc/SDParser.jj
@@ -395,15 +395,16 @@ SPECIAL_TOKEN :
* The rule consumes any schema and returns the corresponding object. This is the only production that should
* ever consume leading newlines.
*
+ * @param dir the directory containing the file being parsed
* @return the schema object
*/
-Schema schema(DocumentTypeManager docMan) :
+Schema schema(DocumentTypeManager docMan, String dir) :
{
this.docMan = docMan;
Schema schema;
}
{
- (<NL>)* (schema = rootSchema() | schema = rootDocument())
+ (<NL>)* (schema = rootSchema(dir) | schema = rootDocument(dir))
{ return schema; }
}
@@ -411,9 +412,10 @@ Schema schema(DocumentTypeManager docMan) :
* This rule consumes a proper schema block. This and rootDocument() are the only rules that should ever consume
* trailing newline tokens.
*
+ * @param dir the directory containing the file being parsed.
* @return the schema definition object.
*/
-Schema rootSchema() :
+Schema rootSchema(String dir) :
{
String name;
String inherited = null;
@@ -457,9 +459,10 @@ Object rootSchemaItem(Schema schema) : { }
/**
* Consumes a schema definition that contains only documents to be used for inheritance, etc.
*
+ * @param dir the directory containing the file being parsed.
* @return the schema definition object.
*/
-Schema rootDocument() :
+Schema rootDocument(String dir) :
{
Schema schema = new DocumentOnlySchema(applicationPackage, fileRegistry, deployLogger, properties);
}