code: public boolean matchesAtLeastThreeLevels(DependencyVersion version) {
          if (version == null) {
              return false;
          }
          if (Math.abs(this.versionParts.size() - version.versionParts.size()) >= 3) {
              return false;
          }
  
          final int max = (this.versionParts.size() < version.versionParts.size())
                  ? this.versionParts.size() : version.versionParts.size();
  
          boolean ret = true;
          for (int i = 0; i < max; i++) {
              final String thisVersion = this.versionParts.get(i);
              final String otherVersion = version.getVersionParts().get(i);
              if (i >= 3) {
                  if (thisVersion.compareToIgnoreCase(otherVersion) >= 0) {
                      ret = false;
                      break;
                  }
              } else if (!thisVersion.equals(otherVersion)) {
                  ret = false;
                  break;
              }
          }
  
          return ret;
      }
docs: Determines if the three most major major version parts are identical. For
  instances, if version 1.2.3.4 was compared to 1.2.3 this function would
  return true.
  
  @param version the version number to compare
  @return true if the first three major parts of the version are identical