Compiere 3.1

org.compiere.framework
Class PO

java.lang.Object
  extended by org.compiere.framework.PO
All Implemented Interfaces:
Serializable, Cloneable, Comparator<PO>, Evaluatee
Direct Known Subclasses:
DocActionTemplate, MyModelExample, X, X_A_Asset, X_A_Asset_Delivery, X_A_Asset_Group, X_A_Asset_Retirement, X_A_Registration, X_A_RegistrationAttribute, X_A_RegistrationProduct, X_A_RegistrationValue, X_AD_AccessLog, X_AD_Alert, X_AD_AlertProcessor, X_AD_AlertProcessorLog, X_AD_AlertRecipient, X_AD_AlertRule, X_AD_Archive, X_AD_AssignCriteria, X_AD_AssignLog, X_AD_AssignSet, X_AD_AssignTarget, X_AD_Attachment, X_AD_AttachmentNote, X_AD_Attribute, X_AD_Attribute_Value, X_AD_BView, X_AD_BView_Access, X_AD_BView_Field, X_AD_BView_ReportLayer, X_AD_BView_ReportLayer_Map, X_AD_BView_Source, X_AD_BView_Source_Mapping, X_AD_ChangeLog, X_AD_Client, X_AD_ClientInfo, X_AD_ClientShare, X_AD_Color, X_AD_Column, X_AD_Column_Access, X_AD_Column_Trl, X_AD_ComponentCreate, X_AD_ComponentReg, X_AD_ComponentRegUpdate, X_AD_ComponentUse, X_AD_CtxArea, X_AD_DataMigration, X_AD_DataMigrationEntry, X_AD_DataMigrationPreview, X_AD_Desktop, X_AD_Desktop_Trl, X_AD_DesktopWorkbench, X_AD_Element, X_AD_Element_Trl, X_AD_ElementCtx, X_AD_ElementCtx_Trl, X_AD_EntityType, X_AD_Error, X_AD_EUL_Setup, X_AD_EUL_User, X_AD_Field, X_AD_Field_Trl, X_AD_FieldGroup, X_AD_FieldGroup_Trl, X_AD_Find, X_AD_Form, X_AD_Form_Access, X_AD_Form_Trl, X_AD_FormShortcut, X_AD_Image, X_AD_ImpFormat, X_AD_ImpFormat_Row, X_AD_IndexColumn, X_AD_InfoColumn, X_AD_InfoColumn_Trl, X_AD_InfoWindow, X_AD_InfoWindow_Trl, X_AD_Issue, X_AD_LabelPrinter, X_AD_LabelPrinterFunction, X_AD_Language, X_AD_LdapAccess, X_AD_LdapProcessor, X_AD_LdapProcessorLog, X_AD_Menu, X_AD_Menu_Trl, X_AD_Message, X_AD_Message_Trl, X_AD_MigrationStep, X_AD_Modification, X_AD_Note, X_AD_Org, X_AD_OrgInfo, X_AD_OrgType, X_AD_PInstance, X_AD_PInstance_Log, X_AD_PInstance_Para, X_AD_Preference, X_AD_PrintColor, X_AD_PrintFont, X_AD_PrintForm, X_AD_PrintFormat, X_AD_PrintFormatItem, X_AD_PrintFormatItem_Trl, X_AD_PrintGraph, X_AD_PrintLabel, X_AD_PrintLabelLine, X_AD_PrintLabelLine_Trl, X_AD_PrintPaper, X_AD_PrintTableFormat, X_AD_Private_Access, X_AD_Process, X_AD_Process_Access, X_AD_Process_Para, X_AD_Process_Para_Trl, X_AD_Process_Trl, X_AD_QueryLog, X_AD_RecentItem, X_AD_Record_Access, X_AD_Ref_List, X_AD_Ref_List_Trl, X_AD_Ref_Table, X_AD_Reference, X_AD_Reference_Trl, X_AD_Registration, X_AD_Replication, X_AD_Replication_Log, X_AD_Replication_Run, X_AD_ReplicationStrategy, X_AD_ReplicationTable, X_AD_ReportTemplate, X_AD_ReportTemplate_Relation, X_AD_ReportView, X_AD_ReportView_Col, X_AD_Role, X_AD_Role_OrgAccess, X_AD_Schedule, X_AD_Scheduler, X_AD_Scheduler_Para, X_AD_SchedulerLog, X_AD_SchedulerRecipient, X_AD_Sequence, X_AD_Sequence_Audit, X_AD_Sequence_No, X_AD_Session, X_AD_System, X_AD_Tab, X_AD_Tab_Trl, X_AD_Table, X_AD_Table_Access, X_AD_Table_Trl, X_AD_TableIndex, X_AD_Task, X_AD_Task_Access, X_AD_Task_Trl, X_AD_TaskInstance, X_AD_Tree, X_AD_TreeBar, X_AD_TreeNode, X_AD_TreeNodeBP, X_AD_TreeNodeCMC, X_AD_TreeNodeCMM, X_AD_TreeNodeCMS, X_AD_TreeNodeCMT, X_AD_TreeNodeMM, X_AD_TreeNodePR, X_AD_TreeNodeU1, X_AD_TreeNodeU2, X_AD_TreeNodeU3, X_AD_TreeNodeU4, X_AD_User, X_AD_User_OrgAccess, X_AD_User_Roles, X_AD_User_Substitute, X_AD_UserBPAccess, X_AD_UserDef_Field, X_AD_UserDef_Tab, X_AD_UserDef_Win, X_AD_UserMail, X_AD_UserPreference, X_AD_UserQuery, X_AD_UserQueryLine, X_AD_Val_Rule, X_AD_Version, X_AD_ViewColumn, X_AD_ViewComponent, X_AD_WF_Activity, X_AD_WF_ActivityResult, X_AD_WF_Block, X_AD_WF_EventAudit, X_AD_WF_NextCondition, X_AD_WF_Node, X_AD_WF_Node_Para, X_AD_WF_Node_Trl, X_AD_WF_NodeNext, X_AD_WF_Process, X_AD_WF_ProcessData, X_AD_WF_Responsible, X_AD_Window, X_AD_Window_Access, X_AD_Window_Trl, X_AD_WindowLog, X_AD_Workbench, X_AD_Workbench_Trl, X_AD_WorkbenchWindow, X_AD_Workflow, X_AD_Workflow_Access, X_AD_Workflow_Trl, X_AD_WorkflowProcessor, X_AD_WorkflowProcessorLog, X_B_Bid, X_B_BidComment, X_B_Buyer, X_B_BuyerFunds, X_B_Offer, X_B_Seller, X_B_SellerFunds, X_B_Topic, X_B_TopicCategory, X_B_TopicType, X_C_AcctProcessor, X_C_AcctProcessorLog, X_C_AcctSchema, X_C_AcctSchema_Default, X_C_AcctSchema_Element, X_C_AcctSchema_GL, X_C_Activity, X_C_AllocationHdr, X_C_AllocationLine, X_C_Bank, X_C_BankAccount, X_C_BankAccount_Acct, X_C_BankAccountDoc, X_C_BankStatement, X_C_BankStatementLine, X_C_BankStatementLoader, X_C_BankStatementMatcher, X_C_BP_BankAccount, X_C_BP_Customer_Acct, X_C_BP_Employee_Acct, X_C_BP_Group, X_C_BP_Group_Acct, X_C_BP_Relation, X_C_BP_Size, X_C_BP_Status, X_C_BP_Vendor_Acct, X_C_BP_Withholding, X_C_BPartner, X_C_BPartner_Location, X_C_BPartner_Product, X_C_Calendar, X_C_Campaign, X_C_Cash, X_C_CashBook, X_C_CashBook_Acct, X_C_CashLine, X_C_Channel, X_C_Charge, X_C_Charge_Acct, X_C_Charge_Trl, X_C_City, X_C_Commission, X_C_CommissionAmt, X_C_CommissionDetail, X_C_CommissionLine, X_C_CommissionRun, X_C_ConsolidationReference, X_C_Conversion_Rate, X_C_ConversionType, X_C_Country, X_C_Country_Trl, X_C_Currency, X_C_Currency_Acct, X_C_Currency_Trl, X_C_Cycle, X_C_CyclePhase, X_C_CycleStep, X_C_DocBaseType, X_C_DocType, X_C_DocType_Trl, X_C_DocTypeCounter, X_C_DocTypeGroup, X_C_DocTypeGroupLine, X_C_Dunning, X_C_DunningLevel, X_C_DunningLevel_Trl, X_C_DunningRun, X_C_DunningRunEntry, X_C_DunningRunLine, X_C_Element, X_C_ElementValue, X_C_ElementValue_Trl, X_C_Greeting, X_C_Greeting_Trl, X_C_IndustryCode, X_C_InterOrg_Acct, X_C_Invoice, X_C_InvoiceBatch, X_C_InvoiceBatchLine, X_C_InvoiceLine, X_C_InvoicePaySchedule, X_C_InvoiceSchedule, X_C_InvoiceTax, X_C_Job, X_C_JobAssignment, X_C_JobCategory, X_C_JobRemuneration, X_C_LandedCost, X_C_LandedCostAllocation, X_C_Lead, X_C_LeadQualification, X_C_Location, X_C_NonBusinessDay, X_C_Order, X_C_OrderLine, X_C_OrderTax, X_C_OrgAssignment, X_C_Payment, X_C_PaymentAllocate, X_C_PaymentBatch, X_C_PaymentProcessor, X_C_PaymentTerm, X_C_PaymentTerm_Trl, X_C_PaySchedule, X_C_PaySelection, X_C_PaySelectionCheck, X_C_PaySelectionLine, X_C_Period, X_C_PeriodControl, X_C_Phase, X_C_POS, X_C_POSKey, X_C_POSKeyLayout, X_C_Project, X_C_Project_Acct, X_C_ProjectIssue, X_C_ProjectIssueMA, X_C_ProjectLine, X_C_ProjectPhase, X_C_ProjectTask, X_C_ProjectType, X_C_Recurring, X_C_Recurring_Run, X_C_Region, X_C_Remuneration, X_C_RfQ, X_C_RfQ_Topic, X_C_RfQ_TopicSubscriber, X_C_RfQ_TopicSubscriberOnly, X_C_RfQLine, X_C_RfQLineQty, X_C_RfQResponse, X_C_RfQResponseLine, X_C_RfQResponseLineQty, X_C_SalesRegion, X_C_SubAcct, X_C_Subscription, X_C_Subscription_Delivery, X_C_SubscriptionType, X_C_Task, X_C_Tax, X_C_Tax_Acct, X_C_Tax_Trl, X_C_TaxCategory, X_C_TaxCategory_Trl, X_C_TaxDeclaration, X_C_TaxDeclarationAcct, X_C_TaxDeclarationLine, X_C_TaxPostal, X_C_UOM, X_C_UOM_Conversion, X_C_UOM_Trl, X_C_UserRemuneration, X_C_ValidCombination, X_C_Wave, X_C_WaveLine, X_C_WaveSortCriteria, X_C_WaveSortCriteriaLine, X_C_Withholding, X_C_Withholding_Acct, X_C_Year, X_CM_AccessChat, X_CM_AccessContainer, X_CM_AccessListBPGroup, X_CM_AccessListRole, X_CM_AccessMedia, X_CM_AccessNewsChannel, X_CM_AccessProfile, X_CM_AccessStage, X_CM_Ad, X_CM_Ad_Cat, X_CM_BroadcastServer, X_CM_Chat, X_CM_ChatEntry, X_CM_ChatType, X_CM_ChatTypeUpdate, X_CM_ChatUpdate, X_CM_Container, X_CM_Container_Element, X_CM_Container_Element_Trl, X_CM_Container_Trl, X_CM_Container_URL, X_CM_ContainerTTable, X_CM_CStage, X_CM_CStage_Element, X_CM_CStage_Element_Trl, X_CM_CStage_Trl, X_CM_CStageTTable, X_CM_Media, X_CM_Media_Server, X_CM_MediaDeploy, X_CM_NewsChannel, X_CM_NewsItem, X_CM_Template, X_CM_Template_Ad_Cat, X_CM_TemplateTable, X_CM_WebAccessLog, X_CM_WebProject, X_CM_WebProject_Domain, X_CM_WikiToken, X_Fact_Acct, X_Fact_Acct_Balance, X_GL_Budget, X_GL_BudgetControl, X_GL_Category, X_GL_Distribution, X_GL_DistributionLine, X_GL_Fund, X_GL_FundRestriction, X_GL_Journal, X_GL_JournalBatch, X_GL_JournalLine, X_I_BankStatement, X_I_BPartner, X_I_Contact, X_I_Conversion_Rate, X_I_ElementValue, X_I_GLJournal, X_I_InOut, X_I_InOutLineConfirm, X_I_Inventory, X_I_Invoice, X_I_Locator, X_I_Order, X_I_Payment, X_I_Product, X_I_ReportLine, X_I_Request, X_IP_Requirement, X_K_Category, X_K_CategoryValue, X_K_Comment, X_K_Entry, X_K_EntryCategory, X_K_EntryRelated, X_K_Index, X_K_IndexLog, X_K_IndexStop, X_K_Source, X_K_Synonym, X_K_Topic, X_K_Type, X_M_Attribute, X_M_AttributeInstance, X_M_AttributeSearch, X_M_AttributeSet, X_M_AttributeSetExclude, X_M_AttributeSetInstance, X_M_AttributeUse, X_M_AttributeValue, X_M_BOM, X_M_BOMAlternative, X_M_BOMProduct, X_M_ChangeNotice, X_M_ChangeRequest, X_M_Cost, X_M_CostDetail, X_M_CostElement, X_M_CostQueue, X_M_CostType, X_M_CostUpdate, X_M_CostUpdateLine, X_M_Demand, X_M_DemandDetail, X_M_DemandLine, X_M_DiscountSchema, X_M_DiscountSchemaBreak, X_M_DiscountSchemaLine, X_M_DistributionList, X_M_DistributionListLine, X_M_DistributionRun, X_M_DistributionRunLine, X_M_Forecast, X_M_ForecastLine, X_M_Freight, X_M_FreightCategory, X_M_InOut, X_M_InOutConfirm, X_M_InOutLine, X_M_InOutLineConfirm, X_M_InOutLineMA, X_M_InOutStage, X_M_Inventory, X_M_InventoryLine, X_M_InventoryLineMA, X_M_Locator, X_M_Lot, X_M_LotCtl, X_M_LotCtlExclude, X_M_MatchInv, X_M_MatchPO, X_M_MMRule, X_M_MMStrategy, X_M_MMStrategyLine, X_M_MMStrategySet, X_M_MMStrategySetLine, X_M_Movement, X_M_MovementConfirm, X_M_MovementLine, X_M_MovementLineConfirm, X_M_MovementLineMA, X_M_OperationResource, X_M_Package, X_M_PackageLine, X_M_PerpetualInv, X_M_PriceList, X_M_PriceList_Version, X_M_Product, X_M_Product_Acct, X_M_Product_BOM, X_M_Product_Category, X_M_Product_Category_Acct, X_M_Product_Costing, X_M_Product_PO, X_M_Product_Trl, X_M_ProductDownload, X_M_Production, X_M_ProductionLine, X_M_ProductionLineMA, X_M_ProductionPlan, X_M_ProductLocator, X_M_ProductOperation, X_M_ProductPrice, X_M_RelatedProduct, X_M_Replenish, X_M_Requisition, X_M_RequisitionLine, X_M_ReturnPolicy, X_M_ReturnPolicyLine, X_M_RMACategory, X_M_Routing, X_M_RoutingOperation, X_M_SerNoCtl, X_M_SerNoCtlExclude, X_M_Shipper, X_M_Storage, X_M_Substitute, X_M_TaskList, X_M_TaskListLine, X_M_Transaction, X_M_TransactionAllocation, X_M_Warehouse, X_M_Warehouse_Acct, X_M_WarehouseTask, X_M_WarehouseTaskMA, X_M_WorkOrder, X_M_WorkOrderClass, X_M_WorkOrderClass_Acct, X_M_WorkOrderComponent, X_M_WorkOrderInvTransaction, X_M_WorkOrderOperation, X_M_WorkOrderTransaction, X_M_WorkOrderTransactionLine, X_M_WorkOrderTransactionLineMA, X_M_Zone, X_M_ZoneLocator, X_M_ZoneRelationship, X_PA_Achievement, X_PA_Benchmark, X_PA_BenchmarkData, X_PA_ColorSchema, X_PA_Goal, X_PA_GoalRestriction, X_PA_Hierarchy, X_PA_Measure, X_PA_MeasureCalc, X_PA_Ratio, X_PA_RatioElement, X_PA_Report, X_PA_ReportColumn, X_PA_ReportColumnSet, X_PA_ReportLine, X_PA_ReportLineSet, X_PA_ReportSource, X_PA_SLA_Criteria, X_PA_SLA_Goal, X_PA_SLA_Measure, X_R_Category, X_R_CategoryUpdates, X_R_ContactInterest, X_R_Group, X_R_GroupUpdates, X_R_InterestArea, X_R_IssueKnown, X_R_IssueProject, X_R_IssueRecommendation, X_R_IssueStatus, X_R_IssueSystem, X_R_IssueUser, X_R_MailText, X_R_MailText_Trl, X_R_Request, X_R_RequestAction, X_R_RequestProcessor, X_R_RequestProcessor_Route, X_R_RequestProcessorLog, X_R_RequestType, X_R_RequestTypeUpdates, X_R_RequestUpdate, X_R_RequestUpdates, X_R_Resolution, X_R_Source, X_R_StandardResponse, X_R_Status, X_R_StatusCategory, X_RV_BPartner, X_RV_WarehousePrice, X_S_ExpenseType, X_S_Resource, X_S_ResourceAssignment, X_S_ResourceType, X_S_ResourceUnAvailable, X_S_TimeExpense, X_S_TimeExpenseLine, X_S_TimeType, X_S_Training, X_S_Training_Class, X_T_Aging, X_T_DistributionRunDetail, X_T_ImpFormat, X_T_InventoryValue, X_T_InvoiceGL, X_T_Replenish, X_T_Report, X_T_ReportStatement, X_T_Selection, X_T_Selection2, X_T_Spool, X_T_Transaction, X_T_TrialBalance, X_Test, X_TIRE_Storage, X_W_Advertisement, X_W_Basket, X_W_BasketLine, X_W_Click, X_W_ClickCount, X_W_Counter, X_W_CounterCount, X_W_MailMsg, X_W_MailMsg_Trl, X_W_Store, X_W_Store_Trl

