/** * INTERNAL: */ public void onConnect() { super.onConnect(); initialize(); }
public int getPreallocationSize() { if ((size != 0) || (getDefaultSequence() == null)) { return size; } else { return getDefaultSequence().getPreallocationSize(); } }
/** * INTERNAL: * This method is called when Sequencing object is created. * It's a chance to do initialization. */ public void onConnect() { qualifier = getDefaultSequence().getQualifier(); }
public boolean equals(Object obj) { if (obj instanceof QuerySequence && super.equals(obj)) { QuerySequence other = (QuerySequence)obj; return (getSelectQuery() == other.getSelectQuery()) && (getUpdateQuery() == other.getUpdateQuery()) && (shouldAcquireValueAfterInsert() == other.shouldAcquireValueAfterInsert()) && (shouldUseTransaction() == other.shouldUseTransaction()) && (shouldSkipUpdate() == other.shouldSkipUpdate()) && (shouldSelectBeforeUpdate() == other.shouldSelectBeforeUpdate()); } else { return false; } }
/** * INTERNAL: */ @Override public void onDisconnect() { this.delegateSequence = null; setShouldAcquireValueAfterInsert(false); setShouldUseTransaction(false); super.onDisconnect(); } }
/** * PUBLIC: * Indicates that Sequence is connected. */ public boolean isConnected() { return getDefaultSequence().isConnected(); }
public int getInitialValue() { if ((initialValue != 0) || (getDefaultSequence() == null)) { return initialValue; } else { return getDefaultSequence().getInitialValue(); } }
/** * INTERNAL: */ public void onDisconnect() { clear(); super.onDisconnect(); }
/** * INTERNAL: * Indicates whether several sequencing values should be acquired at a time * and be kept by TopLink. This in only possible in case sequencing numbers should * be acquired before insert (shouldAcquireValueAfterInsert()==false). * In default implementation, it is true for table sequencing and native * sequencing on Oracle platform, false for native sequencing on other platforms. */ public boolean shouldUsePreallocation() { return getDefaultSequence().shouldUsePreallocation(); }
/** * INTERNAL: * Indicates whether sequencing value should be acquired after INSERT. * Note that preallocation could be used only in case sequencing values * should be acquired before insert (this method returns false). * In default implementation, it is true for table sequencing and native * sequencing on Oracle platform, false for native sequencing on other platforms. */ public boolean shouldAcquireValueAfterInsert() { return getDefaultSequence().shouldAcquireValueAfterInsert(); }
public boolean equals(Object obj) { if (obj instanceof QuerySequence && super.equals(obj)) { QuerySequence other = (QuerySequence)obj; return (getSelectQuery() == other.getSelectQuery()) && (getUpdateQuery() == other.getUpdateQuery()) && (shouldAcquireValueAfterInsert() == other.shouldAcquireValueAfterInsert()) && (shouldUseTransaction() == other.shouldUseTransaction()) && (shouldSkipUpdate() == other.shouldSkipUpdate()) && (shouldSelectBeforeUpdate() == other.shouldSelectBeforeUpdate()); } else { return false; } }
/** * INTERNAL: */ public void onConnect() { super.onConnect(); initialize(); }
public int getPreallocationSize() { if ((size != 0) || (getDefaultSequence() == null)) { return size; } else { return getDefaultSequence().getPreallocationSize(); } }
/** * INTERNAL: * This method is called when Sequencing object is created. * It's a chance to do initialization. */ public void onConnect() { qualifier = getDefaultSequence().getQualifier(); }
/** * PUBLIC: * Indicates that Sequence is connected. */ public boolean isConnected() { return getDefaultSequence().isConnected(); }
public int getInitialValue() { if ((initialValue != 0) || (getDefaultSequence() == null)) { return initialValue; } else { return getDefaultSequence().getInitialValue(); } }
/** * INTERNAL: */ public void onDisconnect() { clear(); super.onDisconnect(); }
public boolean equals(Object obj) { if (obj instanceof QuerySequence && super.equals(obj)) { QuerySequence other = (QuerySequence)obj; return (getSelectQuery() == other.getSelectQuery()) && (getUpdateQuery() == other.getUpdateQuery()) && (shouldAcquireValueAfterInsert() == other.shouldAcquireValueAfterInsert()) && (shouldUseTransaction() == other.shouldUseTransaction()) && (shouldSkipUpdate() == other.shouldSkipUpdate()) && (shouldSelectBeforeUpdate() == other.shouldSelectBeforeUpdate()); } else { return false; } }
/** * INTERNAL: */ public void onConnect() { super.onConnect(); initialize(); }
public int getPreallocationSize() { if ((size != 0) || (getDefaultSequence() == null)) { return size; } else { return getDefaultSequence().getPreallocationSize(); } }