/** * Returns the string representation of the data identifier. * * @return string representation */ public String toString() { return identifier.toString(); }
private static DataIdentifier getIdentifier(String fileName) { return new DataIdentifier( fileName.substring(fileName.lastIndexOf("/") + 1)); }
public boolean equals(Object obj) { if (!(obj instanceof BLOBInDataStore) || obj == null) { return false; } BLOBInDataStore other = (BLOBInDataStore) obj; return store == other.store && identifier.equals(other.identifier); }
/** * Returns the hash code of the data identifier. * * @return hash code */ public int hashCode() { return identifier.hashCode(); } }
/** * Returns the hash code of the data identifier. * * @return hash code */ public int hashCode() { return identifier.hashCode(); }
/** * Returns the string representation of the data identifier. * * @return string representation */ public String toString() { return identifier.toString(); }
@Nullable @Override public DataIdentifier apply(@Nullable String id) { return new DataIdentifier(id); } }), backend.getAllIdentifiers());
public boolean equals(Object obj) { if (!(obj instanceof BLOBInDataStore) || obj == null) { return false; } BLOBInDataStore other = (BLOBInDataStore) obj; return store == other.store && identifier.equals(other.identifier); }
/** * Returns the hash code of the data identifier. * * @return hash code */ public int hashCode() { return identifier.hashCode(); }
/** * Returns the string representation of the data identifier. * * @return string representation */ public String toString() { return identifier.toString(); }
private DataIdentifier generateSafeRandomIdentifier() { return new DataIdentifier( String.format("%s-%d", UUID.randomUUID().toString(), Instant.now().toEpochMilli() ) ); }
/** * Checks if the given object is a data record with the same identifier * as this one. * * @param object other object * @return <code>true</code> if the other object is a data record and has * the same identifier as this one, <code>false</code> otherwise */ public boolean equals(Object object) { return (object instanceof DataRecord) && identifier.equals(((DataRecord) object).getIdentifier()); }
/** * Returns the hash code of the data identifier. * * @return hash code */ public int hashCode() { return identifier.hashCode(); } }
/** * Returns the string representation of the data identifier. * * @return string representation */ public String toString() { return identifier.toString(); }
private DataIdentifier generateSafeRandomIdentifier() { return new DataIdentifier( String.format("%s-%d", UUID.randomUUID().toString(), Instant.now().toEpochMilli() ) ); }
/** * Checks if the given object is a data record with the same identifier * as this one. * * @param object other object * @return <code>true</code> if the other object is a data record and has * the same identifier as this one, <code>false</code> otherwise */ public boolean equals(Object object) { return (object instanceof DataRecord) && identifier.equals(((DataRecord) object).getIdentifier()); }
/** * Returns the hash code of the data identifier. * * @return hash code */ public int hashCode() { return identifier.hashCode(); } }
/** * Returns the string representation of the data identifier. * * @return string representation */ public String toString() { return identifier.toString(); }
@Override public DataRecord getRecordFromReference(String reference) throws DataStoreException { //Override the getRecordFromReference so that reference handling does not //trigger a call to FS if (reference != null) { int colon = reference.indexOf(':'); if (colon != -1) { return getRecordIfStored(new DataIdentifier(reference.substring(0, colon))); } } return null; }
/** * Checks if the given object is a data record with the same identifier * as this one. * * @param object other object * @return <code>true</code> if the other object is a data record and has * the same identifier as this one, <code>false</code> otherwise */ public boolean equals(Object object) { return (object instanceof DataRecord) && identifier.equals(((DataRecord) object).getIdentifier()); }