-
Notifications
You must be signed in to change notification settings - Fork 28
Package Plugin
A package plugin is a directory below the project's plugins/
directory.
The name of that directory is the plugin's name (as far as Espresso is concerned).
This directory usually contains the plugin's native code and it's web resources.
A minimal Android plugin's file system hierarchy might look like this:
plugins/MyPlugin/src/com/test/MyPlugin.java
plugins/MyPlugin/assets/MyPlugin.js
The corresponding "plugins"
-property of the project's [[config.json]]
-file could look like this:
"plugins": {
"com.test.MyPlugin": "MyPlugin"
}
Web resources are JavaScript code, HTML code, images, and so on.
They have to reside below the plugin's assets/
directory.
Native code has to reside below the plugin's src/
directory.
For iOS the native code consists of the plugin's .h
, .cpp
, and .mm
files.
For Android the native code consists of the plugin's .java
files.
The src/
-directory will be used as Java class path.
See also understanding the class path and package names
to unterstand how java classes are mapped to directories.
Currently the name of the plugin has to be the same as the name of the plugin's class name.
I.e. if you have a plugin with the (fully qualified) class name com.test.MyPlugin
, then the plugin
has to reside plugin has to be found below plugins/MyPlugin/
.