Updated CTE.java for Composition matching -- finally works!

fixed bugs in CTEParser, refactored CTE (extract method x2)