Oracle NoSQL Database Examples
version 11gR2.2.0.26

schema
Class RunOperation

java.lang.Object
  extended by schema.RunOperation

abstract class RunOperation
extends Object

Utility class to run a KVStore operation and handle FaultExceptions according to this application's policies. The doOperation method is abstract and must be implemented by callers. doOperation is called by the run() method of this class.

This class is a placeholder for implementing application-specific exception handling policies. This implementation simply prints the exception details to System.err. In addition to performing other actions when an exception occurs, applications may wish to extend this mechanism to perform retries under certain conditions.

Note that OperationExecutionException is not handled by this class because it is a contingency exception that is expected to be handled by the operation itself (the doOperation method).


Constructor Summary
RunOperation()
           
 
Method Summary
(package private) abstract  void doOperation()
          Must be implemented to perform the operation.
(package private)  void run()
          Calls the doOperation method and handles exceptions as needed.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RunOperation

RunOperation()
Method Detail

doOperation

abstract void doOperation()
Must be implemented to perform the operation.


run

void run()
   throws FaultException
Calls the doOperation method and handles exceptions as needed.

Throws:
FaultException

Oracle NoSQL Database Examples
version 11gR2.2.0.26

Copyright (c) 2011, 2013 Oracle and/or its affiliates. All rights reserved.