加入收藏 | 设为首页 | 会员中心 | 我要投稿 李大同 (https://www.lidatong.com.cn/)- 科技、建站、经验、云计算、5G、大数据,站长网!
当前位置: 首页 > 编程开发 > Java > 正文

java – 如何在Netbeans 7.1.2中设置${user}的值?

发布时间:2020-12-14 05:57:27 所属栏目:Java 来源:网络整理
导读:我想在Netbeans中替换${user}的默认值.帮助文件说 To define a parameter: In the IDE’s menu bar,choose Tools Templates. The Template Manager opens. Expand the Other category. Double-click on Properties. The User.properties file opens in the e
我想在Netbeans中替换${user}的默认值.帮助文件说

To define a parameter:

  1. In the IDE’s menu bar,choose Tools > Templates. The Template Manager opens.

  2. Expand the Other category. Double-click on Properties. The User.properties file opens in the editor.

  3. Define a parameter. For example,define the ${user} parameter for adding your name to templates you create. The syntax is ‘user=LorumIpsum@mycompany.com’. When a code template is expanded,all occurrences of ${user} in that template are replaced with ‘LorumIpsum@mycompany.com’.

  4. Add as many additional parameters as you want,with the syntax name=value.

在步骤2中,双击“属性”不执行任何操作.我尝试在编辑器中打开“属性”模板并添加“用户”属性.我还尝试将基于Properties模板的文件添加到项目中.在创建新文件时,这些都没有改变输出.

我如何在Netbeans 7.1.2中执行此操作?

解决方法

当我撰写这个问题时,我找到了解决方案,并希望将其发布在此处供其他人参考. Netbeans帮助文件中的说明不正确.第2步应更改如下:
  1. Expand the Other category. Click the Setting button. The User.properties file opens in the editor.

我希望这对将来的某个人有用.

(编辑:李大同)

【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容!

    推荐文章
      热点阅读