Free cookie consent management tool by TermsFeed Policy Generator

source: branches/HeuristicLab.Hive-3.4/sources/HeuristicLab.Services.Hive.DataAccess/3.4/HiveDataContext.designer.cs @ 5511

Last change on this file since 5511 was 5511, checked in by cneumuel, 13 years ago

#1233

  • added StateLog to log state transitions of hive jobs
  • added permissions to hive experiments (in data access layer, no UI for that yet)
  • extended unit tests
File size: 83.3 KB
Line 
1#pragma warning disable 1591
2//------------------------------------------------------------------------------
3// <auto-generated>
4//     This code was generated by a tool.
5//     Runtime Version:4.0.30319.208
6//
7//     Changes to this file may cause incorrect behavior and will be lost if
8//     the code is regenerated.
9// </auto-generated>
10//------------------------------------------------------------------------------
11
12namespace HeuristicLab.Services.Hive.DataAccess
13{
14  using System.Data.Linq;
15  using System.Data.Linq.Mapping;
16  using System.Data;
17  using System.Collections.Generic;
18  using System.Reflection;
19  using System.Linq;
20  using System.Linq.Expressions;
21  using System.ComponentModel;
22  using System;
23 
24 
25  [global::System.Data.Linq.Mapping.DatabaseAttribute(Name="HeuristicLab.Hive")]
26  public partial class HiveDataContext : System.Data.Linq.DataContext
27  {
28   
29    private static System.Data.Linq.Mapping.MappingSource mappingSource = new AttributeMappingSource();
30   
31    #region Extensibility Method Definitions
32    partial void OnCreated();
33    partial void InsertAssignedResource(AssignedResource instance);
34    partial void UpdateAssignedResource(AssignedResource instance);
35    partial void DeleteAssignedResource(AssignedResource instance);
36    partial void InsertPlugin(Plugin instance);
37    partial void UpdatePlugin(Plugin instance);
38    partial void DeletePlugin(Plugin instance);
39    partial void InsertRequiredPlugin(RequiredPlugin instance);
40    partial void UpdateRequiredPlugin(RequiredPlugin instance);
41    partial void DeleteRequiredPlugin(RequiredPlugin instance);
42    partial void InsertResource(Resource instance);
43    partial void UpdateResource(Resource instance);
44    partial void DeleteResource(Resource instance);
45    partial void InsertJob(Job instance);
46    partial void UpdateJob(Job instance);
47    partial void DeleteJob(Job instance);
48    partial void InsertUptimeCalendar(UptimeCalendar instance);
49    partial void UpdateUptimeCalendar(UptimeCalendar instance);
50    partial void DeleteUptimeCalendar(UptimeCalendar instance);
51    partial void InsertHiveExperiment(HiveExperiment instance);
52    partial void UpdateHiveExperiment(HiveExperiment instance);
53    partial void DeleteHiveExperiment(HiveExperiment instance);
54    partial void InsertJobData(JobData instance);
55    partial void UpdateJobData(JobData instance);
56    partial void DeleteJobData(JobData instance);
57    partial void InsertPluginData(PluginData instance);
58    partial void UpdatePluginData(PluginData instance);
59    partial void DeletePluginData(PluginData instance);
60    partial void InsertStateLog(StateLog instance);
61    partial void UpdateStateLog(StateLog instance);
62    partial void DeleteStateLog(StateLog instance);
63    partial void InsertHiveExperimentPermission(HiveExperimentPermission instance);
64    partial void UpdateHiveExperimentPermission(HiveExperimentPermission instance);
65    partial void DeleteHiveExperimentPermission(HiveExperimentPermission instance);
66    #endregion
67   
68    public HiveDataContext(string connection) :
69        base(connection, mappingSource)
70    {
71      OnCreated();
72    }
73   
74    public HiveDataContext(System.Data.IDbConnection connection) :
75        base(connection, mappingSource)
76    {
77      OnCreated();
78    }
79   
80    public HiveDataContext(string connection, System.Data.Linq.Mapping.MappingSource mappingSource) :
81        base(connection, mappingSource)
82    {
83      OnCreated();
84    }
85   
86    public HiveDataContext(System.Data.IDbConnection connection, System.Data.Linq.Mapping.MappingSource mappingSource) :
87        base(connection, mappingSource)
88    {
89      OnCreated();
90    }
91   
92    public System.Data.Linq.Table<AssignedResource> AssignedResources
93    {
94      get
95      {
96        return this.GetTable<AssignedResource>();
97      }
98    }
99   
100    public System.Data.Linq.Table<Plugin> Plugins
101    {
102      get
103      {
104        return this.GetTable<Plugin>();
105      }
106    }
107   
108    public System.Data.Linq.Table<RequiredPlugin> RequiredPlugins
109    {
110      get
111      {
112        return this.GetTable<RequiredPlugin>();
113      }
114    }
115   
116    public System.Data.Linq.Table<Resource> Resources
117    {
118      get
119      {
120        return this.GetTable<Resource>();
121      }
122    }
123   
124    public System.Data.Linq.Table<Job> Jobs
125    {
126      get
127      {
128        return this.GetTable<Job>();
129      }
130    }
131   
132    public System.Data.Linq.Table<UptimeCalendar> UptimeCalendars
133    {
134      get
135      {
136        return this.GetTable<UptimeCalendar>();
137      }
138    }
139   
140    public System.Data.Linq.Table<HiveExperiment> HiveExperiments
141    {
142      get
143      {
144        return this.GetTable<HiveExperiment>();
145      }
146    }
147   
148    public System.Data.Linq.Table<JobData> JobDatas
149    {
150      get
151      {
152        return this.GetTable<JobData>();
153      }
154    }
155   
156    public System.Data.Linq.Table<PluginData> PluginDatas
157    {
158      get
159      {
160        return this.GetTable<PluginData>();
161      }
162    }
163   
164    public System.Data.Linq.Table<StateLog> StateLogs
165    {
166      get
167      {
168        return this.GetTable<StateLog>();
169      }
170    }
171   
172    public System.Data.Linq.Table<HiveExperimentPermission> HiveExperimentPermissions
173    {
174      get
175      {
176        return this.GetTable<HiveExperimentPermission>();
177      }
178    }
179  }
180 
181  [global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.AssignedResources")]
182  public partial class AssignedResource : INotifyPropertyChanging, INotifyPropertyChanged
183  {
184   
185    private static PropertyChangingEventArgs emptyChangingEventArgs = new PropertyChangingEventArgs(String.Empty);
186   
187    private System.Guid _ResourceId;
188   
189    private System.Guid _JobId;
190   
191    private System.Guid _AssignedRessourcesId;
192   
193    private EntityRef<Resource> _Resource;
194   
195    private EntityRef<Job> _Job;
196   
197    #region Extensibility Method Definitions
198    partial void OnLoaded();
199    partial void OnValidate(System.Data.Linq.ChangeAction action);
200    partial void OnCreated();
201    partial void OnResourceIdChanging(System.Guid value);
202    partial void OnResourceIdChanged();
203    partial void OnJobIdChanging(System.Guid value);
204    partial void OnJobIdChanged();
205    partial void OnAssignedRessourcesIdChanging(System.Guid value);
206    partial void OnAssignedRessourcesIdChanged();
207    #endregion
208   
209    public AssignedResource()
210    {
211      this._Resource = default(EntityRef<Resource>);
212      this._Job = default(EntityRef<Job>);
213      OnCreated();
214    }
215   
216    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ResourceId", DbType="UniqueIdentifier NOT NULL")]
217    public System.Guid ResourceId
218    {
219      get
220      {
221        return this._ResourceId;
222      }
223      set
224      {
225        if ((this._ResourceId != value))
226        {
227          if (this._Resource.HasLoadedOrAssignedValue)
228          {
229            throw new System.Data.Linq.ForeignKeyReferenceAlreadyHasValueException();
230          }
231          this.OnResourceIdChanging(value);
232          this.SendPropertyChanging();
233          this._ResourceId = value;
234          this.SendPropertyChanged("ResourceId");
235          this.OnResourceIdChanged();
236        }
237      }
238    }
239   
240    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_JobId", DbType="UniqueIdentifier NOT NULL")]
241    public System.Guid JobId
242    {
243      get
244      {
245        return this._JobId;
246      }
247      set
248      {
249        if ((this._JobId != value))
250        {
251          if (this._Job.HasLoadedOrAssignedValue)
252          {
253            throw new System.Data.Linq.ForeignKeyReferenceAlreadyHasValueException();
254          }
255          this.OnJobIdChanging(value);
256          this.SendPropertyChanging();
257          this._JobId = value;
258          this.SendPropertyChanged("JobId");
259          this.OnJobIdChanged();
260        }
261      }
262    }
263   
264    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_AssignedRessourcesId", AutoSync=AutoSync.OnInsert, DbType="UniqueIdentifier NOT NULL", IsPrimaryKey=true, IsDbGenerated=true)]
265    public System.Guid AssignedRessourcesId
266    {
267      get
268      {
269        return this._AssignedRessourcesId;
270      }
271      set
272      {
273        if ((this._AssignedRessourcesId != value))
274        {
275          this.OnAssignedRessourcesIdChanging(value);
276          this.SendPropertyChanging();
277          this._AssignedRessourcesId = value;
278          this.SendPropertyChanged("AssignedRessourcesId");
279          this.OnAssignedRessourcesIdChanged();
280        }
281      }
282    }
283   
284    [global::System.Data.Linq.Mapping.AssociationAttribute(Name="Resource_AssignedResource", Storage="_Resource", ThisKey="ResourceId", OtherKey="ResourceId", IsForeignKey=true, DeleteRule="CASCADE")]
285    public Resource Resource
286    {
287      get
288      {
289        return this._Resource.Entity;
290      }
291      set
292      {
293        Resource previousValue = this._Resource.Entity;
294        if (((previousValue != value)
295              || (this._Resource.HasLoadedOrAssignedValue == false)))
296        {
297          this.SendPropertyChanging();
298          if ((previousValue != null))
299          {
300            this._Resource.Entity = null;
301            previousValue.AssignedResources.Remove(this);
302          }
303          this._Resource.Entity = value;
304          if ((value != null))
305          {
306            value.AssignedResources.Add(this);
307            this._ResourceId = value.ResourceId;
308          }
309          else
310          {
311            this._ResourceId = default(System.Guid);
312          }
313          this.SendPropertyChanged("Resource");
314        }
315      }
316    }
317   
318    [global::System.Data.Linq.Mapping.AssociationAttribute(Name="Job_AssignedResource", Storage="_Job", ThisKey="JobId", OtherKey="JobId", IsForeignKey=true, DeleteRule="CASCADE")]
319    public Job Job
320    {
321      get
322      {
323        return this._Job.Entity;
324      }
325      set
326      {
327        Job previousValue = this._Job.Entity;
328        if (((previousValue != value)
329              || (this._Job.HasLoadedOrAssignedValue == false)))
330        {
331          this.SendPropertyChanging();
332          if ((previousValue != null))
333          {
334            this._Job.Entity = null;
335            previousValue.AssignedResources.Remove(this);
336          }
337          this._Job.Entity = value;
338          if ((value != null))
339          {
340            value.AssignedResources.Add(this);
341            this._JobId = value.JobId;
342          }
343          else
344          {
345            this._JobId = default(System.Guid);
346          }
347          this.SendPropertyChanged("Job");
348        }
349      }
350    }
351   
352    public event PropertyChangingEventHandler PropertyChanging;
353   
354    public event PropertyChangedEventHandler PropertyChanged;
355   
356    protected virtual void SendPropertyChanging()
357    {
358      if ((this.PropertyChanging != null))
359      {
360        this.PropertyChanging(this, emptyChangingEventArgs);
361      }
362    }
363   
364    protected virtual void SendPropertyChanged(String propertyName)
365    {
366      if ((this.PropertyChanged != null))
367      {
368        this.PropertyChanged(this, new PropertyChangedEventArgs(propertyName));
369      }
370    }
371  }
372 
373  [global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.Plugin")]
374  public partial class Plugin : INotifyPropertyChanging, INotifyPropertyChanged
375  {
376   
377    private static PropertyChangingEventArgs emptyChangingEventArgs = new PropertyChangingEventArgs(String.Empty);
378   
379    private System.Guid _PluginId;
380   
381    private string _Name;
382   
383    private string _Version;
384   
385    private bool _IsLocal;
386   
387    private System.Guid _UserId;
388   
389    private System.DateTime _DateCreated;
390   
391    private EntitySet<RequiredPlugin> _RequiredPlugins;
392   
393    private EntitySet<PluginData> _PluginData;
394   
395    #region Extensibility Method Definitions
396    partial void OnLoaded();
397    partial void OnValidate(System.Data.Linq.ChangeAction action);
398    partial void OnCreated();
399    partial void OnPluginIdChanging(System.Guid value);
400    partial void OnPluginIdChanged();
401    partial void OnNameChanging(string value);
402    partial void OnNameChanged();
403    partial void OnVersionChanging(string value);
404    partial void OnVersionChanged();
405    partial void OnIsLocalChanging(bool value);
406    partial void OnIsLocalChanged();
407    partial void OnUserIdChanging(System.Guid value);
408    partial void OnUserIdChanged();
409    partial void OnDateCreatedChanging(System.DateTime value);
410    partial void OnDateCreatedChanged();
411    #endregion
412   
413    public Plugin()
414    {
415      this._RequiredPlugins = new EntitySet<RequiredPlugin>(new Action<RequiredPlugin>(this.attach_RequiredPlugins), new Action<RequiredPlugin>(this.detach_RequiredPlugins));
416      this._PluginData = new EntitySet<PluginData>(new Action<PluginData>(this.attach_PluginData), new Action<PluginData>(this.detach_PluginData));
417      OnCreated();
418    }
419   
420    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_PluginId", AutoSync=AutoSync.OnInsert, DbType="UniqueIdentifier NOT NULL", IsPrimaryKey=true, IsDbGenerated=true)]
421    public System.Guid PluginId
422    {
423      get
424      {
425        return this._PluginId;
426      }
427      set
428      {
429        if ((this._PluginId != value))
430        {
431          this.OnPluginIdChanging(value);
432          this.SendPropertyChanging();
433          this._PluginId = value;
434          this.SendPropertyChanged("PluginId");
435          this.OnPluginIdChanged();
436        }
437      }
438    }
439   
440    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Name", DbType="VarChar(MAX)", CanBeNull=false)]
441    public string Name
442    {
443      get
444      {
445        return this._Name;
446      }
447      set
448      {
449        if ((this._Name != value))
450        {
451          this.OnNameChanging(value);
452          this.SendPropertyChanging();
453          this._Name = value;
454          this.SendPropertyChanged("Name");
455          this.OnNameChanged();
456        }
457      }
458    }
459   
460    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Version", DbType="VarChar(MAX)", CanBeNull=false)]
461    public string Version
462    {
463      get
464      {
465        return this._Version;
466      }
467      set
468      {
469        if ((this._Version != value))
470        {
471          this.OnVersionChanging(value);
472          this.SendPropertyChanging();
473          this._Version = value;
474          this.SendPropertyChanged("Version");
475          this.OnVersionChanged();
476        }
477      }
478    }
479   
480    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_IsLocal", DbType="Bit")]
481    public bool IsLocal
482    {
483      get
484      {
485        return this._IsLocal;
486      }
487      set
488      {
489        if ((this._IsLocal != value))
490        {
491          this.OnIsLocalChanging(value);
492          this.SendPropertyChanging();
493          this._IsLocal = value;
494          this.SendPropertyChanged("IsLocal");
495          this.OnIsLocalChanged();
496        }
497      }
498    }
499   
500    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_UserId", DbType="UniqueIdentifier")]
501    public System.Guid UserId
502    {
503      get
504      {
505        return this._UserId;
506      }
507      set
508      {
509        if ((this._UserId != value))
510        {
511          this.OnUserIdChanging(value);
512          this.SendPropertyChanging();
513          this._UserId = value;
514          this.SendPropertyChanged("UserId");
515          this.OnUserIdChanged();
516        }
517      }
518    }
519   
520    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_DateCreated", DbType="DateTime")]
521    public System.DateTime DateCreated
522    {
523      get
524      {
525        return this._DateCreated;
526      }
527      set
528      {
529        if ((this._DateCreated != value))
530        {
531          this.OnDateCreatedChanging(value);
532          this.SendPropertyChanging();
533          this._DateCreated = value;
534          this.SendPropertyChanged("DateCreated");
535          this.OnDateCreatedChanged();
536        }
537      }
538    }
539   
540    [global::System.Data.Linq.Mapping.AssociationAttribute(Name="Plugin_RequiredPlugin", Storage="_RequiredPlugins", ThisKey="PluginId", OtherKey="PluginId")]
541    public EntitySet<RequiredPlugin> RequiredPlugins
542    {
543      get
544      {
545        return this._RequiredPlugins;
546      }
547      set
548      {
549        this._RequiredPlugins.Assign(value);
550      }
551    }
552   
553    [global::System.Data.Linq.Mapping.AssociationAttribute(Name="Plugin_PluginData", Storage="_PluginData", ThisKey="PluginId", OtherKey="PluginId")]
554    public EntitySet<PluginData> PluginData
555    {
556      get
557      {
558        return this._PluginData;
559      }
560      set
561      {
562        this._PluginData.Assign(value);
563      }
564    }
565   
566    public event PropertyChangingEventHandler PropertyChanging;
567   
568    public event PropertyChangedEventHandler PropertyChanged;
569   
570    protected virtual void SendPropertyChanging()
571    {
572      if ((this.PropertyChanging != null))
573      {
574        this.PropertyChanging(this, emptyChangingEventArgs);
575      }
576    }
577   
578    protected virtual void SendPropertyChanged(String propertyName)
579    {
580      if ((this.PropertyChanged != null))
581      {
582        this.PropertyChanged(this, new PropertyChangedEventArgs(propertyName));
583      }
584    }
585   
586    private void attach_RequiredPlugins(RequiredPlugin entity)
587    {
588      this.SendPropertyChanging();
589      entity.Plugin = this;
590    }
591   
592    private void detach_RequiredPlugins(RequiredPlugin entity)
593    {
594      this.SendPropertyChanging();
595      entity.Plugin = null;
596    }
597   
598    private void attach_PluginData(PluginData entity)
599    {
600      this.SendPropertyChanging();
601      entity.Plugin = this;
602    }
603   
604    private void detach_PluginData(PluginData entity)
605    {
606      this.SendPropertyChanging();
607      entity.Plugin = null;
608    }
609  }
610 
611  [global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.RequiredPlugins")]
612  public partial class RequiredPlugin : INotifyPropertyChanging, INotifyPropertyChanged
613  {
614   
615    private static PropertyChangingEventArgs emptyChangingEventArgs = new PropertyChangingEventArgs(String.Empty);
616   
617    private System.Guid _RequiredPluginId;
618   
619    private System.Guid _JobId;
620   
621    private System.Guid _PluginId;
622   
623    private EntityRef<Plugin> _PluginInfo;
624   
625    private EntityRef<Job> _Job;
626   
627    #region Extensibility Method Definitions
628    partial void OnLoaded();
629    partial void OnValidate(System.Data.Linq.ChangeAction action);
630    partial void OnCreated();
631    partial void OnRequiredPluginIdChanging(System.Guid value);
632    partial void OnRequiredPluginIdChanged();
633    partial void OnJobIdChanging(System.Guid value);
634    partial void OnJobIdChanged();
635    partial void OnPluginIdChanging(System.Guid value);
636    partial void OnPluginIdChanged();
637    #endregion
638   
639    public RequiredPlugin()
640    {
641      this._PluginInfo = default(EntityRef<Plugin>);
642      this._Job = default(EntityRef<Job>);
643      OnCreated();
644    }
645   
646    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_RequiredPluginId", AutoSync=AutoSync.OnInsert, DbType="UniqueIdentifier NOT NULL", IsPrimaryKey=true, IsDbGenerated=true, UpdateCheck=UpdateCheck.Never)]
647    public System.Guid RequiredPluginId
648    {
649      get
650      {
651        return this._RequiredPluginId;
652      }
653      set
654      {
655        if ((this._RequiredPluginId != value))
656        {
657          this.OnRequiredPluginIdChanging(value);
658          this.SendPropertyChanging();
659          this._RequiredPluginId = value;
660          this.SendPropertyChanged("RequiredPluginId");
661          this.OnRequiredPluginIdChanged();
662        }
663      }
664    }
665   
666    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_JobId", DbType="UniqueIdentifier NOT NULL")]
667    public System.Guid JobId
668    {
669      get
670      {
671        return this._JobId;
672      }
673      set
674      {
675        if ((this._JobId != value))
676        {
677          if (this._Job.HasLoadedOrAssignedValue)
678          {
679            throw new System.Data.Linq.ForeignKeyReferenceAlreadyHasValueException();
680          }
681          this.OnJobIdChanging(value);
682          this.SendPropertyChanging();
683          this._JobId = value;
684          this.SendPropertyChanged("JobId");
685          this.OnJobIdChanged();
686        }
687      }
688    }
689   
690    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_PluginId", DbType="UniqueIdentifier NOT NULL")]
691    public System.Guid PluginId
692    {
693      get
694      {
695        return this._PluginId;
696      }
697      set
698      {
699        if ((this._PluginId != value))
700        {
701          if (this._PluginInfo.HasLoadedOrAssignedValue)
702          {
703            throw new System.Data.Linq.ForeignKeyReferenceAlreadyHasValueException();
704          }
705          this.OnPluginIdChanging(value);
706          this.SendPropertyChanging();
707          this._PluginId = value;
708          this.SendPropertyChanged("PluginId");
709          this.OnPluginIdChanged();
710        }
711      }
712    }
713   
714    [global::System.Data.Linq.Mapping.AssociationAttribute(Name="Plugin_RequiredPlugin", Storage="_PluginInfo", ThisKey="PluginId", OtherKey="PluginId", IsForeignKey=true, DeleteRule="CASCADE")]
715    public Plugin Plugin
716    {
717      get
718      {
719        return this._PluginInfo.Entity;
720      }
721      set
722      {
723        Plugin previousValue = this._PluginInfo.Entity;
724        if (((previousValue != value)
725              || (this._PluginInfo.HasLoadedOrAssignedValue == false)))
726        {
727          this.SendPropertyChanging();
728          if ((previousValue != null))
729          {
730            this._PluginInfo.Entity = null;
731            previousValue.RequiredPlugins.Remove(this);
732          }
733          this._PluginInfo.Entity = value;
734          if ((value != null))
735          {
736            value.RequiredPlugins.Add(this);
737            this._PluginId = value.PluginId;
738          }
739          else
740          {
741            this._PluginId = default(System.Guid);
742          }
743          this.SendPropertyChanged("Plugin");
744        }
745      }
746    }
747   
748    [global::System.Data.Linq.Mapping.AssociationAttribute(Name="Job_RequiredPlugin", Storage="_Job", ThisKey="JobId", OtherKey="JobId", IsForeignKey=true)]
749    public Job Job
750    {
751      get
752      {
753        return this._Job.Entity;
754      }
755      set
756      {
757        Job previousValue = this._Job.Entity;
758        if (((previousValue != value)
759              || (this._Job.HasLoadedOrAssignedValue == false)))
760        {
761          this.SendPropertyChanging();
762          if ((previousValue != null))
763          {
764            this._Job.Entity = null;
765            previousValue.RequiredPlugins.Remove(this);
766          }
767          this._Job.Entity = value;
768          if ((value != null))
769          {
770            value.RequiredPlugins.Add(this);
771            this._JobId = value.JobId;
772          }
773          else
774          {
775            this._JobId = default(System.Guid);
776          }
777          this.SendPropertyChanged("Job");
778        }
779      }
780    }
781   
782    public event PropertyChangingEventHandler PropertyChanging;
783   
784    public event PropertyChangedEventHandler PropertyChanged;
785   
786    protected virtual void SendPropertyChanging()
787    {
788      if ((this.PropertyChanging != null))
789      {
790        this.PropertyChanging(this, emptyChangingEventArgs);
791      }
792    }
793   
794    protected virtual void SendPropertyChanged(String propertyName)
795    {
796      if ((this.PropertyChanged != null))
797      {
798        this.PropertyChanged(this, new PropertyChangedEventArgs(propertyName));
799      }
800    }
801  }
802 
803  [global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.Resource")]
804  [global::System.Data.Linq.Mapping.InheritanceMappingAttribute(Code="RESOURCE", Type=typeof(Resource))]
805  [global::System.Data.Linq.Mapping.InheritanceMappingAttribute(Code="Slave", Type=typeof(Slave), IsDefault=true)]
806  [global::System.Data.Linq.Mapping.InheritanceMappingAttribute(Code="GROUP", Type=typeof(SlaveGroup))]
807  public partial class Resource : INotifyPropertyChanging, INotifyPropertyChanged
808  {
809   
810    private static PropertyChangingEventArgs emptyChangingEventArgs = new PropertyChangingEventArgs(String.Empty);
811   
812    private System.Guid _ResourceId;
813   
814    private string _Name;
815   
816    private string _ResourceType;
817   
818    private System.Nullable<System.Guid> _ParentResourceId;
819   
820    private EntitySet<AssignedResource> _AssignedResources;
821   
822    private EntitySet<Resource> _ChildResources;
823   
824    private EntitySet<UptimeCalendar> _UptimeCalendars;
825   
826    private EntitySet<StateLog> _StateLogs;
827   
828    private EntityRef<Resource> _ParentResource;
829   
830    #region Extensibility Method Definitions
831    partial void OnLoaded();
832    partial void OnValidate(System.Data.Linq.ChangeAction action);
833    partial void OnCreated();
834    partial void OnResourceIdChanging(System.Guid value);
835    partial void OnResourceIdChanged();
836    partial void OnNameChanging(string value);
837    partial void OnNameChanged();
838    partial void OnResourceTypeChanging(string value);
839    partial void OnResourceTypeChanged();
840    partial void OnParentResourceIdChanging(System.Nullable<System.Guid> value);
841    partial void OnParentResourceIdChanged();
842    #endregion
843   
844    public Resource()
845    {
846      this._AssignedResources = new EntitySet<AssignedResource>(new Action<AssignedResource>(this.attach_AssignedResources), new Action<AssignedResource>(this.detach_AssignedResources));
847      this._ChildResources = new EntitySet<Resource>(new Action<Resource>(this.attach_ChildResources), new Action<Resource>(this.detach_ChildResources));
848      this._UptimeCalendars = new EntitySet<UptimeCalendar>(new Action<UptimeCalendar>(this.attach_UptimeCalendars), new Action<UptimeCalendar>(this.detach_UptimeCalendars));
849      this._StateLogs = new EntitySet<StateLog>(new Action<StateLog>(this.attach_StateLogs), new Action<StateLog>(this.detach_StateLogs));
850      this._ParentResource = default(EntityRef<Resource>);
851      OnCreated();
852    }
853   
854    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ResourceId", AutoSync=AutoSync.OnInsert, DbType="UniqueIdentifier NOT NULL", IsPrimaryKey=true)]
855    public System.Guid ResourceId
856    {
857      get
858      {
859        return this._ResourceId;
860      }
861      set
862      {
863        if ((this._ResourceId != value))
864        {
865          this.OnResourceIdChanging(value);
866          this.SendPropertyChanging();
867          this._ResourceId = value;
868          this.SendPropertyChanged("ResourceId");
869          this.OnResourceIdChanged();
870        }
871      }
872    }
873   
874    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Name", DbType="VarChar(MAX)", CanBeNull=false)]
875    public string Name
876    {
877      get
878      {
879        return this._Name;
880      }
881      set
882      {
883        if ((this._Name != value))
884        {
885          this.OnNameChanging(value);
886          this.SendPropertyChanging();
887          this._Name = value;
888          this.SendPropertyChanged("Name");
889          this.OnNameChanged();
890        }
891      }
892    }
893   
894    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ResourceType", CanBeNull=false, IsDiscriminator=true)]
895    public string ResourceType
896    {
897      get
898      {
899        return this._ResourceType;
900      }
901      set
902      {
903        if ((this._ResourceType != value))
904        {
905          this.OnResourceTypeChanging(value);
906          this.SendPropertyChanging();
907          this._ResourceType = value;
908          this.SendPropertyChanged("ResourceType");
909          this.OnResourceTypeChanged();
910        }
911      }
912    }
913   
914    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ParentResourceId", DbType="UniqueIdentifier")]
915    public System.Nullable<System.Guid> ParentResourceId
916    {
917      get
918      {
919        return this._ParentResourceId;
920      }
921      set
922      {
923        if ((this._ParentResourceId != value))
924        {
925          if (this._ParentResource.HasLoadedOrAssignedValue)
926          {
927            throw new System.Data.Linq.ForeignKeyReferenceAlreadyHasValueException();
928          }
929          this.OnParentResourceIdChanging(value);
930          this.SendPropertyChanging();
931          this._ParentResourceId = value;
932          this.SendPropertyChanged("ParentResourceId");
933          this.OnParentResourceIdChanged();
934        }
935      }
936    }
937   
938    [global::System.Data.Linq.Mapping.AssociationAttribute(Name="Resource_AssignedResource", Storage="_AssignedResources", ThisKey="ResourceId", OtherKey="ResourceId")]
939    public EntitySet<AssignedResource> AssignedResources
940    {
941      get
942      {
943        return this._AssignedResources;
944      }
945      set
946      {
947        this._AssignedResources.Assign(value);
948      }
949    }
950   
951    [global::System.Data.Linq.Mapping.AssociationAttribute(Name="Resource_Resource", Storage="_ChildResources", ThisKey="ResourceId", OtherKey="ParentResourceId")]
952    public EntitySet<Resource> ChildResources
953    {
954      get
955      {
956        return this._ChildResources;
957      }
958      set
959      {
960        this._ChildResources.Assign(value);
961      }
962    }
963   
964    [global::System.Data.Linq.Mapping.AssociationAttribute(Name="Resource_UptimeCalendar", Storage="_UptimeCalendars", ThisKey="ResourceId", OtherKey="ResourceId")]
965    public EntitySet<UptimeCalendar> UptimeCalendars
966    {
967      get
968      {
969        return this._UptimeCalendars;
970      }
971      set
972      {
973        this._UptimeCalendars.Assign(value);
974      }
975    }
976   
977    [global::System.Data.Linq.Mapping.AssociationAttribute(Name="Resource_StateLog", Storage="_StateLogs", ThisKey="ResourceId", OtherKey="SlaveId")]
978    public EntitySet<StateLog> StateLogs
979    {
980      get
981      {
982        return this._StateLogs;
983      }
984      set
985      {
986        this._StateLogs.Assign(value);
987      }
988    }
989   
990    [global::System.Data.Linq.Mapping.AssociationAttribute(Name="Resource_Resource", Storage="_ParentResource", ThisKey="ParentResourceId", OtherKey="ResourceId", IsForeignKey=true)]
991    public Resource ParentResource
992    {
993      get
994      {
995        return this._ParentResource.Entity;
996      }
997      set
998      {
999        Resource previousValue = this._ParentResource.Entity;
1000        if (((previousValue != value)
1001              || (this._ParentResource.HasLoadedOrAssignedValue == false)))
1002        {
1003          this.SendPropertyChanging();
1004          if ((previousValue != null))
1005          {
1006            this._ParentResource.Entity = null;
1007            previousValue.ChildResources.Remove(this);
1008          }
1009          this._ParentResource.Entity = value;
1010          if ((value != null))
1011          {
1012            value.ChildResources.Add(this);
1013            this._ParentResourceId = value.ResourceId;
1014          }
1015          else
1016          {
1017            this._ParentResourceId = default(Nullable<System.Guid>);
1018          }
1019          this.SendPropertyChanged("ParentResource");
1020        }
1021      }
1022    }
1023   
1024    public event PropertyChangingEventHandler PropertyChanging;
1025   
1026    public event PropertyChangedEventHandler PropertyChanged;
1027   
1028    protected virtual void SendPropertyChanging()
1029    {
1030      if ((this.PropertyChanging != null))
1031      {
1032        this.PropertyChanging(this, emptyChangingEventArgs);
1033      }
1034    }
1035   
1036    protected virtual void SendPropertyChanged(String propertyName)
1037    {
1038      if ((this.PropertyChanged != null))
1039      {
1040        this.PropertyChanged(this, new PropertyChangedEventArgs(propertyName));
1041      }
1042    }
1043   
1044    private void attach_AssignedResources(AssignedResource entity)
1045    {
1046      this.SendPropertyChanging();
1047      entity.Resource = this;
1048    }
1049   
1050    private void detach_AssignedResources(AssignedResource entity)
1051    {
1052      this.SendPropertyChanging();
1053      entity.Resource = null;
1054    }
1055   
1056    private void attach_ChildResources(Resource entity)
1057    {
1058      this.SendPropertyChanging();
1059      entity.ParentResource = this;
1060    }
1061   
1062    private void detach_ChildResources(Resource entity)
1063    {
1064      this.SendPropertyChanging();
1065      entity.ParentResource = null;
1066    }
1067   
1068    private void attach_UptimeCalendars(UptimeCalendar entity)
1069    {
1070      this.SendPropertyChanging();
1071      entity.Resource = this;
1072    }
1073   
1074    private void detach_UptimeCalendars(UptimeCalendar entity)
1075    {
1076      this.SendPropertyChanging();
1077      entity.Resource = null;
1078    }
1079   
1080    private void attach_StateLogs(StateLog entity)
1081    {
1082      this.SendPropertyChanging();
1083      entity.Resource = this;
1084    }
1085   
1086    private void detach_StateLogs(StateLog entity)
1087    {
1088      this.SendPropertyChanging();
1089      entity.Resource = null;
1090    }
1091  }
1092 
1093  public partial class Slave : Resource
1094  {
1095   
1096    private System.Nullable<int> _CPUSpeed;
1097   
1098    private System.Nullable<int> _Memory;
1099   
1100    private System.Nullable<System.DateTime> _Login;
1101   
1102    private global::HeuristicLab.Services.Hive.Common.DataTransfer.SlaveState _Status;
1103   
1104    private System.Nullable<int> _NumberOfCores;
1105   
1106    private System.Nullable<int> _NumberOfFreeCores;
1107   
1108    private System.Nullable<int> _FreeMemory;
1109   
1110    private bool _IsAllowedToCalculate;
1111   
1112    private global::HeuristicLab.Services.Hive.Common.DataTransfer.CpuArchitecture _CpuArchitecture;
1113   
1114    private string _OperatingSystem;
1115   
1116    private System.Nullable<System.DateTime> _LastHeartbeat;
1117   
1118    #region Extensibility Method Definitions
1119    partial void OnLoaded();
1120    partial void OnValidate(System.Data.Linq.ChangeAction action);
1121    partial void OnCreated();
1122    partial void OnCpuSpeedChanging(System.Nullable<int> value);
1123    partial void OnCpuSpeedChanged();
1124    partial void OnMemoryChanging(System.Nullable<int> value);
1125    partial void OnMemoryChanged();
1126    partial void OnLoginChanging(System.Nullable<System.DateTime> value);
1127    partial void OnLoginChanged();
1128    partial void OnSlaveStateChanging(global::HeuristicLab.Services.Hive.Common.DataTransfer.SlaveState value);
1129    partial void OnSlaveStateChanged();
1130    partial void OnCoresChanging(System.Nullable<int> value);
1131    partial void OnCoresChanged();
1132    partial void OnFreeCoresChanging(System.Nullable<int> value);
1133    partial void OnFreeCoresChanged();
1134    partial void OnFreeMemoryChanging(System.Nullable<int> value);
1135    partial void OnFreeMemoryChanged();
1136    partial void OnIsAllowedToCalculateChanging(bool value);
1137    partial void OnIsAllowedToCalculateChanged();
1138    partial void OnCpuArchitectureChanging(global::HeuristicLab.Services.Hive.Common.DataTransfer.CpuArchitecture value);
1139    partial void OnCpuArchitectureChanged();
1140    partial void OnOperatingSystemChanging(string value);
1141    partial void OnOperatingSystemChanged();
1142    partial void OnLastHeartbeatChanging(System.Nullable<System.DateTime> value);
1143    partial void OnLastHeartbeatChanged();
1144    #endregion
1145   
1146    public Slave()
1147    {
1148      OnCreated();
1149    }
1150   
1151    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_CPUSpeed", DbType="Int")]
1152    public System.Nullable<int> CpuSpeed
1153    {
1154      get
1155      {
1156        return this._CPUSpeed;
1157      }
1158      set
1159      {
1160        if ((this._CPUSpeed != value))
1161        {
1162          this.OnCpuSpeedChanging(value);
1163          this.SendPropertyChanging();
1164          this._CPUSpeed = value;
1165          this.SendPropertyChanged("CpuSpeed");
1166          this.OnCpuSpeedChanged();
1167        }
1168      }
1169    }
1170   
1171    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Memory", DbType="Int")]
1172    public System.Nullable<int> Memory
1173    {
1174      get
1175      {
1176        return this._Memory;
1177      }
1178      set
1179      {
1180        if ((this._Memory != value))
1181        {
1182          this.OnMemoryChanging(value);
1183          this.SendPropertyChanging();
1184          this._Memory = value;
1185          this.SendPropertyChanged("Memory");
1186          this.OnMemoryChanged();
1187        }
1188      }
1189    }
1190   
1191    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Login", DbType="DateTime")]
1192    public System.Nullable<System.DateTime> Login
1193    {
1194      get
1195      {
1196        return this._Login;
1197      }
1198      set
1199      {
1200        if ((this._Login != value))
1201        {
1202          this.OnLoginChanging(value);
1203          this.SendPropertyChanging();
1204          this._Login = value;
1205          this.SendPropertyChanged("Login");
1206          this.OnLoginChanged();
1207        }
1208      }
1209    }
1210   
1211    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Status", DbType="VarChar(15)", CanBeNull=true)]
1212    public global::HeuristicLab.Services.Hive.Common.DataTransfer.SlaveState SlaveState
1213    {
1214      get
1215      {
1216        return this._Status;
1217      }
1218      set
1219      {
1220        if ((this._Status != value))
1221        {
1222          this.OnSlaveStateChanging(value);
1223          this.SendPropertyChanging();
1224          this._Status = value;
1225          this.SendPropertyChanged("SlaveState");
1226          this.OnSlaveStateChanged();
1227        }
1228      }
1229    }
1230   
1231    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_NumberOfCores", DbType="Int")]
1232    public System.Nullable<int> Cores
1233    {
1234      get
1235      {
1236        return this._NumberOfCores;
1237      }
1238      set
1239      {
1240        if ((this._NumberOfCores != value))
1241        {
1242          this.OnCoresChanging(value);
1243          this.SendPropertyChanging();
1244          this._NumberOfCores = value;
1245          this.SendPropertyChanged("Cores");
1246          this.OnCoresChanged();
1247        }
1248      }
1249    }
1250   
1251    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_NumberOfFreeCores", DbType="Int")]
1252    public System.Nullable<int> FreeCores
1253    {
1254      get
1255      {
1256        return this._NumberOfFreeCores;
1257      }
1258      set
1259      {
1260        if ((this._NumberOfFreeCores != value))
1261        {
1262          this.OnFreeCoresChanging(value);
1263          this.SendPropertyChanging();
1264          this._NumberOfFreeCores = value;
1265          this.SendPropertyChanged("FreeCores");
1266          this.OnFreeCoresChanged();
1267        }
1268      }
1269    }
1270   
1271    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_FreeMemory", DbType="Int")]
1272    public System.Nullable<int> FreeMemory
1273    {
1274      get
1275      {
1276        return this._FreeMemory;
1277      }
1278      set
1279      {
1280        if ((this._FreeMemory != value))
1281        {
1282          this.OnFreeMemoryChanging(value);
1283          this.SendPropertyChanging();
1284          this._FreeMemory = value;
1285          this.SendPropertyChanged("FreeMemory");
1286          this.OnFreeMemoryChanged();
1287        }
1288      }
1289    }
1290   
1291    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_IsAllowedToCalculate", DbType="Bit")]
1292    public bool IsAllowedToCalculate
1293    {
1294      get
1295      {
1296        return this._IsAllowedToCalculate;
1297      }
1298      set
1299      {
1300        if ((this._IsAllowedToCalculate != value))
1301        {
1302          this.OnIsAllowedToCalculateChanging(value);
1303          this.SendPropertyChanging();
1304          this._IsAllowedToCalculate = value;
1305          this.SendPropertyChanged("IsAllowedToCalculate");
1306          this.OnIsAllowedToCalculateChanged();
1307        }
1308      }
1309    }
1310   
1311    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_CpuArchitecture", DbType="VarChar(3)", CanBeNull=false)]
1312    public global::HeuristicLab.Services.Hive.Common.DataTransfer.CpuArchitecture CpuArchitecture
1313    {
1314      get
1315      {
1316        return this._CpuArchitecture;
1317      }
1318      set
1319      {
1320        if ((this._CpuArchitecture != value))
1321        {
1322          this.OnCpuArchitectureChanging(value);
1323          this.SendPropertyChanging();
1324          this._CpuArchitecture = value;
1325          this.SendPropertyChanged("CpuArchitecture");
1326          this.OnCpuArchitectureChanged();
1327        }
1328      }
1329    }
1330   
1331    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_OperatingSystem", DbType="VarChar(MAX)", CanBeNull=false, UpdateCheck=UpdateCheck.Never)]
1332    public string OperatingSystem
1333    {
1334      get
1335      {
1336        return this._OperatingSystem;
1337      }
1338      set
1339      {
1340        if ((this._OperatingSystem != value))
1341        {
1342          this.OnOperatingSystemChanging(value);
1343          this.SendPropertyChanging();
1344          this._OperatingSystem = value;
1345          this.SendPropertyChanged("OperatingSystem");
1346          this.OnOperatingSystemChanged();
1347        }
1348      }
1349    }
1350   
1351    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_LastHeartbeat", DbType="DateTime")]
1352    public System.Nullable<System.DateTime> LastHeartbeat
1353    {
1354      get
1355      {
1356        return this._LastHeartbeat;
1357      }
1358      set
1359      {
1360        if ((this._LastHeartbeat != value))
1361        {
1362          this.OnLastHeartbeatChanging(value);
1363          this.SendPropertyChanging();
1364          this._LastHeartbeat = value;
1365          this.SendPropertyChanged("LastHeartbeat");
1366          this.OnLastHeartbeatChanged();
1367        }
1368      }
1369    }
1370  }
1371 
1372  public partial class SlaveGroup : Resource
1373  {
1374   
1375    #region Extensibility Method Definitions
1376    partial void OnLoaded();
1377    partial void OnValidate(System.Data.Linq.ChangeAction action);
1378    partial void OnCreated();
1379    #endregion
1380   
1381    public SlaveGroup()
1382    {
1383      OnCreated();
1384    }
1385  }
1386 
1387  [global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.Job")]
1388  public partial class Job : INotifyPropertyChanging, INotifyPropertyChanged
1389  {
1390   
1391    private static PropertyChangingEventArgs emptyChangingEventArgs = new PropertyChangingEventArgs(String.Empty);
1392   
1393    private System.Guid _JobId;
1394   
1395    private System.Nullable<System.Guid> _ParentJobId;
1396   
1397    private string _ExecutionTime;
1398   
1399    private int _Priority;
1400   
1401    private int _CoresNeeded;
1402   
1403    private int _MemoryNeeded;
1404   
1405    private System.Nullable<System.DateTime> _LastHeartbeat;
1406   
1407    private global::HeuristicLab.Services.Hive.Common.DataTransfer.JobState _State;
1408   
1409    private EntitySet<AssignedResource> _AssignedResources;
1410   
1411    private EntitySet<RequiredPlugin> _RequiredPlugins;
1412   
1413    private EntitySet<Job> _Jobs;
1414   
1415    private EntityRef<JobData> _JobData;
1416   
1417    private EntitySet<StateLog> _StateLogs;
1418   
1419    private EntityRef<Job> _Job1;
1420   
1421    #region Extensibility Method Definitions
1422    partial void OnLoaded();
1423    partial void OnValidate(System.Data.Linq.ChangeAction action);
1424    partial void OnCreated();
1425    partial void OnJobIdChanging(System.Guid value);
1426    partial void OnJobIdChanged();
1427    partial void OnParentJobIdChanging(System.Nullable<System.Guid> value);
1428    partial void OnParentJobIdChanged();
1429    partial void OnExecutionTimeChanging(string value);
1430    partial void OnExecutionTimeChanged();
1431    partial void OnPriorityChanging(int value);
1432    partial void OnPriorityChanged();
1433    partial void OnCoresNeededChanging(int value);
1434    partial void OnCoresNeededChanged();
1435    partial void OnMemoryNeededChanging(int value);
1436    partial void OnMemoryNeededChanged();
1437    partial void OnLastHeartbeatChanging(System.Nullable<System.DateTime> value);
1438    partial void OnLastHeartbeatChanged();
1439    partial void OnStateChanging(global::HeuristicLab.Services.Hive.Common.DataTransfer.JobState value);
1440    partial void OnStateChanged();
1441    #endregion
1442   
1443    public Job()
1444    {
1445      this._AssignedResources = new EntitySet<AssignedResource>(new Action<AssignedResource>(this.attach_AssignedResources), new Action<AssignedResource>(this.detach_AssignedResources));
1446      this._RequiredPlugins = new EntitySet<RequiredPlugin>(new Action<RequiredPlugin>(this.attach_RequiredPlugins), new Action<RequiredPlugin>(this.detach_RequiredPlugins));
1447      this._Jobs = new EntitySet<Job>(new Action<Job>(this.attach_Jobs), new Action<Job>(this.detach_Jobs));
1448      this._JobData = default(EntityRef<JobData>);
1449      this._StateLogs = new EntitySet<StateLog>(new Action<StateLog>(this.attach_StateLogs), new Action<StateLog>(this.detach_StateLogs));
1450      this._Job1 = default(EntityRef<Job>);
1451      OnCreated();
1452    }
1453   
1454    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_JobId", AutoSync=AutoSync.OnInsert, DbType="UniqueIdentifier NOT NULL", IsPrimaryKey=true, IsDbGenerated=true)]
1455    public System.Guid JobId
1456    {
1457      get
1458      {
1459        return this._JobId;
1460      }
1461      set
1462      {
1463        if ((this._JobId != value))
1464        {
1465          this.OnJobIdChanging(value);
1466          this.SendPropertyChanging();
1467          this._JobId = value;
1468          this.SendPropertyChanged("JobId");
1469          this.OnJobIdChanged();
1470        }
1471      }
1472    }
1473   
1474    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ParentJobId", DbType="UniqueIdentifier")]
1475    public System.Nullable<System.Guid> ParentJobId
1476    {
1477      get
1478      {
1479        return this._ParentJobId;
1480      }
1481      set
1482      {
1483        if ((this._ParentJobId != value))
1484        {
1485          if (this._Job1.HasLoadedOrAssignedValue)
1486          {
1487            throw new System.Data.Linq.ForeignKeyReferenceAlreadyHasValueException();
1488          }
1489          this.OnParentJobIdChanging(value);
1490          this.SendPropertyChanging();
1491          this._ParentJobId = value;
1492          this.SendPropertyChanged("ParentJobId");
1493          this.OnParentJobIdChanged();
1494        }
1495      }
1496    }
1497   
1498    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ExecutionTime", DbType="VarChar(30)")]
1499    public string ExecutionTime
1500    {
1501      get
1502      {
1503        return this._ExecutionTime;
1504      }
1505      set
1506      {
1507        if ((this._ExecutionTime != value))
1508        {
1509          this.OnExecutionTimeChanging(value);
1510          this.SendPropertyChanging();
1511          this._ExecutionTime = value;
1512          this.SendPropertyChanged("ExecutionTime");
1513          this.OnExecutionTimeChanged();
1514        }
1515      }
1516    }
1517   
1518    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Priority", DbType="Int NOT NULL")]
1519    public int Priority
1520    {
1521      get
1522      {
1523        return this._Priority;
1524      }
1525      set
1526      {
1527        if ((this._Priority != value))
1528        {
1529          this.OnPriorityChanging(value);
1530          this.SendPropertyChanging();
1531          this._Priority = value;
1532          this.SendPropertyChanged("Priority");
1533          this.OnPriorityChanged();
1534        }
1535      }
1536    }
1537   
1538    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_CoresNeeded", DbType="Int NOT NULL")]
1539    public int CoresNeeded
1540    {
1541      get
1542      {
1543        return this._CoresNeeded;
1544      }
1545      set
1546      {
1547        if ((this._CoresNeeded != value))
1548        {
1549          this.OnCoresNeededChanging(value);
1550          this.SendPropertyChanging();
1551          this._CoresNeeded = value;
1552          this.SendPropertyChanged("CoresNeeded");
1553          this.OnCoresNeededChanged();
1554        }
1555      }
1556    }
1557   
1558    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_MemoryNeeded", DbType="Int NOT NULL")]
1559    public int MemoryNeeded
1560    {
1561      get
1562      {
1563        return this._MemoryNeeded;
1564      }
1565      set
1566      {
1567        if ((this._MemoryNeeded != value))
1568        {
1569          this.OnMemoryNeededChanging(value);
1570          this.SendPropertyChanging();
1571          this._MemoryNeeded = value;
1572          this.SendPropertyChanged("MemoryNeeded");
1573          this.OnMemoryNeededChanged();
1574        }
1575      }
1576    }
1577   
1578    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_LastHeartbeat", DbType="DateTime")]
1579    public System.Nullable<System.DateTime> LastHeartbeat
1580    {
1581      get
1582      {
1583        return this._LastHeartbeat;
1584      }
1585      set
1586      {
1587        if ((this._LastHeartbeat != value))
1588        {
1589          this.OnLastHeartbeatChanging(value);
1590          this.SendPropertyChanging();
1591          this._LastHeartbeat = value;
1592          this.SendPropertyChanged("LastHeartbeat");
1593          this.OnLastHeartbeatChanged();
1594        }
1595      }
1596    }
1597   
1598    [global::System.Data.Linq.Mapping.ColumnAttribute(Name="JobState", Storage="_State", DbType="VarChar(30)", CanBeNull=false)]
1599    public global::HeuristicLab.Services.Hive.Common.DataTransfer.JobState State
1600    {
1601      get
1602      {
1603        return this._State;
1604      }
1605      set
1606      {
1607        if ((this._State != value))
1608        {
1609          this.OnStateChanging(value);
1610          this.SendPropertyChanging();
1611          this._State = value;
1612          this.SendPropertyChanged("State");
1613          this.OnStateChanged();
1614        }
1615      }
1616    }
1617   
1618    [global::System.Data.Linq.Mapping.AssociationAttribute(Name="Job_AssignedResource", Storage="_AssignedResources", ThisKey="JobId", OtherKey="JobId")]
1619    public EntitySet<AssignedResource> AssignedResources
1620    {
1621      get
1622      {
1623        return this._AssignedResources;
1624      }
1625      set
1626      {
1627        this._AssignedResources.Assign(value);
1628      }
1629    }
1630   
1631    [global::System.Data.Linq.Mapping.AssociationAttribute(Name="Job_RequiredPlugin", Storage="_RequiredPlugins", ThisKey="JobId", OtherKey="JobId")]
1632    public EntitySet<RequiredPlugin> RequiredPlugins
1633    {
1634      get
1635      {
1636        return this._RequiredPlugins;
1637      }
1638      set
1639      {
1640        this._RequiredPlugins.Assign(value);
1641      }
1642    }
1643   
1644    [global::System.Data.Linq.Mapping.AssociationAttribute(Name="Job_Job", Storage="_Jobs", ThisKey="JobId", OtherKey="ParentJobId")]
1645    public EntitySet<Job> ChildJobs
1646    {
1647      get
1648      {
1649        return this._Jobs;
1650      }
1651      set
1652      {
1653        this._Jobs.Assign(value);
1654      }
1655    }
1656   
1657    [global::System.Data.Linq.Mapping.AssociationAttribute(Name="Job_JobData", Storage="_JobData", ThisKey="JobId", OtherKey="JobId", IsUnique=true, IsForeignKey=false)]
1658    public JobData JobData
1659    {
1660      get
1661      {
1662        return this._JobData.Entity;
1663      }
1664      set
1665      {
1666        JobData previousValue = this._JobData.Entity;
1667        if (((previousValue != value)
1668              || (this._JobData.HasLoadedOrAssignedValue == false)))
1669        {
1670          this.SendPropertyChanging();
1671          if ((previousValue != null))
1672          {
1673            this._JobData.Entity = null;
1674            previousValue.Job = null;
1675          }
1676          this._JobData.Entity = value;
1677          if ((value != null))
1678          {
1679            value.Job = this;
1680          }
1681          this.SendPropertyChanged("JobData");
1682        }
1683      }
1684    }
1685   
1686    [global::System.Data.Linq.Mapping.AssociationAttribute(Name="Job_StateLog", Storage="_StateLogs", ThisKey="JobId", OtherKey="JobId")]
1687    public EntitySet<StateLog> StateLogs
1688    {
1689      get
1690      {
1691        return this._StateLogs;
1692      }
1693      set
1694      {
1695        this._StateLogs.Assign(value);
1696      }
1697    }
1698   
1699    [global::System.Data.Linq.Mapping.AssociationAttribute(Name="Job_Job", Storage="_Job1", ThisKey="ParentJobId", OtherKey="JobId", IsForeignKey=true)]
1700    public Job ParentJob
1701    {
1702      get
1703      {
1704        return this._Job1.Entity;
1705      }
1706      set
1707      {
1708        Job previousValue = this._Job1.Entity;
1709        if (((previousValue != value)
1710              || (this._Job1.HasLoadedOrAssignedValue == false)))
1711        {
1712          this.SendPropertyChanging();
1713          if ((previousValue != null))
1714          {
1715            this._Job1.Entity = null;
1716            previousValue.ChildJobs.Remove(this);
1717          }
1718          this._Job1.Entity = value;
1719          if ((value != null))
1720          {
1721            value.ChildJobs.Add(this);
1722            this._ParentJobId = value.JobId;
1723          }
1724          else
1725          {
1726            this._ParentJobId = default(Nullable<System.Guid>);
1727          }
1728          this.SendPropertyChanged("ParentJob");
1729        }
1730      }
1731    }
1732   
1733    public event PropertyChangingEventHandler PropertyChanging;
1734   
1735    public event PropertyChangedEventHandler PropertyChanged;
1736   
1737    protected virtual void SendPropertyChanging()
1738    {
1739      if ((this.PropertyChanging != null))
1740      {
1741        this.PropertyChanging(this, emptyChangingEventArgs);
1742      }
1743    }
1744   
1745    protected virtual void SendPropertyChanged(String propertyName)
1746    {
1747      if ((this.PropertyChanged != null))
1748      {
1749        this.PropertyChanged(this, new PropertyChangedEventArgs(propertyName));
1750      }
1751    }
1752   
1753    private void attach_AssignedResources(AssignedResource entity)
1754    {
1755      this.SendPropertyChanging();
1756      entity.Job = this;
1757    }
1758   
1759    private void detach_AssignedResources(AssignedResource entity)
1760    {
1761      this.SendPropertyChanging();
1762      entity.Job = null;
1763    }
1764   
1765    private void attach_RequiredPlugins(RequiredPlugin entity)
1766    {
1767      this.SendPropertyChanging();
1768      entity.Job = this;
1769    }
1770   
1771    private void detach_RequiredPlugins(RequiredPlugin entity)
1772    {
1773      this.SendPropertyChanging();
1774      entity.Job = null;
1775    }
1776   
1777    private void attach_Jobs(Job entity)
1778    {
1779      this.SendPropertyChanging();
1780      entity.ParentJob = this;
1781    }
1782   
1783    private void detach_Jobs(Job entity)
1784    {
1785      this.SendPropertyChanging();
1786      entity.ParentJob = null;
1787    }
1788   
1789    private void attach_StateLogs(StateLog entity)
1790    {
1791      this.SendPropertyChanging();
1792      entity.Job = this;
1793    }
1794   
1795    private void detach_StateLogs(StateLog entity)
1796    {
1797      this.SendPropertyChanging();
1798      entity.Job = null;
1799    }
1800  }
1801 
1802  [global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.UptimeCalendar")]
1803  public partial class UptimeCalendar : INotifyPropertyChanging, INotifyPropertyChanged
1804  {
1805   
1806    private static PropertyChangingEventArgs emptyChangingEventArgs = new PropertyChangingEventArgs(String.Empty);
1807   
1808    private System.Guid _UptimeCalendarId;
1809   
1810    private System.Guid _ResourceId;
1811   
1812    private System.DateTime _StartDate;
1813   
1814    private System.DateTime _EndDate;
1815   
1816    private bool _AllDayEvent;
1817   
1818    private bool _Recurring;
1819   
1820    private System.Guid _RecurringId;
1821   
1822    private EntityRef<Resource> _Resource;
1823   
1824    #region Extensibility Method Definitions
1825    partial void OnLoaded();
1826    partial void OnValidate(System.Data.Linq.ChangeAction action);
1827    partial void OnCreated();
1828    partial void OnUptimeCalendarIdChanging(System.Guid value);
1829    partial void OnUptimeCalendarIdChanged();
1830    partial void OnResourceIdChanging(System.Guid value);
1831    partial void OnResourceIdChanged();
1832    partial void OnStartDateChanging(System.DateTime value);
1833    partial void OnStartDateChanged();
1834    partial void OnEndDateChanging(System.DateTime value);
1835    partial void OnEndDateChanged();
1836    partial void OnAllDayEventChanging(bool value);
1837    partial void OnAllDayEventChanged();
1838    partial void OnRecurringChanging(bool value);
1839    partial void OnRecurringChanged();
1840    partial void OnRecurringIdChanging(System.Guid value);
1841    partial void OnRecurringIdChanged();
1842    #endregion
1843   
1844    public UptimeCalendar()
1845    {
1846      this._Resource = default(EntityRef<Resource>);
1847      OnCreated();
1848    }
1849   
1850    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_UptimeCalendarId", AutoSync=AutoSync.OnInsert, DbType="UniqueIdentifier", IsPrimaryKey=true, IsDbGenerated=true)]
1851    public System.Guid UptimeCalendarId
1852    {
1853      get
1854      {
1855        return this._UptimeCalendarId;
1856      }
1857      set
1858      {
1859        if ((this._UptimeCalendarId != value))
1860        {
1861          this.OnUptimeCalendarIdChanging(value);
1862          this.SendPropertyChanging();
1863          this._UptimeCalendarId = value;
1864          this.SendPropertyChanged("UptimeCalendarId");
1865          this.OnUptimeCalendarIdChanged();
1866        }
1867      }
1868    }
1869   
1870    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ResourceId", DbType="UniqueIdentifier")]
1871    public System.Guid ResourceId
1872    {
1873      get
1874      {
1875        return this._ResourceId;
1876      }
1877      set
1878      {
1879        if ((this._ResourceId != value))
1880        {
1881          if (this._Resource.HasLoadedOrAssignedValue)
1882          {
1883            throw new System.Data.Linq.ForeignKeyReferenceAlreadyHasValueException();
1884          }
1885          this.OnResourceIdChanging(value);
1886          this.SendPropertyChanging();
1887          this._ResourceId = value;
1888          this.SendPropertyChanged("ResourceId");
1889          this.OnResourceIdChanged();
1890        }
1891      }
1892    }
1893   
1894    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_StartDate", DbType="DateTime")]
1895    public System.DateTime StartDate
1896    {
1897      get
1898      {
1899        return this._StartDate;
1900      }
1901      set
1902      {
1903        if ((this._StartDate != value))
1904        {
1905          this.OnStartDateChanging(value);
1906          this.SendPropertyChanging();
1907          this._StartDate = value;
1908          this.SendPropertyChanged("StartDate");
1909          this.OnStartDateChanged();
1910        }
1911      }
1912    }
1913   
1914    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_EndDate", DbType="DateTime")]
1915    public System.DateTime EndDate
1916    {
1917      get
1918      {
1919        return this._EndDate;
1920      }
1921      set
1922      {
1923        if ((this._EndDate != value))
1924        {
1925          this.OnEndDateChanging(value);
1926          this.SendPropertyChanging();
1927          this._EndDate = value;
1928          this.SendPropertyChanged("EndDate");
1929          this.OnEndDateChanged();
1930        }
1931      }
1932    }
1933   
1934    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_AllDayEvent", DbType="Bit")]
1935    public bool AllDayEvent
1936    {
1937      get
1938      {
1939        return this._AllDayEvent;
1940      }
1941      set
1942      {
1943        if ((this._AllDayEvent != value))
1944        {
1945          this.OnAllDayEventChanging(value);
1946          this.SendPropertyChanging();
1947          this._AllDayEvent = value;
1948          this.SendPropertyChanged("AllDayEvent");
1949          this.OnAllDayEventChanged();
1950        }
1951      }
1952    }
1953   
1954    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Recurring", DbType="Bit")]
1955    public bool Recurring
1956    {
1957      get
1958      {
1959        return this._Recurring;
1960      }
1961      set
1962      {
1963        if ((this._Recurring != value))
1964        {
1965          this.OnRecurringChanging(value);
1966          this.SendPropertyChanging();
1967          this._Recurring = value;
1968          this.SendPropertyChanged("Recurring");
1969          this.OnRecurringChanged();
1970        }
1971      }
1972    }
1973   
1974    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_RecurringId", DbType="UniqueIdentifier")]
1975    public System.Guid RecurringId
1976    {
1977      get
1978      {
1979        return this._RecurringId;
1980      }
1981      set
1982      {
1983        if ((this._RecurringId != value))
1984        {
1985          this.OnRecurringIdChanging(value);
1986          this.SendPropertyChanging();
1987          this._RecurringId = value;
1988          this.SendPropertyChanged("RecurringId");
1989          this.OnRecurringIdChanged();
1990        }
1991      }
1992    }
1993   
1994    [global::System.Data.Linq.Mapping.AssociationAttribute(Name="Resource_UptimeCalendar", Storage="_Resource", ThisKey="ResourceId", OtherKey="ResourceId", IsForeignKey=true, DeleteRule="CASCADE")]
1995    public Resource Resource
1996    {
1997      get
1998      {
1999        return this._Resource.Entity;
2000      }
2001      set
2002      {
2003        Resource previousValue = this._Resource.Entity;
2004        if (((previousValue != value)
2005              || (this._Resource.HasLoadedOrAssignedValue == false)))
2006        {
2007          this.SendPropertyChanging();
2008          if ((previousValue != null))
2009          {
2010            this._Resource.Entity = null;
2011            previousValue.UptimeCalendars.Remove(this);
2012          }
2013          this._Resource.Entity = value;
2014          if ((value != null))
2015          {
2016            value.UptimeCalendars.Add(this);
2017            this._ResourceId = value.ResourceId;
2018          }
2019          else
2020          {
2021            this._ResourceId = default(System.Guid);
2022          }
2023          this.SendPropertyChanged("Resource");
2024        }
2025      }
2026    }
2027   
2028    public event PropertyChangingEventHandler PropertyChanging;
2029   
2030    public event PropertyChangedEventHandler PropertyChanged;
2031   
2032    protected virtual void SendPropertyChanging()
2033    {
2034      if ((this.PropertyChanging != null))
2035      {
2036        this.PropertyChanging(this, emptyChangingEventArgs);
2037      }
2038    }
2039   
2040    protected virtual void SendPropertyChanged(String propertyName)
2041    {
2042      if ((this.PropertyChanged != null))
2043      {
2044        this.PropertyChanged(this, new PropertyChangedEventArgs(propertyName));
2045      }
2046    }
2047  }
2048 
2049  [global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.HiveExperiment")]
2050  public partial class HiveExperiment : INotifyPropertyChanging, INotifyPropertyChanged
2051  {
2052   
2053    private static PropertyChangingEventArgs emptyChangingEventArgs = new PropertyChangingEventArgs(String.Empty);
2054   
2055    private System.Guid _HiveExperimentId;
2056   
2057    private string _Name;
2058   
2059    private string _Description;
2060   
2061    private string _ResourceIds;
2062   
2063    private System.Guid _UserId;
2064   
2065    private System.Guid _RootJobId;
2066   
2067    private System.DateTime _DateCreated;
2068   
2069    private System.Nullable<System.DateTime> _LastAccessed;
2070   
2071    private bool _IsHiveEngine;
2072   
2073    private EntitySet<HiveExperimentPermission> _HiveExperimentPermissions;
2074   
2075    private EntityRef<Job> _Job;
2076   
2077    #region Extensibility Method Definitions
2078    partial void OnLoaded();
2079    partial void OnValidate(System.Data.Linq.ChangeAction action);
2080    partial void OnCreated();
2081    partial void OnHiveExperimentIdChanging(System.Guid value);
2082    partial void OnHiveExperimentIdChanged();
2083    partial void OnNameChanging(string value);
2084    partial void OnNameChanged();
2085    partial void OnDescriptionChanging(string value);
2086    partial void OnDescriptionChanged();
2087    partial void OnResourceIdsChanging(string value);
2088    partial void OnResourceIdsChanged();
2089    partial void OnOwnerUserIdChanging(System.Guid value);
2090    partial void OnOwnerUserIdChanged();
2091    partial void OnRootJobIdChanging(System.Guid value);
2092    partial void OnRootJobIdChanged();
2093    partial void OnDateCreatedChanging(System.DateTime value);
2094    partial void OnDateCreatedChanged();
2095    partial void OnLastAccessedChanging(System.Nullable<System.DateTime> value);
2096    partial void OnLastAccessedChanged();
2097    partial void OnIsHiveEngineChanging(bool value);
2098    partial void OnIsHiveEngineChanged();
2099    #endregion
2100   
2101    public HiveExperiment()
2102    {
2103      this._HiveExperimentPermissions = new EntitySet<HiveExperimentPermission>(new Action<HiveExperimentPermission>(this.attach_HiveExperimentPermissions), new Action<HiveExperimentPermission>(this.detach_HiveExperimentPermissions));
2104      this._Job = default(EntityRef<Job>);
2105      OnCreated();
2106    }
2107   
2108    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_HiveExperimentId", AutoSync=AutoSync.OnInsert, DbType="UniqueIdentifier NOT NULL", IsPrimaryKey=true, IsDbGenerated=true)]
2109    public System.Guid HiveExperimentId
2110    {
2111      get
2112      {
2113        return this._HiveExperimentId;
2114      }
2115      set
2116      {
2117        if ((this._HiveExperimentId != value))
2118        {
2119          this.OnHiveExperimentIdChanging(value);
2120          this.SendPropertyChanging();
2121          this._HiveExperimentId = value;
2122          this.SendPropertyChanged("HiveExperimentId");
2123          this.OnHiveExperimentIdChanged();
2124        }
2125      }
2126    }
2127   
2128    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Name", DbType="VarChar(MAX)", CanBeNull=false)]
2129    public string Name
2130    {
2131      get
2132      {
2133        return this._Name;
2134      }
2135      set
2136      {
2137        if ((this._Name != value))
2138        {
2139          this.OnNameChanging(value);
2140          this.SendPropertyChanging();
2141          this._Name = value;
2142          this.SendPropertyChanged("Name");
2143          this.OnNameChanged();
2144        }
2145      }
2146    }
2147   
2148    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Description", DbType="VarChar(MAX)")]
2149    public string Description
2150    {
2151      get
2152      {
2153        return this._Description;
2154      }
2155      set
2156      {
2157        if ((this._Description != value))
2158        {
2159          this.OnDescriptionChanging(value);
2160          this.SendPropertyChanging();
2161          this._Description = value;
2162          this.SendPropertyChanged("Description");
2163          this.OnDescriptionChanged();
2164        }
2165      }
2166    }
2167   
2168    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ResourceIds", DbType="VarChar(MAX)")]
2169    public string ResourceIds
2170    {
2171      get
2172      {
2173        return this._ResourceIds;
2174      }
2175      set
2176      {
2177        if ((this._ResourceIds != value))
2178        {
2179          this.OnResourceIdsChanging(value);
2180          this.SendPropertyChanging();
2181          this._ResourceIds = value;
2182          this.SendPropertyChanged("ResourceIds");
2183          this.OnResourceIdsChanged();
2184        }
2185      }
2186    }
2187   
2188    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_UserId", DbType="UniqueIdentifier")]
2189    public System.Guid OwnerUserId
2190    {
2191      get
2192      {
2193        return this._UserId;
2194      }
2195      set
2196      {
2197        if ((this._UserId != value))
2198        {
2199          this.OnOwnerUserIdChanging(value);
2200          this.SendPropertyChanging();
2201          this._UserId = value;
2202          this.SendPropertyChanged("OwnerUserId");
2203          this.OnOwnerUserIdChanged();
2204        }
2205      }
2206    }
2207   
2208    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_RootJobId", DbType="UniqueIdentifier")]
2209    public System.Guid RootJobId
2210    {
2211      get
2212      {
2213        return this._RootJobId;
2214      }
2215      set
2216      {
2217        if ((this._RootJobId != value))
2218        {
2219          if (this._Job.HasLoadedOrAssignedValue)
2220          {
2221            throw new System.Data.Linq.ForeignKeyReferenceAlreadyHasValueException();
2222          }
2223          this.OnRootJobIdChanging(value);
2224          this.SendPropertyChanging();
2225          this._RootJobId = value;
2226          this.SendPropertyChanged("RootJobId");
2227          this.OnRootJobIdChanged();
2228        }
2229      }
2230    }
2231   
2232    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_DateCreated", DbType="DateTime")]
2233    public System.DateTime DateCreated
2234    {
2235      get
2236      {
2237        return this._DateCreated;
2238      }
2239      set
2240      {
2241        if ((this._DateCreated != value))
2242        {
2243          this.OnDateCreatedChanging(value);
2244          this.SendPropertyChanging();
2245          this._DateCreated = value;
2246          this.SendPropertyChanged("DateCreated");
2247          this.OnDateCreatedChanged();
2248        }
2249      }
2250    }
2251   
2252    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_LastAccessed", DbType="DateTime")]
2253    public System.Nullable<System.DateTime> LastAccessed
2254    {
2255      get
2256      {
2257        return this._LastAccessed;
2258      }
2259      set
2260      {
2261        if ((this._LastAccessed != value))
2262        {
2263          this.OnLastAccessedChanging(value);
2264          this.SendPropertyChanging();
2265          this._LastAccessed = value;
2266          this.SendPropertyChanged("LastAccessed");
2267          this.OnLastAccessedChanged();
2268        }
2269      }
2270    }
2271   
2272    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_IsHiveEngine", DbType="Bit")]
2273    public bool IsHiveEngine
2274    {
2275      get
2276      {
2277        return this._IsHiveEngine;
2278      }
2279      set
2280      {
2281        if ((this._IsHiveEngine != value))
2282        {
2283          this.OnIsHiveEngineChanging(value);
2284          this.SendPropertyChanging();
2285          this._IsHiveEngine = value;
2286          this.SendPropertyChanged("IsHiveEngine");
2287          this.OnIsHiveEngineChanged();
2288        }
2289      }
2290    }
2291   
2292    [global::System.Data.Linq.Mapping.AssociationAttribute(Name="HiveExperiment_HiveExperimentPermission", Storage="_HiveExperimentPermissions", ThisKey="HiveExperimentId", OtherKey="HiveExperimentId")]
2293    public EntitySet<HiveExperimentPermission> HiveExperimentPermissions
2294    {
2295      get
2296      {
2297        return this._HiveExperimentPermissions;
2298      }
2299      set
2300      {
2301        this._HiveExperimentPermissions.Assign(value);
2302      }
2303    }
2304   
2305    [global::System.Data.Linq.Mapping.AssociationAttribute(Name="Job_HiveExperiment", Storage="_Job", ThisKey="RootJobId", OtherKey="JobId", IsForeignKey=true, DeleteRule="CASCADE")]
2306    public Job RootJob
2307    {
2308      get
2309      {
2310        return this._Job.Entity;
2311      }
2312      set
2313      {
2314        if ((this._Job.Entity != value))
2315        {
2316          this.SendPropertyChanging();
2317          this._Job.Entity = value;
2318          this.SendPropertyChanged("RootJob");
2319        }
2320      }
2321    }
2322   
2323    public event PropertyChangingEventHandler PropertyChanging;
2324   
2325    public event PropertyChangedEventHandler PropertyChanged;
2326   
2327    protected virtual void SendPropertyChanging()
2328    {
2329      if ((this.PropertyChanging != null))
2330      {
2331        this.PropertyChanging(this, emptyChangingEventArgs);
2332      }
2333    }
2334   
2335    protected virtual void SendPropertyChanged(String propertyName)
2336    {
2337      if ((this.PropertyChanged != null))
2338      {
2339        this.PropertyChanged(this, new PropertyChangedEventArgs(propertyName));
2340      }
2341    }
2342   
2343    private void attach_HiveExperimentPermissions(HiveExperimentPermission entity)
2344    {
2345      this.SendPropertyChanging();
2346      entity.HiveExperiment = this;
2347    }
2348   
2349    private void detach_HiveExperimentPermissions(HiveExperimentPermission entity)
2350    {
2351      this.SendPropertyChanging();
2352      entity.HiveExperiment = null;
2353    }
2354  }
2355 
2356  [global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.JobData")]
2357  public partial class JobData : INotifyPropertyChanging, INotifyPropertyChanged
2358  {
2359   
2360    private static PropertyChangingEventArgs emptyChangingEventArgs = new PropertyChangingEventArgs(String.Empty);
2361   
2362    private System.Guid _JobId;
2363   
2364    private System.Data.Linq.Binary _Data;
2365   
2366    private System.DateTime _LastUpdate;
2367   
2368    private EntityRef<Job> _Job;
2369   
2370    #region Extensibility Method Definitions
2371    partial void OnLoaded();
2372    partial void OnValidate(System.Data.Linq.ChangeAction action);
2373    partial void OnCreated();
2374    partial void OnJobIdChanging(System.Guid value);
2375    partial void OnJobIdChanged();
2376    partial void OnDataChanging(System.Data.Linq.Binary value);
2377    partial void OnDataChanged();
2378    partial void OnLastUpdateChanging(System.DateTime value);
2379    partial void OnLastUpdateChanged();
2380    #endregion
2381   
2382    public JobData()
2383    {
2384      this._Job = default(EntityRef<Job>);
2385      OnCreated();
2386    }
2387   
2388    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_JobId", DbType="UniqueIdentifier NOT NULL", IsPrimaryKey=true)]
2389    public System.Guid JobId
2390    {
2391      get
2392      {
2393        return this._JobId;
2394      }
2395      set
2396      {
2397        if ((this._JobId != value))
2398        {
2399          if (this._Job.HasLoadedOrAssignedValue)
2400          {
2401            throw new System.Data.Linq.ForeignKeyReferenceAlreadyHasValueException();
2402          }
2403          this.OnJobIdChanging(value);
2404          this.SendPropertyChanging();
2405          this._JobId = value;
2406          this.SendPropertyChanged("JobId");
2407          this.OnJobIdChanged();
2408        }
2409      }
2410    }
2411   
2412    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Data", DbType="VarBinary(MAX)", CanBeNull=false, UpdateCheck=UpdateCheck.Never)]
2413    public System.Data.Linq.Binary Data
2414    {
2415      get
2416      {
2417        return this._Data;
2418      }
2419      set
2420      {
2421        if ((this._Data != value))
2422        {
2423          this.OnDataChanging(value);
2424          this.SendPropertyChanging();
2425          this._Data = value;
2426          this.SendPropertyChanged("Data");
2427          this.OnDataChanged();
2428        }
2429      }
2430    }
2431   
2432    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_LastUpdate", DbType="DateTime")]
2433    public System.DateTime LastUpdate
2434    {
2435      get
2436      {
2437        return this._LastUpdate;
2438      }
2439      set
2440      {
2441        if ((this._LastUpdate != value))
2442        {
2443          this.OnLastUpdateChanging(value);
2444          this.SendPropertyChanging();
2445          this._LastUpdate = value;
2446          this.SendPropertyChanged("LastUpdate");
2447          this.OnLastUpdateChanged();
2448        }
2449      }
2450    }
2451   
2452    [global::System.Data.Linq.Mapping.AssociationAttribute(Name="Job_JobData", Storage="_Job", ThisKey="JobId", OtherKey="JobId", IsForeignKey=true)]
2453    public Job Job
2454    {
2455      get
2456      {
2457        return this._Job.Entity;
2458      }
2459      set
2460      {
2461        Job previousValue = this._Job.Entity;
2462        if (((previousValue != value)
2463              || (this._Job.HasLoadedOrAssignedValue == false)))
2464        {
2465          this.SendPropertyChanging();
2466          if ((previousValue != null))
2467          {
2468            this._Job.Entity = null;
2469            previousValue.JobData = null;
2470          }
2471          this._Job.Entity = value;
2472          if ((value != null))
2473          {
2474            value.JobData = this;
2475            this._JobId = value.JobId;
2476          }
2477          else
2478          {
2479            this._JobId = default(System.Guid);
2480          }
2481          this.SendPropertyChanged("Job");
2482        }
2483      }
2484    }
2485   
2486    public event PropertyChangingEventHandler PropertyChanging;
2487   
2488    public event PropertyChangedEventHandler PropertyChanged;
2489   
2490    protected virtual void SendPropertyChanging()
2491    {
2492      if ((this.PropertyChanging != null))
2493      {
2494        this.PropertyChanging(this, emptyChangingEventArgs);
2495      }
2496    }
2497   
2498    protected virtual void SendPropertyChanged(String propertyName)
2499    {
2500      if ((this.PropertyChanged != null))
2501      {
2502        this.PropertyChanged(this, new PropertyChangedEventArgs(propertyName));
2503      }
2504    }
2505  }
2506 
2507  [global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.PluginData")]
2508  public partial class PluginData : INotifyPropertyChanging, INotifyPropertyChanged
2509  {
2510   
2511    private static PropertyChangingEventArgs emptyChangingEventArgs = new PropertyChangingEventArgs(String.Empty);
2512   
2513    private System.Guid _PluginDataId;
2514   
2515    private System.Guid _PluginId;
2516   
2517    private System.Data.Linq.Binary _Data;
2518   
2519    private string _FileName;
2520   
2521    private EntityRef<Plugin> _Plugin;
2522   
2523    #region Extensibility Method Definitions
2524    partial void OnLoaded();
2525    partial void OnValidate(System.Data.Linq.ChangeAction action);
2526    partial void OnCreated();
2527    partial void OnPluginDataIdChanging(System.Guid value);
2528    partial void OnPluginDataIdChanged();
2529    partial void OnPluginIdChanging(System.Guid value);
2530    partial void OnPluginIdChanged();
2531    partial void OnDataChanging(System.Data.Linq.Binary value);
2532    partial void OnDataChanged();
2533    partial void OnFileNameChanging(string value);
2534    partial void OnFileNameChanged();
2535    #endregion
2536   
2537    public PluginData()
2538    {
2539      this._Plugin = default(EntityRef<Plugin>);
2540      OnCreated();
2541    }
2542   
2543    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_PluginDataId", AutoSync=AutoSync.OnInsert, DbType="UniqueIdentifier NOT NULL", IsPrimaryKey=true, IsDbGenerated=true)]
2544    public System.Guid PluginDataId
2545    {
2546      get
2547      {
2548        return this._PluginDataId;
2549      }
2550      set
2551      {
2552        if ((this._PluginDataId != value))
2553        {
2554          this.OnPluginDataIdChanging(value);
2555          this.SendPropertyChanging();
2556          this._PluginDataId = value;
2557          this.SendPropertyChanged("PluginDataId");
2558          this.OnPluginDataIdChanged();
2559        }
2560      }
2561    }
2562   
2563    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_PluginId", DbType="UniqueIdentifier NOT NULL")]
2564    public System.Guid PluginId
2565    {
2566      get
2567      {
2568        return this._PluginId;
2569      }
2570      set
2571      {
2572        if ((this._PluginId != value))
2573        {
2574          if (this._Plugin.HasLoadedOrAssignedValue)
2575          {
2576            throw new System.Data.Linq.ForeignKeyReferenceAlreadyHasValueException();
2577          }
2578          this.OnPluginIdChanging(value);
2579          this.SendPropertyChanging();
2580          this._PluginId = value;
2581          this.SendPropertyChanged("PluginId");
2582          this.OnPluginIdChanged();
2583        }
2584      }
2585    }
2586   
2587    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Data", DbType="VarBinary(MAX) NOT NULL", CanBeNull=false, UpdateCheck=UpdateCheck.Never)]
2588    public System.Data.Linq.Binary Data
2589    {
2590      get
2591      {
2592        return this._Data;
2593      }
2594      set
2595      {
2596        if ((this._Data != value))
2597        {
2598          this.OnDataChanging(value);
2599          this.SendPropertyChanging();
2600          this._Data = value;
2601          this.SendPropertyChanged("Data");
2602          this.OnDataChanged();
2603        }
2604      }
2605    }
2606   
2607    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_FileName", DbType="VarChar(MAX)", CanBeNull=false)]
2608    public string FileName
2609    {
2610      get
2611      {
2612        return this._FileName;
2613      }
2614      set
2615      {
2616        if ((this._FileName != value))
2617        {
2618          this.OnFileNameChanging(value);
2619          this.SendPropertyChanging();
2620          this._FileName = value;
2621          this.SendPropertyChanged("FileName");
2622          this.OnFileNameChanged();
2623        }
2624      }
2625    }
2626   
2627    [global::System.Data.Linq.Mapping.AssociationAttribute(Name="Plugin_PluginData", Storage="_Plugin", ThisKey="PluginId", OtherKey="PluginId", IsForeignKey=true)]
2628    public Plugin Plugin
2629    {
2630      get
2631      {
2632        return this._Plugin.Entity;
2633      }
2634      set
2635      {
2636        Plugin previousValue = this._Plugin.Entity;
2637        if (((previousValue != value)
2638              || (this._Plugin.HasLoadedOrAssignedValue == false)))
2639        {
2640          this.SendPropertyChanging();
2641          if ((previousValue != null))
2642          {
2643            this._Plugin.Entity = null;
2644            previousValue.PluginData.Remove(this);
2645          }
2646          this._Plugin.Entity = value;
2647          if ((value != null))
2648          {
2649            value.PluginData.Add(this);
2650            this._PluginId = value.PluginId;
2651          }
2652          else
2653          {
2654            this._PluginId = default(System.Guid);
2655          }
2656          this.SendPropertyChanged("Plugin");
2657        }
2658      }
2659    }
2660   
2661    public event PropertyChangingEventHandler PropertyChanging;
2662   
2663    public event PropertyChangedEventHandler PropertyChanged;
2664   
2665    protected virtual void SendPropertyChanging()
2666    {
2667      if ((this.PropertyChanging != null))
2668      {
2669        this.PropertyChanging(this, emptyChangingEventArgs);
2670      }
2671    }
2672   
2673    protected virtual void SendPropertyChanged(String propertyName)
2674    {
2675      if ((this.PropertyChanged != null))
2676      {
2677        this.PropertyChanged(this, new PropertyChangedEventArgs(propertyName));
2678      }
2679    }
2680  }
2681 
2682  [global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.StateLog")]
2683  public partial class StateLog : INotifyPropertyChanging, INotifyPropertyChanged
2684  {
2685   
2686    private static PropertyChangingEventArgs emptyChangingEventArgs = new PropertyChangingEventArgs(String.Empty);
2687   
2688    private System.Guid _StateLogId;
2689   
2690    private global::HeuristicLab.Services.Hive.Common.DataTransfer.JobState _State;
2691   
2692    private System.DateTime _DateTime;
2693   
2694    private System.Guid _JobId;
2695   
2696    private System.Nullable<System.Guid> _UserId;
2697   
2698    private System.Nullable<System.Guid> _SlaveId;
2699   
2700    private string _Exception;
2701   
2702    private EntityRef<Job> _Job;
2703   
2704    private EntityRef<Resource> _Resource;
2705   
2706    #region Extensibility Method Definitions
2707    partial void OnLoaded();
2708    partial void OnValidate(System.Data.Linq.ChangeAction action);
2709    partial void OnCreated();
2710    partial void OnStateLogIdChanging(System.Guid value);
2711    partial void OnStateLogIdChanged();
2712    partial void OnStateChanging(global::HeuristicLab.Services.Hive.Common.DataTransfer.JobState value);
2713    partial void OnStateChanged();
2714    partial void OnDateTimeChanging(System.DateTime value);
2715    partial void OnDateTimeChanged();
2716    partial void OnJobIdChanging(System.Guid value);
2717    partial void OnJobIdChanged();
2718    partial void OnUserIdChanging(System.Nullable<System.Guid> value);
2719    partial void OnUserIdChanged();
2720    partial void OnSlaveIdChanging(System.Nullable<System.Guid> value);
2721    partial void OnSlaveIdChanged();
2722    partial void OnExceptionChanging(string value);
2723    partial void OnExceptionChanged();
2724    #endregion
2725   
2726    public StateLog()
2727    {
2728      this._Job = default(EntityRef<Job>);
2729      this._Resource = default(EntityRef<Resource>);
2730      OnCreated();
2731    }
2732   
2733    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_StateLogId", AutoSync=AutoSync.OnInsert, DbType="UniqueIdentifier NOT NULL", IsPrimaryKey=true, IsDbGenerated=true)]
2734    public System.Guid StateLogId
2735    {
2736      get
2737      {
2738        return this._StateLogId;
2739      }
2740      set
2741      {
2742        if ((this._StateLogId != value))
2743        {
2744          this.OnStateLogIdChanging(value);
2745          this.SendPropertyChanging();
2746          this._StateLogId = value;
2747          this.SendPropertyChanged("StateLogId");
2748          this.OnStateLogIdChanged();
2749        }
2750      }
2751    }
2752   
2753    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_State", DbType="VarChar(30) NOT NULL", CanBeNull=false)]
2754    public global::HeuristicLab.Services.Hive.Common.DataTransfer.JobState State
2755    {
2756      get
2757      {
2758        return this._State;
2759      }
2760      set
2761      {
2762        if ((this._State != value))
2763        {
2764          this.OnStateChanging(value);
2765          this.SendPropertyChanging();
2766          this._State = value;
2767          this.SendPropertyChanged("State");
2768          this.OnStateChanged();
2769        }
2770      }
2771    }
2772   
2773    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_DateTime", DbType="DateTime NOT NULL")]
2774    public System.DateTime DateTime
2775    {
2776      get
2777      {
2778        return this._DateTime;
2779      }
2780      set
2781      {
2782        if ((this._DateTime != value))
2783        {
2784          this.OnDateTimeChanging(value);
2785          this.SendPropertyChanging();
2786          this._DateTime = value;
2787          this.SendPropertyChanged("DateTime");
2788          this.OnDateTimeChanged();
2789        }
2790      }
2791    }
2792   
2793    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_JobId", DbType="UniqueIdentifier NOT NULL")]
2794    public System.Guid JobId
2795    {
2796      get
2797      {
2798        return this._JobId;
2799      }
2800      set
2801      {
2802        if ((this._JobId != value))
2803        {
2804          if (this._Job.HasLoadedOrAssignedValue)
2805          {
2806            throw new System.Data.Linq.ForeignKeyReferenceAlreadyHasValueException();
2807          }
2808          this.OnJobIdChanging(value);
2809          this.SendPropertyChanging();
2810          this._JobId = value;
2811          this.SendPropertyChanged("JobId");
2812          this.OnJobIdChanged();
2813        }
2814      }
2815    }
2816   
2817    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_UserId", DbType="UniqueIdentifier")]
2818    public System.Nullable<System.Guid> UserId
2819    {
2820      get
2821      {
2822        return this._UserId;
2823      }
2824      set
2825      {
2826        if ((this._UserId != value))
2827        {
2828          this.OnUserIdChanging(value);
2829          this.SendPropertyChanging();
2830          this._UserId = value;
2831          this.SendPropertyChanged("UserId");
2832          this.OnUserIdChanged();
2833        }
2834      }
2835    }
2836   
2837    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_SlaveId", DbType="UniqueIdentifier")]
2838    public System.Nullable<System.Guid> SlaveId
2839    {
2840      get
2841      {
2842        return this._SlaveId;
2843      }
2844      set
2845      {
2846        if ((this._SlaveId != value))
2847        {
2848          if (this._Resource.HasLoadedOrAssignedValue)
2849          {
2850            throw new System.Data.Linq.ForeignKeyReferenceAlreadyHasValueException();
2851          }
2852          this.OnSlaveIdChanging(value);
2853          this.SendPropertyChanging();
2854          this._SlaveId = value;
2855          this.SendPropertyChanged("SlaveId");
2856          this.OnSlaveIdChanged();
2857        }
2858      }
2859    }
2860   
2861    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Exception", DbType="VarChar(MAX)", CanBeNull=false)]
2862    public string Exception
2863    {
2864      get
2865      {
2866        return this._Exception;
2867      }
2868      set
2869      {
2870        if ((this._Exception != value))
2871        {
2872          this.OnExceptionChanging(value);
2873          this.SendPropertyChanging();
2874          this._Exception = value;
2875          this.SendPropertyChanged("Exception");
2876          this.OnExceptionChanged();
2877        }
2878      }
2879    }
2880   
2881    [global::System.Data.Linq.Mapping.AssociationAttribute(Name="Job_StateLog", Storage="_Job", ThisKey="JobId", OtherKey="JobId", IsForeignKey=true)]
2882    public Job Job
2883    {
2884      get
2885      {
2886        return this._Job.Entity;
2887      }
2888      set
2889      {
2890        Job previousValue = this._Job.Entity;
2891        if (((previousValue != value)
2892              || (this._Job.HasLoadedOrAssignedValue == false)))
2893        {
2894          this.SendPropertyChanging();
2895          if ((previousValue != null))
2896          {
2897            this._Job.Entity = null;
2898            previousValue.StateLogs.Remove(this);
2899          }
2900          this._Job.Entity = value;
2901          if ((value != null))
2902          {
2903            value.StateLogs.Add(this);
2904            this._JobId = value.JobId;
2905          }
2906          else
2907          {
2908            this._JobId = default(System.Guid);
2909          }
2910          this.SendPropertyChanged("Job");
2911        }
2912      }
2913    }
2914   
2915    [global::System.Data.Linq.Mapping.AssociationAttribute(Name="Resource_StateLog", Storage="_Resource", ThisKey="SlaveId", OtherKey="ResourceId", IsForeignKey=true)]
2916    public Resource Resource
2917    {
2918      get
2919      {
2920        return this._Resource.Entity;
2921      }
2922      set
2923      {
2924        Resource previousValue = this._Resource.Entity;
2925        if (((previousValue != value)
2926              || (this._Resource.HasLoadedOrAssignedValue == false)))
2927        {
2928          this.SendPropertyChanging();
2929          if ((previousValue != null))
2930          {
2931            this._Resource.Entity = null;
2932            previousValue.StateLogs.Remove(this);
2933          }
2934          this._Resource.Entity = value;
2935          if ((value != null))
2936          {
2937            value.StateLogs.Add(this);
2938            this._SlaveId = value.ResourceId;
2939          }
2940          else
2941          {
2942            this._SlaveId = default(Nullable<System.Guid>);
2943          }
2944          this.SendPropertyChanged("Resource");
2945        }
2946      }
2947    }
2948   
2949    public event PropertyChangingEventHandler PropertyChanging;
2950   
2951    public event PropertyChangedEventHandler PropertyChanged;
2952   
2953    protected virtual void SendPropertyChanging()
2954    {
2955      if ((this.PropertyChanging != null))
2956      {
2957        this.PropertyChanging(this, emptyChangingEventArgs);
2958      }
2959    }
2960   
2961    protected virtual void SendPropertyChanged(String propertyName)
2962    {
2963      if ((this.PropertyChanged != null))
2964      {
2965        this.PropertyChanged(this, new PropertyChangedEventArgs(propertyName));
2966      }
2967    }
2968  }
2969 
2970  [global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.HiveExperimentPermission")]
2971  public partial class HiveExperimentPermission : INotifyPropertyChanging, INotifyPropertyChanged
2972  {
2973   
2974    private static PropertyChangingEventArgs emptyChangingEventArgs = new PropertyChangingEventArgs(String.Empty);
2975   
2976    private System.Guid _HiveExperimentId;
2977   
2978    private System.Guid _GrantedUserId;
2979   
2980    private System.Guid _GrantedByUserId;
2981   
2982    private global::HeuristicLab.Services.Hive.Common.DataTransfer.Permission _Permission;
2983   
2984    private EntityRef<HiveExperiment> _HiveExperiment;
2985   
2986    #region Extensibility Method Definitions
2987    partial void OnLoaded();
2988    partial void OnValidate(System.Data.Linq.ChangeAction action);
2989    partial void OnCreated();
2990    partial void OnHiveExperimentIdChanging(System.Guid value);
2991    partial void OnHiveExperimentIdChanged();
2992    partial void OnGrantedUserIdChanging(System.Guid value);
2993    partial void OnGrantedUserIdChanged();
2994    partial void OnGrantedByUserIdChanging(System.Guid value);
2995    partial void OnGrantedByUserIdChanged();
2996    partial void OnPermissionChanging(global::HeuristicLab.Services.Hive.Common.DataTransfer.Permission value);
2997    partial void OnPermissionChanged();
2998    #endregion
2999   
3000    public HiveExperimentPermission()
3001    {
3002      this._HiveExperiment = default(EntityRef<HiveExperiment>);
3003      OnCreated();
3004    }
3005   
3006    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_HiveExperimentId", DbType="UniqueIdentifier NOT NULL", IsPrimaryKey=true)]
3007    public System.Guid HiveExperimentId
3008    {
3009      get
3010      {
3011        return this._HiveExperimentId;
3012      }
3013      set
3014      {
3015        if ((this._HiveExperimentId != value))
3016        {
3017          if (this._HiveExperiment.HasLoadedOrAssignedValue)
3018          {
3019            throw new System.Data.Linq.ForeignKeyReferenceAlreadyHasValueException();
3020          }
3021          this.OnHiveExperimentIdChanging(value);
3022          this.SendPropertyChanging();
3023          this._HiveExperimentId = value;
3024          this.SendPropertyChanged("HiveExperimentId");
3025          this.OnHiveExperimentIdChanged();
3026        }
3027      }
3028    }
3029   
3030    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_GrantedUserId", DbType="UniqueIdentifier NOT NULL", IsPrimaryKey=true)]
3031    public System.Guid GrantedUserId
3032    {
3033      get
3034      {
3035        return this._GrantedUserId;
3036      }
3037      set
3038      {
3039        if ((this._GrantedUserId != value))
3040        {
3041          this.OnGrantedUserIdChanging(value);
3042          this.SendPropertyChanging();
3043          this._GrantedUserId = value;
3044          this.SendPropertyChanged("GrantedUserId");
3045          this.OnGrantedUserIdChanged();
3046        }
3047      }
3048    }
3049   
3050    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_GrantedByUserId", DbType="UniqueIdentifier NOT NULL")]
3051    public System.Guid GrantedByUserId
3052    {
3053      get
3054      {
3055        return this._GrantedByUserId;
3056      }
3057      set
3058      {
3059        if ((this._GrantedByUserId != value))
3060        {
3061          this.OnGrantedByUserIdChanging(value);
3062          this.SendPropertyChanging();
3063          this._GrantedByUserId = value;
3064          this.SendPropertyChanged("GrantedByUserId");
3065          this.OnGrantedByUserIdChanged();
3066        }
3067      }
3068    }
3069   
3070    [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Permission", DbType="VarChar(15) NOT NULL", CanBeNull=false)]
3071    public global::HeuristicLab.Services.Hive.Common.DataTransfer.Permission Permission
3072    {
3073      get
3074      {
3075        return this._Permission;
3076      }
3077      set
3078      {
3079        if ((this._Permission != value))
3080        {
3081          this.OnPermissionChanging(value);
3082          this.SendPropertyChanging();
3083          this._Permission = value;
3084          this.SendPropertyChanged("Permission");
3085          this.OnPermissionChanged();
3086        }
3087      }
3088    }
3089   
3090    [global::System.Data.Linq.Mapping.AssociationAttribute(Name="HiveExperiment_HiveExperimentPermission", Storage="_HiveExperiment", ThisKey="HiveExperimentId", OtherKey="HiveExperimentId", IsForeignKey=true)]
3091    public HiveExperiment HiveExperiment
3092    {
3093      get
3094      {
3095        return this._HiveExperiment.Entity;
3096      }
3097      set
3098      {
3099        HiveExperiment previousValue = this._HiveExperiment.Entity;
3100        if (((previousValue != value)
3101              || (this._HiveExperiment.HasLoadedOrAssignedValue == false)))
3102        {
3103          this.SendPropertyChanging();
3104          if ((previousValue != null))
3105          {
3106            this._HiveExperiment.Entity = null;
3107            previousValue.HiveExperimentPermissions.Remove(this);
3108          }
3109          this._HiveExperiment.Entity = value;
3110          if ((value != null))
3111          {
3112            value.HiveExperimentPermissions.Add(this);
3113            this._HiveExperimentId = value.HiveExperimentId;
3114          }
3115          else
3116          {
3117            this._HiveExperimentId = default(System.Guid);
3118          }
3119          this.SendPropertyChanged("HiveExperiment");
3120        }
3121      }
3122    }
3123   
3124    public event PropertyChangingEventHandler PropertyChanging;
3125   
3126    public event PropertyChangedEventHandler PropertyChanged;
3127   
3128    protected virtual void SendPropertyChanging()
3129    {
3130      if ((this.PropertyChanging != null))
3131      {
3132        this.PropertyChanging(this, emptyChangingEventArgs);
3133      }
3134    }
3135   
3136    protected virtual void SendPropertyChanged(String propertyName)
3137    {
3138      if ((this.PropertyChanged != null))
3139      {
3140        this.PropertyChanged(this, new PropertyChangedEventArgs(propertyName));
3141      }
3142    }
3143  }
3144}
3145#pragma warning restore 1591
Note: See TracBrowser for help on using the repository browser.