Skip to content

Commit

Permalink
Removed a unused method.
Browse files Browse the repository at this point in the history
  • Loading branch information
taojing2002 committed Jun 26, 2024
1 parent ad2dd13 commit b193762
Showing 1 changed file with 0 additions and 29 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -80,35 +80,6 @@ public static Identifier getPid(Identifier identifier)
return pid;
}

/**
* Check if the given identifier is a PID or a SID
*
* @param identifier
* @return true if the identifier is a SID, false if a PID
* @throws NotFound
* @throws ServiceFailure
* @throws NotImplemented
* @throws NotAuthorized
* @throws InvalidToken
* @throws MarshallingException
* @throws IOException
* @throws IllegalAccessException
* @throws InstantiationException
*/
public static boolean isSeriesId(Identifier identifier)
throws InvalidToken, NotAuthorized, NotImplemented, ServiceFailure, NotFound,
InstantiationException, IllegalAccessException, IOException, MarshallingException {

// if we have system metadata available via HZ map, then it's a PID
org.dataone.service.types.v1.SystemMetadata systemMetadata = ObjectManager.getInstance()
.getSystemMetadata(identifier.getValue());
if (systemMetadata != null) {
return false;
}

// okay, it's a SID
return true;

}

}

0 comments on commit b193762

Please sign in to comment.