new ClassCastException(), new Object[] {o});
}
if (owner != null)
{
StateManager stateManager = owner.jdoGetStateManager();
if (stateManager != null)
{
PersistenceManager pm = (PersistenceManager) stateManager.getPersistenceManagerInternal();
pm.acquireShareLock();
boolean modified = false;
try
{
pm.acquireFieldUpdateLock();
try
{
// Mark the field as dirty
stateManager.makeDirty(fieldName);
modified = super.add(o);
if (modified)
{
if (removed.remove(o) == false)
{
added.add(o);
}
stateManager.applyUpdates(fieldName, this);
}
return modified;
}
finally
{