Package path refactor.
This commit is contained in:
parent
829736279b
commit
83d4c5ad03
72 changed files with 162 additions and 188 deletions
68
date_expression.go
Normal file
68
date_expression.go
Normal file
|
|
@ -0,0 +1,68 @@
|
|||
package jet
|
||||
|
||||
type DateExpression interface {
|
||||
Expression
|
||||
|
||||
EQ(rhs DateExpression) BoolExpression
|
||||
NOT_EQ(rhs DateExpression) BoolExpression
|
||||
IS_DISTINCT_FROM(rhs DateExpression) BoolExpression
|
||||
IS_NOT_DISTINCT_FROM(rhs DateExpression) BoolExpression
|
||||
|
||||
LT(rhs DateExpression) BoolExpression
|
||||
LT_EQ(rhs DateExpression) BoolExpression
|
||||
GT(rhs DateExpression) BoolExpression
|
||||
GT_EQ(rhs DateExpression) BoolExpression
|
||||
}
|
||||
|
||||
type dateInterfaceImpl struct {
|
||||
parent DateExpression
|
||||
}
|
||||
|
||||
func (t *dateInterfaceImpl) EQ(rhs DateExpression) BoolExpression {
|
||||
return EQ(t.parent, rhs)
|
||||
}
|
||||
|
||||
func (t *dateInterfaceImpl) NOT_EQ(rhs DateExpression) BoolExpression {
|
||||
return NOT_EQ(t.parent, rhs)
|
||||
}
|
||||
|
||||
func (t *dateInterfaceImpl) IS_DISTINCT_FROM(rhs DateExpression) BoolExpression {
|
||||
return IS_DISTINCT_FROM(t.parent, rhs)
|
||||
}
|
||||
|
||||
func (t *dateInterfaceImpl) IS_NOT_DISTINCT_FROM(rhs DateExpression) BoolExpression {
|
||||
return IS_NOT_DISTINCT_FROM(t.parent, rhs)
|
||||
}
|
||||
|
||||
func (t *dateInterfaceImpl) LT(rhs DateExpression) BoolExpression {
|
||||
return LT(t.parent, rhs)
|
||||
}
|
||||
|
||||
func (t *dateInterfaceImpl) LT_EQ(rhs DateExpression) BoolExpression {
|
||||
return LT_EQ(t.parent, rhs)
|
||||
}
|
||||
|
||||
func (t *dateInterfaceImpl) GT(rhs DateExpression) BoolExpression {
|
||||
return GT(t.parent, rhs)
|
||||
}
|
||||
|
||||
func (t *dateInterfaceImpl) GT_EQ(rhs DateExpression) BoolExpression {
|
||||
return GT_EQ(t.parent, rhs)
|
||||
}
|
||||
|
||||
//---------------------------------------------------//
|
||||
|
||||
type DateExpressionWrapper struct {
|
||||
dateInterfaceImpl
|
||||
Expression
|
||||
}
|
||||
|
||||
func newDateExpressionWrap(expression Expression) DateExpression {
|
||||
dateExpressionWrap := DateExpressionWrapper{Expression: expression}
|
||||
dateExpressionWrap.dateInterfaceImpl.parent = &dateExpressionWrap
|
||||
return &dateExpressionWrap
|
||||
}
|
||||
|
||||
func DateExp(expression Expression) DateExpression {
|
||||
return newDateExpressionWrap(expression)
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue