PIRL

PIRL.Conductor
Class Processing_Changes

java.lang.Object
  extended by PIRL.Conductor.Processing_Changes

public class Processing_Changes
extends Object

Processing_Changes contains information provided by a Conductor about changes in its processing conditions.

Version:
1.13
Author:
Bradford Castalia - UA/PIRL
See Also:
Conductor, Processing_Event

Field Summary
static String ID
          Class identification name with source code version and date.
static String MASKED_PASSWORD
          The value to set for all configuration parameters named "Password" (case insensitive).
 
Constructor Summary
Processing_Changes()
          Construct Processing_Changes containing no changes.
 
Method Summary
 Configuration Configuration()
          Get the changed Configuration.
 Processing_Changes Configuration(Configuration configuration)
          Set the changed Configuration.
 Processing_Changes Configuration(Parameter parameters)
          Set the changed Configuration from a Parameter.
 String Error_Condition()
          Get an error condition report.
 Processing_Changes Error_Condition(String error_condition)
          Set an error condition report.
 boolean Exiting()
          Test if the Conductor is exiting.
 Processing_Changes Exiting(boolean state)
          Set if the Conductor is exiting.
 Vector<String> Procedure_Record()
          Get the changed procedure record.
 Processing_Changes Procedure_Record(Vector<String> procedure_record)
          Set the changed prcedure record.
 boolean Procedures_Changed()
          Test if the procedure records have changed.
 Processing_Changes Procedures_Changed(boolean changed)
          Set if the procedure records have changed.
 int Processing_State()
          Get the processing state.
 Processing_Changes Processing_State(int processing_state)
          Set the processing state.
 int Sequential_Failures()
          Get the changed sequential failures limit.
 Processing_Changes Sequential_Failures(int failure_count)
          Set the changed sequential failures limit.
 Vector<String> Source_Record()
          Get the changed source record.
 Processing_Changes Source_Record(Vector<String> source_record)
          Set the changed source record.
 boolean Sources_Refreshed()
          Test if the source records cache was refreshed with new records.
 Processing_Changes Sources_Refreshed(boolean refreshed)
          Set if the source records cache was refreshed with new records.
 String toString()
          Get a description of this Processing_Changes state.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

ID

public static final String ID
Class identification name with source code version and date.

See Also:
Constant Field Values

MASKED_PASSWORD

public static final String MASKED_PASSWORD
The value to set for all configuration parameters named "Password" (case insensitive).

See Also:
Constant Field Values
Constructor Detail

Processing_Changes

public Processing_Changes()
Construct Processing_Changes containing no changes.

Method Detail

Configuration

public Configuration Configuration()
Get the changed Configuration.

Returns:
A copy of the changed Configuration. This will be null if the Configuration is unchanged.
See Also:
Configuration(Configuration)

Configuration

public Processing_Changes Configuration(Configuration configuration)
                                 throws Configuration_Exception
Set the changed Configuration.

If the Configuration is non-null it is copied into this Processing_Changes. The copy is set to be case insensitive and all parameters named "PASSWORD" (case insensitive) have their values reset to MASKED_PASSWORD.

Parameters:
configuration - A Configuration. May be null.
Returns:
This Processing_Changes.
Throws:
Configuration_Exception
See Also:
Configuration(Parameter), Configuration()

Configuration

public Processing_Changes Configuration(Parameter parameters)
                                 throws Configuration_Exception
Set the changed Configuration from a Parameter.

If the Parameter is non-null it is copied into the Configuration of this Processing_Changes. The copy is set to be case insensitive and all parameters named "PASSWORD" (case insensitive) have their values reset to MASKED_PASSWORD.

Parameters:
parameters - A Parameter. May be null.
Returns:
This Processing_Changes.
Throws:
Configuration_Exception
See Also:
Configuration(Configuration), Configuration()

Processing_State

public int Processing_State()
Get the processing state.

The expected Conductor processing state values are:

1 - Conductor.RUNNING
Source records are being processing.
2 - Conductor.POLLING
No source records are currently available for processing; the Conductor is polling for new source records to process.
-1 - Conductor.WAITING
The Conductor is waiting to be told to being processing.
-2 - Conductor.HALTED
A problem condition caused the Conductor to stop processing. The problem may be the result of the maximum number of sequential source records processing procedure failures having occured, a database access failure, or some other system error.
0 - Unchanged
The processing state has not changed.

