Skip to content

Commit

Permalink
Merge pull request #637 from zgalor/update_model_0.0.197
Browse files Browse the repository at this point in the history
Bump ocm-api-model version to 0.0.197
  • Loading branch information
zgalor authored May 4, 2022
2 parents a263f5a + 924b397 commit 1eac901
Show file tree
Hide file tree
Showing 28 changed files with 5,625 additions and 4,884 deletions.
5 changes: 5 additions & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,11 @@
This document describes the relevant changes between releases of the OCM API
SDK.

## 0.1.265
- Update to model 0.0.197:
- Change inflight check type Details field to Interface


## 0.1.264
- Update to model 0.0.196:
- Added Machine Pool Security Group Filters for Machine Pools and Cluster Nodes
Expand Down
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
export CGO_ENABLED=0

# Details of the model to use:
model_version:=v0.0.196
model_version:=v0.0.197
model_url:=https://github.com/openshift-online/ocm-api-model.git

# Details of the metamodel to use:
Expand Down
18 changes: 15 additions & 3 deletions accountsmgmt/v1/account_builder.go
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ type AccountBuilder struct {
lastName string
organization *OrganizationBuilder
rhitAccountID string
rhitWebUserId string
updatedAt time.Time
username string
banned bool
Expand Down Expand Up @@ -170,12 +171,21 @@ func (b *AccountBuilder) RhitAccountID(value string) *AccountBuilder {
return b
}

// RhitWebUserId sets the value of the 'rhit_web_user_id' attribute to the given value.
//
//
func (b *AccountBuilder) RhitWebUserId(value string) *AccountBuilder {
b.rhitWebUserId = value
b.bitmap_ |= 8192
return b
}

// ServiceAccount sets the value of the 'service_account' attribute to the given value.
//
//
func (b *AccountBuilder) ServiceAccount(value bool) *AccountBuilder {
b.serviceAccount = value
b.bitmap_ |= 8192
b.bitmap_ |= 16384
return b
}

Expand All @@ -184,7 +194,7 @@ func (b *AccountBuilder) ServiceAccount(value bool) *AccountBuilder {
//
func (b *AccountBuilder) UpdatedAt(value time.Time) *AccountBuilder {
b.updatedAt = value
b.bitmap_ |= 16384
b.bitmap_ |= 32768
return b
}

Expand All @@ -193,7 +203,7 @@ func (b *AccountBuilder) UpdatedAt(value time.Time) *AccountBuilder {
//
func (b *AccountBuilder) Username(value string) *AccountBuilder {
b.username = value
b.bitmap_ |= 32768
b.bitmap_ |= 65536
return b
}

Expand Down Expand Up @@ -226,6 +236,7 @@ func (b *AccountBuilder) Copy(object *Account) *AccountBuilder {
b.organization = nil
}
b.rhitAccountID = object.rhitAccountID
b.rhitWebUserId = object.rhitWebUserId
b.serviceAccount = object.serviceAccount
b.updatedAt = object.updatedAt
b.username = object.username
Expand Down Expand Up @@ -261,6 +272,7 @@ func (b *AccountBuilder) Build() (object *Account, err error) {
}
}
object.rhitAccountID = b.rhitAccountID
object.rhitWebUserId = b.rhitWebUserId
object.serviceAccount = b.serviceAccount
object.updatedAt = b.updatedAt
object.username = b.username
Expand Down
40 changes: 32 additions & 8 deletions accountsmgmt/v1/account_type.go
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@ type Account struct {
lastName string
organization *Organization
rhitAccountID string
rhitWebUserId string
updatedAt time.Time
username string
banned bool
Expand Down Expand Up @@ -324,7 +325,7 @@ func (o *Account) GetOrganization() (value *Organization, ok bool) {
// RhitAccountID returns the value of the 'rhit_account_ID' attribute, or
// the zero value of the type if the attribute doesn't have a value.
//
//
// RhitAccountID will be deprecated in favor of RhitWebUserId
func (o *Account) RhitAccountID() string {
if o != nil && o.bitmap_&4096 != 0 {
return o.rhitAccountID
Expand All @@ -335,7 +336,7 @@ func (o *Account) RhitAccountID() string {
// GetRhitAccountID returns the value of the 'rhit_account_ID' attribute and
// a flag indicating if the attribute has a value.
//
//
// RhitAccountID will be deprecated in favor of RhitWebUserId
func (o *Account) GetRhitAccountID() (value string, ok bool) {
ok = o != nil && o.bitmap_&4096 != 0
if ok {
Expand All @@ -344,12 +345,35 @@ func (o *Account) GetRhitAccountID() (value string, ok bool) {
return
}

// RhitWebUserId returns the value of the 'rhit_web_user_id' attribute, or
// the zero value of the type if the attribute doesn't have a value.
//
//
func (o *Account) RhitWebUserId() string {
if o != nil && o.bitmap_&8192 != 0 {
return o.rhitWebUserId
}
return ""
}

// GetRhitWebUserId returns the value of the 'rhit_web_user_id' attribute and
// a flag indicating if the attribute has a value.
//
//
func (o *Account) GetRhitWebUserId() (value string, ok bool) {
ok = o != nil && o.bitmap_&8192 != 0
if ok {
value = o.rhitWebUserId
}
return
}

// ServiceAccount returns the value of the 'service_account' attribute, or
// the zero value of the type if the attribute doesn't have a value.
//
//
func (o *Account) ServiceAccount() bool {
if o != nil && o.bitmap_&8192 != 0 {
if o != nil && o.bitmap_&16384 != 0 {
return o.serviceAccount
}
return false
Expand All @@ -360,7 +384,7 @@ func (o *Account) ServiceAccount() bool {
//
//
func (o *Account) GetServiceAccount() (value bool, ok bool) {
ok = o != nil && o.bitmap_&8192 != 0
ok = o != nil && o.bitmap_&16384 != 0
if ok {
value = o.serviceAccount
}
Expand All @@ -372,7 +396,7 @@ func (o *Account) GetServiceAccount() (value bool, ok bool) {
//
//
func (o *Account) UpdatedAt() time.Time {
if o != nil && o.bitmap_&16384 != 0 {
if o != nil && o.bitmap_&32768 != 0 {
return o.updatedAt
}
return time.Time{}
Expand All @@ -383,7 +407,7 @@ func (o *Account) UpdatedAt() time.Time {
//
//
func (o *Account) GetUpdatedAt() (value time.Time, ok bool) {
ok = o != nil && o.bitmap_&16384 != 0
ok = o != nil && o.bitmap_&32768 != 0
if ok {
value = o.updatedAt
}
Expand All @@ -395,7 +419,7 @@ func (o *Account) GetUpdatedAt() (value time.Time, ok bool) {
//
//
func (o *Account) Username() string {
if o != nil && o.bitmap_&32768 != 0 {
if o != nil && o.bitmap_&65536 != 0 {
return o.username
}
return ""
Expand All @@ -406,7 +430,7 @@ func (o *Account) Username() string {
//
//
func (o *Account) GetUsername() (value string, ok bool) {
ok = o != nil && o.bitmap_&32768 != 0
ok = o != nil && o.bitmap_&65536 != 0
if ok {
value = o.username
}
Expand Down
23 changes: 18 additions & 5 deletions accountsmgmt/v1/account_type_json.go
Original file line number Diff line number Diff line change
Expand Up @@ -157,6 +157,15 @@ func writeAccount(object *Account, stream *jsoniter.Stream) {
count++
}
present_ = object.bitmap_&8192 != 0
if present_ {
if count > 0 {
stream.WriteMore()
}
stream.WriteObjectField("rhit_web_user_id")
stream.WriteString(object.rhitWebUserId)
count++
}
present_ = object.bitmap_&16384 != 0
if present_ {
if count > 0 {
stream.WriteMore()
Expand All @@ -165,7 +174,7 @@ func writeAccount(object *Account, stream *jsoniter.Stream) {
stream.WriteBool(object.serviceAccount)
count++
}
present_ = object.bitmap_&16384 != 0
present_ = object.bitmap_&32768 != 0
if present_ {
if count > 0 {
stream.WriteMore()
Expand All @@ -174,7 +183,7 @@ func writeAccount(object *Account, stream *jsoniter.Stream) {
stream.WriteString((object.updatedAt).Format(time.RFC3339))
count++
}
present_ = object.bitmap_&32768 != 0
present_ = object.bitmap_&65536 != 0
if present_ {
if count > 0 {
stream.WriteMore()
Expand Down Expand Up @@ -261,22 +270,26 @@ func readAccount(iterator *jsoniter.Iterator) *Account {
value := iterator.ReadString()
object.rhitAccountID = value
object.bitmap_ |= 4096
case "rhit_web_user_id":
value := iterator.ReadString()
object.rhitWebUserId = value
object.bitmap_ |= 8192
case "service_account":
value := iterator.ReadBool()
object.serviceAccount = value
object.bitmap_ |= 8192
object.bitmap_ |= 16384
case "updated_at":
text := iterator.ReadString()
value, err := time.Parse(time.RFC3339, text)
if err != nil {
iterator.ReportError("", err.Error())
}
object.updatedAt = value
object.bitmap_ |= 16384
object.bitmap_ |= 32768
case "username":
value := iterator.ReadString()
object.username = value
object.bitmap_ |= 32768
object.bitmap_ |= 65536
default:
iterator.ReadAny()
}
Expand Down
Loading

0 comments on commit 1eac901

Please sign in to comment.