Show / Hide Table of Contents

Class ReportProvider

This archive provider is made for getting the available criteria for a given report. The report id is set when instanciating the object through the

Inheritance
Object
ReportProvider
Implements
IArchiveProvider
IArchiveProviderHasRows
IArchiveProviderHasColumns
IArchiveProviderHasEntities
Namespace: SuperOffice.CRM.ArchiveLists
Assembly: SoDataBase.dll
Syntax
[ArchiveProvider("ReportProvider", 1073741823)]
public class ReportProvider : Object, IArchiveProvider, IArchiveProviderHasRows, IArchiveProviderHasColumns, IArchiveProviderHasEntities, IPlugin

Constructors

ReportProvider(String)

This provider cannot be instanciated without it's input parameter.

Declaration
public ReportProvider(string id)
Parameters
Type Name Description
String id

If this parameter (even though it's a string) does not parse into an integer, subsequent calls to GetAvailableColumns will couse an exception to be thrown. The way to propperly instanciate a ReportProvider with an id is through the ArchiveProviderFactory

int exampleReportId = 13 ; //this is just an example of a possible report id

//This will create a ReportProvider with the report id 13. 
IArchiveProvider reportProvider = ArchiveProviderFactory.Create(ReportProvider.ProviderName + ReportProvider.ReportIdDelimiter + exampleReportId.ToString()); 

Fields

ProviderName

This archive provider is made for getting the available criteria for a given report. The report id is set when instanciating the object through the

Declaration
public const string ProviderName = "ReportProvider"
Field Value
Type Description
String

ReportIdDelimiter

This archive provider is made for getting the available criteria for a given report. The report id is set when instanciating the object through the

Declaration
public const string ReportIdDelimiter = ":"
Field Value
Type Description
String

Methods

Close()

ReportProvider is meant to be used as a provider for getting the available columns (criteria) for a given report. You are not able to close it.

Declaration
public void Close()

GetAvailableColumns()

This method returns the available criteria for the report id this provider in instanciated with.

Declaration
public List<ArchiveColumnInfo> GetAvailableColumns()
Returns
Type Description
List<ArchiveColumnInfo>

A list of ArchiveColumnInfo objects reprsenting the available criteria.

GetAvailableEntities()

Get the list of entities supported by this provider

Declaration
public List<ArchiveRowTypeInfo> GetAvailableEntities()
Returns
Type Description
List<ArchiveRowTypeInfo>

The list of entities

GetReader(String)

Start the provider, returning an IDataReader compatible object to the client for row enumeration and data access

Declaration
public virtual IDataReader GetReader(string options)
Parameters
Type Name Description
String options

Options, passed to the internal GetRows method

Returns
Type Description
IDataReader

IDataReader primed to provide results

GetResultInformation()

This archive provider is made for getting the available criteria for a given report. The report id is set when instanciating the object through the

Declaration
public ArchiveResultInformation GetResultInformation()
Returns
Type Description
ArchiveResultInformation

GetRows(String)

ReportProvider is meant to be used as a provider for getting the available columns (criteria) for a given report. You are not able to get rows from this provider, only columns

Declaration
public IEnumerable<ArchiveRow> GetRows(string options)
Parameters
Type Name Description
String options
Returns
Type Description
IEnumerable<ArchiveRow>

SetDesiredColumns(String[])

ReportProvider is meant to be used as a provider for getting the available columns (criteria) for a given report. You are not able to set desired columns on this provider.

Declaration
public void SetDesiredColumns(params string[] columnIds)
Parameters
Type Name Description
String[] columnIds

SetDesiredEntities(String[])

ReportProvider is meant to be used as a provider for getting the available columns (criteria) for a given report. You are not able to set the desired enities.

Declaration
public void SetDesiredEntities(params string[] entities)
Parameters
Type Name Description
String[] entities

SetOrderBy(ArchiveOrderByInfo[])

ReportProvider is meant to be used as a provider for getting the available columns (criteria) for a given report. You are not able to set order by on this provider.

Declaration
public void SetOrderBy(params ArchiveOrderByInfo[] orderBy)
Parameters
Type Name Description
ArchiveOrderByInfo[] orderBy

SetPagingInfo(Int32, Int32)

ReportProvider is meant to be used as a provider for getting the available columns (criteria) for a given report. You are not able to set paging info on this provider.

Declaration
public void SetPagingInfo(int pageSize, int pageNumber)
Parameters
Type Name Description
Int32 pageSize
Int32 pageNumber

SetRestriction(ArchiveRestrictionInfo[])

ReportProvider is meant to be used as a provider for getting the available columns (criteria) for a given report. Therefor you are not able to set any restrictions

Declaration
public bool SetRestriction(ArchiveRestrictionInfo[] restrictions)
Parameters
Type Name Description
ArchiveRestrictionInfo[] restrictions
Returns
Type Description
Boolean

Implements

IArchiveProvider
IArchiveProviderHasRows
IArchiveProviderHasColumns
IArchiveProviderHasEntities

Extension Methods

EnumUtil.MapEnums<From, To>(From)
Converters.MapEnums<From, To>(From)
© SuperOffice. All rights reserved.
SuperOffice |  Community |  Release Notes |  Privacy |  Site feedback |  Search Docs |  About Docs |  Contribute |  Back to top