Index: branches/OKB (trunk integration)/HeuristicLab.Services.OKB.DataAccess/3.3/OKB.dbml
===================================================================
--- branches/OKB (trunk integration)/HeuristicLab.Services.OKB.DataAccess/3.3/OKB.dbml	(revision 5459)
+++ branches/OKB (trunk integration)/HeuristicLab.Services.OKB.DataAccess/3.3/OKB.dbml	(revision 5478)
@@ -36,5 +36,4 @@
       <Column Name="Name" Type="System.String" DbType="NVarChar(200) NOT NULL" CanBeNull="false" />
       <Column Name="Description" Type="System.String" DbType="NVarChar(MAX)" CanBeNull="true" />
-      <Association Name="Platform_DataType" Member="DataTypes" ThisKey="Id" OtherKey="PlatformId" Type="DataType" />
       <Association Name="Platform_Algorithm" Member="Algorithms" ThisKey="Id" OtherKey="PlatformId" Type="Algorithm" />
       <Association Name="Platform_Problem" Member="Problems" ThisKey="Id" OtherKey="PlatformId" Type="Problem" />
@@ -44,5 +43,4 @@
     <Type Name="DataType">
       <Column Name="Id" Type="System.Int64" DbType="BigInt NOT NULL IDENTITY" IsPrimaryKey="true" IsDbGenerated="true" CanBeNull="false" />
-      <Column Name="PlatformId" Type="System.Int64" DbType="BigInt NOT NULL" CanBeNull="false" />
       <Column Name="Name" Type="System.String" DbType="NVarChar(200) NOT NULL" CanBeNull="false" />
       <Column Name="TypeName" Type="System.String" DbType="NVarChar(MAX) NOT NULL" CanBeNull="false" />
@@ -51,5 +49,4 @@
       <Association Name="DataType_Value" Member="Values" ThisKey="Id" OtherKey="DataTypeId" Type="Value" />
       <Association Name="DataType_CharacteristicValue" Member="CharacteristicValues" ThisKey="Id" OtherKey="DataTypeId" Type="CharacteristicValue" />
-      <Association Name="Platform_DataType" Member="Platform" ThisKey="PlatformId" OtherKey="Id" Type="Platform" IsForeignKey="true" />
     </Type>
   </Table>
Index: branches/OKB (trunk integration)/HeuristicLab.Services.OKB.DataAccess/3.3/OKB.dbml.layout
===================================================================
--- branches/OKB (trunk integration)/HeuristicLab.Services.OKB.DataAccess/3.3/OKB.dbml.layout	(revision 5459)
+++ branches/OKB (trunk integration)/HeuristicLab.Services.OKB.DataAccess/3.3/OKB.dbml.layout	(revision 5478)
@@ -33,17 +33,10 @@
       </nestedChildShapes>
     </classShape>
-    <classShape Id="34f5a12b-f109-4606-baf8-6ddfde7c1b34" absoluteBounds="7, 2.125, 2, 1.5785953776041666">
+    <classShape Id="34f5a12b-f109-4606-baf8-6ddfde7c1b34" absoluteBounds="7, 2.125, 2, 1.3862939453125">
       <DataClassMoniker Name="/OKBDataContext/DataType" />
       <nestedChildShapes>
-        <elementListCompartment Id="1dacac40-e283-48e9-a98d-dddbc6b4fd48" absoluteBounds="7.0150000000000006, 2.585, 1.9700000000000002, 1.0185953776041665" name="DataPropertiesCompartment" titleTextColor="Black" itemTextColor="Black" />
-      </nestedChildShapes>
-    </classShape>
-    <associationConnector edgePoints="[(8 : 1.8862939453125); (8 : 2.125)]" fixedFrom="NotFixed" fixedTo="NotFixed">
-      <AssociationMoniker Name="/OKBDataContext/Platform/Platform_DataType" />
-      <nodes>
-        <classShapeMoniker Id="42a9e8c0-3168-43f0-a31f-54d1558bd4c2" />
-        <classShapeMoniker Id="34f5a12b-f109-4606-baf8-6ddfde7c1b34" />
-      </nodes>
-    </associationConnector>
+        <elementListCompartment Id="1dacac40-e283-48e9-a98d-dddbc6b4fd48" absoluteBounds="7.0150000000000006, 2.585, 1.9700000000000002, 0.8262939453125" name="DataPropertiesCompartment" titleTextColor="Black" itemTextColor="Black" />
+      </nestedChildShapes>
+    </classShape>
     <classShape Id="c75911bf-ae6d-421c-9219-e027c3059390" absoluteBounds="3.5, 4, 2, 1.5785953776041666">
       <DataClassMoniker Name="/OKBDataContext/ValueName" />
@@ -58,5 +51,5 @@
       </nestedChildShapes>
     </classShape>
-    <associationConnector edgePoints="[(2.75 : 2.39024983723958); (2.5 : 2.39024983723958)]" fixedFrom="Algorithm" fixedTo="Algorithm">
+    <associationConnector edgePoints="[(2.75 : 2.39024983723958); (2.5 : 2.39024983723958)]" fixedFrom="NotFixed" fixedTo="NotFixed">
       <AssociationMoniker Name="/OKBDataContext/Algorithm/Algorithm_AlgorithmUser" />
       <nodes>
