Automata Docs Automata Docs
Automata Docs Automata Docs

Search Results for

    Edit this page

    Class IntSet

    Immutable set of integers.

    Inheritance
    object
    IntSet
    Implements
    IEquatable<IntSet>
    IReadOnlySet<int>
    IReadOnlyCollection<int>
    IEnumerable<int>
    IEnumerable
    Inherited Members
    object.Equals(object, object)
    object.GetType()
    object.MemberwiseClone()
    object.ReferenceEquals(object, object)
    Namespace: Automata.Core
    Assembly: Automata.Core.dll
    Syntax
    public class IntSet : IEquatable<IntSet>, IReadOnlySet<int>, IReadOnlyCollection<int>, IEnumerable<int>, IEnumerable

    Constructors

    | Edit this page View Source

    IntSet(IEnumerable<int>)

    Initializes a new instance of the IntSet class with the specified elements.

    Declaration
    public IntSet(IEnumerable<int> elements)
    Parameters
    Type Name Description
    IEnumerable<int> elements

    Elements to include in the set.

    Properties

    | Edit this page View Source

    Count

    Number of elements in the set.

    Declaration
    public int Count { get; }
    Property Value
    Type Description
    int

    Methods

    | Edit this page View Source

    Contains(int)

    Indicates whether the current set contains the specified item.

    Declaration
    public bool Contains(int item)
    Parameters
    Type Name Description
    int item

    Item to locate in the set.

    Returns
    Type Description
    bool

    true iff the set contains the specified item.

    | Edit this page View Source

    Equals(IntSet?)

    Indicates whether the current set is equal to another set.

    Declaration
    public bool Equals(IntSet? other)
    Parameters
    Type Name Description
    IntSet other

    Other set to compare to.

    Returns
    Type Description
    bool

    true iff the sets are equal.

    | Edit this page View Source

    Equals(object?)

    Indicates whether the current set is equal to another object.

    Declaration
    public override bool Equals(object? obj)
    Parameters
    Type Name Description
    object obj

    Object to compare to.

    Returns
    Type Description
    bool

    true iff the object is an IntSet and the sets are equal.

    Overrides
    object.Equals(object)
    | Edit this page View Source

    GetEnumerator()

    Returns an enumerator that iterates through the set.

    Declaration
    public IEnumerator<int> GetEnumerator()
    Returns
    Type Description
    IEnumerator<int>

    An enumerator for the set.

    | Edit this page View Source

    GetHashCode()

    Hash code for the current set.

    Declaration
    public override int GetHashCode()
    Returns
    Type Description
    int

    The hash code for the current set.

    Overrides
    object.GetHashCode()
    | Edit this page View Source

    IsProperSubsetOf(IEnumerable<int>)

    Indicates whether the current set is a proper subset of the specified collection.

    Declaration
    public bool IsProperSubsetOf(IEnumerable<int> other)
    Parameters
    Type Name Description
    IEnumerable<int> other

    Collection to compare to.

    Returns
    Type Description
    bool

    true iff the current set is a proper subset of the specified collection.

    | Edit this page View Source

    IsProperSupersetOf(IEnumerable<int>)

    Indicates whether the current set is a proper superset of the specified collection.

    Declaration
    public bool IsProperSupersetOf(IEnumerable<int> other)
    Parameters
    Type Name Description
    IEnumerable<int> other

    Collection to compare to.

    Returns
    Type Description
    bool

    true iff the current set is a proper superset of the specified collection.

    | Edit this page View Source

    IsSubsetOf(IEnumerable<int>)

    Indicates whether the current set is a subset of the specified collection.

    Declaration
    public bool IsSubsetOf(IEnumerable<int> other)
    Parameters
    Type Name Description
    IEnumerable<int> other

    Collection to compare to.

    Returns
    Type Description
    bool

    true iff the current set is a subset of the specified collection.

    | Edit this page View Source

    IsSupersetOf(IEnumerable<int>)

    Indicates whether the current set is a superset of the specified collection.

    Declaration
    public bool IsSupersetOf(IEnumerable<int> other)
    Parameters
    Type Name Description
    IEnumerable<int> other

    Collection to compare to.

    Returns
    Type Description
    bool

    true iff the current set is a superset of the specified collection.

    | Edit this page View Source

    Overlaps(IEnumerable<int>)

    Indicates whether the current set overlaps with the specified collection.

    Declaration
    public bool Overlaps(IEnumerable<int> other)
    Parameters
    Type Name Description
    IEnumerable<int> other

    Collection to compare to.

    Returns
    Type Description
    bool

    true iff the current set overlaps with the specified collection.

    | Edit this page View Source

    SetEquals(IEnumerable<int>)

    Indicates whether the current set is equal to the specified collection.

    Declaration
    public bool SetEquals(IEnumerable<int> other)
    Parameters
    Type Name Description
    IEnumerable<int> other

    Collection to compare to.

    Returns
    Type Description
    bool

    true iff the current set is equal to the specified collection.

    | Edit this page View Source

    ToString()

    String that represents the current set.

    Declaration
    public override string ToString()
    Returns
    Type Description
    string

    A string that represents the current set.

    Overrides
    object.ToString()

    Operators

    | Edit this page View Source

    operator ==(IntSet, IntSet)

    Equality operator.

    Declaration
    public static bool operator ==(IntSet left, IntSet right)
    Parameters
    Type Name Description
    IntSet left

    Left operand.

    IntSet right

    Right operand.

    Returns
    Type Description
    bool

    true iff the operands are equal.

    | Edit this page View Source

    operator !=(IntSet, IntSet)

    Inequality operator.

    Declaration
    public static bool operator !=(IntSet left, IntSet right)
    Parameters
    Type Name Description
    IntSet left

    Left operand.

    IntSet right

    Right operand.

    Returns
    Type Description
    bool

    true iff the operands are not equal.

    Implements

    IEquatable<T>
    IReadOnlySet<T>
    IReadOnlyCollection<T>
    IEnumerable<T>
    IEnumerable