C# Class clojure.lang.Cons

Implements an immutable cons cell.
Inheritance: clojure.lang.ASeq
Mostra file Open project: arohner/clojure-contrib Class Usage Examples

Public Methods

Method Description
Cons ( IPersistentMap meta, object first, ISeq rest ) : System

Initializes a Cons with the given metadata and first/rest.

Cons ( object first, ISeq rest ) : System

Initializes a Cons with null metadata and given first/rest.

first ( ) : Object

Gets the first item.

rest ( ) : ISeq

Gets the rest of the sequence.

seq ( ) : ISeq

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

withMeta ( IPersistentMap meta ) : IObj

Create a copy with new metadata.

Method Details

Cons() public method

Initializes a Cons with the given metadata and first/rest.
public Cons ( IPersistentMap meta, object first, ISeq rest ) : System
meta IPersistentMap The metadata to attach.
first object The first value.
rest ISeq The rest of the sequence.
return System

Cons() public method

Initializes a Cons with null metadata and given first/rest.
public Cons ( object first, ISeq rest ) : System
first object The first value.
rest ISeq The rest of the sequence.
return System

first() public method

Gets the first item.
public first ( ) : Object
return Object

rest() public method

Gets the rest of the sequence.
public rest ( ) : ISeq
return ISeq

seq() public method

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

withMeta() public method

Create a copy with new metadata.
public withMeta ( IPersistentMap meta ) : IObj
meta IPersistentMap The new metadata.
return IObj