A Codenameone library for gaining access to native device system logs
Currently only Android is supported. Contributions are welcome!
- Download the project onto your machine, into a directory separate from your cn1 project
- Build the project in NetBeans
- Copy the .jar file that has now appeared in the dist directory to the lib directory in your cn1 project
- Right-click on the cn1 project and select Codename One > Refresh cn1lib files
There's only one method, and it's static. It has two different signatures, with no arguments or setting the number of lines you want to return from the system error logs. The default is 150.
String log = SystemLogsUtil.getSysErrorLogs();
String log = SystemLogsUtil.getSysErrorLogs(250);