Class
RepositoryDataBus

Definition

Namespace:ArtOfTest.WebAii.Design.Repository

Assembly:ArtOfTest.WebAii.Design.dll

Syntax:

cs-api-definition
public class RepositoryDataBus : IRepositoryDataBus

Inheritance: objectRepositoryDataBus

Implements: IRepositoryDataBus

Constructors

RepositoryDataBus(IExtendedRepositoryFactory)

Declaration

cs-api-definition
public RepositoryDataBus(IExtendedRepositoryFactory repositoryFactory)

Parameters

repositoryFactory

IExtendedRepositoryFactory

RepositoryDataBus(IExtendedRepositoryFactory, IFileReaderWriterSync)

Declaration

cs-api-definition
public RepositoryDataBus(IExtendedRepositoryFactory repositoryFactory, IFileReaderWriterSync fileReaderWriter)

Parameters

repositoryFactory

IExtendedRepositoryFactory

fileReaderWriter

IFileReaderWriterSync

Fields

DataPrefix

Declaration

cs-api-definition
public const string DataPrefix = "Data."

Field Value

string

ValuePrefix

Declaration

cs-api-definition
public const string ValuePrefix = "Data.__value."

Field Value

string

Properties

RepositoryFactory

Updatable IExtendedRepositoryFactory (in case the user switches storage creds)

Declaration

cs-api-definition
public IExtendedRepositoryFactory RepositoryFactory { get; set; }

Property Value

IExtendedRepositoryFactory

Implements IRepositoryDataBus.RepositoryFactory

Methods

DeleteReportDefinition(Guid)

Deletes a ReportDefinition

Declaration

cs-api-definition
public Task<bool> DeleteReportDefinition(Guid definitionId)

Parameters

definitionId

Guid

Returns

Task<bool>

True if delete was successful

Implements IRepositoryDataBus.DeleteReportDefinition(Guid)

DeleteTopLevelTestListResults(string)

Declaration

cs-api-definition
public Task DeleteTopLevelTestListResults(string documentId)

Parameters

documentId

string

Returns

Task

Implements IRepositoryDataBus.DeleteTopLevelTestListResults(string)

DownloadLightProjectsAsync()

Uses a Cloud Storage repo to download all projects as light objects

Declaration

cs-api-definition
public Task<IStorageCollection<IStorageDocument<LightProjectTransport>>> DownloadLightProjectsAsync()

Returns

Task<IStorageCollection<IStorageDocument<LightProjectTransport>>>

Implements IRepositoryDataBus.DownloadLightProjectsAsync()

DownloadLightRunResultsForTestListRun(Guid, int, int, string)

Declaration

cs-api-definition
public Task<IStorageCollection<IStorageDocument<LightRunResultTransport>>> DownloadLightRunResultsForTestListRun(Guid testListRunId, int skip = 0, int take = 0, string sort = null)

Parameters

testListRunId

Guid

skip

int

take

int

sort

string

Returns

Task<IStorageCollection<IStorageDocument<LightRunResultTransport>>>

Implements IRepositoryDataBus.DownloadLightRunResultsForTestListRun(Guid, int, int, string)

DownloadLightTestListResultsForTestList(Guid, int, int, string)

Declaration

cs-api-definition
public Task<IStorageCollection<IStorageDocument<LightTestListResultTransport>>> DownloadLightTestListResultsForTestList(Guid testListId, int skip = 0, int take = 0, string sort = null)

Parameters

testListId

Guid

skip

int

take

int

sort

string

Returns

Task<IStorageCollection<IStorageDocument<LightTestListResultTransport>>>

Implements IRepositoryDataBus.DownloadLightTestListResultsForTestList(Guid, int, int, string)

DownloadLightTestListsByProjectIdAsync(Guid)

Uses a Cloud Storage repo to download light transports for all test lists in a single project

Declaration

cs-api-definition
public Task<IStorageCollection<IStorageDocument<LightTestListTransport>>> DownloadLightTestListsByProjectIdAsync(Guid projectId)

Parameters

projectId

Guid

The id of project

Returns

Task<IStorageCollection<IStorageDocument<LightTestListTransport>>>

A Storage Collection with all test lists

