Tabnine Logo
RenderContext.visit
Code IndexAdd Tabnine to your IDE (free)

How to use
visit
method
in
org.jooq.RenderContext

Best Java code snippets using org.jooq.RenderContext.visit (Showing top 20 results out of 315)

origin: com.ning.billing/killbill-osgi-bundles-analytics

private final void toSQLInParam(RenderContext context, Parameter<?> parameter, Field<?> value) {
  /* [pro] xx
  xxxxxx xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx x
    xxxx xxxxxxx
      xxxxxxxxxxxxxxxxxxxxxxxxx
      xxxxxxxxxxxxx xx xxx
      xxxxxx
  x
  xx [/pro] */
  context.visit(value);
}
origin: com.ning.billing/killbill-osgi-bundles-analytics

private final void toSQL92Values(RenderContext context) {
  context.visit(insertMaps.get(0));
  int i = 0;
  for (FieldMapForInsert map : insertMaps) {
    if (map != null && i > 0) {
      context.sql(", ");
      context.visit(map);
    }
    i++;
  }
}
origin: com.ning.billing/killbill-osgi-bundles-analytics

/**
 * The default LIMIT / OFFSET clause in most dialects
 */
private void toSQLReferenceLimitDefault(RenderContext context) {
  toSQLReference0(context);
  context.visit(getLimit());
}
origin: com.ning.billing/killbill-osgi-bundles-analytics

private void toSQLWrapped(RenderContext context) {
  context.sql(wrapInParentheses ? "(" : "")
      .visit(wrapped)
      .sql(wrapInParentheses ? ")" : "");
}
origin: com.ning.billing/killbill-osgi-bundles-analytics

@Override
public final void toSQL(RenderContext context) {
  context.visit(row)
      .sql(" ")
      .keyword(isNull ? "is null" : "is not null");
}
origin: com.ning.billing/killbill-osgi-bundles-analytics

@Override
public final void toSQL(RenderContext context) {
  context.visit(field)
      .sql(" ")
      .keyword(comparator.toSQL())
      .sql(" ")
      .visit(query);
}
origin: com.ning.billing/killbill-osgi-bundles-analytics

@Override
public final void toSQL(RenderContext context) {
  context.visit(left)
      .sql(" ")
      .keyword(comparator.toSQL())
      .sql(" (")
      .visit(right)
      .sql(")");
}
origin: org.jooq/jooq

static final void pgRenderRecordCast(RenderContext render, Record value) {
  if (value instanceof UDTRecord)
    render.sql("::").visit(((UDTRecord<?>) value).getUDT().getQualifiedName());
  else if (value instanceof TableRecord)
    render.sql("::").visit(((TableRecord<?>) value).getTable().getQualifiedName());
}
origin: org.jooq/jooq

@Override
final void sqlInline0(BindingSQLContext<U> ctx, Boolean value) {
  // [#1153] Some dialects don't support boolean literals TRUE and FALSE
  if (BIND_AS_1_0.contains(ctx.family()))
    ctx.render().sql(value ? "1" : "0");
  else
    ctx.render().visit(value ? K_TRUE : K_FALSE);
}
origin: com.ning.billing/killbill-osgi-bundles-analytics

@Override
public final void toSQL(RenderContext context) {
  context.sql("(");
  String separator = "";
  for (Field<?> field : fields.fields) {
    context.sql(separator);
    context.visit(field);
    separator = ", ";
  }
  context.sql(")");
}
origin: org.jooq/jooq

private final void sql(BindingSQLContext<U> ctx, T value) throws SQLException {
  if (ctx.render().paramType() == INLINED)
    if (value == null)
      ctx.render().visit(K_NULL);
    else
      sqlInline0(ctx, value);
  else
    sqlBind0(ctx, value);
}
origin: org.jooq/jooq

private final void toSQLQualifiedName(RenderContext ctx) {
  if (ctx.qualify()) {
    Schema mapped = Tools.getMappedSchema(ctx.configuration(), getSchema());
    if (mapped != null && !"".equals(mapped.getName()))
      ctx.visit(mapped)
        .sql('.');
  }
  ctx.literal(getName());
}
origin: com.ning.billing/killbill-osgi-bundles-analytics

@Override
public final void toSQL(RenderContext context) {
  context.data(DATA_OMIT_CLAUSE_EVENT_EMISSION, true);
  if (context.qualify()) {
    context.visit(table);
    context.sql(".");
  }
  context.literal(getName());
  context.data(DATA_OMIT_CLAUSE_EVENT_EMISSION, null);
}
origin: com.ning.billing/killbill-osgi-bundles-analytics