@@ -72,5 +65,5 @@
       </nodes>
     </associationConnector>
-    <associationConnector edgePoints="[(7 : 2.39024983723958); (4.75 : 2.39024983723958)]" fixedFrom="NotFixed" fixedTo="NotFixed">
+    <associationConnector edgePoints="[(7 : 2.39024983723958); (4.75 : 2.39024983723958)]" fixedFrom="Algorithm" fixedTo="Algorithm">
       <AssociationMoniker Name="/OKBDataContext/DataType/DataType_Algorithm" />
       <nodes>
@@ -92,5 +85,5 @@
       </nestedChildShapes>
     </classShape>
-    <associationConnector edgePoints="[(13.25 : 2.39024983723958); (13.5 : 2.39024983723958)]" fixedFrom="Algorithm" fixedTo="Algorithm">
+    <associationConnector edgePoints="[(13.25 : 2.39024983723958); (13.5 : 2.39024983723958)]" fixedFrom="NotFixed" fixedTo="NotFixed">
       <AssociationMoniker Name="/OKBDataContext/Problem/Problem_ProblemUser" />
       <nodes>
@@ -99,5 +92,5 @@
       </nodes>
     </associationConnector>
-    <associationConnector edgePoints="[(9 : 2.39024983723958); (11.25 : 2.39024983723958)]" fixedFrom="NotFixed" fixedTo="NotFixed">
+    <associationConnector edgePoints="[(9 : 2.39024983723958); (11.25 : 2.39024983723958)]" fixedFrom="Algorithm" fixedTo="Algorithm">
       <AssociationMoniker Name="/OKBDataContext/DataType/DataType_Problem" />
       <nodes>
@@ -126,5 +119,5 @@
       </nestedChildShapes>
     </classShape>
-    <associationConnector edgePoints="[(7 : 10.3181469726562); (2.98333686713063 : 10.3181469726562); (2.98333686713063 : 2.65549967447917)]" fixedFrom="Algorithm" fixedTo="Algorithm">
+    <associationConnector edgePoints="[(7 : 10.3181469726562); (2.98333686713063 : 10.3181469726562); (2.98333686713063 : 2.65549967447917)]" fixedFrom="NotFixed" fixedTo="NotFixed">
       <AssociationMoniker Name="/OKBDataContext/BinaryData/BinaryData_Algorithm" />
       <nodes>
@@ -133,5 +126,5 @@
       </nodes>
     </associationConnector>
-    <associationConnector edgePoints="[(9 : 10.3181469726562); (13.0131477507419 : 10.3181469726562); (13.0131477507419 : 2.65549967447917)]" fixedFrom="Algorithm" fixedTo="Algorithm">
+    <associationConnector edgePoints="[(9 : 10.3181469726562); (13.0131477507419 : 10.3181469726562); (13.0131477507419 : 2.65549967447917)]" fixedFrom="NotFixed" fixedTo="NotFixed">
       <AssociationMoniker Name="/OKBDataContext/BinaryData/BinaryData_Problem" />
       <nodes>
@@ -173,5 +166,5 @@
       </nodes>
     </associationConnector>
-    <associationConnector edgePoints="[(7 : 3.07568669800201); (6.6959048132675 : 3.07568669800201); (6.6959048132675 : 4)]" fixedFrom="NotFixed" fixedTo="NotFixed">
+    <associationConnector edgePoints="[(7.273878302532 : 3.5112939453125); (7.273878302532 : 4)]" fixedFrom="Caller" fixedTo="Algorithm">
       <AssociationMoniker Name="/OKBDataContext/DataType/DataType_Value" />
       <nodes>
@@ -213,5 +206,5 @@
       </nodes>
     </associationConnector>
-    <associationConnector edgePoints="[(9 : 3.05278498857512); (9.24152226977744 : 3.05278498857512); (9.24152226977744 : 4)]" fixedFrom="NotFixed" fixedTo="NotFixed">
+    <associationConnector edgePoints="[(8.68784173221247 : 3.5112939453125); (8.68784173221247 : 4)]" fixedFrom="Caller" fixedTo="Algorithm">
       <AssociationMoniker Name="/OKBDataContext/DataType/DataType_CharacteristicValue" />
       <nodes>
Index: branches/OKB (trunk integration)/HeuristicLab.Services.OKB.DataAccess/3.3/OKB.designer.cs
===================================================================
--- branches/OKB (trunk integration)/HeuristicLab.Services.OKB.DataAccess/3.3/OKB.designer.cs	(revision 5459)
+++ branches/OKB (trunk integration)/HeuristicLab.Services.OKB.DataAccess/3.3/OKB.designer.cs	(revision 5478)
@@ -760,6 +760,4 @@
 		private string _Description;
 		
-		private EntitySet<DataType> _DataTypes;
-		
 		private EntitySet<Algorithm> _Algorithms;
 		
