initial = new InitialContext();
environment = (Context) initial.lookup("java:comp/env");
}
catch (NamingException ex)
{
throw new XEJBException("Could not lookup environment.", ex);
}
try
{
blockSizeProperty = (Integer) environment.lookup("blockSize");
}
catch (NamingException ex)
{
throw new XEJBException("Could not lookup blockSize property.", ex);
}
blockSize = blockSizeProperty.intValue();
try
{
dataSource = (DataSource) environment.lookup("jdbc/dataSource");
}
catch (NamingException ex)
{
throw new XEJBException("Could not lookup data source.", ex);
}
if (keys == null) keys = new LinkedList();
}