LEADTOOLS Cloud (Leadtools.Services.Cloud.ServiceContracts assembly)
LEAD Technologies, Inc

GetClientJobs Method

Example 





A Leadtools.Services.Cloud.DataContracts.GetClientJobsRequest class containing the client (user) information.
Retrieves all jobs from the cloud for the specified client (user).
Syntax
[OperationContractAttribute()]
[FaultContractAttribute(DetailType=Leadtools.Services.Cloud.FaultContracts.CloudFault, 
   Action="", 
   Name="", 
   Namespace="", 
   ProtectionLevel=ProtectionLevel.None, 
   HasProtectionLevel=false)]
GetClientJobsResponse GetClientJobs( 
   GetClientJobsRequest request
)
'Declaration
 
<OperationContractAttribute()>
<FaultContractAttribute(DetailType=Leadtools.Services.Cloud.FaultContracts.CloudFault, 
   Action="", 
   Name="", 
   Namespace="", 
   ProtectionLevel=ProtectionLevel.None, 
   HasProtectionLevel=False)>
Function GetClientJobs( _
   ByVal request As GetClientJobsRequest _
) As GetClientJobsResponse
'Usage
 
Dim instance As IJobService
Dim request As GetClientJobsRequest
Dim value As GetClientJobsResponse
 
value = instance.GetClientJobs(request)
[OperationContractAttribute()]
[FaultContractAttribute(DetailType=Leadtools.Services.Cloud.FaultContracts.CloudFault, 
   Action="", 
   Name="", 
   Namespace="", 
   ProtectionLevel=ProtectionLevel.None, 
   HasProtectionLevel=false)]
GetClientJobsResponse GetClientJobs( 
   GetClientJobsRequest request
)
OperationContractAttribute()
FaultContractAttribute(DetailType=Leadtools.Services.Cloud.FaultContracts.CloudFault, 
   Action="", 
   Name="", 
   Namespace="", 
   ProtectionLevel=ProtectionLevel.None, 
   HasProtectionLevel=)
function Leadtools.Services.Cloud.ServiceContracts.IJobService.GetClientJobs( 
   request 
)
[OperationContractAttribute()]
[FaultContractAttribute(DetailType=Leadtools.Services.Cloud.FaultContracts.CloudFault, 
   Action="", 
   Name="", 
   Namespace="", 
   ProtectionLevel=ProtectionLevel.None, 
   HasProtectionLevel=false)]
GetClientJobsResponse^ GetClientJobs( 
   GetClientJobsRequest^ request
) 

Parameters

request
A Leadtools.Services.Cloud.DataContracts.GetClientJobsRequest class containing the client (user) information.

Return Value

A Leadtools.Services.Cloud.DataContracts.GetClientJobsResponse class containing all jobs for the specified user.
Remarks

Use this method to retrieve all jobs for a given user. This method will return all jobs with a matching value in the cUserToken column. The Leadtools.Services.Cloud.DataContracts.GetClientJobsResponse class will contain an array of all job IDs matching the specified user token. If no matching jobs are found, a zero length array is returned.

Example
 
Public Sub GetClientJobs()
   Using jobServiceClient As JobServiceClient = New JobServiceClient()
      'Get all the jobs with a user token of "user1".
      Dim getClientJobsRequest As GetClientJobsRequest = New GetClientJobsRequest()
      getClientJobsRequest.UserToken = "User2"
      Dim getClientJobsResponse As GetClientJobsResponse = jobServiceClient.GetClientJobs(getClientJobsRequest)
      For Each jobID As String In getClientJobsResponse.JobsIds
         Console.WriteLine(String.Format("ID = {0}", jobID))
      Next jobID
   End Using
End Sub
public void GetClientJobs()
{
   using (JobServiceClient jobServiceClient = new JobServiceClient())
   {
      //Get all the jobs with a user token of "user1".
      GetClientJobsRequest getClientJobsRequest = new GetClientJobsRequest();
      getClientJobsRequest.UserToken = "User2";
      GetClientJobsResponse getClientJobsResponse = jobServiceClient.GetClientJobs(getClientJobsRequest);
      foreach (string jobID in getClientJobsResponse.JobsIds)
         Console.WriteLine(String.Format("ID = {0}", jobID));
   }
}
Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also

Reference

IJobService Interface
IJobService Members
Programming with Leadtools Cloud SDK
Understanding The LEADTOOLS Cloud Database

 

 


Products | Support | Contact Us | Copyright Notices

© 2006-2012 All Rights Reserved. LEAD Technologies, Inc.