|
org.netbeans.modules.editor.codetemplates/1 1.2.22 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface CodeTemplateProcessor
Fills in default values of the code template's parameters and may react
to user's typing modifications of the parameters.
Each processor is associated with CodeTemplateInsertRequest
which was given to it during construction by CodeTemplateProcessorFactory
.
CodeTemplateProcessorFactory
Method Summary | |
---|---|
void |
parameterValueChanged(CodeTemplateParameter masterParameter,
boolean typingChange)
Notification that a master parameter's value has been modified by the user and the processor may need to react to it. |
void |
release()
Notify the processor that the insert request which it services was already completed and there is no more work to do. |
void |
updateDefaultValues()
Update the values of the parameters in the parsed code template before the code template gets physically inserted into the document. |
Method Detail |
---|
void updateDefaultValues()
CodeTemplateInsertRequest.getMasterParameters()
to find the master parameters.
CodeTemplateParameter.setValue(String)
can be called. The value will be propagated to all slave parameters
automatically.
void parameterValueChanged(CodeTemplateParameter masterParameter, boolean typingChange)
CodeTemplateInsertRequest.isInserted()
returns true.
The processor is only allowed to change master parameters.
Slave parameter's changes are not notified at all.
masterParameter
- master parameter that was changed.typingChange
- allows to react to user's typing immediately
or only react once the active parameter gets changed e.g. by TAB.
true
is passed if the parameter value was modified
by user's typing. Some processors may want such immediate reaction.
false
which happens when
at least one typing change occurred in the current active parameter
and the active parameter is being changed by TAB
or Shift-TAB or Enter.void release()
|
org.netbeans.modules.editor.codetemplates/1 1.2.22 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |