code: public int subtreeDepth() throws UnsupportedOperationException {
          DNSName dnsName = null;
          try {
              dnsName = new DNSName(host);
          } catch (IOException ioe) {
              throw new UnsupportedOperationException(ioe.getMessage());
          }
          return dnsName.subtreeDepth();
      }
docs: Return subtree depth of this name for purposes of determining
  NameConstraints minimum and maximum bounds and for calculating
  path lengths in name subtrees.
  
  @returns distance of name from root
  @throws UnsupportedOperationException if not supported for this name type