Interface ContentType

All Known Implementing Classes:
ContentType.DefinedType

public interface ContentType
Describes the content of a Config in a more technical way. In fact it provides information to determine how the content should be rendered in a editor (e.g. CodeMirror).
Author:
domi
  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Interface
    Description
    static enum 
     
  • Method Summary

    Modifier and Type
    Method
    Description
    The CodeMirror mode as defined in Stapler ( org.kohsuke.stapler.codemirror.mode.*).
    Actually the 'mode' attribute for the CodeMirror editor.
  • Method Details

    • getCmMode

      String getCmMode()
      The CodeMirror mode as defined in Stapler ( org.kohsuke.stapler.codemirror.mode.*).
      Currently Supported:
      • clike
      • css
      • diff
      • haskell
      • htmlmixed
      • javascript
      • lua
      • php
      • plsql
      • python
      • rst
      • smaltalk
      • stex
      • xml
      e.g. used in <textarea name="config.content" codemirror-mode="${contentType.cmMode}" ... />
      Returns:
      the CodeMirror mode
    • getMime

      String getMime()
      Actually the 'mode' attribute for the CodeMirror editor. As in: <textarea name="config.content" codemirror-config="mode:'${contentType.mime}',lineNumbers: true" ... />
      Returns:
      the mime.