Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
12/16/08 17:26:43 (16 years ago)
Author:
svonolfe
Message:

Refactored DAL, Improved Caching (#372)

Location:
trunk/sources/HeuristicLab.Hive.Contracts
Files:
1 added
10 edited

Legend:

Unmodified
Added
Removed
  • trunk/sources/HeuristicLab.Hive.Contracts/BusinessObjects/Client.cs

    r842 r995  
    2828namespace HeuristicLab.Hive.Contracts.BusinessObjects {
    2929
    30   public enum State { idle, calculating, offline };
     30  public enum State { nullState, idle, calculating, offline };
    3131
    3232  [DataContract]
  • trunk/sources/HeuristicLab.Hive.Contracts/BusinessObjects/ClientConfig.cs

    r795 r995  
    2929
    3030  [DataContract]
    31   public class ClientConfig {
     31  public class ClientConfig: IHiveObject {
    3232    [DataMember]
    33     public long ClientConfigId { get; set; }
     33    public long Id { get; set; }
    3434    [DataMember]
    3535    public String UpDownTimeCalendar { get; set; } // TODO define DataStructure
  • trunk/sources/HeuristicLab.Hive.Contracts/BusinessObjects/GrantedPermissions.cs

    r795 r995  
    2929 
    3030  [DataContract]
    31   public class GrantedPermissions {
     31  public class GrantedPermissions: IHiveObject {
    3232    [DataMember]
    33     public long GrantedPermissionsId { get; set; }
     33    public long Id { get; set; }
    3434    [DataMember]
    3535    public Permission Permission { get; set; }
  • trunk/sources/HeuristicLab.Hive.Contracts/BusinessObjects/Job.cs

    r967 r995  
    2929
    3030  [DataContract]
    31   public class Job {
     31  public class Job: IHiveObject {
    3232    [DataMember]
    33     public long JobId { get; set; }
     33    public long Id { get; set; }
    3434    [DataMember]
    3535    public State State { get; set; }
     
    3838    [DataMember]
    3939    public Job ParentJob { get; set; }
     40
     41    public override bool Equals(object obj) {
     42      if (obj is Job) {
     43        return (obj as Job).Id.Equals(Id);
     44      } else     
     45        return base.Equals(obj);
     46    }
     47
     48    public override int GetHashCode() {
     49      return Id.GetHashCode();
     50    }
    4051  }
    4152}
  • trunk/sources/HeuristicLab.Hive.Contracts/BusinessObjects/JobResult.cs

    r967 r995  
    2929
    3030  [DataContract]
    31   public class JobResult {
     31  public class JobResult: IHiveObject {
    3232    [DataMember]
    33     public long JobResultId { get; set; }
     33    public long Id { get; set; }
    3434    [DataMember]
    3535    public long JobId { get; set; }
  • trunk/sources/HeuristicLab.Hive.Contracts/BusinessObjects/Permission.cs

    r795 r995  
    2929
    3030  [DataContract]
    31   public class Permission {
     31  public class Permission: IHiveObject {
    3232    [DataMember]
    33     public long PermissionId { get; set; }
     33    public long Id { get; set; }
    3434    [DataMember]
    3535    public String Name { get; set; }
  • trunk/sources/HeuristicLab.Hive.Contracts/BusinessObjects/PermissionOwner.cs

    r939 r995  
    2929
    3030  [DataContract]
    31   public class PermissionOwner {
     31  public class PermissionOwner: IHiveObject {
    3232    [DataMember]
    33     public long PermissionOwnerId { get; set; }
     33    public long Id { get; set; }
    3434    [DataMember]
    3535    public string Name { get; set; }
     
    3737    public override bool Equals(object obj) {
    3838      if (obj is PermissionOwner)
    39         return this.PermissionOwnerId.Equals(
    40           (obj as PermissionOwner).PermissionOwnerId);
     39        return this.Id.Equals(
     40          (obj as PermissionOwner).Id);
    4141      else
    4242        return base.Equals(obj);
     
    4444
    4545    public override int GetHashCode() {
    46       return this.PermissionOwnerId.GetHashCode();
     46      return this.Id.GetHashCode();
    4747    }
    4848  }
  • trunk/sources/HeuristicLab.Hive.Contracts/BusinessObjects/Resource.cs

    r827 r995  
    2929
    3030  [DataContract]
    31   public class Resource {
     31  public class Resource: IHiveObject {
    3232    [DataMember]
    33     public long ResourceId { get; set; }
     33    public long Id { get; set; }
    3434    [DataMember]
    3535    public string Name { get; set; }
    3636
     37    public override bool Equals(object obj) {
     38      if (obj is Resource)
     39        return (obj as Resource).Id.Equals(Id);
     40      else
     41        return base.Equals(obj);
     42    }
     43
     44    public override int GetHashCode() {
     45      return Id.GetHashCode();
     46    }
    3747  }
    3848}
  • trunk/sources/HeuristicLab.Hive.Contracts/BusinessObjects/UpTimeStatistics.cs

    r795 r995  
    2929
    3030  [DataContract]
    31   public class UpTimeStatistics {
     31  public class UpTimeStatistics: IHiveObject {
    3232    [DataMember]
    33     public long UpTimeStatisticsId { get; set; }
     33    public long Id { get; set; }
    3434    [DataMember]
    3535    public ClientInfo Client { get; set; }
  • trunk/sources/HeuristicLab.Hive.Contracts/HeuristicLab.Hive.Contracts.csproj

    r952 r995  
    7474    <Compile Include="BusinessObjects\ClientGroup.cs" />
    7575    <Compile Include="BusinessObjects\HeartBeatData.cs" />
     76    <Compile Include="BusinessObjects\IHiveObject.cs" />
    7677    <Compile Include="BusinessObjects\Job.cs" />
    7778    <Compile Include="BusinessObjects\JobResult.cs" />
Note: See TracChangeset for help on using the changeset viewer.