Java Error Fixes

(Difference between revisions)
m
m
Line 8: Line 8:
;'''Add Cast Fix'''
;'''Add Cast Fix'''
: handles the following errors:
: handles the following errors:
 +
: * {0} {1} in {4} {5} cannot be applied to given types; required: {2} found: {3} reason: {6}
: * no suitable {0} found for {1}({2})
: * no suitable {0} found for {1}({2})
-
: * incompatible types: {0}
 
: * cannot find symbol symbol:  {0} {1}({3}) location: {4}
: * cannot find symbol symbol:  {0} {1}({3}) location: {4}
-
: * {0} {1} in {4} {5} cannot be applied to given types; required: {2} found: {3} reason: {6}
+
: * incompatible types: {0}
: <span style='padding-left: 1em; font-size: 90%'> ''In NetBeans 7.3 or earlier''</span>
: <span style='padding-left: 1em; font-size: 90%'> ''In NetBeans 7.3 or earlier''</span>
;'''Add Class Dependency From Maven Repository'''
;'''Add Class Dependency From Maven Repository'''
: handles the following errors:
: handles the following errors:
-
: * not a statement
+
: * cannot find symbol symbol: {0} {1}
: * cannot find symbol symbol:  {0} {1} location: {4}
: * cannot find symbol symbol:  {0} {1} location: {4}
: * package {0} does not exist
: * package {0} does not exist
-
: * cannot find symbol symbol: {0} {1}
+
: * not a statement
: <span style='padding-left: 1em; font-size: 90%'> ''In NetBeans 7.3 or earlier''</span>
: <span style='padding-left: 1em; font-size: 90%'> ''In NetBeans 7.3 or earlier''</span>
;'''Add Constructor'''
;'''Add Constructor'''
: handles the following errors:
: handles the following errors:
-
: * no suitable {0} found for {1}({2})
 
: * {0} {1} in {4} {5} cannot be applied to given types; required: {2} found: {3} reason: {6}
: * {0} {1} in {4} {5} cannot be applied to given types; required: {2} found: {3} reason: {6}
 +
: * no suitable {0} found for {1}({2})
: <span style='padding-left: 1em; font-size: 90%'> ''In current development version''</span>
: <span style='padding-left: 1em; font-size: 90%'> ''In current development version''</span>
;'''Add Import Fix'''
;'''Add Import Fix'''
: handles the following errors:
: handles the following errors:
-
: * not a statement
+
: * cannot find symbol symbol: {0} {1}
: * cannot find symbol symbol:  {0} {1} location: {4}
: * cannot find symbol symbol:  {0} {1} location: {4}
: * cannot find symbol symbol:  {0} {1}({3}) location: {4}
: * cannot find symbol symbol:  {0} {1}({3}) location: {4}
: * package {0} does not exist
: * package {0} does not exist
-
: * cannot find symbol symbol: {0} {1}
+
: * not a statement
: <span style='padding-left: 1em; font-size: 90%'> ''In NetBeans 7.3 or earlier''</span>
: <span style='padding-left: 1em; font-size: 90%'> ''In NetBeans 7.3 or earlier''</span>
;'''Add Module Dependency'''
;'''Add Module Dependency'''
: handles the following errors:
: handles the following errors:
-
: * not a statement
+
: * cannot find symbol symbol: {0} {1}
: * cannot find symbol symbol:  {0} {1} location: {4}
: * cannot find symbol symbol:  {0} {1} location: {4}
: * package {0} does not exist
: * package {0} does not exist
-
: * cannot find symbol symbol: {0} {1}
+
: * not a statement
: <span style='padding-left: 1em; font-size: 90%'> ''In current development version''</span>
: <span style='padding-left: 1em; font-size: 90%'> ''In current development version''</span>
Line 67: Line 67:
;'''Change Type Fix'''
;'''Change Type Fix'''
: handles the following errors:
: handles the following errors:
-
: * incompatible types: {0}
 
: * incomparable types: {0} and {1}
: * incomparable types: {0} and {1}
 +
