You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cloudstack.apache.org by da...@apache.org on 2024/12/30 15:18:37 UTC
(cloudstack-go) 13/25: add NewQuotaUpdateParams for QuotaUpdate
This is an automated email from the ASF dual-hosted git repository.
dahn pushed a commit to branch pr90
in repository https://gitbox.apache.org/repos/asf/cloudstack-go.git
commit ed2fe1df670b94143f074a77b99a7f720ed58adb
Author: tonymmm1 <to...@mail.magnatox.com>
AuthorDate: Mon Jul 22 18:35:19 2024 -0500
add NewQuotaUpdateParams for QuotaUpdate
---
cloudstack/QuotaService.go | 13 +++++++++++++
1 file changed, 13 insertions(+)
diff --git a/cloudstack/QuotaService.go b/cloudstack/QuotaService.go
index ee35453..7f28459 100644
--- a/cloudstack/QuotaService.go
+++ b/cloudstack/QuotaService.go
@@ -45,6 +45,7 @@ type QuotaServiceIface interface {
QuotaTariffUpdate(p *QuotaTariffUpdateParams) (*QuotaTariffUpdateResponse, error)
NewQuotaTariffUpdateParams(name string) *QuotaTariffUpdateParams
QuotaUpdate() (*QuotaUpdateResponse, error)
+ NewQuotaUpdateParams() *QuotaUpdateParams
}
type QuotaBalanceParams struct {
@@ -1400,6 +1401,18 @@ type QuotaTariffUpdateResponse struct {
Uuid string `json:"uuid"`
}
+type QuotaUpdateParams struct {
+ p map[string]interface{}
+}
+
+// You should always use this function to get a new QuotaUpdateParams instance,
+// as then you are sure you have configured all required params
+func (s *QuotaService) NewQuotaUpdateParams() *QuotaUpdateParams {
+ p := &QuotaUpdateParams{}
+ p.p = make(map[string]interface{})
+ return p
+}
+
func (s *QuotaService) QuotaUpdate() (*QuotaUpdateResponse, error) {
resp, err := s.cs.newRequest("quotaUpdate", nil)
if err != nil {