io.sarl.lang.codebuilder.builders
Class AbstractBuilder
All Known Subclasses:
BlockExpressionBuilderImpl, ExpressionBuilderImpl, FormalParameterBuilderImpl, SarlActionBuilderImpl, SarlAgentBuilderImpl, SarlAnnotationTypeBuilderImpl, SarlArtifactBuilderImpl, SarlBehaviorBuilderImpl, SarlBehaviorUnitBuilderImpl, SarlCapacityBuilderImpl, SarlClassBuilderImpl, SarlConstructorBuilderImpl, SarlEnumLiteralBuilderImpl, SarlEnumerationBuilderImpl, SarlEventBuilderImpl, SarlFieldBuilderImpl, SarlInterfaceBuilderImpl, SarlSkillBuilderImpl, SarlSpaceBuilderImpl, ScriptBuilderImpl, TypeParameterBuilderImpl
abstract class AbstractBuilder
extends java.lang.Object
Abstract implementation of a builder for the Sarl language.
Property Summary
Modifier and type Property and description
protected org.eclipse.xtext.xbase.compiler.ImportManager importManager
Replies the import manager that stores the imported types.
protected org.eclipse.xtext.xbase.imports.IImportsConfiguration importsConfiguration
Replies the import's configuration.
protected org.eclipse.xtext.common.types.util.Primitives primitiveTypes
Replies the primitive type tools.
protected org.eclipse.xtext.resource.IResourceFactory resourceFactory
Replies the resource factory.
java.lang.String scriptFileExtension
Replies the script's file extension.
protected org.eclipse.xtext.common.types.util.TypeReferences typeReferences
Replies the builder of type references.
org.eclipse.xtext.common.types.access.IJvmTypeProvider typeResolutionContext
Constructor Summary
Constructor and description
new
Action Summary
Modifier and type Action and description
protected org.eclipse.emf.common.util.URI computeUnusedUri(ResourceSet)
Compute a unused URI for a synthetic resource.
void dispose
abstract org.eclipse.emf.ecore.resource.Resource eResource
protected org.eclipse.xtext.common.types.JvmTypeReference findType(Notifier,String)
protected T getAssociatedElement(Class<T>,EObject,Resource)
protected org.eclipse.xtext.xbase.compiler.ImportManager getImportManager
Replies the import manager that stores the imported types.
protected org.eclipse.xtext.xbase.imports.IImportsConfiguration getImportsConfiguration
Replies the import's configuration.
protected org.eclipse.xtext.common.types.util.Primitives getPrimitiveTypes
Replies the primitive type tools.
protected java.lang.String getQualifiedName(EObject)
protected org.eclipse.xtext.resource.IResourceFactory getResourceFactory
Replies the resource factory.
java.lang.String getScriptFileExtension
Replies the script's file extension.
protected org.eclipse.xtext.common.types.util.TypeReferences getTypeReferences
Replies the builder of type references.
org.eclipse.xtext.common.types.access.IJvmTypeProvider getTypeResolutionContext
protected boolean isActionBodyAllowed(XtendTypeDeclaration)
Replies if the type could contains functions with a body.
protected boolean isSubTypeOf(EObject,JvmTypeReference,JvmTypeReference)
Replies if the first parameter is a subtype of the second parameter.
protected boolean isTypeReference(JvmTypeReference)
Replies if the given object is a valid type reference.
org.eclipse.xtext.common.types.JvmParameterizedTypeReference newTypeRef(String)
Replies the type reference for the given name in the given context.
org.eclipse.xtext.common.types.JvmParameterizedTypeReference newTypeRef(Notifier,String)
Replies the type reference for the given name in the given context.
void setFileExtensions(String)
protected void setTypeResolutionContext(IJvmTypeProvider)
protected static org.eclipse.xtext.resource.XtextResource toResource(Notifier)
Property Details
importManager
protected val importManager : org.eclipse.xtext.xbase.compiler.ImportManager
Replies the import manager that stores the imported types.

This property is an alias for the action: getImportManager

Returns:
the import manager.
importsConfiguration
protected val importsConfiguration : org.eclipse.xtext.xbase.imports.IImportsConfiguration
Replies the import's configuration.

