Java Reference
In-Depth Information
3. Repeat steps 1 and 2 to find the remaining bookmarked lines and
replace the text, Exception, with the exceptions and parameters listed
in Table 10-2. When you have finished, click Toggle Bookmark on the
Search menu.
All exceptions are changed appropriately, and all bookmarks are cleared
from the code (Figure 10-32).
text replaced
text replaced
text replaced
text replaced
FIGURE 10-32
OTHER WAYS
1. To find next
bookmark, press
ALT + S , E
2. To find next
bookmark, press F 2
3. To clear all
bookmarks, press
CTRL + SHIFT + F 2
Table 10-2
Replacement Exception Code on Bookmarked Lines
LINE
REPLACEMENT EXCEPTION
REPLACEMENT ARGUMENTS
180
PasswordInvalidException
183
PasswordExpiredException
193
PasswordInvalidException
204
PasswordInvalidFormatException
207
PasswordSizeException
“Password < minimum size”,
pswd.length(), MIN_SIZE, MAX_SIZE
210
PasswordSizeException
“Password > maximum size”,
pswd.length(), MIN_SIZE, MAX_SIZE
218
PasswordInvalidFormatException
As shown in Table 10-2 and Figure 10-32, the arguments for creating the
new PasswordSizeException object are modified in lines 207 and 210 so that the
object retains information about the size of the password entered by the user, as
well as the maximum and minimum sizes allowed.
 
Search WWH ::




Custom Search