edu.stanford.smi.protegex.owl.ui.dialogs
Class DefaultSelectionDialogFactory
java.lang.Object
edu.stanford.smi.protegex.owl.ui.dialogs.AbstractSelectionDialogFactory
edu.stanford.smi.protegex.owl.ui.dialogs.DefaultSelectionDialogFactory
- All Implemented Interfaces:
- SelectionDialogFactory
- public class DefaultSelectionDialogFactory
- extends AbstractSelectionDialogFactory
The default implementation based on the core Protege dialogs.
- Author:
- Holger Knublauch
Method Summary |
static Collection |
ensureResourcesHaveVisibility(Collection allowedResources,
boolean visible)
Makes sure that the resources in the specified collection have the specified
visibility. |
private static void |
getFirstTwoClasses(Collection allowedClasses,
Collection classes)
|
private static Collection |
getFirstTwoClasses(OWLModel owlModel,
Collection allowedClasses)
|
private static boolean |
hasOneClass(Collection rootClses)
|
private static edu.stanford.smi.protege.model.Cls |
pickClass(Component component,
OWLModel owlModel,
Collection allowedClasses,
String label)
|
private static Collection |
pickClasses(Component component,
OWLModel owlModel,
Collection rootClses,
String label,
boolean multiple)
|
private static edu.stanford.smi.protege.model.Instance |
pickInstanceFromCollection(Component component,
Collection collection,
int initialSelection,
String label)
|
private static Collection |
pickInstancesFromCollection(Component component,
Collection instances,
String label)
|
private static RDFSNamedClass |
promptForClass(Component component,
OWLModel owlModel,
Collection clses,
String label)
|
RDFSNamedClass |
selectClass(Component parent,
OWLModel owlModel,
Collection rootClasses,
String title)
|
Set |
selectClasses(Component parent,
OWLModel owlModel,
Collection rootClasses,
String title)
|
RDFProperty |
selectProperty(Component parent,
OWLModel owlModel,
Collection allowedProperties,
String title)
|
RDFResource |
selectResourceByType(Component parent,
OWLModel owlModel,
Collection allowedClasses,
String title)
|
RDFResource |
selectResourceFromCollection(Component parent,
OWLModel owlModel,
Collection resources,
String title)
|
Set |
selectResourcesByType(Component parent,
OWLModel owlModel,
Collection allowedClasses,
String title)
|
Set |
selectResourcesFromCollection(Component parent,
OWLModel owlModel,
Collection resources,
String title)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DefaultSelectionDialogFactory
public DefaultSelectionDialogFactory()
getFirstTwoClasses
private static Collection getFirstTwoClasses(OWLModel owlModel,
Collection allowedClasses)
getFirstTwoClasses
private static void getFirstTwoClasses(Collection allowedClasses,
Collection classes)
hasOneClass
private static boolean hasOneClass(Collection rootClses)
pickClasses
private static Collection pickClasses(Component component,
OWLModel owlModel,
Collection rootClses,
String label,
boolean multiple)
pickClass
private static edu.stanford.smi.protege.model.Cls pickClass(Component component,
OWLModel owlModel,
Collection allowedClasses,
String label)
pickInstanceFromCollection
private static edu.stanford.smi.protege.model.Instance pickInstanceFromCollection(Component component,
Collection collection,
int initialSelection,
String label)
pickInstancesFromCollection
private static Collection pickInstancesFromCollection(Component component,
Collection instances,
String label)
promptForClass
private static RDFSNamedClass promptForClass(Component component,
OWLModel owlModel,
Collection clses,
String label)
selectClass
public RDFSNamedClass selectClass(Component parent,
OWLModel owlModel,
Collection rootClasses,
String title)
- Specified by:
selectClass
in interface SelectionDialogFactory
- Overrides:
selectClass
in class AbstractSelectionDialogFactory
selectClasses
public Set selectClasses(Component parent,
OWLModel owlModel,
Collection rootClasses,
String title)
selectProperty
public RDFProperty selectProperty(Component parent,
OWLModel owlModel,
Collection allowedProperties,
String title)
selectResourceFromCollection
public RDFResource selectResourceFromCollection(Component parent,
OWLModel owlModel,
Collection resources,
String title)
selectResourceByType
public RDFResource selectResourceByType(Component parent,
OWLModel owlModel,
Collection allowedClasses,
String title)
selectResourcesByType
public Set selectResourcesByType(Component parent,
OWLModel owlModel,
Collection allowedClasses,
String title)
selectResourcesFromCollection
public Set selectResourcesFromCollection(Component parent,
OWLModel owlModel,
Collection resources,
String title)
ensureResourcesHaveVisibility
public static Collection ensureResourcesHaveVisibility(Collection allowedResources,
boolean visible)
- Makes sure that the resources in the specified collection have the specified
visibility.
- Parameters:
allowedResources
- The resources that should have the specified visibility.visible
- Specified whether or not the resources should be visible.
- Returns:
true
if the resources should be visible, or false
if the resources should not be visible.