Пример #1
0
        // public constructors ---------------------------------------------

        /// <summary>
        /// Creates a new Trie with the settings for the trie data.
        /// <para/>
        /// Unserialize the 32-bit-aligned input buffer and use the data for the trie.
        /// </summary>
        /// <param name="bytes">Data of an ICU data file, containing the trie.</param>
        /// <param name="dataManipulate">Object which provides methods to parse the char data.</param>
        public CharTrie(ByteBuffer bytes, ITrieDataManipulate dataManipulate) // ICU4N TODO: API - make internal and make overload that accepts byte[]
            : base(bytes, dataManipulate)
        {
            if (!IsCharTrie)
            {
                throw new ArgumentException(
                          "Data given does not belong to a char trie.");
            }
        }