This property is an alias for the action: getImportsConfiguration

Returns:
the import's configuration.
primitiveTypes
protected val primitiveTypes : org.eclipse.xtext.common.types.util.Primitives
Replies the primitive type tools.

This property is an alias for the action: getPrimitiveTypes

Returns:
the primitive type tools.
resourceFactory
protected val resourceFactory : org.eclipse.xtext.resource.IResourceFactory
Replies the resource factory.

This property is an alias for the action: getResourceFactory

Returns:
the resource factory.
scriptFileExtension
val scriptFileExtension : java.lang.String
Replies the script's file extension.

This property is an alias for the action: getScriptFileExtension

typeReferences
protected val typeReferences : org.eclipse.xtext.common.types.util.TypeReferences
Replies the builder of type references.

This property is an alias for the action: getTypeReferences

Returns:
the type reference builder.
typeResolutionContext
var typeResolutionContext : org.eclipse.xtext.common.types.access.IJvmTypeProvider

This property is an alias for the action: getTypeResolutionContext

Constructor Details
new
new
Action Details
computeUnusedUri(ResourceSet)
protected def computeUnusedUri(ResourceSet) : org.eclipse.emf.common.util.URI
Compute a unused URI for a synthetic resource.
Parameters:
resourceSet - the resource set in which the resource should be located.
Returns:
the uri.
dispose
def dispose
eResource
def eResource : org.eclipse.emf.ecore.resource.Resource
findType(Notifier,String)
protected def findType(Notifier,String) : org.eclipse.xtext.common.types.JvmTypeReference
getAssociatedElement(Class<T>,EObject,Resource)
protected def getAssociatedElement(Class<T>,EObject,Resource) : T

with T

getImportManager
protected def getImportManager : org.eclipse.xtext.xbase.compiler.ImportManager
Replies the import manager that stores the imported types.
Returns:
the import manager.
getImportsConfiguration
protected def getImportsConfiguration : org.eclipse.xtext.xbase.imports.IImportsConfiguration
Replies the import's configuration.
Returns:
the import's configuration.
getPrimitiveTypes
protected def getPrimitiveTypes : org.eclipse.xtext.common.types.util.Primitives
Replies the primitive type tools.
Returns:
the primitive type tools.
getQualifiedName(EObject)
protected def getQualifiedName(EObject) : java.lang.String
getResourceFactory
protected def getResourceFactory : org.eclipse.xtext.resource.IResourceFactory
Replies the resource factory.
Returns:
the resource factory.
getScriptFileExtension
def getScriptFileExtension : java.lang.String
Replies the script's file extension.
getTypeReferences
protected def getTypeReferences : org.eclipse.xtext.common.types.util.TypeReferences
Replies the builder of type references.
Returns:
the type reference builder.
getTypeResolutionContext
def getTypeResolutionContext : org.eclipse.xtext.common.types.access.IJvmTypeProvider
isActionBodyAllowed(XtendTypeDeclaration)
protected def isActionBodyAllowed(XtendTypeDeclaration) : boolean
Replies if the type could contains functions with a body.
isSubTypeOf(EObject,JvmTypeReference,JvmTypeReference)
protected def isSubTypeOf(EObject,JvmTypeReference,JvmTypeReference) : boolean
Replies if the first parameter is a subtype of the second parameter.
Parameters:
context - the context.
subType - the subtype to test.
superType - the expected super type.
Returns:
the type reference.
isTypeReference(JvmTypeReference)
protected def isTypeReference(JvmTypeReference) : boolean
Replies if the given object is a valid type reference.
newTypeRef(String)
def newTypeRef(String) : org.eclipse.xtext.common.types.JvmParameterizedTypeReference
Replies the type reference for the given name in the given context.
newTypeRef(Notifier,String)
def newTypeRef(Notifier,String) : org.eclipse.xtext.common.types.JvmParameterizedTypeReference
Replies the type reference for the given name in the given context.
setFileExtensions(String)
def setFileExtensions(String)
setTypeResolutionContext(IJvmTypeProvider)
protected def setTypeResolutionContext(IJvmTypeProvider)
toResource(Notifier)
protected def toResource(Notifier) : org.eclipse.xtext.resource.XtextResource