i3.dragos.core.services.rules
Enum RuleCouplingMode

java.lang.Object
  extended by java.lang.Enum<RuleCouplingMode>
      extended by i3.dragos.core.services.rules.RuleCouplingMode
All Implemented Interfaces:
java.io.Serializable, java.lang.Comparable<RuleCouplingMode>

public enum RuleCouplingMode
extends java.lang.Enum<RuleCouplingMode>

The constants in this class describe the different coupling modes between an event, a transaction and the execution of an action.

Author:
Boris Boehlen <boehlen@cs.rwth-aachen.de>, Thorsten Hermes <thermes@i3.informatik.rwth-aachen.de>

Enum Constant Summary
DECOUPLED
          RuleAction is executed within a seperate transaction after the transaction which contained the operations that raised the event has been committed.
DEFERRED
          RuleAction is executed within the transaction after all operations, which belong to the transaction have been executed.
 
Method Summary
static RuleCouplingMode valueOf(java.lang.String name)
          Returns the enum constant of this type with the specified name.
static RuleCouplingMode[] values()
          Returns an array containing the constants of this enum type, in the order they are declared.
 
Methods inherited from class java.lang.Enum
clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Enum Constant Detail

DEFERRED

public static final RuleCouplingMode DEFERRED
RuleAction is executed within the transaction after all operations, which belong to the transaction have been executed. This implies that a rule can still prevent the transaction from being committed by setting the "rollback only" flag or by leaving the graph data in an inconsistent state that will be rejected by the checkers.


DECOUPLED

public static final RuleCouplingMode DECOUPLED
RuleAction is executed within a seperate transaction after the transaction which contained the operations that raised the event has been committed. If the RuleAction sets the "rollback only" flag on the transaction, the transaction will be rolled back, and the original modification or any other rules will not be affected. However, if the RuleAction leaves the graph data in an inconsistent state that is be rejected by the checkers, the usual TransactionException will be thrown.

Method Detail

values

public static RuleCouplingMode[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
for (RuleCouplingMode c : RuleCouplingMode.values())
    System.out.println(c);

Returns:
an array containing the constants of this enum type, in the order they are declared

valueOf

public static RuleCouplingMode valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)

Parameters:
name - the name of the enum constant to be returned.
Returns:
the enum constant with the specified name
Throws:
java.lang.IllegalArgumentException - if this enum type has no constant with the specified name
java.lang.NullPointerException - if the argument is null


Copyright © 2002-2008 RWTH Aachen, Department of Computer Science 3 (Software Engineering). All Rights Reserved.