Class FileDefinitionStorage
Represents a file-based definition storage to resolve report definitions from a local directory.
Inheritance
Inherited Members
Namespace: Telerik.WebReportDesigner.Services
Assembly: Telerik.WebReportDesigner.Services.dll
Syntax
public class FileDefinitionStorage : FileDefinitionStorageBase, IResourceStorage, IHasBaseDir, IDefinitionStorage, IAssetsStorage
Constructors
FileDefinitionStorage(String)
Initializes a new instance of the FileDefinitionStorage class.
Declaration
public FileDefinitionStorage(string baseDir)
Parameters
System.String
baseDir
The base directory where the report definitions are stored. |
FileDefinitionStorage(String, String[])
Initializes a new instance of the FileDefinitionStorage class.
Declaration
public FileDefinitionStorage(string baseDir, string[] excludedFolders)
Parameters
System.String
baseDir
The base directory where the report definitions are stored. |
System.String[]
excludedFolders
Relative folder paths to be excluded when retrieving folder contents. Wildcards are not supported. |
Fields
RootFolderName
The constant name of the Reports root folder.
Declaration
public const string RootFolderName = "Reports"
Field Value
System.String
|
Properties
FileExtensions
Gets an array with allowed file extensions.
Declaration
protected override string[] FileExtensions { get; }
Property Value
System.String[]
|
Overrides
Methods
GetByUri(String)
Finds a definition by its uri
and returns its contents as byte array.
Declaration
public override byte[] GetByUri(string uri)
Parameters
System.String
uri
The unique resource identifier (URI) of the definition. |
Returns
System.Byte[]
|
Overrides
RenameAsync(RenameResourceModel)
Renames a report by its model
.
Declaration
public override Task<ResourceFileModel> RenameAsync(RenameResourceModel model)
Parameters
RenameResourceModel
model
The model containing relevant data used to rename |
Returns
System.Threading.Tasks.Task<ResourceFileModel>
|
Overrides
Implements
SaveAsync(SaveResourceModel, Byte[])
Creates new or overwrites an existing report definition file with the provided definition bytes.
Declaration
public override Task<ResourceFileModel> SaveAsync(SaveResourceModel model, byte[] resource)
Parameters
SaveResourceModel
model
|
System.Byte[]
resource
|
Returns
System.Threading.Tasks.Task<ResourceFileModel>
|
Overrides
Implements
ValidateDefinitionId(String)
Validates the provided definitionId.
Declaration
protected override void ValidateDefinitionId(string definitionId)
Parameters
System.String
definitionId
|