io.gravitee.management.model.ApiModelEntity Maven / Gradle / Ivy
/**
* 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 io.gravitee.common.component.Lifecycle;
import io.gravitee.definition.model.Path;
import io.gravitee.definition.model.Properties;
import io.gravitee.definition.model.Proxy;
import io.gravitee.definition.model.plugins.resources.Resource;
import io.gravitee.definition.model.services.Services;
import java.util.*;
/**
* @author Azize ELAMRANI (azize.elamrani at graviteesource.com)
* @author Nicolas GERAUD (nicolas.geraud at graviteesource.com)
* @author GraviteeSource Team
*/
public class ApiModelEntity {
private String id;
private String name;
private String version;
private String description;
private Set groups;
private Proxy proxy;
private Map paths = new HashMap<>();
private Date deployedAt;
private Date createdAt;
private Date updatedAt;
private Visibility visibility;
private Lifecycle.State state;
private PrimaryOwnerEntity primaryOwner;
private Properties properties;
private String role;
private Services services;
private Set tags;
private String picture;
private String pictureUrl;
private List resources = new ArrayList<>();
private Set views;
private Map metadata;
public String getId() {
return id;
}
public void setId(String id) {
this.id = id;
}
public Date getCreatedAt() {
return createdAt;
}
public void setCreatedAt(Date createdAt) {
this.createdAt = createdAt;
}
public String getName() {
return name;
}
public void setName(String name) {
this.name = name;
}
public Visibility getVisibility() {
return visibility;
}
public void setVisibility(Visibility visibility) {
this.visibility = visibility;
}
public Date getUpdatedAt() {
return updatedAt;
}
public void setUpdatedAt(Date updatedAt) {
this.updatedAt = updatedAt;
}
public String getVersion() {
return version;
}
public void setVersion(String version) {
this.version = version;
}
public String getDescription() {
return description;
}
public void setDescription(String description) {
this.description = description;
}
public Lifecycle.State getState() {
return state;
}
public void setState(Lifecycle.State state) {
this.state = state;
}
public Proxy getProxy() {
return proxy;
}
public void setProxy(Proxy proxy) {
this.proxy = proxy;
}
public Map getPaths() {
return paths;
}
public void setPaths(Map paths) {
this.paths = paths;
}
public String getRole() {
return role;
}
public void setRole(String role) {
this.role = role;
}
public PrimaryOwnerEntity getPrimaryOwner() {
return primaryOwner;
}
public void setPrimaryOwner(PrimaryOwnerEntity primaryOwner) {
this.primaryOwner = primaryOwner;
}
public Services getServices() {
return services;
}
public void setServices(Services services) {
this.services = services;
}
public Properties getProperties() {
return properties;
}
public void setProperties(Properties properties) {
this.properties = properties;
}
public Set getTags() {
return tags;
}
public void setTags(Set tags) {
this.tags = tags;
}
public Date getDeployedAt() {
return deployedAt;
}
public void setDeployedAt(Date deployedAt) {
this.deployedAt = deployedAt;
}
public String getPicture() {
return picture;
}
public void setPicture(String picture) {
this.picture = picture;
}
public String getPictureUrl() {
return pictureUrl;
}
public void setPictureUrl(String pictureUrl) {
this.pictureUrl = pictureUrl;
}
public List getResources() {
return resources;
}
public void setResources(List resources) {
this.resources = resources;
}
public Set getViews() {
return views;
}
public void setViews(Set views) {
this.views = views;
}
public Set getGroups() {
return groups;
}
public void setGroups(Set groups) {
this.groups = groups;
}
public Map getMetadata() {
return metadata;
}
public void setMetadata(Map metadata) {
this.metadata = metadata;
}
@Override
public boolean equals(Object o) {
if (this == o) return true;
if (o == null || getClass() != o.getClass()) return false;
ApiModelEntity api = (ApiModelEntity) o;
return Objects.equals(id, api.id) &&
Objects.equals(version, api.version);
}
@Override
public int hashCode() {
return Objects.hash(id, version);
}
public String toString() {
return "ApiEntity{" +
"id='" + id + '\'' +
", name='" + name + '\'' +
", version='" + version + '\'' +
", description='" + description + '\'' +
", proxy=" + proxy +
", paths=" + paths +
", createdAt=" + createdAt +
", updatedAt=" + updatedAt +
", visibility=" + visibility +
", state=" + state +
", primaryOwner=" + primaryOwner +
", role=" + role +
", tags=" + tags +
", view=" + views +
", groups=" + groups +
", metadata=" + metadata +
'}';
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy