com.stratelia.silverpeas.silverpeasinitialize
Class CallBackManager

java.lang.Object
  extended by com.stratelia.silverpeas.silverpeasinitialize.CallBackManager

Deprecated. Please use the Silverpeas Notification API defined in the package com.silverpeas.notification

@Deprecated
public class CallBackManager
extends Object

The CallBackManager centralizes and dispatches the notification events coming from the different actions performed within Silverpeas components. The CallBackManager is a way to loosly couply the differents components between them. In effect, some components can be interested by some kind of events, whatever their origin, in order to perform some useful computation. For doing, they have just to subscribe a callback function for the kind of event they are interested. The callback function will be invoked by a CallBackManager at the firing of a such event. The callback function is represented by an object implementing the CallBack interface.


Field Summary
static int ACTION_AFTER_CREATE_COMPONENT
          Deprecated.  
static int ACTION_AFTER_CREATE_GROUP
          Deprecated.  
static int ACTION_AFTER_CREATE_SPACE
          Deprecated.  
static int ACTION_AFTER_CREATE_USER
          Deprecated.  
static int ACTION_ATTACHMENT_ADD
          Deprecated.  
static int ACTION_ATTACHMENT_REMOVE
          Deprecated.  
static int ACTION_ATTACHMENT_UPDATE
          Deprecated.  
static int ACTION_BEFORE_REMOVE_COMPONENT
          Deprecated.  
static int ACTION_BEFORE_REMOVE_GROUP
          Deprecated.  
static int ACTION_BEFORE_REMOVE_SPACE
          Deprecated.  
static int ACTION_BEFORE_REMOVE_USER
          Deprecated.  
static int ACTION_COMMENT_ADD
          Deprecated.  
static int ACTION_COMMENT_REMOVE
          Deprecated.  
static int ACTION_CUTANDPASTE
          Deprecated.  
static int ACTION_HEADER_PUBLICATION_UPDATE
          Deprecated.  
static int ACTION_LAST
          Deprecated.  
static int ACTION_ON_WYSIWYG
          Deprecated.  
static int ACTION_PUBLICATION_REMOVE
          Deprecated.  
static int ACTION_VERSIONING_ADD
          Deprecated.  
static int ACTION_VERSIONING_REMOVE
          Deprecated.  
static int ACTION_VERSIONING_UPDATE
          Deprecated.  
static int ACTION_XMLCONTENT_CREATE
          Deprecated.  
static int ACTION_XMLCONTENT_DELETE
          Deprecated.  
static int ACTION_XMLCONTENT_UPDATE
          Deprecated.  
 
Method Summary
static CallBackManager get()
          Deprecated. Gets an instance of a CallBackManager.
 String getInvokeString(int action, int iParam, String sParam, Object extraParam)
          Deprecated. Gets the string representation of the invocation of the callbacks registered for the specified event.
 void invoke(int action, int iParam, String sParam, Object extraParam)
          Deprecated. Invokes all of the callback functions registered for the specified event matching a well-defined action.
 void subscribeAction(int action, CallBack theObj)
          Deprecated. Subscribes the specified callback function for the given notification event.
 void subscribeAll(CallBack theObj)
          Deprecated. Subscribes the specified callback function for all notification events, whatever they are.
 void unsubscribeAction(int action, CallBack theObj)
          Deprecated. Unsubscribes the specified callback function for the given notification event.
 void unsubscribeAll(CallBack theObj)
          Deprecated. Unsubscribes the specified callback function for all notification events, whatever they are.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

ACTION_AFTER_CREATE_USER

public static final int ACTION_AFTER_CREATE_USER
Deprecated. 
See Also:
Constant Field Values

ACTION_BEFORE_REMOVE_USER

public static final int ACTION_BEFORE_REMOVE_USER
Deprecated. 
See Also:
Constant Field Values

ACTION_AFTER_CREATE_GROUP

public static final int ACTION_AFTER_CREATE_GROUP
Deprecated. 
See Also:
Constant Field Values

ACTION_BEFORE_REMOVE_GROUP

public static final int ACTION_BEFORE_REMOVE_GROUP
Deprecated. 
See Also:
Constant Field Values

ACTION_AFTER_CREATE_SPACE

public static final int ACTION_AFTER_CREATE_SPACE
Deprecated. 
See Also:
Constant Field Values

ACTION_BEFORE_REMOVE_SPACE

public static final int ACTION_BEFORE_REMOVE_SPACE
Deprecated. 
See Also:
Constant Field Values

ACTION_AFTER_CREATE_COMPONENT