@@ -780,5 +778,4 @@
 		public Platform()
 		{
-			this._DataTypes = new EntitySet<DataType>(new Action<DataType>(this.attach_DataTypes), new Action<DataType>(this.detach_DataTypes));
 			this._Algorithms = new EntitySet<Algorithm>(new Action<Algorithm>(this.attach_Algorithms), new Action<Algorithm>(this.detach_Algorithms));
 			this._Problems = new EntitySet<Problem>(new Action<Problem>(this.attach_Problems), new Action<Problem>(this.detach_Problems));
@@ -846,17 +843,4 @@
 		}
 		
-		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="Platform_DataType", Storage="_DataTypes", ThisKey="Id", OtherKey="PlatformId")]
-		public EntitySet<DataType> DataTypes
-		{
-			get
-			{
-				return this._DataTypes;
-			}
-			set
-			{
-				this._DataTypes.Assign(value);
-			}
-		}
-		
 		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="Platform_Algorithm", Storage="_Algorithms", ThisKey="Id", OtherKey="PlatformId")]
 		public EntitySet<Algorithm> Algorithms
@@ -903,16 +887,4 @@
 				this.PropertyChanged(this, new PropertyChangedEventArgs(propertyName));
 			}
-		}
-		
-		private void attach_DataTypes(DataType entity)
-		{
-			this.SendPropertyChanging();
-			entity.Platform = this;
-		}
-		
-		private void detach_DataTypes(DataType entity)
-		{
-			this.SendPropertyChanging();
-			entity.Platform = null;
 		}
 		
@@ -950,6 +922,4 @@
 		private long _Id;
 		
-		private long _PlatformId;
-		
 		private string _Name;
 		
@@ -963,6 +933,4 @@
 		
 		private EntitySet<CharacteristicValue> _CharacteristicValues;
-		
-		private EntityRef<Platform> _Platform;
 		
     #region Extensibility Method Definitions
@@ -972,6 +940,4 @@
     partial void OnIdChanging(long value);
     partial void OnIdChanged();
-    partial void OnPlatformIdChanging(long value);
-    partial void OnPlatformIdChanged();
     partial void OnNameChanging(string value);
     partial void OnNameChanged();
@@ -986,5 +952,4 @@
 			this._Values = new EntitySet<Value>(new Action<Value>(this.attach_Values), new Action<Value>(this.detach_Values));
 			this._CharacteristicValues = new EntitySet<CharacteristicValue>(new Action<CharacteristicValue>(this.attach_CharacteristicValues), new Action<CharacteristicValue>(this.detach_CharacteristicValues));
-			this._Platform = default(EntityRef<Platform>);
 			OnCreated();
 		}
@@ -1010,28 +975,4 @@
 		}
 		
-		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_PlatformId", DbType="BigInt NOT NULL")]
-		public long PlatformId
-		{
-			get
-			{
-				return this._PlatformId;
-			}
-			set
-			{
-				if ((this._PlatformId != value))
-				{
-					if (this._Platform.HasLoadedOrAssignedValue)
-					{
-						throw new System.Data.Linq.ForeignKeyReferenceAlreadyHasValueException();
-					}
-					this.OnPlatformIdChanging(value);
-					this.SendPropertyChanging();
-					this._PlatformId = value;
-					this.SendPropertyChanged("PlatformId");
-					this.OnPlatformIdChanged();
-				}
-			}
-		}
-		
 		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Name", DbType="NVarChar(200) NOT NULL", CanBeNull=false)]
 		public string Name
@@ -1123,38 +1064,4 @@
 			{
 				this._CharacteristicValues.Assign(value);
-			}
-		}
-		
-		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="Platform_DataType", Storage="_Platform", ThisKey="PlatformId", OtherKey="Id", IsForeignKey=true)]
-		public Platform Platform
-		{
-			get
-			{
-				return this._Platform.Entity;
-			}
-			set
-			{
-				Platform previousValue = this._Platform.Entity;
-				if (((previousValue != value) 
-							|| (this._Platform.HasLoadedOrAssignedValue == false)))
-				{
-					this.SendPropertyChanging();
-					if ((previousValue != null))
-					{
-						this._Platform.Entity = null;
-						previousValue.DataTypes.Remove(this);
-					}
-					this._Platform.Entity = value;
-					if ((value != null))
-					{
-						value.DataTypes.Add(this);
-						this._PlatformId = value.Id;
-					}
-					else
-					{
-						this._PlatformId = default(long);
-					}
-					this.SendPropertyChanged("Platform");
-				}
 			}
 		}
Index: branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/HeuristicLab.Services.OKB-3.3.csproj
===================================================================
--- branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/HeuristicLab.Services.OKB-3.3.csproj	(revision 5459)
+++ branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/HeuristicLab.Services.OKB-3.3.csproj	(revision 5478)
@@ -164,4 +164,21 @@
     <Compile Include="Interfaces\IFilter.cs" />
     <Compile Include="Properties\AssemblyInfo.cs" />
