org.eclipse.xtext.parser
Interface IAstFactory

All Known Implementing Classes:
DefaultEcoreElementFactory

public interface IAstFactory

Responsible for instantiating and initializing the semantic model according to call backs from clients. Main (and only default) client is the parser.

Author:
Sven Efftinge

Method Summary
 void add(org.eclipse.emf.ecore.EObject _this, java.lang.String feature, java.lang.Object value, java.lang.String lexerRule, INode node)
          Adds a given value to a list described by the given feature.
 org.eclipse.emf.ecore.EObject create(org.eclipse.emf.ecore.EClassifier clazz)
          Creates an instance of the given type which has to be an EClass.
 void set(org.eclipse.emf.ecore.EObject _this, java.lang.String feature, java.lang.Object value, java.lang.String lexerRule, INode node)
          Assigns a given value to a feature of the element _this.
 

Method Detail

create

org.eclipse.emf.ecore.EObject create(org.eclipse.emf.ecore.EClassifier clazz)
Creates an instance of the given type which has to be an EClass.

Parameters:
clazz - the EClass to be instantiated.
Returns:
the instantiated EObject which must conform the given class.

set

void set(org.eclipse.emf.ecore.EObject _this,
         java.lang.String feature,
         java.lang.Object value,
         java.lang.String lexerRule,
         INode node)
         throws ValueConverterException
Assigns a given value to a feature of the element _this. The value may be converted according to the optional lexer rule. The feature must be resolvable to a single value feature.

Throws:
ValueConverterException - if the value cannot be converted.

add

void add(org.eclipse.emf.ecore.EObject _this,
         java.lang.String feature,
         java.lang.Object value,
         java.lang.String lexerRule,
         INode node)
         throws ValueConverterException
Adds a given value to a list described by the given feature. The list is owned by the element _this. The given value may be converted according to the optional lexer rule. The feature must be resolvable to a multi value feature.

Throws:
ValueConverterException - if the value cannot be converted.