public class BusinessObjectTool
extends java.lang.Object
Helper class to manipulate business objects in specific code
Modifier and Type | Class and Description |
---|---|
class |
BusinessObjectTool.ReturnMessage |
Constructor and Description |
---|
BusinessObjectTool(Grant grant,
java.lang.String objectName,
java.lang.String objectIntanceName)
Constructor
|
BusinessObjectTool(ObjectDB object)
Constructor
|
Modifier and Type | Method and Description |
---|---|
BusinessObjectTool.ReturnMessage |
create()
Helper method to process create save throwing exception in case of error
Forces row ID at objectField.DEFAULT_ROW_ID and calls save. |
BusinessObjectTool.ReturnMessage |
del()
Helper method to process deletion throwing exception in case of error (same as delete but for script usage)
|
BusinessObjectTool.ReturnMessage |
delete()
Helper method to process deletion throwing exception in case of error
|
void |
get(java.lang.String rowId)
Helper method to process row selection throwing exception in case of error
Same as select |
ObjectDB |
getObject() |
void |
log(java.lang.String method,
com.simplicite.util.exceptions.GenericException e)
Helper method to handle an Exception as a log entry (for code EXCEPTION)
|
BusinessObjectTool.ReturnMessage |
save()
Helper method to process save (create or update) throwing appropriate exception in case of error
|
java.util.Vector<java.lang.String[]> |
search()
Helper method to process search throwing exception in case of error
|
void |
select(java.lang.String rowId)
Helper method to process row selection throwing exception in case of error
Same as get. |
BusinessObjectTool.ReturnMessage |
update()
Helper method to process update save throwing exception in case of error
Same as save |
java.util.Vector<BusinessObjectTool.ReturnMessage> |
validate()
Helper method to process validation throwing exception in case of error(s)
|
java.util.Vector<BusinessObjectTool.ReturnMessage> |
validateAndCreate()
Helper method to process validation and create save throwing appropriate exception in case of error(s).
Forces row ID at objectField.DEFAULT_ROW_ID and calls validateAndSave. |
java.util.Vector<BusinessObjectTool.ReturnMessage> |
validateAndSave()
Helper method to process validation and save (create or update) throwing appropriate exception in case of error(s)
|
java.util.Vector<java.lang.String[]> |
validateAndSearch()
Helper method to process search validation and search throwing exception in case of error
|
java.util.Vector<BusinessObjectTool.ReturnMessage> |
validateAndUpdate()
Helper method to process validation and update save throwing appropriate exception in case of error(s)
Same as validateAndSave. |
public BusinessObjectTool(ObjectDB object)
Constructor
object
- Business objectpublic BusinessObjectTool(Grant grant, java.lang.String objectName, java.lang.String objectIntanceName)
Constructor
grant
- GrantobjectName
- Object nameobjectIntanceName
- Object instance namepublic ObjectDB getObject()
public void get(java.lang.String rowId) throws com.simplicite.util.exceptions.GetException
Helper method to process row selection throwing exception in case of error
Same as select
com.simplicite.util.exceptions.GetException
public void select(java.lang.String rowId) throws com.simplicite.util.exceptions.GetException
Helper method to process row selection throwing exception in case of error
Same as get.
com.simplicite.util.exceptions.GetException
public java.util.Vector<java.lang.String[]> validateAndSearch() throws com.simplicite.util.exceptions.ValidateSearchException, com.simplicite.util.exceptions.SearchException
Helper method to process search validation and search throwing exception in case of error
com.simplicite.util.exceptions.SearchException
com.simplicite.util.exceptions.ValidateSearchException
public java.util.Vector<java.lang.String[]> search() throws com.simplicite.util.exceptions.SearchException
Helper method to process search throwing exception in case of error
com.simplicite.util.exceptions.SearchException
public java.util.Vector<BusinessObjectTool.ReturnMessage> validate() throws com.simplicite.util.exceptions.ValidateException
Helper method to process validation throwing exception in case of error(s)
com.simplicite.util.exceptions.ValidateException
public BusinessObjectTool.ReturnMessage save() throws com.simplicite.util.exceptions.SaveException
Helper method to process save (create or update) throwing appropriate exception in case of error
com.simplicite.util.exceptions.CreateException
com.simplicite.util.exceptions.UpdateException
com.simplicite.util.exceptions.SaveException
public BusinessObjectTool.ReturnMessage create() throws com.simplicite.util.exceptions.CreateException
Helper method to process create save throwing exception in case of error
Forces row ID at objectField.DEFAULT_ROW_ID and calls save.
com.simplicite.util.exceptions.CreateException
public BusinessObjectTool.ReturnMessage update() throws com.simplicite.util.exceptions.UpdateException
Helper method to process update save throwing exception in case of error
Same as save
com.simplicite.util.exceptions.CreateException
com.simplicite.util.exceptions.UpdateException
public java.util.Vector<BusinessObjectTool.ReturnMessage> validateAndSave() throws com.simplicite.util.exceptions.ValidateException, com.simplicite.util.exceptions.SaveException
Helper method to process validation and save (create or update) throwing appropriate exception in case of error(s)
com.simplicite.util.exceptions.ValidateException
com.simplicite.util.exceptions.CreateException
com.simplicite.util.exceptions.UpdateException
com.simplicite.util.exceptions.SaveException
public java.util.Vector<BusinessObjectTool.ReturnMessage> validateAndCreate() throws com.simplicite.util.exceptions.ValidateException, com.simplicite.util.exceptions.CreateException
Helper method to process validation and create save throwing appropriate exception in case of error(s).
Forces row ID at objectField.DEFAULT_ROW_ID and calls validateAndSave.
com.simplicite.util.exceptions.ValidateException
com.simplicite.util.exceptions.CreateException
com.simplicite.util.exceptions.UpdateException
public java.util.Vector<BusinessObjectTool.ReturnMessage> validateAndUpdate() throws com.simplicite.util.exceptions.ValidateException, com.simplicite.util.exceptions.UpdateException
Helper method to process validation and update save throwing appropriate exception in case of error(s)
Same as validateAndSave.
com.simplicite.util.exceptions.ValidateException
com.simplicite.util.exceptions.CreateException
com.simplicite.util.exceptions.UpdateException
public BusinessObjectTool.ReturnMessage delete() throws com.simplicite.util.exceptions.DeleteException
Helper method to process deletion throwing exception in case of error
com.simplicite.util.exceptions.DeleteException
public final BusinessObjectTool.ReturnMessage del() throws com.simplicite.util.exceptions.DeleteException
Helper method to process deletion throwing exception in case of error (same as delete but for script usage)
com.simplicite.util.exceptions.DeleteException
public void log(java.lang.String method, com.simplicite.util.exceptions.GenericException e)
Helper method to handle an Exception as a log entry (for code EXCEPTION)
method
- Methode
- ExceptionCopyright (c)2006-2014 Simplicite Software. All Rights Reserved.