public abstract class PO
extends Object
implements Serializable, Cloneable, Comparator<PO>, Evaluatee

Persistent Object. Superclass for actual implementations

Version:
$Id: PO.java,v 1.12 2006/08/09 16:38:47 jjanke Exp $
Author:
Jorg Janke
See Also:
Serialized Form

Field Summary
static int ACCESSLEVEL_ALL
          Access Level SCO 111 7 System shared info
static int ACCESSLEVEL_CLIENT
          Access Level _C_ 010 2 Client info
static int ACCESSLEVEL_CLIENTORG
          Access Level _CO 011 3 Client shared info
static int ACCESSLEVEL_ORG
          Access Level __O 001 1 Organization info
static int ACCESSLEVEL_SYSTEM
          Access Level S__ 100 4 System info
static int ACCESSLEVEL_SYSTEMCLIENT
          Access Level SC_ 110 6 System/Client info
protected static String ENTITYTYPE_Dictionary
          Dictionary Maintained Entity Type
protected static String ENTITYTYPE_UserMaintained
          User Maintained Entity Type
protected static Integer I_ZERO
          Zero Integer
protected  CLogger log
          Logger
protected  ChangeVO p_changeVO
          Change VO
protected  POInfo p_info
          Model Info
static String XML_ATTRIBUTE_AD_Table_ID
          Table ID Attribute
