Documentation ¶
Index ¶
- Variables
- type Client
- func (cli *Client) CreateMetaObject(data []byte) (int, error)
- func (cli *Client) CreateMetaObjectAsst(data []byte) (int, error)
- func (cli *Client) CreateMetaObjectAtt(data []byte) (int, error)
- func (cli *Client) CreateMetaObjectAttGroup(data []byte) (int, error)
- func (cli *Client) CreateMetaObjectCls(data []byte) (int, error)
- func (cli *Client) DeleteMetaObject(objID int, data []byte) error
- func (cli *Client) DeleteMetaObjectAsst(objAsstID int, data []byte) error
- func (cli *Client) DeleteMetaObjectAtt(objAttID int, data []byte) error
- func (cli *Client) DeleteMetaObjectAttGroup(id int, data []byte) error
- func (cli *Client) DeleteMetaObjectAttGroupProperty(ownerID, objectID, propertyID, groupID string) error
- func (cli *Client) DeleteMetaObjectCls(objClsID int, data []byte) error
- func (cli *Client) GetAddress() string
- func (cli *Client) SearchMetaObject(data []byte) ([]ObjDes, error)
- func (cli *Client) SearchMetaObjectAsst(data []byte) ([]ObjAsstDes, error)
- func (cli *Client) SearchMetaObjectAtt(data []byte) ([]ObjAttDes, error)
- func (cli *Client) SearchMetaObjectAttByID(attrID int) (*ObjAttDes, error)
- func (cli *Client) SearchMetaObjectAttExceptInnerFiled(data []byte) ([]ObjAttDes, error)
- func (cli *Client) SearchMetaObjectCls(data []byte) ([]ObjClsDes, error)
- func (cli *Client) SearchMetaObjectClsObjects(ownerID string, data []byte) ([]ObjClsObjectDes, error)
- func (cli *Client) SelectPropertyGroup(data []byte) ([]ObjAttGroupDes, error)
- func (cli *Client) SelectPropertyGroupByObjectID(ownerID, objectID string, data []byte) ([]ObjAttGroupDes, error)
- func (cli *Client) SetAddress(address string)
- func (cli *Client) UpdateMetaObject(objID int, data []byte) error
- func (cli *Client) UpdateMetaObjectAsst(objAsstID int, data []byte) error
- func (cli *Client) UpdateMetaObjectAtt(objAttID int, data []byte) error
- func (cli *Client) UpdateMetaObjectAttGroup(data []byte) error
- func (cli *Client) UpdateMetaObjectAttGroupProperty(data []byte) error
- func (cli *Client) UpdateMetaObjectCls(objClsID int, data []byte) error
- type ObjAsstDes
- type ObjAsstRsp
- type ObjAttDes
- type ObjAttGroupDes
- type ObjAttGroupRsp
- type ObjAttRsp
- type ObjClsDes
- type ObjClsObjectDes
- type ObjClsObjectRsp
- type ObjClsRsp
- type ObjDes
- type ObjDesRsp
Constants ¶
This section is empty.
Variables ¶
var ( Err_Not_Found_Anything = errors.New("found nothing") Err_Not_Set_Input = errors.New("input nothing") Err_Not_Set_ObjID = errors.New("not set objid") Err_Request_Object = errors.New("http request failed") Err_Decode_Json = errors.New("decode json failed") Err_Creaate_Object = errors.New("create object failed") )
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client
func (*Client) CreateMetaObject ¶
CreateMetaObject 创建元对象, 如果成功则返回 新数据的ID
func (*Client) CreateMetaObjectAsst ¶
CreateMetaObject 创建元对象, 如果成功则返回 新数据的ID
func (*Client) CreateMetaObjectAtt ¶
CreateMetaObject 创建元对象, 如果成功则返回 新数据的ID
func (*Client) CreateMetaObjectAttGroup ¶
CreateMetaObjectAttGroup create a new object attribute group, return the id
func (*Client) CreateMetaObjectCls ¶
CreateMetaObjectCls 创建元对象分类, 如果成功则返回 新数据的ID
func (*Client) DeleteMetaObject ¶
DeleteMetaObject, objID 如果为0, 则必须要设置obj,如果设置了 objID,那么会自动忽略obj 的值
func (*Client) DeleteMetaObjectAsst ¶
DeleteMetaObject, objID 如果为0, 则必须要设置obj,如果设置了 objID,那么会自动忽略obj 的值
func (*Client) DeleteMetaObjectAtt ¶
DeleteMetaObject, objID 如果为0, 则必须要设置obj,如果设置了 objID,那么会自动忽略obj 的值
func (*Client) DeleteMetaObjectAttGroup ¶
DeleteMetaObjectAttGroup delete the property group
func (*Client) DeleteMetaObjectAttGroupProperty ¶
func (cli *Client) DeleteMetaObjectAttGroupProperty(ownerID, objectID, propertyID, groupID string) error
DeleteMetaObjectAttGroupProperty delete the group property
func (*Client) DeleteMetaObjectCls ¶
DeleteMetaObject, objID 如果为0, 则必须要设置obj,如果设置了 objID,那么会自动忽略obj 的值
func (*Client) GetAddress ¶
func (*Client) SearchMetaObject ¶
SearchMetaobject 查询元数据对象集合
func (*Client) SearchMetaObjectAsst ¶
func (cli *Client) SearchMetaObjectAsst(data []byte) ([]ObjAsstDes, error)
SearchMetaobject 查询元数据对象集合
func (*Client) SearchMetaObjectAtt ¶
SearchMetaObjectAtt 查询元数据对象集合
func (*Client) SearchMetaObjectAttByID ¶
SearchMetaobjectAttByID 查询元数据对象集合
func (*Client) SearchMetaObjectAttExceptInnerFiled ¶
SearchMetaObjectAttExceptInnerFiled 排除内置字段
func (*Client) SearchMetaObjectCls ¶
SearchMetaobjectCls 仅返回分组信息
func (*Client) SearchMetaObjectClsObjects ¶
func (cli *Client) SearchMetaObjectClsObjects(ownerID string, data []byte) ([]ObjClsObjectDes, error)
SearchMetaObjectClsObjects 查询所有的分类及分类下属的所有分组信息
func (*Client) SelectPropertyGroup ¶
func (cli *Client) SelectPropertyGroup(data []byte) ([]ObjAttGroupDes, error)
func (*Client) SelectPropertyGroupByObjectID ¶
func (cli *Client) SelectPropertyGroupByObjectID(ownerID, objectID string, data []byte) ([]ObjAttGroupDes, error)
SelectPropertyGroupByObjectID 查询元数据对象集合
func (*Client) UpdateMetaObject ¶
UpdateMetaObject objID 被更新的对象的ID,val 新的ID值
func (*Client) UpdateMetaObjectAsst ¶
UpdateMetaObject objID 被更新的对象的ID,val 新的ID值
func (*Client) UpdateMetaObjectAtt ¶
UpdateMetaObjectAtt objID 被更新的对象的ID,val 新的ID值
func (*Client) UpdateMetaObjectAttGroup ¶
UpdateMetaObjectAttGroup update object attribute group
func (*Client) UpdateMetaObjectAttGroupProperty ¶
UpdateMetaObjectAttGroupProperty update object attribute group
type ObjAsstDes ¶
type ObjAsstDes struct {
metadata.ObjectAsst `json:",inline"`
}
ObjAsstDes association
type ObjAsstRsp ¶
type ObjAsstRsp struct { Result bool `json:"result"` Code int `json:"code"` Message interface{} `json:"message"` Data []ObjAsstDes `json:"data"` }
ObjAsstRsp 用于提取congtroller 返回的数据结构
type ObjAttDes ¶
type ObjAttDes struct { metadata.ObjectAttDes `json:",inline"` AssoType int `json:"bk_asst_type"` AsstForward string `json:"bk_asst_forward"` AssociationID string `json:"bk_asst_obj_id"` PropertyGroupName string `json:"bk_property_group_name"` }
ObjAttDes 对象模型属性
type ObjAttGroupDes ¶
type ObjAttGroupDes struct {
metadata.PropertyGroup `json:",inline"`
}
ObjAttGroupDes define property group
type ObjAttGroupRsp ¶
type ObjAttGroupRsp struct { Result bool `json:"result"` Code int `json:"code"` Message interface{} `json:"message"` Data []ObjAttGroupDes `json:"data"` }
ObjAttGroupRsp 用于提取controller 返回的数据结构
type ObjAttRsp ¶
type ObjAttRsp struct { Result bool `json:"result"` Code int `json:"code"` Message interface{} `json:"message"` Data []ObjAttDes `json:"data"` }
ObjAttRsp 用于提取controller 返回的数据结构
type ObjClsDes ¶
type ObjClsDes struct {
metadata.ObjClassification `json:",inline"`
}
ObjClsDes 对象分类(分栏/分组)
type ObjClsObjectDes ¶
type ObjClsObjectDes struct {
metadata.ObjClassificationObject `json:",inline"`
}
ObjClsObjectDes 分类下的对象模型
type ObjClsObjectRsp ¶
type ObjClsObjectRsp struct { Result bool `json:"result"` Code int `json:"code"` Message interface{} `json:"message"` Data []ObjClsObjectDes `json:"data"` }
ObjClsObjectRsp 用于提起controller返回的数据结构
Source Files ¶
- client.go
- object_create.go
- object_delete.go
- object_select.go
- object_update.go
- objectasst_create.go
- objectasst_delete.go
- objectasst_select.go
- objectasst_update.go
- objectatt_create.go
- objectatt_delete.go
- objectatt_group_create.go
- objectatt_group_delete.go
- objectatt_group_select.go
- objectatt_group_update.go
- objectatt_select.go
- objectatt_update.go
- objectcls_create.go
- objectcls_delete.go
- objectcls_select.go
- objectcls_update.go
- type.go