C# 클래스 Spring.Core.TypeConversion.RuntimeTypeConverter

A custom System.ComponentModel.TypeConverter for runtime type references.

Currently only supports conversion to and from a System.String.

상속: System.ComponentModel.TypeConverter
파일 보기 프로젝트 열기: spring-projects/spring-net 1 사용 예제들

공개 메소드들

메소드 설명
CanConvertFrom ( ITypeDescriptorContext context, Type sourceType ) : bool

Returns whether this converter can convert an object of one System.Type to the System.Type of this converter.

Currently only supports conversion from a System.String instance.

CanConvertTo ( ITypeDescriptorContext context, Type destinationType ) : bool

Returns whether this converter can convert the object to the specified System.Type.

ConvertFrom ( ITypeDescriptorContext context, CultureInfo culture, object value ) : object

Converts the given value to the type of this converter.

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

Converts the given value object to the specified type, using the specified context and culture information.

RuntimeTypeConverter ( ) : System

Creates a new instance of the Spring.Core.TypeConversion.RuntimeTypeConverter class.

메소드 상세

CanConvertFrom() 공개 메소드

Returns whether this converter can convert an object of one System.Type to the System.Type of this converter.

Currently only supports conversion from a System.String instance.

public CanConvertFrom ( ITypeDescriptorContext context, Type sourceType ) : bool
context ITypeDescriptorContext /// A /// that provides a format context. ///
sourceType System.Type /// A that represents the /// you want to convert from. ///
리턴 bool

CanConvertTo() 공개 메소드

Returns whether this converter can convert the object to the specified System.Type.
public CanConvertTo ( ITypeDescriptorContext context, Type destinationType ) : bool
context ITypeDescriptorContext /// A /// that provides a format context. ///
destinationType System.Type /// A that represents the /// you want to convert to. ///
리턴 bool

ConvertFrom() 공개 메소드

Converts the given value to the type of this converter.
public ConvertFrom ( ITypeDescriptorContext context, CultureInfo culture, object value ) : object
context ITypeDescriptorContext /// A /// that provides a format context. ///
culture System.Globalization.CultureInfo /// The to use /// as the current culture. ///
value object /// The value that is to be converted. ///
리턴 object

ConvertTo() 공개 메소드

Converts the given value object to the specified type, using the specified context and culture information.
public ConvertTo ( ITypeDescriptorContext context, CultureInfo culture, object value, Type destinationType ) : object
context ITypeDescriptorContext /// A /// that provides a format context. ///
culture System.Globalization.CultureInfo /// The to use /// as the current culture. ///
value object /// The value that is to be converted. ///
destinationType System.Type /// The to convert the /// parameter to. ///
리턴 object

RuntimeTypeConverter() 공개 메소드

Creates a new instance of the Spring.Core.TypeConversion.RuntimeTypeConverter class.
public RuntimeTypeConverter ( ) : System
리턴 System