Refine search
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 whether the potentially configured {@link QueryHint}s shall be applied when triggering the count query for * pagination. * * @return */ boolean applyHintsToCountQuery() { QueryHints hints = AnnotatedElementUtils.findMergedAnnotation(method, QueryHints.class); return hints != null ? hints.forCounting() : false; }
@QueryHints({@QueryHint(name = org.hibernate.jpa.QueryHints.HINT_CACHEABLE, value = "true")}) DemoSiteUser findByAccount(Account account); }
/** * 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(); }
@QueryHints({@QueryHint(name = org.hibernate.jpa.QueryHints.HINT_CACHEABLE, value = "true")}) List<DistrictData> findAllByOrderByIdAsc(); }
/** * 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(); }
@QueryHints({@QueryHint(name = org.hibernate.jpa.QueryHints.HINT_CACHEABLE, value = "true")}) List<AttachmentFile> findBySourceTypeAndSourceIdAndSourceCategoryOrderByOrderIndexAsc(String sourceType, String sourceId, String sourceCategory);
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 whether the potentially configured {@link QueryHint}s shall be applied when triggering the count query for * pagination. * * @return */ boolean applyHintsToCountQuery() { QueryHints hints = AnnotatedElementUtils.findMergedAnnotation(method, QueryHints.class); return hints != null ? hints.forCounting() : false; }
@QueryHints({@QueryHint(name = org.hibernate.jpa.QueryHints.HINT_CACHEABLE, value = "true")}) List<DistrictData> findByIdStartsWithOrderByIdAsc(String idPrefix);
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); }
@QueryHints({@QueryHint(name = org.hibernate.jpa.QueryHints.HINT_CACHEABLE, value = "true")}) Account findByAccessToken(String accessToken); }
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); }
@QueryHints({@QueryHint(name = org.hibernate.jpa.QueryHints.HINT_CACHEABLE, value = "true")}) Account findByDataDomainAndAuthTypeAndMobile(String dataDomain, Account.AuthTypeEnum authType, String mobile);
@QueryHints({@QueryHint(name = org.hibernate.jpa.QueryHints.HINT_CACHEABLE, value = "true")}) Account findByEmail(String email);
@QueryHints({@QueryHint(name = org.hibernate.jpa.QueryHints.HINT_CACHEABLE, value = "true")}) Account findByMobile(String mobile);
@QueryHints({@QueryHint(name = org.hibernate.jpa.QueryHints.HINT_CACHEABLE, value = "true")}) ConfigProperty findByPropKey(String propKey); }
@QueryHints({ @QueryHint(name = org.hibernate.jpa.QueryHints.HINT_CACHEABLE, value = "true") }) JobBeanCfg findByJobClass(String jobClass); }
@QueryHints({@QueryHint(name = org.hibernate.jpa.QueryHints.HINT_CACHEABLE, value = "true")}) OauthAccount findByAccountAndOauthOpenIdAndOauthTypeAndAuthType(Account account, String oauthOpenId, GlobalConstant.OauthTypeEnum oauthType, Account.AuthTypeEnum authType); }
@QueryHints(@QueryHint(name = org.hibernate.ejb.QueryHints.HINT_CACHEABLE, value = "true")) Role findByIdentifier(RoleIdentifier identifier);