Free cookie consent management tool by TermsFeed Policy Generator

source: branches/DeploymentServer Prototype/HeuristicLab.Services/HeuristicLab.Services.Deployment.DataAccess/PluginDescription.cs @ 2771

Last change on this file since 2771 was 2771, checked in by gkronber, 14 years ago

Implemented and tested rudimentary WCF service interface on top of the Linq2Sql data access layer. #860

File size: 1.8 KB
Line 
1using System;
2using System.Collections.Generic;
3using System.Linq;
4using System.Text;
5using System.Runtime.Serialization;
6
7namespace HeuristicLab.Services.Deployment.DataAccess {
8  [DataContract(Name = "PluginDescription")]
9  public class PluginDescription {
10
11    [DataMember(Name = "Id")]
12    private long id;
13    internal long Id {
14      get {
15        return id;
16      }
17      set {
18        id = value;
19      }
20    }
21
22    [DataMember(Name = "Name")]
23    private string name;
24    public string Name {
25      get { return name; }
26    }
27
28    [DataMember(Name = "Version")]
29    private Version version;
30    public Version Version {
31      get { return version; }
32    }
33
34
35    [DataMember(Name = "Dependencies")]
36    private List<PluginDescription> dependencies;
37    public List<PluginDescription> Dependencies {
38      get { return dependencies; }
39    }
40
41    //[DataMember(Name = "IsDatabaseInstance")]
42    //private bool isDatabaseInstance;
43    //internal bool IsDatabaseInstance {
44    //  get {
45    //    return isDatabaseInstance;
46    //  }
47    //}
48
49    internal PluginDescription(long id, string name, Version version, IEnumerable<PluginDescription> dependencies) {
50      this.id = id;
51      this.name = name;
52      this.version = version;
53      this.dependencies = new List<PluginDescription>(dependencies); //.AsReadOnly();
54      //this.isDatabaseInstance = true;
55    }
56
57    public PluginDescription(string name, Version version, IEnumerable<PluginDescription> dependencies)
58      : this(0, name, version, dependencies) {
59      //this.isDatabaseInstance = false;
60    }
61
62    public PluginDescription(string name, Version version)
63      : this(name, version, Enumerable.Empty<PluginDescription>()) {
64      //this.isDatabaseInstance = false;
65    }
66  }
67}
Note: See TracBrowser for help on using the repository browser.