1- /*
2- Copyright (c) 2018 VMware, Inc. All Rights Reserved.
3-
4- Licensed under the Apache License, Version 2.0 (the "License");
5- you may not use this file except in compliance with the License.
6- You may obtain a copy of the License at
7-
8- http://www.apache.org/licenses/LICENSE-2.0
9-
10- Unless required by applicable law or agreed to in writing, software
11- distributed under the License is distributed on an "AS IS" BASIS,
12- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13- See the License for the specific language governing permissions and
14- limitations under the License.
15- */
1+ // © Broadcom. All Rights Reserved.
2+ // The term “Broadcom” refers to Broadcom Inc. and/or its subsidiaries.
3+ // SPDX-License-Identifier: Apache-2.0
164
175package tags
186
@@ -34,6 +22,7 @@ type Category struct {
3422 Cardinality string `json:"cardinality,omitempty"`
3523 AssociableTypes []string `json:"associable_types,omitempty"`
3624 UsedBy []string `json:"used_by,omitempty"`
25+ CategoryID string `json:"category_id,omitempty"`
3726}
3827
3928func (c * Category ) hasType (kind string ) bool {
@@ -74,6 +63,7 @@ func (c *Manager) CreateCategory(ctx context.Context, category *Category) (strin
7463 Description string `json:"description"`
7564 Cardinality string `json:"cardinality"`
7665 AssociableTypes []string `json:"associable_types"`
66+ CategoryID string `json:"category_id,omitempty"`
7767 }
7868 spec := struct {
7969 Category create `json:"create_spec"`
@@ -83,6 +73,7 @@ func (c *Manager) CreateCategory(ctx context.Context, category *Category) (strin
8373 Description : category .Description ,
8474 Cardinality : category .Cardinality ,
8575 AssociableTypes : category .AssociableTypes ,
76+ CategoryID : category .CategoryID ,
8677 },
8778 }
8879 if spec .Category .AssociableTypes == nil {
0 commit comments