generator.setParameter(JobSubmissionProtocolConstants.SUBMISSION_ID, value);
q = generator.selectQuery(em);
results = q.getResultList();
if (results.size() != 0) {
for (Object result : results) {
JobSubmissionProtocol jobSubmissionProtocol = (JobSubmissionProtocol) result;
JobSubmissionProtocolResource jobSubmissionProtocolResource =
(JobSubmissionProtocolResource) AppCatalogJPAUtils.getResource(AppCatalogResourceType.JOB_SUBMISSION_PROTOCOL, jobSubmissionProtocol);
jobSubmissionProtocolResourceList.add(jobSubmissionProtocolResource);
}
}
} else if (fieldName.equals(JobSubmissionProtocolConstants.JOB_TYPE)) {
generator.setParameter(JobSubmissionProtocolConstants.JOB_TYPE, value);
q = generator.selectQuery(em);
results = q.getResultList();
if (results.size() != 0) {
for (Object result : results) {
JobSubmissionProtocol jobSubmissionProtocol = (JobSubmissionProtocol) result;
JobSubmissionProtocolResource jobSubmissionProtocolResource =
(JobSubmissionProtocolResource) AppCatalogJPAUtils.getResource(AppCatalogResourceType.JOB_SUBMISSION_PROTOCOL, jobSubmissionProtocol);
jobSubmissionProtocolResourceList.add(jobSubmissionProtocolResource);
}
}
} else if (fieldName.equals(HostIPAddressConstants.RESOURCE_ID)) {
generator.setParameter(HostIPAddressConstants.RESOURCE_ID, value);
q = generator.selectQuery(em);
results = q.getResultList();
if (results.size() != 0) {
for (Object result : results) {
JobSubmissionProtocol jobSubmissionProtocol = (JobSubmissionProtocol) result;
JobSubmissionProtocolResource jobSubmissionProtocolResource =
(JobSubmissionProtocolResource) AppCatalogJPAUtils.getResource(AppCatalogResourceType.JOB_SUBMISSION_PROTOCOL, jobSubmissionProtocol);
jobSubmissionProtocolResourceList.add(jobSubmissionProtocolResource);
}
}