Implements IRepositoryDataBus.DownloadLightTestListsByProjectIdAsync(Guid)

DownloadLightTestListsForTestListIds(Guid[])

Uses a Cloud Storage repo to download light transports for all test lists from a list of test list ids

Declaration

cs-api-definition
public Task<IStorageCollection<IStorageDocument<LightTestListTransport>>> DownloadLightTestListsForTestListIds(Guid[] testListIds)

Parameters

testListIds

Guid[]

The list of test list ids

Returns

Task<IStorageCollection<IStorageDocument<LightTestListTransport>>>

A StorageCollection with all test lists

Implements IRepositoryDataBus.DownloadLightTestListsForTestListIds(Guid[])

DownloadLightTestsAsync(Guid)

Uses a Cloud Storage repo to download LightTests filtered by Project ID and test type

Declaration

cs-api-definition
public Task<IQueryable<IStorageDocument<LightTestTransport>>> DownloadLightTestsAsync(Guid projectId)

Parameters

projectId

Guid

Returns

Task<IQueryable<IStorageDocument<LightTestTransport>>>

Implements IRepositoryDataBus.DownloadLightTestsAsync(Guid)

DownloadMinimalTransportById<T>(Guid)

Wrapper around ProjectCloudStorageRepositoryFactory.CreateLightweightRepository

Declaration

cs-api-definition
public Task<IStorageDocument<MinimalTransport>> DownloadMinimalTransportById<T>(Guid id) where T : class, IDataTransport

Parameters

id

Guid

Returns

Task<IStorageDocument<MinimalTransport>>

Implements IRepositoryDataBus.DownloadMinimalTransportById<T>(Guid)

DownloadPerfResultsAsync(Guid)

Uses a Cloud Storage repo to download perf results filtered by test ID

Declaration

cs-api-definition
public Task<IQueryable<IStorageDocument<ResultsFileXmlRoot>>> DownloadPerfResultsAsync(Guid testId)

Parameters

testId

Guid

Returns

Task<IQueryable<IStorageDocument<ResultsFileXmlRoot>>>

Implements IRepositoryDataBus.DownloadPerfResultsAsync(Guid)

DownloadProjectByIdAsync(string)

Direct single project request from the repo

Declaration

cs-api-definition
public Task<IStorageDocument<Project>> DownloadProjectByIdAsync(string documentId)

Parameters

documentId

string

Returns

Task<IStorageDocument<Project>>

Implements IRepositoryDataBus.DownloadProjectByIdAsync(string)

DownloadProjectByTestStudioIdAsync(Guid)

Declaration

cs-api-definition
public Task<IStorageDocument<Project>> DownloadProjectByTestStudioIdAsync(Guid projectId)

Parameters

projectId

Guid

Returns

Task<IStorageDocument<Project>>

Implements IRepositoryDataBus.DownloadProjectByTestStudioIdAsync(Guid)

DownloadProjectsAsync()

Direct all projects request from the repo

Declaration

cs-api-definition
public Task<IQueryable<IStorageDocument<Project>>> DownloadProjectsAsync()

Returns

Task<IQueryable<IStorageDocument<Project>>>

All projects from the repo

Implements IRepositoryDataBus.DownloadProjectsAsync()

DownloadReportDefinitionByIdAsync(Guid)

Uses a Cloud Storage repo to download a report definition by id

Declaration

cs-api-definition
public Task<IStorageDocument<ReportDefinition>> DownloadReportDefinitionByIdAsync(Guid id)

Parameters

id

Guid

Returns

Task<IStorageDocument<ReportDefinition>>

Implements IRepositoryDataBus.DownloadReportDefinitionByIdAsync(Guid)

DownloadReportDefinitionsForProjectAsync(Guid)

Uses a Cloud Storage repo to download all report definitions for a single project

Declaration

cs-api-definition
public Task<IStorageCollection<IStorageDocument<ReportDefinition>>> DownloadReportDefinitionsForProjectAsync(Guid projectId)

Parameters

projectId

Guid

Returns

Task<IStorageCollection<IStorageDocument<ReportDefinition>>>

Implements IRepositoryDataBus.DownloadReportDefinitionsForProjectAsync(Guid)

DownloadRunResultsCounters(Guid[], DateTime, DateTime)

