Class SimpleCallout
- java.lang.Object
-
- org.openbravo.erpCommon.ad_callouts.DelegateConnectionProvider
-
- org.openbravo.erpCommon.ad_callouts.SimpleCallout
-
- All Implemented Interfaces:
ConnectionProvider
- Direct Known Subclasses:
AUM_ConversionRate
,BackgroundProcessClusterConfig
,CheckOptionalFilterCallout
,EmailConfiguration_Port
,EmptyCallout
,GridConfigurationSequenceNumberCallout
,GtinFormat
,JavaPackageChecker
,JSExecuteCalloutExample
,JSExpressionCallout
,MetadataOnTab
,Multiphase_dates
,OperativeQuantity_To_BaseQuantity
,SE_Amount_Transaction
,SE_CalculateExchangeRate
,SE_DimensionDocBaseType
,SE_DoubtfulDebt_Method
,SE_ElementValue_AccountSign
,SE_Expense_Amount
,SE_Expense_BP_Project
,SE_Expense_Product
,SE_ExternalPOS_BPartner
,SE_FinancialAccount_BSAccounts
,SE_GLItem_Transaction
,SE_InOut_DocType
,SE_InOut_Organization
,SE_InOut_Warehouse
,SE_Invoice_AccountingDate
,SE_Invoice_BPartner
,SE_Invoice_BPartnerLocation
,SE_Invoice_Organization
,SE_Invoice_Project
,SE_Invoice_TaxDate
,SE_Locator_Activate
,SE_Order_BPartner
,SE_Order_BPartnerLocation
,SE_Order_Organization
,SE_Order_Project
,SE_Organization_NotTaxDeductable
,SE_Payment_BPartner
,SE_Payment_FinAccount
,SE_Payment_MultiCurrency
,SE_Payment_Transaction
,SE_PaymentMethod
,SE_PaymentMethod_FinAccount
,SE_Period_Control
,SE_PeriodNo
,SE_Pricelist_Active
,SE_Project_BPartner
,SE_ProjectLine_Value
,SE_Proposal_BPartner
,SE_RefInventory_RefInvType
,SE_Sales_Pricelist
,SE_StatementDate_Transaction
,SE_Supplier_BPartner
,SE_Taxes_Active
,SE_TaxRate_Withholding
,SE_Trxtype_Transaction
,SelectorFieldPropertyCallout
,SL_AdvPayment_Document
,SL_AlertRule_SQL
,SL_Asset_Product
,SL_Assets
,SL_BankDebt_Amount
,SL_BankStmt_Amount
,SL_BP_Category_Default
,SL_BPartnerLocation
,SL_Budget_Product
,SL_CashJournal_Amounts
,SL_CCPMeasure_Group
,SL_Charge
,SL_Column
,SL_Commission_ListDetails
,SL_Conversion_Rate
,SL_CostAdjustment_DocType
,SL_CostcenterEmployee_SalaryCategory
,SL_Costing_Currency
,SL_CostingRule_FixBackdated
,SL_Currency_StdPrecision
,SL_Depreciate
,SL_GlobalUse_Conversion
,SL_GlobalUse_Product
,SL_InOut_AccountingDate
,SL_InOut_BPartner
,SL_InOut_Conversion
,SL_InOutLine_Product
,SL_Internal_Consumption_Conversion
,SL_Internal_Consumption_Product
,SL_InvAmtUpd_AmtUnitCost
,SL_InvAmtUpd_DocType
,SL_InvAmtUpd_ProductRefDate
,SL_Inventory_Conversion
,SL_Inventory_Locator
,SL_Inventory_Product
,SL_Invoice_Amt
,SL_Invoice_Charge_Tax
,SL_Invoice_Conversion
,SL_Invoice_DocType
,SL_Invoice_Glitem
,SL_Invoice_PriceList
,SL_Invoice_Product
,SL_InvoiceTax_Amt
,SL_IsDefault
,SL_Journal_MultiAcctSchema
,SL_Journal_Period
,SL_JournalLineAmt
,SL_LandedCost_Cost_Type
,SL_LandedCost_DocType
,SL_LandedCost_InvoiceLine
,SL_LandedCost_Receipt
,SL_LegalEntity_Acct
,SL_MachineCost
,SL_Module_Minor_Version
,SL_ModuleCallout
,SL_Movement_Conversion
,SL_Movement_Product
,SL_Order_Amt
,SL_Order_Charge_Tax
,SL_Order_Conversion
,SL_Order_DocType
,SL_Order_PriceList
,SL_Order_Product
,SL_Order_Tax
,SL_Order_UpdateLinesDate
,SL_Organization_Info
,SL_PC_Case_Product
,SL_Preference
,SL_Product_Type
,SL_ProductCh_Characteristic
,SL_Production_Conversion
,SL_Production_Product
,SL_ProductionPlan_Conversion
,SL_ProductionPlan_WRPhase
,SL_ProductionPlan_WRPhase_Quantity
,SL_ProductPrice_PriceListVersion
,SL_Project_Margin
,SL_Project_Planned
,SL_Project_PriceList
,SL_Project_Service
,SL_Project_Type
,SL_Proposal_Product
,SL_RefreshSequenceAndLength
,SL_Requisition_BPartner
,SL_Requisition_BPartner_PriceList
,SL_RequisitionLine_Amt
,SL_RequisitionLine_Conversion
,SL_RequisitionLine_Product
,SL_RequisitionOrder_Order
,SL_Reservation
,SL_ScheduledMaintenance_Maintenance
,SL_SequenceProduct_Conversion
,SL_SequenceProduct_Product
,SL_SequenceProduct_Product_Attribute
,SL_StatusFieldDefaults
,SL_TableAudit
,SL_TableTab
,SL_TaxCategory_Org
,SL_User_Name
,SL_WorkRequirement_Conversion
,SL_WorkRequirement_ProcessPlan
,SL_WorkRequirement_StartDate
,SL_WRPhase_Sequence
,SL_WRPhaseProduct_Product
,SL_Year_Validation
,SysInfoCustomAllowed
public abstract class SimpleCallout extends DelegateConnectionProvider
This class is used to implement Openbravo ERP servlet callouts in a simple manner.To develop a new servlet callout based on this class you only have to create a new java class that extends the method:
protected void execute(CalloutInfo info) throws ServletException;
In this method you can develop the logic of the callout and use the info object of class
SimpleCallout.CalloutInfo
to access window fields, database and other methods- Author:
- aro
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description protected static class
SimpleCallout.CalloutInfo
Helper class that contains all data to access callout information and servlet information
-
Field Summary
-
Fields inherited from class org.openbravo.erpCommon.ad_callouts.DelegateConnectionProvider
log4j, myPool
-
-
Constructor Summary
Constructors Constructor Description SimpleCallout()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description protected abstract void
execute(SimpleCallout.CalloutInfo info)
Overwrite this method to implement a new servlet callout based inSimlpleCallout
org.codehaus.jettison.json.JSONObject
executeSimpleCallout(RequestContext request)
This method execute the SimpleCallout operations.void
init(CalloutServletConfig config)
-
Methods inherited from class org.openbravo.erpCommon.ad_callouts.DelegateConnectionProvider
destroy, getCallableStatement, getCallableStatement, getCallableStatement, getConnection, getPreparedStatement, getPreparedStatement, getPreparedStatement, getRDBMS, getStatement, getStatement, getStatement, getStatus, getTransactionConnection, releaseCallableStatement, releaseCommitConnection, releasePreparedStatement, releaseRollbackConnection, releaseStatement, releaseTransactionalPreparedStatement, releaseTransactionalStatement
-
-
-
-
Method Detail
-
execute
protected abstract void execute(SimpleCallout.CalloutInfo info) throws javax.servlet.ServletException
Overwrite this method to implement a new servlet callout based inSimlpleCallout
- Parameters:
info
- TheCalloutInfo
that contains all helper data to access callout information and servlet information- Throws:
javax.servlet.ServletException
-
init
public void init(CalloutServletConfig config)
- Overrides:
init
in classDelegateConnectionProvider
-
executeSimpleCallout
public org.codehaus.jettison.json.JSONObject executeSimpleCallout(RequestContext request) throws javax.servlet.ServletException, org.codehaus.jettison.json.JSONException
This method execute the SimpleCallout operations.- Returns:
- JSONObject with the values updated by the SimpleCallout.
- Throws:
javax.servlet.ServletException
org.codehaus.jettison.json.JSONException
-
-