Added encoders for operators to work with JSON encoding