generator.setParameter(GatewayProfileConstants.GATEWAY_ID, value);
q = generator.selectQuery(em);
results = q.getResultList();
if (results.size() != 0) {
for (Object result : results) {
GatewayProfile gatewayProfile = (GatewayProfile) result;
GatewayProfileResource gatewayProfileResource =
(GatewayProfileResource) AppCatalogJPAUtils.getResource(AppCatalogResourceType.GATEWAY_PROFILE, gatewayProfile);
gatewayProfileResources.add(gatewayProfileResource);
}
}
} else if (fieldName.equals(GatewayProfileConstants.GATEWAY_NAME)) {
generator.setParameter(GatewayProfileConstants.GATEWAY_NAME, value);
q = generator.selectQuery(em);
results = q.getResultList();
if (results.size() != 0) {
for (Object result : results) {
GatewayProfile gatewayProfile = (GatewayProfile) result;
GatewayProfileResource gatewayProfileResource =
(GatewayProfileResource) AppCatalogJPAUtils.getResource(AppCatalogResourceType.GATEWAY_PROFILE, gatewayProfile);
gatewayProfileResources.add(gatewayProfileResource);
}
}