C# Class Mono.CSharp.TypeManager

Show file Open project: kumpera/mono Class Usage Examples

Public Properties

Property Type Description
activator_create_instance MethodSpec
arg_iterator_type System.TypeSpec
array_type BuildinTypeSpec
attribute_type BuildinTypeSpec
bool_movenext_void MethodSpec
bool_type BuildinTypeSpec
byte_type BuildinTypeSpec
char_type BuildinTypeSpec
decimal_type BuildinTypeSpec
delegate_combine_delegate_delegate MethodSpec
delegate_remove_delegate_delegate MethodSpec
delegate_type BuildinTypeSpec
double_type BuildinTypeSpec
enum_type BuildinTypeSpec
exception_type BuildinTypeSpec
fieldinfo_get_field_from_handle MethodSpec
fieldinfo_get_field_from_handle_generic MethodSpec
float_type BuildinTypeSpec
gen_interlocked_compare_exchange MethodSpec
generic_icollection_type System.TypeSpec
generic_ienumerable_type System.TypeSpec
generic_ienumerator_type System.TypeSpec
generic_ilist_type System.TypeSpec
generic_nullable_type System.TypeSpec
idisposable_type BuildinTypeSpec
ienumerable_type BuildinTypeSpec
ienumerator_getcurrent PropertySpec
ienumerator_type BuildinTypeSpec
int32_type BuildinTypeSpec
int64_type BuildinTypeSpec
int_get_offset_to_string_data PropertySpec
int_interlocked_compare_exchange MethodSpec
intptr_type BuildinTypeSpec
mbr_type System.TypeSpec
methodbase_get_type_from_handle MethodSpec
methodbase_get_type_from_handle_generic MethodSpec
multicast_delegate_type BuildinTypeSpec
object_type BuildinTypeSpec
runtime_field_handle_type BuildinTypeSpec
runtime_handle_type BuildinTypeSpec
sbyte_type BuildinTypeSpec
short_type BuildinTypeSpec
string_empty FieldSpec
string_type BuildinTypeSpec
system_type_get_type_from_handle MethodSpec
type_type BuildinTypeSpec
typed_reference_type System.TypeSpec
uint32_type BuildinTypeSpec
uint64_type BuildinTypeSpec
uintptr_type BuildinTypeSpec
ushort_type BuildinTypeSpec
value_type BuildinTypeSpec
void_decimal_ctor_five_args MethodSpec
void_decimal_ctor_int_arg MethodSpec
void_decimal_ctor_long_arg MethodSpec
void_dispose_void MethodSpec
void_initializearray_array_fieldhandle MethodSpec
void_monitor_enter_object MethodSpec
void_monitor_exit_object MethodSpec
void_type BuildinTypeSpec

Public Methods

Method Description
CSharpName ( IList types ) : string
CSharpName ( System.TypeSpec t ) : string

Returns the C# name of a type if possible, or the full type name otherwise

CSharpSignature ( MemberSpec mb ) : string
ChangeType ( object value, System.TypeSpec targetType, bool &error ) : object
GetElementType ( System.TypeSpec t ) : System.TypeSpec
GetFullNameSignature ( MemberSpec mi ) : string
GetPredefinedConstructor ( System.TypeSpec t, Mono.CSharp.Location loc ) : MethodSpec
GetPredefinedField ( System.TypeSpec t, string name, Mono.CSharp.Location loc, System.TypeSpec type ) : FieldSpec
GetPredefinedMethod ( System.TypeSpec t, MemberFilter filter, Mono.CSharp.Location loc ) : MethodSpec
GetPredefinedMethod ( System.TypeSpec t, MemberFilter filter, bool optional, Mono.CSharp.Location loc ) : MethodSpec
GetPredefinedMethod ( System.TypeSpec t, string name, Mono.CSharp.Location loc ) : MethodSpec
GetPredefinedProperty ( System.TypeSpec t, string name, Mono.CSharp.Location loc, System.TypeSpec type ) : PropertySpec
GetTypeArguments ( System.TypeSpec t ) : System.TypeSpec[]
HasElementType ( System.TypeSpec t ) : bool

This method is not implemented by MS runtime for dynamic types

IsBuiltinOrEnum ( System.TypeSpec t ) : bool
IsBuiltinType ( System.TypeSpec t ) : bool
IsDelegateType ( System.TypeSpec t ) : bool
IsEnumType ( System.TypeSpec t ) : bool
IsFamilyAccessible ( System.TypeSpec type, System.TypeSpec parent ) : bool
IsGenericParameter ( System.TypeSpec type ) : bool
IsGenericType ( System.TypeSpec type ) : bool
IsInstantiationOfSameGenericType ( System.TypeSpec type, System.TypeSpec parent ) : bool