static String XML_ATTRIBUTE_Record_ID
          Record ID Attribute
 
Constructor Summary
PO(Ctx ctx)
          Create New Persisent Object
PO(Ctx ctx, int ID, String trxName)
          Create & Load existing Persistent Object
PO(Ctx ctx, PO source, int AD_Client_ID, int AD_Org_ID)
          Create New PO by Copying existing (key not copied).
PO(Ctx ctx, ResultSet rs, String trxName)
          Create & Load existing Persistent Object.
PO(Ctx ctx, VO vo)
          VO Constructor
 
Method Summary
 boolean addAttachment(File file)
          Add Attachment to Record
 boolean addAttachment(URI uri)
          Add Attachment to Record
protected  void addError(String message)
          Added the message text to p_changeVO if p_changeVO is not null.
protected  boolean afterDelete(boolean success)
          Executed after Delete operation.
protected  boolean afterSave(boolean newRecord, boolean success)
          Called after Save for Post-Save Operation
protected  boolean beforeDelete()
          Executed before Delete operation.
protected  boolean beforeSave(boolean newRecord)
          Called before Save for Pre-Save Operation
 int compare(PO o1, PO o2)
          Compare based on DocumentNo, Value, Name, Description
static BigDecimal convertToBigDecimal(String stringValue)
          Convert String To BigDecimal.
