Search in sources :

Example 51 with INodesForEObjectProvider

use of org.eclipse.xtext.serializer.sequencer.ISemanticNodeProvider.INodesForEObjectProvider in project mechanoid by robotoworks.

the class SqliteModelSemanticSequencer method sequence_ContentUriSegment.

/**
	 * Constraint:
	 *     name=ID
	 */
protected void sequence_ContentUriSegment(EObject context, ContentUriSegment semanticObject) {
    if (errorAcceptor != null) {
        if (transientValues.isValueTransient(semanticObject, SqliteModelPackage.Literals.CONTENT_URI_SEGMENT__NAME) == ValueTransient.YES)
            errorAcceptor.accept(diagnosticProvider.createFeatureValueMissing(semanticObject, SqliteModelPackage.Literals.CONTENT_URI_SEGMENT__NAME));
    }
    INodesForEObjectProvider nodes = createNodeProvider(semanticObject);
    SequenceFeeder feeder = createSequencerFeeder(semanticObject, nodes);
    feeder.accept(grammarAccess.getContentUriSegmentAccess().getNameIDTerminalRuleCall_0_0(), semanticObject.getName());
    feeder.finish();
}
Also used : SequenceFeeder(org.eclipse.xtext.serializer.acceptor.SequenceFeeder) INodesForEObjectProvider(org.eclipse.xtext.serializer.sequencer.ISemanticNodeProvider.INodesForEObjectProvider)

Example 52 with INodesForEObjectProvider

use of org.eclipse.xtext.serializer.sequencer.ISemanticNodeProvider.INodesForEObjectProvider in project mechanoid by robotoworks.

the class SqliteModelSemanticSequencer method sequence_ExprAnd.

/**
	 * Constraint:
	 *     (left=ExprAnd_ExprAnd_1_0 op='and' right=ExprOr)
	 */
protected void sequence_ExprAnd(EObject context, ExprAnd semanticObject) {
    if (errorAcceptor != null) {
        if (transientValues.isValueTransient(semanticObject, SqliteModelPackage.Literals.EXPR_AND__LEFT) == ValueTransient.YES)
            errorAcceptor.accept(diagnosticProvider.createFeatureValueMissing(semanticObject, SqliteModelPackage.Literals.EXPR_AND__LEFT));
        if (transientValues.isValueTransient(semanticObject, SqliteModelPackage.Literals.EXPR_AND__OP) == ValueTransient.YES)
            errorAcceptor.accept(diagnosticProvider.createFeatureValueMissing(semanticObject, SqliteModelPackage.Literals.EXPR_AND__OP));
        if (transientValues.isValueTransient(semanticObject, SqliteModelPackage.Literals.EXPR_AND__RIGHT) == ValueTransient.YES)
            errorAcceptor.accept(diagnosticProvider.createFeatureValueMissing(semanticObject, SqliteModelPackage.Literals.EXPR_AND__RIGHT));
    }
    INodesForEObjectProvider nodes = createNodeProvider(semanticObject);
    SequenceFeeder feeder = createSequencerFeeder(semanticObject, nodes);
    feeder.accept(grammarAccess.getExprAndAccess().getExprAndLeftAction_1_0(), semanticObject.getLeft());
    feeder.accept(grammarAccess.getExprAndAccess().getOpAndKeyword_1_1_0(), semanticObject.getOp());
    feeder.accept(grammarAccess.getExprAndAccess().getRightExprOrParserRuleCall_1_2_0(), semanticObject.getRight());
    feeder.finish();
}
Also used : SequenceFeeder(org.eclipse.xtext.serializer.acceptor.SequenceFeeder) INodesForEObjectProvider(org.eclipse.xtext.serializer.sequencer.ISemanticNodeProvider.INodesForEObjectProvider)

Example 53 with INodesForEObjectProvider

use of org.eclipse.xtext.serializer.sequencer.ISemanticNodeProvider.INodesForEObjectProvider in project mechanoid by robotoworks.

the class SqliteModelSemanticSequencer method sequence_LiteralValue.

/**
	 * Constraint:
	 *     literal='current_timestamp'
	 */
