static Sentence insert(TradosDB db, string name, string srcText, Langs srcLang, string transText, Langs transLang) { TradosDT.Sentence sent = new TradosDT.Sentence(); db.Sentences.Add(sent); sent.Name = name; sent.SrcLang = (short)srcLang; sent.SrcText = srcText; sent.TransLang = (short)transLang; sent.TransText = transText; //sent.TransText = sent.TransText.Replace("\r\n", crlfCode); sent.finish(); return sent; }
public static Lookup insert(TradosDB db, string srcText, Langs srcLang, string transText, Langs transLang) { Lookup res = new Lookup(); db.Lookups.Add(res); res.finish(srcText, srcLang, transText, transLang); return res; }
public static Sentence insert(TradosDB db, int pageId, string name, string srcText, Langs srcLang, string transText, Langs transLang) { var sent = insert(db, name, srcText, srcLang, transText, transLang); sent.PageId = pageId; return sent; }