: * incompatible types: {0}
: <span style='padding-left: 1em; font-size: 90%'> ''In NetBeans 7.3 or earlier''</span>
: <span style='padding-left: 1em; font-size: 90%'> ''In NetBeans 7.3 or earlier''</span>
Line 84: Line 84:
;'''Create CDI Annotation'''
;'''Create CDI Annotation'''
: handles the following errors:
: handles the following errors:
 +
: * {0} {1} in {4} {5} cannot be applied to given types; required: {2} found: {3} reason: {6}
 +
: * cannot find symbol symbol: {0} {1}
 +
: * cannot find symbol symbol: {0} {1}({3})
: * cannot find symbol symbol:  {0} {1} location: {4}
: * cannot find symbol symbol:  {0} {1} location: {4}
-
: * cannot find symbol symbol: {0} {1}({3})
 
-
: * {0} {1} in {4} {5} cannot be applied to given types; required: {2} found: {3} reason: {6}
 
: * cannot find symbol symbol:  {0} {1}({3}) location: {4}
: * cannot find symbol symbol:  {0} {1}({3}) location: {4}
-
: * cannot find symbol symbol: {0} {1}
 
: <span style='padding-left: 1em; font-size: 90%'> ''In NetBeans 7.3 or earlier''</span>
: <span style='padding-left: 1em; font-size: 90%'> ''In NetBeans 7.3 or earlier''</span>
;'''Create Field Fix'''
;'''Create Field Fix'''
: handles the following errors:
: handles the following errors:
-
: * cannot find symbol symbol:  {0} {1} location: {4}
 
-
: * cannot find symbol symbol: {0} {1}({3})
 
: * {0} {1} in {4} {5} cannot be applied to given types; required: {2} found: {3} reason: {6}
: * {0} {1} in {4} {5} cannot be applied to given types; required: {2} found: {3} reason: {6}
-
: * cannot find symbol symbol:  {0} {1}({3}) location: {4}
 
: * cannot find symbol symbol: {0} {1}
: * cannot find symbol symbol: {0} {1}
 +
: * cannot find symbol symbol: {0} {1}({3})
 +
: * cannot find symbol symbol:  {0} {1} location: {4}
 +
: * cannot find symbol symbol:  {0} {1}({3}) location: {4}
: <span style='padding-left: 1em; font-size: 90%'> ''In NetBeans 7.3 or earlier''</span>
: <span style='padding-left: 1em; font-size: 90%'> ''In NetBeans 7.3 or earlier''</span>
Line 118: Line 118:
;'''Implement All Abstract Methods Fix'''
;'''Implement All Abstract Methods Fix'''
: handles the following errors:
: handles the following errors:
-
: * {0} is not abstract and does not override abstract method {1} in {2}
 
: * {0} is abstract; cannot be instantiated
: * {0} is abstract; cannot be instantiated
 +
: * {0} is not abstract and does not override abstract method {1} in {2}
: <span style='padding-left: 1em; font-size: 90%'> ''In NetBeans 7.3 or earlier''</span>
: <span style='padding-left: 1em; font-size: 90%'> ''In NetBeans 7.3 or earlier''</span>
Line 144: Line 144:
;'''Remove invalid modifier'''
;'''Remove invalid modifier'''
: handles the following errors:
: handles the following errors:
-
: * modifier {0} not allowed here
+
: * abstract methods cannot have a body
: <span style='padding-left: 1em; font-size: 90%'> ''In current development version''</span>
: <span style='padding-left: 1em; font-size: 90%'> ''In current development version''</span>
;'''Remove invalid modifier'''
;'''Remove invalid modifier'''
: handles the following errors:
: handles the following errors:
-
: * abstract methods cannot have a body
+
: * modifier {0} not allowed here
: <span style='padding-left: 1em; font-size: 90%'> ''In current development version''</span>
: <span style='padding-left: 1em; font-size: 90%'> ''In current development version''</span>
Line 164: Line 164:
;'''Suppress Warnings Fix'''
;'''Suppress Warnings Fix'''
: handles the following errors:
: handles the following errors:
-
: * unchecked generic array creation for varargs parameter of type {0}
+
: * {0} in {1} has been deprecated
-
: * unchecked assignment to variable {0} as member of raw type {1}
+
: * possible fall-through into case
: * possible fall-through into case
 +
