MetadataTypesGenerator
Assembly: ServiceStack.dll
View Source
Declaration
public class MetadataTypesGenerator
Properties
AttributeConverters
View Source
Declaration
public static Dictionary<Type, Func<Attribute, MetadataAttribute>> AttributeConverters { get; }
Methods
GetMetadataTypes(IRequest, Func<Operation, Boolean>)
View Source
Declaration
public MetadataTypes GetMetadataTypes(IRequest req, Func<Operation, bool> predicate = null)
Returns
Parameters
Type | Name |
---|---|
ServiceStack.Web.IRequest | req |
System.Func<ServiceStack.Host.Operation,System.Boolean> | predicate |
ToTypeName(Type)
View Source
Declaration
public MetadataTypeName ToTypeName(Type type)
Returns
Parameters
Type | Name |
---|---|
System.Type | type |
ToFlattenedType(Type)
View Source
Declaration
public MetadataType ToFlattenedType(Type type)
Returns
Parameters
Type | Name |
---|---|
System.Type | type |
ToType(Type)
View Source
Declaration
public MetadataType ToType(Type type)
Returns
Parameters
Type | Name |
---|---|
System.Type | type |
ToExactType(Type)
View Source
Declaration
public MetadataType ToExactType(Type type)
Returns
Parameters
Type | Name |
---|---|
System.Type | type |
GetEnumMember(Type, String)
View Source
Declaration
public static FieldInfo GetEnumMember(Type type, string name)
Returns
System.Reflection.FieldInfo
Parameters
Type | Name |
---|---|
System.Type | type |
System.String | name |
ToAttributes(Type)
View Source
Declaration
public List<MetadataAttribute> ToAttributes(Type type)
Returns
System.Collections.Generic.List<ServiceStack.MetadataAttribute>
Parameters
Type | Name |
---|---|
System.Type | type |
ToProperties(Type)
View Source
Declaration
public List<MetadataPropertyType> ToProperties(Type type)
Returns
System.Collections.Generic.List<ServiceStack.MetadataPropertyType>
Parameters
Type | Name |
---|---|
System.Type | type |
GetNamespacesUsed(Type)
View Source
Declaration
public HashSet<string> GetNamespacesUsed(Type type)
Returns
System.Collections.Generic.HashSet<System.String>
Parameters
Type | Name |
---|---|
System.Type | type |
IncludeAttrsFilter(Attribute)
View Source
Declaration
public bool IncludeAttrsFilter(Attribute x)
Returns
System.Boolean
Parameters
Type | Name |
---|---|
System.Attribute | x |
ToAttributes(Object[])
View Source
Declaration
public List<MetadataAttribute> ToAttributes(object[] attrs)
Returns
System.Collections.Generic.List<ServiceStack.MetadataAttribute>
Parameters
Type | Name |
---|---|
System.Object[] | attrs |
ToAttributes(IEnumerable<Attribute>)
View Source
Declaration
public List<MetadataAttribute> ToAttributes(IEnumerable<Attribute> attrs)
Returns
System.Collections.Generic.List<ServiceStack.MetadataAttribute>
Parameters
Type | Name |
---|---|
System.Collections.Generic.IEnumerable<System.Attribute> | attrs |
ToAttribute(Attribute)
View Source
Declaration
public MetadataAttribute ToAttribute(Attribute attr)
Returns
ServiceStack.MetadataAttribute
Parameters
Type | Name |
---|---|
System.Attribute | attr |
ToMetadataAttribute(Attribute)
View Source
Declaration
public MetadataAttribute ToMetadataAttribute(Attribute attr)
Returns
ServiceStack.MetadataAttribute
Parameters
Type | Name |
---|---|
System.Attribute | attr |
Properties(Attribute)
View Source
Declaration
public List<PropertyInfo> Properties(Attribute attr)
Returns
System.Collections.Generic.List<System.Reflection.PropertyInfo>
Parameters
Type | Name |
---|---|
System.Attribute | attr |
NonDefaultProperties(Attribute)
View Source
Declaration
public List<MetadataPropertyType> NonDefaultProperties(Attribute attr)
Returns
System.Collections.Generic.List<ServiceStack.MetadataPropertyType>
Parameters
Type | Name |
---|---|
System.Attribute | attr |
ToProperty(PropertyInfo, Object, Dictionary<String, Object>)
View Source
Declaration
public MetadataPropertyType ToProperty(PropertyInfo pi, object instance = null, Dictionary<string, object> ignoreValues = null)
Returns
ServiceStack.MetadataPropertyType
Parameters
Type | Name |
---|---|
System.Reflection.PropertyInfo | pi |
System.Object | instance |
System.Collections.Generic.Dictionary<System.String,System.Object> | ignoreValues |
ToProperty(ParameterInfo)
View Source
Declaration
public MetadataPropertyType ToProperty(ParameterInfo pi)
Returns
ServiceStack.MetadataPropertyType
Parameters
Type | Name |
---|---|
System.Reflection.ParameterInfo | pi |