Skip to main content
Skip table of contents

Entity Generation (Android)

To create entity generation Android packages
  1. Create a folder named decode in the main source folder.



  2. Within the decode folder, create subfolders for each of the objects required by your application.
    The subfolders should be named according to the schema library structure, shown below:



  3. The JSON definition files representing your Android classes should be exported from Cantara Server. For information about the procedure to generate the export files, refer to Exporting a Function and Exporting a Query.

    After export, the JSON definition files for entity generation can be modified by the developer.
    For information about the file format, refer to JSON Definition Files for Entity Generation.

  4. Add the entity definition JSON files to the appropriate decode subfolder.
To generate entity classes based on the JSON definition files
  1. Open the Run/Debug Configurations window:




  2. Click on the + button  and select Gradle from the drop down list to create a new gradle configuration




  3. Give the configuration an appropriate name eg: apply_decode
  4. Select Gradle project:



  5. Add the appropriate decode task in the Tasks field. Usually decodeDebug or decode{flavor_name}Debug




  6. Apply changes, and run the gradle configuration.
  7. The generated classes will be created in your project:






JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.