-
CSR
-
Resolution: Approved
-
P3
-
None
-
behavioral
-
minimal
-
No behavior change - specification only so minimal risk
-
Java API
-
SE
Summary
The current state of specification for /javax/swing/JFormattedTextField.AbstractFormatter.html#getDocumentFilter() /javax/swing/JFormattedTextField.AbstractFormatter.html#getNavigationFilter() doesn't mention "null" is returned by both "default" implementations
Problem
The current state of specification for /javax/swing/JFormattedTextField.AbstractFormatter.html#getDocumentFilter() /javax/swing/JFormattedTextField.AbstractFormatter.html#getNavigationFilter() doesn't mention "null" is returned by both "default" implementations
Solution
Default implementation returns "null" needs to be stated explicitly by @implSpec tag.
Specification
* Subclass and override if you wish to provide a
* <code>DocumentFilter</code> to restrict what can be input.
* <code>install</code> will install the returned value onto
* the <code>JFormattedTextField</code>.
*
+ * @implSpec The default implementation returns <code>null</code>.
+ *
* @return DocumentFilter to restrict edits
*/
protected DocumentFilter getDocumentFilter() {
return null;
* Subclass and override if you wish to provide a filter to restrict
* where the user can navigate to.
* <code>install</code> will install the returned value onto
* the <code>JFormattedTextField</code>.
*
+ * @implSpec The default implementation returns <code>null</code>.
+ *
* @return NavigationFilter to restrict navigation
*/
protected NavigationFilter getNavigationFilter() {
return null;
}
- csr of
-
JDK-8263768 JFormattedTextField.AbstractFormatter.getDocumentFilter()/getNavigationFilter() spec doesn't mention what the default impls return and what does it mean
-
- Resolved
-