private final void toSQLFunctionName(RenderContext ctx) {
  if (name != null) {
    ctx.visit(name);
  }
  else if (term != null) {
    ctx.sql(term.translate(ctx.configuration().dialect()));
  }
  else {
    ctx.sql(getName());
  }
}
origin: jklingsporn/vertx-jooq

@Override
public void sql(BindingSQLContext<JsonObject> ctx) throws SQLException {
  // Depending on how you generate your SQL, you may need to explicitly distinguish
  // between jOOQ generating bind variables or inlined literals. If so, use this check:
  // ctx.render().paramType() == INLINED
  ctx.render().visit(DSL.val(ctx.convert(converter()).value())).sql("::json");
}
origin: io.github.jklingsporn/vertx-jooq-shared

@Override
public void sql(BindingSQLContext<JsonArray> ctx) throws SQLException {
  // Depending on how you generate your SQL, you may need to explicitly distinguish
  // between jOOQ generating bind variables or inlined literals. If so, use this check:
  // ctx.render().paramType() == INLINED
  ctx.render().visit(DSL.val(ctx.convert(converter()).value())).sql("::json");
}
origin: com.ning.billing/killbill-osgi-bundles-analytics

@Override
public final void toSQL(RenderContext context) {
  switch (context.configuration().dialect()) {
    case HSQLDB: {
      context.keyword("table(").visit(function).sql(")");
      break;
    }
    default:
      throw new SQLDialectNotSupportedException("FUNCTION TABLE is not supported for " + context.configuration().dialect());
  }
}
origin: com.ning.billing/killbill-osgi-bundles-analytics

/**
 * Render <code>WITHIN GROUP (ORDER BY ..)</code> clause
 */
private final void toSQLWithinGroupClause(RenderContext ctx) {
  if (!withinGroupOrderBy.isEmpty()) {
    ctx.sql(" ").keyword("within group")
      .sql(" (").keyword("order by")
      .sql(" ").visit(withinGroupOrderBy)
      .sql(")");
  }
}
origin: org.jooq/jooq

@Override
final void sqlInline0(BindingSQLContext<U> ctx, Record value) throws SQLException {
  if (                                                            ctx.family() == POSTGRES) {
    ctx.render().visit(inline(PostgresUtils.toPGString(value)));
    pgRenderRecordCast(ctx.render(), value);
  }
  else
    ctx.render().sql("[UDT]");
}
origin: com.ning.billing/killbill-osgi-bundles-analytics

private void toSQLInline(RenderContext context) {
  context.sql(getInlineConstructor(context));
  context.sql("(");
  String separator = "";
  for (Field<?> field : value.fields()) {
    context.sql(separator);
    context.visit(val(value.getValue(field), field));
    separator = ", ";
  }
  context.sql(")");
}
org.jooqRenderContextvisit

Popular methods of RenderContext

  • sql
    Recurse rendering.
  • render
    Render a query part in a new context derived from this one. The rendered SQL will not be appended to
  • declareTables
  • paramType
    Set the new context value for #paramType().
  • castMode
    Set the new cast mode for #castMode().
  • configuration
  • data
  • declareFields
  • declareWindows
  • end
  • formatIndentEnd
    Stop indenting subsequent SQL by a number of characters, if Settings#isRenderFormatted() is set to t
  • formatIndentLockEnd
    Stop indenting subsequent SQL at the same level as the current line, if Settings#isRenderFormatted()
  • formatIndentEnd,
  • formatIndentLockEnd,
  • formatIndentLockStart,
  • formatIndentStart,
  • formatNewLine,
  • formatSeparator,
  • keyword,
  • literal,
  • nextAlias

Popular in Java

  • Finding current android device location
  • addToBackStack (FragmentTransaction)
  • getSharedPreferences (Context)
  • getExternalFilesDir (Context)
  • Selector (java.nio.channels)
    A controller for the selection of SelectableChannel objects. Selectable channels can be registered w
  • Manifest (java.util.jar)
    The Manifest class is used to obtain attribute information for a JarFile and its entries.
  • Annotation (javassist.bytecode.annotation)
    The annotation structure.An instance of this class is returned bygetAnnotations() in AnnotationsAttr
  • HttpServlet (javax.servlet.http)
    Provides an abstract class to be subclassed to create an HTTP servlet suitable for a Web site. A sub
  • JComboBox (javax.swing)
  • IOUtils (org.apache.commons.io)
    General IO stream manipulation utilities. This class provides static utility methods for input/outpu
  • Top Vim plugins
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now