Show / Hide Table of Contents

Class PagingHandler

A RDF Handler which wraps another handler passing only the chunk of triples falling within a given limit and offset to the underlying Handler.

Inheritance
object
BaseHandler
BaseRdfHandler
PagingHandler
Implements
ICommentRdfHandler
IWrappingRdfHandler
IRdfHandler
INodeFactory
Inherited Members
BaseRdfHandler.StartRdf()
BaseRdfHandler.EndRdf(bool)
BaseRdfHandler.HandleNamespace(string, Uri)
BaseRdfHandler.HandleBaseUri(Uri)
BaseRdfHandler.HandleTriple(Triple)
BaseRdfHandler.HandleQuad(Triple, IRefNode)
BaseRdfHandler.HandleComment(string)
BaseRdfHandler.HandleCommentInternal(string)
BaseHandler.NodeFactory
BaseHandler.NormalizeLiteralValues
BaseHandler.LanguageTagValidation
BaseHandler.ResolveQName(string)
BaseHandler.BaseUri
BaseHandler.NamespaceMap
BaseHandler.UriFactory
BaseHandler.CreateBlankNode()
BaseHandler.CreateBlankNode(string)
BaseHandler.CreateGraphLiteralNode()
BaseHandler.CreateGraphLiteralNode(IGraph)
BaseHandler.CreateLiteralNode(string, Uri)
BaseHandler.CreateLiteralNode(string)
BaseHandler.CreateLiteralNode(string, string)
BaseHandler.CreateUriNode(Uri)
BaseHandler.CreateUriNode(string)
BaseHandler.CreateUriNode()
BaseHandler.CreateVariableNode(string)
BaseHandler.CreateTripleNode(Triple)
BaseHandler.GetNextBlankNodeID()
object.Equals(object)
object.Equals(object, object)
object.GetHashCode()
object.GetType()
object.MemberwiseClone()
object.ReferenceEquals(object, object)
object.ToString()
Namespace: VDS.RDF.Parsing.Handlers
Assembly: dotNetRdf.dll
Syntax
public class PagingHandler : BaseRdfHandler, ICommentRdfHandler, IWrappingRdfHandler, IRdfHandler, INodeFactory
Remarks

This handler does not guarantee that you will receive exactly the chunk specified by the limit and offset for two reasons:.

  1. It does not perform any sort of data de-duplication so it is possible that if this handler receives duplicate triples and the underlying handler performs de-duplication then you may see less triples than you expect in your final output since although the underlying handler will receive at most the specified chunk size of triples it may not retain them all
  2. If there are fewer triples than the chunk size or if the chunk exceeds the bounds of the data then you will only receive the triples that fall within the chunk (if any)

Constructors

| Edit this page View Source

PagingHandler(IRdfHandler, int)

Creates a new Paging Handler.

Declaration
public PagingHandler(IRdfHandler handler, int limit)
Parameters
Type Name Description
IRdfHandler handler

Inner Handler to use.

int limit

Limit.

| Edit this page View Source

PagingHandler(IRdfHandler, int, int)

Creates a new Paging Handler.

Declaration
public PagingHandler(IRdfHandler handler, int limit, int offset)
Parameters
Type Name Description
IRdfHandler handler

Inner Handler to use.

int limit

Limit.

int offset

Offset.

Remarks

If you just want to use an offset and not apply a limit then set limit to be less than zero.

Properties

| Edit this page View Source

AcceptsAll

Gets whether the Handler will accept all Triples based on its Limit setting.

Declaration
public override bool AcceptsAll { get; }
Property Value
Type Description
bool
Overrides
BaseRdfHandler.AcceptsAll
| Edit this page View Source

InnerHandlers

Gets the Inner Handler wrapped by this Handler.

Declaration
public IEnumerable<IRdfHandler> InnerHandlers { get; }
Property Value
Type Description
IEnumerable<IRdfHandler>

Methods

| Edit this page View Source

EndRdfInternal(bool)

Ends RDF Handler.

Declaration
protected override void EndRdfInternal(bool ok)
Parameters
Type Name Description
bool ok

Indicated whether parsing completed without error.

Overrides
BaseRdfHandler.EndRdfInternal(bool)
| Edit this page View Source

HandleBaseUriInternal(Uri)

Handles Base URI Declarations by allowing the inner handler to handle it.

Declaration
protected override bool HandleBaseUriInternal(Uri baseUri)
Parameters
Type Name Description
Uri baseUri

Base URI.

Returns
Type Description
bool
Overrides
BaseRdfHandler.HandleBaseUriInternal(Uri)
| Edit this page View Source

HandleNamespaceInternal(string, Uri)

Handles Namespace Declarations by allowing the inner handler to handle it.

Declaration
protected override bool HandleNamespaceInternal(string prefix, Uri namespaceUri)
Parameters
Type Name Description
string prefix

Namespace Prefix.

Uri namespaceUri

Namespace URI.

Returns
Type Description
bool
Overrides
BaseRdfHandler.HandleNamespaceInternal(string, Uri)
| Edit this page View Source

HandleQuadInternal(Triple, IRefNode)

Handles a quad by passing it to the Inner Handler only if the Offset has been passed and the Limit has yet to be reached.

Declaration
protected override bool HandleQuadInternal(Triple t, IRefNode graph)
Parameters
Type Name Description
Triple t

Triple.

IRefNode graph

The name of the graph containing the triple.

Returns
Type Description
bool
Overrides
BaseRdfHandler.HandleQuadInternal(Triple, IRefNode)
Remarks

Terminates handling immediately upon the reaching of the limit.

| Edit this page View Source

HandleTripleInternal(Triple)

Handles a Triple by passing it to the Inner Handler only if the Offset has been passed and the Limit has yet to be reached.

Declaration
protected override bool HandleTripleInternal(Triple t)
Parameters
Type Name Description
Triple t

Triple.

Returns
Type Description
bool
Overrides
BaseRdfHandler.HandleTripleInternal(Triple)
Remarks

Terminates handling immediately upon the reaching of the limit.

| Edit this page View Source

StartRdfInternal()

Starts RDF Handler.

Declaration
protected override void StartRdfInternal()
Overrides
BaseRdfHandler.StartRdfInternal()

Implements

ICommentRdfHandler
IWrappingRdfHandler
IRdfHandler
INodeFactory

Extension Methods

Extensions.ToSafeString(object)
HandlerExtensions.Apply(IRdfHandler, IEnumerable<Triple>)
HandlerExtensions.Apply(IRdfHandler, IGraph)
Extensions.AsEnumerable<T>(T)
  • Edit this page
  • View Source
In this article
  • Constructors
    • PagingHandler(IRdfHandler, int)
    • PagingHandler(IRdfHandler, int, int)
  • Properties
    • AcceptsAll
    • InnerHandlers
  • Methods
    • EndRdfInternal(bool)
    • HandleBaseUriInternal(Uri)
    • HandleNamespaceInternal(string, Uri)
    • HandleQuadInternal(Triple, IRefNode)
    • HandleTripleInternal(Triple)
    • StartRdfInternal()
  • Implements
  • Extension Methods
Back to top Generated by DocFX