Declaration

cs-api-definition
public Task<IQueryable<IStorageDocument<RunResultCountersTransport>>> DownloadRunResultsCounters(Guid[] testListIds, DateTime fromStartDate, DateTime toStartDate)

Parameters

testListIds

Guid[]

fromStartDate

DateTime

toStartDate

DateTime

Returns

Task<IQueryable<IStorageDocument<RunResultCountersTransport>>>

Implements IRepositoryDataBus.DownloadRunResultsCounters(Guid[], DateTime, DateTime)

DownloadRunResultsForTestListRun(Guid, int, int, string)

Declaration

cs-api-definition
public Task<IStorageCollection<IStorageDocument<RunResult>>> DownloadRunResultsForTestListRun(Guid dispatchGroupId, int skip = 0, int take = 0, string sort = null)

Parameters

dispatchGroupId

Guid

skip

int

take

int

sort

string

Returns

Task<IStorageCollection<IStorageDocument<RunResult>>>

Implements IRepositoryDataBus.DownloadRunResultsForTestListRun(Guid, int, int, string)

DownloadSingleTestRunResultsForTestListRun(Guid, int, int, string)

Declaration

cs-api-definition
public Task<IStorageCollection<IStorageDocument<LightRunResultSingleTestTransport>>> DownloadSingleTestRunResultsForTestListRun(Guid dispatchGroupId, int skip = 0, int take = 0, string sort = null)

Parameters

dispatchGroupId

Guid

skip

int

take

int

sort

string

Returns

Task<IStorageCollection<IStorageDocument<LightRunResultSingleTestTransport>>>

Implements IRepositoryDataBus.DownloadSingleTestRunResultsForTestListRun(Guid, int, int, string)

DownloadTestByIdAsync(Guid)

Uses a Cloud Storage repo to download a single test

Declaration

cs-api-definition
public Task<IStorageDocument<TestBase>> DownloadTestByIdAsync(Guid testId)

Parameters

testId

Guid

Returns

Task<IStorageDocument<TestBase>>

Implements IRepositoryDataBus.DownloadTestByIdAsync(Guid)

DownloadTestIdByPathAsync(Guid, string)

Uses a Cloud Storage repo to download a single test

Declaration

cs-api-definition
public Task<IStorageDocument<TestIdTransport>> DownloadTestIdByPathAsync(Guid projectId, string path)

Parameters

projectId

Guid

path

string

Returns

Task<IStorageDocument<TestIdTransport>>

Implements IRepositoryDataBus.DownloadTestIdByPathAsync(Guid, string)

DownloadTestListByIdAsync(Guid)

Uses a Cloud Storage repo to download a single test list

Declaration

cs-api-definition
public Task<IStorageDocument<TestList>> DownloadTestListByIdAsync(Guid testListId)

Parameters

testListId

Guid

The test list id

Returns

Task<IStorageDocument<TestList>>

Implements IRepositoryDataBus.DownloadTestListByIdAsync(Guid)

DownloadTestListsAsync(Guid)

Uses a Cloud Storage repo to download test lists filtered by Project ID

Declaration

cs-api-definition
public Task<IQueryable<IStorageDocument<TestList>>> DownloadTestListsAsync(Guid projectId)

Parameters

projectId

Guid

Returns

Task<IQueryable<IStorageDocument<TestList>>>

Implements IRepositoryDataBus.DownloadTestListsAsync(Guid)

DownloadTestsAsync(Guid)

Uses a Cloud Storage repo to download tests filtered by Project ID

Declaration

cs-api-definition
public Task<IQueryable<IStorageDocument<TestBase>>> DownloadTestsAsync(Guid projectId)

Parameters

projectId

Guid

Returns

Task<IQueryable<IStorageDocument<TestBase>>>

Implements IRepositoryDataBus.DownloadTestsAsync(Guid)

DownloadTestsExcludingLoadAsync(Guid)

Uses a Cloud Storage repo to download tests filtered by Project ID excluding load tests

Declaration

cs-api-definition
public Task<IQueryable<IStorageDocument<TestBase>>> DownloadTestsExcludingLoadAsync(Guid projectId)

Parameters

projectId

Guid

Returns

