using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
namespace EHEC_Server
{
///
/// This clas converts the object from db model to the needs of Json
/// conversion for Clusteranalysis.
///
public class ClusterResult
{
public int Id { get; set; }
public string Name { get; set; }
public string Nodetype { get; set; }
public ClusterResult() { }
public List GetClusterResults()
{
Result result = new Result();
List results = new List();
results = result.GetAllResults();
List clusterResults = new List();
foreach (Result element in results)
{
ClusterResult clusterResult = new ClusterResult
{
Id = element.ResultId,
Nodetype = "result",
Name = element.Name
};
clusterResults.Add(clusterResult);
};
return clusterResults;
}
}
}