Please use the Apache issue tracking system for new NetBeans issues ( !!

Bug 210454

Summary: Patch for: Code Templates: add 'currClassName'/'currClassFullName'/'currPackage' variables
Product: editor Reporter: 280Z28
Component: Completion & TemplatesAssignee: Dusan Balek <dbalek>
Status: RESOLVED FIXED QA Contact: issues <>
Priority: P3 CC: pfabier
Version: -S1S-Keywords: PATCH_AVAILABLE
Target Milestone: 8.0.1   
Hardware: PC   
OS: Windows 7   
Whiteboard: netfix801
Issue Type: ENHANCEMENT Exception Report:
Bug Depends on:    
Bug Blocks: 148947    
Attachments: Implementation

Description 280Z28 2012-03-30 15:39:01 UTC
Created attachment 117562 [details]

The currPackage and currClassFullName hints would be similar to the currClassName hint, and could be used like the following:

I'm particularly interested in using this for modifying the default "logr" template by adding a usage comment:

// -D${fullClassVar editable="false" currClassFullName}.level=FINE
private static final ${loggerType type="java.util.logging.Logger" default="Logger" editable="false"} LOGGER = ${loggerType}.getLogger(${classVar editable="false" currClassName default="getClass()"}.class.getName());

The currPackage hint is not used here, but in the process of implementing the currClassFullName hint it was trivial to include as well.
Comment 1 Dusan Balek 2013-06-20 15:56:42 UTC
Unfortunately NB 7.4 is already feature frozen. Marking as an enhancement for
the next release.
Comment 2 markiewb 2014-07-09 21:54:16 UTC
@Dusan: Please review the patch. The original author (Samuel Harwell - NB - 280Z28) signed the OCA.
Comment 3 Dusan Balek 2014-07-22 11:50:01 UTC
Slightly modified patch applied. Thanks for your contribution.
Comment 4 Quality Engineering 2014-07-30 02:33:55 UTC
Integrated into 'main-silver', will be available in build *201407300001* on (upload may still be in progress)

User: Dusan Balek <>
Log: Issue #210454: Patch for: Code Templates: add 'currClassName'/'currClassFullName'/'currPackage' variables - applied.
Comment 5 markiewb 2015-03-26 22:26:18 UTC
*** Bug 183633 has been marked as a duplicate of this bug. ***
By use of this website, you agree to the NetBeans Policies and Terms of Use. © 2014, Oracle Corporation and/or its affiliates. Sponsored by Oracle logo