com.vinculumtech.carrierwave.manager
Class Delete

java.lang.Object
  extended bycom.vinculumtech.carrierwave.manager.Delete

public final class Delete
extends java.lang.Object

The Delete class is the root of all deletion functions initiated via CarrierWave and its client API. It is simply a convenience over the PersistenceRoot class.

Version:
$Id: //depot/carrierwave/src/server/com/vinculumtech/carrierwave/manager/Delete.java#17 $

Method Summary
static void deleteAllImageablesFor(java.util.List icons)
          Deletes all Imageable instances referenced by the given List of Icon instances.
This method will ignore Icon instances that reference dependent objects, unlike the deleteObjectFor method.
protected static void deleteImageable(Icon icon)
           
static void deleteImageableFor(Icon icon)
          Delete the Imageable instance referenced by the given Icon instance.
This method will fail if the given Icon instance refers to a dependent object.
Note this method cannot dereference a dependent object by default, as lists are not guaranteed to be ordered and there would be no guarantee the object was removed.
Note that some persistence implementations do guarantee ordering, in such cases the property carrierwave.factory.always_delegate_to_persistence should be true.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

deleteAllImageablesFor

public static final void deleteAllImageablesFor(java.util.List icons)
                                         throws GraphDeleteException,
                                                GraphException
Deletes all Imageable instances referenced by the given List of Icon instances.
This method will ignore Icon instances that reference dependent objects, unlike the deleteObjectFor method.

Parameters:
icons -
Throws:
GraphException
GraphDeleteException

deleteImageableFor

public static final void deleteImageableFor(Icon icon)
                                     throws GraphDeleteException,
                                            GraphException
Delete the Imageable instance referenced by the given Icon instance.
This method will fail if the given Icon instance refers to a dependent object.
Note this method cannot dereference a dependent object by default, as lists are not guaranteed to be ordered and there would be no guarantee the object was removed.
Note that some persistence implementations do guarantee ordering, in such cases the property carrierwave.factory.always_delegate_to_persistence should be true.

Parameters:
icon -
Throws:
GraphException
GraphDeleteException

deleteImageable

protected static final void deleteImageable(Icon icon)
                                     throws GraphException
Throws:
GraphException


Copyright (C) 2002 Vinculum Technologies, Inc. All Rights Reserved.