public class ScanElement extends Object
org.gcube.searchservice.searchlibrary.resultset.ResultSet
file buffer and join related structs| Constructor and Description |
|---|
ScanElement(gr.uoa.di.madgik.grs.reader.RandomReader<gr.uoa.di.madgik.grs.record.Record> reader,
String keyFieldName,
BlockingQueue<JoinElement> queue,
Queue<EventEntry> events,
EventHandler eventHandler,
long timeout,
TimeUnit timeUnit,
Object synchThis,
short inputID,
BooleanHolder stopNotifier)
Create a new
ScanElement |
| Modifier and Type | Method and Description |
|---|---|
long |
getCounter()
Retrieves the counter for this
ScanElement |
EventHandler |
getEventHandler()
Retrieves the event handler used to propagate events
|
Queue<EventEntry> |
getEventQueue()
Retrieves the queue used to place events
|
short |
getInputID()
Retrieves the input id of this
ScanElement |
String |
getKey()
Retrieves the key
|
BlockingQueue<JoinElement> |
getQueue()
Retrieves the queue used to place records
|
gr.uoa.di.madgik.grs.reader.RandomReader<gr.uoa.di.madgik.grs.record.Record> |
getReader()
Retrieves the
RandomReader |
BooleanHolder |
getStopNotifier()
Retrieves the synch object used to notify this reader of consumption halt
|
Object |
getSynchThis()
Retrieves the object used to synchronize queue access
|
long |
getTimeout()
Retrieves the timeout used by the reader
|
TimeUnit |
getTimeUnit()
Retrieves the time unit of the timeout used by the reader
|
boolean |
hasFinished()
Checks if the current
ScanElement has finished authoring |
boolean |
isActive()
Checks if the current
ScanElement is active |
void |
setActive(boolean active)
Sets if the current
ScanElement is active |
void |
setCounter(long counter)
Sets the counter of this
ScanElement |
void |
setEventHandler(EventHandler eventHandler)
Sets the event handler used to propagate events
|
void |
setEventQueue(Queue<EventEntry> events)
Sets the queue used to place events
|
void |
setFinished(boolean finished)
Sets if the current
ScanElement has finished authoring |
void |
setInputID(short inputID)
Sets the input id of this
ScanElement |
void |
setKey(String keyFieldName)
Sets the key
|
void |
setQueue(BlockingQueue<JoinElement> queue)
Sets the queue used to place records
|
void |
setReader(gr.uoa.di.madgik.grs.reader.RandomReader<gr.uoa.di.madgik.grs.record.Record> reader)
Sets the
RandomReader |
void |
setSynchThis(Object synchThis)
Sets the object used to synchronize queue access
|
void |
setTimeout(long timeout)
Sets the timeout used by the reader
|
void |
setTimeUnit(TimeUnit timeUnit)
Sets the time unit of the timeout used by the reader
|
public ScanElement(gr.uoa.di.madgik.grs.reader.RandomReader<gr.uoa.di.madgik.grs.record.Record> reader,
String keyFieldName,
BlockingQueue<JoinElement> queue,
Queue<EventEntry> events,
EventHandler eventHandler,
long timeout,
TimeUnit timeUnit,
Object synchThis,
short inputID,
BooleanHolder stopNotifier)
ScanElementreader - Reader of the inputkeyFieldName - The name of the Field containing the key based on which the join is performedqueue - The queue to place extacted recordsevents - The queue used to propagate eventseventHandler - The event handler which is used to propagate eventstimeout - The timeout that will be used by the RandomReadertimeUnit - The time unit of the timeout that will be usedfileBuf - The file buffer to usesynchThis - Used for queue synchronizationinputID - Used to separate the various ScanElement instancespublic long getCounter()
ScanElementpublic void setCounter(long counter)
ScanElementcounter - The counterpublic short getInputID()
ScanElementpublic void setInputID(short inputID)
ScanElementinputID - The input idpublic boolean isActive()
ScanElement is activetrue if it is, false otherwisepublic void setActive(boolean active)
ScanElement is activeactive - true if it is, false otherwisepublic boolean hasFinished()
ScanElement has finished authoringpublic void setFinished(boolean finished)
ScanElement has finished authoringfinished - true if is has, false otherwisepublic gr.uoa.di.madgik.grs.reader.RandomReader<gr.uoa.di.madgik.grs.record.Record> getReader()
RandomReaderpublic void setReader(gr.uoa.di.madgik.grs.reader.RandomReader<gr.uoa.di.madgik.grs.record.Record> reader)
RandomReaderreader - The readerpublic String getKey()
public void setKey(String keyFieldName)
keyFieldName - The name of the Field containing the keypublic BlockingQueue<JoinElement> getQueue()
public void setQueue(BlockingQueue<JoinElement> queue)
queue - The queuepublic Queue<EventEntry> getEventQueue()
public void setEventQueue(Queue<EventEntry> events)
events - The queuepublic Object getSynchThis()
public EventHandler getEventHandler()
public void setEventHandler(EventHandler eventHandler)
eventHandler - The event handlerpublic void setSynchThis(Object synchThis)
synchThis - The object to usepublic BooleanHolder getStopNotifier()
public long getTimeout()
public void setTimeout(long timeout)
timeout - the timeoutpublic TimeUnit getTimeUnit()
public void setTimeUnit(TimeUnit timeUnit)
timeUnit - the unit of the timeoutCopyright © 2017. All Rights Reserved.