org.apache.manifoldcf.crawler.interfaces
Interface IJobDescription

All Known Implementing Classes:
JobDescription

public interface IJobDescription

This is a paper object describing a job. Each job in lcf has: - an identifier; - a description; - a repository connection; - one of a number of scheduling options: starting every n hours/days/weeks/months, on specific dates, or "continuous" (which basically establishes a priority queue based on modification frequency); - "seeds" (or starting points), which are the places that scanning begins. Also remember that since incremental deletion must occur on a job-by-job basis, the scanning data also records the job that performed the scan, so that each job can rescan previous ingested data, and delete documents that have been removed.


Field Summary
static java.lang.String _rcsid
           
static int HOPCOUNT_ACCURATE
           
static int HOPCOUNT_NEVERDELETE
           
static int HOPCOUNT_NODELETE
           
static int START_DISABLE
           
static int START_WINDOWBEGIN
           
static int START_WINDOWINSIDE
           
static int TYPE_CONTINUOUS
           
static int TYPE_SPECIFIED
           
 
Method Summary
 void addHopCountFilter(java.lang.String linkType, java.lang.Long maxHops)
          Add a hopcount filter to the job.
 void addScheduleRecord(ScheduleRecord record)
          Add a record.
 void clearHopCountFilters()
          Clear the set of hopcount filters for the job.
 void clearScheduleRecords()
          Clear all the scheduling records.
 void deleteScheduleRecord(int index)
          Delete a specified schedule record.
 java.lang.String getConnectionName()
          Get the connection name.
 java.lang.String getDescription()
          Get the description.
 java.lang.Long getExpiration()
          Get the expiration time, in milliseconds.
 java.util.Map getHopCountFilters()
          Get the set of hopcount filters the job has defined.
 int getHopcountMode()
          Get the hopcount mode.
 java.lang.Long getID()
          Get the id.
 java.lang.Long getInterval()
          Get the rescheduling interval, in milliseconds.
 boolean getIsNew()
          Get isnew.
 java.lang.String getOutputConnectionName()
          Get the output connection name.
 OutputSpecification getOutputSpecification()
          Get the output specification (which can be modified).
 int getPriority()
          Get the job priority.
 java.lang.Long getReseedInterval()
          Get the reseeding interval, in milliseconds.
 ScheduleRecord getScheduleRecord(int index)
          Get a specified schedule record.
 int getScheduleRecordCount()
          Get the number of schedule records.
 DocumentSpecification getSpecification()
          Get the document specification (which can be modified).
 int getStartMethod()
          Get the job's start method.
 int getType()
          Get the job type.
 void setConnectionName(java.lang.String connectionName)
          Set the connection name.
 void setDescription(java.lang.String description)
          Set the description.
 void setExpiration(java.lang.Long time)
          Set the expiration time, in milliseconds.
 void setHopcountMode(int mode)
          Set the hopcount mode.
 void setInterval(java.lang.Long interval)
          Set the rescheduling interval, in milliseconds, or null if forever.
 void setOutputConnectionName(java.lang.String connectionName)
          Set the output connection name.
 void setPriority(int priority)
          Set the job priority.
 void setReseedInterval(java.lang.Long interval)
          Set the reseeding interval, in milliseconds.
 void setStartMethod(int startMethod)
          Set the job's start method.
 void setType(int type)
          Set the job type.
 

Field Detail

_rcsid

static final java.lang.String _rcsid
See Also:
Constant Field Values

TYPE_CONTINUOUS

static final int TYPE_CONTINUOUS
See Also:
Constant Field Values

TYPE_SPECIFIED

static final int TYPE_SPECIFIED
See Also:
Constant Field Values

START_WINDOWBEGIN

static final int START_WINDOWBEGIN
See Also:
Constant Field Values

START_WINDOWINSIDE

static final int START_WINDOWINSIDE
See Also:
Constant Field Values

START_DISABLE

static final int START_DISABLE
See Also:
Constant Field Values

HOPCOUNT_ACCURATE

static final int HOPCOUNT_ACCURATE
See Also:
Constant Field Values

HOPCOUNT_NODELETE

static final int HOPCOUNT_NODELETE
See Also:
Constant Field Values