public static final int ACTION_AFTER_CREATE_COMPONENT
Deprecated. 
See Also:
Constant Field Values

ACTION_BEFORE_REMOVE_COMPONENT

public static final int ACTION_BEFORE_REMOVE_COMPONENT
Deprecated. 
See Also:
Constant Field Values

ACTION_ON_WYSIWYG

public static final int ACTION_ON_WYSIWYG
Deprecated. 
See Also:
Constant Field Values

ACTION_ATTACHMENT_ADD

public static final int ACTION_ATTACHMENT_ADD
Deprecated. 
See Also:
Constant Field Values

ACTION_ATTACHMENT_UPDATE

public static final int ACTION_ATTACHMENT_UPDATE
Deprecated. 
See Also:
Constant Field Values

ACTION_ATTACHMENT_REMOVE

public static final int ACTION_ATTACHMENT_REMOVE
Deprecated. 
See Also:
Constant Field Values

ACTION_VERSIONING_ADD

public static final int ACTION_VERSIONING_ADD
Deprecated. 
See Also:
Constant Field Values

ACTION_VERSIONING_UPDATE

public static final int ACTION_VERSIONING_UPDATE
Deprecated. 
See Also:
Constant Field Values

ACTION_VERSIONING_REMOVE

public static final int ACTION_VERSIONING_REMOVE
Deprecated. 
See Also:
Constant Field Values

ACTION_COMMENT_ADD

public static final int ACTION_COMMENT_ADD
Deprecated. 
See Also:
Constant Field Values

ACTION_COMMENT_REMOVE

public static final int ACTION_COMMENT_REMOVE
Deprecated. 
See Also:
Constant Field Values

ACTION_CUTANDPASTE

public static final int ACTION_CUTANDPASTE
Deprecated. 
See Also:
Constant Field Values

ACTION_XMLCONTENT_CREATE

public static final int ACTION_XMLCONTENT_CREATE
Deprecated. 
See Also:
Constant Field Values

ACTION_XMLCONTENT_UPDATE

public static final int ACTION_XMLCONTENT_UPDATE
Deprecated. 
See Also:
Constant Field Values

ACTION_XMLCONTENT_DELETE

public static final int ACTION_XMLCONTENT_DELETE
Deprecated. 
See Also:
Constant Field Values

ACTION_HEADER_PUBLICATION_UPDATE

public static final int ACTION_HEADER_PUBLICATION_UPDATE
Deprecated. 
See Also:
Constant Field Values

ACTION_PUBLICATION_REMOVE

public static final int ACTION_PUBLICATION_REMOVE
Deprecated. 
See Also:
Constant Field Values

ACTION_LAST

public static final int ACTION_LAST
Deprecated. 
See Also:
Constant Field Values
Method Detail

get

public static CallBackManager get()
Deprecated. 
Gets an instance of a CallBackManager.

Returns:
an instance of this class.

subscribeAction

public void subscribeAction(int action,
                            CallBack theObj)
Deprecated. 
Subscribes the specified callback function for the given notification event.

Parameters:
action - the action at the origin of a notification event.
theObj - the callback function to invoke when a such action is performed.

unsubscribeAction

public void unsubscribeAction(int action,
                              CallBack theObj)
Deprecated. 
Unsubscribes the specified callback function for the given notification event.

Parameters:
action - the action at the origin of a notification event.
theObj - the callback function to unsubscribe.

subscribeAll

public void subscribeAll(CallBack theObj)
Deprecated. 
Subscribes the specified callback function for all notification events, whatever they are.

Parameters:
theObj - the callback function to invoke when an action, responsible of a notification event firing, is performed.

unsubscribeAll

public void unsubscribeAll(CallBack theObj)
Deprecated. 
Unsubscribes the specified callback function for all notification events, whatever they are.

Parameters:
theObj - the callback function to unsubscribe.

invoke

public void invoke(int action,
                   int iParam,
                   String sParam,
                   Object extraParam)
Deprecated. 
Invokes all of the callback functions registered for the specified event matching a well-defined action.

Parameters:
action - the event fired and matching a specific context of an action.
iParam - a parameter as integer.
sParam - another parameter as string.
extraParam - an extra parameter as an object.

getInvokeString

public String getInvokeString(int action,
                              int iParam,
                              String sParam,
                              Object extraParam)
Deprecated. 
Gets the string representation of the invocation of the callbacks registered for the specified event.

Parameters:
action - the event matching a specific context of an action.
iParam - a parameter as integer.
sParam - another parameter as string.
extraParam - an extra parameter as an object.
Returns:
a String representation of the invocation.


Copyright © 2016 Silverpeas. All Rights Reserved.