Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/markiewb/nb-additional-hints
Additional java hints for NetBeans IDE http://plugins.netbeans.org/plugin/47589/additional-hints
https://github.com/markiewb/nb-additional-hints
hint hints inspections java java-editor netbeans-plugin quickfix
Last synced: about 2 months ago
JSON representation
Additional java hints for NetBeans IDE http://plugins.netbeans.org/plugin/47589/additional-hints
- Host: GitHub
- URL: https://github.com/markiewb/nb-additional-hints
- Owner: markiewb
- Created: 2013-02-04T22:41:04.000Z (almost 12 years ago)
- Default Branch: master
- Last Pushed: 2017-02-11T12:40:39.000Z (almost 8 years ago)
- Last Synced: 2024-08-05T11:12:43.016Z (4 months ago)
- Topics: hint, hints, inspections, java, java-editor, netbeans-plugin, quickfix
- Language: Java
- Homepage: http://benkiew.wordpress.com/2013/03/17/netbeans-ide-additional-hints-plugin-to-simplify-the-work-with-string-literals/
- Size: 1.96 MB
- Stars: 7
- Watchers: 6
- Forks: 3
- Open Issues: 29
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
- awesome-netbeans - Additional Hints - Adds more hints to the editor during development. (:electric_plug: Plugins <a name="plugins"></a> / Development)
README
Looking for maintainers, who want to take over the development!
[![Build Status](https://travis-ci.org/markiewb/nb-additional-hints.svg?branch=master)](https://travis-ci.org/markiewb/nb-additional-hints)
[![Donate](https://www.paypalobjects.com/en_US/i/btn/btn_donate_SM.gif)](https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=K4CMP92RZELE2)Plugin page: http://plugins.netbeans.org/plugin/47589/
Additional Java hints for NetBeans IDE
Supported Hints:
- "Replace '+' with 'MessageFormat.format()'"
- "Replace '+' with 'new StringBuilder().append()'"
- "Replace '+' with 'String.format()'"
- "Join literals"
- "Copy joined literals to clipboard"
- "Split at linebreaks"
- "Split at caret" (since 1.1)
- "Convert to assertTrue/assertFalse" (since 1.1)
- "Support transformation to BigDecimal constants" (since 1.1)
- "Remove "public abstract" modifiers from method declarations within interfaces" (since 1.1)
- "Remove public/abstract/final modifiers from field declarations within interfaces" (since 1.2)
- "Change modifiers" (since 1.2)
- "Convert char to string and back" (since 1.2)
- "Convert number in literal to number and back" (since 1.2)
- "Convert to StringUtils.isBlank()/StringUtils.isNotBlank()/StringUtils.isEmpty()" (since 1.2)
- "Convert from if/else to ternary and back" (since 1.2)
- "Invert ternary if/else" (since 1.2)
- "Report methods that have class name" (since 1.2, no transformation)
- "Add "this." to methods and variables" (since 1.3, disabled by default)
- "Replace with Optional.isPresent()/Convert return null to return Optional.empty()" (since 1.5)
- "Replace with null-assignment to Optional with Optional.empty()| (since 1.6)
- "Convert return xxx to return Optional.ofNullable(xxx)/Optional.of(xxx)/Optional.empty()| (since 1.6)
- "Convert to assertNull" (since 1.6)
- "Replace with org.junit.Assert" (since 1.6)
Example:
Updates
1.6.1:
- [Bugfix]: Fixed: Hints for converting ternary to if and back are missing
1.6.0:
- [New Fix]: Replace with null-assignment to Optional with Optional.empty()
- [New Fix]: Convert return xxx to return Optional.ofNullable(xxx)/Optional.of(xxx)/Optional.empty()
- [New Fix]: Convert to assertNull
- [New Fix]: Replace with org.junit.Assert
- [Updated Fix]: "Replace +..." works for more expressions
- [Updated Fix]: Fixed false positive result from "Convert to Optional.isEmpty()"
- [Updated Fix]: Make "Change modifiers" hints non-intrusive
- [Updated Fix]: Make "Change modifiers" hints work for constructors too
- [Updated Fix ]: java.lang.NullPointerException in "Report methods that have class name"
- [Updated Fix ]: java.lang.NullPointerException in ReturnForOptional
- [Removed Fix]: "dead instanceof" hint has been removed
- [Task]: Update dependencies to NB 8.1
- [Task]: Reduce dependencies
1.5.0:
- [Updated Fix]: "Convert to if/else" now supports assignments to new variables
- [Updated Fix]: "Invert ternary"/"Convert to ternary" now support conditions without brackets
- [Updated Fix]: "Replace +..." is not proposed for erroneous conditions anymore
- [Updated Fix]: "Replace +..." works for more expressions
- [Updated Fix]: Remove false positive detected by "Detect dead instanceof"
- [New Fix]: Replace with Optional.isPresent()/Convert return null to return Optional.empty()
- [Task]: Update requirements JDK7 and NB7.4
1.4.0:
- [New Hint]: Detect dead instanceof-expressions
- [Updated Fix]: "Replace +..." hints can now supports chars too
- [Meta]: Add donation link (for those who want to support this project)
1.3.0:
- [Updated Fix]: "Invert ternary if/else" now supports more patterns
- [New Hint]: Add "this." to methods and variables (disabled by default)
1.2.0:
- [New Fix]: Change the modifier of a class/method/field to public/package protected/protected/private (by rasa-silva)
- [New Fix]: Remove public/abstract/final modifiers from field declarations within interfaces
- [New Fix]: Convert from char and string and back
- [New Fix]: Convert number in literal to number and back
- [New Fix]: Convert to StringUtils.isBlank()/StringUtils.isNotBlank()/StringUtils.isEmpty()
- [New Fix]: Convert from if/else to ternary and back
- [New Fix]: Invert ternary if/else
- [New Hint]: Report methods that have class name
- [Updated Fix]: "Convert to assertTrue/assertFalse" now supports junit.framework.Assert too
- [Updated Fix]: "Replace +..." hints can now be configured
1.1.0:
- [New Fix]: Support transformation to BigDecimal constants
- [New Fix]: Split a string at caret
- [New Fix]: Convert to assertTrue/assertFalse
- [New Fix]: Remove "public abstract" modifiers from method declarations within interfaces
- [Bugfix]: Literals with quoted Strings won't be copied properly to clipboard
- [Refactoring]: Convert to maven based module
- [Refactoring]: Hints should be proposals instead of errors/warnings
1.0.x:
- [Bugfix]: Literals with quoted Strings create uncompileable code
Further information:
This plugin is orginally based on code from the "I18N Checker" plugin from Jan Lahoda.
The original sourcecode can be found at http://hg.netbeans.org/main/contrib/file/tip/editor.hints.i18n
License remains CDDL-GPL-2-CP - http://www.netbeans.org/cddl-gplv2.html
Provide defects, request for enhancements and feedback at https://github.com/markiewb/nb-additional-hints/issues
Compatible to NetBeans 8.1+