Free cookie consent management tool by TermsFeed Policy Generator

Changeset 791 for trunk


Ignore:
Timestamp:
11/20/08 15:45:16 (16 years ago)
Author:
whackl
Message:

refactored the Client to ClientInfo (#378)

Location:
trunk/sources
Files:
8 edited

Legend:

Unmodified
Added
Removed
  • trunk/sources/HeuristicLab.Hive.Client.Communication/ServerProxy.cs

    r790 r791  
    1010
    1111    [System.ServiceModel.OperationContractAttribute(Action = "http://tempuri.org/IClientCommunicator/Login", ReplyAction = "http://tempuri.org/IClientCommunicator/LoginResponse")]
    12     HeuristicLab.Hive.Contracts.Response Login(HeuristicLab.Hive.Contracts.BusinessObjects.Client clientInfo);
     12    HeuristicLab.Hive.Contracts.Response Login(HeuristicLab.Hive.Contracts.BusinessObjects.ClientInfo clientInfo);
    1313
    1414    [System.ServiceModel.OperationContractAttribute(AsyncPattern = true, Action = "http://tempuri.org/IClientCommunicator/Login", ReplyAction = "http://tempuri.org/IClientCommunicator/LoginResponse")]
    15     System.IAsyncResult BeginLogin(HeuristicLab.Hive.Contracts.BusinessObjects.Client clientInfo, System.AsyncCallback callback, object asyncState);
     15    System.IAsyncResult BeginLogin(HeuristicLab.Hive.Contracts.BusinessObjects.ClientInfo clientInfo, System.AsyncCallback callback, object asyncState);
    1616
    1717    HeuristicLab.Hive.Contracts.Response EndLogin(System.IAsyncResult result);
     
    212212    public event System.EventHandler<LogoutCompletedEventArgs> LogoutCompleted;
    213213
    214     public HeuristicLab.Hive.Contracts.Response Login(HeuristicLab.Hive.Contracts.BusinessObjects.Client clientInfo) {
     214    public HeuristicLab.Hive.Contracts.Response Login(HeuristicLab.Hive.Contracts.BusinessObjects.ClientInfo clientInfo) {
    215215      return base.Channel.Login(clientInfo);
    216216    }
    217217
    218218    [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)]
    219     public System.IAsyncResult BeginLogin(HeuristicLab.Hive.Contracts.BusinessObjects.Client clientInfo, System.AsyncCallback callback, object asyncState) {
     219    public System.IAsyncResult BeginLogin(HeuristicLab.Hive.Contracts.BusinessObjects.ClientInfo clientInfo, System.AsyncCallback callback, object asyncState) {
    220220      return base.Channel.BeginLogin(clientInfo, callback, asyncState);
    221221    }
     
    227227
    228228    private System.IAsyncResult OnBeginLogin(object[] inValues, System.AsyncCallback callback, object asyncState) {
    229       HeuristicLab.Hive.Contracts.BusinessObjects.Client clientInfo = ((HeuristicLab.Hive.Contracts.BusinessObjects.Client)(inValues[0]));
     229      HeuristicLab.Hive.Contracts.BusinessObjects.ClientInfo clientInfo = ((HeuristicLab.Hive.Contracts.BusinessObjects.ClientInfo)(inValues[0]));
    230230      return this.BeginLogin(clientInfo, callback, asyncState);
    231231    }
     
    244244    }
    245245
    246     public void LoginAsync(HeuristicLab.Hive.Contracts.BusinessObjects.Client clientInfo) {
     246    public void LoginAsync(HeuristicLab.Hive.Contracts.BusinessObjects.ClientInfo clientInfo) {
    247247      this.LoginAsync(clientInfo, null);
    248248    }
    249249
    250     public void LoginAsync(HeuristicLab.Hive.Contracts.BusinessObjects.Client clientInfo, object userState) {
     250    public void LoginAsync(HeuristicLab.Hive.Contracts.BusinessObjects.ClientInfo clientInfo, object userState) {
    251251      if ((this.onBeginLoginDelegate == null)) {
    252252        this.onBeginLoginDelegate = new BeginOperationDelegate(this.OnBeginLogin);
  • trunk/sources/HeuristicLab.Hive.Client.Core/Core.cs

    r790 r791  
    6464      beat.StartHeartbeat();
    6565
    66       BO.Client clientInfo = new BO.Client { ClientId = Guid.NewGuid() };
     66      BO.ClientInfo clientInfo = new BO.ClientInfo { ClientId = Guid.NewGuid() };
    6767
    6868      ClientCommunicatorClient clientCommunicator = ServiceLocator.GetClientCommunicator();
  • trunk/sources/HeuristicLab.Hive.Contracts/BusinessObjects/Client.cs

    r751 r791  
    3131
    3232  [DataContract]
    33   public class Client : Resource {
     33  public class ClientInfo : Resource {
    3434    [DataMember]
    3535    public Guid ClientId { get; set; }
  • trunk/sources/HeuristicLab.Hive.Contracts/BusinessObjects/Job.cs

    r780 r791  
    3535    public State State { get; set; }
    3636    [DataMember]
    37     public Client Client { get; set; }
     37    public ClientInfo Client { get; set; }
    3838    [DataMember]
    3939    public Job parentJob { get; set; }
  • trunk/sources/HeuristicLab.Hive.Contracts/BusinessObjects/JobResult.cs

    r751 r791  
    3535    public String Result { get; set; } // TODO DataStructure for Result needs to be defined
    3636    [DataMember]
    37     public Client Client { get; set; }
     37    public ClientInfo Client { get; set; }
    3838
    3939  }
  • trunk/sources/HeuristicLab.Hive.Contracts/BusinessObjects/UpTimeStatistics.cs

    r751 r791  
    3131  public class UpTimeStatistics {
    3232    [DataMember]
    33     public Client Client { get; set; }
     33    public ClientInfo Client { get; set; }
    3434    [DataMember]
    3535    public DateTime Login { get; set; }
  • trunk/sources/HeuristicLab.Hive.Contracts/Interfaces/IClientCommunicator.cs

    r780 r791  
    3434  public interface IClientCommunicator {
    3535    [OperationContract]
    36     Response Login(Client clientInfo);
     36    Response Login(ClientInfo clientInfo);
    3737    [OperationContract]
    3838    ResponseHB SendHeartBeat(HeartBeatData hbData);
  • trunk/sources/HeuristicLab.Hive.Server.Core/ClientCommunicator.cs

    r786 r791  
    1212  /// </summary>
    1313  public class ClientCommunicator: IClientCommunicator {
    14     List<Client> clients;
     14    List<ClientInfo> clients;
    1515    List<long> jobs;
    1616    int nrOfJobs = 10;
     
    2525    #region IClientCommunicator Members
    2626
    27     public Response Login(Client clientInfo) {
     27    public Response Login(ClientInfo clientInfo) {
    2828      if (clients == null)
    29         clients = new List<Client>();
     29        clients = new List<ClientInfo>();
    3030
    3131      clients.Add(clientInfo);
     
    7272    public Response Logout(Guid clientId) {
    7373      bool clientRemoved = false;
    74       foreach (Client client in clients) {
     74      foreach (ClientInfo client in clients) {
    7575        if (client.ClientId.Equals(clientId)) {
    7676          clients.Remove(client);
Note: See TracChangeset for help on using the changeset viewer.