Index: branches/OptimizationNetworks/HeuristicLab.Problems.FacilityLocation/3.3/FacilityLocationProblem.cs
===================================================================
--- branches/OptimizationNetworks/HeuristicLab.Problems.FacilityLocation/3.3/FacilityLocationProblem.cs	(revision 14587)
+++ branches/OptimizationNetworks/HeuristicLab.Problems.FacilityLocation/3.3/FacilityLocationProblem.cs	(revision 14607)
@@ -37,5 +37,5 @@
   [Creatable(CreatableAttribute.Categories.CombinatorialProblems, Priority = 230)]
   [StorableClass]
-  public class FacilityLocationProblem : SingleObjectiveBasicProblem<IntegerVectorEncoding> {
+  public sealed class FacilityLocationProblem : SingleObjectiveBasicProblem<IntegerVectorEncoding> {
     public override bool Maximization {
       get { return false; }
@@ -67,6 +67,6 @@
 
     [StorableConstructor]
-    protected FacilityLocationProblem(bool deserializing) : base(deserializing) { }
-    protected FacilityLocationProblem(FacilityLocationProblem original, Cloner cloner)
+    private FacilityLocationProblem(bool deserializing) : base(deserializing) { }
+    private FacilityLocationProblem(FacilityLocationProblem original, Cloner cloner)
       : base(original, cloner) {
       openingCostsParameter = cloner.Clone(original.openingCostsParameter);
@@ -153,5 +153,5 @@
     }
 
-    public virtual double Evaluate(IntegerVector depotAssignment) {
+    public double Evaluate(IntegerVector depotAssignment) {
       var openingCosts = OpeningCostsParameter.Value;
       var capacities = DepotCapacitiesParameter.Value;
@@ -163,17 +163,41 @@
 
       try {
-        Evaluate(depotAssignment, openingCosts, capacities, demands, deliveryCosts, out totalOpeningCosts, out totalDeliveryCosts, out depotUsage);
+        return Evaluate(depotAssignment, openingCosts, capacities, demands, deliveryCosts, out totalOpeningCosts, out totalDeliveryCosts, out depotUsage);
       } catch (IndexOutOfRangeException) {
         throw new ArgumentException("The solution contains more customers than there are problem data for.");
       }
+    }
+
+    public FacilityLocationSolution GetSolution(IntegerVector depotAssignment) {
+      var openingCosts = OpeningCostsParameter.Value;
+      var capacities = DepotCapacitiesParameter.Value;
+      var demands = CustomerDemandsParameter.Value;
+      var deliveryCosts = DeliveryCostsParameter.Value;
+
+      double totalOpeningCosts, totalDeliveryCosts, fitness;
+      double[] depotUsage;
+
+      try {
+        fitness = Evaluate(depotAssignment, openingCosts, capacities, demands, deliveryCosts, out totalOpeningCosts, out totalDeliveryCosts, out depotUsage);
+      } catch (IndexOutOfRangeException) {
+        throw new ArgumentException("The solution contains more customers than there are problem data for.");
+      }
 
       var overbooking = depotUsage.Zip(capacities, (a, b) => a > b ? a - b : 0).Sum();
-      if (overbooking > 0) // infeasible
-        return openingCosts.Sum() + deliveryCosts.Sum() + overbooking;
-
-      return totalOpeningCosts + totalDeliveryCosts;
-    }
-
-    public static void Evaluate(IEnumerable<int> customer2Depot, DoubleArray openingCosts, DoubleArray capacities, DoubleArray demands, DoubleMatrix deliveryCosts, out double totalOpeningCosts, out double totalDeliveryCosts, out double[] capacityDemandsPerDepot) {
+
+      return new FacilityLocationSolution() {
+        OpeningCosts = (DoubleArray)openingCosts.Clone(),
+        DepotCapacities = (DoubleArray)capacities.Clone(),
+        CustomerDemands = (DoubleArray)demands.Clone(),
+        DeliveryCosts = (DoubleMatrix)deliveryCosts.Clone(),
+        CustomerToDepotAssignmentParameter = { Value = (IntegerVector)depotAssignment.Clone() },
+        FitnessValueParameter = { Value = new DoubleValue(fitness) },
+        TotalOpeningCostsParameter = { Value = new DoubleValue(totalOpeningCosts) },
+        TotalDeliveryCostsParameter = { Value = new DoubleValue(totalDeliveryCosts) },
+        TotalOverbookedCapacityParameter = { Value = new DoubleValue(overbooking) }
+      };
+    } 
+
+    public static double Evaluate(IEnumerable<int> customer2Depot, DoubleArray openingCosts, DoubleArray capacities, DoubleArray demands, DoubleMatrix deliveryCosts, out double totalOpeningCosts, out double totalDeliveryCosts, out double[] capacityDemandsPerDepot) {
       var D = capacities.Length;
 
@@ -189,4 +213,11 @@
         customer++;
       }
+
+
+      var overbooking = capacityDemandsPerDepot.Zip(capacities, (a, b) => a > b ? a - b : 0).Sum();
+      if (overbooking > 0) // infeasible
+        return openingCosts.Sum() + deliveryCosts.Sum() + overbooking;
+
+      return totalOpeningCosts + totalDeliveryCosts;
     }
 
