using System; using System.Collections.Generic; using System.Linq; using System.Text; using DataAnalysisControl.Core; using Aitex.Core.RT.Log; namespace Triton160.UI.ViewModel { public class JetDataAnalysisContext : IDataAnalysisControlContext { public Dictionary GetChamberList() { Dictionary lst = new Dictionary(); lst["System"] = "System"; return lst; } public Dictionary GetRecipeChamberList() { Dictionary lst = new Dictionary(); lst["System"] = "System"; return lst; } public void Write(string info) { LOG.Write(info); } public void Write(Exception ex, string error) { LOG.Write(ex, error); } public string GetDBConnString() { string connString = string.Empty; try { connString = System.Configuration.ConfigurationManager.ConnectionStrings["DataAnalysisPostgreSQL"].ConnectionString; } catch (Exception ex) { LOG.Write(ex); } if (string.IsNullOrEmpty(connString)) connString = "Server=localhost;Port=5432;User Id=postgres;Password=123456;Database=triton160db;Enlist=true;"; return connString; } public void WriteLog(Exception ex, string error) { LOG.Write(ex); } } }