protected void sequence_LiteralValue(EObject context, CurrentTimeStampLiteral semanticObject) {
    if (errorAcceptor != null) {
        if (transientValues.isValueTransient(semanticObject, SqliteModelPackage.Literals.CURRENT_TIME_STAMP_LITERAL__LITERAL) == ValueTransient.YES)
            errorAcceptor.accept(diagnosticProvider.createFeatureValueMissing(semanticObject, SqliteModelPackage.Literals.CURRENT_TIME_STAMP_LITERAL__LITERAL));
    }
    INodesForEObjectProvider nodes = createNodeProvider(semanticObject);
    SequenceFeeder feeder = createSequencerFeeder(semanticObject, nodes);
    feeder.accept(grammarAccess.getLiteralValueAccess().getLiteralCurrent_timestampKeyword_5_1_0(), semanticObject.getLiteral());
    feeder.finish();
}
Also used : SequenceFeeder(org.eclipse.xtext.serializer.acceptor.SequenceFeeder) INodesForEObjectProvider(org.eclipse.xtext.serializer.sequencer.ISemanticNodeProvider.INodesForEObjectProvider)

Example 54 with INodesForEObjectProvider

use of org.eclipse.xtext.serializer.sequencer.ISemanticNodeProvider.INodesForEObjectProvider in project mechanoid by robotoworks.

the class SqliteModelSemanticSequencer method sequence_PrimaryExpression.

/**
	 * Constraint:
	 *     column=[ColumnSource|ID]
	 */
protected void sequence_PrimaryExpression(EObject context, OldColumn semanticObject) {
    if (errorAcceptor != null) {
        if (transientValues.isValueTransient(semanticObject, SqliteModelPackage.Literals.OLD_COLUMN__COLUMN) == ValueTransient.YES)
            errorAcceptor.accept(diagnosticProvider.createFeatureValueMissing(semanticObject, SqliteModelPackage.Literals.OLD_COLUMN__COLUMN));
    }
    INodesForEObjectProvider nodes = createNodeProvider(semanticObject);
    SequenceFeeder feeder = createSequencerFeeder(semanticObject, nodes);
    feeder.accept(grammarAccess.getPrimaryExpressionAccess().getColumnColumnSourceIDTerminalRuleCall_1_2_0_1(), semanticObject.getColumn());
    feeder.finish();
}
Also used : SequenceFeeder(org.eclipse.xtext.serializer.acceptor.SequenceFeeder) INodesForEObjectProvider(org.eclipse.xtext.serializer.sequencer.ISemanticNodeProvider.INodesForEObjectProvider)

Example 55 with INodesForEObjectProvider

use of org.eclipse.xtext.serializer.sequencer.ISemanticNodeProvider.INodesForEObjectProvider in project mechanoid by robotoworks.

the class SqliteModelSemanticSequencer method sequence_LiteralValue.

/**
	 * Constraint:
	 *     literal='null'
	 */
protected void sequence_LiteralValue(EObject context, NullLiteral semanticObject) {
    if (errorAcceptor != null) {
        if (transientValues.isValueTransient(semanticObject, SqliteModelPackage.Literals.NULL_LITERAL__LITERAL) == ValueTransient.YES)
            errorAcceptor.accept(diagnosticProvider.createFeatureValueMissing(semanticObject, SqliteModelPackage.Literals.NULL_LITERAL__LITERAL));
    }
    INodesForEObjectProvider nodes = createNodeProvider(semanticObject);
    SequenceFeeder feeder = createSequencerFeeder(semanticObject, nodes);
    feeder.accept(grammarAccess.getLiteralValueAccess().getLiteralNullKeyword_2_1_0(), semanticObject.getLiteral());
    feeder.finish();
}
Also used : SequenceFeeder(org.eclipse.xtext.serializer.acceptor.SequenceFeeder) INodesForEObjectProvider(org.eclipse.xtext.serializer.sequencer.ISemanticNodeProvider.INodesForEObjectProvider)

Aggregations

INodesForEObjectProvider (org.eclipse.xtext.serializer.sequencer.ISemanticNodeProvider.INodesForEObjectProvider)65 SequenceFeeder (org.eclipse.xtext.serializer.acceptor.SequenceFeeder)64 List (java.util.List)2 AbstractElement (org.eclipse.xtext.AbstractElement)2 IConstraint (org.eclipse.xtext.serializer.analysis.IGrammarConstraintProvider.IConstraint)2 EObject (org.eclipse.emf.ecore.EObject)1 InternalEList (org.eclipse.emf.ecore.util.InternalEList)1 INode (org.eclipse.xtext.nodemodel.INode)1 ISemState (org.eclipse.xtext.serializer.analysis.ISemanticSequencerNfaProvider.ISemState)1 NfaUtil (org.eclipse.xtext.util.formallang.NfaUtil)1