org.sakaiproject.search.model
Interface SearchBuilderItem


public interface SearchBuilderItem

Represents an operation or state of a document in the search engine. This Object is used as a communication and persistance mechanism between the changes made to entities and the thread processing the index updates

Author:
ieb

Field Summary
static Integer ACTION_ADD
          Action ADD the record to the search engine, if the doc ID is set, then remove first, if not set, check its not there.
static Integer ACTION_DELETE
          Action DELETE the record from the search engine, once complete delete the record
static Integer ACTION_REBUILD
          The action REBUILD causes the indexer thread to rebuild the index from scratch, re-fetching all entities This should only ever appear on the master record
static Integer ACTION_REFRESH
          The action REFRESH causes the indexer thread to refresh the search index from the current set of entities.
static Integer ACTION_UNKNOWN
          Action Unknown, usually because the record has just been created
static String[] actions
           
static String GLOBAL_CONTEXT
           
static String GLOBAL_MASTER
           
static String INDEX_MASTER
          A master record is used to override the indexer thread operation and avoid hide updates to the database in the request cycle.
static Integer ITEM
           
static Integer ITEM_GLOBAL_MASTER
           
static Integer ITEM_SITE_MASTER
           
static String[] scope
           
static String SITE_MASTER_FORMAT
           
static String SITE_MASTER_PATTERN
           
static Integer STATE_COMPLETED
          Operation completed
static Integer STATE_FAILED
           
static Integer STATE_LOCKED
          Locked for processing
static Integer STATE_PENDING
          Operation pending
static Integer STATE_PENDING_2
           
static Integer STATE_UNKNOWN
          Unknown state
static String[] states
           
 
Method Summary
 String getContext()
          The context of the index item
 String getId()
           
 Integer getItemscope()
           
 int getLock()
          The lock id on this object
 String getName()
          Name of the resource in the search index
 Integer getSearchaction()
          The action being performed
 Integer getSearchstate()
          The state of the record
 Date getVersion()
          The last update to the record
 void input(DataInputStream dataInputStream)
           
 boolean isLocked()
           
 void output(DataOutputStream dataOutputStream)
           
 void setContext(String context)
          The context of the index item
 void setId(String id)
           
 void setItemscope(Integer itemscope)
           
 void setName(String name)
          The name of the resource in the search index
 void setSearchaction(Integer searchaction)
          The action being performed
 void setSearchstate(Integer searchstate)
          The state of the record
 void setVersion(Date version)
          The last update to the record
 

Field Detail

INDEX_MASTER

static final String INDEX_MASTER
A master record is used to override the indexer thread operation and avoid hide updates to the database in the request cycle.

See Also:
Constant Field Values

ACTION_UNKNOWN

static final Integer ACTION_UNKNOWN
Action Unknown, usually because the record has just been created


ACTION_ADD

static final Integer ACTION_ADD
Action ADD the record to the search engine, if the doc ID is set, then remove first, if not set, check its not there.


ACTION_DELETE

static final Integer ACTION_DELETE
Action DELETE the record from the search engine, once complete delete the record


ACTION_REBUILD

static final Integer ACTION_REBUILD
The action REBUILD causes the indexer thread to rebuild the index from scratch, re-fetching all entities This should only ever appear on the master record


ACTION_REFRESH

static final Integer ACTION_REFRESH
The action REFRESH causes the indexer thread to refresh the search index from the current set of entities. If a Rebuild is in progress, the refresh will not override the rebuild


STATE_UNKNOWN

static final Integer STATE_UNKNOWN
Unknown state


STATE_PENDING

static final Integer STATE_PENDING
Operation pending


STATE_COMPLETED

static final Integer STATE_COMPLETED
Operation completed


STATE_PENDING_2

static final Integer STATE_PENDING_2

STATE_LOCKED

static final Integer STATE_LOCKED
Locked for processing


STATE_FAILED

static final Integer STATE_FAILED

ITEM

static final Integer ITEM

ITEM_GLOBAL_MASTER

static final Integer ITEM_GLOBAL_MASTER

ITEM_SITE_MASTER

static final Integer ITEM_SITE_MASTER

GLOBAL_CONTEXT

static final String GLOBAL_CONTEXT
See Also:
Constant Field Values

GLOBAL_MASTER

static final String GLOBAL_MASTER
See Also:
Constant Field Values

SITE_MASTER_FORMAT

static final String SITE_MASTER_FORMAT
See Also:
Constant Field Values

SITE_MASTER_PATTERN

static final String SITE_MASTER_PATTERN
See Also:
Constant Field Values

states

static final String[] states

actions

static final String[] actions

scope

static final String[] scope
Method Detail

getId

String getId()

setId

void setId(String id)

getName

String getName()
Name of the resource in the search index

Returns:

setName

void setName(String name)
The name of the resource in the search index

Parameters:
name -

getSearchaction

Integer getSearchaction()
The action being performed

Returns:

setSearchaction

void setSearchaction(Integer searchaction)
The action being performed

Parameters:
searchaction -

getSearchstate

Integer getSearchstate()
The state of the record

Returns:

setSearchstate

void setSearchstate(Integer searchstate)
The state of the record

Parameters:
searchstate -

getVersion

Date getVersion()
The last update to the record

Returns:

setVersion

void setVersion(Date version)
The last update to the record

Parameters:
version -

getContext

String getContext()
The context of the index item

Returns:

setContext

void setContext(String context)
The context of the index item

Parameters:
context -

getItemscope

Integer getItemscope()
Returns:
the itemscope

setItemscope

void setItemscope(Integer itemscope)
Parameters:
itemscope - the itemscope to set

output

void output(DataOutputStream dataOutputStream)
            throws IOException
Parameters:
dataOutputStream -
Throws:
IOException

input

void input(DataInputStream dataInputStream)
           throws IOException
Parameters:
dataInputStream -
Throws:
IOException

getLock

int getLock()
The lock id on this object

Returns:

isLocked

boolean isLocked()
Returns:


Copyright © 2003-2013 Sakai Project. All Rights Reserved.