Javascript-0.10.0
Total Page:16
File Type:pdf, Size:1020Kb
MicroEJ Documentation MicroEJ Corp. Revision f8637e2f Jun 23, 2021 Copyright 2008-2020, MicroEJ Corp. Content in this space is free for read and redistribute. Except if otherwise stated, modification is subject to MicroEJ Corp prior approval. MicroEJ is a trademark of MicroEJ Corp. All other trademarks and copyrights are the property of their respective owners. CONTENTS 1 MicroEJ Glossary 2 2 Overview 4 2.1 MicroEJ Editions.............................................4 2.1.1 Introduction..........................................4 2.1.2 Determine the MicroEJ Studio/SDK Version..........................5 2.2 Licenses.................................................7 2.2.1 License Manager Overview...................................7 2.2.2 Evaluation Licenses......................................7 2.2.3 Production Licenses...................................... 10 2.3 MicroEJ Runtime............................................. 15 2.3.1 Language............................................ 15 2.3.2 Scheduler............................................ 15 2.3.3 Garbage Collector....................................... 15 2.3.4 Foundation Libraries...................................... 15 2.4 MicroEJ Libraries............................................ 16 2.5 MicroEJ Central Repository....................................... 16 2.5.1 Introduction.......................................... 16 2.5.2 Use............................................... 17 2.5.3 Content Organization..................................... 17 2.5.4 Javadoc............................................. 17 2.6 Embedded Specification Requests................................... 17 2.7 MicroEJ Firmware............................................ 17 2.7.1 Bootable Binary with Core Services.............................. 17 2.7.2 Specification.......................................... 18 2.8 MicroEJ SDK............................................... 18 2.8.1 Release Notes.......................................... 19 2.8.2 MicroEJ SDK Distribution Changelog............................. 19 2.8.3 MicroEJ SDK Changelog.................................... 21 2.8.4 Advanced Installation Notes.................................. 31 2.8.5 Migration Notes......................................... 31 2.9 Introducing MicroEJ Studio and Virtual Devices............................ 34 2.10 Perform Online Getting Started..................................... 35 2.11 GitHub Repositories........................................... 36 2.12 System Requirements.......................................... 41 2.13 Get Support............................................... 42 3 Application Developer Guide 43 3.1 Introduction............................................... 43 3.2 Local Workspaces and Repositories................................... 43 i 3.3 Standalone Application......................................... 44 3.3.1 MicroEJ Platform Import.................................... 44 3.3.2 Build and Run an Application................................. 47 3.3.3 Build Output Files....................................... 52 3.3.4 MicroEJ Launch......................................... 53 3.3.5 Application Options...................................... 57 3.3.6 SOAR.............................................. 84 3.4 Sandboxed Application......................................... 85 3.4.1 Sandboxed Application Structure............................... 85 3.4.2 Application Publication.................................... 86 3.4.3 Shared Interfaces........................................ 86 3.5 Virtual Device.............................................. 90 3.5.1 Using a Virtual Device for Simulation............................. 90 3.5.2 Runtime Environment..................................... 90 3.6 MicroEJ Module Manager........................................ 91 3.6.1 Introduction.......................................... 91 3.6.2 Specification.......................................... 92 3.6.3 Module Project Skeleton.................................... 92 3.6.4 Module Description File.................................... 93 3.6.5 MicroEJ Module Manager Configuration........................... 95 3.6.6 Module Build.......................................... 99 3.6.7 Build Kit............................................. 100 3.6.8 Command Line Interface.................................... 101 3.6.9 Troubleshooting........................................ 105 3.6.10 Meta Build........................................... 108 3.6.11 Former MicroEJ SDK Versions (lower than 5.2.0)....................... 109 3.6.12 Former MicroEJ SDK Versions (from 5.2.0 to 5.3.x)...................... 111 3.7 Module Natures............................................. 111 3.7.1 Add-On Library......................................... 111 3.7.2 Add-On Processor....................................... 112 3.7.3 Foundation Library API..................................... 112 3.7.4 Foundation Library Implementation............................. 112 3.7.5 Meta Build........................................... 113 3.7.6 Mock.............................................. 113 3.7.7 Module Repository....................................... 113 3.7.8 Sandboxed Application.................................... 114 3.7.9 Standalone Application.................................... 115 3.7.10 Natures Plugins......................................... 115 3.8 Module Repository............................................ 120 3.8.1 Create a Repository Project.................................. 122 3.8.2 Configure Resolver for Input Modules............................. 122 3.8.3 Configure Consistency Check................................. 122 3.8.4 Advanced Options....................................... 122 3.8.5 Include Modules........................................ 122 3.8.6 Build the Repository...................................... 124 3.8.7 Use the Oline Repository................................... 124 3.9 MicroEJ Classpath............................................ 124 3.9.1 Application Classpath..................................... 125 3.9.2 Classpath Load Model..................................... 125 3.9.3 Classpath Elements...................................... 126 3.10 Application Resources.......................................... 129 3.10.1 Images............................................. 129 3.10.2 Fonts.............................................. 130 3.10.3 Native Language Support................................... 131 ii 3.11 Platform Selection............................................ 132 3.12 Development Tools........................................... 133 3.12.1 Test Suite with JUnit...................................... 134 3.12.2 Stack Trace Reader....................................... 138 3.12.3 Code Coverage Analyzer.................................... 151 3.12.4 Heap Dumper & Heap Analyzer................................ 154 3.12.5 ELF to Map File Generator................................... 165 3.12.6 Serial to Socket Transmitter.................................. 167 3.12.7 Memory Map Analyzer..................................... 168 3.12.8 Event Tracing.......................................... 171 3.12.9 Null Analysis.......................................... 173 3.13 Advanced Tools............................................. 180 3.13.1 MicroEJ Linker......................................... 180 3.13.2 MicroEJ Test Suite Engine................................... 192 3.14 Graphical User Interface......................................... 198 3.14.1 MicroUI............................................. 199 3.14.2 MWT (Micro Widget Toolkit).................................. 230 3.14.3 Widgets and Examples..................................... 246 3.15 Limitations................................................ 249 3.16 JavaScript................................................ 249 3.16.1 Getting started......................................... 250 3.16.2 Sources Management..................................... 251 3.16.3 Examples............................................ 252 3.16.4 Communication between Java and JS............................ 256 3.16.5 Tests............................................... 257 3.16.6 Limitations........................................... 258 3.16.7 Built-in objects......................................... 259 3.16.8 Troubleshooting........................................ 263 3.16.9 Internals............................................ 264 4 Platform Developer Guide 267 4.1 Introduction............................................... 267 4.1.1 Scope.............................................. 267 4.1.2 Intended Audience....................................... 267 4.2 MicroEJ Platform............................................ 267 4.2.1 Introduction.......................................... 267 4.2.2 Build Process.......................................... 268 4.2.3 Concepts............................................ 269 4.3 MicroEJ Architecture........................................... 274 4.3.1 Naming Convention...................................... 275 4.3.2 MicroEJ Architectures Changelog............................... 276 4.4 MicroEJ Packs.............................................. 295 4.4.1 Overview............................................ 295 4.4.2 Naming Convention...................................... 295 4.5 Platform Creation............................................ 296 4.5.1 MicroEJ Architecture Import.................................. 296 4.5.2 MicroEJ Pack Import.....................................