Class TemplateContext
Holds a reference to the current template.
Inheritance
System.Object
TemplateContext
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: Sartorius.SAF.ReportGenerator
Assembly: Sartorius.SAF.ReportGenerator.dll
Syntax
public static class TemplateContext
Properties
View SourceCurrentTemplate
Gets the current template.
Declaration
public static IReportTemplate CurrentTemplate { get; }
Property Value
Type | Description |
---|---|
IReportTemplate |
Exceptions
Type | Condition |
---|---|
System.InvalidOperationException | There is no current TemplateContext. |
CurrentTemplateType
Gets the type of the current template.
Declaration
public static Type CurrentTemplateType { get; }
Property Value
Type | Description |
---|---|
System.Type |
Exceptions
Type | Condition |
---|---|
System.InvalidOperationException | There is no current TemplateContext. |
Methods
View SourceUseContext(IReportTemplate)
Starts a new context for the specified template.
Declaration
public static IDisposable UseContext(IReportTemplate template)
Parameters
Type | Name | Description |
---|---|---|
IReportTemplate | template | The template that defines the context. |
Returns
Type | Description |
---|---|
System.IDisposable | An System.IDisposable that defines the lifetime of the context. |