Fix #95,  class and hasPredicate are optional