Refactor ComplexType to be defined in terms of predicates instead of instance variables.