|
From: <tr...@us...> - 2003-09-04 00:25:42
|
Update of /cvsroot/babeldoc/babeldoc/modules/core/src/com/babeldoc/core/journal/dummy
In directory sc8-pr-cvs1:/tmp/cvs-serv6124/src/com/babeldoc/core/journal/dummy
Added Files:
DummyJournal.java
Log Message:
Added a dummy journal - does not do anything with the journal logging
--- NEW FILE: DummyJournal.java ---
package com.babeldoc.core.journal.dummy;
import com.babeldoc.core.journal.*;
import com.babeldoc.core.journal.query.QueryTicket;
import com.babeldoc.core.journal.query.JournalQuery;
import com.babeldoc.core.option.IConfigInfo;
import com.babeldoc.core.pipeline.PipelineDocument;
import java.util.Collection;
import java.util.ArrayList;
/**
* A dummy journal - this journal does nothing
*
* @author bmcdonald
* @version 1.1
*/
public class DummyJournal
implements IJournal {
/** maintain the configuration information object */
private IConfigInfo info;
/**
* Get the configuration iformation for this class
*
* @return IConfigInfo object
*/
public IConfigInfo getInfo() {
if(info==null) {
info = new JournalConfigInfo() {
/**
* This method returns type specific options
*
* @return comments
*/
public Collection getTypeSpecificOptions() {
return new ArrayList();
}
/**
* Return description of this worker
*
* @return description
*/
public String getDescription() {
return "Dummy journal is a do-nothing jounal";
}
/**
* return the name
*
* @return
*/
public String getName() {
return null;
}
};
}
return info;
}
/**
* getChildrenTickets. Get all the tickets which are children of this ticket
*
* @param parent
*
* @return array of child tickets.
*/
public IJournalTicket[] getAllChildTickets(IJournalTicket parent)
throws JournalException {
return new IJournalTicket[0];
}
/**
* getJournalForTicket. Get all the ticketsteps for the ticket.
*
* @param ticket number
*
* @return array of querytickets
*/
public QueryTicket[] getAllTicketSteps(IJournalTicket ticket)
throws JournalException {
return new QueryTicket[0];
}
/**
* retrieve the document from the journal for this ticket, step.
*
* @param ticket - the ticket to replay
* @param step - the step to replay from
*
* @return
*
* @throws JournalException
*/
public PipelineDocument getDocumentAtTicketStep(IJournalTicket ticket,
int step) throws JournalException {
return null;
}
/**
* Get an existing ticket from the string identifier.
*
* @param identifier ;
*
* @return the created tracker ticket
*/
public IJournalTicket getTicket(String identifier) throws JournalException {
return null;
}
/**
* getChild tickets between the specified dates. Return up to the maxreturned
* number of results.
*
* @param jQuery journal query object
*
* @return the results.
*/
public QueryTicket[] getTickets(JournalQuery jQuery)
throws JournalException {
return new QueryTicket[0];
}
/**
* Get a ticket for tracking a document.
*
* @return the created tracker ticket
*/
public IJournalTicket dummyTicket() throws JournalException {
return null;
}
/**
* Get a ticket for tracking a document from a parent ticket.
*
* @param parentTicket the creating ticket
*
* @return the created tracker ticket
*/
public IJournalTicket forkTicket(IJournalTicket parentTicket)
throws JournalException {
return null;
}
/**
* Get a ticket for tracking a document.
*
* @return the created tracker ticket
*/
public IJournalTicket newTicket() throws JournalException {
return null;
}
/**
* Log a message into the log file
*
* @param ticket track the document
* @param stage log message at this pipeline stage
* @param message The message to log
* @throws JournalException
*/
public void logMessage(IJournalTicket ticket, String stage, String message)
throws JournalException {
}
/**
* Replay this ticket from the step
*
* @param ticket - the ticket to replay
* @param step - the step to replay from
*/
public void replayTicket(IJournalTicket ticket, int step)
throws JournalException {
}
/**
* Update a document associated with this ticket
*
* @param ticket - the ticket to replay
* @param document the document to update
* @param stage the pipeline stage resulting in this status change
*/
public void updateDocument(IJournalTicket ticket, PipelineDocument document,
String stage) throws JournalException {
}
/**
* Update the status of this ticket
*
* @param ticket - the ticket for this status
* @param status - the status of the ticket
* @param stage the pipeline stage resulting in this status change
*/
public void updateStatus(IJournalTicket ticket, IJournalStatus status,
String stage) throws JournalException {
}
}
|