Class EditorUtils
- java.lang.Object
-
- edu.uiuc.ncsa.security.util.cli.editing.EditorUtils
-
public class EditorUtils extends Object
Created by Jeff Gaynor
on 3/17/21 at 6:47 AM
-
-
Field Summary
Fields Modifier and Type Field Description static String
EDITOR_ARG_CONNECTOR_ATTR
static String
EDITOR_ARG_FLAG_ATTR
static String
EDITOR_ARG_TAG
static String
EDITOR_ARG_VALUE_ATTR
static String
EDITOR_CLEAR_SCREEN_ATTR
static String
EDITOR_EXEC_ATTR
static String
EDITOR_NAME_ATTR
static int
EDITOR_RC_ERROR
static int
EDITOR_RC_OK
static String
EDITOR_TAG
static String
EDITORS_TAG
-
Constructor Summary
Constructors Constructor Description EditorUtils()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static int
editFile(EditorEntry editorEntry, File targetFile)
Edits a file.static Editors
getEditors(org.apache.commons.configuration.tree.ConfigurationNode cn)
protected static void
say(String x)
static void
updateEditors(Editors editors, InputLine inputLine)
Facility for updating the editors.
-
-
-
Field Detail
-
EDITORS_TAG
public static final String EDITORS_TAG
- See Also:
- Constant Field Values
-
EDITOR_TAG
public static final String EDITOR_TAG
- See Also:
- Constant Field Values
-
EDITOR_ARG_TAG
public static final String EDITOR_ARG_TAG
- See Also:
- Constant Field Values
-
EDITOR_NAME_ATTR
public static final String EDITOR_NAME_ATTR
- See Also:
- Constant Field Values
-
EDITOR_EXEC_ATTR
public static final String EDITOR_EXEC_ATTR
- See Also:
- Constant Field Values
-
EDITOR_CLEAR_SCREEN_ATTR
public static final String EDITOR_CLEAR_SCREEN_ATTR
- See Also:
- Constant Field Values
-
EDITOR_ARG_FLAG_ATTR
public static final String EDITOR_ARG_FLAG_ATTR
- See Also:
- Constant Field Values
-
EDITOR_ARG_CONNECTOR_ATTR
public static final String EDITOR_ARG_CONNECTOR_ATTR
- See Also:
- Constant Field Values
-
EDITOR_ARG_VALUE_ATTR
public static final String EDITOR_ARG_VALUE_ATTR
- See Also:
- Constant Field Values
-
EDITOR_RC_OK
public static final int EDITOR_RC_OK
- See Also:
- Constant Field Values
-
EDITOR_RC_ERROR
public static final int EDITOR_RC_ERROR
- See Also:
- Constant Field Values
-
-
Method Detail
-
getEditors
public static Editors getEditors(org.apache.commons.configuration.tree.ConfigurationNode cn)
-
say
protected static void say(String x)
-
updateEditors
public static void updateEditors(Editors editors, InputLine inputLine)
Facility for updating the editors. (Under construction -- issue is that each CLI has very specialized needs, so a general facility just might not work).- Parameters:
editors
-inputLine
-
-
editFile
public static int editFile(EditorEntry editorEntry, File targetFile)
Edits a file. Return code isEDITOR_RC_OK
if everything worked andEDITOR_RC_ERROR
if not.- Parameters:
editorEntry
-targetFile
-- Returns:
-
-