Top Description Methods
org.jooq

public Interface VisitContext

extends Scope
Known Direct Implementers
org.jooq.impl.AbstractContext.DefaultVisitContext
Imports
org.jetbrains.annotations.NotNull, .Nullable

A context object for QueryPart traversal passed to registered VisitListener's.

This type is a Scope with whose lifecycle is shared with the parent rendering Context scope. It also shares the latter's data() map.

Author
Lukas Eder
See Also
VisitListener

Method Summary

Modifier and TypeMethod and Description
public @Nullable BindContext
bindContext()

The underlying BindContext or null, if the underlying context is a RenderContext.

public @NotNull Clause
clause()

Deprecated as a consequence of Clause being deprecated.
The most recent clause that was encountered through Context#start(Clause).
public @NotNull @NotNull Clause[]
clauses()

Deprecated as a consequence of Clause being deprecated.
A path of clauses going through the visiting tree.
public int
clausesLength()

This is the same as calling clauses().length.

public @NotNull Context<?>
context()

The underlying RenderContext or BindContext object.

public @NotNull QueryPart
queryPart()

The most recent QueryPart that was encountered through Context#visit(QueryPart).

public void
queryPart(QueryPart
The new QueryPart.
part
)

Replace the most recent QueryPart that was encountered through Context#visit(QueryPart).

public @NotNull @NotNull QueryPart[]
queryParts()

A path of QueryParts going through the visiting tree.

public int
queryPartsLength()

This is the same as calling queryParts().length.

public @Nullable RenderContext
renderContext()

The underlying RenderContext or null, if the underlying context is a BindContext.

Inherited from org.jooq.Scope:
configurationcreationTimedatadatadatadialectdslfamilysettings

Method Detail

bindContextback to summary
public @Nullable BindContext bindContext() throws UnsupportedOperationException

The underlying BindContext or null, if the underlying context is a RenderContext.

Annotations
@Nullable
Exceptions
UnsupportedOperationException:
[#2694] [#2695] As of jOOQ 3.2, this method is not yet implemented as QueryPart traversal SPI through VisitListener is only implemented for RenderContext
clauseback to summary
public @NotNull Clause clause()

Deprecated

as a consequence of Clause being deprecated. See corresponding docs for further information.

The most recent clause that was encountered through Context#start(Clause).

Annotations
@NotNull
clausesback to summary
public @NotNull @NotNull Clause[] clauses()

Deprecated

as a consequence of Clause being deprecated. See corresponding docs for further information.

A path of clauses going through the visiting tree.

This returns all previous clauses that were encountered through Context#start(Clause) and that haven't been removed yet through Context#end(Clause). In other words, VisitContext contains a stack of clauses.

Annotations
@NotNull
clausesLengthback to summary
public int clausesLength()

This is the same as calling clauses().length.

contextback to summary
public @NotNull Context<?> context()

The underlying RenderContext or BindContext object.

Annotations
@NotNull
queryPartback to summary
public @NotNull QueryPart queryPart()

The most recent QueryPart that was encountered through Context#visit(QueryPart).

Annotations
@NotNull
queryPartback to summary
public void queryPart(QueryPart part)

Replace the most recent QueryPart that was encountered through Context#visit(QueryPart).

This method can be called by VisitListener implementation methods, in particular by VisitListener#visitStart(VisitContext).

Parameters
part:QueryPart

The new QueryPart.

queryPartsback to summary
public @NotNull @NotNull QueryPart[] queryParts()

A path of QueryParts going through the visiting tree.

This returns all previous QueryParts that were encountered through Context#visit(QueryPart). In other words, VisitContext contains a stack of QueryParts.

Annotations
@NotNull
queryPartsLengthback to summary
public int queryPartsLength()

This is the same as calling queryParts().length.

renderContextback to summary
public @Nullable RenderContext renderContext()

The underlying RenderContext or null, if the underlying context is a BindContext.

[#2694] [#2695] As of jOOQ 3.2, the QueryPart traversal SPI through VisitListener is only implemented for RenderContext. Hence, you may need to inline bind values if applicable.

Annotations
@Nullable