Skip to content

Commit 6ad118c

Browse files
jjohnstnvogella
authored andcommitted
1 parent 8d148ed commit 6ad118c

File tree

6 files changed

+175
-7
lines changed

6 files changed

+175
-7
lines changed
127 KB
Loading
33.4 KB
Loading
33.4 KB
Loading
49.9 KB
Loading

news/4.37/jdt.html

Lines changed: 141 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,144 @@
1-
<!DOCTYPE html>
2-
<html>
1+
<h1>Java Development Tools - 4.37</h1>
32

4-
<head>
5-
<script src="../../project.js"></script>
6-
</head>
3+
<p>A special thanks to everyone who <a href="acknowledgements.md#java-development-tools">contributed to JDT</a> in this release!</p>
74

8-
<body onload="redirect()"></body>
5+
<!--
6+
---
7+
## Java&trade; XX Support
8+
-->
9+
10+
11+
12+
13+
<!--
14+
---
15+
## JUnit
16+
-->
17+
18+
19+
<hr />
20+
21+
<h2>Java Editor</h2>
22+
23+
<h3>Support Overlapping Start and End Markers for Custom Folding Regions</h3>
24+
25+
<p><details>
26+
<summary>Contributors</summary></p>
27+
28+
<ul>
29+
<li><a href="https://github.com/danthe1st">Daniel Schmid</a>
30+
</details></li>
31+
</ul>
32+
33+
34+
<p>Custom Folding Regions have been enhanced to allow using the same text for both the start and end region comment.
35+
If the start and end region markers are the same, the same comment can be used to end a folding region and start a new one.
36+
The last section automatically ends when the last block is closed or at the end of the file.</p>
37+
38+
<p>This is useful if a class (or other Java file) contains multiple sections that are seperated with some comment.
39+
To use this functionality, check &ldquo;Enable folding of custom regions&rdquo; in <code>Window &gt; Preferences &gt; Java &gt; Editor &gt; Folding</code> and enter the same text in &ldquo;Region start comment text&rdquo; and &ldquo;Region end comment text&rdquo;.</p>
40+
41+
<p><img src="images/overlappingStartEndCustomRegionMarkersPrefs.png" alt="Preference window with folding of custom regions enabled and the start and end region markers set to the same text" /></p>
42+
43+
<p>This marker can then be used in comments to separate start and end regions.</p>
44+
45+
<p><img src="images/overlappingStartEndCustomRegionMarkersExpanded.png" alt="Java class with multiple sections seperated by comments" /></p>
46+
47+
<p><img src="images/overlappingStartEndCustomRegionMarkersCollapsed.png" alt="The same Java class with some regions collapsed" /></p>
48+
49+
<h3>New quick-fix/clean-up to replace deprecated fields</h3>
50+
51+
<p><details>
52+
<summary>Contributors</summary></p>
53+
54+
<ul>
55+
<li><a href="https://github.com/jjohnstn">Jeff Johnston</a>
56+
</details></li>
57+
</ul>
58+
59+
60+
<p>In a previous release, support was added to replace deprecated method calls with a suggested replacement found in Javadoc. With this release, it is now possible to also replace fields with suggested replacements.</p>
61+
62+
<p>The new clean-up is found by going to the <code>Source Fixing</code> tab of the Clean-up Configuration dialog and selecting: <code>Replace deprecated field where possible</code>. The quick-fix is accessible by clicking CTRL+space on the deprecated field reference.</p>
63+
64+
<p><img src="images/deprecatedFieldCleanUp.png" alt="Setting the deprecated field clean-up" /></p>
65+
66+
<p>To make the field replaceable, the Javadoc should specify the alternate field or constant to use. For example, for the following code:</p>
67+
68+
<p><img src="images/deprecatedFieldExampleBefore.png" alt="Code example for deprecated field" /></p>
69+
70+
<p>results in:</p>
71+
72+
<p><img src="images/deprecatedFieldExampleAfter.png" alt="Code example after clean-up" /></p>
73+
74+
<p>after applying the clean-up.</p>
75+
76+
<h3>Access modifier specification added to Extract Method</h3>
77+
78+
<p><details>
79+
<summary>Contributors</summary></p>
80+
81+
<ul>
82+
<li><a href="https://github.com/jjohnstn">Jeff Johnston</a>
83+
</details></li>
84+
</ul>
85+
86+
87+
<p>When extracting code to a method, a user can now specify access modifiers for the new method including: <code>public</code>, <code>protected</code>, <code>package-private</code>, <code>private</code>, <code>final</code>, and <code>synchronized</code>.</p>
88+
89+
<p><img src="images/extractMethodAccessors.png" alt="Example of new Extract Method dialog" /></p>
90+
91+
<h2>Debugger</h2>
92+
93+
<h3>Toggle Triggerpoint and Breakpoint with Hit Count</h3>
94+
95+
<p><details>
96+
<summary>Contributors</summary></p>
97+
98+
<ul>
99+
<li><a href="https://github.com/iloveeclipse">Andrey Loskutov</a></li>
100+
<li><a href="https://github.com/subyssurendran666">Suby S Surendran</a>
101+
</details></li>
102+
</ul>
103+
104+
105+
<p>The ruler context menu in the editor has been enhanced to make debugging setup more efficient. You can now directly toggle a breakpoint with hit count or a triggerpoint by <code>right-clicking on the vertical ruler</code> (left margin), where the context menu includes the options Toggle Breakpoint with Hit Count and Toggle Triggerpoint.</p>
106+
107+
<p><img src="images/rulerToggleMenuWithHitcountAndTriggerpoint.png" alt="Ruler context menu in the Java editor showing new entries for Toggle Breakpoint with Hit Count and Toggle Triggerpoint" /></p>
108+
109+
<!--
110+
---
111+
## Java Views and Dialogs
112+
-->
113+
114+
115+
116+
117+
<!--
118+
---
119+
## Java Compiler
120+
-->
121+
122+
123+
124+
125+
<!--
126+
---
127+
## Java Formatter
128+
-->
129+
130+
131+
132+
133+
<!--
134+
---
135+
## Debug
136+
-->
137+
138+
139+
140+
141+
<!--
142+
### JDT Developers
143+
-->
9144

