This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 270282 - Added a isValid method into JavaPlatform
Summary: Added a isValid method into JavaPlatform
Status: NEW
Alias: None
Product: java
Classification: Unclassified
Component: Project (show other bugs)
Version: Dev
Hardware: All All
: P3 normal (vote)
Assignee: apireviews
URL:
Keywords: API, API_REVIEW_FAST
Depends on:
Blocks:
 
Reported: 2017-04-03 12:36 UTC by Tomas Zezula
Modified: 2017-04-03 12:38 UTC (History)
0 users

See Also:
Issue Type: TASK
Exception Reporter:


Attachments
Patch file (33.67 KB, application/octet-stream)
2017-04-03 12:36 UTC, Tomas Zezula
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Tomas Zezula 2017-04-03 12:36:16 UTC
Created attachment 164009 [details]
Patch file

Added a isValid method into the JavaPlatform to check JavaPlatform validity.
Currently there are several places which check JavaPlatform validity in different ways.
Most used pattern is !jp.getInstallFolder().isEmpty() but on some places also important tools are checked in addition to install folders.

The JavaPlatform was extended by isValid method doing the !jp.getInstallFolder().isEmpty(). The subclasses like J2SEPlatform can do more checks like check of important tools and boot classpath validity.