Task<IQueryable<IStorageDocument<TestBase>>>

Implements IRepositoryDataBus.DownloadTestsExcludingLoadAsync(Guid)

DownloadTopLevelTestListResult(Guid)

Used to get just a single result.

Declaration

cs-api-definition
public Task<IStorageDocument<TestListResultTransport>> DownloadTopLevelTestListResult(Guid headerId)

Parameters

headerId

Guid

Returns

Task<IStorageDocument<TestListResultTransport>>

Implements IRepositoryDataBus.DownloadTopLevelTestListResult(Guid)

DownloadTopLevelTestListResults()

Declaration

cs-api-definition
public Task<IQueryable<IStorageDocument<TestListResultTransport>>> DownloadTopLevelTestListResults()

Returns

Task<IQueryable<IStorageDocument<TestListResultTransport>>>

Implements IRepositoryDataBus.DownloadTopLevelTestListResults()

DownloadTopLevelTestListResults(int, int, string)

Declaration

cs-api-definition
public Task<IStorageCollection<IStorageDocument<TestListResultTransport>>> DownloadTopLevelTestListResults(int skip = 0, int take = 0, string sort = null)

Parameters

skip

int

take

int

sort

string

Returns

Task<IStorageCollection<IStorageDocument<TestListResultTransport>>>

Implements IRepositoryDataBus.DownloadTopLevelTestListResults(int, int, string)

DownloadTopLevelTestListResultsForTestList(Guid, int, int, string)

Declaration

cs-api-definition
public Task<IStorageCollection<IStorageDocument<TestListResultTransport>>> DownloadTopLevelTestListResultsForTestList(Guid testListId, int skip = 0, int take = 0, string sort = null)

Parameters

testListId

Guid

skip

int

take

int

sort

string

Returns

Task<IStorageCollection<IStorageDocument<TestListResultTransport>>>

Implements IRepositoryDataBus.DownloadTopLevelTestListResultsForTestList(Guid, int, int, string)

DownloadTopLevelTestListResultsForTestListForPeriod(Guid, DateTime, DateTime, int, int, string)

Declaration

cs-api-definition
public Task<IStorageCollection<IStorageDocument<LightTestListResultTransport>>> DownloadTopLevelTestListResultsForTestListForPeriod(Guid testListId, DateTime fromStartDate, DateTime toStartDate, int skip = 0, int take = 0, string sort = null)

Parameters

testListId

Guid

fromStartDate

DateTime

toStartDate

DateTime

skip

int

take

int

sort

string

Returns

Task<IStorageCollection<IStorageDocument<LightTestListResultTransport>>>

Implements IRepositoryDataBus.DownloadTopLevelTestListResultsForTestListForPeriod(Guid, DateTime, DateTime, int, int, string)

DownloadTopLevelTestListResultsPerProject(Guid)

Declaration

cs-api-definition
public Task<IQueryable<IStorageDocument<TestListResultTransport>>> DownloadTopLevelTestListResultsPerProject(Guid projectId)

Parameters

projectId

Guid

Returns

Task<IQueryable<IStorageDocument<TestListResultTransport>>>

Implements IRepositoryDataBus.DownloadTopLevelTestListResultsPerProject(Guid)

UploadAsync(Project, IStorageDocument<Project>)

Uploads a Project via a Project Cloud Repository

Declaration

cs-api-definition
public Task UploadAsync(Project project, IStorageDocument<Project> cachedDocument)

Parameters

project

Project

cachedDocument

IStorageDocument<Project>

if we already downloaded a document, reuse it and do a PUT

Returns

Task

Implements IRepositoryDataBus.UploadAsync(Project, IStorageDocument<Project>)

UploadAsync(ReportDefinition)

Uploads a ReportDefinition via a ReportDefinition Cloud Repository

Declaration

cs-api-definition
public Task UploadAsync(ReportDefinition reportDefinition)

Parameters

reportDefinition

ReportDefinition

Returns

Task

Implements IRepositoryDataBus.UploadAsync(ReportDefinition)

UploadAsync(ResultsFileXmlRoot)

Uploads a ResultsFileXmlRoot via a ResultsFileXmlRoot Cloud Repository

Declaration

cs-api-definition
public Task UploadAsync(ResultsFileXmlRoot perfResult)

