ObjectItemCollection.TryGetClrType Method

 

Returns the underlying CLR type for the specified OSpace enum type argument.

Namespace:   System.Data.Entity.Core.Metadata.Edm
Assembly:  EntityFramework (in EntityFramework.dll)

NameDescription
System_CAPS_pubmethodTryGetClrType(EnumType, Type)

Returns the underlying CLR type for the specified OSpace enum type argument. If the DataSpace of the parameter is not OSpace, the method returns false and sets the out parameter to null.

System_CAPS_pubmethodTryGetClrType(StructuralType, Type)

Returns a CLR type corresponding to the StructuralType supplied by the objectSpaceType parameter.


ObjectItemCollection.TryGetClrType Method (EnumType, Type)

Returns the underlying CLR type for the specified OSpace enum type argument. If the DataSpace of the parameter is not OSpace, the method returns false and sets the out parameter to null.

[SuppressMessageAttribute("Microsoft.Performance", "CA1822:MarkMembersAsStatic")]
public bool TryGetClrType(
	EnumType objectSpaceType,
	out Type clrType
)

Parameters

objectSpaceType
Type: System.Data.Entity.Core.Metadata.Edm.EnumType

The OSpace enum type to look up

clrType
Type: System.Type

The CLR enum type of the OSpace argument

Return Value

Type: System.Boolean

true on success, false on failure


ObjectItemCollection.TryGetClrType Method (StructuralType, Type)

Returns a CLR type corresponding to the StructuralType supplied by the objectSpaceType parameter.

[SuppressMessageAttribute("Microsoft.Performance", "CA1822:MarkMembersAsStatic")]
public bool TryGetClrType(
	StructuralType objectSpaceType,
	out Type clrType
)

Parameters

objectSpaceType
Type: System.Data.Entity.Core.Metadata.Edm.StructuralType

A StructuralType that represents the object space type.

clrType
Type: System.Type

The CLR type.

Return Value

Type: System.Boolean

true if there is a type that matches the search criteria; otherwise, false.