Refactoring codes for more tg message types
This commit is contained in:
27
query/objects.go
Normal file
27
query/objects.go
Normal file
@@ -0,0 +1,27 @@
|
||||
package query
|
||||
|
||||
type QTerm struct {
|
||||
Org string
|
||||
Value string
|
||||
IsKey bool
|
||||
}
|
||||
|
||||
type QueryMessage struct {
|
||||
Lang string
|
||||
Text string
|
||||
Location *GeoLocation
|
||||
}
|
||||
|
||||
type QueryObject struct {
|
||||
Key string
|
||||
Message *QueryMessage
|
||||
SearchTerms *[]*QTerm
|
||||
Results *[]ISearchable
|
||||
}
|
||||
|
||||
type IQueryResult interface {
|
||||
Message() (string, error)
|
||||
DataType() string
|
||||
GetTableData() [][]map[string]string
|
||||
Consumed() bool
|
||||
}
|
||||
Reference in New Issue
Block a user