Class AbstractClassJavaTypeDescriptor<T>

    • Constructor Detail

      • AbstractClassJavaTypeDescriptor

        protected AbstractClassJavaTypeDescriptor​(Class<? extends T> type,
                                                  MutabilityPlan<? extends T> mutabilityPlan)
        Initialize a type descriptor for the given type and mutability plan.
        Parameters:
        type - The Java type.
        mutabilityPlan - The plan for handling mutability aspects of the java type.
      • AbstractClassJavaTypeDescriptor

        protected AbstractClassJavaTypeDescriptor​(Class<? extends T> type,
                                                  MutabilityPlan<? extends T> mutabilityPlan,
                                                  Comparator<? extends T> comparator)
        Initialize a type descriptor for the given type, mutability plan and comparator.
        Parameters:
        type - The Java type.
        mutabilityPlan - The plan for handling mutability aspects of the java type.
        comparator - The comparator for handling comparison of values
    • Method Detail

      • extractHashCode

        public int extractHashCode​(T value)
        Description copied from interface: JavaType
        Extract a proper hash code for this value.
        Specified by:
        extractHashCode in interface JavaType<T>
        Parameters:
        value - The value for which to extract a hash code.
        Returns:
        The extracted hash code.
      • areEqual

        public boolean areEqual​(T one,
                                T another)
        Description copied from interface: JavaType
        Determine if two instances are equal
        Specified by:
        areEqual in interface JavaType<T>
        Parameters:
        one - One instance
        another - The other instance
        Returns:
        True if the two are considered equal; false otherwise.
      • extractLoggableRepresentation

        public String extractLoggableRepresentation​(T value)
        Description copied from interface: JavaType
        Extract a loggable representation of the value.
        Specified by:
        extractLoggableRepresentation in interface JavaType<T>
        Parameters:
        value - The value for which to extract a loggable representation.
        Returns:
        The loggable representation