/** * Remove the given previously dereferenced dependent object from the * cache. It is now referenced. */ void removeDereferencedDependent(StateManagerImpl sm) { lock(); try { boolean removed = false; if (_derefAdditions != null) removed = _derefAdditions.remove(sm); if (!removed && (_derefCache == null || !_derefCache.remove(sm))) throw new InvalidStateException(_loc.get("not-derefed", Exceptions.toString(sm.getManagedInstance()))). setFailedObject(sm.getManagedInstance()). setFatal(true); } finally { unlock(); } }
/** * Remove the given previously dereferenced dependent object from the * cache. It is now referenced. */ void removeDereferencedDependent(StateManagerImpl sm) { lock(); try { boolean removed = false; if (_derefAdditions != null) removed = _derefAdditions.remove(sm); if (!removed && (_derefCache == null || !_derefCache.remove(sm))) throw new InvalidStateException(_loc.get("not-derefed", Exceptions.toString(sm.getManagedInstance()))). setFailedObject(sm.getManagedInstance()). setFatal(true); } finally { unlock(); } }
/** * Remove the given previously dereferenced dependent object from the * cache. It is now referenced. */ void removeDereferencedDependent(StateManagerImpl sm) { lock(); try { boolean removed = false; if (_derefAdditions != null) removed = _derefAdditions.remove(sm); if (!removed && (_derefCache == null || !_derefCache.remove(sm))) throw new InvalidStateException(_loc.get("not-derefed", Exceptions.toString(sm.getManagedInstance()))). setFailedObject(sm.getManagedInstance()). setFatal(true); } finally { unlock(); } }
/** * Remove the given previously dereferenced dependent object from the * cache. It is now referenced. */ void removeDereferencedDependent(StateManagerImpl sm) { lock(); try { boolean removed = false; if (_derefAdditions != null) removed = _derefAdditions.remove(sm); if (!removed && (_derefCache == null || !_derefCache.remove(sm))) throw new InvalidStateException(_loc.get("not-derefed", Exceptions.toString(sm.getManagedInstance()))). setFailedObject(sm.getManagedInstance()). setFatal(true); } finally { unlock(); } }
/** * Remove the given previously dereferenced dependent object from the * cache. It is now referenced. */ void removeDereferencedDependent(StateManagerImpl sm) { lock(); try { boolean removed = false; if (_derefAdditions != null) removed = _derefAdditions.remove(sm); if (!removed && (_derefCache == null || !_derefCache.remove(sm))) throw new InvalidStateException(_loc.get("not-derefed", Exceptions.toString(sm.getManagedInstance()))). setFailedObject(sm.getManagedInstance()). setFatal(true); } finally { unlock(); } }
/** * Throw appropriate exception on attempt to flush an unmapped object. */ private static void throwFlushException(OpenJPAStateManager sm) { throw new InvalidStateException(_loc.get("flush-virtual", sm.getMetaData(), sm.getObjectId())). setFailedObject(sm.getManagedInstance()). setFatal(true); } }
/** * Throw appropriate exception on attempt to flush an unmapped object. */ private static void throwFlushException(OpenJPAStateManager sm) { throw new InvalidStateException(_loc.get("flush-virtual", sm.getMetaData(), sm.getObjectId())). setFailedObject(sm.getManagedInstance()). setFatal(true); } }
/** * Throw an inconsistency exception */ protected void throwException(OpenJPAStateManager sm, FieldMetaData fmd) { throw new InvalidStateException(_loc.get("inverse-consistency", fmd, sm.getId(), sm.getContext())).setFailedObject (sm.getManagedInstance()).setFatal(true); } }
/** * Throw appropriate exception on attempt to flush an unmapped object. */ private static void throwFlushException(OpenJPAStateManager sm) { throw new InvalidStateException(_loc.get("flush-virtual", sm.getMetaData(), sm.getObjectId())). setFailedObject(sm.getManagedInstance()). setFatal(true); } }
/** * Throw an inconsistency exception */ protected void throwException(OpenJPAStateManager sm, FieldMetaData fmd) { throw new InvalidStateException(_loc.get("inverse-consistency", fmd, sm.getId(), sm.getContext())).setFailedObject (sm.getManagedInstance()).setFatal(true); } }
/** * Throw an inconsistency exception */ protected void throwException(OpenJPAStateManager sm, FieldMetaData fmd) { throw new InvalidStateException(_loc.get("inverse-consistency", fmd, sm.getId(), sm.getContext())).setFailedObject (sm.getManagedInstance()).setFatal(true); } }
private void makeCallback(LifecycleEvent ev) { int eventType = ev.getType(); if (_callbacks[eventType] == null) return; Object src = ev.getSource(); for (LifecycleCallbacks callback : _callbacks[eventType]) { try { callback.makeCallback(src, ev.getRelated(), eventType); } catch (Throwable t) { if (t instanceof InvocationTargetException) t = t.getCause(); if (t instanceof RuntimeException) throw (RuntimeException) t; throw new CallbackException(_loc.get("system-listener-err", src)).setCause(t).setFatal(true); } } }
/** * Throw an inconsistency exception */ protected void throwException(OpenJPAStateManager sm, FieldMetaData fmd) { throw new InvalidStateException(_loc.get("inverse-consistency", fmd, sm.getId(), sm.getContext())).setFailedObject (sm.getManagedInstance()).setFatal(true); } }
/** * Throw appropriate exception on attempt to flush an unmapped object. */ private static void throwFlushException(OpenJPAStateManager sm) { throw new InvalidStateException(_loc.get("flush-virtual", sm.getMetaData(), sm.getObjectId())). setFailedObject(sm.getManagedInstance()). setFatal(true); } }
/** * Throw an inconsistency exception */ protected void throwException(OpenJPAStateManager sm, FieldMetaData fmd) { throw new InvalidStateException(_loc.get("inverse-consistency", fmd, sm.getId(), sm.getContext())).setFailedObject (sm.getManagedInstance()).setFatal(true); } }
/** * Throw appropriate exception on attempt to flush an unmapped object. */ private static void throwFlushException(OpenJPAStateManager sm) { throw new InvalidStateException(_loc.get("flush-virtual", sm.getMetaData(), sm.getObjectId())). setFailedObject(sm.getManagedInstance()). setFatal(true); } }
private void makeCallback(LifecycleEvent ev) { int eventType = ev.getType(); if (_callbacks[eventType] == null) return; Object src = ev.getSource(); for (LifecycleCallbacks callback : _callbacks[eventType]) { try { callback.makeCallback(src, ev.getRelated(), eventType); } catch (Throwable t) { if (t instanceof InvocationTargetException) t = t.getCause(); if (t instanceof RuntimeException) throw (RuntimeException) t; throw new CallbackException(_loc.get("system-listener-err", src)).setCause(t).setFatal(true); } } }
private void makeCallback(LifecycleEvent ev) { int eventType = ev.getType(); if (_callbacks[eventType] == null) return; Object src = ev.getSource(); for (LifecycleCallbacks callback : _callbacks[eventType]) { try { callback.makeCallback(src, ev.getRelated(), eventType); } catch (Throwable t) { if (t instanceof InvocationTargetException) t = t.getCause(); if (t instanceof RuntimeException) throw (RuntimeException) t; throw new CallbackException(_loc.get("system-listener-err", src)).setCause(t).setFatal(true); } } }
private void makeCallback(LifecycleEvent ev) { int eventType = ev.getType(); if (_callbacks[eventType] == null) return; Object src = ev.getSource(); for (LifecycleCallbacks callback : _callbacks[eventType]) { try { callback.makeCallback(src, ev.getRelated(), eventType); } catch (Throwable t) { if (t instanceof InvocationTargetException) t = t.getCause(); if (t instanceof RuntimeException) throw (RuntimeException) t; throw new CallbackException(_loc.get("system-listener-err", src)).setCause(t).setFatal(true); } } }
private void makeCallback(LifecycleEvent ev) { int eventType = ev.getType(); if (_callbacks[eventType] == null) return; Object src = ev.getSource(); for (LifecycleCallbacks callback : _callbacks[eventType]) { try { callback.makeCallback(src, ev.getRelated(), eventType); } catch (Throwable t) { if (t instanceof InvocationTargetException) t = t.getCause(); if (t instanceof RuntimeException) throw (RuntimeException) t; throw new CallbackException(_loc.get("system-listener-err", src)).setCause(t).setFatal(true); } } }