OK, I have gotten a little bit further. The first "mismatched input" error
gave me a clue about the problem. I had added two attributes to
DslReference. When I comment out the two new attributes from the
sculptordsl.xtxt file and remove them from my model.design file, the
generator works. I don't see the problem though because I copied and pasted
them from another concept and those work fine. Also, I can see these two
attributes in the generated metamodel Java files. The definition is as
follows:
DslReference :
(doc=STRING)?
REF (visibility=DslVisibility)? (collectionType=DslCollectionType"<")?
(("@")?domainObjectType=[DslSimpleDomainObject]) (">")? name=ID
((key?="key") |
((notChangeable?=NOT "changeable") | ("changeable")) |
((required?="required") | (NOT "required")) |
((nullable?="nullable") | (NOT "nullable")) |
("cascade" "=" cascade=STRING) |
("fetch" "=" fetch=STRING) |
((cache?="cache") | (NOT "cache")) |
((inverse?="inverse") | (NOT "inverse")) |
("databaseColumn" "=" databaseColumn=STRING) |
("orderBy" "=" orderBy=ID) |
("foo" "=" foo=STRING) |
("foo2" "=" foo2=STRING))*
(OPPOSITE oppositeName=ID)? (";")?;
--Polly
amphoras wrote:
>
> Hi,
>
> I am making some modifications to the Sculptor DSL according to the
> instructions in the Developer's Guide. I added some attributes to
> DomainObject and Attribute and introduced a new concept called Constant
> and added this as a collection to DomainObject.
>
> I am able to generate the editor plugin and type my new keywords into
> "model.design" file. All my new keywords are highlighted and there are no
> syntax errors. I was quite pleased and thought that I was doing
> everything correctly.
>
> However, I know now that I should have run the model.design's generator
> with each change to make sure it really worked before adding the next
> thing! After making all these changes, I fired up Maven's install goal
> for the first time, and I get:
>
> 1551 INFO CompositeComponent - Workflow: executing workflow
> sculptorworkflow.oaw in workflow.oaw:3
> 1551 INFO CompositeComponent - Workflow: executing workflow
> org/fornax/cartridges/sculptor/dsl/parser/Parser.oaw in
> sculptorworkflow.oaw:29
> 1551 INFO CompositeComponent - ParserComponent(sculptordsl-parser)
> 1739 INFO CompositeComponent - IfComponent: executing if
> org/fornax/cartridges/sculptor/dsl/parser/Parser.oaw in
> org/fornax/cartridges/sculptor/dsl/parser/Parser.oaw:9
> 1739 INFO ConditionalComponent - CheckComponent(sculptordsl-checker):
> expression dslModel.eAllContents.union({dslModel}) check file(s):
> org::fornax::cartridges::sculptor::dsl::GenChecks
> org::fornax::cartridges::sculptor::dsl::Checks
> 1864 ERROR AbstractExpressionsUsingWorkflowComponent - Error in Component
> sculptordsl-checker of type org.openarchitectureware.check.CheckComponent:
> EvaluationException : Couldn't find type or property 'dslModel'
> nofile[0,8] on line 1 'dslModel'
>
> 1864 ERROR WorkflowRunner - mismatched input 'foo' expecting '}' on
> line 95 in model.design
> ...[snip a bunch more mismatched input errors]...
>
> 1864 ERROR WorkflowRunner - no viable alternative at input '<EOF>' on
> line 0 in model.design
> 1864 ERROR WorkflowRunner - ERROR in Component sculptordsl-checker of
> type org.openarchitectureware.check.CheckComponent
> Couldn't find type or property 'dslModel' [dslModel] in workflow:
> CheckComponent(sculptordsl-checker): expression
> dslModel.eAllContents.union({dslModel}) check file(s):
> org::fornax::cartridges::sculptor::dsl::GenChecks
> org::fornax::cartridges::sculptor::dsl::Checks
> 1864 ERROR WorkflowRunner - ERROR in Component sculptordsl-checker of
> type org.openarchitectureware.check.CheckComponent
> Couldn't find type or property 'dslModel' [dslModel.eAllContents] in
> workflow: CheckComponent(sculptordsl-checker): expression
> dslModel.eAllContents.union({dslModel}) check file(s):
> org::fornax::cartridges::sculptor::dsl::GenChecks
> org::fornax::cartridges::sculptor::dsl::Checks
> 1880 ERROR WorkflowRunner - ERROR in Component sculptordsl-checker of
> type org.openarchitectureware.check.CheckComponent
> Couldn't find type or property 'dslModel'
> [dslModel.eAllContents.union({dslModel})] in workflow:
> CheckComponent(sculptordsl-checker): expression
> dslModel.eAllContents.union({dslModel}) check file(s):
> org::fornax::cartridges::sculptor::dsl::GenChecks
> org::fornax::cartridges::sculptor::dsl::Checks
> [FATAL ERROR] org.fornax.toolsupport.maven2.OawWorkflowMojo#execute()
> caused a linkage error (java.lang.NoSuchMethodError) and may be
> out-of-date. Check the realms:
> [FATAL ERROR] Plugin realm =
> app0.child-container[org.fornax.toolsupport:fornax-oaw-m2-plugin]
> ...
>
> I have no idea what these errors mean. I didn't change the GenChecks.chk
> and Checks.chk files. What file did I mess up? The only thing that I can
> think of doing is to retrace my steps and take out my changes one by one
> to see if I can get back to something that generates. That is going to be
> time consuming though, so I appreciate any hints or clues that you can
> give me.
>
> Thanks,
> Polly
>
>
--
View this message in context:
http://www.nabble.com/-sculptor--weird-errors-after-editing-DSL-tp18389174s17564p18389967.html
Sent from the Fornax-Platform mailing list archive at Nabble.com.
-------------------------------------------------------------------------
Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
Studies have shown that voting for your favorite open source project,
along with a healthy diet, reduces your potential for chronic lameness
and boredom. Vote Now at http://www.sourceforge.net/community/cca08
_______________________________________________
Fornax-developer mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/fornax-developer