static boolean convertToBoolean(String stringValue)
          Convert String To boolean.
static int convertToInt(String stringValue)
          Convert String To int.
static Timestamp convertToTimestamp(String stringValue)
          Convert String To Timestamp.
static PO copy(Ctx ctx, PO po)
          Get a copy/clone of PO and set ctx
static void copyValues(PO from, PO to)
          Copy old values of From to new values of To.
protected static void copyValues(PO from, PO to, int AD_Client_ID, int AD_Org_ID)
          Copy old values of From to new values of To.
 MAttachment createAttachment()
          Create/return Attachment for PO.
protected  boolean delete_Accounting(String acctTable)
          Delete Accounting records.
 boolean delete(boolean force)
          Delete Current Record
 boolean delete(boolean force, String trxName)
          Delete Current Record
 void dump()
          Dump Record
 void dump(int index)
          Dump column
 boolean equals(Object cmp)
          Equals based on ID
protected abstract  int get_AccessLevel()
          Get Table Access Level
 ChangeVO get_ChangeVO()
          Get Change VO
 int get_ColumnCount()
          Get Column Count
protected  String get_ColumnDescription(int index)
          Get Column Description
 int get_ColumnDisplayType(int index)
          Get Column DisplayType
 int get_ColumnIndex(String columnName)
          Get Column Index
protected  String get_ColumnLabel(int index)
          Get Column Label
protected  Lookup get_ColumnLookup(int index)
          Get Lookup
 String get_ColumnName(int index)
          Get Column Name
protected  String get_DisplayValue(String columnName, boolean currentValue)
          Get Display Value of value
 String get_EntityType()
          Get Entity Type of record
protected  HashMap<String,String> get_HashMap()
          Create HashMap with data as Strings
 int get_ID()
          Return Single Key Record ID
 int get_IDOld()
          Return Deleted Single Key Record ID
 POInfo get_Info()
          Get PO Info
 String[] get_KeyColumns()
          Get Key Columns.
 CLogger get_Logger()
          Get Logger
 int get_Table_ID()
          Get AD Table ID.
static int get_Table_ID(String tableName)
          Get ID of table
 String get_TableName()
          Get TableName.
protected  String get_Translation(String columnName, String AD_Language)
          Get Translation of column
 String get_TrxName()
          Get Trx
 Object get_Value(int index)
          Get Value
 Object get_Value(String columnName)
          Get Value
protected  int get_ValueAsInt(int index)
          Get Value as int
 int get_ValueAsInt(String columnName)
          Get Value as Integer
 String get_ValueAsString(String columnName)
          Get Column Value
 Object get_ValueDifference(int index)
          Return new - old
 Object get_ValueDifference(String columnName)
          Return new - old
 Object get_ValueOfColumn(int AD_Column_ID)
          Get Value of Column
 Object get_ValueOld(int index)
          Get Old Value
 Object get_ValueOld(String columnName)
          Get Old Value
protected  int get_ValueOldAsInt(String columnName)
          Get Old Value as int
 String[] get_ValuesAsString(String[] columnNames)
          Get Column Values as String
 String get_WhereClause(boolean withValues)
          Create Single/Multi Key Where Clause
 Document get_xmlDocument(boolean noComment, boolean dataOnly)
          Get XML Document representation
 StringBuffer get_xmlString(StringBuffer xml)
          Get Object xml (data only) representation as string
 StringBuffer get_xmlString(StringBuffer xml, boolean dataOnly)
          Get Object xml representation as string
 int getAD_Client_ID()
          Get AD_Client
 int getAD_Org_ID()
          Get AD_Org
static int[] getAllIDs(String TableName, String WhereClause, String trxName)
          Get All IDs of Table.
 MAttachment getAttachment()
          Get Attachments.
 MAttachment getAttachment(boolean requery)
          Get Attachments
 byte[] getAttachmentData(String extension)
          Get Attachment Data of type
 Timestamp getCreated()
          Get Created
 int getCreatedBy()
          Get CreatedBy
 Ctx getCtx()
          Get Context
protected static String getFindParameter(String query)
          Get Find parameter.
 byte[] getPdfAttachment()
          Get PDF Attachment Data
 Timestamp getUpdated()
          Get Updated
 int getUpdatedBy()
          Get UpdatedBy
 VO getVO()
          Get Object as VO
 int hashCode()
          Used for HashTable
protected abstract  POInfo initPO(Ctx ctx)
          Initialize and return PO_Info
