github.com/morlay/goqcloud@v0.0.0-20181123023149-b00e0b0b9afc/clients/sqlserver/describe_d_bs.go (about)

     1  package sqlserver
     2  
     3  import (
     4  	github_com_morlay_goqcloud "github.com/morlay/goqcloud"
     5  )
     6  
     7  // 查询数据库列表
     8  // https://cloud.tencent.com/document/api/238/19968
     9  
    10  type DescribeDBsRequest struct {
    11  	// 实例ID
    12  	InstanceIdSet []*string `name:"InstanceIdSet"`
    13  	// 每页记录数,最大为100,默认20
    14  	Limit *int64 `name:"Limit,omitempty"`
    15  	// 页编号,从第0页开始
    16  	Offset *int64 `name:"Offset,omitempty"`
    17  	// 区域
    18  	Region string `name:"Region"`
    19  }
    20  
    21  func (req *DescribeDBsRequest) Invoke(client github_com_morlay_goqcloud.Client) (*DescribeDBsResponse, error) {
    22  	resp := &DescribeDBsResponse{}
    23  	err := client.Request("sqlserver", "DescribeDBs", "2018-03-28").Do(req, resp)
    24  	return resp, err
    25  }
    26  
    27  type DescribeDBsResponse struct {
    28  	github_com_morlay_goqcloud.TencentCloudBaseResponse
    29  	// 实例数据库列表
    30  	DBInstances []*InstanceDBDetail `json:"DBInstances"`
    31  	// 数据库数量
    32  	TotalCount int64 `json:"TotalCount"`
    33  }