Class CustomEditor

java.lang.Object
io.bdeploy.api.plugin.v1.CustomEditor

public class CustomEditor extends Object
Describes a custom editor plugin. A custom editor is a ES6 module loaded into the frontend.

The module must be hosted by a PluginAssets. The module path is specified as path relative to the plugins namespace root.

Each CustomEditor handles a custom editor 'type'. This may be annotated on parameters in app-info.yaml files of applications. If BDeploy finds a CustomEditor with a matching getTypeName(), this custom editor will be loaded on demand in the Web UI and used instead of the built-in editor.

  • Constructor Details

    • CustomEditor

      public CustomEditor(String modulePath, String typeName, boolean allowDirectEdit)
      Parameters:
      modulePath - the relative path to the plugins ES6 module file. Must be hosted by a PluginAssets in the same plugin.
      typeName - the type name of the editor. This is a custom string which is defined by the plugin. app-info.yaml maintainers can use this type name to request usage of this plugins CustomEditor.
      allowDirectEdit - whether direct/manual editing of the raw value should still be permitted.
  • Method Details

    • getModulePath

      public String getModulePath()
      Returns:
      the path to the ES6 module
    • getTypeName

      public String getTypeName()
      Returns:
      the unique type name of this CustomEditor.
    • isAllowDirectEdit

      public boolean isAllowDirectEdit()
      Returns:
      whether direct editing is still allowed even though the plugin was loaded.