Class UnionShape

    • 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.
      • getAllMembers

        public java.util.Map<java.lang.String,​MemberShape> getAllMembers()
        Gets the members of the shape.
        Returns:
        Returns the immutable member map.
      • getMemberNames

        public java.util.List<java.lang.String> getMemberNames()
        Returns an ordered list of member names based on the order they are defined in the model.
        Returns:
        Returns an immutable list of member names.
      • getMember

        public java.util.Optional<MemberShape> getMember​(java.lang.String name)
        Get a specific member by name.
        Parameters:
        name - Name of the member to retrieve.
        Returns:
        Returns the optional member.
      • 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