HOPCOUNT_NEVERDELETE

static final int HOPCOUNT_NEVERDELETE
See Also:
Constant Field Values
Method Detail

getIsNew

boolean getIsNew()
Get isnew.

Returns:
true if the object is new.

getID

java.lang.Long getID()
Get the id.

Returns:
the id.

setDescription

void setDescription(java.lang.String description)
Set the description.

Parameters:
description - is the description.

getDescription

java.lang.String getDescription()
Get the description.

Returns:
the description

setConnectionName

void setConnectionName(java.lang.String connectionName)
Set the connection name.

Parameters:
connectionName - is the connection name.

getConnectionName

java.lang.String getConnectionName()
Get the connection name.

Returns:
the connection name.

setOutputConnectionName

void setOutputConnectionName(java.lang.String connectionName)
Set the output connection name.

Parameters:
connectionName - is the output connection name.

getOutputConnectionName

java.lang.String getOutputConnectionName()
Get the output connection name.

Returns:
the output connection name.

setType

void setType(int type)
Set the job type.

Parameters:
type - is the type (as an integer).

getType

int getType()
Get the job type.

Returns:
the type (as an integer).

setStartMethod

void setStartMethod(int startMethod)
Set the job's start method.

Parameters:
startMethod - is the start description.

getStartMethod

int getStartMethod()
Get the job's start method.

Returns:
the start method.

clearScheduleRecords

void clearScheduleRecords()
Clear all the scheduling records.


addScheduleRecord

void addScheduleRecord(ScheduleRecord record)
Add a record.

Parameters:
record - is the record to add.

getScheduleRecordCount

int getScheduleRecordCount()
Get the number of schedule records.

Returns:
the count.

getScheduleRecord

ScheduleRecord getScheduleRecord(int index)
Get a specified schedule record.

Parameters:
index - is the record number.
Returns:
the record.

deleteScheduleRecord

void deleteScheduleRecord(int index)
Delete a specified schedule record.

Parameters:
index - is the record number.

setInterval

void setInterval(java.lang.Long interval)
Set the rescheduling interval, in milliseconds, or null if forever.

Parameters:
interval - is the default interval.

getInterval

java.lang.Long getInterval()
Get the rescheduling interval, in milliseconds.

Returns:
the default interval, or null if forever.

setExpiration

void setExpiration(java.lang.Long time)
Set the expiration time, in milliseconds.

Parameters:
time - is the maximum expiration time of a document, in milliseconds, or null if none.

getExpiration

java.lang.Long getExpiration()
Get the expiration time, in milliseconds.

Returns:
the maximum expiration time of a document, or null if none.

setReseedInterval

void setReseedInterval(java.lang.Long interval)
Set the reseeding interval, in milliseconds.

Parameters:
interval - is the interval, or null for infinite.

getReseedInterval

java.lang.Long getReseedInterval()
Get the reseeding interval, in milliseconds.

Returns:
the interval, or null if infinite.

getOutputSpecification

OutputSpecification getOutputSpecification()
Get the output specification (which can be modified).

Returns:
the specification.

getSpecification

DocumentSpecification getSpecification()
Get the document specification (which can be modified).

Returns:
the specification.

setPriority

void setPriority(int priority)
Set the job priority. This is a simple integer between 1 and 10, where 1 is the highest priority.

Parameters:
priority - is the priority.

getPriority

int getPriority()
Get the job priority.

Returns:
the priority (a number between 1 and 10).

getHopCountFilters

java.util.Map getHopCountFilters()
Get the set of hopcount filters the job has defined.

Returns:
the set as a map, keyed by Strings and containing Longs.

clearHopCountFilters

void clearHopCountFilters()
Clear the set of hopcount filters for the job.


addHopCountFilter

void addHopCountFilter(java.lang.String linkType,
                       java.lang.Long maxHops)
Add a hopcount filter to the job.

Parameters:
linkType - is the type of link the filter applies to.
maxHops - is the maximum hop count. Use null to remove a filter.

getHopcountMode

int getHopcountMode()
Get the hopcount mode.


setHopcountMode

void setHopcountMode(int mode)
Set the hopcount mode.