Sample AppObject
- Last Updated: July 22, 2025
- 1 minute read
- OpenEdge
- Version 12.2
- Documentation
The following methods comprise the definition of a sample Java AppObject, Account, where each method appears as it is displayed in Java:
- The AppObject constructors that connect to an Application Service.
For example:
public Account(com.progress.open4gl.javaproxy.Connection connectObj) throws Open4GLException, IOException, ConnectException, SystemErrorException public Account(String urlString, String userId, String password, String Info) throws Open4GLException, IOException, ConnectException, SystemErrorException public Account(String userId, String password, String Info) throws Open4GLException, IOException, ConnectException, SystemErrorException public Account() throws Open4GLException, IOException, ConnectException, SystemErrorException - A SubAppObject class factory method that creates a SubAppObject
called
Tax. For example:public Tax createAO_Tax() throws Open4GLException, RunTime4GLException, SystemErrorException - A ProcObject class factory method that creates a ProcObject called
AccountInfoand runs and instantiates the persistent procedureAccountInfo.pon the application server. For example:public AccountInfo createPO_AccountInfo(int accountNum) throws Open4GLException, RunTime4GLException, SystemErrorExceptionIf
AccountInfo.pwere to be run as a single-run or singleton procedure, the parameter in its main block would have to be removed and passed to its internal procedures or user-defined functions directly. The class factory method would then look like this:public AccountInfo createPO_AccountInfo() throws Open4GLException, RunTime4GLException, SystemErrorExceptionSee the Sample ProcObject for an example of how the methods for the internal procedures and user-defined functions of might look if
AccountInfo.pwere called as a single-run or singleton procedure. - Built-in class factory methods that run and instantiate a SmartDataObject
on the application server. For example:
public SDOResultSet _createSDOResultSet(String procName) throws Open4GLException, ProSQLException public SDOResultSet _createSDOResultSet(String procName, String whereClause, String sortBy) throws Open4GLException, ProSQLException public SDOResultSet _createSDOResultSet(String procName, String whereClause, String sortBy, SDOPameters params) throws Open4GLException, ProSQLException - Remote ABL methods to run the non-persistent procedures
Add(defined byAdd.p) andRemove(defined byRemove.p) on the application server. For example:public void Add(int accountNum, String name) public void Remove(int accountNum) - Common methods in all Java proxy objects. For example:
public void _cancelAllRequests() throws Open4GLException public String _getConnectionId() throws Open4GLException public String _getProcReturnString() public boolean _isStreaming() throws Open4GLException public String _getRequestId() throws Open4GLException public String _getSSLSubjectName() throws Open4GLException public void _release()