code: public boolean handleFirstOrSecondLevel(ObjectName pName) {
          if (maxDepth == 1 && pathStack.size() == 0) {
              // Only add domain names with a dummy value if max depth is restricted to 1
              // But only when used without path
              infoMap.put(pName.getDomain(), 1);
              return true;
          } else if (maxDepth == 2 && pathStack.size() == 0) {
              // Add domain an object name into the map, final value is a dummy value
              JSONObject mBeansMap = getOrCreateJSONObject(infoMap, pName.getDomain());
              mBeansMap.put(getKeyPropertyString(pName),1);
              return true;
          }
          return false;
      }
docs: The first two levels of this map (tree) consist of the MBean's domain name and name properties, which are
  independent of an MBean's meta data. If the max depth given at construction time is less or equals than 2 (and
  no inner path into the map is given), then a client of this map does not need to query the MBeanServer for
  MBeanInfo meta data.
  <p></p>
  This method checks this condition and returns true if this is the case. As side effect it will update this
  map with the name part extracted from the given object name
  
  @param pName the objectname used for the first two levels
  @return true if the object name has been added.