November Happy Hour will be moved to Thursday December 5th.

Class TemplateModel

Model describing a template.

Inheritance
System.Object
TemplateModel
Inherited Members
System.Object.ToString()
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
Namespace: EPiServer.DataAbstraction
Assembly: EPiServer.dll
Version: 8.11.0
Syntax
public class TemplateModel : IReadOnly<TemplateModel>, IReadOnly

Constructors

TemplateModel()

Declaration
public TemplateModel()

Properties

AvailableWithoutTag

Gets or sets a value indicating whether the renderer should be available even when no specific tag is requested.

Declaration
public bool AvailableWithoutTag { get; set; }
Property Value
Type Description
System.Boolean

true if renderer is available without tag specified; otherwise, false.

Default

Gets or sets a value indicating whether this template should be the default rendering template.

Declaration
public bool Default { get; set; }
Property Value
Type Description
System.Boolean

true if this template is a default template; otherwise, false.

Description

Gets or sets a text describing the template.

Declaration
public string Description { get; set; }
Property Value
Type Description
System.String

DisplayName

Gets or sets the display name.

Declaration
public string DisplayName { get; set; }
Property Value
Type Description
System.String

Inherit

Gets or sets a value indicating whether this template can be inherited by other types.

Declaration
public bool Inherit { get; set; }
Property Value
Type Description
System.Boolean

true if the template can be inherited; otherwise, false.

Inherited

Gets or sets a value indicating whether this TemplateModel is inherited from another type.

Declaration
[Obsolete("Deprecated due to misunderstandings of usage. To register a template to be inherited use the Inherit property. To learn if this model represents an inherited template, use the IsInherited() method.")]
public bool Inherited { get; set; }
Property Value
Type Description
System.Boolean

true if the template has been inherited; otherwise, false.

IsReadOnly

Gets a value indicating whether this instance is read only.

Declaration
public bool IsReadOnly { get; protected set; }
Property Value
Type Description
System.Boolean

true if this instance is read only; otherwise, false.

Name

Gets or sets the name of the template.

Declaration
public string Name { get; set; }
Property Value
Type Description
System.String

Path

Gets or sets the path to the render.

Declaration
public string Path { get; set; }
Property Value
Type Description
System.String

Tags

Gets or sets the supperted tags of the render.

Declaration
public string[] Tags { get; set; }
Property Value
Type Description
System.String[]

TemplateType

Gets or sets the type of the template class that will render the model type.

Declaration
public Type TemplateType { get; set; }
Property Value
Type Description
System.Type

TemplateTypeCategory

Gets or sets the category of the type of the template.

Declaration
public TemplateTypeCategories TemplateTypeCategory { get; set; }
Property Value
Type Description
TemplateTypeCategories

Methods

CreateWritableClone()

Creates the writable clone.

Declaration
public TemplateModel CreateWritableClone()
Returns
Type Description
TemplateModel

IsInherited()

Determines whether the template is inherited from another model type by setting the Inherit property when registering the template.

Declaration
public bool IsInherited()
Returns
Type Description
System.Boolean

true if this instance has been inherited from another model type; otherwise, false.

MakeReadOnly()

Makes the instance read only.

Declaration
public void MakeReadOnly()

ThrowIfReadOnly()

Throws an System.NotSupportedException if this instance is set to read only.

Declaration
protected void ThrowIfReadOnly()

Explicit Interface Implementations

IReadOnly.CreateWritableClone()

Creates the writable clone.

Declaration
object IReadOnly.CreateWritableClone()
Returns
Type Description
System.Object

Implements

Extension Methods