public static AffixConfig Read(IHunspellLineReader reader, AffixConfig.Builder builder = null) { var readerInstance = new AffixReader(builder, reader); readerInstance.Read(); return(readerInstance.Builder.MoveToImmutable()); }
public static async Task <AffixConfig> ReadAsync(IHunspellLineReader reader, AffixConfig.Builder builder = null) { var readerInstance = new AffixReader(builder, reader); await readerInstance.ReadAsync().ConfigureAwait(false); return(readerInstance.Builder.MoveToImmutable()); }
public static WordList ReadFile(string dictionaryFilePath, string affixFilePath) { var affixBuilder = new AffixConfig.Builder(); var affix = AffixReader.ReadFile(affixFilePath, affixBuilder); var wordListBuilder = new WordList.Builder(affix, affixBuilder.FlagSetDeduper, affixBuilder.MorphSetDeduper, affixBuilder.StringDeduper); return(ReadFile(dictionaryFilePath, affix, wordListBuilder)); }
public static WordList Read(Stream dictionaryStream, Stream affixStream) { var affixBuilder = new AffixConfig.Builder(); var affix = AffixReader.Read(affixStream, affixBuilder); var wordListBuilder = new WordList.Builder(affix, affixBuilder.FlagSetDeduper, affixBuilder.MorphSetDeduper, affixBuilder.StringDeduper); return(Read(dictionaryStream, affix, wordListBuilder)); }
public static async Task <WordList> ReadFileAsync(string dictionaryFilePath, string affixFilePath) { var affixBuilder = new AffixConfig.Builder(); var affix = await AffixReader.ReadFileAsync(affixFilePath, affixBuilder).ConfigureAwait(false); var wordListBuilder = new WordList.Builder(affix, affixBuilder.FlagSetDeduper, affixBuilder.MorphSetDeduper, affixBuilder.StringDeduper); return(await ReadFileAsync(dictionaryFilePath, affix, wordListBuilder).ConfigureAwait(false)); }
public static async Task <WordList> ReadAsync(Stream dictionaryStream, Stream affixStream) { var affixBuilder = new AffixConfig.Builder(); var affix = await AffixReader.ReadAsync(affixStream, affixBuilder).ConfigureAwait(false); var wordListBuilder = new WordList.Builder(affix, affixBuilder.FlagSetDeduper, affixBuilder.MorphSetDeduper, affixBuilder.StringDeduper); return(await ReadAsync(dictionaryStream, affix, wordListBuilder).ConfigureAwait(false)); }
public static WordList ReadFile(string dictionaryFilePath) { var affixFilePath = FindAffixFilePath(dictionaryFilePath); return(ReadFile(dictionaryFilePath, AffixReader.ReadFile(affixFilePath))); }