public interface ITemplateService : IService
Methods View Source CreateAsync(String, String, String, Guid, Nullable<Guid>)
Creates a new template
DeclarationTask<Attempt<ITemplate, TemplateOperationStatus>> CreateAsync(string name, string alias, string content, Guid userKey, Guid? templateKey = null)
Parameters Type Name Description System.String name
Name of the new template
System.String aliasAlias of the template
System.String contentView content for the new template
Guid userKeyKey of the user performing the Create.
System.Nullable<Guid> templateKey Returns View Source CreateAsync(ITemplate, Guid)Creates a new template
DeclarationTask<Attempt<ITemplate, TemplateOperationStatus>> CreateAsync(ITemplate template, Guid userKey)
Parameters Type Name Description ITemplate template
The new template
Guid userKeyKey of the user performing the Create.
Returns View Source CreateForContentTypeAsync(String, String, Guid)Creates a template for a content type
DeclarationTask<Attempt<ITemplate, TemplateOperationStatus>> CreateForContentTypeAsync(string contentTypeAlias, string contentTypeName, Guid userKey)
Parameters Type Name Description System.String contentTypeAlias System.String contentTypeName Guid userKey
Key of the user performing the Create.
Returns View Source DeleteAsync(Guid, Guid)Deletes a template by its key
DeclarationTask<Attempt<ITemplate, TemplateOperationStatus>> DeleteAsync(Guid key, Guid userKey)
Parameters Type Name Description Guid key
Key of the ITemplate to delete
Guid userKeyKey of the user performing the Delete.
Returns View Source DeleteAsync(String, Guid)Deletes a template by its alias
DeclarationTask<Attempt<ITemplate, TemplateOperationStatus>> DeleteAsync(string alias, Guid userKey)
Parameters Type Name Description System.String alias
Alias of the ITemplate to delete
Guid userKeyKey of the user performing the Delete.
Returns View Source GetAllAsync(Guid[])Gets a list of all ITemplate objects
DeclarationTask<IEnumerable<ITemplate>> GetAllAsync(Guid[] keys)
Parameters Type Name Description Guid[] keys Returns View Source GetAllAsync(String[])
Gets a list of all ITemplate objects
DeclarationTask<IEnumerable<ITemplate>> GetAllAsync(params string[] aliases)
Parameters Type Name Description System.String[] aliases Returns View Source GetAsync(Guid)
Gets a ITemplate object by its guid identifier.
DeclarationTask<ITemplate> GetAsync(Guid id)
Parameters Type Name Description Guid id
The guid identifier of the template.
Returns View Source GetAsync(Int32)Gets a ITemplate object by its identifier.
DeclarationTask<ITemplate> GetAsync(int id)
Parameters Type Name Description System.Int32 id
The identifier of the template.
Returns View Source GetAsync(String)Gets a ITemplate object by its alias.
DeclarationTask<ITemplate> GetAsync(string alias)
Parameters Type Name Description System.String alias
The alias of the template.
Returns View Source GetChildrenAsync(Int32)Gets a list of all ITemplate objects
DeclarationTask<IEnumerable<ITemplate>> GetChildrenAsync(int masterTemplateId)
Parameters Type Name Description System.Int32 masterTemplateId Returns View Source GetDescendantsAsync(Int32)
Gets the template descendants
DeclarationTask<IEnumerable<ITemplate>> GetDescendantsAsync(int masterTemplateId)
Parameters Type Name Description System.Int32 masterTemplateId Returns Type Description Task<IEnumerable<ITemplate>> View Source GetFileContentStreamAsync(String)
Gets the content of a template as a stream.
DeclarationTask<Stream> GetFileContentStreamAsync(string filepath)
Parameters Type Name Description System.String filepath
The filesystem path to the template.
Returns Type Description Task<Stream>The content of the template.
View Source GetFileSizeAsync(String)Gets the size of a template.
DeclarationTask<long> GetFileSizeAsync(string filepath)
Parameters Type Name Description System.String filepath
The filesystem path to the template.
Returns Type Description Task<System.Int64>The size of the template.
View Source SetFileContentAsync(String, Stream)Sets the content of a template.
DeclarationTask SetFileContentAsync(string filepath, Stream content)
Parameters Type Name Description System.String filepath
The filesystem path to the template.
Stream contentThe content of the template.
Returns View Source UpdateAsync(ITemplate, Guid)Updates a ITemplate
DeclarationTask<Attempt<ITemplate, TemplateOperationStatus>> UpdateAsync(ITemplate template, Guid userKey)
Parameters Type Name Description ITemplate template
ITemplate to update
Guid userKeyKey of the user saving the template
ReturnsRetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4