Check whether `type' and `parent' are both instantiations of the same generic type. Note that we do not check the type parameters here.

IsNestedChildOf ( System.TypeSpec type, ITypeDefinition parent ) : bool
IsNestedFamilyAccessible ( System.TypeSpec type, System.TypeSpec base_type ) : bool
IsNullableType ( System.TypeSpec t ) : bool
IsPrimitiveType ( System.TypeSpec t ) : bool
IsReferenceType ( System.TypeSpec t ) : bool
IsSpecialType ( System.TypeSpec t ) : bool
IsStruct ( System.TypeSpec t ) : bool
IsUnmanagedType ( System.TypeSpec t ) : bool
IsValueType ( System.TypeSpec t ) : bool
Reset ( ) : void
VerifyUnmanaged ( CompilerContext ctx, System.TypeSpec t, Mono.CSharp.Location loc ) : bool

Utility function that can be used to probe whether a type is managed or not.

Private Methods

Method Description
GetPredefinedMember ( System.TypeSpec t, MemberFilter filter, bool optional, Mono.CSharp.Location loc ) : MemberSpec
TypeManager ( ) : System

Method Details

CSharpName() static public method

static public CSharpName ( IList types ) : string
types IList
return string

CSharpName() static public method

Returns the C# name of a type if possible, or the full type name otherwise
static public CSharpName ( System.TypeSpec t ) : string
t System.TypeSpec
return string

CSharpSignature() static public method

static public CSharpSignature ( MemberSpec mb ) : string
mb MemberSpec
return string

ChangeType() public static method

public static ChangeType ( object value, System.TypeSpec targetType, bool &error ) : object
value object
targetType System.TypeSpec
error bool
return object

GetElementType() public static method

public static GetElementType ( System.TypeSpec t ) : System.TypeSpec
t System.TypeSpec
return System.TypeSpec

GetFullNameSignature() static public method

static public GetFullNameSignature ( MemberSpec mi ) : string
mi MemberSpec
return string

GetPredefinedConstructor() public static method

public static GetPredefinedConstructor ( System.TypeSpec t, Mono.CSharp.Location loc ) : MethodSpec
t System.TypeSpec
loc Mono.CSharp.Location
return MethodSpec

GetPredefinedField() public static method

public static GetPredefinedField ( System.TypeSpec t, string name, Mono.CSharp.Location loc, System.TypeSpec type ) : FieldSpec
t System.TypeSpec
name string
loc Mono.CSharp.Location
type System.TypeSpec
return FieldSpec

GetPredefinedMethod() public static method

public static GetPredefinedMethod ( System.TypeSpec t, MemberFilter filter, Mono.CSharp.Location loc ) : MethodSpec
t System.TypeSpec
filter MemberFilter
loc Mono.CSharp.Location
return MethodSpec

GetPredefinedMethod() public static method

public static GetPredefinedMethod ( System.TypeSpec t, MemberFilter filter, bool optional, Mono.CSharp.Location loc ) : MethodSpec
t System.TypeSpec
filter MemberFilter
optional bool
loc Mono.CSharp.Location
return MethodSpec

GetPredefinedMethod() public static method

public static GetPredefinedMethod ( System.TypeSpec t, string name, Mono.CSharp.Location loc ) : MethodSpec
t System.TypeSpec
name string
loc Mono.CSharp.Location
return MethodSpec

GetPredefinedProperty() public static method

public static GetPredefinedProperty ( System.TypeSpec t, string name, Mono.CSharp.Location loc, System.TypeSpec type ) : PropertySpec
t System.TypeSpec
name string
loc Mono.CSharp.Location
type System.TypeSpec
return PropertySpec

GetTypeArguments() public static method

public static GetTypeArguments ( System.TypeSpec t ) : System.TypeSpec[]
t System.TypeSpec
return System.TypeSpec[]

HasElementType() public static method

This method is not implemented by MS runtime for dynamic types
public static HasElementType ( System.TypeSpec t ) : bool
t System.TypeSpec
return bool

IsBuiltinOrEnum() public static method

public static IsBuiltinOrEnum ( System.TypeSpec t ) : bool
t System.TypeSpec
return bool

IsBuiltinType() public static method

public static IsBuiltinType ( System.TypeSpec t ) : bool
t System.TypeSpec
return bool

IsDelegateType() public static method

public static IsDelegateType ( System.TypeSpec t ) : bool
t System.TypeSpec
return bool

IsEnumType() public static method

public static IsEnumType ( System.TypeSpec t ) : bool
t System.TypeSpec
return bool

