Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » TMF (Xtext) » How to implement scoping and validation for an element at same time
How to implement scoping and validation for an element at same time [message #1795617] Wed, 26 September 2018 09:00 Go to next message
shubhankar chowdhury is currently offline shubhankar chowdhuryFriend
Messages: 17
Registered: January 2018
Junior Member
Hi,
I have Implemented scoping for an element
contentRef<Dropdown list which match some condition >

element in drop down list has implementation with a value for USED as : USED True/False

drop down list will contain elements with USED as True

So in contentRef dropdown it is contain elements with USED as True

Now if in future , if user changes the USED from True to False it should throw error from validation but it is not throwing


Eg :
Correct Example:
abc {
contentRef measureVal
}

measureVal {
USED True

}
measureValue2{
USED False
}

Now user changes the value of USED in measureVal from True to False then contentRef should throw an error from validation but it is not throwing error from validation.Instead it is just throwing a general error as : "Couldn't resolve reference to EObject 'measureVal'."

Wrong example :

abc {
contentRef measureVal //it will throw error as "Couldn't resolve reference to EObject 'measureVal" but I want customized error message
}

measureVal {
USED False

}
measureValue2{
USED False
}



Re: How to implement scoping and validation for an element at same time [message #1795635 is a reply to message #1795617] Wed, 26 September 2018 10:25 Go to previous message
Karsten Thoms is currently offline Karsten ThomsFriend
Messages: 762
Registered: July 2009
Location: Dortmund, Germany
Senior Member

To customize the message customize the binding for ILinkingDiagnosticMessageProvider
Previous Topic:JAVA HEAP SPACE (OUT OF MEMEORY)
Next Topic:Cloning/Copying Xtext Resource including node model
Goto Forum:
  


Current Time: Thu Mar 28 22:43:01 GMT 2024

Powered by FUDForum. Page generated in 0.08470 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top