Package tilda.parsing.parts.helpers
Class JoinHelper.RefDef
- java.lang.Object
-
- tilda.parsing.parts.helpers.JoinHelper.RefDef
-
- Enclosing class:
- JoinHelper
protected static class JoinHelper.RefDef extends java.lang.Object
-
-
Field Summary
Fields Modifier and Type Field Description protected java.lang.String
_signature
protected ViewColumn
_vc
-
Constructor Summary
Constructors Modifier Constructor Description protected
RefDef(ViewColumn vc)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description protected static void
duplicateFKError(ParserSession PS, ForeignKey FK, ForeignKey fk, JoinHelper.RefDef ref)
protected boolean
equals(JoinHelper.RefDef rhs)
protected static int
findRef(java.util.List<JoinHelper.RefDef> refs, JoinHelper.RefDef ref)
protected ForeignKey
getCompatibleRefDef(ParserSession PS, View V, java.util.List<JoinHelper.RefDef> refs)
The auto-join logic for Tilda is to look for the nearest previously referenced table and check if there is an FK either forward or backward.protected static java.lang.String
signature(Base ref, java.lang.String as)
java.lang.String
toString()
-
-
-
Field Detail
-
_vc
protected final ViewColumn _vc
-
_signature
protected final java.lang.String _signature
-
-
Constructor Detail
-
RefDef
protected RefDef(ViewColumn vc)
-
-
Method Detail
-
equals
protected boolean equals(JoinHelper.RefDef rhs)
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
signature
protected static java.lang.String signature(Base ref, java.lang.String as)
-
findRef
protected static int findRef(java.util.List<JoinHelper.RefDef> refs, JoinHelper.RefDef ref)
-
duplicateFKError
protected static void duplicateFKError(ParserSession PS, ForeignKey FK, ForeignKey fk, JoinHelper.RefDef ref)
-
getCompatibleRefDef
protected ForeignKey getCompatibleRefDef(ParserSession PS, View V, java.util.List<JoinHelper.RefDef> refs)
The auto-join logic for Tilda is to look for the nearest previously referenced table and check if there is an FK either forward or backward. For example:
- TableA.a1
- TableA.a2
- TableB.b1
- TableB.b2
- TableC.c1
- TableC.c2
- Parameters:
PS
-V
-refs
-- Returns:
-
-