IsFamilyAccessible() public static method

public static IsFamilyAccessible ( System.TypeSpec type, System.TypeSpec parent ) : bool
type System.TypeSpec
parent System.TypeSpec
return bool

IsGenericParameter() public static method

public static IsGenericParameter ( System.TypeSpec type ) : bool
type System.TypeSpec
return bool

IsGenericType() public static method

public static IsGenericType ( System.TypeSpec type ) : bool
type System.TypeSpec
return bool

IsInstantiationOfSameGenericType() public static method

Check whether `type' and `parent' are both instantiations of the same generic type. Note that we do not check the type parameters here.
public static IsInstantiationOfSameGenericType ( System.TypeSpec type, System.TypeSpec parent ) : bool
type System.TypeSpec
parent System.TypeSpec
return bool

IsNestedChildOf() public static method

public static IsNestedChildOf ( System.TypeSpec type, ITypeDefinition parent ) : bool
type System.TypeSpec
parent ITypeDefinition
return bool

IsNestedFamilyAccessible() public static method

public static IsNestedFamilyAccessible ( System.TypeSpec type, System.TypeSpec base_type ) : bool
type System.TypeSpec
base_type System.TypeSpec
return bool

IsNullableType() public static method

public static IsNullableType ( System.TypeSpec t ) : bool
t System.TypeSpec
return bool

IsPrimitiveType() public static method

public static IsPrimitiveType ( System.TypeSpec t ) : bool
t System.TypeSpec
return bool

IsReferenceType() public static method

public static IsReferenceType ( System.TypeSpec t ) : bool
t System.TypeSpec
return bool

IsSpecialType() public static method

public static IsSpecialType ( System.TypeSpec t ) : bool
t System.TypeSpec
return bool

IsStruct() public static method

public static IsStruct ( System.TypeSpec t ) : bool
t System.TypeSpec
return bool

IsUnmanagedType() public static method

public static IsUnmanagedType ( System.TypeSpec t ) : bool
t System.TypeSpec
return bool

IsValueType() public static method

public static IsValueType ( System.TypeSpec t ) : bool
t System.TypeSpec
return bool

Reset() static public method

static public Reset ( ) : void
return void

VerifyUnmanaged() public static method

Utility function that can be used to probe whether a type is managed or not.
public static VerifyUnmanaged ( CompilerContext ctx, System.TypeSpec t, Mono.CSharp.Location loc ) : bool
ctx CompilerContext
t System.TypeSpec
loc Mono.CSharp.Location
return bool

Property Details

activator_create_instance public static property

public static MethodSpec,Mono.CSharp activator_create_instance
return MethodSpec

arg_iterator_type static public property

static public TypeSpec,System arg_iterator_type
return System.TypeSpec

array_type static public property

static public BuildinTypeSpec array_type
return BuildinTypeSpec

attribute_type static public property

static public BuildinTypeSpec attribute_type
return BuildinTypeSpec

bool_movenext_void static public property

static public MethodSpec,Mono.CSharp bool_movenext_void
return MethodSpec

bool_type static public property

static public BuildinTypeSpec bool_type
return BuildinTypeSpec

byte_type static public property

static public BuildinTypeSpec byte_type
return BuildinTypeSpec

char_type static public property

static public BuildinTypeSpec char_type
return BuildinTypeSpec

decimal_type static public property

static public BuildinTypeSpec decimal_type
return BuildinTypeSpec

delegate_combine_delegate_delegate static public property

static public MethodSpec,Mono.CSharp delegate_combine_delegate_delegate
return MethodSpec

delegate_remove_delegate_delegate static public property

static public MethodSpec,Mono.CSharp delegate_remove_delegate_delegate
return MethodSpec

delegate_type static public property

static public BuildinTypeSpec delegate_type
return BuildinTypeSpec

double_type static public property

static public BuildinTypeSpec double_type
return BuildinTypeSpec

enum_type static public property

static public BuildinTypeSpec enum_type
return BuildinTypeSpec

exception_type static public property

static public BuildinTypeSpec exception_type
return BuildinTypeSpec

fieldinfo_get_field_from_handle public static property

public static MethodSpec,Mono.CSharp fieldinfo_get_field_from_handle
return MethodSpec

fieldinfo_get_field_from_handle_generic public static property

public static MethodSpec,Mono.CSharp fieldinfo_get_field_from_handle_generic
return MethodSpec

float_type static public property

static public BuildinTypeSpec float_type
return BuildinTypeSpec

gen_interlocked_compare_exchange public static property

public static MethodSpec,Mono.CSharp gen_interlocked_compare_exchange
return MethodSpec