Returns:
A Conductor processing state value, or zero the state is unchanged.
See Also:
Processing_State(int)

Processing_State

public Processing_Changes Processing_State(int processing_state)
Set the processing state.

Parameters:
processing_state - A Conductor processing state value, or zero the state is unchanged.
Returns:
This Processing_Changes.
See Also:
Processing_State()

Source_Record

public Vector<String> Source_Record()
Get the changed source record.

Returns:
A Vector containing the changed source record, or null if the record is unchanged.
See Also:
Source_Record(Vector)

Source_Record

public Processing_Changes Source_Record(Vector<String> source_record)
Set the changed source record.

If the record is non-null it is copied into this Processing_Changes.

Parameters:
source_record - A Vector containing the changed source record, or null if the record is unchanged.
Returns:
This Processing_Changes.
See Also:
Source_Record()

Sources_Refreshed

public boolean Sources_Refreshed()
Test if the source records cache was refreshed with new records.

Returns:
true if the source records cache was refreshed with new records; false if the cache is unchanged.
See Also:
Sources_Refreshed(boolean)

Sources_Refreshed

public Processing_Changes Sources_Refreshed(boolean refreshed)
Set if the source records cache was refreshed with new records.

Parameters:
refreshed - true if the source records cache was refreshed with new records; false if the cache is unchanged.
Returns:
This Processing_Changes.
See Also:
Sources_Refreshed()

Procedure_Record

public Vector<String> Procedure_Record()
Get the changed procedure record.

Returns:
A Vector containing the changed procedure record, or null if the record is unchanged.
See Also:
Procedure_Record(Vector)

Procedure_Record

public Processing_Changes Procedure_Record(Vector<String> procedure_record)
Set the changed prcedure record.

If the record is non-null it is copied into this Processing_Changes.

Parameters:
procedure_record - A Vector containing the changed procedure record, or null if the record is unchanged.
Returns:
This Processing_Changes.
See Also:
Procedure_Record()

Procedures_Changed

public boolean Procedures_Changed()
Test if the procedure records have changed.

Returns:
true if the procedure records were replaced with new records; false if the records are unchanged.
See Also:
Procedures_Changed(boolean)

Procedures_Changed

public Processing_Changes Procedures_Changed(boolean changed)
Set if the procedure records have changed.

Parameters:
changed - true if the procedure records were replaced with new records; false if the records are unchanged.
Returns:
This Processing_Changes.
See Also:
Procedures_Changed()

Sequential_Failures

public int Sequential_Failures()
Get the changed sequential failures limit.

Returns:
The sequential failures limit. This will be -1 if the limit is unchanged.
See Also:
Sequential_Failures(int)

Sequential_Failures

public Processing_Changes Sequential_Failures(int failure_count)
Set the changed sequential failures limit.

Returns:
The sequential failures limit. A negative value means the limit is unchanged.
See Also:
Sequential_Failures()

Error_Condition

public String Error_Condition()
Get an error condition report.

Returns:
A String describing the error condition. This will be null if no error condition occurred.
See Also:
Error_Condition(String)

Error_Condition

public Processing_Changes Error_Condition(String error_condition)
Set an error condition report.

Returns:
A String describing the error condition. If null no error condition occurred.
See Also:
Error_Condition()

Exiting

public boolean Exiting()
Test if the Conductor is exiting.

Returns:
true if the Conductor is exiting; false if the Conductor is still running.
See Also:
Exiting(boolean)

Exiting

public Processing_Changes Exiting(boolean state)
Set if the Conductor is exiting.

Returns:
true if the Conductor is exiting; false if the Conductor is still running.
See Also:
Exiting()

toString

public String toString()
Get a description of this Processing_Changes state.

The Processing_Changes object is described by its ID followed by the name and values of each state variable.

The Configuration description will occupy many lines and may include at the end warnings from the PVL Lister about illegal syntax in values; this is to be expected and is harmless. If the Configuration is malformed its description will begin with an empty line followed by a description of the problem.

Overrides:
toString in class Object
Returns:
A multi-line String describing the state of this Processing_Changes object.

PIRL

Copyright (C) \ 2003-2009 Bradford Castalia, University of Arizona