Show / Hide Table of Contents

Class BuiltinContextsProvider

Provides the built-in contexts which are inherent to the TALES specification. These are generally accessible as if they were root objects within a path expression. If, for example, their names have been overwritten they may alternatively be referenced explicitly with the CONTEXTS reserved variable name.

Inheritance
System.Object
BuiltinContextsProvider
Implements
IGetsDictionaryOfNamedTalesValues
IGetsNamedTalesValue
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: ZptSharp.Expressions
Assembly: ZptSharp.dll
Syntax
public class BuiltinContextsProvider : IGetsDictionaryOfNamedTalesValues, IGetsNamedTalesValue
Remarks

This is the default implementation of the root contexts provider. If RootContextsProvider has not been overridden upon the configuration then this is the class which shall be used to provide the root contexts. A more in-depth treatment of the root contexts which are provided by this class is available in the separate writeup about global contexts.

If the configuration has been overridden and a different implementation chosen for the root contexts provider, then there might be a very different set of root contexts available, and not those described in the link above.

Constructors

| Improve this Doc View Source

BuiltinContextsProvider(ExpressionContext, RenderingConfig, IGetsMetalDocumentAdapter)

Initializes a new instance of the BuiltinContextsProvider class.

Declaration
public BuiltinContextsProvider(ExpressionContext context, RenderingConfig config, IGetsMetalDocumentAdapter metalDocumentAdapterFactory)
Parameters
Type Name Description
ExpressionContext context

The rendering context.

RenderingConfig config

The configuration.

IGetsMetalDocumentAdapter metalDocumentAdapterFactory

A METAL document adapter factory.

Fields

| Improve this Doc View Source

Attributes

An identifier/alias for getting the attributes from the current INode.

Declaration
public static readonly string Attributes
Field Value
Type Description
System.String
| Improve this Doc View Source

Container

An identifier/alias for getting the container of the current IDocument.

Declaration
public static readonly string Container
Field Value
Type Description
System.String
| Improve this Doc View Source

Default

An identifier/alias for an object which indicates that the current action should be cancelled.

Declaration
public static readonly string Default
Field Value
Type Description
System.String
| Improve this Doc View Source

Error

An identifier/alias for getting an error object which was encountered whilst processing a context.

Declaration
public static readonly string Error
Field Value
Type Description
System.String
| Improve this Doc View Source

Here

An identifier/alias for the model object contained within the expression context.

Declaration
public static readonly string Here
Field Value
Type Description
System.String
| Improve this Doc View Source

Nothing

An identifier/alias for a non-object. This translates to null in C# applications.

Declaration
public static readonly string Nothing
Field Value
Type Description
System.String
| Improve this Doc View Source

Options

An identifier for the keyword-options presented to the rendering process.

Declaration
public static readonly string Options
Field Value
Type Description
System.String
| Improve this Doc View Source

Repeat

An identifier for the collection of named repetition-information objects available in the expression context.

Declaration
public static readonly string Repeat
Field Value
Type Description
System.String
| Improve this Doc View Source

Template

An identifier/alias for getting the IDocument

Declaration
public static readonly string Template
Field Value
Type Description
System.String

Methods

| Improve this Doc View Source

GetAllNamedValues()

Gets a dictionary of every available named TALES value, exposed by the current instance.

Declaration
public virtual Task<IDictionary<string, object>> GetAllNamedValues()
Returns
Type Description
System.Threading.Tasks.Task<System.Collections.Generic.IDictionary<System.String, System.Object>>

The named values.

| Improve this Doc View Source

TryGetValueAsync(String, CancellationToken)

Attempts to get a value for a named reference, relative to the current instance.

Declaration
public virtual Task<GetValueResult> TryGetValueAsync(string name, CancellationToken cancellationToken = default(CancellationToken))
Parameters
Type Name Description
System.String name

The name of the value to retrieve.

System.Threading.CancellationToken cancellationToken

An optional cancellation token.

Returns
Type Description
System.Threading.Tasks.Task<GetValueResult>

An object indicating whether a value was successfully retrieved or not, along with the retrieved value (if applicable).

Implements

IGetsDictionaryOfNamedTalesValues
IGetsNamedTalesValue
  • Improve this Doc
  • View Source
In This Article
Back to top Generated by DocFX