Class OPlaceholder
java.lang.Object
com.orientechnologies.orient.core.db.record.OPlaceholder
- All Implemented Interfaces:
OIdentifiable,OStreamable,Comparable<OIdentifiable>,Comparator<OIdentifiable>
Base interface for identifiable objects. This abstraction is required to use ORID and ORecord in
many points.
- Author:
- Luca Garulli (l.garulli--(at)--orientdb.com)
-
Constructor Summary
ConstructorsConstructorDescriptionEmpty constructor used by serializationOPlaceholder(ORecordId rid, int version) OPlaceholder(ORecord iRecord) -
Method Summary
Modifier and TypeMethodDescriptionintcompare(OIdentifiable o1, OIdentifiable o2) intbooleanvoidfromStream(DataInput in) Returns the record identity.<T extends ORecord>
TReturns the record instance.intinthashCode()booleanisLocked()voidlock(boolean iExclusive) UseODatabase.lock(ORID)instead.voidtoStream(DataOutput out) toString()voidunlock()UseODatabase.unlock(ORID)instead.Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface java.util.Comparator
reversed, thenComparing, thenComparing, thenComparing, thenComparingDouble, thenComparingInt, thenComparingLong
-
Constructor Details
-
OPlaceholder
public OPlaceholder()Empty constructor used by serialization -
OPlaceholder
-
OPlaceholder
-
-
Method Details
-
getIdentity
Description copied from interface:OIdentifiableReturns the record identity.- Specified by:
getIdentityin interfaceOIdentifiable- Returns:
- ORID instance
-
getRecord
Description copied from interface:OIdentifiableReturns the record instance.- Specified by:
getRecordin interfaceOIdentifiable- Returns:
- ORecord instance
-
equals
- Specified by:
equalsin interfaceComparator<OIdentifiable>- Overrides:
equalsin classObject
-
hashCode
public int hashCode() -
compareTo
- Specified by:
compareToin interfaceComparable<OIdentifiable>
-
compare
- Specified by:
comparein interfaceComparator<OIdentifiable>
-
getVersion
public int getVersion() -
toString
-
toStream
- Specified by:
toStreamin interfaceOStreamable- Throws:
IOException
-
fromStream
- Specified by:
fromStreamin interfaceOStreamable- Throws:
IOException
-
lock
public void lock(boolean iExclusive) Description copied from interface:OIdentifiableUseODatabase.lock(ORID)instead.- Specified by:
lockin interfaceOIdentifiable
-
isLocked
public boolean isLocked()- Specified by:
isLockedin interfaceOIdentifiable
-
lockingStrategy
- Specified by:
lockingStrategyin interfaceOIdentifiable
-
unlock
public void unlock()Description copied from interface:OIdentifiableUseODatabase.unlock(ORID)instead.- Specified by:
unlockin interfaceOIdentifiable
-