Example usage for org.apache.commons.pool MethodCall setReturned

List of usage examples for org.apache.commons.pool MethodCall setReturned

Introduction

In this page you can find the example usage for org.apache.commons.pool MethodCall setReturned.

Prototype

public void setReturned(final Object returned) 

Source Link

Usage

From source file:edu.illinois.enforcemop.examples.apache.pool.MethodCallPoolableObjectFactory.java

public Object makeObject() throws Exception {
    final MethodCall call = new MethodCall("makeObject");
    methodCalls.add(call);//  w ww  . j  a  v a2 s  .  com
    int count = this.count++;
    if (makeObjectFail) {
        throw new PrivateException("makeObject");
    }
    final Integer obj = new Integer(count);
    call.setReturned(obj);
    return obj;
}