/** * Recursion depth for the given field. This is the depth of relations of * the same class as this one we can fetch through the given field. */ public int getRecursionDepth(FieldMetaData fm) { Number depth = findRecursionDepth(fm); return (depth == null) ? RECURSION_DEPTH_DEFAULT : depth.intValue(); }
/** * Recursion depth for the given field. This is the depth of relations of * the same class as this one we can fetch through the given field. */ public int getRecursionDepth(FieldMetaData fm) { Number depth = findRecursionDepth(fm); return (depth == null) ? RECURSION_DEPTH_DEFAULT : depth.intValue(); }
/** * Recursion depth for the given field. This is the depth of relations of * the same class as this one we can fetch through the given field. */ public int getRecursionDepth(FieldMetaData fm) { Number depth = findRecursionDepth(fm); return (depth == null) ? RECURSION_DEPTH_DEFAULT : depth.intValue(); }
/** * Recursion depth for the given field. This is the depth of relations of * the same class as this one we can fetch through the given field. */ public int getRecursionDepth(FieldMetaData fm) { Number depth = findRecursionDepth(fm); return (depth == null) ? RECURSION_DEPTH_DEFAULT : depth.intValue(); }
/** * Recursion depth for the given field. This is the depth of relations of * the same class as this one we can fetch through the given field. */ public int getRecursionDepth(FieldMetaData fm) { Number depth = findRecursionDepth(fm); return (depth == null) ? RECURSION_DEPTH_DEFAULT : depth.intValue(); }
/** * Helper to find recursion depth recursively in our includes. */ private Number findRecursionDepth(FieldMetaData fm) { Number depth = (_depths == null) ? null : (Number) _depths.get(fm); if (depth != null) return depth; // check for superclass declaration of depth Number max = null; if (_meta != null && fm.getDeclaringMetaData() != _meta) { ClassMetaData sup = _meta.getPCSuperclassMetaData(); if (sup != null) { FetchGroup supFG = sup.getFetchGroup(_name); if (supFG != null) max = supFG.findRecursionDepth(fm); } } if (_includes == null) return max; // find largest included depth FetchGroup fg; for (Iterator itr = _includes.iterator(); itr.hasNext();) { fg = _meta.getFetchGroup((String) itr.next()); depth = (fg == null) ? null : fg.findRecursionDepth(fm); if (depth != null && (max == null || depth.intValue() > max.intValue())) max = depth; } return max; }
/** * Helper to find recursion depth recursively in our includes. */ private Number findRecursionDepth(FieldMetaData fm) { Number depth = (_depths == null) ? null : _depths.get(fm); if (depth != null) return depth; // check for superclass declaration of depth Number max = null; if (_meta != null && fm.getDeclaringMetaData() != _meta) { ClassMetaData sup = _meta.getPCSuperclassMetaData(); if (sup != null) { FetchGroup supFG = sup.getFetchGroup(_name); if (supFG != null) max = supFG.findRecursionDepth(fm); } } if (_includes == null) return max; // find largest included depth FetchGroup fg; for (String included : _includes) { fg = _meta.getFetchGroup(included); depth = (fg == null) ? null : fg.findRecursionDepth(fm); if (depth != null && (max == null || depth.intValue() > max.intValue())) max = depth; } return max; }
/** * Helper to find recursion depth recursively in our includes. */ private Number findRecursionDepth(FieldMetaData fm) { Number depth = (_depths == null) ? null : _depths.get(fm); if (depth != null) return depth; // check for superclass declaration of depth Number max = null; if (_meta != null && fm.getDeclaringMetaData() != _meta) { ClassMetaData sup = _meta.getPCSuperclassMetaData(); if (sup != null) { FetchGroup supFG = sup.getFetchGroup(_name); if (supFG != null) max = supFG.findRecursionDepth(fm); } } if (_includes == null) return max; // find largest included depth FetchGroup fg; for (String included : _includes) { fg = _meta.getFetchGroup(included); depth = (fg == null) ? null : fg.findRecursionDepth(fm); if (depth != null && (max == null || depth.intValue() > max.intValue())) max = depth; } return max; }
/** * Helper to find recursion depth recursively in our includes. */ private Number findRecursionDepth(FieldMetaData fm) { Number depth = (_depths == null) ? null : _depths.get(fm); if (depth != null) return depth; // check for superclass declaration of depth Number max = null; if (_meta != null && fm.getDeclaringMetaData() != _meta) { ClassMetaData sup = _meta.getPCSuperclassMetaData(); if (sup != null) { FetchGroup supFG = sup.getFetchGroup(_name); if (supFG != null) max = supFG.findRecursionDepth(fm); } } if (_includes == null) return max; // find largest included depth FetchGroup fg; for (String included : _includes) { fg = _meta.getFetchGroup(included); depth = (fg == null) ? null : fg.findRecursionDepth(fm); if (depth != null && (max == null || depth.intValue() > max.intValue())) max = depth; } return max; }
/** * Helper to find recursion depth recursively in our includes. */ private Number findRecursionDepth(FieldMetaData fm) { Number depth = (_depths == null) ? null : _depths.get(fm); if (depth != null) return depth; // check for superclass declaration of depth Number max = null; if (_meta != null && fm.getDeclaringMetaData() != _meta) { ClassMetaData sup = _meta.getPCSuperclassMetaData(); if (sup != null) { FetchGroup supFG = sup.getFetchGroup(_name); if (supFG != null) max = supFG.findRecursionDepth(fm); } } if (_includes == null) return max; // find largest included depth FetchGroup fg; for (String included : _includes) { fg = _meta.getFetchGroup(included); depth = (fg == null) ? null : fg.findRecursionDepth(fm); if (depth != null && (max == null || depth.intValue() > max.intValue())) max = depth; } return max; }