public abstract class OSequence extends Object
Modifier and Type | Class and Description |
---|---|
static class |
OSequence.CreateParams |
static class |
OSequence.SEQUENCE_TYPE |
Modifier and Type | Field and Description |
---|---|
static String |
CLASS_NAME |
protected static int |
DEF_MAX_RETRY |
static int |
DEFAULT_CACHE |
static int |
DEFAULT_INCREMENT |
static Long |
DEFAULT_LIMIT_VALUE |
static SequenceOrderType |
DEFAULT_ORDER_TYPE |
static boolean |
DEFAULT_RECYCLABLE_VALUE |
static long |
DEFAULT_START |
protected static int |
replicationProtocolVersion |
protected ThreadLocal<ODocument> |
tlDocument |
Modifier | Constructor and Description |
---|---|
protected |
OSequence() |
protected |
OSequence(ODocument iDocument) |
protected |
OSequence(ODocument iDocument,
OSequence.CreateParams params) |
Modifier and Type | Method and Description |
---|---|
protected <T> T |
callRetry(boolean reloadSequence,
Callable<T> callable,
String method) |
long |
current() |
protected abstract long |
currentWork() |
protected boolean |
getCrucialValueChanged() |
protected ODatabaseDocumentInternal |
getDatabase() |
ODocument |
getDocument() |
protected int |
getIncrement() |
protected Long |
getLimitValue() |
int |
getMaxRetry() |
String |
getName() |
protected SequenceOrderType |
getOrderType() |
boolean |
getRecyclable() |
static String |
getSequenceName(ODocument iDocument) |
abstract OSequence.SEQUENCE_TYPE |
getSequenceType() |
static OSequence.SEQUENCE_TYPE |
getSequenceType(ODocument document) |
protected long |
getStart() |
protected long |
getValue() |
protected static Long |
getValue(ODocument doc) |
static void |
initClass(OClassImpl sequenceClass) |
protected void |
initSequence(OSequence.CreateParams params) |
protected boolean |
isOnDistributted() |
long |
next() |
abstract long |
nextWork() |
void |
onUpdate(ODocument iDocument) |
protected void |
reloadSequence() |
long |
reset() |
abstract long |
resetWork() |
void |
save() |
void |
save(ODatabaseDocument database) |
protected void |
setCrucialValueChanged(boolean val) |
protected void |
setIncrement(int value) |
protected void |
setLimitValue(Long limitValue) |
void |
setMaxRetry(int maxRetry) |
OSequence |
setName(String name) |
protected void |
setOrderType(SequenceOrderType orderType) |
void |
setRecyclable(boolean recyclable) |
protected void |
setStart(long value) |
protected void |
setValue(long value) |
protected boolean |
shouldGoOverDistrtibute() |
boolean |
updateParams(OSequence.CreateParams params) |
public static final long DEFAULT_START
public static final int DEFAULT_INCREMENT
public static final int DEFAULT_CACHE
public static final Long DEFAULT_LIMIT_VALUE
public static final boolean DEFAULT_RECYCLABLE_VALUE
protected static final int DEF_MAX_RETRY
public static final String CLASS_NAME
protected ThreadLocal<ODocument> tlDocument
public static final SequenceOrderType DEFAULT_ORDER_TYPE
protected static int replicationProtocolVersion
protected OSequence()
protected OSequence(ODocument iDocument)
protected OSequence(ODocument iDocument, OSequence.CreateParams params)
protected void setCrucialValueChanged(boolean val)
protected boolean getCrucialValueChanged()
public void save()
public void save(ODatabaseDocument database)
public final ODocument getDocument()
protected final void initSequence(OSequence.CreateParams params)
protected boolean shouldGoOverDistrtibute()
public boolean updateParams(OSequence.CreateParams params) throws ODatabaseException
ODatabaseException
protected boolean isOnDistributted()
public void onUpdate(ODocument iDocument)
protected long getValue()
protected void setValue(long value)
protected int getIncrement()
protected void setLimitValue(Long limitValue)
protected Long getLimitValue()
protected void setOrderType(SequenceOrderType orderType)
protected SequenceOrderType getOrderType()
protected void setIncrement(int value)
protected long getStart()
protected void setStart(long value)
public int getMaxRetry()
public void setMaxRetry(int maxRetry)
public String getName()
public boolean getRecyclable()
public void setRecyclable(boolean recyclable)
protected final ODatabaseDocumentInternal getDatabase()
public static OSequence.SEQUENCE_TYPE getSequenceType(ODocument document)
public static void initClass(OClassImpl sequenceClass)
public long next() throws OSequenceLimitReachedException, ODatabaseException
public abstract long nextWork() throws OSequenceLimitReachedException
OSequenceLimitReachedException
public long current() throws ODatabaseException
ODatabaseException
protected abstract long currentWork()
public long reset() throws ODatabaseException
ODatabaseException
public abstract long resetWork()
public abstract OSequence.SEQUENCE_TYPE getSequenceType()
protected void reloadSequence()
Copyright © 2009–2020 OrientDB. All rights reserved.