C# 클래스 Microsoft.Scripting.MutableTuple

파일 보기 프로젝트 열기: jschementi/iron 1 사용 예제들

공개 프로퍼티들

프로퍼티 타입 설명
MaxSize int

공개 메소드들

메소드 설명
Create ( ) : Expression

Provides an expression for creating a tuple with the specified values.

GetAccessPath ( Type tupleType, int index ) : IEnumerable

Gets the series of properties that needs to be accessed to access a logical item in a potentially nested tuple.

GetNestedValue ( int size, int index ) : object

Gets the value at the given index for a tuple of the given size. This get supports walking through nested tuples to get the correct final index.

GetSize ( Type tupleType ) : int

Gets the number of usable slots in the provided Tuple type including slots available in nested tuples.

GetTupleType ( int size ) : Type

Gets the unbound generic Tuple type which has at lease size slots or null if a large enough tuple is not available.

GetTupleValues ( MutableTuple tuple ) : object[]

Gets the values from a tuple including unpacking nested values.

GetValue ( int index ) : object
MakeTuple ( Type tupleType ) : MutableTuple

Creates a new instance of tupleType with the specified args. If the tuple is a nested tuple the values are added in their nested forms.

MakeTupleType ( ) : Type

Creates a generic tuple with the specified types. If the number of slots fits within the maximum tuple size then we simply create a single tuple. If it's greater then we create nested tuples (e.g. a Tuple`2 which contains a Tuple`128 and a Tuple`8 if we had a size of 136).

SetNestedValue ( int size, int index, object value ) : void

Sets the value at the given index for a tuple of the given size. This set supports walking through nested tuples to get the correct final index.

SetValue ( int index, object value ) : void

비공개 메소드들

메소드 설명
CreateNew ( Type tupleType, int start, int end, Expression values ) : Expression
CreateTupleInstance ( Type tupleType, int start, int end, object args ) : MutableTuple
GetAccessPath ( int size, int index ) : IEnumerable
GetAccessProperties ( Type tupleType, int size, int index ) : IEnumerable

Gets the series of properties that needs to be accessed to access a logical item in a potentially nested tuple.

GetTupleValues ( MutableTuple tuple, List args ) : void
MakeTuple ( Type tupleType, int start, int end, object args ) : MutableTuple
MakeTupleType ( Type types, int start, int end ) : Type
PowerOfTwoRound ( int value ) : int

메소드 상세

Create() 공개 정적인 메소드

Provides an expression for creating a tuple with the specified values.
public static Create ( ) : Expression
리턴 Expression

GetAccessPath() 공개 정적인 메소드

Gets the series of properties that needs to be accessed to access a logical item in a potentially nested tuple.
public static GetAccessPath ( Type tupleType, int index ) : IEnumerable
tupleType System.Type
index int
리턴 IEnumerable

GetNestedValue() 공개 메소드

Gets the value at the given index for a tuple of the given size. This get supports walking through nested tuples to get the correct final index.
public GetNestedValue ( int size, int index ) : object
size int
index int
리턴 object

GetSize() 공개 정적인 메소드

Gets the number of usable slots in the provided Tuple type including slots available in nested tuples.
public static GetSize ( Type tupleType ) : int
tupleType System.Type
리턴 int

GetTupleType() 공개 정적인 메소드

Gets the unbound generic Tuple type which has at lease size slots or null if a large enough tuple is not available.
public static GetTupleType ( int size ) : Type
size int
리턴 System.Type

GetTupleValues() 공개 정적인 메소드

Gets the values from a tuple including unpacking nested values.
public static GetTupleValues ( MutableTuple tuple ) : object[]
tuple MutableTuple
리턴 object[]

GetValue() 공개 추상적인 메소드

public abstract GetValue ( int index ) : object
index int
리턴 object

MakeTuple() 공개 정적인 메소드

Creates a new instance of tupleType with the specified args. If the tuple is a nested tuple the values are added in their nested forms.
public static MakeTuple ( Type tupleType ) : MutableTuple
tupleType System.Type
리턴 MutableTuple

MakeTupleType() 공개 정적인 메소드

Creates a generic tuple with the specified types. If the number of slots fits within the maximum tuple size then we simply create a single tuple. If it's greater then we create nested tuples (e.g. a Tuple`2 which contains a Tuple`128 and a Tuple`8 if we had a size of 136).
public static MakeTupleType ( ) : Type
리턴 System.Type

SetNestedValue() 공개 메소드

Sets the value at the given index for a tuple of the given size. This set supports walking through nested tuples to get the correct final index.
public SetNestedValue ( int size, int index, object value ) : void
size int
index int
value object
리턴 void

SetValue() 공개 추상적인 메소드

public abstract SetValue ( int index, object value ) : void
index int
value object
리턴 void

프로퍼티 상세

MaxSize 공개적으로 정적으로 프로퍼티

public static int MaxSize
리턴 int