Protege-2000 1.7

edu.stanford.smi.protege.model
Class DefaultFacet

java.lang.Object
  |
  +--edu.stanford.smi.protege.model.DefaultFrame
        |
        +--edu.stanford.smi.protege.model.DefaultInstance
              |
              +--edu.stanford.smi.protege.model.DefaultFacet
All Implemented Interfaces:
Comparable, Facet, Frame, Instance

public class DefaultFacet
extends DefaultInstance
implements Facet

Default implementation of Facet interface. Forwards all method calls to its DefaultKnowledgeBase.

Author:
Ray Fergerson

Constructor Summary
DefaultFacet(KnowledgeBase kb, FrameID id)
           
 
Method Summary
 void addFacetListener(FacetListener listener)
           
 boolean areValidValues(Frame frame, Slot slot, Collection slotValues)
           
 Slot getAssociatedSlot()
           
 FacetConstraint getConstraint()
           
 String getInvalidValuesText(Frame frame, Slot slot, Collection slotValues)
           
 String getInvalidValueText(Frame frame, Slot slot, Object item)
           
 ValueType getValueType()
           
 boolean isValidValue(Frame frame, Slot slot, Object value)
           
 void removeFacetListener(FacetListener listener)
           
 void setAssociatedSlot(Slot slot)
           
 void setConstraint(FacetConstraint c)
           
 String toString()
           
 
Methods inherited from class edu.stanford.smi.protege.model.DefaultInstance
addInstanceListener, deepCopy, getBrowserText, getDirectType, getOwnFacetValue, getOwnFacetValues, getReachableSimpleInstances, hasDirectType, hasType, removeInstanceListener, setDirectType
 
Methods inherited from class edu.stanford.smi.protege.model.DefaultFrame
addFrameListener, addOwnFacetValue, addOwnSlotValue, areValidOwnSlotValues, compareTo, delete, finalize, getDefaultKnowledgeBase, getDocumentation, getFrameID, getInvalidOwnSlotValuesText, getInvalidOwnSlotValueText, getKnowledgeBase, getName, getOwnSlotAllowsMultipleValues, getOwnSlotAndSubslotValues, getOwnSlotDefaultValues, getOwnSlotFacets, getOwnSlotFacetValues, getOwnSlots, getOwnSlotValue, getOwnSlotValueCount, getOwnSlotValues, getOwnSlotValueType, getProject, getReferences, getReferences, hasOwnSlot, isEditable, isIncluded, isSystem, isValid, isValidOwnSlotValue, isVisible, moveOwnSlotValue, removeFrameID, removeFrameListener, removeOwnSlotValue, setDocumentation, setDocumentation, setEditable, setIncluded, setName, setOwnFacetValue, setOwnFacetValues, setOwnSlotValue, setOwnSlotValues, setSystem, setVisible
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface edu.stanford.smi.protege.model.Instance
addInstanceListener, getDirectType, getReachableSimpleInstances, hasDirectType, hasType, removeInstanceListener, setDirectType
 
Methods inherited from interface edu.stanford.smi.protege.model.Frame
addFrameListener, addOwnFacetValue, addOwnSlotValue, areValidOwnSlotValues, deepCopy, delete, getBrowserText, getDocumentation, getFrameID, getInvalidOwnSlotValuesText, getInvalidOwnSlotValueText, getKnowledgeBase, getName, getOwnFacetValue, getOwnFacetValues, getOwnSlotAllowsMultipleValues, getOwnSlotAndSubslotValues, getOwnSlotDefaultValues, getOwnSlotFacets, getOwnSlotFacetValues, getOwnSlots, getOwnSlotValue, getOwnSlotValueCount, getOwnSlotValues, getOwnSlotValueType, getProject, getReferences, getReferences, hasOwnSlot, isEditable, isIncluded, isSystem, isValid, isValidOwnSlotValue, isVisible, moveOwnSlotValue, removeFrameListener, removeOwnSlotValue, setDocumentation, setDocumentation, setEditable, setIncluded, setName, setOwnFacetValue, setOwnFacetValues, setOwnSlotValue, setOwnSlotValues, setVisible
 
Methods inherited from interface java.lang.Comparable
compareTo
 

Constructor Detail

DefaultFacet

public DefaultFacet(KnowledgeBase kb,
                    FrameID id)
Method Detail

addFacetListener

public void addFacetListener(FacetListener listener)
Specified by:
addFacetListener in interface Facet

areValidValues

public boolean areValidValues(Frame frame,
                              Slot slot,
                              Collection slotValues)
Specified by:
areValidValues in interface Facet

getAssociatedSlot

public Slot getAssociatedSlot()
Specified by:
getAssociatedSlot in interface Facet

getConstraint

public FacetConstraint getConstraint()
Specified by:
getConstraint in interface Facet

getInvalidValuesText

public String getInvalidValuesText(Frame frame,
                                   Slot slot,
                                   Collection slotValues)
Specified by:
getInvalidValuesText in interface Facet

getInvalidValueText

public String getInvalidValueText(Frame frame,
                                  Slot slot,
                                  Object item)
Specified by:
getInvalidValueText in interface Facet

getValueType

public ValueType getValueType()
Specified by:
getValueType in interface Facet

isValidValue

public boolean isValidValue(Frame frame,
                            Slot slot,
                            Object value)
Specified by:
isValidValue in interface Facet

removeFacetListener

public void removeFacetListener(FacetListener listener)
Specified by:
removeFacetListener in interface Facet

setAssociatedSlot

public void setAssociatedSlot(Slot slot)
Specified by:
setAssociatedSlot in interface Facet

setConstraint

public void setConstraint(FacetConstraint c)
Specified by:
setConstraint in interface Facet

toString

public String toString()
Overrides:
toString in class DefaultInstance

Protege-2000 1.7

Submit a bug report or feature request
Protege-2000 is a trademark of Stanford University.
Copyright (c) 1998-2002 Stanford University.