Class WhenVisitor

java.lang.Object
org.springframework.data.relational.core.sql.render.WhenVisitor
All Implemented Interfaces:
Visitor

public class WhenVisitor extends Object
Renderer for When segments.
Since:
3.4
Author:
Sven Rienstra
  • Method Details

    • getRenderedPart

      public CharSequence getRenderedPart()
    • hasDelegatedRendering

      protected boolean hasDelegatedRendering()
      Returns whether rendering was delegated to a ExpressionVisitor or ConditionVisitor.
      Returns:
      true when rendering was delegated to a ExpressionVisitor or ConditionVisitor.
    • consumeRenderedPart

      protected CharSequence consumeRenderedPart()
      Consumes the delegated rendering part. Call hasDelegatedRendering() to check whether rendering was actually delegated. Consumption releases the delegated rendered.
      Returns:
      the delegated rendered part.
      Throws:
      IllegalStateException - if rendering was not delegate.
    • doEnter

      public final org.springframework.data.relational.core.sql.render.DelegatingVisitor.Delegation doEnter(Visitable segment)
    • doLeave

      public final org.springframework.data.relational.core.sql.render.DelegatingVisitor.Delegation doLeave(Visitable segment)
    • enter

      public final void enter(Visitable segment)
      Description copied from interface: Visitor
      Enter a Visitable.
      Specified by:
      enter in interface Visitor
      Parameters:
      segment - the segment to visit.
    • leave

      public final void leave(Visitable segment)
      Description copied from interface: Visitor
      Leave a Visitable.
      Specified by:
      leave in interface Visitor
      Parameters:
      segment - the visited segment.