Class IfElseStatementExec

Object
org.apache.spark.sql.scripting.IfElseStatementExec
All Implemented Interfaces:
org.apache.spark.internal.Logging, CompoundStatementExec, NonLeafStatementExec

public class IfElseStatementExec extends Object implements NonLeafStatementExec
Executable node for IfElseStatement. param: conditions Collection of executable conditions. First condition corresponds to IF clause, while others (if any) correspond to following ELSE IF clauses. param: conditionalBodies Collection of executable bodies that have a corresponding condition, in IF or ELSE IF branches. param: elseBody Body that is executed if none of the conditions are met, i.e. ELSE branch. param: session Spark session that SQL script is executed within.
  • Nested Class Summary

    Nested classes/interfaces inherited from interface org.apache.spark.internal.Logging

    org.apache.spark.internal.Logging.LogStringContext, org.apache.spark.internal.Logging.SparkShellLoggingFilter
  • Constructor Summary

    Constructors
    Constructor
    Description
    IfElseStatementExec(scala.collection.immutable.Seq<SingleStatementExec> conditions, scala.collection.immutable.Seq<CompoundBodyExec> conditionalBodies, scala.Option<CompoundBodyExec> elseBody, SparkSession session)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    scala.collection.Iterator<CompoundStatementExec>
    Construct the iterator to traverse the tree rooted at this node in an in-order traversal.
    boolean
    Whether the statement originates from the SQL script or is created during the interpretation.
    void
    Reset execution of the current node.

    Methods inherited from class java.lang.Object

    equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

    Methods inherited from interface org.apache.spark.internal.Logging

    initializeForcefully, initializeLogIfNecessary, initializeLogIfNecessary, initializeLogIfNecessary$default$2, isTraceEnabled, log, logDebug, logDebug, logDebug, logDebug, logError, logError, logError, logError, logInfo, logInfo, logInfo, logInfo, logName, LogStringContext, logTrace, logTrace, logTrace, logTrace, logWarning, logWarning, logWarning, logWarning, org$apache$spark$internal$Logging$$log_, org$apache$spark$internal$Logging$$log__$eq, withLogContext

    Methods inherited from interface org.apache.spark.sql.scripting.NonLeafStatementExec

    evaluateBooleanCondition