public AvailableServiceBindingVO getAvailableServiceBindingVOWithName(String name, Database db) throws SystemException, Bug, Exception
{
String key = "" + name;
logger.info("key:" + key);
AvailableServiceBindingVO availableServiceBindingVO = (AvailableServiceBindingVO)CacheController.getCachedObject("availableServiceBindingCache", key);
if(availableServiceBindingVO != null)
{
logger.info("There was an cached availableServiceBindingVO:" + availableServiceBindingVO);
}
else
{
OQLQuery oql = db.getOQLQuery( "SELECT asb FROM org.infoglue.cms.entities.management.impl.simple.SmallAvailableServiceBindingImpl asb WHERE asb.name = $1");
oql.bind(name);
QueryResults results = oql.execute(Database.READONLY);
if (results.hasMore())
{
AvailableServiceBinding availableServiceBinding = (AvailableServiceBinding)results.next();
availableServiceBindingVO = availableServiceBinding.getValueObject();
logger.info("Found availableServiceBinding:" + availableServiceBindingVO.getName());
}
results.close();
oql.close();