/** * Create an instance of {@link RenderFormatting } * */ public RenderFormatting createRenderFormatting() { return new RenderFormatting(); }
public RenderFormatting withIndentation(String value) { setIndentation(value); return this; }
public RenderFormatting withNewline(String value) { setNewline(value); return this; }
DefaultRenderContext(Configuration configuration) { super(configuration, null); Settings settings = configuration.settings(); this.sql = new StringBuilder(); this.bindValues = new QueryPartList<Param<?>>(); this.cachedRenderKeywordStyle = settings.getRenderKeywordStyle(); this.cachedRenderFormatted = Boolean.TRUE.equals(settings.isRenderFormatted()); this.cachedRenderNameStyle = settings.getRenderNameStyle(); RenderFormatting formatting = settings.getRenderFormatting(); if (formatting == null) formatting = new RenderFormatting(); this.cachedNewline = formatting.getNewline() == null ? "\n" : formatting.getNewline(); this.cachedIndentation = formatting.getIndentation() == null ? " " : formatting.getIndentation(); this.cachedIndentWidth = cachedIndentation.length(); this.cachedPrintMargin = formatting.getPrintMargin() == null ? 80 : formatting.getPrintMargin(); }
public RenderFormatting withPrintMargin(Integer value) { setPrintMargin(value); return this; }
/** * Clone some settings. */ public static final Settings clone(Settings settings) { Settings result = (Settings) settings.clone(); if (result.renderFormatting != null) result.renderFormatting = (RenderFormatting) result.renderFormatting.clone(); return result; }
result = ((prime*result)+((renderKeywordStyle == null)? 0 :renderKeywordStyle.hashCode())); result = ((prime*result)+((renderFormatted == null)? 0 :renderFormatted.hashCode())); result = ((prime*result)+((renderFormatting == null)? 0 :renderFormatting.hashCode())); result = ((prime*result)+((renderScalarSubqueriesForStoredFunctions == null)? 0 :renderScalarSubqueriesForStoredFunctions.hashCode())); result = ((prime*result)+((renderOrderByRownumberForEmulatedPagination == null)? 0 :renderOrderByRownumberForEmulatedPagination.hashCode()));
if (!renderFormatting.equals(other.renderFormatting)) { return false;