ProjectOperationsRollingWave Method |
Run the Rolling Wave.
Namespace: Cobra.WebService.ClientAPI.Application.FilesAssembly: Cobra.WebService.ClientAPI (in Cobra.WebService.ClientAPI.dll) Version: 8.7.700.3793 (8.7.0700.3793)
Syntaxpublic ServiceResult RollingWave(
RollingWaveServiceArguments rollingWaveServiceArguments
)
Parameters
- rollingWaveServiceArguments RollingWaveServiceArguments
- An instance of RollingWaveServiceArguments class that contains the options to run the Rolling Wave.
Return Value
ServiceResultThe result of running Rolling Wave.
Exceptions| Exception | Condition |
|---|
| InvalidOperationException | Thrown when state of the instance of the CobraServices that generated the current ProjectOperations is not in opened state. |
Example
This sample shows how to run the Rolling Wave.
using Cobra.WebService.ClientAPI;
using Cobra.WebService.ClientAPI.Client;
using Cobra.WebService.ClientAPI.Application.Files;
.
.
.
CobraServices cobraServices = new CobraServices();
cobraServices.ServiceIdentityData.Username = "SYSADMIN";
cobraServices.ServiceIdentityData.SecurePassword = new SecurePassword();
cobraServices.ServiceIdentityData.SecurePassword.AppendChar('P');
cobraServices.ServiceIdentityData.SecurePassword.AppendChar('A');
cobraServices.ServiceIdentityData.SecurePassword.AppendChar('S');
cobraServices.ServiceIdentityData.SecurePassword.AppendChar('S');
cobraServices.ServiceIdentityData.SecurePassword.AppendChar('W');
cobraServices.ServiceIdentityData.SecurePassword.AppendChar('O');
cobraServices.ServiceIdentityData.SecurePassword.AppendChar('R');
cobraServices.ServiceIdentityData.SecurePassword.AppendChar('D');
cobraServices.ServiceIdentityData.DataSourceKey = "COBRA";
LoginResult loginResult = cobraServices.Login();
if (!loginResult.Success) {
Console.WriteLine("Login failed.");
return;
}
Console.WriteLine("Login Success.");
ProjectOperations projectOperations = cobraServices.CreateServiceOperations<ProjectOperations>();
RollingWaveServiceArguments rollingWaveServiceArguments = projectOperations.CreateProjectOperationsServiceArguments<RollingWaveServiceArguments>();
rollingWaveServiceArguments.Project = "Demo";
rollingWaveServiceArguments.CollapseAllPeriods = true;
Console.WriteLine("Running Rolling Wave...");
ServiceResult rollingWaveResult = projectOperations.RollingWave(rollingWaveServiceArguments);
if (rollingWaveResult.Success)
Console.WriteLine("Rolling Wave process completed successfully.");
else
Console.WriteLine("Rolling Wave process did not completed successfully.");
cobraServices.LogOut();
See Also