public string GetSourceValue(string lutName, string targetValue) { LUTItemMgt lut = GetLut(lutName); if (lut == null) { return(null); } return(lut.GetSourceValue(targetValue)); }
public bool DeleteLut(string lutName) { if (lutName == null || lutName.Length < 1) { return(false); } LUTItemMgt lut = _lutList[lutName] as LUTItemMgt; if (lut != null) { _lutList.Remove(lutName); } else { lut = new LUTItemMgt(_db, lutName); } return(lut.Drop());; }
public LUTItemMgt GetLut(string lutName) { if (lutName == null) { return(null); } LUTItemMgt lut = _lutList[lutName] as LUTItemMgt; if (lut == null) { lut = new LUTItemMgt(_db, lutName); if (lut.ReloadLUT() == null) { return(null); } _lutList[lutName] = lut; } return(lut); }
public LUTItemMgt AddLut(string lutName) { if (lutName == null || lutName.Length < 1) { return(null); } string name = lutName; if (name.Length <= Prefix.Length || name.Substring(0, Prefix.Length).ToUpper() != Prefix) { name = Prefix + name; } LUTItemMgt lut = new LUTItemMgt(_db, name); if (!lut.Create()) { return(null); } return(lut); }