protected  boolean insert_Accounting(String acctTable, String acctBaseTable, String whereClause)
          Insert Accounting Records
 boolean is_Changed()
          Is there a Change to be saved?
 boolean is_KeyColumn(String columnName)
          Is Column a Key Column?
 boolean is_new()
          Is new record
 boolean is_ValueChanged(int index)
          Is Value Changed
 boolean is_ValueChanged(String columnName)
          Is Value Changed
 boolean isActive()
          Is Active
 boolean isAttachment(String extension)
          Do we have a Attachment of type
protected  boolean isColumnMandatory(int index)
          Is Column Mandatory
protected  boolean isColumnUpdateable(int index)
          Is Column Updateable
protected  boolean isMandatoryOK()
          Are all mandatory Fields filled (i.e. can we save)?.
 boolean isPdfAttachment()
          Do we have a PDF Attachment
 void load(int ID, String trxName)
          Load record with ID
 boolean load(Map<String,String> hmIn)
          Load from HashMap.
protected  boolean load(ResultSet rs)
          Load from the current position of a ResultSet
 boolean load(String trxName)
          (re)Load record with m_ID[*]
protected  void loadComplete(boolean success)
          Load is complete
protected  void loadDefaults()
          Load Defaults
protected  Object loadSpecial(ResultSet rs, int index)
          Load Special data (images, ..).
 boolean lock()
          Lock it.
 boolean save()
          Update Value or create new record.
 boolean save(String trxName)
          Update Value or create new record.
protected  int saveNew_getID()
          Get ID for new record during save.
 boolean saveNewInsertSQL()
          Create Insert SQL and execute
protected  String saveNewSpecial(Object value, int index)
          Save Special Data.
protected  boolean saveUpdate()
          Update Record directly
 void set_ChangeVO(ChangeVO change)
          Set Change VO
protected  void set_ColumnUpdateable(int index, boolean updateable)
          Set Column Updateable
 void set_CustomColumn(String columnName, Object value)
          Set Custom Column
 void set_TrxName(String trxName)
          Set Trx
 boolean set_Value(int index, Object value)
          Set Value if updateable and correct class.
 boolean set_Value(String ColumnName, Object value)
          Set Value
protected  boolean set_ValueE(String ColumnName, Object value)
          Set Encrypted Value
 boolean set_ValueNoCheck(String ColumnName, Object value)
          Set Value w/o check (update, r/o, ..).
protected  boolean set_ValueNoCheckE(String ColumnName, Object value)
          Set Encrypted Value w/o check (update, r/o, ..).
 void set_ValueOfColumn(int AD_Column_ID, Object value)
          Set Value of Column
protected  String set_ValueString(int index, String stringValue)
          Set Value from String.
 void setAD_Client_ID(int AD_Client_ID)
          Set AD_Client
 void setAD_Org_ID(int AD_Org_ID)
          Set AD_Org
 void setClientOrg(int AD_Client_ID, int AD_Org_ID)
          Overwrite Client Org if different
 void setClientOrg(PO po)
          Overwrite Client Org if different
protected  void setContext(int windowNo, String columnName, String value)
          Sets the context in p_changeVO, if p_changeVO is not null
protected  void setCtx(Ctx ctx)
          set Context
static void setDocWorkflowMgr(DocWorkflowMgr docWFMgr)
          Set Document Value Workflow Manager
 void setIsActive(boolean active)
          Set Active
protected  void setStandardDefaults()
          Set Default values.
protected  void setUpdateable(boolean updateable)
          Set all columns updateable
protected  void setUpdatedBy(int AD_User_ID)
          Set UpdatedBy
 String toString()
          String info
 String toStringX()
          Extended String info
 boolean unlock(String trxName)
          UnLock it
 String update(Map<String,String> context)
          Update PO based on string context
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

ENTITYTYPE_UserMaintained

protected static final String ENTITYTYPE_UserMaintained
User Maintained Entity Type

See Also:
Constant Field Values

ENTITYTYPE_Dictionary

protected static final String ENTITYTYPE_Dictionary
Dictionary Maintained Entity Type

See Also:
Constant Field Values

log

protected transient CLogger log
Logger


p_info

protected volatile POInfo p_info
Model Info


I_ZERO

protected static final Integer I_ZERO
Zero Integer


p_changeVO

protected ChangeVO p_changeVO
Change VO


ACCESSLEVEL_SYSTEM

public static final int ACCESSLEVEL_SYSTEM
Access Level S__ 100 4 System info

See Also:
Constant Field Values

ACCESSLEVEL_CLIENT

public static final int ACCESSLEVEL_CLIENT
Access Level _C_ 010 2 Client info

See Also:
Constant Field Values

ACCESSLEVEL_ORG

public static final int ACCESSLEVEL_ORG
Access Level __O 001 1 Organization info

See Also:
Constant Field Values

ACCESSLEVEL_ALL

public static final int ACCESSLEVEL_ALL
Access Level SCO 111 7 System shared info

See Also:
Constant Field Values

ACCESSLEVEL_SYSTEMCLIENT

public static final int ACCESSLEVEL_SYSTEMCLIENT
Access Level SC_ 110 6 System/Client info

See Also:
Constant Field Values

ACCESSLEVEL_CLIENTORG

public static final int ACCESSLEVEL_CLIENTORG
Access Level _CO 011 3 Client shared info

See Also:
Constant Field Values

XML_ATTRIBUTE_AD_Table_ID

public static final String XML_ATTRIBUTE_AD_Table_ID
Table ID Attribute

See Also:
Constant Field Values

XML_ATTRIBUTE_Record_ID

public static final String XML_ATTRIBUTE_Record_ID
Record ID Attribute

See Also:
Constant Field Values
Constructor Detail

PO

public PO(Ctx ctx)
Create New Persisent Object

Parameters:
ctx - context

PO

public PO(Ctx ctx,
          int ID,
          String trxName)
Create & Load existing Persistent Object

Parameters:
ID - The unique ID of the object
ctx - context
trxName - transaction name

PO

public PO(Ctx ctx,
          ResultSet rs,
          String trxName)
Create & Load existing Persistent Object.

Parameters:
ctx - context
rs - optional - load from current result set position (no navigation, not closed) if null, a new record is created.
trxName - transaction name

PO

public PO(Ctx ctx,
          PO source,
          int AD_Client_ID,
          int AD_Org_ID)
Create New PO by Copying existing (key not copied).

