Package org.apache.bsf

Examples of org.apache.bsf.BSFManager.terminate()


            result.setFailure(true);
            result.setError(true);
            result.setFailureMessage(e.toString());
        } finally {
            if(mgr != null) {
                mgr.terminate();
            }
        }
        return result;
    }
}
View Full Code Here


            processFileOrScript(mgr);
        } catch (BSFException e) {
            log.warn("Problem in BSF script "+e);
        } finally {
            if (mgr != null) {
                mgr.terminate();
            }
        }
    }
}
View Full Code Here

                return result;
            }
            mgr.declareBean("SampleResult", response, SampleResult.class);
            mgr.declareBean("AssertionResult", result, AssertionResult.class);
            processFileOrScript(mgr);
            mgr.terminate();
            result.setError(false);
        } catch (BSFException e) {
            log.warn("Problem in BSF script "+e);
            result.setError(true);
            result.setFailureMessage(e.toString());
View Full Code Here

            IOUtils.closeQuietly(is);
// Will be done by mgr.terminate() anyway
//          if (bsfEngine != null) {
//              bsfEngine.terminate();
//          }
            mgr.terminate();
        }

        return res;
    }
}
View Full Code Here

            processFileOrScript(mgr);
        } catch (BSFException e) {
            log.warn("Problem in BSF script "+e);
        } finally {
            if (mgr != null) {
                mgr.terminate();
            }
        }
    }

    @Override
View Full Code Here

        bsf.eval("jruby", "(java)", 1, 1, "at_exit { @result =  \"#{x} and #{$x} in an at_exit block\" }");
        Object ret = bsf.eval("jruby", "(java)", 1, 1, "@lvar = \"x = #{x}\";return @gvar, @lvar");
        List<String> expResult = Arrays.asList("$x = GVar", "x = LVar");
        assertEquals(expResult, ret);
        logger1.info(ret.toString());
        bsf.terminate();
    }

}
View Full Code Here

   
    public void discardFromPool(Object object)
    {
        BSFManager manager = (BSFManager)object;
       
        manager.terminate();
    }

}
View Full Code Here

   
    public void discardFromPool(Object object)
    {
        BSFManager manager = (BSFManager)object;
       
        manager.terminate();
    }

}
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.