/** * Returns all {@link QueryHint}s annotated at this class. Note, that {@link QueryHints} * * @return */ List<QueryHint> getHints() { QueryHints hints = AnnotatedElementUtils.findMergedAnnotation(method, QueryHints.class); if (hints != null) { return Arrays.asList(hints.value()); } return Collections.emptyList(); }
private static Map<String, Object> findQueryHints(Method method) { Map<String, Object> queryHints = new HashMap<String, Object>(); QueryHints queryHintsAnnotation = AnnotatedElementUtils.findMergedAnnotation(method, QueryHints.class); if (queryHintsAnnotation != null) { for (QueryHint hint : queryHintsAnnotation.value()) { queryHints.put(hint.name(), hint.value()); } } QueryHint queryHintAnnotation = AnnotationUtils.findAnnotation(method, QueryHint.class); if (queryHintAnnotation != null) { queryHints.put(queryHintAnnotation.name(), queryHintAnnotation.value()); } return Collections.unmodifiableMap(queryHints); }
/** * Returns all {@link QueryHint}s annotated at this class. Note, that {@link QueryHints} * * @return */ List<QueryHint> getHints() { QueryHints hints = AnnotatedElementUtils.findMergedAnnotation(method, QueryHints.class); if (hints != null) { return Arrays.asList(hints.value()); } return Collections.emptyList(); }
private static Map<String, Object> findQueryHints(Method method) { Map<String, Object> queryHints = new HashMap<String, Object>(); QueryHints queryHintsAnnotation = AnnotatedElementUtils.findMergedAnnotation(method, QueryHints.class); if (queryHintsAnnotation != null) { for (QueryHint hint : queryHintsAnnotation.value()) { queryHints.put(hint.name(), hint.value()); } } QueryHint queryHintAnnotation = AnnotationUtils.findAnnotation(method, QueryHint.class); if (queryHintAnnotation != null) { queryHints.put(queryHintAnnotation.name(), queryHintAnnotation.value()); } return Collections.unmodifiableMap(queryHints); }
private static Map<String, Object> findQueryHints(Method method) { Map<String, Object> queryHints = new HashMap<String, Object>(); QueryHints queryHintsAnnotation = AnnotatedElementUtils.findMergedAnnotation(method, QueryHints.class); if (queryHintsAnnotation != null) { for (QueryHint hint : queryHintsAnnotation.value()) { queryHints.put(hint.name(), hint.value()); } } QueryHint queryHintAnnotation = AnnotationUtils.findAnnotation(method, QueryHint.class); if (queryHintAnnotation != null) { queryHints.put(queryHintAnnotation.name(), queryHintAnnotation.value()); } return Collections.unmodifiableMap(queryHints); }
private static Map<String, Object> findQueryHints(Method method) { Map<String, Object> queryHints = new HashMap<String, Object>(); QueryHints queryHintsAnnotation = AnnotatedElementUtils.findMergedAnnotation(method, QueryHints.class); if (queryHintsAnnotation != null) { for (QueryHint hint : queryHintsAnnotation.value()) { queryHints.put(hint.name(), hint.value()); } } QueryHint queryHintAnnotation = AnnotationUtils.findAnnotation(method, QueryHint.class); if (queryHintAnnotation != null) { queryHints.put(queryHintAnnotation.name(), queryHintAnnotation.value()); } return Collections.unmodifiableMap(queryHints); }