Parameters:
ctx - context
source - source object
AD_Client_ID - client
AD_Org_ID - org

PO

public PO(Ctx ctx,
          VO vo)
VO Constructor

Parameters:
ctx - context
vo - value object
Method Detail

copy

public static PO copy(Ctx ctx,
                      PO po)
Get a copy/clone of PO and set ctx

Parameters:
ctx - context
po - PO
Returns:
po or null

setDocWorkflowMgr

public static void setDocWorkflowMgr(DocWorkflowMgr docWFMgr)
Set Document Value Workflow Manager

Parameters:
docWFMgr - mgr

convertToInt

public static int convertToInt(String stringValue)
Convert String To int. Null throws an error

Parameters:
stringValue - value
Returns:
int

convertToTimestamp

public static Timestamp convertToTimestamp(String stringValue)
Convert String To Timestamp. Null is passed through

Parameters:
stringValue - value
Returns:
Timestamp

convertToBigDecimal

public static BigDecimal convertToBigDecimal(String stringValue)
Convert String To BigDecimal. Null is passed through

Parameters:
stringValue - value
Returns:
BigDecimal

convertToBoolean

public static boolean convertToBoolean(String stringValue)
Convert String To boolean. 'Y','true' is true - rest (incl null) is false

Parameters:
stringValue - value
Returns:
boolean

get_Table_ID

public static int get_Table_ID(String tableName)
Get ID of table

Parameters:
tableName - name
Returns:
AD_Table_ID

initPO

protected abstract POInfo initPO(Ctx ctx)
Initialize and return PO_Info

Parameters:
ctx - context
Returns:
POInfo

get_AccessLevel

protected abstract int get_AccessLevel()
Get Table Access Level

Returns:
Access Level

get_Info

public POInfo get_Info()
Get PO Info

Returns:
info

toString

public String toString()
String info

Overrides:
toString in class Object
Returns:
String info

toStringX

public String toStringX()
Extended String info

Returns:
String info

equals

public boolean equals(Object cmp)
Equals based on ID

Specified by:
equals in interface Comparator<PO>
Overrides:
equals in class Object
Parameters:
cmp - comparator
Returns:
true if ID the same

hashCode

public int hashCode()
Used for HashTable

Overrides:
hashCode in class Object

compare

public int compare(PO o1,
                   PO o2)
Compare based on DocumentNo, Value, Name, Description

Specified by:
compare in interface Comparator<PO>
Parameters:
o1 - Object 1
o2 - Object 2
Returns:
-1 if o1 < o2

get_TableName

public String get_TableName()
Get TableName.

Returns:
table name

get_KeyColumns

public String[] get_KeyColumns()
Get Key Columns.

Returns:
table name

is_KeyColumn

public boolean is_KeyColumn(String columnName)
Is Column a Key Column?

Parameters:
columnName - column name
Returns:
true if key column

get_Table_ID

public int get_Table_ID()
Get AD Table ID.

Returns:
AD_Table_ID

get_ID

public int get_ID()
Return Single Key Record ID

Returns:
ID or 0

get_IDOld

public int get_IDOld()
Return Deleted Single Key Record ID

Returns:
ID or 0

getCtx

public Ctx getCtx()
Get Context

Returns:
context

get_Logger

public CLogger get_Logger()
Get Logger

Returns:
logger

get_Value

public final Object get_Value(int index)
Get Value

Parameters:
index - index
Returns:
value

get_ValueAsInt

protected int get_ValueAsInt(int index)
Get Value as int

Parameters:
index - index
Returns:
int value or 0

get_Value

public final Object get_Value(String columnName)
Get Value

Parameters:
columnName - column name
Returns:
value or null

get_ValueAsInt

public final int get_ValueAsInt(String columnName)
Get Value as Integer

Parameters:
columnName - column name
Returns:
value or -1 (null) or -2 (no integer)

get_ValueAsString

public String get_ValueAsString(String columnName)
Get Column Value

Specified by:
get_ValueAsString in interface Evaluatee
Parameters:
columnName - name
Returns:
value or ""

get_ValuesAsString

public String[] get_ValuesAsString(String[] columnNames)
Get Column Values as String

Parameters:
columnNames - column names
Returns:
string array

get_ValueOfColumn

public final Object get_ValueOfColumn(int AD_Column_ID)
Get Value of Column

Parameters:
AD_Column_ID - column
Returns:
value or null

get_ValueOld

public final Object get_ValueOld(int index)
Get Old Value

Parameters:
index - index
Returns:
value

get_ValueOld

public final Object get_ValueOld(String columnName)
Get Old Value

Parameters:
columnName - column name
Returns:
value or null

get_ValueOldAsInt

protected int get_ValueOldAsInt(String columnName)
Get Old Value as int

Parameters:
columnName - column name
Returns:
int value or 0

is_ValueChanged

public final boolean is_ValueChanged(int index)
Is Value Changed

Parameters:
index - index
Returns:
true if changed

is_ValueChanged

public final boolean is_ValueChanged(String columnName)
Is Value Changed

Parameters:
columnName - column name
Returns:
true if changed

get_ValueDifference

public final Object get_ValueDifference(int index)
Return new - old. - New Value if Old Valus is null - New Value - Old Value if Number - otherwise null

Parameters:
index - index
Returns:
new - old or null if not appropiate or not changed

get_ValueDifference

public final Object get_ValueDifference(String columnName)
Return new - old. - New Value if Old Valus is null - New Value - Old Value if Number - otherwise null

Parameters:
columnName - column name
Returns:
new - old or null if not appropiate or not changed

set_Value

public final boolean set_Value(String ColumnName,
                               Object value)
Set Value

Parameters:
ColumnName - column name
value - value
Returns:
true if value set

set_ValueE

protected final boolean set_ValueE(String ColumnName,
                                   Object value)
Set Encrypted Value

Parameters:
ColumnName - column name
value - value
Returns:
true if value set

set_Value

public final boolean set_Value(int index,
                               Object value)
Set Value if updateable and correct class. (and to NULL if not mandatory)

Parameters:
index - index
value - value
Returns:
true if value set

set_ValueNoCheck

public final boolean set_ValueNoCheck(String ColumnName,
                                      Object value)
Set Value w/o check (update, r/o, ..). Used when Column is R/O Required for key and parent values

Parameters:
ColumnName - column name
value - value
Returns:
true if value set

set_ValueNoCheckE

protected final boolean set_ValueNoCheckE(String ColumnName,
                                          Object value)
Set Encrypted Value w/o check (update, r/o, ..). Used when Column is R/O Required for key and parent values

