Class ProjectReportsOperations
Use this class to manage the project reports operations
Inheritance
Inherited Members
Namespace: Sdl.ProjectAutomation.FileBased.Reports.Operations
Assembly: Sdl.ProjectAutomation.FileBased.dll
Syntax
public class ProjectReportsOperations
Constructors
ProjectReportsOperations(FileBasedProject)
Declaration
public ProjectReportsOperations(FileBasedProject fileBasedProject)
Parameters
Type | Name | Description |
---|---|---|
FileBasedProject | fileBasedProject |
Methods
AddReport(String, String, String, String, String)
Add a report based on Studio report templates
Declaration
public Report AddReport(string templateId, string name, string description, string languageAbbreviation, string data)
Parameters
Type | Name | Description |
---|---|---|
System.String | templateId | Report template Id |
System.String | name | Report name |
System.String | description | Report description |
System.String | languageAbbreviation | ISO abbreviation for the report language |
System.String | data | Report html data |
Returns
Type | Description |
---|---|
Report | The newly generated report |
GetProjectReports()
Returns the project reports list
Declaration
public List<Report> GetProjectReports()
Returns
Type | Description |
---|---|
System.Collections.Generic.List<Report> | List of reports |
GetReportDefinition(String)
Returns the report definition
Declaration
public ReportDefinition GetReportDefinition(string taskTemplateId)
Parameters
Type | Name | Description |
---|---|---|
System.String | taskTemplateId | Task template Id |
Returns
Type | Description |
---|---|
ReportDefinition | The report definition |
GetReportRendering(Guid, String)
Returns the report rendering
Declaration
public byte[] GetReportRendering(Guid reportId, string fileExtension)
Parameters
Type | Name | Description |
---|---|---|
System.Guid | reportId | Report Id |
System.String | fileExtension | Report file extension |
Returns
Type | Description |
---|---|
System.Byte[] | The report content in the specified format |
GetReportRendering(Guid, String, String)
Returns the report rendering based on custom report template
Declaration
public byte[] GetReportRendering(Guid reportId, string customTemplate, string fileExtension)
Parameters
Type | Name | Description |
---|---|---|
System.Guid | reportId | Report Id |
System.String | customTemplate | Custom report template |
System.String | fileExtension | Report file extension |
Returns
Type | Description |
---|---|
System.Byte[] | The report content in the specified format |
GetReportRenderingSupportedFileFormats(Guid)
Returns the list of supported file extensions by the report rendering engine
Declaration
public List<string> GetReportRenderingSupportedFileFormats(Guid reportId)
Parameters
Type | Name | Description |
---|---|---|
System.Guid | reportId | Report Id |
Returns
Type | Description |
---|---|
System.Collections.Generic.List<System.String> | The list with supported file extensions |
RemoveReports(List<Guid>)
Remove a set of reports
Declaration
public void RemoveReports(List<Guid> reportIds)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.Generic.List<System.Guid> | reportIds | List of report Ids |
UpdateReport(Guid, String, String, String)
Update a report
Declaration
public void UpdateReport(Guid reportId, string name, string description, string data)
Parameters
Type | Name | Description |
---|---|---|
System.Guid | reportId | Report Id |
System.String | name | Report name |
System.String | description | Report description |
System.String | data | Report html data |