[all packages] [package BR.unicamp.Guarana] [class hierarchy] [index]

public abstract class BR.unicamp.Guarana.OperationFactoryFilter

(source file: /home/lsd/oliva/src/java/guarana/kaffe/libraries/extensions/guarana/javalib/BR/unicamp/Guarana/OperationFactoryFilter.java)
java.lang.Object
   |
   +----BR.unicamp.Guarana.OperationFactory
           |
           +----BR.unicamp.Guarana.OperationFactoryFilter

The pure class interface.
public abstract class OperationFactoryFilter
  extends OperationFactory
An instance of this class delegates all methods to another OperationFactory. It is intended to be used as a base class for classes that prevent certain kinds of Operations from being created.


Constuctor Index

O OperationFactoryFilter(OperationFactory)
Creates an OperationFactory that delegates all requests to the given OperationFactory, except

Methods

O construct(Constructor, Object[], Operation)
Asks the OperationFactoryFilter specified in the constructor to create a Constructor
O getObject()
Should return the Object this OperationFactory creates Operations for
O invoke(Method, Object[], Operation)
Asks the OperationFactoryFilter specified in the constructor to create a Method invocation
O length(Operation)
Asks the OperationFactoryFilter specified in the constructor to create an Array length
O monitorEnter(Operation)
Asks the OperationFactoryFilter specified in the constructor to create a
O monitorExit(Operation)
Asks the OperationFactoryFilter specified in the constructor to create an
O nop()
Asks the OperationFactoryFilter specified in the constructor to create a do-nothing
O read(Field, Operation)
Asks the OperationFactoryFilter specified in the constructor to create a Field read
O readElement(int, Operation)
Asks the OperationFactoryFilter specified in the constructor to create an Array element read
O write(Field, Object, Operation)
Asks the OperationFactoryFilter specified in the constructor to create a Field write
O writeElement(int, Object, Operation)
Asks the OperationFactoryFilter specified in the constructor to create an Array element write

Constructors

O OperationFactoryFilter
public OperationFactoryFilter(OperationFactory factory);
Creates an OperationFactory that delegates all requests to the given OperationFactory, except the ones overridden by subclasses.

Parameters:
factory - the OperationFactory it delegates to.

Methods

O getObject
public final Object getObject();
Should return the Object this OperationFactory creates Operations for. For static Operations, it will be the target class.

Returns:
the target Object for this class.
Overrides:
getObject in class OperationFactory

O nop

public Operation nop()
  throws IllegalAccessException;
Asks the OperationFactoryFilter specified in the constructor to create a do-nothing Operation.

Returns:
the new Operation.
Throws:
IllegalAccessException -propagated.
Overrides:
nop in class OperationFactory

O invoke

public Operation invoke(Method method,
                        Object[] arguments,
                        Operation operation)
  throws IllegalArgumentException, IllegalAccessException;
Asks the OperationFactoryFilter specified in the constructor to create a Method invocation Operation.

Parameters:
method - the Method to be invoked.
arguments - the argument list to be passed to the Method.
operation - an Operation that should be replaced. If it is null, a non-replacement Operation is created.
Returns:
the new Operation.
Throws:
IllegalArgumentException -propagated.
IllegalAccessException -propagated.
Overrides:
invoke in class OperationFactory

O construct

public Operation construct(Constructor constructor,
                           Object[] arguments,
                           Operation operation)
  throws IllegalArgumentException, IllegalAccessException;
Asks the OperationFactoryFilter specified in the constructor to create a Constructor invocation Operation.

Parameters:
constructor - the Constructor to be invoked.
arguments - the argument list to be passed to the Constructor.
operation - an Operation that should be replaced. If it is null, a non-replacement Operation is created.
Returns:
the new Operation.
Throws:
IllegalArgumentException -propagated.
IllegalAccessException -propagated.
Overrides:
construct in class OperationFactory

O monitorEnter

public Operation monitorEnter(Operation operation)
  throws IllegalArgumentException, IllegalAccessException;
Asks the OperationFactoryFilter specified in the constructor to create a start-of-synchronization Operation.

Parameters:
operation - an Operation that should be replaced. If it is null, a non-replacement Operation is created.
Returns:
the new Operation.
Throws:
IllegalArgumentException -propagated.
IllegalAccessException -propagated.
Overrides:
monitorEnter in class OperationFactory

O monitorExit

public Operation monitorExit(Operation operation)
  throws IllegalArgumentException, IllegalAccessException;
Asks the OperationFactoryFilter specified in the constructor to create an end-of-synchronization Operation.

Parameters:
operation - an Operation that should be replaced. If it is null, a non-replacement Operation is created.
Returns:
the new Operation.
Throws:
IllegalArgumentException -propagated.
IllegalAccessException -propagated.
Overrides:
monitorExit in class OperationFactory

O read

public Operation read(Field field,
                      Operation operation)
  throws IllegalArgumentException, IllegalAccessException;
Asks the OperationFactoryFilter specified in the constructor to create a Field read Operation.

Parameters:
field - the Field whose value is to be obtained.
operation - an Operation that should be replaced. If it is null, a non-replacement Operation is created.
Returns:
the new Operation.
Throws:
IllegalArgumentException -propagated.
IllegalAccessException -propagated.
Overrides:
read in class OperationFactory

O write

public Operation write(Field field,
                       Object value,
                       Operation operation)
  throws IllegalArgumentException, IllegalAccessException;
Asks the OperationFactoryFilter specified in the constructor to create a Field write Operation.

Parameters:
field - the Field whose value is to be changed.
value - the value to be stored in the Field.
operation - an Operation that should be replaced. If it is null, a non-replacement Operation is created.
Returns:
the new Operation.
Throws:
IllegalArgumentException -propagated.
IllegalAccessException -propagated.
Overrides:
write in class OperationFactory

O length

public Operation length(Operation operation)
  throws IllegalArgumentException, IllegalAccessException;
Asks the OperationFactoryFilter specified in the constructor to create an Array length Operation.

Parameters:
operation - an Operation that should be replaced. If it is null, a non-replacement Operation is created.
Returns:
the new Operation.
Throws:
IllegalArgumentException -propagated.
IllegalAccessException -propagated.
Overrides:
length in class OperationFactory

O readElement

public Operation readElement(int element,
                             Operation operation)
  throws IllegalArgumentException, IllegalAccessException;
Asks the OperationFactoryFilter specified in the constructor to create an Array element read Operation.

Parameters:
element - the element whose value is to be obtained.
operation - an Operation that should be replaced. If it is null, a non-replacement Operation is created.
Returns:
the new Operation.
Throws:
IllegalArgumentException -propagated.
IllegalAccessException -propagated.
Overrides:
readElement in class OperationFactory

O writeElement

public Operation writeElement(int element,
                              Object value,
                              Operation operation)
  throws IllegalArgumentException, IllegalAccessException;
Asks the OperationFactoryFilter specified in the constructor to create an Array element write Operation.

Parameters:
element - the element whose value is to be changed.
value - the value to be stored in the element.
operation - an Operation that should be replaced. If it is null, a non-replacement Operation is created.
Returns:
the new Operation.
Throws:
IllegalArgumentException -propagated.
IllegalAccessException -propagated.
Overrides:
writeElement in class OperationFactory


[all packages] [package BR.unicamp.Guarana] [class hierarchy] [index]
BR.unicamp.Guarana.OperationFactoryFilter.html