Primavera Integration API 7.0

com.primavera.integration.util
Class BODeleteHelper

java.lang.Object
  extended by com.primavera.integration.util.BODeleteHelper

public class BODeleteHelper
extends java.lang.Object

This helper class is used to delete multiple business objects from the database in the ideal order. Business objects are deleted in the opposite order from which they were added to this object, i.e., the last objects added will be the first objects deleted.


Constructor Summary
BODeleteHelper()
          Class constructor
 
Method Summary
 void add(BusinessObject bo)
          Adds an object to eventually be deleted from the database
 void add(BusinessObject[] bos)
          Adds multiple objects to eventually be deleted from the database
 void add(java.lang.String sBOType, ObjectId objId)
          Adds an ObjectId for a particular business object type to eventually be deleted from the database
 void add(java.lang.String sBOType, ObjectId[] objIds)
          Adds multiple ObjectIds for a particular business object type to eventually be deleted from the database
 void delete(Session session, java.lang.String sBOType)
          Deletes from the database all the business objects of a particular type that were added to this object.
 void deleteAll(Session session)
          Deletes from the database all the business objects that were added to this object
 void reset()
          Clears all the objects added without deleting any objects from the database.
 java.lang.String toString()
          Returns a string representation of the object, listing counts of object types currently contained.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

BODeleteHelper

public BODeleteHelper()
Class constructor

Method Detail

add

public void add(java.lang.String sBOType,
                ObjectId objId)
Adds an ObjectId for a particular business object type to eventually be deleted from the database

Parameters:
sBOType - the business object type
objId - the related ObjectId
Throws:
java.lang.IllegalArgumentException - if a parameter is null

add

public void add(java.lang.String sBOType,
                ObjectId[] objIds)
Adds multiple ObjectIds for a particular business object type to eventually be deleted from the database

Parameters:
sBOType - the business object type
objIds - the related ObjectIds
Throws:
java.lang.IllegalArgumentException - if a parameter is null

add

public void add(BusinessObject bo)
Adds an object to eventually be deleted from the database

Parameters:
bo - the business object

add

public void add(BusinessObject[] bos)
Adds multiple objects to eventually be deleted from the database

Parameters:
bos - the business objects

reset

public void reset()
Clears all the objects added without deleting any objects from the database.


toString

public java.lang.String toString()
Returns a string representation of the object, listing counts of object types currently contained.

Overrides:
toString in class java.lang.Object
Returns:
String a string representation of the object.

deleteAll

public void deleteAll(Session session)
Deletes from the database all the business objects that were added to this object

Parameters:
session - the Session object

delete

public void delete(Session session,
                   java.lang.String sBOType)
            throws ServerException,
                   NetworkException,
                   BusinessObjectException
Deletes from the database all the business objects of a particular type that were added to this object. Business objects are deleted in the opposite order from which they were added to this object, i.e., the last objects added will be the first

Parameters:
session - the Session object
sBOType - the business object type
Throws:
ServerException - if a problem occurred on the server-side
NetworkException - if a problem occurred in the network layer
BusinessObjectException - if the type is invalid or may not be deleted
java.lang.IllegalArgumentException - if a parameter is null

Primavera Integration API 7.0

Copyright © 2003, 2009, Oracle and/or its affiliates. All rights reserved.