com.holonplatform.core.internal

## Class DefaultNullExpression<T>

- java.lang.Object
- - com.holonplatform.core.internal.AbstractConverterExpression<T>
  - - com.holonplatform.core.internal.DefaultNullExpression<T>

- Type Parameters:
    `T` - Expression type
  All Implemented Interfaces:
    ConverterExpression<T>, Expression, NullExpression<T>, TypedExpression<T>

      public class DefaultNullExpression<T>
      extends AbstractConverterExpression<T>
      implements NullExpression<T>

  Default `NullExpression` implementation.
  Since:
    5.1.0

- - ### Nested Class Summary

    - ### Nested classes/interfaces inherited from interface com.holonplatform.core.Expression

      `Expression.ExpressionResolverFunction<E extends Expression,R extends Expression>, Expression.InvalidExpressionException`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `DefaultNullExpression(Class<? extends T> type)` Default constructor.
    `DefaultNullExpression(TypedExpression<T> expression)` Constructor with associated expression.

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `Object` | `getModelValue()` Get the model data type value, using the `ExpressionValueConverter` to convert constant expression value, if available.
    `Class<? extends T>` | `getType()` Get the expression type.
    `String` | `toString()`
    `void` | `validate()` Validate this expression.

    - ### Methods inherited from class com.holonplatform.core.internal.AbstractConverterExpression

      `getExpressionValueConverter, getTemporalType, setTemporalType`

    - ### Methods inherited from class java.lang.Object

      `equals, getClass, hashCode, notify, notifyAll, wait, wait, wait`

    - ### Methods inherited from interface com.holonplatform.core.NullExpression

      `create, create`

    - ### Methods inherited from interface com.holonplatform.core.ConverterExpression

      `getExpressionValueConverter, getModelType, getModelValue`

    - ### Methods inherited from interface com.holonplatform.core.TypedExpression

      `getTemporalType, isCollectionExpression, isConverterExpression`

- - ### Constructor Detail

    - #### DefaultNullExpression

          public DefaultNullExpression(Class<? extends T> type)

      Default constructor.
      Parameters:
        `type` - Expression type (not null)

    - #### DefaultNullExpression

          public DefaultNullExpression(TypedExpression<T> expression)

      Constructor with associated expression.
      Parameters:
        `expression` - Optional expression from which to inherit an `ExpressionValueConverter`, if available.

  - ### Method Detail

    - #### getType

          public Class<? extends T> getType()

      Description copied from interface: `TypedExpression`
      Get the expression type.
      Specified by:
        `getType` in interface `TypedExpression<T>`
      Returns:
        Expression type

    - #### getModelValue

          public Object getModelValue()

      Description copied from interface: `NullExpression`
      Get the model data type value, using the `ExpressionValueConverter` to convert constant expression value, if available. If an `ExpressionValueConverter` is not available, `null` is returned.
      Specified by:
        `getModelValue` in interface `NullExpression<T>`
      Returns:
        The model-converted expression value if an `ExpressionValueConverter` is available, or `null` otherwise

    - #### validate

          public void validate()
                        throws Expression.InvalidExpressionException

      Description copied from interface: `Expression`
      Validate this expression.
      Specified by:
        `validate` in interface `Expression`
      Throws:
        `Expression.InvalidExpressionException` - If the expression is not valid

    - #### toString

          public String toString()

      Overrides:
        `toString` in class `Object`

Copyright © 2019 The Holon Platform. All rights reserved.