Class OptionalType

    • Constructor Detail

      • OptionalType

        public OptionalType​(java.lang.reflect.Type baseJavaType)
        for TypeFactory.spawnFromPrototype()
      • OptionalType

        public OptionalType()
    • Method Detail

      • map

        public java.lang.Object map​(java.lang.Object sourceOptional_,
                                    java.util.function.Function mapFunction)
        Description copied from class: EnumerableType
        Returns a new Enumerable (unmodifiable when possible) with items from sourceEnumerable mapped by mapFunction.
        Overrides:
        map in class EnumerableType
      • items

        protected java.util.stream.Stream<java.lang.Object> items​(java.lang.Object source)
        Overrides:
        items in class CollectionType
      • isEmpty

        public boolean isEmpty​(java.lang.Object optional)
        Overrides:
        isEmpty in class CollectionType
      • isInstance

        public boolean isInstance​(java.lang.Object cdo)
        Specified by:
        isInstance in class JaversType
      • getRawDehydratedType

        protected java.lang.reflect.Type getRawDehydratedType()
        Type for JSON representation. For Values it's simply baseJavaType. For ManagedTypes (references to Entities and ValueObjects) it's GlobalId because JaVers serializes references in the 'dehydrated' form.
      • getBaseJavaClass

        public java.lang.Class getBaseJavaClass()