/// <summary> /// Записать действие определённого типа в журнал /// </summary> public void WriteAction(string text, ActTypes actType) { string nowStr = DateTime.Now.ToString(DateTimeFormat); if (format == Formats.Simple) { WriteLine(nowStr + " " + text); } else { WriteLine(new StringBuilder(nowStr).Append(" <").Append(CompName).Append("><").Append(UserName). Append("><").Append(ActTypeToStr(actType)).Append("> ").Append(text).ToString()); } }
/// <summary type="" dos="public"> /// Конструткор для инициализации полей. /// </summary> /// <param name="actType"> Тип анимационного события. </param> /// <param name="objs"> Список анимируемых объектов. </param> public Act(ActTypes actType, params object[] objs) { ActType = actType; labels = new List <ALabel>(); foreach (var item in objs) { vertex = vertex ?? item as Vertex; edge = edge ?? item as Edge; data = data ?? item as ActData; if (item is Label) { labels.Add(item as ALabel); } } }
/// <summary> /// Получить строковое представления типа действия /// </summary> protected string ActTypeToStr(ActTypes actType) { switch (actType) { case ActTypes.Exception: return("EXC"); case ActTypes.Error: return("ERR"); case ActTypes.Action: return("ACT"); default: // ActTypes.Information: return("INF"); } }
} // 0x007D6B90-0x007D6CB0 private void _cbFromRenameWindow(ActTypes act_) { } // 0x007D6E00-0x007D6F70
} // 0x007D8260-0x007D8350 public void callAction(ActTypes action) { } // 0x007D8250-0x007D8260
/// <summary> /// Получить строковое представления типа действия /// </summary> protected string ActTypeToStr(ActTypes actType) { switch (actType) { case ActTypes.Exception: return "EXC"; case ActTypes.Error: return "ERR"; case ActTypes.Action: return "ACT"; default: // ActTypes.Information: return "INF"; } }
/// <summary> /// Записать действие в лог-файл, указав его тип /// </summary> public void WriteAction(string actText, ActTypes actType) { string nowStr = DateTime.Now.ToString(DateTimeFormat); if (format == Formats.Simple) WriteLine(nowStr + " " + actText); else WriteLine(new StringBuilder(nowStr).Append(" <").Append(CompName).Append("><").Append(UserName). Append("><").Append(ActTypeToStr(actType)).Append("> ").Append(actText).ToString()); }