Package burp.api.montoya.ui.editor
Interface WebSocketMessageEditor
-
Method Summary
Modifier and TypeMethodDescriptionint
boolean
This will returnOptional.empty()
if the user has not made a selection.void
setContents
(ByteArray contents) This method can be used to set content within the message editor programmaticallyvoid
setSearchExpression
(String expression) Update the search expression that is shown in the search bar below the editor.
-
Method Details
-
getContents
ByteArray getContents()- Returns:
- The contents of the message editor.
-
setContents
This method can be used to set content within the message editor programmatically- Parameters:
contents
- The content to set in the message editor.
-
setSearchExpression
Update the search expression that is shown in the search bar below the editor.- Specified by:
setSearchExpression
in interfaceEditor
- Parameters:
expression
- The search expression.
-
isModified
boolean isModified()- Specified by:
isModified
in interfaceEditor
- Returns:
- True if the user has modified the contents of the editor since the last time the content was set programmatically.
-
caretPosition
int caretPosition()- Specified by:
caretPosition
in interfaceEditor
- Returns:
- The index of the position for the carat within the current message editor.
-
selection
-
uiComponent
Component uiComponent()- Specified by:
uiComponent
in interfaceEditor
- Returns:
- UI component of the editor, for extensions to add to their own UI.
-