code: public Set<String> getParents(String pid) throws MelcoeXacmlException {
          logger.debug("Obtaining parents for: {}", pid);
  
          Set<String> parentPIDs = new HashSet<String>();
          if (pid.equalsIgnoreCase(Constants.FEDORA_REPOSITORY_PID.uri)) {
              return parentPIDs;
          }
  
          query: for (String relationship : relationships) {
              logger.debug("relationship query: {}, {}", pid, relationship);
  
              Map<String, Set<String>> mapping;
              try {
                  mapping = getRelationships(pid, relationship);
              } catch (MelcoeXacmlException e) {
                  Throwable t = e.getCause();
                  // An object X, may legitimately declare a parent relation to
                  // another object, Y which does not exist. Therefore, we don't
                  // want to continue querying for Y's parents.
                  if (t != null && t instanceof ObjectNotInLowlevelStorageException) {
                      logger.debug("Parent, {}, not found.", pid);
                      break query;
                  } else {
                  // Unexpected error, so we throw back the original
                  throw e;
              }
              }
  
              Set<String> parents = mapping.get(relationship);
              if (parents != null) {
                  for (String parent : parents) {
                      PID parentPID = PID.getInstance(parent);
                      // we want the parents in demo:123 form, not info:fedora/demo:123
                      parentPIDs.add(parentPID.toString());
                      logger.debug("added parent {}", parentPID.toString());
                  }
              }
          }
          return parentPIDs;
      }
docs: /*
  (non-Javadoc)
  @see
  org.fcrepo.server.security.xacml.pdp.finder.support.RelationshipResolver#getParents(java.
  lang.String)