org.cometd.server.authorizer
Class GrantAuthorizer

java.lang.Object
  extended by org.cometd.server.authorizer.GrantAuthorizer
All Implemented Interfaces:
Authorizer

public class GrantAuthorizer
extends Object
implements Authorizer

This Authorizer implementation grants permission for a set of operations defined at construction time.

If the operation does not match, it ignores the authorization request.


Nested Class Summary
 
Nested classes/interfaces inherited from interface org.cometd.bayeux.server.Authorizer
Authorizer.Operation, Authorizer.Result
 
Field Summary
static GrantAuthorizer GRANT_ALL
          Grants Operation#CREATE, Operation#SUBSCRIBE and Operation#PUBLISH authorization
static GrantAuthorizer GRANT_CREATE
          Grants Operation#CREATE authorization
static GrantAuthorizer GRANT_CREATE_SUBSCRIBE
          Grants Operation#CREATE and Operation#SUBSCRIBE authorization
static GrantAuthorizer GRANT_NONE
          Grants no authorization, the authorization request is ignored
static GrantAuthorizer GRANT_PUBLISH
          Grants Operation#PUBLISH authorization
static GrantAuthorizer GRANT_SUBSCRIBE
          Grants Operation#SUBSCRIBE authorization
static GrantAuthorizer GRANT_SUBSCRIBE_PUBLISH
          Grants Operation#SUBSCRIBE and Operation#PUBLISH authorization
 
Method Summary
 Authorizer.Result authorize(Authorizer.Operation operation, ChannelId channel, ServerSession session, ServerMessage message)
           
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

GRANT_CREATE

public static final GrantAuthorizer GRANT_CREATE
Grants Operation#CREATE authorization


GRANT_SUBSCRIBE

public static final GrantAuthorizer GRANT_SUBSCRIBE
Grants Operation#SUBSCRIBE authorization


GRANT_PUBLISH

public static final GrantAuthorizer GRANT_PUBLISH
Grants Operation#PUBLISH authorization


GRANT_CREATE_SUBSCRIBE

public static final GrantAuthorizer GRANT_CREATE_SUBSCRIBE
Grants Operation#CREATE and Operation#SUBSCRIBE authorization


GRANT_SUBSCRIBE_PUBLISH

public static final GrantAuthorizer GRANT_SUBSCRIBE_PUBLISH
Grants Operation#SUBSCRIBE and Operation#PUBLISH authorization


GRANT_ALL

public static final GrantAuthorizer GRANT_ALL
Grants Operation#CREATE, Operation#SUBSCRIBE and Operation#PUBLISH authorization


GRANT_NONE

public static final GrantAuthorizer GRANT_NONE
Grants no authorization, the authorization request is ignored

Method Detail

authorize

public Authorizer.Result authorize(Authorizer.Operation operation,
                                   ChannelId channel,
                                   ServerSession session,
                                   ServerMessage message)
Specified by:
authorize in interface Authorizer

toString

public String toString()
Overrides:
toString in class Object


Copyright © 2008-2012 Dojo Foundation. All Rights Reserved.