Overview | Package | Class | Tree | Serialized | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.apache.muse.ws.resource.properties.listeners
Interface PropertyChangeApprover

All Known Implementing Classes:
  AbstractChangeApprover

public interface PropertyChangeApprover

PropertyChangeApprover describes a type of property listener that is invoked when a property change is about to occur (through the WS-RP SetResourceProperties operation). Approvers can prevent the change by throwing an exception from the validateChange() method. Before writing your own approver, make sure that Muse's WS-RMD support doesn't already do what you are trying to do.

Author:
  Dan Jemiolo (danj)
See Also:
  `MetadataDescriptor`

Method Summary
`QName` | `getPropertyName()`
`boolean` | `isSecure(java.lang.Object securityToken)`
`void` | `setSecurityToken(java.lang.Object securityToken)` Sets the security token that will be used in all security checks via isSecure(Object).
`void` | `validateChange(org.w3c.dom.Element oldValue, org.w3c.dom.Element newValue, java.lang.Object token)` Analyzes the property change being made and throws an exception if the change is invalid.

Method Detail

### getPropertyName

    public QName getPropertyName()

  Returns:
    The QName of the property being monitored.

### isSecure

    public boolean isSecure(java.lang.Object securityToken)

  Parameters:
    `securityToken` - The security token provided by the caller who wishes to make the property change.
  Returns:
    True if the token matches one the approver knows to be valid.
  See Also:
    `setSecurityToken(Object)`

### setSecurityToken

    public void setSecurityToken(java.lang.Object securityToken)

  Sets the security token that will be used in all security checks via isSecure(Object).

  Parameters:
    `securityToken` -
  See Also:
    `isSecure(Object)`

### validateChange

    public void validateChange(org.w3c.dom.Element oldValue,
                               org.w3c.dom.Element newValue,
                               java.lang.Object token)
                        throws BaseFault

  Analyzes the property change being made and throws an exception if the change is invalid.

  Parameters:
    `oldValue` - The current (about to be "old") value of the resource property. This should be null if the change is a WS-RP Insert.
    `newValue` - The potential new value of the resource property. This should be null if the change is a WS-RP Delete.
    `token` - The security token provided by the caller who wishes to make the property change.
  Throws:
    `BaseFault` -
    - If the modification is not allowed for any reason.

Overview | Package | Class | Tree | Serialized | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD