I would probably just do something like:
builder.append("select i from Item i where 1=1");
        builder.append(" and i.enabled = true");
        if (showDisabled) {
            builder.append(" and i.enabled = false");
        }