forked from community/device-mgt-core
commit
f587e2a38f
@ -0,0 +1,312 @@
|
||||
/*
|
||||
* Copyright (c) 2018 - 2023, Entgra (Pvt) Ltd. (http://www.entgra.io) All Rights Reserved.
|
||||
*
|
||||
* Entgra (Pvt) Ltd. licenses this file to you 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.entgra.device.mgt.core.apimgt.extension.rest.api.bean.APIMConsumer;
|
||||
|
||||
import io.entgra.device.mgt.core.apimgt.extension.rest.api.util.ScopeUtils;
|
||||
import org.json.JSONObject;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import java.util.Set;
|
||||
|
||||
/**
|
||||
* This class represents the Consumer API Information.
|
||||
*/
|
||||
|
||||
public class APIInfo {
|
||||
|
||||
private String id;
|
||||
private String name;
|
||||
private String description;
|
||||
private String context;
|
||||
private String version;
|
||||
private String provider;
|
||||
private JSONObject apiDefinition;
|
||||
private String wsdlUri;
|
||||
private String lifeCycleStatus;
|
||||
private boolean isDefaultVersion;
|
||||
private String type;
|
||||
private Set<String> transport;
|
||||
private List<JSONObject> operations;
|
||||
private String authorizationHeader;
|
||||
private String securityScheme;
|
||||
private Set<String> tags;
|
||||
private List<JSONObject> tiers;
|
||||
private boolean hasThumbnail;
|
||||
private String additionalProperties;
|
||||
private JSONObject monetization;
|
||||
private List<JSONObject> endpointURLs;
|
||||
private JSONObject businessInformation;
|
||||
private List<JSONObject> environmentList;
|
||||
private List<ScopeUtils> scopes;
|
||||
private String avgRating;
|
||||
private JSONObject advertiseInfo;
|
||||
private boolean isSubscriptionAvailable;
|
||||
private List<JSONObject> categories;
|
||||
private List<String> keyManagers = new ArrayList();
|
||||
private String createdTime;
|
||||
private String lastUpdatedTime;
|
||||
|
||||
public String getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
public void setId(String id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public String getName() {
|
||||
return name;
|
||||
}
|
||||
|
||||
public void setName(String name) {
|
||||
this.name = name;
|
||||
}
|
||||
|
||||
public String getDescription() {
|
||||
return description;
|
||||
}
|
||||
|
||||
public void setDescription(String description) {
|
||||
this.description = description;
|
||||
}
|
||||
|
||||
public String getContext() {
|
||||
return context;
|
||||
}
|
||||
|
||||
public void setContext(String context) {
|
||||
this.context = context;
|
||||
}
|
||||
|
||||
public String getVersion() {
|
||||
return version;
|
||||
}
|
||||
|
||||
public void setVersion(String version) {
|
||||
this.version = version;
|
||||
}
|
||||
|
||||
public String getProvider() {
|
||||
return provider;
|
||||
}
|
||||
|
||||
public void setProvider(String provider) {
|
||||
this.provider = provider;
|
||||
}
|
||||
|
||||
public JSONObject getApiDefinition() {
|
||||
return apiDefinition;
|
||||
}
|
||||
|
||||
public void setApiDefinition(JSONObject apiDefinition) {
|
||||
this.apiDefinition = apiDefinition;
|
||||
}
|
||||
|
||||
public String getWsdlUri() {
|
||||
return wsdlUri;
|
||||
}
|
||||
|
||||
public void setWsdlUri(String wsdlUri) {
|
||||
this.wsdlUri = wsdlUri;
|
||||
}
|
||||
|
||||
public String getLifeCycleStatus() {
|
||||
return lifeCycleStatus;
|
||||
}
|
||||
|
||||
public void setLifeCycleStatus(String lifeCycleStatus) {
|
||||
this.lifeCycleStatus = lifeCycleStatus;
|
||||
}
|
||||
|
||||
public boolean isDefaultVersion() {
|
||||
return isDefaultVersion;
|
||||
}
|
||||
|
||||
public void setDefaultVersion(boolean defaultVersion) {
|
||||
isDefaultVersion = defaultVersion;
|
||||
}
|
||||
|
||||
public String getType() {
|
||||
return type;
|
||||
}
|
||||
|
||||
public void setType(String type) {
|
||||
this.type = type;
|
||||
}
|
||||
|
||||
public Set<String> getTransport() {
|
||||
return transport;
|
||||
}
|
||||
|
||||
public void setTransport(Set<String> transport) {
|
||||
this.transport = transport;
|
||||
}
|
||||
|
||||
public List<JSONObject> getOperations() {
|
||||
return operations;
|
||||
}
|
||||
|
||||
public void setOperations(List<JSONObject> operations) {
|
||||
this.operations = operations;
|
||||
}
|
||||
|
||||
public String getAuthorizationHeader() {
|
||||
return authorizationHeader;
|
||||
}
|
||||
|
||||
public void setAuthorizationHeader(String authorizationHeader) {
|
||||
this.authorizationHeader = authorizationHeader;
|
||||
}
|
||||
|
||||
public String getSecurityScheme() {
|
||||
return securityScheme;
|
||||
}
|
||||
|
||||
public void setSecurityScheme(String securityScheme) {
|
||||
this.securityScheme = securityScheme;
|
||||
}
|
||||
|
||||
public Set<String> getTags() {
|
||||
return tags;
|
||||
}
|
||||
|
||||
public void setTags(Set<String> tags) {
|
||||
this.tags = tags;
|
||||
}
|
||||
|
||||
public List<JSONObject> getTiers() {
|
||||
return tiers;
|
||||
}
|
||||
|
||||
public void setTiers(List<JSONObject> tiers) {
|
||||
this.tiers = tiers;
|
||||
}
|
||||
|
||||
public boolean isHasThumbnail() {
|
||||
return hasThumbnail;
|
||||
}
|
||||
|
||||
public void setHasThumbnail(boolean hasThumbnail) {
|
||||
this.hasThumbnail = hasThumbnail;
|
||||
}
|
||||
|
||||
public String getAdditionalProperties() {
|
||||
return additionalProperties;
|
||||
}
|
||||
|
||||
public void setAdditionalProperties(String additionalProperties) {
|
||||
this.additionalProperties = additionalProperties;
|
||||
}
|
||||
|
||||
public JSONObject getMonetization() {
|
||||
return monetization;
|
||||
}
|
||||
|
||||
public void setMonetization(JSONObject monetization) {
|
||||
this.monetization = monetization;
|
||||
}
|
||||
|
||||
public List<JSONObject> getEndpointURLs() {
|
||||
return endpointURLs;
|
||||
}
|
||||
|
||||
public void setEndpointURLs(List<JSONObject> endpointURLs) {
|
||||
this.endpointURLs = endpointURLs;
|
||||
}
|
||||
|
||||
public JSONObject getBusinessInformation() {
|
||||
return businessInformation;
|
||||
}
|
||||
|
||||
public void setBusinessInformation(JSONObject businessInformation) {
|
||||
this.businessInformation = businessInformation;
|
||||
}
|
||||
|
||||
public List<JSONObject> getEnvironmentList() {
|
||||
return environmentList;
|
||||
}
|
||||
|
||||
public void setEnvironmentList(List<JSONObject> environmentList) {
|
||||
this.environmentList = environmentList;
|
||||
}
|
||||
|
||||
public List<ScopeUtils> getScopes() {
|
||||
return scopes;
|
||||
}
|
||||
|
||||
public void setScopes(List<ScopeUtils> scopes) {
|
||||
this.scopes = scopes;
|
||||
}
|
||||
|
||||
public String getAvgRating() {
|
||||
return avgRating;
|
||||
}
|
||||
|
||||
public void setAvgRating(String avgRating) {
|
||||
this.avgRating = avgRating;
|
||||
}
|
||||
|
||||
public JSONObject getAdvertiseInfo() {
|
||||
return advertiseInfo;
|
||||
}
|
||||
|
||||
public void setAdvertiseInfo(JSONObject advertiseInfo) {
|
||||
this.advertiseInfo = advertiseInfo;
|
||||
}
|
||||
|
||||
public boolean isSubscriptionAvailable() {
|
||||
return isSubscriptionAvailable;
|
||||
}
|
||||
|
||||
public void setSubscriptionAvailable(boolean subscriptionAvailable) {
|
||||
isSubscriptionAvailable = subscriptionAvailable;
|
||||
}
|
||||
|
||||
public List<JSONObject> getCategories() {
|
||||
return categories;
|
||||
}
|
||||
|
||||
public void setCategories(List<JSONObject> categories) {
|
||||
this.categories = categories;
|
||||
}
|
||||
|
||||
public List<String> getKeyManagers() {
|
||||
return keyManagers;
|
||||
}
|
||||
|
||||
public void setKeyManagers(List<String> keyManagers) {
|
||||
this.keyManagers = keyManagers;
|
||||
}
|
||||
|
||||
public String getCreatedTime() {
|
||||
return createdTime;
|
||||
}
|
||||
|
||||
public void setCreatedTime(String createdTime) {
|
||||
this.createdTime = createdTime;
|
||||
}
|
||||
|
||||
public String getLastUpdatedTime() {
|
||||
return lastUpdatedTime;
|
||||
}
|
||||
|
||||
public void setLastUpdatedTime(String lastUpdatedTime) {
|
||||
this.lastUpdatedTime = lastUpdatedTime;
|
||||
}
|
||||
}
|
@ -0,0 +1,110 @@
|
||||
/*
|
||||
* Copyright (c) 2018 - 2023, Entgra (Pvt) Ltd. (http://www.entgra.io) All Rights Reserved.
|
||||
*
|
||||
* Entgra (Pvt) Ltd. licenses this file to you 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.entgra.device.mgt.core.apimgt.extension.rest.api.bean.APIMConsumer;
|
||||
|
||||
import io.apicurio.datamodels.asyncapi.v2.visitors.Aai20Traverser;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* This class represents the Consumer Application configuration Information.
|
||||
*/
|
||||
public class ApplicationConfigurations {
|
||||
|
||||
private String name;
|
||||
private String label;
|
||||
private String type;
|
||||
private boolean required;
|
||||
private boolean mask;
|
||||
private boolean multiple;
|
||||
private String tooltip;
|
||||
private List<String> values;
|
||||
private String defaults;
|
||||
|
||||
public String getName() {
|
||||
return name;
|
||||
}
|
||||
|
||||
public void setName(String name) {
|
||||
this.name = name;
|
||||
}
|
||||
|
||||
public String getLabel() {
|
||||
return label;
|
||||
}
|
||||
|
||||
public void setLabel(String label) {
|
||||
this.label = label;
|
||||
}
|
||||
|
||||
public String getType() {
|
||||
return type;
|
||||
}
|
||||
|
||||
public void setType(String type) {
|
||||
this.type = type;
|
||||
}
|
||||
|
||||
public boolean isRequired() {
|
||||
return required;
|
||||
}
|
||||
|
||||
public void setRequired(boolean required) {
|
||||
this.required = required;
|
||||
}
|
||||
|
||||
public boolean isMask() {
|
||||
return mask;
|
||||
}
|
||||
|
||||
public void setMask(boolean mask) {
|
||||
this.mask = mask;
|
||||
}
|
||||
|
||||
public boolean isMultiple() {
|
||||
return multiple;
|
||||
}
|
||||
|
||||
public void setMultiple(boolean multiple) {
|
||||
this.multiple = multiple;
|
||||
}
|
||||
|
||||
public String getTooltip() {
|
||||
return tooltip;
|
||||
}
|
||||
|
||||
public void setTooltip(String tooltip) {
|
||||
this.tooltip = tooltip;
|
||||
}
|
||||
|
||||
public List<String> getValues() {
|
||||
return values;
|
||||
}
|
||||
|
||||
public void setValues(List<String> values) {
|
||||
this.values = values;
|
||||
}
|
||||
|
||||
public String getDefaults() {
|
||||
return defaults;
|
||||
}
|
||||
|
||||
public void setDefaults(String defaults) {
|
||||
this.defaults = defaults;
|
||||
}
|
||||
}
|
@ -0,0 +1,184 @@
|
||||
/*
|
||||
* Copyright (c) 2018 - 2023, Entgra (Pvt) Ltd. (http://www.entgra.io) All Rights Reserved.
|
||||
*
|
||||
* Entgra (Pvt) Ltd. licenses this file to you 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.entgra.device.mgt.core.apimgt.extension.rest.api.bean.APIMConsumer;
|
||||
|
||||
import org.json.JSONObject;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* This class represents the Consumer Key manager Information.
|
||||
*/
|
||||
|
||||
public class KeyManager {
|
||||
|
||||
private String id;
|
||||
private String name;
|
||||
private String type;
|
||||
private String displayName;
|
||||
private String description;
|
||||
private boolean enabled;
|
||||
private List<String> availableGrantTypes;
|
||||
private String tokenEndpoint;
|
||||
private String revokeEndpoint;
|
||||
private String userInfoEndpoint;
|
||||
private String enableTokenGeneration;
|
||||
private String enableTokenEncryption;
|
||||
private String enableTokenHashing;
|
||||
private String enableOAuthAppCreation;
|
||||
private String enableMapOAuthConsumerApps;
|
||||
private List<ApplicationConfigurations> applicationConfiguration;
|
||||
private JSONObject additionalProperties;
|
||||
|
||||
public String getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
public void setId(String id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public String getName() {
|
||||
return name;
|
||||
}
|
||||
|
||||
public void setName(String name) {
|
||||
this.name = name;
|
||||
}
|
||||
|
||||
public String getType() {
|
||||
return type;
|
||||
}
|
||||
|
||||
public void setType(String type) {
|
||||
this.type = type;
|
||||
}
|
||||
|
||||
public String getDisplayName() {
|
||||
return displayName;
|
||||
}
|
||||
|
||||
public void setDisplayName(String displayName) {
|
||||
this.displayName = displayName;
|
||||
}
|
||||
|
||||
public String getDescription() {
|
||||
return description;
|
||||
}
|
||||
|
||||
public void setDescription(String description) {
|
||||
this.description = description;
|
||||
}
|
||||
|
||||
public boolean isEnabled() {
|
||||
return enabled;
|
||||
}
|
||||
|
||||
public void setEnabled(boolean enabled) {
|
||||
this.enabled = enabled;
|
||||
}
|
||||
|
||||
public List<String> getAvailableGrantTypes() {
|
||||
return availableGrantTypes;
|
||||
}
|
||||
|
||||
public void setAvailableGrantTypes(List<String> availableGrantTypes) {
|
||||
this.availableGrantTypes = availableGrantTypes;
|
||||
}
|
||||
|
||||
public String getTokenEndpoint() {
|
||||
return tokenEndpoint;
|
||||
}
|
||||
|
||||
public void setTokenEndpoint(String tokenEndpoint) {
|
||||
this.tokenEndpoint = tokenEndpoint;
|
||||
}
|
||||
|
||||
public String getRevokeEndpoint() {
|
||||
return revokeEndpoint;
|
||||
}
|
||||
|
||||
public void setRevokeEndpoint(String revokeEndpoint) {
|
||||
this.revokeEndpoint = revokeEndpoint;
|
||||
}
|
||||
|
||||
public String getUserInfoEndpoint() {
|
||||
return userInfoEndpoint;
|
||||
}
|
||||
|
||||
public void setUserInfoEndpoint(String userInfoEndpoint) {
|
||||
this.userInfoEndpoint = userInfoEndpoint;
|
||||
}
|
||||
|
||||
public String getEnableTokenGeneration() {
|
||||
return enableTokenGeneration;
|
||||
}
|
||||
|
||||
public void setEnableTokenGeneration(String enableTokenGeneration) {
|
||||
this.enableTokenGeneration = enableTokenGeneration;
|
||||
}
|
||||
|
||||
public String getEnableTokenEncryption() {
|
||||
return enableTokenEncryption;
|
||||
}
|
||||
|
||||
public void setEnableTokenEncryption(String enableTokenEncryption) {
|
||||
this.enableTokenEncryption = enableTokenEncryption;
|
||||
}
|
||||
|
||||
public String getEnableTokenHashing() {
|
||||
return enableTokenHashing;
|
||||
}
|
||||
|
||||
public void setEnableTokenHashing(String enableTokenHashing) {
|
||||
this.enableTokenHashing = enableTokenHashing;
|
||||
}
|
||||
|
||||
public String getEnableOAuthAppCreation() {
|
||||
return enableOAuthAppCreation;
|
||||
}
|
||||
|
||||
public void setEnableOAuthAppCreation(String enableOAuthAppCreation) {
|
||||
this.enableOAuthAppCreation = enableOAuthAppCreation;
|
||||
}
|
||||
|
||||
public String getEnableMapOAuthConsumerApps() {
|
||||
return enableMapOAuthConsumerApps;
|
||||
}
|
||||
|
||||
public void setEnableMapOAuthConsumerApps(String enableMapOAuthConsumerApps) {
|
||||
this.enableMapOAuthConsumerApps = enableMapOAuthConsumerApps;
|
||||
}
|
||||
|
||||
public List<ApplicationConfigurations> getApplicationConfiguration() {
|
||||
return applicationConfiguration;
|
||||
}
|
||||
|
||||
public void setApplicationConfiguration(List<ApplicationConfigurations> applicationConfiguration) {
|
||||
this.applicationConfiguration = applicationConfiguration;
|
||||
}
|
||||
|
||||
public JSONObject getAdditionalProperties() {
|
||||
return additionalProperties;
|
||||
}
|
||||
|
||||
public void setAdditionalProperties(JSONObject additionalProperties) {
|
||||
this.additionalProperties = additionalProperties;
|
||||
}
|
||||
}
|
@ -0,0 +1,65 @@
|
||||
/*
|
||||
* Copyright (c) 2018 - 2023, Entgra (Pvt) Ltd. (http://www.entgra.io) All Rights Reserved.
|
||||
*
|
||||
* Entgra (Pvt) Ltd. licenses this file to you 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.entgra.device.mgt.core.apimgt.extension.rest.api.bean.APIMConsumer;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* This class represents the scope data.
|
||||
*/
|
||||
|
||||
public class Scopes {
|
||||
|
||||
private String key;
|
||||
private String name;
|
||||
private List<String> roles;
|
||||
private String description;
|
||||
|
||||
public String getKey() {
|
||||
return key;
|
||||
}
|
||||
|
||||
public void setKey(String key) {
|
||||
this.key = key;
|
||||
}
|
||||
|
||||
public String getName() {
|
||||
return name;
|
||||
}
|
||||
|
||||
public void setName(String name) {
|
||||
this.name = name;
|
||||
}
|
||||
|
||||
public List<String> getRoles() {
|
||||
return roles;
|
||||
}
|
||||
|
||||
public void setRoles(List<String> roles) {
|
||||
this.roles = roles;
|
||||
}
|
||||
|
||||
public String getDescription() {
|
||||
return description;
|
||||
}
|
||||
|
||||
public void setDescription(String description) {
|
||||
this.description = description;
|
||||
}
|
||||
}
|
Loading…
Reference in new issue