case class AnalysisContext(catalogAndNamespace: Seq[String] = Nil, nestedViewDepth: Int = 0, maxNestedViewDepth: Int = -1, relationCache: Map[Seq[String], LogicalPlan] = mutable.Map.empty, referredTempViewNames: Seq[Seq[String]] = Seq.empty, referredTempFunctionNames: Seq[String] = Seq.empty) extends Product with Serializable
Provides a way to keep state during the analysis, mostly for resolving views. This enables us to decouple the concerns of analysis environment from the catalog. The state that is kept here is per-query.
Note this is thread local.
- catalogAndNamespace
The catalog and namespace used in the view resolution. This overrides the current catalog and namespace when resolving relations inside views.
- nestedViewDepth
The nested depth in the view resolution, this enables us to limit the depth of nested views.
- maxNestedViewDepth
The maximum allowed depth of nested view resolution.
- relationCache
A mapping from qualified table names to resolved relations. This can ensure that the table is resolved only once if a table is used multiple times in a query.
- referredTempViewNames
All the temp view names referred by the current view we are resolving. It's used to make sure the relation resolution is consistent between view creation and view resolution. For example, if
twas a permanent table when the current view was created, it should still be a permanent table when resolving the current view, even if a temp viewthas been created.
- Alphabetic
- By Inheritance
- AnalysisContext
- Serializable
- Serializable
- Product
- Equals
- AnyRef
- Any
- Hide All
- Show All
- Public
- All
Instance Constructors
-
new
AnalysisContext(catalogAndNamespace: Seq[String] = Nil, nestedViewDepth: Int = 0, maxNestedViewDepth: Int = -1, relationCache: Map[Seq[String], LogicalPlan] = mutable.Map.empty, referredTempViewNames: Seq[Seq[String]] = Seq.empty, referredTempFunctionNames: Seq[String] = Seq.empty)
- catalogAndNamespace
The catalog and namespace used in the view resolution. This overrides the current catalog and namespace when resolving relations inside views.
- nestedViewDepth
The nested depth in the view resolution, this enables us to limit the depth of nested views.
- maxNestedViewDepth
The maximum allowed depth of nested view resolution.
- relationCache
A mapping from qualified table names to resolved relations. This can ensure that the table is resolved only once if a table is used multiple times in a query.
- referredTempViewNames
All the temp view names referred by the current view we are resolving. It's used to make sure the relation resolution is consistent between view creation and view resolution. For example, if
twas a permanent table when the current view was created, it should still be a permanent table when resolving the current view, even if a temp viewthas been created.
Value Members
-
final
def
!=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
##(): Int
- Definition Classes
- AnyRef → Any
-
final
def
==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
asInstanceOf[T0]: T0
- Definition Classes
- Any
- val catalogAndNamespace: Seq[String]
-
def
clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()
-
final
def
eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
def
finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( classOf[java.lang.Throwable] )
-
final
def
getClass(): Class[_]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
-
final
def
isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- val maxNestedViewDepth: Int
-
final
def
ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- val nestedViewDepth: Int
-
final
def
notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
final
def
notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- val referredTempFunctionNames: Seq[String]
- val referredTempViewNames: Seq[Seq[String]]
- val relationCache: Map[Seq[String], LogicalPlan]
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
- Definition Classes
- AnyRef
-
final
def
wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()