Overview | Package | Class | Tree | Deprecated | Index | Help
| Protégé-OWL 3.4 rc2
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## edu.stanford.smi.protegex.owl.ui.editors
Class StringValueEditor

    java.lang.Object
      edu.stanford.smi.protegex.owl.ui.editors.StringValueEditor

All Implemented Interfaces:
  PropertyValueEditor

    public class StringValueEditor

extends Object
implements PropertyValueEditor

Author:
  Holger Knublauch

Constructor Summary
`StringValueEditor()`

Method Summary
`boolean` | `canEdit(RDFResource instance, RDFProperty property, Object value)` Checks whether this is able to edit values for a certain predicate.
`Object` | `createDefaultValue(RDFResource instance, RDFProperty property)` Creates a default value for a given predicate at a given subject.
`Object` | `editValue(Component parent, RDFResource instance, RDFProperty property, Object value)` Edits a given value for a given resource/predicate pair.
`boolean` | `mustEdit(RDFResource subject, RDFProperty predicate, Object value)` Checks whether this is the only way to edit values for a certain predicate.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### StringValueEditor

    public StringValueEditor()

Method Detail

### canEdit

    public boolean canEdit(RDFResource instance,
                           RDFProperty property,
                           Object value)

  Description copied from interface: `PropertyValueEditor`
  Checks whether this is able to edit values for a certain predicate.

  Specified by:
    `canEdit` in interface `PropertyValueEditor`
  Returns:
    true if this can edit such values

### createDefaultValue

    public Object createDefaultValue(RDFResource instance,
                                     RDFProperty property)

  Description copied from interface: `PropertyValueEditor`
  Creates a default value for a given predicate at a given subject. The hosting widget should call this method on each of its registered editors to see whether any of them defines a non-null default value.

  Specified by:
    `createDefaultValue` in interface `PropertyValueEditor`
  Parameters:
    `instance` - the RDFResource to create a default value for
    `property` - the annotation predicate
  Returns:
    the default value or null if this does not define a default for this predicate

### editValue

    public Object editValue(Component parent,
                            RDFResource instance,
                            RDFProperty property,
                            Object value)

  Description copied from interface: `PropertyValueEditor`
  Edits a given value for a given resource/predicate pair. For example, after the user has double-clicked on the value, the host widget could iterate on all editors to see whether any of them is ready to edit this value (returning true).

  Specified by:
    `editValue` in interface `PropertyValueEditor`
  Returns:
    the new value (!= null) if this has handled editing for the value

### mustEdit

    public boolean mustEdit(RDFResource subject,
                            RDFProperty predicate,
                            Object value)

  Description copied from interface: `PropertyValueEditor`
  Checks whether this is the only way to edit values for a certain predicate. This is used to force editing of value types like xsd:date, where simple string input fields would not be sufficient.

  Specified by:
    `mustEdit` in interface `PropertyValueEditor`
  Returns:
    true if this can edit such values

Overview | Package | Class | Tree | Deprecated | Index | Help
| Protégé-OWL 3.4 rc2
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Submit a bug report or feature request
Copyright (c) 1998-2009 Stanford University.