Class TypeCache
Used by serializers to find value types
Inherited Members
Namespace:CacheManager.Core.Internal
Assembly:CacheManager.Core.dll
Syntax
public static class TypeCache
Properties
| Improve this Doc View SourceObjectType
Gets typeof(object)
.
Declaration
public static Type ObjectType { get; }
Property Value
Type | Description |
---|---|
Type |
Methods
| Improve this Doc View SourceGetType(String)
Gets Type by full name (with falling back to the first part only).
Declaration
public static Type GetType(string type)
Parameters
Type | Name | Description |
---|---|---|
String | type | The type name. |
Returns
Type | Description |
---|---|
Type | The Type if valid. |
Exceptions
Type | Condition |
---|---|
TypeLoadException | In case the type is not a valid type. (Might also throw other type load related exceptions). |
RegisterResolveType(Func<String, Type>)
Registers a custom type resolver in case you really need to manipulate the way serialization works with types. The resolve func is allowed to return null in case you cannot resolve the requested type. Any exception the resolve func might throw will not bubble up.
Declaration
public static void RegisterResolveType(Func<string, Type> resolve)
Parameters
Type | Name | Description |
---|---|---|
Func<String, Type> | resolve | The resolver |