Parameters

perfResult

ResultsFileXmlRoot

Returns

Task

Implements IRepositoryDataBus.UploadAsync(ResultsFileXmlRoot)

UploadAsync(RunResult, bool)

Uploads a RunResult via a RunResult Cloud Repository

Declaration

cs-api-definition
public Task UploadAsync(RunResult runResult, bool newItemsOnly = false)

Parameters

runResult

RunResult

newItemsOnly

bool

Determines if we should query storage for an existing result to update or just simply add it

Returns

Task

Implements IRepositoryDataBus.UploadAsync(RunResult, bool)

UploadAsync(TestBase, IStorageDocument<TestBase>)

Uploads a Test via a TestBase Cloud Repository

Declaration

cs-api-definition
public Task UploadAsync(TestBase test, IStorageDocument<TestBase> cachedDocument)

Parameters

test

TestBase

cachedDocument

IStorageDocument<TestBase>

if we already downloaded a document, reuse it and do a PUT

Returns

Task

Implements IRepositoryDataBus.UploadAsync(TestBase, IStorageDocument<TestBase>)

UploadAsync(TestList, IStorageDocument<TestList>)

Uploads a TestList via a TestList Cloud Repository

Declaration

cs-api-definition
public Task UploadAsync(TestList testList, IStorageDocument<TestList> cachedDocument)

Parameters

testList

TestList

cachedDocument

IStorageDocument<TestList>

if we already downloaded a document, reuse it and do a PUT

Returns

Task

Implements IRepositoryDataBus.UploadAsync(TestList, IStorageDocument<TestList>)

UploadAsync(TestListResultTransport)

Declaration

cs-api-definition
public Task UploadAsync(TestListResultTransport testListRunHeader)

Parameters

testListRunHeader

TestListResultTransport

Returns

Task

Implements IRepositoryDataBus.UploadAsync(TestListResultTransport)

In this article
DefinitionConstructorsRepositoryDataBus(IExtendedRepositoryFactory)RepositoryDataBus(IExtendedRepositoryFactory, IFileReaderWriterSync)FieldsDataPrefixValuePrefixPropertiesRepositoryFactoryMethodsDeleteReportDefinition(Guid)DeleteTopLevelTestListResults(string)DownloadLightProjectsAsync()DownloadLightRunResultsForTestListRun(Guid, int, int, string)DownloadLightTestListResultsForTestList(Guid, int, int, string)DownloadLightTestListsByProjectIdAsync(Guid)DownloadLightTestListsForTestListIds(Guid[])DownloadLightTestsAsync(Guid)DownloadMinimalTransportById<T>(Guid)DownloadPerfResultsAsync(Guid)DownloadProjectByIdAsync(string)DownloadProjectByTestStudioIdAsync(Guid)DownloadProjectsAsync()DownloadReportDefinitionByIdAsync(Guid)DownloadReportDefinitionsForProjectAsync(Guid)DownloadRunResultsCounters(Guid[], DateTime, DateTime)DownloadRunResultsForTestListRun(Guid, int, int, string)DownloadSingleTestRunResultsForTestListRun(Guid, int, int, string)DownloadTestByIdAsync(Guid)DownloadTestIdByPathAsync(Guid, string)DownloadTestListByIdAsync(Guid)DownloadTestListsAsync(Guid)DownloadTestsAsync(Guid)DownloadTestsExcludingLoadAsync(Guid)DownloadTopLevelTestListResult(Guid)DownloadTopLevelTestListResults()DownloadTopLevelTestListResults(int, int, string)DownloadTopLevelTestListResultsForTestList(Guid, int, int, string)DownloadTopLevelTestListResultsForTestListForPeriod(Guid, DateTime, DateTime, int, int, string)DownloadTopLevelTestListResultsPerProject(Guid)UploadAsync(Project, IStorageDocument<Project>)UploadAsync(ReportDefinition)UploadAsync(ResultsFileXmlRoot)UploadAsync(RunResult, bool)UploadAsync(TestBase, IStorageDocument<TestBase>)UploadAsync(TestList, IStorageDocument<TestList>)UploadAsync(TestListResultTransport)
Not finding the help you need?
Contact Support