public double getDepth() throws WikiApiException {
        if (depth < 0) {    // has not been initialized
            if (rootPathMap != null) {
                this.depth = getDepthFromRootPathMap();
                logger.info("Getting depth from RootPathMap: " + this.depth);

            }
            else {
                depth = computeDepth();
                logger.info("Computing depth of the hierarchy: " + this.depth);
            }
        }
        return depth;
    }
public double getDepth ( ) throws WikiApiException { if ( depth < 0 ) { if ( rootPathMap != null ) { this . depth = getDepthFromRootPathMap ( ) ; logger . info ( "Getting depth from RootPathMap: " + this . depth ) ; } else { depth = computeDepth ( ) ; logger . info ( "Computing depth of the hierarchy: " + this . depth ) ; } } return depth ; }
This parameter is already set in the constructor as it is needed for computation of relatedness values.
Therefore its computation does not trigger setGraphParameters (it is too slow), even if the depth is implicitly determined there, too.
@return The depth of the category graph, i.e. the maximum path length starting with the root node.
@throws WikiApiException Thrown if errors occurred.