+    <Compile Include="RunCreation\Convert.cs" />
+    <Compile Include="RunCreation\DataTransfer\Algorithm.cs" />
+    <Compile Include="RunCreation\DataTransfer\AlgorithmClass.cs" />
+    <Compile Include="RunCreation\DataTransfer\BinaryValue.cs" />
+    <Compile Include="RunCreation\DataTransfer\BoolValue.cs" />
+    <Compile Include="RunCreation\DataTransfer\DataType.cs" />
+    <Compile Include="RunCreation\DataTransfer\DoubleValue.cs" />
+    <Compile Include="RunCreation\DataTransfer\FloatValue.cs" />
+    <Compile Include="RunCreation\DataTransfer\IntValue.cs" />
+    <Compile Include="RunCreation\DataTransfer\LongValue.cs" />
+    <Compile Include="RunCreation\DataTransfer\Problem.cs" />
+    <Compile Include="RunCreation\DataTransfer\ProblemClass.cs" />
+    <Compile Include="RunCreation\DataTransfer\Run.cs" />
+    <Compile Include="RunCreation\DataTransfer\StringValue.cs" />
+    <Compile Include="RunCreation\DataTransfer\Value.cs" />
+    <Compile Include="RunCreation\RunCreationService.cs" />
+    <Compile Include="RunCreation\IRunCreationService.cs" />
   </ItemGroup>
   <ItemGroup>
@@ -181,4 +198,12 @@
       <Name>HeuristicLab.Services.OKB.DataTransfer-3.3</Name>
     </ProjectReference>
+  </ItemGroup>
+  <ItemGroup>
+    <Folder Include="Administration\" />
+    <Folder Include="Authentication\" />
+    <Folder Include="Query\" />
+  </ItemGroup>
+  <ItemGroup>
+    <Service Include="{3259AA49-8AA1-44D3-9025-A0B520596A8C}" />
   </ItemGroup>
   <Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" />
