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

## org.jivesoftware.openfire.pubsub.models
Class PublisherModel

    java.lang.Object
      org.jivesoftware.openfire.pubsub.models.PublisherModel

Direct Known Subclasses:
  OnlyPublishers, OnlySubscribers, OpenPublisher

    public abstract class PublisherModel

extends Object

Policy that defines who is allowed to publish items to the node.

Author:
  Matt Tucker

Field Summary
`static PublisherModel` | `open`
`static PublisherModel` | `publishers`
`static PublisherModel` | `subscribers`

Constructor Summary
`PublisherModel()`

Method Summary
`abstract boolean` | `canPublish(Node node, org.xmpp.packet.JID entity)` Returns true if the entity is allowed to publish items to the specified node.
`abstract String` | `getName()` Returns the name as defined by the JEP-60 spec.
`static PublisherModel` | `valueOf(String name)` Returns the specific subclass of PublisherModel as specified by the publisher model name.

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

Field Detail

### open

    public static final PublisherModel open

### publishers

    public static final PublisherModel publishers

### subscribers

    public static final PublisherModel subscribers

Constructor Detail

### PublisherModel

    public PublisherModel()

Method Detail

### valueOf

    public static PublisherModel valueOf(String name)

  Returns the specific subclass of PublisherModel as specified by the publisher model name. If an unknown name is specified then an IllegalArgumentException is going to be thrown.

  Parameters:
    `name` - the name of the subsclass.
  Returns:
    the specific subclass of PublisherModel as specified by the access model name.

### getName

    public abstract String getName()

  Returns the name as defined by the JEP-60 spec.

  Returns:
    the name as defined by the JEP-60 spec.

### canPublish

    public abstract boolean canPublish(Node node,
                                       org.xmpp.packet.JID entity)

  Returns true if the entity is allowed to publish items to the specified node.

  Parameters:
    `node` - the node that may get a new published item by the specified entity.
    `entity` - the JID of the entity that wants to publish an item to the node.
  Returns:
    true if the subscriber is allowed to publish items to the specified node.

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

Copyright © 2003-2008 Jive Software.