This repository has been archived by the owner on Aug 20, 2021. It is now read-only.
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
This closes gravitee-io/issues#1818
- Loading branch information
Showing
40 changed files
with
1,565 additions
and
179 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
133 changes: 133 additions & 0 deletions
133
...tee-management-api-model/src/main/java/io/gravitee/management/model/InvitationEntity.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,133 @@ | ||
/** | ||
* Copyright (C) 2015 The Gravitee team (http://gravitee.io) | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License"); | ||
* you may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
*/ | ||
package io.gravitee.management.model; | ||
|
||
import com.fasterxml.jackson.annotation.JsonProperty; | ||
|
||
import java.util.Date; | ||
import java.util.Objects; | ||
|
||
/** | ||
* @author Azize ELAMRANI (azize.elamrani at graviteesource.com) | ||
* @author GraviteeSource Team | ||
*/ | ||
public class InvitationEntity { | ||
private String id; | ||
@JsonProperty("reference_type") | ||
private InvitationReferenceType referenceType; | ||
@JsonProperty("reference_id") | ||
private String referenceId; | ||
private String email; | ||
@JsonProperty("api_role") | ||
private String apiRole; | ||
@JsonProperty("application_role") | ||
private String applicationRole; | ||
@JsonProperty("created_at") | ||
private Date createdAt; | ||
@JsonProperty("updated_at") | ||
private Date updatedAt; | ||
|
||
public String getId() { | ||
return id; | ||
} | ||
|
||
public void setId(String id) { | ||
this.id = id; | ||
} | ||
|
||
public InvitationReferenceType getReferenceType() { | ||
return referenceType; | ||
} | ||
|
||
public void setReferenceType(InvitationReferenceType referenceType) { | ||
this.referenceType = referenceType; | ||
} | ||
|
||
public String getReferenceId() { | ||
return referenceId; | ||
} | ||
|
||
public void setReferenceId(String referenceId) { | ||
this.referenceId = referenceId; | ||
} | ||
|
||
public String getEmail() { | ||
return email; | ||
} | ||
|
||
public void setEmail(String email) { | ||
this.email = email; | ||
} | ||
|
||
public String getApiRole() { | ||
return apiRole; | ||
} | ||
|
||
public void setApiRole(String apiRole) { | ||
this.apiRole = apiRole; | ||
} | ||
|
||
public String getApplicationRole() { | ||
return applicationRole; | ||
} | ||
|
||
public void setApplicationRole(String applicationRole) { | ||
this.applicationRole = applicationRole; | ||
} | ||
|
||
public Date getCreatedAt() { | ||
return createdAt; | ||
} | ||
|
||
public void setCreatedAt(Date createdAt) { | ||
this.createdAt = createdAt; | ||
} | ||
|
||
public Date getUpdatedAt() { | ||
return updatedAt; | ||
} | ||
|
||
public void setUpdatedAt(Date updatedAt) { | ||
this.updatedAt = updatedAt; | ||
} | ||
|
||
@Override | ||
public boolean equals(Object o) { | ||
if (this == o) return true; | ||
if (!(o instanceof InvitationEntity)) return false; | ||
InvitationEntity that = (InvitationEntity) o; | ||
return Objects.equals(id, that.id); | ||
} | ||
|
||
@Override | ||
public int hashCode() { | ||
return Objects.hash(id); | ||
} | ||
|
||
@Override | ||
public String toString() { | ||
return "InvitationEntity{" + | ||
"id='" + id + '\'' + | ||
", referenceType=" + referenceType + | ||
", referenceId='" + referenceId + '\'' + | ||
", email='" + email + '\'' + | ||
", apiRole='" + apiRole + '\'' + | ||
", applicationRole='" + applicationRole + '\'' + | ||
", createdAt=" + createdAt + | ||
", updatedAt=" + updatedAt + | ||
'}'; | ||
} | ||
} |
24 changes: 24 additions & 0 deletions
24
...agement-api-model/src/main/java/io/gravitee/management/model/InvitationReferenceType.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
/** | ||
* Copyright (C) 2015 The Gravitee team (http://gravitee.io) | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License"); | ||
* you may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
*/ | ||
package io.gravitee.management.model; | ||
|
||
/** | ||
* @author Azize ELAMRANI (azize.elamrani at graviteesource.com) | ||
* @author GraviteeSource Team | ||
*/ | ||
public enum InvitationReferenceType { | ||
API, APPLICATION, GROUP | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.