protected void constructorsForVariables(CodeWriter writer, EntityType model) throws IOException {
        String localName = writer.getRawName(model);
        String genericName = writer.getGenericName(true, model);

        boolean stringOrBoolean = model.getOriginalCategory() == TypeCategory.STRING
                || model.getOriginalCategory() == TypeCategory.BOOLEAN;
        boolean hasEntityFields = model.hasEntityFields() || superTypeHasEntityFields(model);
        String thisOrSuper = hasEntityFields ? THIS : SUPER;
        String additionalParams = hasEntityFields ? "" : getAdditionalConstructorParameter(model);

        if (!localName.equals(genericName)) {
            suppressAllWarnings(writer);
        }
        writer.beginConstructor(new Parameter("variable", Types.STRING));
        if (stringOrBoolean) {
            writer.line(thisOrSuper,"(forVariable(variable)",additionalParams,");");
        } else {
            writer.line(thisOrSuper,"(", localName.equals(genericName) ? EMPTY : "(Class) ",
            writer.getClassConstant(localName) + COMMA + "forVariable(variable)", hasEntityFields ? ", INITS" : EMPTY,
                            additionalParams,");");
        }
        if (!hasEntityFields) {
            constructorContent(writer, model);
        }
        writer.end();
    }
Create a new {@code EntitySerializer} instance

@param mappings type mappings to be used
@param keywords keywords to be used
querydsl-codegen/src/main/java/com/querydsl/codegen/DefaultEntitySerializer.java