C# Класс Revit.SDK.Samples.ProjectInfo.CS.RevitEnumConverter

Converter for Enumeration types of RevitAPI
Наследование: System.ComponentModel.EnumConverter
Показать файл Открыть проект

Открытые методы

Метод Описание
ConvertFrom ( ITypeDescriptorContext context, System culture, object value ) : object

Returns an enum item from a string

ConvertTo ( ITypeDescriptorContext context, System culture, object value, Type destinationType ) : object

Convert enum item to string

GetStandardValues ( ITypeDescriptorContext context ) : StandardValuesCollection

Returns a collection of standard values from the default context for the data type this type converter is designed for.

RevitEnumConverter ( Type type ) : System

Initialize private variables

Описание методов

ConvertFrom() публичный Метод

Returns an enum item from a string
public ConvertFrom ( ITypeDescriptorContext context, System culture, object value ) : object
context ITypeDescriptorContext An System.ComponentModel.ITypeDescriptorContext /// that provides a format context.
culture System An optional System.Globalization.CultureInfo. /// If not supplied, the current culture is assumed.
value object string to be converted to
Результат object

ConvertTo() публичный Метод

Convert enum item to string
public ConvertTo ( ITypeDescriptorContext context, System culture, object value, Type destinationType ) : object
context ITypeDescriptorContext An ITypeDescriptorContext that provides a format context.
culture System A CultureInfo. If null is passed, the current culture is assumed.
value object The Object to convert.
destinationType System.Type The Type to convert the value parameter to.
Результат object

GetStandardValues() публичный Метод

Returns a collection of standard values from the default context for the data type this type converter is designed for.
public GetStandardValues ( ITypeDescriptorContext context ) : StandardValuesCollection
context ITypeDescriptorContext
Результат StandardValuesCollection

RevitEnumConverter() публичный Метод

Initialize private variables
public RevitEnumConverter ( Type type ) : System
type System.Type Enumeration type
Результат System