Package limn.backend
Record Class FileDialogs.Filter
java.lang.Object
java.lang.Record
limn.backend.FileDialogs.Filter
- Enclosing interface:
FileDialogs
A file-name filter: a human-readable description plus glob patterns,
e.g.
Filter.of("Images", "*.png", "*.jpg"). Dialogs may show the
description and restrict the listing to the patterns. Open dialogs
honour the patterns on macOS too, including *.ext filters for
extensions no installed application registers (an application's own
document type): the macOS panel matches by uniform type identifier, not
filename, and the backend translates such patterns to the system's
identifier. The macOS save panel offers no name filtering: a
filter passed to FileDialogs.saveFile(java.lang.String, java.nio.file.Path, limn.backend.FileDialogs.Filter) is ignored there; the other platforms
filter save dialogs by name as usual.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of thedescriptionrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.static FileDialogs.FilterA filter shown asdescription, matching glob patterns like"*.png".patterns()Returns the value of thepatternsrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
Filter
Creates an instance of aFilterrecord class.- Parameters:
description- the value for thedescriptionrecord componentpatterns- the value for thepatternsrecord component
-
-
Method Details
-
of
A filter shown asdescription, matching glob patterns like"*.png". -
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object). -
description
Returns the value of thedescriptionrecord component.- Returns:
- the value of the
descriptionrecord component
-
patterns
Returns the value of thepatternsrecord component.- Returns:
- the value of the
patternsrecord component
-