Show / Hide Table of Contents

Interface IPatternItemFactory

Interface for creating PatternItem instances.

Namespace: VDS.RDF.Query.Builder
Assembly: dotNetRdf.dll
Syntax
public interface IPatternItemFactory

Methods

| Edit this page View Source

CreateBlankNodeMatchPattern(string)

Create a pattern item that matches a specific blank node.

Declaration
PatternItem CreateBlankNodeMatchPattern(string blankNodeIdentifier)
Parameters
Type Name Description
string blankNodeIdentifier

The blank node identifier to match.

Returns
Type Description
PatternItem
| Edit this page View Source

CreateLiteralNodeMatchPattern(object)

Create a pattern item that matches a literal value.

Declaration
PatternItem CreateLiteralNodeMatchPattern(object literal)
Parameters
Type Name Description
object literal

The value to match as a literal.

Returns
Type Description
PatternItem
Remarks

If literal is a DateTime or DateTimeOffset then the literal pattern will use the appropriate XML Schema-compatible string representation as the literal value. For all other types, the value returned by the ToString method will be used as the literal value.

| Edit this page View Source

CreateLiteralNodeMatchPattern(object, string)

Create a pattern item that matches a literal value with an associated language tag.

Declaration
PatternItem CreateLiteralNodeMatchPattern(object literal, string langSpec)
Parameters
Type Name Description
object literal

The literal value to match.

string langSpec

The language tag to match.

Returns
Type Description
PatternItem
Remarks

If literal is a DateTime or DateTimeOffset then the literal pattern will use the appropriate XML Schema-compatible string representation as the literal value. For all other types, the value returned by the ToString method will be used as the literal value.

| Edit this page View Source

CreateLiteralNodeMatchPattern(object, Uri)

Create a pattern item that matches a literal value with its associated datatype.

Declaration
PatternItem CreateLiteralNodeMatchPattern(object literal, Uri datatype)
Parameters
Type Name Description
object literal

The literal value to match.

Uri datatype

The literal datatype URI to match.

Returns
Type Description
PatternItem
Remarks

If literal is a DateTime or DateTimeOffset then the literal pattern will use the appropriate XML Schema-compatible string representation as the literal value. For all other types, the value returned by the ToString method will be used as the literal value.

| Edit this page View Source

CreateNodeMatchPattern(string, INamespaceMapper)

Create a URI node pattern.

Declaration
PatternItem CreateNodeMatchPattern(string qName, INamespaceMapper namespaceMapper)
Parameters
Type Name Description
string qName

The CURIE representation of the URI.

INamespaceMapper namespaceMapper

The mapper to use when resolving the prefix part of the CURIE.

Returns
Type Description
PatternItem
| Edit this page View Source

CreateNodeMatchPattern(Uri)

Create a URI node pattern.

Declaration
PatternItem CreateNodeMatchPattern(Uri uri)
Parameters
Type Name Description
Uri uri

The URI for the pattern item.

Returns
Type Description
PatternItem
| Edit this page View Source

CreateNodeMatchPattern(INode)

Create a pattern item that matches the specified node.

Declaration
PatternItem CreateNodeMatchPattern(INode node)
Parameters
Type Name Description
INode node

The node to match.

Returns
Type Description
PatternItem
| Edit this page View Source

CreatePatternItem(Type, string, INamespaceMapper)

Create a pattern item that matches a node of a specific type.

Declaration
PatternItem CreatePatternItem(Type nodeType, string patternString, INamespaceMapper namespaceMapper)
Parameters
Type Name Description
Type nodeType

The type of node to match. Must be one of IBlankNode, ILiteralNode, IUriNode or IVariableNode.

string patternString

The string value of the pattern item.

INamespaceMapper namespaceMapper

The namespace mapper to use when resolving any prefixes in patternString.

Returns
Type Description
PatternItem
Remarks

It is recommended to use one of the CreateXxxNodeMatchPattern methods in preference to this method.

| Edit this page View Source

CreateVariablePattern(string)

Create a variable pattern item.

Declaration
PatternItem CreateVariablePattern(string variableName)
Parameters
Type Name Description
string variableName

The name of the variable.

Returns
Type Description
PatternItem

Extension Methods

Extensions.ToSafeString(object)
Extensions.AsEnumerable<T>(T)
  • Edit this page
  • View Source
In this article
  • Methods
    • CreateBlankNodeMatchPattern(string)
    • CreateLiteralNodeMatchPattern(object)
    • CreateLiteralNodeMatchPattern(object, string)
    • CreateLiteralNodeMatchPattern(object, Uri)
    • CreateNodeMatchPattern(string, INamespaceMapper)
    • CreateNodeMatchPattern(Uri)
    • CreateNodeMatchPattern(INode)
    • CreatePatternItem(Type, string, INamespaceMapper)
    • CreateVariablePattern(string)
  • Extension Methods
Back to top Generated by DocFX