org.alfresco.bm.user
Class InviteUser

java.lang.Object
  extended by org.alfresco.bm.event.AbstractEventProcessor
      extended by org.alfresco.bm.user.InviteUser
All Implemented Interfaces:
org.alfresco.bm.event.EventProcessor, org.springframework.beans.factory.Aware, org.springframework.beans.factory.BeanNameAware

public class InviteUser
extends org.alfresco.bm.event.AbstractEventProcessor

Process an Alfresco Cloud invite.

Input

User email address.

Data

A MongoDB collection containing the details of the user matching the input email address.

Actions

Fetches the user data from the MongoDB using the inbound email address. Registers the user in the sign-up queue. Stores the sign-up details.

Output

EVENT_NAME_GET_INVITE_STATUS: The user's email address

Since:
1.0
Author:
Derek Hulley

Field Summary
static String DEFAULT_API_SIGNUP_QUEUE
           
static long DEFAULT_MAX_ACCEPT_TIME
           
static long DEFAULT_MIN_ACCEPT_TIME
           
static String EVENT_NAME_GET_INVITE_STATUS
           
 
Fields inherited from class org.alfresco.bm.event.AbstractEventProcessor
DEFAULT_WARN_DELAY, logger
 
Constructor Summary
InviteUser(org.springframework.data.mongodb.core.MongoTemplate mongo, String userData, String alfrescoUrl)
           
 
Method Summary
 org.alfresco.bm.event.EventResult processEvent(org.alfresco.bm.event.Event event)
           
 void setApiSignupQueue(String apiSignupQueue)
          Override the default URL part to the signup queue api.
 void setEventNameGetInviteStatus(String eventNameGetInviteStatus)
          Override the default event name for 'get invite status'.
 void setMaxAcceptTime(long maxAcceptTime)
          Override the default maximum time for the user to accept the invite.
 void setMinAcceptTime(long minAcceptTime)
          Override the default minimum time for the user to accept the invite.
 
Methods inherited from class org.alfresco.bm.event.AbstractEventProcessor
getWarnDelay, register, setBeanName, setEventName, setEventNames, setRegistry, setWarnDelay
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

DEFAULT_MIN_ACCEPT_TIME

public static final long DEFAULT_MIN_ACCEPT_TIME
See Also:
Constant Field Values

DEFAULT_MAX_ACCEPT_TIME

public static final long DEFAULT_MAX_ACCEPT_TIME
See Also:
Constant Field Values

DEFAULT_API_SIGNUP_QUEUE

public static final String DEFAULT_API_SIGNUP_QUEUE
See Also:
Constant Field Values

EVENT_NAME_GET_INVITE_STATUS

public static final String EVENT_NAME_GET_INVITE_STATUS
See Also:
Constant Field Values
Constructor Detail

InviteUser

public InviteUser(org.springframework.data.mongodb.core.MongoTemplate mongo,
                  String userData,
                  String alfrescoUrl)
Parameters:
mongo - connection to MongoDB
userData - name of DB collection containing user details
alfrescoUrl - the Alfresco root URL e.g. http://localhost:8080/
Method Detail

setApiSignupQueue

public void setApiSignupQueue(String apiSignupQueue)
Override the default URL part to the signup queue api.


setMinAcceptTime

public void setMinAcceptTime(long minAcceptTime)
Override the default minimum time for the user to accept the invite.


setMaxAcceptTime

public void setMaxAcceptTime(long maxAcceptTime)
Override the default maximum time for the user to accept the invite.


setEventNameGetInviteStatus

public void setEventNameGetInviteStatus(String eventNameGetInviteStatus)
Override the default event name for 'get invite status'.


processEvent

public org.alfresco.bm.event.EventResult processEvent(org.alfresco.bm.event.Event event)
                                               throws Exception
Throws:
Exception


Copyright © 2012. All Rights Reserved.