- java.lang.Object
-
- javax.swing.tree.DefaultTreeSelectionModel
-
- javax.swing.JTree.EmptySelectionModel
-
- All Implemented Interfaces:
- Serializable, Cloneable, TreeSelectionModel
- Enclosing class:
- JTree
protected static class JTree.EmptySelectionModel extends DefaultTreeSelectionModel
EmptySelectionModel
is aTreeSelectionModel
that does not allow anything to be selected.Warning: Serialized objects of this class will not be compatible with future Swing releases. The current serialization support is appropriate for short term storage or RMI between applications running the same version of Swing. As of 1.4, support for long term storage of all JavaBeansTM has been added to the
java.beans
package. Please seeXMLEncoder
.
-
-
Field Summary
Fields Modifier and Type Field and Description protected static JTree.EmptySelectionModel
sharedInstance
The single instance ofEmptySelectionModel
.-
Fields inherited from class javax.swing.tree.DefaultTreeSelectionModel
changeSupport, leadIndex, leadPath, leadRow, listenerList, listSelectionModel, rowMapper, selection, SELECTION_MODE_PROPERTY, selectionMode
-
Fields inherited from interface javax.swing.tree.TreeSelectionModel
CONTIGUOUS_TREE_SELECTION, DISCONTIGUOUS_TREE_SELECTION, SINGLE_TREE_SELECTION
-
-
Constructor Summary
Constructors Modifier Constructor and Description protected
JTree.EmptySelectionModel()
-
Method Summary
Methods Modifier and Type Method and Description void
addPropertyChangeListener(PropertyChangeListener listener)
This is overriden to do nothing;EmptySelectionModel
does not allow a selection.void
addSelectionPaths(TreePath[] paths)
This is overriden to do nothing;EmptySelectionModel
does not allow a selection.void
addTreeSelectionListener(TreeSelectionListener listener)
This is overriden to do nothing;EmptySelectionModel
does not allow a selection.void
removePropertyChangeListener(PropertyChangeListener listener)
This is overriden to do nothing;EmptySelectionModel
does not allow a selection.void
removeSelectionPaths(TreePath[] paths)
This is overriden to do nothing;EmptySelectionModel
does not allow a selection.void
removeTreeSelectionListener(TreeSelectionListener listener)
This is overriden to do nothing;EmptySelectionModel
does not allow a selection.void
setRowMapper(RowMapper mapper)
This is overriden to do nothing;EmptySelectionModel
does not allow a selection.void
setSelectionMode(int mode)
This is overriden to do nothing;EmptySelectionModel
does not allow a selection.void
setSelectionPaths(TreePath[] paths)
This is overriden to do nothing;EmptySelectionModel
does not allow a selection.static JTree.EmptySelectionModel
sharedInstance()
Returns the single instance ofEmptySelectionModel
.-
Methods inherited from class javax.swing.tree.DefaultTreeSelectionModel
addSelectionPath, arePathsContiguous, canPathsBeAdded, canPathsBeRemoved, clearSelection, clone, fireValueChanged, getLeadSelectionPath, getLeadSelectionRow, getListeners, getMaxSelectionRow, getMinSelectionRow, getPropertyChangeListeners, getRowMapper, getSelectionCount, getSelectionMode, getSelectionPath, getSelectionPaths, getSelectionRows, getTreeSelectionListeners, insureRowContinuity, insureUniqueness, isPathSelected, isRowSelected, isSelectionEmpty, notifyPathChange, removeSelectionPath, resetRowSelection, setSelectionPath, toString, updateLeadIndex
-
-
-
-
Field Detail
-
sharedInstance
protected static final JTree.EmptySelectionModel sharedInstance
The single instance ofEmptySelectionModel
.
-
-
Method Detail
-
sharedInstance
public static JTree.EmptySelectionModel sharedInstance()
Returns the single instance ofEmptySelectionModel
.- Returns:
- single instance of
EmptySelectionModel
-
setSelectionPaths
public void setSelectionPaths(TreePath[] paths)
This is overriden to do nothing;EmptySelectionModel
does not allow a selection.- Specified by:
setSelectionPaths
in interfaceTreeSelectionModel
- Overrides:
setSelectionPaths
in classDefaultTreeSelectionModel
- Parameters:
paths
- the paths to select; this is ignored
-
addSelectionPaths
public void addSelectionPaths(TreePath[] paths)
This is overriden to do nothing;EmptySelectionModel
does not allow a selection.- Specified by:
addSelectionPaths
in interfaceTreeSelectionModel
- Overrides:
addSelectionPaths
in classDefaultTreeSelectionModel
- Parameters:
paths
- the paths to add to the selection; this is ignored
-
removeSelectionPaths
public void removeSelectionPaths(TreePath[] paths)
This is overriden to do nothing;EmptySelectionModel
does not allow a selection.- Specified by:
removeSelectionPaths
in interfaceTreeSelectionModel
- Overrides:
removeSelectionPaths
in classDefaultTreeSelectionModel
- Parameters:
paths
- the paths to remove; this is ignored
-
setSelectionMode
public void setSelectionMode(int mode)
This is overriden to do nothing;EmptySelectionModel
does not allow a selection.- Specified by:
setSelectionMode
in interfaceTreeSelectionModel
- Overrides:
setSelectionMode
in classDefaultTreeSelectionModel
- Parameters:
mode
- the selection mode; this is ignored- Since:
- 1.7
-
setRowMapper
public void setRowMapper(RowMapper mapper)
This is overriden to do nothing;EmptySelectionModel
does not allow a selection.- Specified by:
setRowMapper
in interfaceTreeSelectionModel
- Overrides:
setRowMapper
in classDefaultTreeSelectionModel
- Parameters:
mapper
- theRowMapper
instance; this is ignored- Since:
- 1.7
-
addTreeSelectionListener
public void addTreeSelectionListener(TreeSelectionListener listener)
This is overriden to do nothing;EmptySelectionModel
does not allow a selection.- Specified by:
addTreeSelectionListener
in interfaceTreeSelectionModel
- Overrides:
addTreeSelectionListener
in classDefaultTreeSelectionModel
- Parameters:
listener
- the listener to add; this is ignored- Since:
- 1.7
-
removeTreeSelectionListener
public void removeTreeSelectionListener(TreeSelectionListener listener)
This is overriden to do nothing;EmptySelectionModel
does not allow a selection.- Specified by:
removeTreeSelectionListener
in interfaceTreeSelectionModel
- Overrides:
removeTreeSelectionListener
in classDefaultTreeSelectionModel
- Parameters:
listener
- the listener to remove; this is ignored- Since:
- 1.7
-
addPropertyChangeListener
public void addPropertyChangeListener(PropertyChangeListener listener)
This is overriden to do nothing;EmptySelectionModel
does not allow a selection.- Specified by:
addPropertyChangeListener
in interfaceTreeSelectionModel
- Overrides:
addPropertyChangeListener
in classDefaultTreeSelectionModel
- Parameters:
listener
- the listener to add; this is ignored- Since:
- 1.7
-
removePropertyChangeListener
public void removePropertyChangeListener(PropertyChangeListener listener)
This is overriden to do nothing;EmptySelectionModel
does not allow a selection.- Specified by:
removePropertyChangeListener
in interfaceTreeSelectionModel
- Overrides:
removePropertyChangeListener
in classDefaultTreeSelectionModel
- Parameters:
listener
- the listener to remove; this is ignored- Since:
- 1.7
-
-
Deutsche Übersetzung
Sie haben gebeten, diese Seite auf Deutsch zu besuchen. Momentan ist nur die Oberfläche übersetzt, aber noch nicht der gesamte Inhalt.Wenn Sie mir bei Übersetzungen helfen wollen, ist Ihr Beitrag willkommen. Alles, was Sie tun müssen, ist, sich auf der Website zu registrieren und mir eine Nachricht zu schicken, in der Sie gebeten werden, Sie der Gruppe der Übersetzer hinzuzufügen, die Ihnen die Möglichkeit gibt, die gewünschten Seiten zu übersetzen. Ein Link am Ende jeder übersetzten Seite zeigt an, dass Sie der Übersetzer sind und einen Link zu Ihrem Profil haben.
Vielen Dank im Voraus.
Dokument erstellt 11/06/2005, zuletzt geändert 04/03/2020
Quelle des gedruckten Dokuments:https://www.gaudry.be/de/java-api-rf-javax/swing/JTree.EmptySelectionModel.html
Die Infobro ist eine persönliche Seite, deren Inhalt in meiner alleinigen Verantwortung liegt. Der Text ist unter der CreativeCommons-Lizenz (BY-NC-SA) verfügbar. Weitere Informationen auf die Nutzungsbedingungen und dem Autor.
Referenzen
Diese Verweise und Links verweisen auf Dokumente, die während des Schreibens dieser Seite konsultiert wurden, oder die zusätzliche Informationen liefern können, aber die Autoren dieser Quellen können nicht für den Inhalt dieser Seite verantwortlich gemacht werden.
Der Autor Diese Website ist allein dafür verantwortlich, wie die verschiedenen Konzepte und Freiheiten, die mit den Nachschlagewerken gemacht werden, hier dargestellt werden. Denken Sie daran, dass Sie mehrere Quellinformationen austauschen müssen, um das Risiko von Fehlern zu reduzieren.