: * {0} required: {2} found:    {1}
: * unchecked assignment: {0} to {1}
: * unchecked assignment: {0} to {1}
-
: * {0} in {1} has been deprecated
+
: * unchecked assignment to variable {0} as member of raw type {1}
 +
: * unchecked call to {0} as a member of the raw type {1}
: * unchecked cast to type {0}
: * unchecked cast to type {0}
 +
: * unchecked generic array creation for varargs parameter of type {0}
: * unchecked method invocation: {0} {1} in {4} {5} is applied to given types required: {2} found: {3}
: * unchecked method invocation: {0} {1} in {4} {5} is applied to given types required: {2} found: {3}
-
: * {0} required: {2} found:    {1}
 
-
: * unchecked call to {0} as a member of the raw type {1}
 
: <span style='padding-left: 1em; font-size: 90%'> ''In NetBeans 7.3 or earlier''</span>
: <span style='padding-left: 1em; font-size: 90%'> ''In NetBeans 7.3 or earlier''</span>
;'''Upgrade elements access'''
;'''Upgrade elements access'''
: handles the following errors:
: handles the following errors:
-
: * array required, but {0} found
+
: * {0} has {1} access in {2}
: <span style='padding-left: 1em; font-size: 90%'> ''In current development version''</span>
: <span style='padding-left: 1em; font-size: 90%'> ''In current development version''</span>
;'''Upgrade elements access'''
;'''Upgrade elements access'''
: handles the following errors:
: handles the following errors:
-
: * {0} has {1} access in {2}
+
: * array required, but {0} found
: <span style='padding-left: 1em; font-size: 90%'> ''In current development version''</span>
: <span style='padding-left: 1em; font-size: 90%'> ''In current development version''</span>

Revision as of 13:28, 26 July 2013

There are 31 total error fixes, 11 of them in current development version only.

