C# Class Ninject.Parameters.ConstructorArgument

Overrides the injected value of a constructor argument.
Inheritance: Parameter, IConstructorArgument
Mostrar archivo Open project: ninject/Ninject Class Usage Examples

Public Methods

Method Description
AppliesToTarget ( IContext context, ITarget target ) : bool

Determines if the parameter applies to the given target.

Only one parameter may return true.

ConstructorArgument ( string name, Func valueCallback ) : System

Initializes a new instance of the ConstructorArgument class.

ConstructorArgument ( string name, Func valueCallback, bool shouldInherit ) : System

Initializes a new instance of the ConstructorArgument class.

ConstructorArgument ( string name, object>.Func valueCallback ) : System

Initializes a new instance of the ConstructorArgument class.

ConstructorArgument ( string name, object>.Func valueCallback, bool shouldInherit ) : System

Initializes a new instance of the ConstructorArgument class.

ConstructorArgument ( string name, object value ) : System

Initializes a new instance of the ConstructorArgument class.

ConstructorArgument ( string name, object value, bool shouldInherit ) : System

Initializes a new instance of the ConstructorArgument class.

Method Details

AppliesToTarget() public method

Determines if the parameter applies to the given target.
Only one parameter may return true.
public AppliesToTarget ( IContext context, ITarget target ) : bool
context IContext The context.
target ITarget The target.
return bool

ConstructorArgument() public method

Initializes a new instance of the ConstructorArgument class.
public ConstructorArgument ( string name, Func valueCallback ) : System
name string The name of the argument to override.
valueCallback Func The callback to invoke to get the value that should be injected.
return System

ConstructorArgument() public method

Initializes a new instance of the ConstructorArgument class.
public ConstructorArgument ( string name, Func valueCallback, bool shouldInherit ) : System
name string The name of the argument to override.
valueCallback Func The callback to invoke to get the value that should be injected.
shouldInherit bool if set to true [should inherit].
return System

ConstructorArgument() public method

Initializes a new instance of the ConstructorArgument class.
public ConstructorArgument ( string name, object>.Func valueCallback ) : System
name string The name of the argument to override.
valueCallback object>.Func The callback to invoke to get the value that should be injected.
return System

ConstructorArgument() public method

Initializes a new instance of the ConstructorArgument class.
public ConstructorArgument ( string name, object>.Func valueCallback, bool shouldInherit ) : System
name string The name of the argument to override.
valueCallback object>.Func The callback to invoke to get the value that should be injected.
shouldInherit bool if set to true [should inherit].
return System

ConstructorArgument() public method

Initializes a new instance of the ConstructorArgument class.
public ConstructorArgument ( string name, object value ) : System
name string The name of the argument to override.
value object The value to inject into the property.
return System

ConstructorArgument() public method

Initializes a new instance of the ConstructorArgument class.
public ConstructorArgument ( string name, object value, bool shouldInherit ) : System
name string The name of the argument to override.
value object The value to inject into the property.
shouldInherit bool Whether the parameter should be inherited into child requests.
return System