Class UniqueBlankNodesHandler
A decorator for handlers which ensures that all blank nodes get unique IDs even if a blank node identifier is reused.
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: VDS.RDF.Parsing.Handlers
Assembly: dotNetRDF.dll
Syntax
public class UniqueBlankNodesHandler : BaseRdfHandler, IWrappingRdfHandler, IRdfHandler, INodeFactory
Remarks
In most parsing scenarios this handler is not suitable for usage as it may unintentionally modify the RDF data being parsed, in non-parsing scenarios where this handler is instead being used as a means to generate RDF data from some non-RDF source it may prove very useful.
This handler essentially works by redirecting all calls to the argument taking form of CreateBlankNode() with the non-argument form which should always generate a new blank node thus guaranteeing the uniqueness of nodes.
Constructors
| Improve this Doc View SourceUniqueBlankNodesHandler(IRdfHandler)
Creates a new Unique Blank Nodes handler.
Declaration
public UniqueBlankNodesHandler(IRdfHandler handler)
Parameters
Type | Name | Description |
---|---|---|
IRdfHandler | handler |
Properties
| Improve this Doc View SourceAcceptsAll
Gets whether the inner handler accepts all.
Declaration
public override bool AcceptsAll { get; }
Property Value
Type | Description |
---|---|
System.Boolean |
Overrides
| Improve this Doc View SourceInnerHandlers
Gets the inner handler.
Declaration
public IEnumerable<IRdfHandler> InnerHandlers { get; }
Property Value
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<IRdfHandler> |
Methods
| Improve this Doc View SourceCreateBlankNode(String)
Creates a Blank Node.
Declaration
public override IBlankNode CreateBlankNode(string nodeId)
Parameters
Type | Name | Description |
---|---|---|
System.String | nodeId | Node ID which will be ignored by this Handler. |
Returns
Type | Description |
---|---|
IBlankNode |
Overrides
| Improve this Doc View SourceEndRdfInternal(Boolean)
Ends handling RDF.
Declaration
protected override void EndRdfInternal(bool ok)
Parameters
Type | Name | Description |
---|---|---|
System.Boolean | ok | Whether parsing completed OK. |
Overrides
| Improve this Doc View SourceHandleBaseUriInternal(Uri)
Handles a Base URI declaration.
Declaration
protected override bool HandleBaseUriInternal(Uri baseUri)
Parameters
Type | Name | Description |
---|---|---|
System.Uri | baseUri | Base URI. |
Returns
Type | Description |
---|---|
System.Boolean |
Overrides
| Improve this Doc View SourceHandleNamespaceInternal(String, Uri)
Handles a Namespace declaration.
Declaration
protected override bool HandleNamespaceInternal(string prefix, Uri namespaceUri)
Parameters
Type | Name | Description |
---|---|---|
System.String | prefix | Prefix. |
System.Uri | namespaceUri | Namespace URI. |
Returns
Type | Description |
---|---|
System.Boolean |
Overrides
| Improve this Doc View SourceHandleTripleInternal(Triple)
Handles a Triple.
Declaration
protected override bool HandleTripleInternal(Triple t)
Parameters
Type | Name | Description |
---|---|---|
Triple | t | Triple. |
Returns
Type | Description |
---|---|
System.Boolean |
Overrides
| Improve this Doc View SourceStartRdfInternal()
Starts handling RDF.
Declaration
protected override void StartRdfInternal()