@API(type=NOT_EXTENDABLE,
src=PUBLIC)
public interface ContentCompletionManager
Modifier and Type | Method and Description |
---|---|
void |
executeInsert(CCItemProxy ccItem,
AuthorSelectionAndCaretModel selectionModel)
Executes the insert element action.
|
void |
executeInsertInvalid(CCItemProxy ccItem,
AuthorSelectionAndCaretModel selectionModel)
Inserts an element from content completion which is invalid at the caret position.
|
void |
executeNewLine(AuthorSelectionAndCaretModel selectionModel)
Executes a new line insertion.
|
void |
executeRename(AuthorSelectionAndCaretModel selectionModel,
CCItemProxy ccItem)
Executes the rename operation.
|
void |
executeSplit(CCItemProxy ccItem,
AuthorSelectionAndCaretModel selectionModel)
Splits the element chosen by the user.
|
void |
executeSurround(CCItemProxy ccItem,
AuthorSelectionAndCaretModel selectionModel)
Surrounds the current selection with an element that has the specified
render string and type as chosen by the user/
|
java.util.List<CCItemProxy> |
getAllPossibleElementsForInsert()
Returns all possible elements defined by the schema, including those that are not valid
to be inserted at the caret position.
|
CCItemProxy |
getNewLineProposal(AuthorSelectionAndCaretModel selectionModel)
If the selection/caret is inside a space preserve content it will return a
proposal for inserting a new line.
|
java.util.List<CCItemProxy> |
getProposedElementsForInsert(AuthorSelectionAndCaretModel selectionModel)
Returns the proposals for element insertions at the current offset.
|
java.util.List<CCItemProxy> |
getProposedElementsForRename(AuthorSelectionAndCaretModel selectionModel)
Returns the proposals for renaming.
|
java.util.List<CCItemProxy> |
getProposedElementsForSurround(AuthorSelectionAndCaretModel selectionModel)
Returns the proposals for a tag to surround the current selection with.
|
java.util.List<CCItemProxy> |
getProposedElementsToSplit(AuthorSelectionAndCaretModel selectionModel)
Returns the block elements around the caret position that can be split.
|
java.util.List<CCItemProxy> getProposedElementsForInsert(AuthorSelectionAndCaretModel selectionModel) throws javax.swing.text.BadLocationException
selectionModel
- The selection and caret model of the document.javax.swing.text.BadLocationException
java.util.List<CCItemProxy> getAllPossibleElementsForInsert()
void executeInsert(CCItemProxy ccItem, AuthorSelectionAndCaretModel selectionModel) throws javax.swing.text.BadLocationException, ItemNotFoundException
ccItem
- The content completion item chosen by the user.selectionModel
- The selection and caret model of the document.javax.swing.text.BadLocationException
ItemNotFoundException
java.util.List<CCItemProxy> getProposedElementsForRename(AuthorSelectionAndCaretModel selectionModel) throws javax.swing.text.BadLocationException
selectionModel
- The selection and caret model of the document.
The selection should be either collapsed, or an entire element should be
selected.javax.swing.text.BadLocationException
- If the selection does not comply with the
restrictions above.void executeRename(AuthorSelectionAndCaretModel selectionModel, CCItemProxy ccItem) throws javax.swing.text.BadLocationException
selectionModel
- The selection and caret model of the document.ccItem
- The content completion item chosen for rename.javax.swing.text.BadLocationException
void executeNewLine(AuthorSelectionAndCaretModel selectionModel) throws javax.swing.text.BadLocationException
selectionModel
- The selection and caret model of the document.javax.swing.text.BadLocationException
java.util.List<CCItemProxy> getProposedElementsForSurround(AuthorSelectionAndCaretModel selectionModel) throws javax.swing.text.BadLocationException
selectionModel
- The selection and caret model of the document.javax.swing.text.BadLocationException
void executeSurround(CCItemProxy ccItem, AuthorSelectionAndCaretModel selectionModel) throws javax.swing.text.BadLocationException, ItemNotFoundException
ccItem
- The content completion item chosen by the user.selectionModel
- The selection and caret model of the document.javax.swing.text.BadLocationException
ItemNotFoundException
java.util.List<CCItemProxy> getProposedElementsToSplit(AuthorSelectionAndCaretModel selectionModel) throws javax.swing.text.BadLocationException
selectionModel
- The selection and caret model of the document.javax.swing.text.BadLocationException
void executeSplit(CCItemProxy ccItem, AuthorSelectionAndCaretModel selectionModel) throws javax.swing.text.BadLocationException, ItemNotFoundException
ccItem
- The element chosen by the user.selectionModel
- The selection model of the document.javax.swing.text.BadLocationException
ItemNotFoundException
CCItemProxy getNewLineProposal(AuthorSelectionAndCaretModel selectionModel) throws javax.swing.text.BadLocationException
selectionModel
- Selection and caret model.null
if the caret is
not in a space preserve context.javax.swing.text.BadLocationException
- Bad offsets.void executeInsertInvalid(CCItemProxy ccItem, AuthorSelectionAndCaretModel selectionModel) throws javax.swing.text.BadLocationException, ItemNotFoundException
ccItem
- The selected element.selectionModel
- The selection.javax.swing.text.BadLocationException
ItemNotFoundException
© Copyright SyncRO Soft SRL 2002 - 2016. All rights reserved.