public class SignupPlugin extends de.deepamehta.thymeleaf.ThymeleafPlugin implements SignupPluginService, de.deepamehta.core.service.event.PostUpdateTopicListener
Modifier and Type | Field and Description |
---|---|
static String |
CONFIG_TOPIC_ACCOUNT_ENABLED |
static boolean |
DM4_ACCOUNTS_ENABLED |
static String |
DM4_HOST_URL |
static String |
MAILBOX_TYPE_URI |
Constructor and Description |
---|
SignupPlugin() |
Modifier and Type | Method and Description |
---|---|
void |
addTemplateResolverBundle(org.osgi.framework.Bundle bundle)
IMPORTANT: If you register your own bundle as a resource for thymeleaf templates you must call
reinitTemplateEngine afterwards.
|
String |
createAPIWorkspaceMembershipRequest() |
com.sun.jersey.api.view.Viewable |
getAccountCreationOKView(String username) |
com.sun.jersey.api.view.Viewable |
getAccountCreationPendingView() |
com.sun.jersey.api.view.Viewable |
getAccountDetailsView() |
com.sun.jersey.api.view.Viewable |
getConfirmationInfoView() |
com.sun.jersey.api.view.Viewable |
getFailureView() |
com.sun.jersey.api.view.Viewable |
getLoginView() |
String |
getMailboxAvailability(String email) |
com.sun.jersey.api.view.Viewable |
getPasswordResetView() |
com.sun.jersey.api.view.Viewable |
getSignupFormView() |
String |
getTranslationTable(String language) |
String |
getUsernameAvailability(String username)
Checks for a Topic with the exact "username" value.
|
com.sun.jersey.api.view.Viewable |
handlePasswordResetRequest(String token) |
com.sun.jersey.api.view.Viewable |
handleSignupRequest(String username,
String password,
String mailbox)
Handles a sign-up request in regards to whether an Email based confirmation process is configured (true|false)
in the resp.
|
com.sun.jersey.api.view.Viewable |
handleSignupRequest(String username,
String password,
String mailbox,
boolean skipConfirmation) |
void |
init() |
javax.ws.rs.core.Response |
initiatePasswordReset(String email) |
boolean |
isMailboxTaken(String email) |
boolean |
isValidEmailAddress(String value) |
void |
postUpdateTopic(de.deepamehta.core.Topic topic,
de.deepamehta.core.model.TopicModel tm,
de.deepamehta.core.model.TopicModel tm1) |
com.sun.jersey.api.view.Viewable |
processPasswordUpdateRequest(String token,
String password) |
com.sun.jersey.api.view.Viewable |
processSignupRequest(String key) |
void |
reinitTemplateEngine() |
void |
removeTemplateResolverBundle(org.osgi.framework.Bundle bundle) |
void |
sendSystemMailboxNotification(String subject,
String message)
Send notification email to system administrator mailbox configured in current \"Sign-up Configuration\" topic.
|
void |
sendUserMailboxNotification(String mailbox,
String subject,
String message)
Send notification email to all mailboxes in String (many are seperated by a simple ";" and without spaces.
|
addTemplateResourceBundle, getTemplateEngine, initTemplateEngine, removeTemplateResourceBundle, serviceRequestFilter, view, viewData
public static final String MAILBOX_TYPE_URI
public static final String DM4_HOST_URL
public static final boolean DM4_ACCOUNTS_ENABLED
public static final String CONFIG_TOPIC_ACCOUNT_ENABLED
public void init()
init
in interface de.deepamehta.core.osgi.PluginContext
init
in class de.deepamehta.core.osgi.PluginActivator
public String getUsernameAvailability(String username)
SignupPluginService
getUsernameAvailability
in interface SignupPluginService
public javax.ws.rs.core.Response initiatePasswordReset(String email) throws URISyntaxException
URISyntaxException
public com.sun.jersey.api.view.Viewable handlePasswordResetRequest(String token)
public com.sun.jersey.api.view.Viewable processPasswordUpdateRequest(String token, String password)
public com.sun.jersey.api.view.Viewable handleSignupRequest(String username, String password, String mailbox, boolean skipConfirmation) throws javax.ws.rs.WebApplicationException
javax.ws.rs.WebApplicationException
public com.sun.jersey.api.view.Viewable handleSignupRequest(String username, String password, String mailbox) throws javax.ws.rs.WebApplicationException
SignupPluginService
Sign-up Configuration
topic.
To check whether a username is already taken you *must* use the getUsernameAvailability() call before issueing
an account creation request via this method.handleSignupRequest
in interface SignupPluginService
username
- String Unique username.password
- String SHA256 encoded password with a prefix of "-SHA26-"mailbox
- String containing a valid Email address related to the account creation request.javax.ws.rs.WebApplicationException
public com.sun.jersey.api.view.Viewable processSignupRequest(String key)
public String createAPIWorkspaceMembershipRequest()
createAPIWorkspaceMembershipRequest
in interface SignupPluginService
public void postUpdateTopic(de.deepamehta.core.Topic topic, de.deepamehta.core.model.TopicModel tm, de.deepamehta.core.model.TopicModel tm1)
postUpdateTopic
in interface de.deepamehta.core.service.event.PostUpdateTopicListener
public com.sun.jersey.api.view.Viewable getSignupFormView()
public com.sun.jersey.api.view.Viewable getLoginView()
public com.sun.jersey.api.view.Viewable getPasswordResetView()
public com.sun.jersey.api.view.Viewable getAccountCreationOKView(String username)
public com.sun.jersey.api.view.Viewable getAccountCreationPendingView()
public com.sun.jersey.api.view.Viewable getFailureView()
public com.sun.jersey.api.view.Viewable getConfirmationInfoView()
public com.sun.jersey.api.view.Viewable getAccountDetailsView()
public void sendSystemMailboxNotification(String subject, String message)
SignupPluginService
sendSystemMailboxNotification
in interface SignupPluginService
public void sendUserMailboxNotification(String mailbox, String subject, String message)
SignupPluginService
sendUserMailboxNotification
in interface SignupPluginService
public boolean isMailboxTaken(String email)
isMailboxTaken
in interface SignupPluginService
public boolean isValidEmailAddress(String value)
isValidEmailAddress
in interface SignupPluginService
public void reinitTemplateEngine()
reinitTemplateEngine
in interface SignupPluginService
public void addTemplateResolverBundle(org.osgi.framework.Bundle bundle)
SignupPluginService
addTemplateResolverBundle
in interface SignupPluginService
public void removeTemplateResolverBundle(org.osgi.framework.Bundle bundle)
removeTemplateResolverBundle
in interface SignupPluginService
Copyright © 2017. All rights reserved.