// Process the JPA named stored procedure query annotations.
// Look for a JPA @NamedStoredProcedureQueries.
MetadataAnnotation jpaNamedStoredProcedureQueries = getAnnotation(JPA_NAMED_STORED_PROCEDURE_QUERIES);
if (jpaNamedStoredProcedureQueries != null) {
for (Object jpaNamedStoredProcedureQuery : (Object[]) jpaNamedStoredProcedureQueries.getAttribute("value")) {
getProject().addQuery(new NamedStoredProcedureQueryMetadata((MetadataAnnotation) jpaNamedStoredProcedureQuery, this));
}
}
// Look for a JPA @NamedStoredProcedureQuery.
MetadataAnnotation jpaNamedStoredProcedureQuery = getAnnotation(JPA_NAMED_STORED_PROCEDURE_QUERY);
if (jpaNamedStoredProcedureQuery != null) {
getProject().addQuery(new NamedStoredProcedureQueryMetadata(jpaNamedStoredProcedureQuery, this));
}
// Process the named stored procedure query annotations.
// Look for a @NamedStoredProcedureQueries.
MetadataAnnotation namedStoredProcedureQueries = getAnnotation(org.eclipse.persistence.annotations.NamedStoredProcedureQueries.class);
if (namedStoredProcedureQueries != null) {
for (Object namedStoredProcedureQuery : (Object[]) namedStoredProcedureQueries.getAttribute("value")) {
getProject().addQuery(new NamedStoredProcedureQueryMetadata((MetadataAnnotation) namedStoredProcedureQuery, this));
}
}
// Look for a @NamedStoredProcedureQuery.
MetadataAnnotation namedStoredProcedureQuery = getAnnotation(org.eclipse.persistence.annotations.NamedStoredProcedureQuery.class);
if (namedStoredProcedureQuery != null) {
getProject().addQuery(new NamedStoredProcedureQueryMetadata(namedStoredProcedureQuery, this));
}
}