Add "final" modifier
handles the following errors:
* local variable {0} is accessed from within inner class; needs to be declared final
In NetBeans 7.3 or earlier
Add Cast Fix
handles the following errors:
* {0} {1} in {4} {5} cannot be applied to given types; required: {2} found: {3} reason: {6}
* no suitable {0} found for {1}({2})
* cannot find symbol symbol: {0} {1}({3}) location: {4}
* incompatible types: {0}
In NetBeans 7.3 or earlier
Add Class Dependency From Maven Repository
handles the following errors:
* cannot find symbol symbol: {0} {1}
* cannot find symbol symbol: {0} {1} location: {4}
* package {0} does not exist
* not a statement
In NetBeans 7.3 or earlier
Add Constructor
handles the following errors:
* {0} {1} in {4} {5} cannot be applied to given types; required: {2} found: {3} reason: {6}
* no suitable {0} found for {1}({2})
In current development version
Add Import Fix
handles the following errors:
* cannot find symbol symbol: {0} {1}
* cannot find symbol symbol: {0} {1} location: {4}
* cannot find symbol symbol: {0} {1}({3}) location: {4}
* package {0} does not exist
* not a statement
In NetBeans 7.3 or earlier
Add Module Dependency
handles the following errors:
* cannot find symbol symbol: {0} {1}
* cannot find symbol symbol: {0} {1} location: {4}
* package {0} does not exist
* not a statement
In current development version
Add Throws Clause and Surround With try-catch Fixes
handles the following errors:
* unreported exception {0}; must be caught or declared to be thrown
In NetBeans 7.3 or earlier
Add serialVersionUID
handles the following errors:
* serializable class {0} has no definition of serialVersionUID
In NetBeans 7.3 or earlier
Change Method Parameters Fix
handles the following errors:
* no suitable {0} found for {1}({2})
In NetBeans 7.3 or earlier
Change Method Return Type
handles the following errors:
* incompatible types: {0}
In NetBeans 7.3 or earlier
Change Type Fix
handles the following errors:
* incomparable types: {0} and {1}
* incompatible types: {0}
In NetBeans 7.3 or earlier
Class Name not Matching File Name
handles the following errors:
* class {0} is public, should be declared in a file named {0}.java
In current development version
Convert between extends and implements
handles the following errors:
* interface expected here
* no interface expected here
In current development version
Create CDI Annotation
handles the following errors:
* {0} {1} in {4} {5} cannot be applied to given types; required: {2} found: {3} reason: {6}
* cannot find symbol symbol: {0} {1}
* cannot find symbol symbol: {0} {1}({3})
* cannot find symbol symbol: {0} {1} location: {4}
* cannot find symbol symbol: {0} {1}({3}) location: {4}
In NetBeans 7.3 or earlier
Create Field Fix
handles the following errors:
* {0} {1} in {4} {5} cannot be applied to given types; required: {2} found: {3} reason: {6}
* cannot find symbol symbol: {0} {1}
* cannot find symbol symbol: {0} {1}({3})
* cannot find symbol symbol: {0} {1} location: {4}
* cannot find symbol symbol: {0} {1}({3}) location: {4}
In NetBeans 7.3 or earlier
Extra catch clauses
handles the following errors:
* exception {0} has already been caught
* exception {0} is never thrown in body of corresponding try statement
In current development version
Fix modifiers when an overriding method has too weak access rights
handles the following errors:
* {0} attempting to assign weaker access privileges; was {1}
In NetBeans 7.3 or earlier
Handling of Missing Return Statement compiler error
handles the following errors:
* missing return statement
In NetBeans 7.3 or earlier
Implement All Abstract Methods Fix
handles the following errors:
* {0} is abstract; cannot be instantiated
* {0} is not abstract and does not override abstract method {1} in {2}
In NetBeans 7.3 or earlier
Remove "final" modifier
handles the following errors:
* final parameter {0} may not be assigned
In current development version
Remove "final" modifier
handles the following errors:
* cannot assign a value to final variable {0}
In current development version
Remove @Override Annotation
handles the following errors:
* method does not override or implement a method from a supertype
In NetBeans 7.3 or earlier
Remove Useless Cast Fix
handles the following errors:
* redundant cast to {0}
In NetBeans 7.3 or earlier
Remove invalid modifier
handles the following errors:
* abstract methods cannot have a body
In current development version
Remove invalid modifier
handles the following errors:
* modifier {0} not allowed here
In current development version
Rename Constructor
handles the following errors:
* invalid method declaration; return type required
In NetBeans 7.3 or earlier
Resolve inexact varargs type warning
handles the following errors:
* non-varargs call of varargs method with inexact argument type for last parameter; cast to {0} for a varargs call cast to {1} for a non-varargs call and to suppress this warning
In NetBeans 7.3 or earlier
Suppress Warnings Fix
handles the following errors:
* {0} in {1} has been deprecated
* possible fall-through into case
* {0} required: {2} found: {1}
* unchecked assignment: {0} to {1}
* unchecked assignment to variable {0} as member of raw type {1}
* unchecked call to {0} as a member of the raw type {1}
* unchecked cast to type {0}
* unchecked generic array creation for varargs parameter of type {0}
* unchecked method invocation: {0} {1} in {4} {5} is applied to given types required: {2} found: {3}
In NetBeans 7.3 or earlier
Upgrade elements access
handles the following errors:
* {0} has {1} access in {2}
In current development version
Upgrade elements access
handles the following errors:
* array required, but {0} found
In current development version
Use of uninitialized variable
handles the following errors:
* variable {0} might not have been initialized
In NetBeans 7.3 or earlier
Not logged in. Log in, Register

By use of this website, you agree to the NetBeans Policies and Terms of Use. © 2012, Oracle Corporation and/or its affiliates. Sponsored by Oracle logo