generic_icollection_type static public property

static public TypeSpec,System generic_icollection_type
return System.TypeSpec

generic_ienumerable_type static public property

static public TypeSpec,System generic_ienumerable_type
return System.TypeSpec

generic_ienumerator_type static public property

static public TypeSpec,System generic_ienumerator_type
return System.TypeSpec

generic_ilist_type static public property

static public TypeSpec,System generic_ilist_type
return System.TypeSpec

generic_nullable_type static public property

static public TypeSpec,System generic_nullable_type
return System.TypeSpec

idisposable_type static public property

static public BuildinTypeSpec idisposable_type
return BuildinTypeSpec

ienumerable_type static public property

static public BuildinTypeSpec ienumerable_type
return BuildinTypeSpec

ienumerator_getcurrent static public property

static public PropertySpec,Mono.CSharp ienumerator_getcurrent
return PropertySpec

ienumerator_type static public property

static public BuildinTypeSpec ienumerator_type
return BuildinTypeSpec

int32_type static public property

static public BuildinTypeSpec int32_type
return BuildinTypeSpec

int64_type static public property

static public BuildinTypeSpec int64_type
return BuildinTypeSpec

int_get_offset_to_string_data static public property

static public PropertySpec,Mono.CSharp int_get_offset_to_string_data
return PropertySpec

int_interlocked_compare_exchange static public property

static public MethodSpec,Mono.CSharp int_interlocked_compare_exchange
return MethodSpec

intptr_type static public property

static public BuildinTypeSpec intptr_type
return BuildinTypeSpec

mbr_type static public property

static public TypeSpec,System mbr_type
return System.TypeSpec

methodbase_get_type_from_handle public static property

public static MethodSpec,Mono.CSharp methodbase_get_type_from_handle
return MethodSpec

methodbase_get_type_from_handle_generic public static property

public static MethodSpec,Mono.CSharp methodbase_get_type_from_handle_generic
return MethodSpec

multicast_delegate_type static public property

static public BuildinTypeSpec multicast_delegate_type
return BuildinTypeSpec

object_type static public property

static public BuildinTypeSpec object_type
return BuildinTypeSpec

runtime_field_handle_type static public property

static public BuildinTypeSpec runtime_field_handle_type
return BuildinTypeSpec

runtime_handle_type static public property

static public BuildinTypeSpec runtime_handle_type
return BuildinTypeSpec

sbyte_type static public property

static public BuildinTypeSpec sbyte_type
return BuildinTypeSpec

short_type static public property

static public BuildinTypeSpec short_type
return BuildinTypeSpec

string_empty static public property

static public FieldSpec,Mono.CSharp string_empty
return FieldSpec

string_type static public property

static public BuildinTypeSpec string_type
return BuildinTypeSpec

system_type_get_type_from_handle static public property

static public MethodSpec,Mono.CSharp system_type_get_type_from_handle
return MethodSpec

type_type static public property

static public BuildinTypeSpec type_type
return BuildinTypeSpec

typed_reference_type static public property

static public TypeSpec,System typed_reference_type
return System.TypeSpec

uint32_type static public property

static public BuildinTypeSpec uint32_type
return BuildinTypeSpec

uint64_type static public property

static public BuildinTypeSpec uint64_type
return BuildinTypeSpec

uintptr_type static public property

static public BuildinTypeSpec uintptr_type
return BuildinTypeSpec

ushort_type static public property

static public BuildinTypeSpec ushort_type
return BuildinTypeSpec

value_type static public property

static public BuildinTypeSpec value_type
return BuildinTypeSpec

void_decimal_ctor_five_args static public property

static public MethodSpec,Mono.CSharp void_decimal_ctor_five_args
return MethodSpec

void_decimal_ctor_int_arg static public property

static public MethodSpec,Mono.CSharp void_decimal_ctor_int_arg
return MethodSpec

void_decimal_ctor_long_arg public static property

public static MethodSpec,Mono.CSharp void_decimal_ctor_long_arg
return MethodSpec

void_dispose_void static public property

static public MethodSpec,Mono.CSharp void_dispose_void
return MethodSpec

void_initializearray_array_fieldhandle static public property

static public MethodSpec,Mono.CSharp void_initializearray_array_fieldhandle
return MethodSpec

void_monitor_enter_object static public property

static public MethodSpec,Mono.CSharp void_monitor_enter_object
return MethodSpec

void_monitor_exit_object static public property

static public MethodSpec,Mono.CSharp void_monitor_exit_object
return MethodSpec

void_type static public property

static public BuildinTypeSpec void_type
return BuildinTypeSpec