C# 클래스 clojure.lang.Range

Represents a (contiguous) range of integers.
상속: clojure.lang.ASeq, IReduce, Streamable, Counted
파일 보기 프로젝트 열기: richhickey/clojure-clr 1 사용 예제들

공개 메소드들

메소드 설명
Range ( IPersistentMap meta, int start, int end ) : System

Initialize a range and attach metadata.

Range ( int start, int end ) : System

Initialize a range.

Range ( object start, object end ) : System

Initialize a range.

Needed to interface with core.clj

count ( ) : int

Gets the number of items in the collection.

first ( ) : object

Gets the first item.

next ( ) : ISeq

Return a seq of the items after the first. Calls seq on its argument. If there are no more items, returns nil."

reduce ( IFn f ) : object

Reduce the collection using a function.

Computes f(...f(f(f(i0,i1),i2),i3),...).

reduce ( IFn f, object start ) : object

Reduce the collection using a function.

Computes f(...f(f(f(start,i0),i1),i2),...).

withMeta ( IPersistentMap meta ) : IObj

Create a copy with new metadata.

메소드 상세

Range() 공개 메소드

Initialize a range and attach metadata.
public Range ( IPersistentMap meta, int start, int end ) : System
meta IPersistentMap The metadata to attach.
start int Start value
end int End value
리턴 System

Range() 공개 메소드

Initialize a range.
public Range ( int start, int end ) : System
start int Start value
end int End value
리턴 System

Range() 공개 메소드

Initialize a range.
Needed to interface with core.clj
public Range ( object start, object end ) : System
start object Start value
end object End value
리턴 System

count() 공개 메소드

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

first() 공개 메소드

Gets the first item.
public first ( ) : object
리턴 object

next() 공개 메소드

Return a seq of the items after the first. Calls seq on its argument. If there are no more items, returns nil."
public next ( ) : ISeq
리턴 ISeq

reduce() 공개 메소드

Reduce the collection using a function.
Computes f(...f(f(f(i0,i1),i2),i3),...).
public reduce ( IFn f ) : object
f IFn The function to apply.
리턴 object

reduce() 공개 메소드

Reduce the collection using a function.
Computes f(...f(f(f(start,i0),i1),i2),...).
public reduce ( IFn f, object start ) : object
f IFn The function to apply.
start object An initial value to get started.
리턴 object

withMeta() 공개 메소드

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