EditLive!'s Advanced API and plugin functionality is only supported with an EditLive! Enterprise Edition license.

This article provides developers with an understanding of how the Advanced APIs for EditLive! operate. This article also details the basic steps required by developers to extend the core functionality of an EditLive! applet by creating Java classes that utilize the Advanced APIs. 

How the Advanced APIs Work

To load an instance of EditLive! in a webpage, developers use the Load Time Methods and a Configuration File. The Advanced APIs allow developers to then create a Java class that is passed to an instance of the EditLive! applet with all the properties defined in the above mentioned Load Time Methods and the Configuration File. This developer-designed Java class can then be used to access the properties of the EditLive! applet and specify additional functionality for the applet.

Coding with the Advanced APIs

In order to use the Advanced APIs to extend the functionality of EditLive!, developers must create their own Java class. This Java class needs to utilize the Tiny Java APIs in order to access the properties of the EditLive! applet.

Java classes created to use the Advanced APIs need to adhere to the following properties:

The following packages are required to use the Tiny Java APIs:

import com.ephox.editlive.*;
import com.ephox.editlive.common.*;
  • Ensure the Java class' constructor has only one parameter: An instance of ELJBean.

The ELJBean class is the Java representation of the EditLive! applet. All the information specified in applet's Load Time Properties and Configuration File are passed to the ELJBean class. This allows developers to not only specify additional functionality for the EditLive! applet, but also access the current properties of the EditLive! applet as well. For information on how to interact with the ELJBean class see the Tiny Java APIs.

Example
The following example shows how to specify a Java class called AdvancedAPITest that can utilize the Advanced APIs.

public class AdvancedAPITest {
   ELJBean _bean;
 
   public AdvancedAPITest(ELJBean bean) {
      _bean = bean;
 
      // perform actions on _bean using Tiny Java APIs
   }
}

For information on how to compile and run Java classes utilizing the Advanced APIs, see the Compiling and Running the Advanced APIs article.

See Also