C# Class Zetetic.Chain.Xml.XmlConfig

Afficher le fichier Open project: skradel/Zetetic.Chain Class Usage Examples

Private Properties

Свойство Type Description
GetPropValue string

Méthodes publiques

Méthode Description
ChangeType ( object value, Type conversionType ) : object

Returns an Object with the specified Type and whose value is equivalent to the specified object. Swiped from http://aspalliance.com/852_CodeSnip_ConvertChangeType_Wrapper_that_Handles_Nullable_Types

This method exists as a workaround to System.Convert.ChangeType(Object, Type) which does not handle nullables as of version 2.0 (2.0.50727.42) of the .NET Framework. The idea is that this method will be deleted once Convert.ChangeType is updated in a future version of the .NET Framework to handle nullable types, so we want this to behave as closely to Convert.ChangeType as possible. This method was written by Peter Johnson at: http://aspalliance.com/author.aspx?uId=1026.

CreateFromICommand ( ICommand cmd ) : XmlConfig
ResolveInternals ( ) : ICommand

Méthodes protégées

Méthode Description
DeserializeProperties ( ICommand target ) : ICommand

Deserialize the properties of the current XmlChain / XmlCommand and try to set the writeable properties of the output ICommand

ExcludeProperty ( PropertyInfo pi ) : bool

Don't discover properties with XmlIgnoreAttribute, nor the reserved 'Name' property.

IsChainRequired ( PropertyInfo pi ) : bool
SerializeProperties ( ICommand cmd, XmlConfig target ) : void

Investigate writeable, IConvertible properties of ICommand 'cmd' and write them into the XML-serializable properties of 'target'

Private Methods

Méthode Description
GetPropValue ( string key ) : string

Method Details

ChangeType() public static méthode

Returns an Object with the specified Type and whose value is equivalent to the specified object. Swiped from http://aspalliance.com/852_CodeSnip_ConvertChangeType_Wrapper_that_Handles_Nullable_Types
This method exists as a workaround to System.Convert.ChangeType(Object, Type) which does not handle nullables as of version 2.0 (2.0.50727.42) of the .NET Framework. The idea is that this method will be deleted once Convert.ChangeType is updated in a future version of the .NET Framework to handle nullable types, so we want this to behave as closely to Convert.ChangeType as possible. This method was written by Peter Johnson at: http://aspalliance.com/author.aspx?uId=1026.
public static ChangeType ( object value, Type conversionType ) : object
value object An Object that implements the IConvertible interface.
conversionType System.Type The Type to which value is to be converted.
Résultat object

CreateFromICommand() public static méthode

public static CreateFromICommand ( ICommand cmd ) : XmlConfig
cmd ICommand
Résultat XmlConfig

DeserializeProperties() protected méthode

Deserialize the properties of the current XmlChain / XmlCommand and try to set the writeable properties of the output ICommand
If ChainRequired property is absent
protected DeserializeProperties ( ICommand target ) : ICommand
target ICommand
Résultat ICommand

ExcludeProperty() protected static méthode

Don't discover properties with XmlIgnoreAttribute, nor the reserved 'Name' property.
protected static ExcludeProperty ( PropertyInfo pi ) : bool
pi System.Reflection.PropertyInfo
Résultat bool

IsChainRequired() protected static méthode

protected static IsChainRequired ( PropertyInfo pi ) : bool
pi System.Reflection.PropertyInfo
Résultat bool

ResolveInternals() public abstract méthode

public abstract ResolveInternals ( ) : ICommand
Résultat ICommand

SerializeProperties() protected static méthode

Investigate writeable, IConvertible properties of ICommand 'cmd' and write them into the XML-serializable properties of 'target'
If ChainRequired property is absent
protected static SerializeProperties ( ICommand cmd, XmlConfig target ) : void
cmd ICommand
target XmlConfig
Résultat void