Eclipse doesn't strike out deprecated classes?
Here is a sample code
public class DeprecatedTest {
private final List<Object> instances;
public DeprecatedTest(){
instances = new ArrayList<Object>();
instances.add(new Depr());
instances.add(new Depr1());
instances.add(new Depr2());
instances.add(new Depr3());
Depr depr = new Depr();开发者_高级运维
Depr2 depr2 = new Depr2();
}
@Deprecated
public class Depr{}
@Deprecated
public class Depr1{}
@Deprecated
public class Depr2{}
@Deprecated
public class Depr3{}
}
Eclipse does strikes out class name before instance name (2 last declarations). But if it is anonymous class Eclipse doesn't strike out class initialization after new operand. It's really inconvenient! Is it configurable?
SpringSource Tool Suite Version: 2.5.0.M3 Build Id: 201008251000
Should be very easy ->
- open Preferences
- type "deprecated" in the Search Box
- go to Java->Editor->Syntax Coloring
- find Java->Deprecated members in the Tree
- Check the Enable Checkbox and the Strikethroigh Checkbox
tadaa!
精彩评论