public class BlockingQueueCollection extends AbstractQueueCollection
Title: Dataspace framework
Description: Blocking queue collection implementation.
Copyright: Copyright (c) 2011
Company: StreamScape Technologies
AbstractQueueCollection.KeyValue
SchemaObject.ConstraintTypes, SchemaObject.Deferable, SchemaObject.Nullability, SchemaObject.ParameterModes, SchemaObject.ReferentialAction, SchemaObject.ViewCheckModes
ACTOR, ASPECTS, ASSERTION, CATALOG, CHARSET, COLLATION, COLLECTION, COLUMN, CONNECTION_FACTORY, CONSTRAINT, CURSOR, DOMAIN, emptyArray, EVENT_PROTOTYPE, FACETS, FILE_DESCRIPTOR, FULL_TEXT_INDEX, FUNCTION, GRANTEE, INDEX, JOB, LABEL, PARAMETER, PROCEDURE, REFERENCE_LINK, REPLICA, REPLICATION_SOURCE, ROUTINE, SCHEMA, SEMANTIC_TYPE, SEQUENCE, SERVER, SPECIFIC_ROUTINE, SUBQUERY, TABLE, TIMER, TRANSIENT_VAR, TRANSITION, TRIGGER, TYPE, VARIABLE, VIEW, WRAPPER
Constructor and Description |
---|
BlockingQueueCollection(DataspaceStore store,
NameManager.ObjectName name,
com.streamscape.ds.core.MemoryModel memoryModel) |
Modifier and Type | Method and Description |
---|---|
void |
compile(com.streamscape.ds.session.Session session,
SchemaObject parentObject) |
void |
compileInternalStatements(com.streamscape.ds.session.Session session) |
java.util.List |
drain(com.streamscape.ds.session.Session session,
int maxElements,
java.lang.String selector) |
int |
drainTo(com.streamscape.ds.session.Session session,
BlockingQueueCollection c,
int maxElements) |
int |
drainTo(com.streamscape.ds.session.Session session,
BlockingQueueCollection c,
int maxElements,
java.lang.String selector) |
int |
drainTo(com.streamscape.ds.session.Session session,
java.lang.String nodeName,
java.lang.String componentType,
java.lang.String componentName,
java.lang.String collectionName,
int maxElements,
java.lang.String selector) |
com.streamscape.ds.result.Result |
getCollectionProperties(com.streamscape.ds.session.Session session) |
java.lang.String |
getCollectionSQL(boolean forReplication) |
com.streamscape.ds.types.Type |
getDataType() |
com.streamscape.sef.dii.AccessibleObjectProxy |
getProxy() |
AbstractIterator |
iterator(com.streamscape.ds.session.Session session) |
boolean |
offer(com.streamscape.ds.session.Session session,
java.lang.Object o,
long timeout,
java.util.concurrent.TimeUnit unit)
Inserts the specified element into this queue, waiting if necessary
up to the specified wait time for space to become available.
|
java.lang.Object |
poll(com.streamscape.ds.session.Session session,
long timeout,
java.util.concurrent.TimeUnit unit)
Retrieves and removes the head of this queue, waiting
if necessary up to the specified wait time if no elements are
present on this queue.
|
java.lang.Object |
poll(com.streamscape.ds.session.Session session,
long timeout,
java.util.concurrent.TimeUnit unit,
boolean isLast) |
java.lang.Object |
pollLast(com.streamscape.ds.session.Session session,
long timeout,
java.util.concurrent.TimeUnit unit) |
void |
put(com.streamscape.ds.session.Session session,
java.lang.Object o)
Adds the specified element to this queue, waiting if necessary for
space to become available.
|
int |
remainingCapacity(com.streamscape.ds.session.Session session) |
void |
setConstraint(com.streamscape.ds.types.Type dataType) |
java.lang.Object |
take(com.streamscape.ds.session.Session session)
Retrieves and removes the head of this queue, waiting
if no elements are present on this queue.
|
java.lang.Object |
take(com.streamscape.ds.session.Session session,
boolean isLast) |
java.lang.Object |
takeLast(com.streamscape.ds.session.Session session) |
add, addAll, addAll, addRow, addRows, clear, contains, containsAll, containsAll, drainFromQueue, drainRows, drainRowsTo, drainRowsTo, drainToMap, drainToQueue, drainToRowSet, drainToTable, element, element, elementLast, fromMap, fromQueue, fromRowSet, fromTable, getMaxDepth, getName, getQueueName, getSchema, getTableName, isEmpty, offer, peek, peek, peekLast, poll, poll, pollLast, remove, remove, remove, removeAll, removeAll, removeLast, retainAll, retainAll, size, toArray, toArray, toMap, toMapCollection, toQueue, toQueueCollection, toRowSet, toTable
aggregateStateHolder, checkResultIsData, checkResultNotError, checkUpdateCountIs, close, count, destroy, dropReplicationSource, exposeCollectionState, getBaseTable, getCatalogName, getChangeTimestamp, getCollectionComponents, getCollectionName, getCollectionName, getCollectionType, getCollectionType, getCollectionTypeName, getCollectionTypeNameCamelCase, getComponents, getDataspace, getEventForTrigger, getEvents, getMemoryModel, getMemoryModel, getObjectName, getObjectType, getOwner, getReferences, getReplicationSource, getSchemaName, getSQL, getSQL, getSQL, getSQL, getSQLForReplication, getStateHolder, getTriggerEventId, getWindowTriggers, isReplicated, isTriggerEventAutogenerated, listTriggers, listTriggers, open, resetBaseTable, setReplicationSource, unwrapEvent, updateBaseTable, validate, validateTypes, wrapEvent
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
aggregateObjectStateHolder, getSQLInSchema, recompileObject
public BlockingQueueCollection(DataspaceStore store, NameManager.ObjectName name, com.streamscape.ds.core.MemoryModel memoryModel)
public void setConstraint(com.streamscape.ds.types.Type dataType)
public com.streamscape.ds.types.Type getDataType()
public void compile(com.streamscape.ds.session.Session session, SchemaObject parentObject)
compile
in interface SchemaObject
compile
in class AbstractQueueCollection
public void compileInternalStatements(com.streamscape.ds.session.Session session)
compileInternalStatements
in interface Collection
compileInternalStatements
in class AbstractQueueCollection
public java.lang.String getCollectionSQL(boolean forReplication)
public com.streamscape.ds.result.Result getCollectionProperties(com.streamscape.ds.session.Session session)
getCollectionProperties
in interface Collection
getCollectionProperties
in class AbstractCollection
public com.streamscape.sef.dii.AccessibleObjectProxy getProxy()
getProxy
in interface com.streamscape.sef.dii.AccessibleObject
getProxy
in class AbstractQueueCollection
public boolean offer(com.streamscape.ds.session.Session session, java.lang.Object o, long timeout, java.util.concurrent.TimeUnit unit) throws java.lang.InterruptedException
o
- the element to addtimeout
- how long to wait before giving up, in units of
unitunit
- a TimeUnit determining how to interpret the
timeout parameterjava.lang.InterruptedException
- if interrupted while waiting.java.lang.NullPointerException
- if the specified element is null.public java.lang.Object poll(com.streamscape.ds.session.Session session, long timeout, java.util.concurrent.TimeUnit unit) throws java.lang.InterruptedException
timeout
- how long to wait before giving up, in units of
unitunit
- a TimeUnit determining how to interpret the
timeout parameterjava.lang.InterruptedException
- if interrupted while waiting.public java.lang.Object pollLast(com.streamscape.ds.session.Session session, long timeout, java.util.concurrent.TimeUnit unit) throws java.lang.InterruptedException
java.lang.InterruptedException
public java.lang.Object poll(com.streamscape.ds.session.Session session, long timeout, java.util.concurrent.TimeUnit unit, boolean isLast) throws java.lang.InterruptedException
java.lang.InterruptedException
public java.lang.Object take(com.streamscape.ds.session.Session session) throws java.lang.InterruptedException
java.lang.InterruptedException
- if interrupted while waiting.public java.lang.Object takeLast(com.streamscape.ds.session.Session session) throws java.lang.InterruptedException
java.lang.InterruptedException
public java.lang.Object take(com.streamscape.ds.session.Session session, boolean isLast) throws java.lang.InterruptedException
java.lang.InterruptedException
public void put(com.streamscape.ds.session.Session session, java.lang.Object o) throws java.lang.InterruptedException
o
- the element to addjava.lang.InterruptedException
- if interrupted while waiting.java.lang.NullPointerException
- if the specified element is null.public int remainingCapacity(com.streamscape.ds.session.Session session)
public int drainTo(com.streamscape.ds.session.Session session, BlockingQueueCollection c, int maxElements)
public int drainTo(com.streamscape.ds.session.Session session, BlockingQueueCollection c, int maxElements, java.lang.String selector)
public int drainTo(com.streamscape.ds.session.Session session, java.lang.String nodeName, java.lang.String componentType, java.lang.String componentName, java.lang.String collectionName, int maxElements, java.lang.String selector)
public java.util.List drain(com.streamscape.ds.session.Session session, int maxElements, java.lang.String selector)
public AbstractIterator iterator(com.streamscape.ds.session.Session session)
iterator
in class AbstractQueueCollection
Copyright © 2015-2024 StreamScape Technologies. All rights reserved.