def getMetricPath(self):
        # If we don't have a host name, assume it's just the fourth+ part of the
        # metric path
        if self.host is None:
            path = self.path.split('.')[3:]
            return '.'.join(path)

        prefix = '.'.join([self.getPathPrefix(), self.host,
                           self.getCollectorPath()])

        offset = len(prefix) + 1
        return self.path[offset:]
Returns the code object for this BUILD file.
dataset/ETHPy150Open python-diamond/Diamond/src/diamond/metric.py/Metric.getMetricPath--crossover with--dataset/ETHPy150Open pantsbuild/pants/src/python/pants/base/build_file.py/BuildFile.code