10-
</html>

news/4.37/jdt.md

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,40 @@ This marker can then be used in comments to separate start and end regions.
3838

3939
![The same Java class with some regions collapsed](images/overlappingStartEndCustomRegionMarkersCollapsed.png)
4040

41+
### New quick-fix/clean-up to replace deprecated fields
42+
<details>
43+
<summary>Contributors</summary>
44+
45+
- [Jeff Johnston](https://github.com/jjohnstn)
46+
</details>
47+
48+
In a previous release, support was added to replace deprecated method calls with a suggested replacement found in Javadoc. With this release, it is now possible to also replace fields with suggested replacements.
49+
50+
The new clean-up is found by going to the `Source Fixing` tab of the Clean-up Configuration dialog and selecting: `Replace deprecated field where possible`. The quick-fix is accessible by clicking CTRL+space on the deprecated field reference.
51+
52+
![Setting the deprecated field clean-up](images/deprecatedFieldCleanUp.png)
53+
54+
To make the field replaceable, the Javadoc should specify the alternate field or constant to use. For example, for the following code:
55+
56+
![Code example for deprecated field](images/deprecatedFieldExampleBefore.png)
57+
58+
results in:
59+
60+
![Code example after clean-up](images/deprecatedFieldExampleAfter.png)
61+
62+
after applying the clean-up.
63+
64+
### Access modifier specification added to Extract Method
65+
<details>
66+
<summary>Contributors</summary>
67+
68+
- [Jeff Johnston](https://github.com/jjohnstn)
69+
</details>
70+
71+
When extracting code to a method, a user can now specify access modifiers for the new method including: `public`, `protected`, `package-private`, `private`, `final`, and `synchronized`.
72+
73+
![Example of new Extract Method dialog](images/extractMethodAccessors.png)
74+
4175
## Debugger
4276

4377
### Toggle Triggerpoint and Breakpoint with Hit Count

0 commit comments

Comments
 (0)