Index: branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/Convert.cs
===================================================================
--- branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/Convert.cs	(revision 5478)
+++ branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/Convert.cs	(revision 5478)
@@ -0,0 +1,129 @@
+﻿#region License Information
+/* HeuristicLab
+ * Copyright (C) 2002-2010 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
+ *
+ * This file is part of HeuristicLab.
+ *
+ * HeuristicLab is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * HeuristicLab is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with HeuristicLab. If not, see <http://www.gnu.org/licenses/>.
+ */
+#endregion
+
+using System;
+using System.Linq;
+using System.Security.Cryptography;
+using DA = HeuristicLab.Services.OKB.DataAccess;
+using DT = HeuristicLab.Services.OKB.RunCreation.DataTransfer;
+
+namespace HeuristicLab.Services.OKB.RunCreation {
+  public static class Convert {
+    #region ToDto
+    public static DT.Algorithm ToDto(DA.Algorithm source) {
+      if (source == null) return null;
+      return new DT.Algorithm { Id = source.Id, Name = source.Name, Description = source.Description, AlgorithmClass = Convert.ToDto(source.AlgorithmClass), DataType = Convert.ToDto(source.DataType) };
+    }
+
+    public static DT.Problem ToDto(DA.Problem source) {
+      if (source == null) return null;
+      return new DT.Problem { Id = source.Id, Name = source.Name, Description = source.Description, ProblemClass = Convert.ToDto(source.ProblemClass), DataType = Convert.ToDto(source.DataType) };
+    }
+
+    private static DT.DataType ToDto(DA.DataType source) {
+      if (source == null) return null;
+      return new DT.DataType { Name = source.Name, TypeName = source.TypeName };
+    }
+
+    private static DT.AlgorithmClass ToDto(DA.AlgorithmClass source) {
+      if (source == null) return null;
+      return new DT.AlgorithmClass { Name = source.Name, Description = source.Description };
+    }
+
+    private static DT.ProblemClass ToDto(DA.ProblemClass source) {
+      if (source == null) return null;
+      return new DT.ProblemClass { Name = source.Name, Description = source.Description };
+    }
+    #endregion
+
+    #region ToEntity
+    public static DA.Run ToEntity(DT.Run source, DA.OKBDataContext okb) {
+      if (source == null) return null;
+      DA.Run entity = new DA.Run { Id = 0, AlgorithmId = source.AlgorithmId, ProblemId = source.ProblemId, RandomSeed = source.RandomSeed, CreatedDate = source.CreatedDate, UserId = source.UserId, ClientId = source.ClientId };
+      foreach (var value in source.ParameterValues)
+        entity.Values.Add(Convert.ToEntity(value, entity, DA.ValueNameCategory.Parameter, okb));
+      foreach (var value in source.ResultValues)
+        entity.Values.Add(Convert.ToEntity(value, entity, DA.ValueNameCategory.Result, okb));
+      return entity;
+    }
+
+    private static DA.Value ToEntity(DT.Value source, DA.Run run, DA.ValueNameCategory category, DA.OKBDataContext okb) {
+      if (source == null) return null;
+      var entity = new DA.Value();
+      entity.Run = run;
+      entity.DataType = Convert.ToEntity(source.DataType, okb);
+      if (source is DT.BoolValue) {
+        entity.ValueName = Convert.ToEntity(source.Name, category, DA.ValueNameType.Bool, okb);
+        entity.BoolValue = ((DT.BoolValue)source).Value;
+      } else if (source is DT.IntValue) {
+        entity.ValueName = Convert.ToEntity(source.Name, category, DA.ValueNameType.Int, okb);
+        entity.IntValue = ((DT.IntValue)source).Value;
+      } else if (source is DT.LongValue) {
+        entity.ValueName = Convert.ToEntity(source.Name, category, DA.ValueNameType.Long, okb);
+        entity.LongValue = ((DT.LongValue)source).Value;
+      } else if (source is DT.FloatValue) {
+        entity.ValueName = Convert.ToEntity(source.Name, category, DA.ValueNameType.Float, okb);
+        entity.FloatValue = ((DT.FloatValue)source).Value;
+      } else if (source is DT.DoubleValue) {
+        entity.ValueName = Convert.ToEntity(source.Name, category, DA.ValueNameType.Double, okb);
+        entity.DoubleValue = ((DT.DoubleValue)source).Value;
+      } else if (source is DT.StringValue) {
+        entity.ValueName = Convert.ToEntity(source.Name, category, DA.ValueNameType.String, okb);
+        entity.StringValue = ((DT.StringValue)source).Value;
+      } else if (source is DT.BinaryValue) {
+        entity.ValueName = Convert.ToEntity(source.Name, category, DA.ValueNameType.Binary, okb);
+        entity.BinaryData = Convert.ToEntity(((DT.BinaryValue)source).Value, okb);
+      } else {
+        throw new ArgumentException("Unknown value type.", "source");
+      }
+      return entity;
+    }
+
+    private static DA.DataType ToEntity(DT.DataType source, DA.OKBDataContext okb) {
+      if (source == null) return null;
+      var entity = okb.DataTypes.Where(x => (x.Name == source.Name) && (x.TypeName == source.TypeName)).FirstOrDefault();
+      if (entity == null)
+        entity = new DA.DataType() { Id = 0, Name = source.Name, TypeName = source.TypeName };
+      return entity;
+    }
+
+    private static DA.ValueName ToEntity(string name, DA.ValueNameCategory category, DA.ValueNameType type, DA.OKBDataContext okb) {
+      if (string.IsNullOrEmpty(name)) return null;
+      var entity = okb.ValueNames.Where(x => (x.Name == name) && (x.Category == category) && (x.Type == type)).FirstOrDefault();
+      if (entity == null)
+        entity = new DA.ValueName() { Id = 0, Name = name, Category = category, Type = type };
+      return entity;
+    }
+
+    private static DA.BinaryData ToEntity(byte[] data, DA.OKBDataContext okb) {
+      if (data == null) return null;
+      byte[] hash;
+      using (SHA1 sha1 = SHA1.Create()) {
+        hash = sha1.ComputeHash(data);
+      }
+      var entity = okb.BinaryDatas.Where(x => x.Hash.Equals(hash)).FirstOrDefault();
+      if (entity == null)
+        entity = new DA.BinaryData() { Id = 0, Data = data };
+      return entity;
+    }
+    #endregion
+  }
+}
Index: branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/DataTransfer/Algorithm.cs
===================================================================
--- branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/DataTransfer/Algorithm.cs	(revision 5478)
+++ branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/DataTransfer/Algorithm.cs	(revision 5478)
@@ -0,0 +1,38 @@
+﻿#region License Information
+/* HeuristicLab
+ * Copyright (C) 2002-2010 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
+ *
+ * This file is part of HeuristicLab.
+ *
+ * HeuristicLab is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * HeuristicLab is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with HeuristicLab. If not, see <http://www.gnu.org/licenses/>.
+ */
+#endregion
+
+using System.Runtime.Serialization;
+
+namespace HeuristicLab.Services.OKB.RunCreation.DataTransfer {
+  [DataContract]
+  public class Algorithm {
+    [DataMember]
+    public long Id { get; set; }
+    [DataMember]
+    public string Name { get; set; }
+    [DataMember]
+    public string Description { get; set; }
+    [DataMember]
+    public AlgorithmClass AlgorithmClass { get; set; }
+    [DataMember]
+    public DataType DataType { get; set; }
+  }
+}
Index: branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/DataTransfer/AlgorithmClass.cs
===================================================================
--- branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/DataTransfer/AlgorithmClass.cs	(revision 5478)
+++ branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/DataTransfer/AlgorithmClass.cs	(revision 5478)
@@ -0,0 +1,32 @@
+﻿#region License Information
+/* HeuristicLab
+ * Copyright (C) 2002-2010 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
+ *
+ * This file is part of HeuristicLab.
+ *
+ * HeuristicLab is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * HeuristicLab is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with HeuristicLab. If not, see <http://www.gnu.org/licenses/>.
+ */
+#endregion
+
+using System.Runtime.Serialization;
+
+namespace HeuristicLab.Services.OKB.RunCreation.DataTransfer {
+  [DataContract]
+  public class AlgorithmClass {
+    [DataMember]
+    public string Name { get; set; }
+    [DataMember]
+    public string Description { get; set; }
+  }
+}
Index: branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/DataTransfer/BinaryValue.cs
===================================================================
--- branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/DataTransfer/BinaryValue.cs	(revision 5478)
+++ branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/DataTransfer/BinaryValue.cs	(revision 5478)
@@ -0,0 +1,30 @@
+﻿#region License Information
+/* HeuristicLab
+ * Copyright (C) 2002-2010 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
+ *
+ * This file is part of HeuristicLab.
+ *
+ * HeuristicLab is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * HeuristicLab is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with HeuristicLab. If not, see <http://www.gnu.org/licenses/>.
+ */
+#endregion
+
+using System.Runtime.Serialization;
+
+namespace HeuristicLab.Services.OKB.RunCreation.DataTransfer {
+  [DataContract]
+  public class BinaryValue : Value {
+    [DataMember]
+    public byte[] Value { get; set; }
+  }
+}
Index: branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/DataTransfer/BoolValue.cs
===================================================================
--- branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/DataTransfer/BoolValue.cs	(revision 5478)
+++ branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/DataTransfer/BoolValue.cs	(revision 5478)
@@ -0,0 +1,30 @@
+﻿#region License Information
+/* HeuristicLab
+ * Copyright (C) 2002-2010 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
+ *
+ * This file is part of HeuristicLab.
+ *
+ * HeuristicLab is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * HeuristicLab is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with HeuristicLab. If not, see <http://www.gnu.org/licenses/>.
+ */
+#endregion
+
+using System.Runtime.Serialization;
+
+namespace HeuristicLab.Services.OKB.RunCreation.DataTransfer {
+  [DataContract]
+  public class BoolValue : Value {
+    [DataMember]
+    public bool Value { get; set; }
+  }
+}
Index: branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/DataTransfer/DataType.cs
===================================================================
--- branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/DataTransfer/DataType.cs	(revision 5478)
+++ branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/DataTransfer/DataType.cs	(revision 5478)
@@ -0,0 +1,32 @@
+﻿#region License Information
+/* HeuristicLab
+ * Copyright (C) 2002-2010 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
+ *
+ * This file is part of HeuristicLab.
+ *
+ * HeuristicLab is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * HeuristicLab is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with HeuristicLab. If not, see <http://www.gnu.org/licenses/>.
+ */
+#endregion
+
+using System.Runtime.Serialization;
+
+namespace HeuristicLab.Services.OKB.RunCreation.DataTransfer {
+  [DataContract]
+  public class DataType {
+    [DataMember]
+    public string Name { get; set; }
+    [DataMember]
+    public string TypeName { get; set; }
+  }
+}
Index: branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/DataTransfer/DoubleValue.cs
===================================================================
--- branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/DataTransfer/DoubleValue.cs	(revision 5478)
+++ branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/DataTransfer/DoubleValue.cs	(revision 5478)
@@ -0,0 +1,30 @@
+﻿#region License Information
+/* HeuristicLab
+ * Copyright (C) 2002-2010 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
+ *
+ * This file is part of HeuristicLab.
+ *
+ * HeuristicLab is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * HeuristicLab is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with HeuristicLab. If not, see <http://www.gnu.org/licenses/>.
+ */
+#endregion
+
+using System.Runtime.Serialization;
+
+namespace HeuristicLab.Services.OKB.RunCreation.DataTransfer {
+  [DataContract]
+  public class DoubleValue : Value {
+    [DataMember]
+    public double Value { get; set; }
+  }
+}
Index: branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/DataTransfer/FloatValue.cs
===================================================================
--- branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/DataTransfer/FloatValue.cs	(revision 5478)
+++ branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/DataTransfer/FloatValue.cs	(revision 5478)
@@ -0,0 +1,30 @@
+﻿#region License Information
+/* HeuristicLab
+ * Copyright (C) 2002-2010 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
+ *
+ * This file is part of HeuristicLab.
+ *
+ * HeuristicLab is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * HeuristicLab is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with HeuristicLab. If not, see <http://www.gnu.org/licenses/>.
+ */
+#endregion
+
+using System.Runtime.Serialization;
+
+namespace HeuristicLab.Services.OKB.RunCreation.DataTransfer {
+  [DataContract]
+  public class FloatValue : Value {
+    [DataMember]
+    public float Value { get; set; }
+  }
+}
Index: branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/DataTransfer/IntValue.cs
===================================================================
--- branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/DataTransfer/IntValue.cs	(revision 5478)
+++ branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/DataTransfer/IntValue.cs	(revision 5478)
@@ -0,0 +1,30 @@
+﻿#region License Information
+/* HeuristicLab
+ * Copyright (C) 2002-2010 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
+ *
+ * This file is part of HeuristicLab.
+ *
+ * HeuristicLab is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * HeuristicLab is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with HeuristicLab. If not, see <http://www.gnu.org/licenses/>.
+ */
+#endregion
+
+using System.Runtime.Serialization;
+
+namespace HeuristicLab.Services.OKB.RunCreation.DataTransfer {
+  [DataContract]
+  public class IntValue : Value {
+    [DataMember]
+    public int Value { get; set; }
+  }
+}
Index: branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/DataTransfer/LongValue.cs
===================================================================
--- branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/DataTransfer/LongValue.cs	(revision 5478)
+++ branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/DataTransfer/LongValue.cs	(revision 5478)
@@ -0,0 +1,30 @@
+﻿#region License Information
+/* HeuristicLab
+ * Copyright (C) 2002-2010 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
+ *
+ * This file is part of HeuristicLab.
+ *
+ * HeuristicLab is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * HeuristicLab is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with HeuristicLab. If not, see <http://www.gnu.org/licenses/>.
+ */
+#endregion
+
+using System.Runtime.Serialization;
+
+namespace HeuristicLab.Services.OKB.RunCreation.DataTransfer {
+  [DataContract]
+  public class LongValue : Value {
+    [DataMember]
+    public long Value { get; set; }
+  }
+}
Index: branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/DataTransfer/Problem.cs
===================================================================
--- branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/DataTransfer/Problem.cs	(revision 5478)
+++ branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/DataTransfer/Problem.cs	(revision 5478)
@@ -0,0 +1,38 @@
+﻿#region License Information
+/* HeuristicLab
+ * Copyright (C) 2002-2010 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
+ *
+ * This file is part of HeuristicLab.
+ *
+ * HeuristicLab is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * HeuristicLab is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with HeuristicLab. If not, see <http://www.gnu.org/licenses/>.
+ */
+#endregion
+
+using System.Runtime.Serialization;
+
+namespace HeuristicLab.Services.OKB.RunCreation.DataTransfer {
+  [DataContract]
+  public class Problem {
+    [DataMember]
+    public long Id { get; set; }
+    [DataMember]
+    public string Name { get; set; }
+    [DataMember]
+    public string Description { get; set; }
+    [DataMember]
+    public ProblemClass ProblemClass { get; set; }
+    [DataMember]
+    public DataType DataType { get; set; }
+  }
+}
Index: branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/DataTransfer/ProblemClass.cs
===================================================================
--- branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/DataTransfer/ProblemClass.cs	(revision 5478)
+++ branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/DataTransfer/ProblemClass.cs	(revision 5478)
@@ -0,0 +1,32 @@
+﻿#region License Information
+/* HeuristicLab
+ * Copyright (C) 2002-2010 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
+ *
+ * This file is part of HeuristicLab.
+ *
+ * HeuristicLab is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * HeuristicLab is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with HeuristicLab. If not, see <http://www.gnu.org/licenses/>.
+ */
+#endregion
+
+using System.Runtime.Serialization;
+
+namespace HeuristicLab.Services.OKB.RunCreation.DataTransfer {
+  [DataContract]
+  public class ProblemClass {
+    [DataMember]
+    public string Name { get; set; }
+    [DataMember]
+    public string Description { get; set; }
+  }
+}
Index: branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/DataTransfer/Run.cs
===================================================================
--- branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/DataTransfer/Run.cs	(revision 5478)
+++ branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/DataTransfer/Run.cs	(revision 5478)
@@ -0,0 +1,46 @@
+﻿#region License Information
+/* HeuristicLab
+ * Copyright (C) 2002-2010 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
+ *
+ * This file is part of HeuristicLab.
+ *
+ * HeuristicLab is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * HeuristicLab is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with HeuristicLab. If not, see <http://www.gnu.org/licenses/>.
+ */
+#endregion
+
+using System;
+using System.Collections.Generic;
+using System.Runtime.Serialization;
+
+namespace HeuristicLab.Services.OKB.RunCreation.DataTransfer {
+  [DataContract]
+  public class Run {
+    [DataMember]
+    public long AlgorithmId { get; set; }
+    [DataMember]
+    public long ProblemId { get; set; }
+    [DataMember]
+    public int RandomSeed { get; set; }
+    [DataMember]
+    public DateTime CreatedDate { get; set; }
+    [DataMember]
+    public Guid UserId { get; set; }
+    [DataMember]
+    public Guid ClientId { get; set; }
+    [DataMember]
+    public IEnumerable<Value> ParameterValues { get; set; }
+    [DataMember]
+    public IEnumerable<Value> ResultValues { get; set; }
+  }
+}
Index: branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/DataTransfer/StringValue.cs
===================================================================
--- branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/DataTransfer/StringValue.cs	(revision 5478)
+++ branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/DataTransfer/StringValue.cs	(revision 5478)
@@ -0,0 +1,30 @@
+﻿#region License Information
+/* HeuristicLab
+ * Copyright (C) 2002-2010 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
+ *
+ * This file is part of HeuristicLab.
+ *
+ * HeuristicLab is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * HeuristicLab is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with HeuristicLab. If not, see <http://www.gnu.org/licenses/>.
+ */
+#endregion
+
+using System.Runtime.Serialization;
+
+namespace HeuristicLab.Services.OKB.RunCreation.DataTransfer {
+  [DataContract]
+  public class StringValue : Value {
+    [DataMember]
+    public string Value { get; set; }
+  }
+}
Index: branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/DataTransfer/Value.cs
===================================================================
--- branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/DataTransfer/Value.cs	(revision 5478)
+++ branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/DataTransfer/Value.cs	(revision 5478)
@@ -0,0 +1,39 @@
+﻿#region License Information
+/* HeuristicLab
+ * Copyright (C) 2002-2010 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
+ *
+ * This file is part of HeuristicLab.
+ *
+ * HeuristicLab is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * HeuristicLab is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with HeuristicLab. If not, see <http://www.gnu.org/licenses/>.
+ */
+#endregion
+
+using System.Runtime.Serialization;
+
+namespace HeuristicLab.Services.OKB.RunCreation.DataTransfer {
+  [DataContract]
+  [KnownType(typeof(BoolValue))]
+  [KnownType(typeof(IntValue))]
+  [KnownType(typeof(LongValue))]
+  [KnownType(typeof(FloatValue))]
+  [KnownType(typeof(DoubleValue))]
+  [KnownType(typeof(StringValue))]
+  [KnownType(typeof(BinaryValue))]
+  public abstract class Value {
+    [DataMember]
+    public string Name { get; set; }
+    [DataMember]
+    public DataType DataType { get; set; }
+  }
+}
Index: branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/IRunCreationService.cs
===================================================================
--- branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/IRunCreationService.cs	(revision 5478)
+++ branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/IRunCreationService.cs	(revision 5478)
@@ -0,0 +1,48 @@
+﻿#region License Information
+/* HeuristicLab
+ * Copyright (C) 2002-2010 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
+ *
+ * This file is part of HeuristicLab.
+ *
+ * HeuristicLab is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * HeuristicLab is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with HeuristicLab. If not, see <http://www.gnu.org/licenses/>.
+ */
+#endregion
+
+using System.Collections.Generic;
+using System.Net.Security;
+using System.ServiceModel;
+using HeuristicLab.Services.OKB.RunCreation.DataTransfer;
+
+namespace HeuristicLab.Services.OKB.RunCreation {
+  /// <summary>
+  /// Interface of the OKB run creation service.
+  /// </summary>
+  [ServiceContract(ProtectionLevel = ProtectionLevel.EncryptAndSign)]
+  public interface IRunCreationService {
+    [OperationContract]
+    IEnumerable<Algorithm> GetAlgorithms(string platformName);
+
+    [OperationContract]
+    byte[] GetAlgorithmData(long algorithmId);
+
+    [OperationContract]
+    IEnumerable<Problem> GetProblems(string platformName);
+
+    [OperationContract]
+    byte[] GetProblemData(long problemId);
+
+    [OperationContract]
+    long AddRun(Run run);
+  }
+}
Index: branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/RunCreationService.cs
===================================================================
--- branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/RunCreationService.cs	(revision 5478)
+++ branches/OKB (trunk integration)/HeuristicLab.Services.OKB/3.3/RunCreation/RunCreationService.cs	(revision 5478)
@@ -0,0 +1,75 @@
+﻿#region License Information
+/* HeuristicLab
+ * Copyright (C) 2002-2010 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
+ *
+ * This file is part of HeuristicLab.
+ *
+ * HeuristicLab is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * HeuristicLab is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with HeuristicLab. If not, see <http://www.gnu.org/licenses/>.
+ */
+#endregion
+
+using System.Collections.Generic;
+using System.Data.Linq;
+using System.Linq;
+using System.ServiceModel;
+using HeuristicLab.Services.OKB.DataAccess;
+
+namespace HeuristicLab.Services.OKB.RunCreation {
+  /// <summary>
+  /// Implementation of the OKB run creation service (interface <see cref="IRunCreationService"/>).
+  /// </summary>
+  [ServiceBehavior(IncludeExceptionDetailInFaults = true)]
+  public class RunCreationService : IRunCreationService {
+    public IEnumerable<DataTransfer.Algorithm> GetAlgorithms(string platformName) {
+      using (OKBDataContext okb = new OKBDataContext()) {
+        DataLoadOptions dlo = new DataLoadOptions();
+        dlo.LoadWith<Algorithm>(x => x.AlgorithmClass);
+        dlo.LoadWith<Algorithm>(x => x.DataType);
+        okb.LoadOptions = dlo;
+        return okb.Algorithms.Where(x => x.Platform.Name == platformName).Select(x => Convert.ToDto(x)).ToArray();
+      }
+    }
+
+    public byte[] GetAlgorithmData(long algorithmId) {
+      using (OKBDataContext okb = new OKBDataContext()) {
+        return okb.Algorithms.Where(x => x.Id == algorithmId).Select(x => x.BinaryData.Data.ToArray()).FirstOrDefault();
+      }
+    }
+
+    public IEnumerable<DataTransfer.Problem> GetProblems(string platformName) {
+      using (OKBDataContext okb = new OKBDataContext()) {
+        DataLoadOptions dlo = new DataLoadOptions();
+        dlo.LoadWith<Problem>(x => x.ProblemClass);
+        dlo.LoadWith<Problem>(x => x.DataType);
+        okb.LoadOptions = dlo;
+        return okb.Problems.Where(x => x.Platform.Name == platformName).Select(x => Convert.ToDto(x)).ToArray();
+      }
+    }
+
+    public byte[] GetProblemData(long problemId) {
+      using (OKBDataContext okb = new OKBDataContext()) {
+        return okb.Problems.Where(x => x.Id == problemId).Select(x => x.BinaryData.Data.ToArray()).FirstOrDefault();
+      }
+    }
+
+    public long AddRun(DataTransfer.Run run) {
+      using (OKBDataContext okb = new OKBDataContext()) {
+        DataAccess.Run entity = Convert.ToEntity(run, okb);
+        okb.Runs.InsertOnSubmit(entity);
+        okb.SubmitChanges();
+        return entity.Id;
+      }
+    }
+  }
+}
