Class StructLikeWrapper


  • public class StructLikeWrapper
    extends java.lang.Object
    Wrapper to adapt StructLike for use in maps and sets by implementing equals and hashCode.
    • Method Detail

      • copyFor

        public StructLikeWrapper copyFor​(StructLike newStruct)
        Creates a copy of this wrapper that wraps a struct.

        This is equivalent to new StructLikeWrapper(type).set(newStruct) but is cheaper because no analysis of the type is necessary.

        Parameters:
        newStruct - a StructLike row
        Returns:
        a copy of this wrapper wrapping the give struct
      • equals

        public boolean equals​(java.lang.Object other)
        Overrides:
        equals in class java.lang.Object
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object