Ejemplo n.º 1
0
        static public int Search <T>(List <T> subsequence, SuffixTree tree)
        {
            //TODO
            int positionOfEntry = 0;

            return(positionOfEntry);
        }
Ejemplo n.º 2
0
        public static SuffixTree BuildSuffixTree <T>(List <T> alphabet, List <T> sequence)
        {
            TypeOfModel = alphabet.GetType();
            SuffixTree tree = new SuffixTree();

            return(tree);
        }
Ejemplo n.º 3
0
        private static SuffixTree BasicAlgorithm <T>(List <T> alphabet, List <T> sequence)
        {
            Node       root = new Node();
            SuffixTree tree = new SuffixTree(root);

            foreach (var element in sequence)
            {
            }

            //TODO
            return(tree);
        }
Ejemplo n.º 4
0
        static void Main( )
        {
            CharType        a = new CharType('a');
            List <CharType> b = new List <CharType>();

            b.Add(a);
            //
            SuffixTree tree   = SuffixTreeHelper.BuildSuffixTree <CharType>(b, b);
            int        result = SearchHelper.Search(b, tree);

            Console.WriteLine(result);
            //
            Node parent = new Node(5);
            Node son    = new Node(ref parent, 9);

            parent.AddChildren(ref son);
            foreach (var child in parent.GetChildren())
            {
                Console.WriteLine(child.GetParent().GetPositionInText());
            }
            Console.ReadKey();
        }
Ejemplo n.º 5
0
 static public void Initialize <T>(List <T> alphabet, List <T> sequence)
 {
     suffixTree = SuffixTreeHelper.BuildSuffixTree(alphabet, sequence);
 }