public class SignupPlugin extends de.deepamehta.plugins.webactivator.WebActivatorPlugin implements SignupPluginService, PostUpdateTopicListener
Modifier and Type | Field and Description |
---|---|
private AccessControlService |
acService |
private String |
CONFIG_CSS_PATH |
private String |
CONFIG_LOGO_PATH |
private String |
CONFIG_PAGES_FOOTER |
private String |
CONFIG_PD_DETAILS |
private String |
CONFIG_PD_LABEL |
private String |
CONFIG_PROJECT_TITLE |
private String |
CONFIG_READ_MORE_URL |
private String |
CONFIG_TOS_DETAILS |
private String |
CONFIG_TOS_LABEL |
private String |
CONFIG_WEBAPP_TITLE |
private Topic |
currentModuleConfiguration |
private static Logger |
log |
static String |
MAILBOX_TYPE_URI |
private String |
SIGN_UP_CONFIG_TYPE_URI |
private String |
SIGN_UP_PLUGIN_TOPIC_URI |
(package private) HashMap<String,org.codehaus.jettison.json.JSONObject> |
token |
(package private) javax.ws.rs.core.UriInfo |
uri |
(package private) static DeepaMehtaEvent |
USER_ACCOUNT_CREATE_LISTENER |
static String |
WS_DM_DEFAULT_URI |
private WorkspacesService |
wsService |
bundle, dms
Constructor and Description |
---|
SignupPlugin() |
Modifier and Type | Method and Description |
---|---|
private String |
createSimpleUserAccount(String username,
String password,
String mailbox) |
String |
createUserValidationToken(String username,
String password,
String mailbox)
Creates a token for username and "E Mail Address" for the creation of a
new "User Account" topic.
|
com.sun.jersey.api.view.Viewable |
getAccountCreationOKView() |
com.sun.jersey.api.view.Viewable |
getConfirmationInfoView() |
private Topic |
getCurrentSignupConfiguration()
The sign-up configuration object is loaded once when this bundle/plugin is
initialized by the framework and as soon as one configuration was edited.
|
com.sun.jersey.api.view.Viewable |
getFailureView() |
com.sun.jersey.api.view.Viewable |
getLoginFormView()
--- Sign-up Routes ---
|
String |
getMailboxAvailability(String email) |
com.sun.jersey.api.view.Viewable |
getSignupFormView() |
String |
getUsernameAvailability(String username)
Plugin Service Implementation
|
com.sun.jersey.api.view.Viewable |
handleTokenRequest(String key) |
void |
init() |
private boolean |
isMailboxTaken(String email) |
private boolean |
isUsernameTaken(String username) |
void |
postUpdateTopic(Topic topic,
TopicModel tm,
TopicModel tm1) |
private void |
prepareSignupPage() |
private Topic |
reloadConfiguration()
Loads the next sign-up configuration topic for this plugin.
|
private void |
sendConfirmationMail(String key,
String username,
String mailbox) |
private void |
sendNotificationMail(String username,
String mailbox) |
private void |
sendSystemMail(String subject,
String message,
String recipient) |
getTemplateEngine, initTemplateEngine, serviceRequestFilter, view, viewData
getBundleContext, getPluginName, getStaticResource, getUri, preInstall, publishFileSystem, serviceArrived, serviceGone, setCoreService, shutdown, start, stop, toString
public static final String MAILBOX_TYPE_URI
public static final String WS_DM_DEFAULT_URI
private final String SIGN_UP_PLUGIN_TOPIC_URI
private final String SIGN_UP_CONFIG_TYPE_URI
private final String CONFIG_PROJECT_TITLE
private final String CONFIG_WEBAPP_TITLE
private final String CONFIG_LOGO_PATH
private final String CONFIG_CSS_PATH
private final String CONFIG_READ_MORE_URL
private final String CONFIG_PAGES_FOOTER
private final String CONFIG_TOS_LABEL
private final String CONFIG_TOS_DETAILS
private final String CONFIG_PD_LABEL
private final String CONFIG_PD_DETAILS
private Topic currentModuleConfiguration
private AccessControlService acService
private WorkspacesService wsService
@Context javax.ws.rs.core.UriInfo uri
static DeepaMehtaEvent USER_ACCOUNT_CREATE_LISTENER
public SignupPlugin()
public void init()
init
in interface PluginContext
init
in class PluginActivator
public String getUsernameAvailability(String username)
getUsernameAvailability
in interface SignupPluginService
public String getMailboxAvailability(String email)
private String createSimpleUserAccount(String username, String password, String mailbox)
public String createUserValidationToken(String username, String password, String mailbox)
SignupPluginService
createUserValidationToken
in interface SignupPluginService
password
- String Password in cleartext.public com.sun.jersey.api.view.Viewable handleTokenRequest(String key)
private Topic reloadConfiguration()
init()
,
postUpdateTopic()
private void sendConfirmationMail(String key, String username, String mailbox)
private void sendNotificationMail(String username, String mailbox)
private void sendSystemMail(String subject, String message, String recipient)
private boolean isUsernameTaken(String username)
private boolean isMailboxTaken(String email)
private Topic getCurrentSignupConfiguration()
reloadConfiguration()
public com.sun.jersey.api.view.Viewable getLoginFormView()
public com.sun.jersey.api.view.Viewable getSignupFormView()
public com.sun.jersey.api.view.Viewable getAccountCreationOKView()
public com.sun.jersey.api.view.Viewable getFailureView()
public com.sun.jersey.api.view.Viewable getConfirmationInfoView()
private void prepareSignupPage()
public void postUpdateTopic(Topic topic, TopicModel tm, TopicModel tm1)
postUpdateTopic
in interface PostUpdateTopicListener
Copyright © 2015. All Rights Reserved.