Package org.faktorips.fl
Class JavaExprCompiler
java.lang.Object
org.faktorips.fl.ExprCompiler<org.faktorips.codegen.JavaCodeFragment>
org.faktorips.fl.JavaExprCompiler
-
Field Summary
Fields inherited from class org.faktorips.fl.ExprCompiler
AMBIGUOUS_FUNCTION_CALL, DATATYPE_CREATION_ERROR, INTERNAL_ERROR, LEXICAL_ERROR, NO_ASSOCIATION_TARGET, NO_INDEX_FOR_1TO1_ASSOCIATION, NULL_NOT_ALLOWED, PREFIX, SYNTAX_ERROR, UNDEFINED_FUNCTION, UNDEFINED_IDENTIFIER, UNDEFINED_OPERATOR, UNKNOWN_QUALIFIER, WRONG_ARGUMENT_TYPES, WRONG_MONEY_LITERAL -
Constructor Summary
ConstructorsConstructorDescriptionCreates a new compiler.JavaExprCompiler(Locale locale) Creates a new compiler. -
Method Summary
Modifier and TypeMethodDescriptionprotected org.faktorips.codegen.JavaCodeFragmentconvertPrimitiveToWrapper(org.faktorips.datatype.Datatype resultType, org.faktorips.codegen.JavaCodeFragment codeFragment) org.faktorips.codegen.DatatypeHelpergetDatatypeHelper(org.faktorips.datatype.Datatype type) Returns thecode generation helperfor the given type ornullif no helper is available.protected AbstractCompilationResult<org.faktorips.codegen.JavaCodeFragment>newCompilationResultImpl(org.faktorips.codegen.JavaCodeFragment sourcecode, org.faktorips.datatype.Datatype datatype) protected AbstractCompilationResult<org.faktorips.codegen.JavaCodeFragment>newCompilationResultImpl(org.faktorips.runtime.Message message) protected ParseTreeVisitor<org.faktorips.codegen.JavaCodeFragment>protected voidRegisters the default operations.Methods inherited from class org.faktorips.fl.ExprCompiler
add, compile, getAmbiguousFunctions, getBinaryOperation, getConversionCodeGenerator, getDatatypeHelperProvider, getEnsureResultIsObject, getFunctions, getIdentifierResolver, getLocale, getLocalizedStrings, getMatchingFunctionUsingConversion, getMatchingFunctionUsingConversionSingleArgument, isValidIdentifier, parse, parseExceptionToResult, register, register, remove, setBinaryOperations, setConversionCodeGenerator, setDatatypeHelperProvider, setEnsureResultIsObject, setIdentifierResolver, setLocale, setUnaryOperations
-
Constructor Details
-
JavaExprCompiler
public JavaExprCompiler()Creates a new compiler. Messages returned by the compiler are generated using the default locale. -
JavaExprCompiler
Creates a new compiler.- Parameters:
locale- The locale that is used to generate locale dependent messages.
-
-
Method Details
-
registerDefaults
protected void registerDefaults()Description copied from class:ExprCompilerRegisters the default operations.- Specified by:
registerDefaultsin classExprCompiler<org.faktorips.codegen.JavaCodeFragment>
-
convertPrimitiveToWrapper
protected org.faktorips.codegen.JavaCodeFragment convertPrimitiveToWrapper(org.faktorips.datatype.Datatype resultType, org.faktorips.codegen.JavaCodeFragment codeFragment) - Specified by:
convertPrimitiveToWrapperin classExprCompiler<org.faktorips.codegen.JavaCodeFragment>
-
newParseTreeVisitor
- Specified by:
newParseTreeVisitorin classExprCompiler<org.faktorips.codegen.JavaCodeFragment>
-
newCompilationResultImpl
protected AbstractCompilationResult<org.faktorips.codegen.JavaCodeFragment> newCompilationResultImpl(org.faktorips.runtime.Message message) - Specified by:
newCompilationResultImplin classExprCompiler<org.faktorips.codegen.JavaCodeFragment>
-
newCompilationResultImpl
protected AbstractCompilationResult<org.faktorips.codegen.JavaCodeFragment> newCompilationResultImpl(org.faktorips.codegen.JavaCodeFragment sourcecode, org.faktorips.datatype.Datatype datatype) - Specified by:
newCompilationResultImplin classExprCompiler<org.faktorips.codegen.JavaCodeFragment>
-
getDatatypeHelper
public org.faktorips.codegen.DatatypeHelper getDatatypeHelper(org.faktorips.datatype.Datatype type) Description copied from class:ExprCompilerReturns thecode generation helperfor the given type ornullif no helper is available.- Overrides:
getDatatypeHelperin classExprCompiler<org.faktorips.codegen.JavaCodeFragment>
-