/// <summary> /// Appends information about lemma to tree. /// </summary> /// <param name="lemma"></param> /// <param name="li"></param> public void AppendLemmaInfo(string lemma, LemmaInfo li) { if (lemma != string.Empty && lemma[0] == '-') { return; } foreach (string prefix in PrefixCache.GetItem(li.FlexiaModelNo)) { Root.ProcessString(string.Format("{0}{1}", prefix, lemma), 0, li); } }
/// <summary> /// Returns a cached prefix corresponding to the specified channel. /// </summary> /// <param name="channel">The channel.</param> /// <returns>The cached prefix of the channel.</returns> public static string GetCachedPrefix(IMessageChannel channel) => channel.IsPrivate() ? CachedGlobalPrefix : PrefixCache.GetValueOrDefault(((IGuildChannel)channel).GuildId, CachedGlobalPrefix) ?? CachedGlobalPrefix;