boolean isHinted(FetchConfiguration fetch, String hint) { if (fetch == null) return false; Object result = fetch.getHint(hint); return result != null && "true".equalsIgnoreCase(result.toString()); }
boolean isHinted(FetchConfiguration fetch, String hint) { if (fetch == null) return false; Object result = fetch.getHint(hint); return result != null && "true".equalsIgnoreCase(result.toString()); }
boolean isHinted(FetchConfiguration fetch, String hint) { if (fetch == null) return false; Object result = fetch.getHint(hint); return result != null && "true".equalsIgnoreCase(result.toString()); }
boolean isHinted(FetchConfiguration fetch, String hint) { if (fetch == null) return false; Object result = fetch.getHint(hint); return result != null && "true".equalsIgnoreCase(result.toString()); }
boolean isHinted(FetchConfiguration fetch, String hint) { if (fetch == null) return false; Object result = fetch.getHint(hint); return result != null && "true".equalsIgnoreCase(result.toString()); }
boolean isHinted(FetchConfiguration fetch, String hint) { if (fetch == null) return false; Object result = fetch.getHint(hint); return result != null && "true".equalsIgnoreCase(result.toString()); }
boolean isHinted(FetchConfiguration fetch, String hint) { if (fetch == null) return false; Object result = fetch.getHint(hint); return result != null && "true".equalsIgnoreCase(result.toString()); }
boolean isHinted(FetchConfiguration fetch, String hint) { if (fetch == null) return false; Object result = fetch.getHint(hint); return result != null && "true".equalsIgnoreCase(result.toString()); }
public Object getHint(String name) { try { return _fetch.getHint(name); } catch (RuntimeException re) { throw translate(re); } }
public Object getHint(String name) { try { return _fetch.getHint(name); } catch (RuntimeException re) { throw translate(re); } }
public Object getHint(String name) { try { return _fetch.getHint(name); } catch (RuntimeException re) { throw translate(re); } }
public Object getHint(String name) { try { return _fetch.getHint(name); } catch (RuntimeException re) { throw translate(re); } }
public Object getHint(String name) { try { return _fetch.getHint(name); } catch (RuntimeException re) { throw translate(re); } }
/** * Gets the list of slices mentioned as * {@link SlicePersistence#HINT_TARGET hint} of the given * {@link FetchConfiguration#getHint(String) fetch configuration}. * * @return all active slices if a) the hint is not specified or b) a null * value or c) a non-String or d) matches no active slice. */ List<SliceStoreManager> getTargets(FetchConfiguration fetch) { if (fetch == null) return _slices; Object hint = fetch.getHint(SlicePersistence.HINT_TARGET); if (hint == null || !(hint instanceof String || hint instanceof String[])) return _slices; String[] targetNames = hint instanceof String ? new String[]{hint.toString()} : (String[])hint; List<SliceStoreManager> targets = new ArrayList<SliceStoreManager>(); for (SliceStoreManager slice : _slices) { for (String name : targetNames) { if (slice.getName().equals(name)) { targets.add(slice); } } } if (targets.isEmpty()) return _slices; return targets; }
/** * Gets the list of slices mentioned as * {@link SlicePersistence#HINT_TARGET hint} of the given * {@link FetchConfiguration#getHint(String) fetch configuration}. * * @return all active slices if a) the hint is not specified or b) a null * value or c) a non-String or d) matches no active slice. */ List<SliceStoreManager> getTargets(FetchConfiguration fetch) { if (fetch == null) return _slices; Object hint = fetch.getHint(SlicePersistence.HINT_TARGET); if (hint == null || !(hint instanceof String || hint instanceof String[])) return _slices; String[] targetNames = hint instanceof String ? new String[]{hint.toString()} : (String[])hint; List<SliceStoreManager> targets = new ArrayList<SliceStoreManager>(); for (SliceStoreManager slice : _slices) { for (String name : targetNames) { if (slice.getName().equals(name)) { targets.add(slice); } } } if (targets.isEmpty()) return _slices; return targets; }
/** * Gets the list of slices mentioned as * {@link ProductDerivation#HINT_TARGET hint} of the given * {@link FetchConfiguration#getHint(String) fetch configuration}. * * @return all active slices if a) the hint is not specified or b) a null * value or c) a non-String or d) matches no active slice. */ List<SliceStoreManager> getTargets(FetchConfiguration fetch) { if (fetch == null) return _slices; Object hint = fetch.getHint(ProductDerivation.HINT_TARGET); if (hint == null || !(hint instanceof String)) return _slices; List<String> targetNames = Arrays.asList(hint.toString().split("\\,")); List<SliceStoreManager> targets = new ArrayList<SliceStoreManager>(); for (SliceStoreManager slice : _slices) { if (targetNames.contains(slice.getName())) targets.add(slice); } if (targets.isEmpty()) return _slices; return targets; }
/** * Gets the list of slices mentioned as * {@link SlicePersistence#HINT_TARGET hint} of the given * {@link FetchConfiguration#getHint(String) fetch configuration}. * * @return all active slices if a) the hint is not specified or b) a null * value or c) a non-String or d) matches no active slice. */ List<SliceStoreManager> getTargets(FetchConfiguration fetch) { if (fetch == null) return _slices; Object hint = fetch.getHint(SlicePersistence.HINT_TARGET); if (hint == null || !(hint instanceof String || hint instanceof String[])) return _slices; String[] targetNames = hint instanceof String ? new String[]{hint.toString()} : (String[])hint; List<SliceStoreManager> targets = new ArrayList<SliceStoreManager>(); for (SliceStoreManager slice : _slices) { for (String name : targetNames) { if (slice.getName().equals(name)) { targets.add(slice); } } } if (targets.isEmpty()) return _slices; return targets; }