@Override
    public boolean equals(Object o) {
        if (o == this) {
            return true;
        } else if (o instanceof Constant<?>) {
            return ((Constant<?>) o).getConstant().equals(constant);
        } else {
            return false;
        }
    }
Create a new Constant of the given type for the given object

@param type type of the expression
@param constant constant
querydsl-core/src/main/java/com/querydsl/core/types/ConstantImpl.java