Exemple #1
0
        public void StringsFor()
        {
            var entry = Cache.ServiceLocator.GetInstance <ILexEntryFactory>().Create();

            entry.CitationForm.VernacularDefaultWritingSystem = Cache.TsStrFactory.MakeString("kick", Cache.DefaultVernWs);
            var doc = new XmlDocument();

            doc.LoadXml(@"<string class='LexEntry' field='CitationForm'/>");
            var node    = doc.DocumentElement;
            var strings = XmlViewsUtils.StringsFor(Cache, Cache.DomainDataByFlid, node, entry.Hvo, null, null, null,
                                                   (int)WritingSystemServices.kwsVern);

            Assert.That(strings, Has.Length.EqualTo(1));
            Assert.That(strings, Has.Member("kick"));
        }
Exemple #2
0
 private string[] StringsFor(int hvo, XmlNode layout, int wsForce)
 {
     return(XmlViewsUtils.StringsFor(m_cache, m_cache.DomainDataByFlid, layout, hvo, m_layouts, null, m_stringTbl, wsForce));
 }