可以根据条件制作编辑器模板

时间:2012-08-30 13:42:19

标签: eclipse

我正在寻找制作编辑器模板的可能性,如果存在,则会生成$ {enclosing_method_arguments}的索引。

我当前的方法体模板:

log.debug("Begin -- ${return_type} ${enclosing_method}(${enclosing_method_arguments}");

结果如下:

public File chooseFile(final String text, final String fileName)
  {
    log.debug("Begin -- File chooseFile(text, fileName");
    return null;
  }

但我喜欢的是这样的:

  public File chooseFile(final String text, final String fileName)
  {
    log.debug("Begin -- File chooseFile({0},{1})",text, fileName);
    return null;
  }

0 个答案:

没有答案