Parameters:
ColumnName - column name
value - value
Returns:
true if value set

set_ValueString

protected String set_ValueString(int index,
                                 String stringValue)
                          throws Exception
Set Value from String. No Check if column is updateable or mandatory

Parameters:
index - index
stringValue - value
Returns:
error message or null
Throws:
Exception

set_ValueOfColumn

public final void set_ValueOfColumn(int AD_Column_ID,
                                    Object value)
Set Value of Column

Parameters:
AD_Column_ID - column
value - value

set_CustomColumn

public final void set_CustomColumn(String columnName,
                                   Object value)
Set Custom Column

Parameters:
columnName - column
value - value

setCtx

protected void setCtx(Ctx ctx)
set Context


get_ColumnCount

public int get_ColumnCount()
Get Column Count

Returns:
column count

get_ColumnName

public String get_ColumnName(int index)
Get Column Name

Parameters:
index - index
Returns:
ColumnName

get_ColumnLabel

protected String get_ColumnLabel(int index)
Get Column Label

Parameters:
index - index
Returns:
Column Label

get_ColumnDescription

protected String get_ColumnDescription(int index)
Get Column Description

Parameters:
index - index
Returns:
column description

isColumnMandatory

protected boolean isColumnMandatory(int index)
Is Column Mandatory

Parameters:
index - index
Returns:
true if column mandatory

isColumnUpdateable

protected boolean isColumnUpdateable(int index)
Is Column Updateable

Parameters:
index - index
Returns:
true if column updateable

set_ColumnUpdateable

protected void set_ColumnUpdateable(int index,
                                    boolean updateable)
Set Column Updateable

Parameters:
index - index
updateable - column updateable

setUpdateable

protected void setUpdateable(boolean updateable)
Set all columns updateable

Parameters:
updateable - updateable

get_ColumnDisplayType

public int get_ColumnDisplayType(int index)
Get Column DisplayType

Parameters:
index - index
Returns:
display type

get_ColumnLookup

protected Lookup get_ColumnLookup(int index)
Get Lookup

Parameters:
index - index
Returns:
Lookup or null

get_ColumnIndex

public final int get_ColumnIndex(String columnName)
Get Column Index

Parameters:
columnName - column name
Returns:
index of column with ColumnName or -1 if not found

get_DisplayValue

protected String get_DisplayValue(String columnName,
                                  boolean currentValue)
Get Display Value of value

Parameters:
columnName - columnName
currentValue - current value
Returns:
String value with "./." as null

copyValues

protected static void copyValues(PO from,
                                 PO to,
                                 int AD_Client_ID,
                                 int AD_Org_ID)
Copy old values of From to new values of To. Does not copy Keys

Parameters:
from - old, existing & unchanged PO
to - new, not saved PO
AD_Client_ID - client
AD_Org_ID - org

copyValues

public static void copyValues(PO from,
                              PO to)
Copy old values of From to new values of To. Does not copy Keys and AD_Client_ID/AD_Org_ID

Parameters:
from - old, existing & unchanged PO
to - new, not saved PO

get_ChangeVO

public ChangeVO get_ChangeVO()
Get Change VO

Returns:
change vo

set_ChangeVO

public void set_ChangeVO(ChangeVO change)
Set Change VO

Parameters:
change - vo

load

public void load(int ID,
                 String trxName)
Load record with ID

Parameters:
ID - ID
trxName - transaction name

load

public boolean load(String trxName)
(re)Load record with m_ID[*]

Parameters:
trxName - transaction
Returns:
true if loaded

load

protected boolean load(ResultSet rs)
Load from the current position of a ResultSet

Parameters:
rs - result set
Returns:
true if loaded

load

public boolean load(Map<String,String> hmIn)
Load from HashMap. Do not use unless you know what you are doing.

Parameters:
hmIn - hash map
Returns:
true if loaded

get_HashMap

protected HashMap<String,String> get_HashMap()
Create HashMap with data as Strings

Returns:
HashMap

getVO

public VO getVO()
Get Object as VO

Returns:

loadSpecial

protected Object loadSpecial(ResultSet rs,
                             int index)
                      throws SQLException
Load Special data (images, ..). To be extended by sub-classes

Parameters:
rs - result set
index - zero based index
Returns:
value value
Throws:
SQLException

loadComplete

protected void loadComplete(boolean success)
Load is complete

Parameters:
success - success To be extended by sub-classes

loadDefaults

protected void loadDefaults()
Load Defaults


setStandardDefaults

protected void setStandardDefaults()
Set Default values. Client, Org, Created/Updated, *By, IsActive


isMandatoryOK

protected boolean isMandatoryOK()
Are all mandatory Fields filled (i.e. can we save)?. Stops at first null mandatory field

Returns:
true if all mandatory fields are ok

setAD_Client_ID

public final void setAD_Client_ID(int AD_Client_ID)
Set AD_Client

Parameters:
AD_Client_ID - client

getAD_Client_ID

public final int getAD_Client_ID()
Get AD_Client

Returns:
AD_Client_ID

setAD_Org_ID

public final void setAD_Org_ID(int AD_Org_ID)
Set AD_Org

Parameters:
AD_Org_ID - org

getAD_Org_ID

public int getAD_Org_ID()
Get AD_Org

Returns:
AD_Org_ID

setClientOrg

public void setClientOrg(int AD_Client_ID,
                         int AD_Org_ID)
Overwrite Client Org if different

Parameters:
AD_Client_ID - client
AD_Org_ID - org

setClientOrg

public void setClientOrg(PO po)
Overwrite Client Org if different

Parameters:
po - persistent object

setIsActive

public final void setIsActive(boolean active)
Set Active

Parameters:
active - active

isActive

public final boolean isActive()
Is Active

Returns:
is active

getCreated

public final Timestamp getCreated()
Get Created

Returns:
created

getUpdated

public final Timestamp getUpdated()
Get Updated

Returns:
updated

getCreatedBy

public final int getCreatedBy()
Get CreatedBy

Returns:
AD_User_ID

getUpdatedBy

public final int getUpdatedBy()
Get UpdatedBy

Returns:
AD_User_ID

setUpdatedBy

protected final void setUpdatedBy(int AD_User_ID)
Set UpdatedBy

Parameters:
AD_User_ID - user

get_EntityType

public String get_EntityType()
Get Entity Type of record

Returns:
entity type or null if none

get_Translation

protected String get_Translation(String columnName,
                                 String AD_Language)
Get Translation of column

Parameters:
columnName -
AD_Language -
Returns:
translation or null if not found

is_new

public boolean is_new()
Is new record

Returns:
true if new

update

public String update(Map<String,String> context)
Update PO based on string context

Parameters:
context - row context
Returns:
error message or null

save

public boolean save()
Update Value or create new record. To reload call load() - not updated

Returns:
true if saved

save

public boolean save(String trxName)
Update Value or create new record. To reload call load() - not updated

Parameters:
trxName - transaction
Returns:
true if saved

is_Changed

public boolean is_Changed()
Is there a Change to be saved?

Returns:
true if record changed

beforeSave

protected boolean beforeSave(boolean newRecord)
Called before Save for Pre-Save Operation

Parameters:
newRecord - new record
Returns:
true if record can be saved

afterSave

protected boolean afterSave(boolean newRecord,
                            boolean success)
Called after Save for Post-Save Operation

Parameters:
newRecord - new record
success - true if save operation was success
Returns:
if save was a success

saveUpdate

protected boolean saveUpdate()
Update Record directly

Returns:
true if updated

saveNewInsertSQL

public boolean saveNewInsertSQL()
Create Insert SQL and execute

Returns:
success

saveNew_getID

protected int saveNew_getID()
Get ID for new record during save. You can overwite this to explicitly set the ID

Returns:
ID to be used or 0 for fedault logic

get_WhereClause

public String get_WhereClause(boolean withValues)
Create Single/Multi Key Where Clause

Parameters:
withValues - if true uses actual values otherwise ?
Returns:
where clause

saveNewSpecial

protected String saveNewSpecial(Object value,
                                int index)
Save Special Data. To be extended by sub-classes

Parameters:
value - value
index - index
Returns:
SQL code for INSERT VALUES clause

delete

public boolean delete(boolean force)
Delete Current Record

Parameters:
force - delete also processed records
Returns:
true if deleted

delete

public boolean delete(boolean force,
                      String trxName)
Delete Current Record

Parameters:
force - delete also processed records
trxName - transaction
Returns:
true if deleted

beforeDelete

protected boolean beforeDelete()
Executed before Delete operation.

Returns:
true if record can be deleted

afterDelete

protected boolean afterDelete(boolean success)
Executed after Delete operation.

Parameters:
success - true if record deleted
Returns:
true if delete is a success

insert_Accounting

protected boolean insert_Accounting(String acctTable,
                                    String acctBaseTable,
                                    String whereClause)
Insert Accounting Records

Parameters:
acctTable - accounting sub table
acctBaseTable - acct table to get data from
whereClause - optional where clause with alisa "p" for acctBaseTable
Returns:
true if records inserted

delete_Accounting

protected boolean delete_Accounting(String acctTable)
Delete Accounting records. NOP - done by database constraints

Parameters:
acctTable - accounting sub table
Returns:
true

lock

public boolean lock()
Lock it.

Returns:
true if locked

unlock

public boolean unlock(String trxName)
UnLock it

Parameters:
trxName - transaction
Returns:
true if unlocked (false only if unlock fails)

set_TrxName

public void set_TrxName(String trxName)
Set Trx

Parameters:
trxName - transaction

get_TrxName

public String get_TrxName()
Get Trx

Returns:
transaction

getAttachment

public MAttachment getAttachment()
Get Attachments. An attachment may have multiple entries

Returns:
Attachment or null

getAttachment

public MAttachment getAttachment(boolean requery)
Get Attachments

Parameters:
requery - requery
Returns:
Attachment or null

createAttachment

public MAttachment createAttachment()
Create/return Attachment for PO. If not exist, create new

Returns:
attachment

isAttachment

public boolean isAttachment(String extension)
Do we have a Attachment of type

Parameters:
extension - extension e.g. .pdf
Returns:
true if there is a attachment of type

getAttachmentData

public byte[] getAttachmentData(String extension)
Get Attachment Data of type

Parameters:
extension - extension e.g. .pdf
Returns:
data or null

isPdfAttachment

public boolean isPdfAttachment()
Do we have a PDF Attachment

Returns:
true if there is a PDF attachment

getPdfAttachment

public byte[] getPdfAttachment()
Get PDF Attachment Data

Returns:
data or null

addAttachment

public boolean addAttachment(URI uri)
Add Attachment to Record

Parameters:
uri - uri reference to be added
Returns:
true if added

addAttachment

public boolean addAttachment(File file)
Add Attachment to Record

Parameters:
file - file to be loaded and added
Returns:
true if added

dump

public void dump()
Dump Record


dump

public void dump(int index)
Dump column

Parameters:
index - index

getAllIDs

public static int[] getAllIDs(String TableName,
                              String WhereClause,
                              String trxName)
Get All IDs of Table. Used for listing all Entities int[] IDs = PO.getAllIDs ("AD_PrintFont", null); for (int i = 0; i < IDs.length; i++) { pf = new MPrintFont(Env.getCtx(), IDs[i]); System.out.println(IDs[i] + " = " + pf.getFont()); }

Parameters:
TableName - table name (key column with _ID)
WhereClause - optional where clause
trxName - transaction
Returns:
array of IDs or null

getFindParameter

protected static String getFindParameter(String query)
Get Find parameter. Convert to upper case and add % at the end

Parameters:
query - in string
Returns:
out string

get_xmlString

public StringBuffer get_xmlString(StringBuffer xml)
Get Object xml (data only) representation as string

Parameters:
xml - optional string buffer
Returns:
updated/new string buffer header is only added once

get_xmlString

public StringBuffer get_xmlString(StringBuffer xml,
                                  boolean dataOnly)
Get Object xml representation as string

Parameters:
xml - optional string buffer
dataOnly - if false, add value, label and info tags
Returns:
updated/new string buffer header is only added once

get_xmlDocument

public Document get_xmlDocument(boolean noComment,
                                boolean dataOnly)
Get XML Document representation

Parameters:
noComment - do not add comment
dataOnly - if false, add value, label and info tags
Returns:
XML document

setContext

protected void setContext(int windowNo,
                          String columnName,
                          String value)
Sets the context in p_changeVO, if p_changeVO is not null

Parameters:
windowNo - window
columnName - column
value - value

addError

protected void addError(String message)
Added the message text to p_changeVO if p_changeVO is not null. The message should have already been translated.

Parameters:
message - error info

Compiere 3.1

Compiere® is a registered trademark of ComPiere, Inc. ©2004-2008 HumanFlash.com All rights reserved.