Class GrammarConstraintProvider
- java.lang.Object
-
- org.eclipse.xtext.serializer.analysis.GrammarConstraintProvider
-
- All Implemented Interfaces:
IGrammarConstraintProvider
public class GrammarConstraintProvider extends java.lang.Object implements IGrammarConstraintProvider
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description protected static class
GrammarConstraintProvider.Constraint
protected static class
GrammarConstraintProvider.ConstraintElement
protected static class
GrammarConstraintProvider.ConstraintElementFactory
protected static class
GrammarConstraintProvider.FeatureInfo
-
Nested classes/interfaces inherited from interface org.eclipse.xtext.serializer.analysis.IGrammarConstraintProvider
IGrammarConstraintProvider.ConstraintElementProduction, IGrammarConstraintProvider.ConstraintElementType, IGrammarConstraintProvider.IConstraint, IGrammarConstraintProvider.IConstraintElement, IGrammarConstraintProvider.IFeatureInfo
-
-
Field Summary
Fields Modifier and Type Field Description protected Context2NameFunction
context2Name
-
Fields inherited from interface org.eclipse.xtext.serializer.analysis.IGrammarConstraintProvider
MAX
-
-
Constructor Summary
Constructors Constructor Description GrammarConstraintProvider()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected com.google.common.collect.Multimap<Parameter,java.lang.Boolean>
collectAllParameterValues(IGrammarConstraintProvider.IConstraint constraint)
protected java.lang.String
findBestConstraintName(Grammar grammar, SerializationContextMap<org.eclipse.xtext.util.formallang.Pda<ISerState,RuleCall>> typePDAs, IGrammarConstraintProvider.IConstraint constraint)
SerializationContextMap<IGrammarConstraintProvider.IConstraint>
getConstraints(Grammar grammar)
Returns all constraints form this grammar.
-
-
-
Field Detail
-
context2Name
@Inject protected Context2NameFunction context2Name
-
-
Method Detail
-
collectAllParameterValues
protected com.google.common.collect.Multimap<Parameter,java.lang.Boolean> collectAllParameterValues(IGrammarConstraintProvider.IConstraint constraint)
-
findBestConstraintName
protected java.lang.String findBestConstraintName(Grammar grammar, SerializationContextMap<org.eclipse.xtext.util.formallang.Pda<ISerState,RuleCall>> typePDAs, IGrammarConstraintProvider.IConstraint constraint)
-
getConstraints
public SerializationContextMap<IGrammarConstraintProvider.IConstraint> getConstraints(Grammar grammar)
Description copied from interface:IGrammarConstraintProvider
Returns all constraints form this grammar. If a constraint belongs to multiple ConstraintContexts, it is important to call this method to ensure there is inly one instance fo this constraint.- Specified by:
getConstraints
in interfaceIGrammarConstraintProvider
-
-