C# Class Habanero.Testability.BODefaultValueRegistry

This is a registry of the BOTestValues for various Properties and Single Relationships of a BusinessObject. This was creates so as to allow the Developer to BOTestFactory{TBO}.SetValueFor{TReturn} and such that when the Object is created with the BOTestFactory.CreateBusinessObject etc or updated with BOTestFactory.UpdateCompulsoryProperties this will be the value used.
Afficher le fichier Open project: Chillisoft/habanero.testability

Méthodes publiques

Méthode Description
IsRegistered ( string methodName ) : bool

Returns True if a value is registered with the name methodName

Register ( string methodName, object defaultValue ) : void

Registers the Default value to be used for the Method

Resolve ( string methodName ) : object

Resolves the registered BOTestFactory if one is registered. Else tries to find a Sub Class of the Generic BOTestFactory{TBO} in the App Domain and returns an instance of it. else constructs the Generic BOTestFactory{TBO}

Private Methods

Méthode Description
ClearPreviousInstances ( string methodName ) : void

Method Details

IsRegistered() public méthode

Returns True if a value is registered with the name methodName
public IsRegistered ( string methodName ) : bool
methodName string
Résultat bool

Register() public méthode

Registers the Default value to be used for the Method
public Register ( string methodName, object defaultValue ) : void
methodName string
defaultValue object
Résultat void

Resolve() public méthode

Resolves the registered BOTestFactory if one is registered. Else tries to find a Sub Class of the Generic BOTestFactory{TBO} in the App Domain and returns an instance of it. else constructs the Generic BOTestFactory{TBO}
public Resolve ( string methodName ) : object
methodName string
Résultat object