Generate object API code containing mobile business object (MBO) references, which allows you to use APIs to develop device applications for various mobile devices.
From | Action |
---|---|
The Mobile Application Diagram | Right-click within the Mobile Application Diagram and select Generate Code. |
WorkSpace Navigator | Right-click the Mobile Application project folder that contains the mobile objects for which you are generating API code, and select Generate Code. |
Option | Description |
---|---|
Language | Choose the language used for developing the client applications:
|
Platform | Select the platform ( target device) from the drop-down list for which the device client code is intended. The platform is dependent on the language selected.
|
SAP Mobile Server | Specify a default SAP Mobile Server connection profile to which the generated code connects at runtime. |
Server domain | Choose the domain to which the generated code will connect. If you specified an SAP Mobile Server to which you previously connected successfully, the first domain in the list is chosen by default. You can enter a different domain manually. Note: This field is only enabled when an SAP Mobile Server is selected.
|
Page size | (Optional) Select the page size for the generated client
code. The page size field is filled either with the
recommended values if this is the very first invocation
(based on the selected MBO's attributes), or the value
saved from the previous code generation invocation. In
cases where the page size is smaller then the
recommended size, the code generation wizard shows the
warning:
Page size is smaller than the maximum business object size, which may cause synchronization failureand you must chose a larger page size to avoid a runtime errror. The page size should be larger than the sum of all attribute lengths for any MBO that is included with all the MBOs selected, and must be valid for the database. If the page size is changed, but does not meet these guidelines, object queries that use string or binary attributes with a WHERE clause may fail. Note: This field is only enabled when an
SAP Mobile Server is selected.
|
Package, Namespace, or Name Prefix |
|
Destination | Specify the destination
of the generated device client files. Enter (or Browse) to either a
Project path
(Mobile Application project) location or File system path location.
Select Clean up destination
before code generation to clean up the
destination folder before generating the device client
files. Note: If you select Java as the
language, enter a project path, specify a mobile
application project folder, and select Generated Code as the
destination. JAR files are automatically added to the
destination for the platform that supports compiling of
the generated client code.
|
Third-party jar file | Enter or browse to the location of the third party jar file. For example, net_rim_api.jar for BlackBerry, or android.jar for Android. If you select Java as the language, and if the BlackBerry or Android third-party JAR file has not been added, the warning The dependent third-party class 'net.rim.device.api.system.ApplicationDescriptor' cannot be found or The dependent third-party class 'android.content.Context' cannot be found displays. |