Click or drag to resize

IObjectFactoryTryLoadObject Method

Attempts to load an Object of the given type identified by the given Node and returned as the Type that this loader generates.

Namespace:  VDS.RDF.Configuration
Assembly:  dotNetRDF (in dotNetRDF.dll) Version:
Syntax
bool TryLoadObject(
	IGraph g,
	INode objNode,
	Type targetType,
	out Object obj
)

Parameters

g
Type: VDS.RDFIGraph
Configuration Graph.
objNode
Type: VDS.RDFINode
Object Node.
targetType
Type: SystemType
Target Type.
obj
Type: SystemObject
Created Object.

Return Value

Type: Boolean
True if the loader succeeded in creating an Object.
Remarks

The Factory should not throw an error if some required configuration is missing as another factory further down the processing chain may still be able to create the object. If the factory encounters errors and all the required configuration information is present then that error should be thrown i.e. class instantiation throws an error or a call to load an object that this object requires fails.

See Also