Class Resolver

    • Constructor Detail

      • Resolver

        protected Resolver​(Resolver parent)
        Creates a new Resolver.
        Parameters:
        parent - The parent of this resolver, which is never null
        Throws:
        java.lang.NullPointerException - If the parent is null
    • Method Detail

      • addChild

        public final void addChild​(java.lang.String variableName,
                                   Resolver resolver)
        Caches the given Resolver.
        Parameters:
        variableName - The key used to cache the given Resolver
        resolver - The Resolver to cache
      • checkParent

        protected void checkParent​(Resolver parent)
      • getChild

        public final Resolver getChild​(java.lang.String variableName)
        Retrieves the child of this Resolver that has the given variable name.
        Parameters:
        variableName - The name of the property that was cached
        Returns:
        The cached Resolver mapped with the given property name; otherwise null
      • getMapping

        public IMapping getMapping()
        Returns the IMapping for the wrapped field.
        Returns:
        Either the IMapping or null if none exists
      • getParentManagedType

        public final IManagedType getParentManagedType()
        Returns the managed type of the parent resolver.
        Returns:
        The managed type of the parent resolver
      • getParentMapping

        public final IMapping getParentMapping()
        Returns the IMapping of the parent resolver.
        Returns:
        The IMapping of the parent resolver
      • getParentType

        public final IType getParentType()
        Returns the type of the parent resolver.
        Returns:
        The type of the parent resolver
      • getParentTypeDeclaration

        public final ITypeDeclaration getParentTypeDeclaration()
        Returns the type declaration of the parent resolver.
        Returns:
        The type declaration of the parent resolver
      • getProvider

        public final IManagedTypeProvider getProvider()
        Returns the provider of managed types.
        Returns:
        The container holding the managed types
      • getQuery

        public IQuery getQuery()
        Returns the external form representing the JPQL query.
        Returns:
        The external form of the JPQL query
      • getType

        public final IType getType​(java.lang.Class<?> type)
        Returns the IType of the given Java type.
        Parameters:
        type - The Java type for which its external form will be returned
        Returns:
        The IType representing the given Java type
      • getType

        public final IType getType​(java.lang.String typeName)
        Retrieves the external class for the given fully qualified class name.
        Parameters:
        typeName - The fully qualified class name of the class to retrieve
        Returns:
        The external form of the class to retrieve
      • getTypeHelper

        public final TypeHelper getTypeHelper()
        Returns a helper that gives access to the most common types.
        Returns:
        A helper containing a collection of methods related to IType
      • getTypeRepository

        public final ITypeRepository getTypeRepository()
        Returns the type repository for the application.
        Returns:
        The repository of ITypes
      • isNullAllowed

        public boolean isNullAllowed()
        Determines whether the Expression to be created, which wraps the attribute or query key name allows the target of the 1:1 relationship to be null if there is no corresponding relationship in the database.
        Returns:
        true to allow null if the corresponding relationship in the database does not exists; false otherwise
      • setNullAllowed

        public void setNullAllowed​(boolean nullAllowed)
        Sets whether the Expression to be created, which wraps the attribute or query key name allows the target of the 1:1 relationship to be null if there is no corresponding relationship in the database.
        Parameters:
        nullAllowed - true to allow null if the corresponding relationship in the database does not exists; false otherwise