C# Class clojure.lang.APersistentSet

Inheritance: AFn, IPersistentSet, ICollection
显示文件 Open project: arohner/clojure-contrib

Protected Properties

Property Type Description
_hash int
_impl IPersistentMap

Public Methods

Method Description
CopyTo ( Array array, int index ) : void
Equals ( object obj ) : bool

Determines whether the specified Object is equal to the current Object.

GetEnumerator ( ) : IEnumerator
GetHashCode ( ) : int

Computes a hash code for the current object.

The hash code is value-based (based on the items in the set). Once computed, the value is cached.

ToString ( ) : string

Returns a string representing the current object.

cons ( object o ) : IPersistentCollection
contains ( object key ) : bool

Test if the set contains the key.

count ( ) : int

Gets the number of items in the collection.

disjoin ( object key ) : IPersistentSet

Get a set with the given item removed.

empty ( ) : IPersistentCollection
equiv ( object o ) : bool

Determine if an object is equivalent to this (handles all collections).

get ( object key ) : object

Get the value for the key (= the key itself, or null if not present).

invoke ( object arg1 ) : object
seq ( ) : ISeq

Gets an ISeq to allow first/rest iteration through the collection.

Protected Methods

Method Description
APersistentSet ( IPersistentMap meta, IPersistentMap impl ) : System

Initialize an APersistentSet from the metadata map and the data map.

Method Details

APersistentSet() protected method

Initialize an APersistentSet from the metadata map and the data map.
protected APersistentSet ( IPersistentMap meta, IPersistentMap impl ) : System
meta IPersistentMap The metadata
impl IPersistentMap The underlying implementation map
return System

CopyTo() public method

public CopyTo ( Array array, int index ) : void
array System.Array
index int
return void

Equals() public method

Determines whether the specified Object is equal to the current Object.
public Equals ( object obj ) : bool
obj object The Object to compare with the current Object.
return bool

GetEnumerator() public method

public GetEnumerator ( ) : IEnumerator
return IEnumerator

GetHashCode() public method

Computes a hash code for the current object.
The hash code is value-based (based on the items in the set). Once computed, the value is cached.
public GetHashCode ( ) : int
return int

ToString() public method

Returns a string representing the current object.
public ToString ( ) : string
return string

cons() public abstract method

public abstract cons ( object o ) : IPersistentCollection
o object
return IPersistentCollection

contains() public method

Test if the set contains the key.
public contains ( object key ) : bool
key object The value to test for membership in the set.
return bool

count() public method

Gets the number of items in the collection.
public count ( ) : int
return int

disjoin() public abstract method

Get a set with the given item removed.
public abstract disjoin ( object key ) : IPersistentSet
key object The item to remove.
return IPersistentSet

empty() public abstract method

public abstract empty ( ) : IPersistentCollection
return IPersistentCollection

equiv() public method

Determine if an object is equivalent to this (handles all collections).
public equiv ( object o ) : bool
o object The object to compare.
return bool

get() public method

Get the value for the key (= the key itself, or null if not present).
public get ( object key ) : object
key object The value to test for membership in the set.
return object

invoke() public method

public invoke ( object arg1 ) : object
arg1 object
return object

seq() public method

Gets an ISeq to allow first/rest iteration through the collection.
public seq ( ) : ISeq
return ISeq

Property Details

_hash protected_oe property

Caches the hash code, when computed.
protected int _hash
return int

_impl protected_oe property

The underlying map that contains the set's elements.
protected IPersistentMap _impl
return IPersistentMap