User Tools

Site Tools


import_a_script_directly_into_ll

**This is an old revision of the document!** ----

A PCRE internal error occured. This might be caused by a faulty plugin

==== External API: Manage Scripts ==== [[https://drive.google.com/folderview?id=0B40xU-30MxN7flhicHg3Y05XMWplMTl3c1RJU0ZuWUZ3emJxZG56RDdma2xpMXVvRmRlaXc&usp=sharing|Download]] the current Version of the Library and drop the .aar file in your projects lib folder (/app/libs) if the folder does not exist, create it. Add this to build.gradle of your apps module: <sxh java;>repositories{ flatDir { dirs 'libs' } } dependencies { compile(name:'name-of-file',ext:'aar') //other dependencies... }</sxh> and replace //name-of-file// with the actual file name (without the extension). Now you can import the class ''com.app.lukas.script.ScriptManager'' in any of your modules files. The ''ScriptManager'' provides two static methods: ''loadScript'' and ''runScript''. Be sure to use as unique names for scripts as possible, because if a script with the same name already exists, it may be overwritten. It may be a good idea to let your script name start with your projects name (e.g. "layoutmanager_save"). **//Hint: This requires the Repository Importer to be installed on the android device. If it is not installed, it will give a prompt to do so.//**

import_a_script_directly_into_ll.1424895304.txt.gz · Last modified: 2015/02/25 20:15 by lm13