Class MapShape

    • Method Detail

      • accept

        public <R> R accept​(ShapeVisitor<R> cases)
        Description copied from class: Shape
        Dispatches the shape to the appropriate ShapeVisitor method.
        Specified by:
        accept in class Shape
        Type Parameters:
        R - Return type of the accept.
        Parameters:
        cases - NeighborVisitor to use.
        Returns:
        Returns the result.
      • asMapShape

        public java.util.Optional<MapShape> asMapShape()
        Overrides:
        asMapShape in class Shape
        Returns:
        Optionally returns the shape as a MapShape.
      • getValue

        public MemberShape getValue()
        Get the value member shape of the map.
        Returns:
        Returns the value member shape.
      • getKey

        public MemberShape getKey()
        Get the key member shape of the map.
        Returns:
        Returns the key member shape.
      • members

        public java.util.Collection<MemberShape> members()
        Description copied from class: Shape
        Gets all of the members contained in the shape.
        Overrides:
        members in class Shape
        Returns:
        Returns the members contained in the shape (if any).
      • equals

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