Documentation
¶
Index ¶
- func SetTrace(t bool)
- type Client
- func (client *Client) CreateCube(cubeName string) (code int, body []byte, err error)
- func (client *Client) GetCube(cubeName string) (code int, body []byte, err error)
- func (client *Client) GetCubeDesc(cubeName string) (code int, body []byte, err error)
- func (client *Client) GetModel(modelName string) (code int, body []byte, err error)
- func (client *Client) ListCubes(offset, limit int, cubeName, projectName string) (code int, body []byte, err error)
- func (client *Client) ListTables(project string) (code int, body []byte, err error)
- func (client *Client) Login() (code int, body []byte, err error)
- func (client *Client) Query(sql, project string, offset, limit int) (*QueryResult, error)
- func (client *Client) QueryKylin(query *Query) (code int, body []byte, err error)
- type Column
- type Config
- type H
- type Proxy
- type Query
- type QueryOut
- type QueryResult
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client 客户端
func (*Client) CreateCube ¶
CreateCube 创建cube
func (*Client) GetCubeDesc ¶
GetCubeDesc 获取cube描述 //cubeName 必须参数
func (*Client) ListCubes ¶
func (client *Client) ListCubes(offset, limit int, cubeName, projectName string) (code int, body []byte, err error)
ListCubes 列出cubes offset limit 必须参数 cubeName, projectName 可选参数
func (*Client) ListTables ¶
ListTables 列出tables project 必须参数
type Column ¶
type Column struct {
IsNullable int `json:"isNullable"`
DisplaySize int `json:"displaySize"`
Label string `json:"label"`
Name string `json:"name"`
SchemaName string `json:"schemaName"`
CatelogName string `json:"catelogName"`
TableName string `json:"tableName"`
Precision int `json:"precision"`
Scale int `json:"scale"`
ColumnType int `json:"columnType"`
ColumnTypeName string `json:"columnTypeName"`
ReadOnly bool `json:"readOnly"`
AutoIncrement bool `json:"autoIncrement"`
CaseSensitive bool `json:"caseSensitive"`
Searchable bool `json:"searchable"`
Currency bool `json:"currency"`
Signed bool `json:"signed"`
DefinitelyWritable bool `json:"definitelyWritable"`
Writable bool `json:"writable"`
}
Column 字段
type Proxy ¶
type Proxy struct {
// contains filtered or unexported fields
}
Proxy 代理
func (*Proxy) SetNameSpace ¶
SetNameSpace 设置组
type Query ¶
type Query struct {
SQL string `json:"sql"`
Offset int `json:"offset"`
Limit int `json:"limit"`
AcceptPartial bool `json:"acceptPartial"`
Project string `json:"project"`
}
Query 查询条件封装
type QueryOut ¶
type QueryOut struct {
ColumnMetas []string `json:"columnMetas"`
Result []interface{} `json:"results"`
}
QueryOut 返回上层数据
type QueryResult ¶
type QueryResult struct {
ColumnMetas []*Column `json:"columnMetas"`
Result []interface{} `json:"results"`
Cube string `json:"cube"`
AffectedRowCount int `json:"affectedRowCount"`
IsException bool `json:"isException"`
ExceptionMessage string `json:"exceptionMessage"`
Duration int `json:"duration"`
TotalScanCount int `json:"totalScanCount"`
HitExceptionCache bool `json:"hitExceptionCache"`
StorageCacheUsed bool `json:"storageCacheUsed"`
Partial bool `json:"partial"`
}
QueryResult 查询后正常的返回结果
Click to show internal directories.
Click to hide internal directories.