org.apache.jetspeed.modules.actions.portlets.email
Class EmailPortlet

java.lang.Object
  extended byorg.apache.turbine.modules.Assembler
      extended byorg.apache.turbine.modules.Action
          extended byorg.apache.turbine.modules.ActionEvent
              extended byorg.apache.jetspeed.modules.actions.portlets.PortletActionEvent
                  extended byorg.apache.jetspeed.modules.actions.portlets.PortletAction
                      extended byorg.apache.jetspeed.modules.actions.portlets.GenericMVCAction
                          extended byorg.apache.jetspeed.modules.actions.portlets.VelocityPortletAction
                              extended byorg.apache.jetspeed.modules.actions.portlets.email.EmailPortlet

public class EmailPortlet
extends VelocityPortletAction

Email Action

Version:
$Id: EmailPortlet.java,v 1.2 2004/03/22 22:26:58 taylor Exp $
Author:
Jonas Lim

Field Summary
protected static java.lang.String CUSTOMIZE_TEMPLATE
           
 
Fields inherited from class org.apache.jetspeed.modules.actions.portlets.GenericMVCAction
logger
 
Fields inherited from class org.apache.turbine.modules.ActionEvent
BUTTON, BUTTON_LENGTH, LENGTH, METHOD_NAME_LENGTH, METHOD_NAME_PREFIX
 
Constructor Summary
EmailPortlet()
           
 
Method Summary
protected  void buildConfigureContext(VelocityPortlet portlet, org.apache.velocity.context.Context context, org.apache.turbine.util.RunData rundata)
          Subclasses should override this method if they wish to provide their own customization behavior.
protected  void buildMaximizedContext(VelocityPortlet portlet, org.apache.velocity.context.Context context, org.apache.turbine.util.RunData rundata)
          Subclasses should override this method if they wish to build specific content when maximized.
protected  void buildNormalContext(VelocityPortlet portlet, org.apache.velocity.context.Context context, org.apache.turbine.util.RunData rundata)
          Subclasses must override this method to provide default behavior for the portlet action
 java.lang.String checkFormat(java.lang.String msg)
           
 void checkMessages(org.apache.turbine.util.RunData data, org.apache.velocity.context.Context context, Email email)
           
 int checkNewmessage(javax.mail.Message[] message, int current_index)
           
 java.lang.String convertMessage(java.lang.String msg)
           
 void DBdelete(org.apache.turbine.util.RunData data, int current_index, org.apache.velocity.context.Context context)
           
 void DBInsert(org.apache.turbine.util.RunData data, javax.mail.Message message, boolean withAttachment)
           
 void DBmultipleDelete(org.apache.turbine.util.RunData data, java.lang.String[] checkboxes, org.apache.velocity.context.Context context)
           
 void descendingOrder(org.apache.turbine.util.RunData data, org.apache.velocity.context.Context context, java.util.Vector inMessages, int start_index, int range_per_page, int msgectr)
           
 void doAuth(org.apache.turbine.util.RunData data, org.apache.velocity.context.Context context)
           
 void doCompose(org.apache.turbine.util.RunData data, org.apache.velocity.context.Context context)
           
 void doCreatenewfolder(org.apache.turbine.util.RunData data, org.apache.velocity.context.Context context)
           
 void doDelete(org.apache.turbine.util.RunData data, org.apache.velocity.context.Context context)
           
 void doDownload(org.apache.turbine.util.RunData data)
           
 void doFolderdelete(org.apache.turbine.util.RunData data, org.apache.velocity.context.Context context)
           
 void doForward(org.apache.turbine.util.RunData data, org.apache.velocity.context.Context context)
           
 void doForwardsend(org.apache.turbine.util.RunData data, org.apache.velocity.context.Context context)
           
 void doGetfolderdest(org.apache.turbine.util.RunData data, org.apache.velocity.context.Context context)
           
 void doGetfoldername(org.apache.turbine.util.RunData data, org.apache.velocity.context.Context context)
           
 void doInbox(org.apache.turbine.util.RunData data, org.apache.velocity.context.Context context)
           
 void doMovesinglemsge(org.apache.turbine.util.RunData data, org.apache.velocity.context.Context context)
           
 void doNext(org.apache.turbine.util.RunData data, org.apache.velocity.context.Context context)
           
 void doOpenmyfolder(org.apache.turbine.util.RunData data, org.apache.velocity.context.Context context)
           
 void doPrevious(org.apache.turbine.util.RunData data, org.apache.velocity.context.Context context)
           
 void doReply(org.apache.turbine.util.RunData data, org.apache.velocity.context.Context context)
           
 void doSend(org.apache.turbine.util.RunData data, org.apache.velocity.context.Context context)
           
 void doSendreply(org.apache.turbine.util.RunData data, org.apache.velocity.context.Context context)
           
 void doShow(org.apache.turbine.util.RunData data, org.apache.velocity.context.Context context)
           
 void doShowcontent(org.apache.turbine.util.RunData data, org.apache.velocity.context.Context context, Email email)
           
 void doSignout(org.apache.turbine.util.RunData data, org.apache.velocity.context.Context context)
           
 java.util.Hashtable getEmailUserInfo(org.apache.turbine.util.RunData rundata, org.apache.velocity.context.Context context)
          get user authentication info for email.
 java.lang.String getMessageId(javax.mail.Message message)
           
 java.lang.String getPortletParameter(org.apache.turbine.util.RunData data, org.apache.velocity.context.Context context, java.lang.String paramName)
          get portlet parameter from portlet instance.
 java.util.Hashtable getPortletParameters(org.apache.turbine.util.RunData data, org.apache.velocity.context.Context context)
           
 java.lang.Object getPortletSession(org.apache.turbine.util.RunData data, org.apache.velocity.context.Context context, java.lang.String paramName)
          gets the portlet session
 void setMessageflag(javax.mail.Message message)
           
 void setPortletSession(org.apache.turbine.util.RunData data, org.apache.velocity.context.Context context, java.lang.String paramName, java.lang.Object value)
          sets the portlet session
 
Methods inherited from class org.apache.jetspeed.modules.actions.portlets.VelocityPortletAction
buildConfigureContext, buildMaximizedContext, buildNormalContext
 
Methods inherited from class org.apache.jetspeed.modules.actions.portlets.GenericMVCAction
checkAdministrativeAction, doPerform, getAttribute, getAttribute, getPortletInstance, perform, setAttribute
 
Methods inherited from class org.apache.jetspeed.modules.actions.portlets.PortletAction
doPerform, getContext, getPortlet, getTemplate, resetTemplate, setTemplate, setTemplate
 
Methods inherited from class org.apache.jetspeed.modules.actions.portlets.PortletActionEvent
executeEvents, fireEvent
 
Methods inherited from class org.apache.turbine.modules.ActionEvent
executeEvents, formatString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

CUSTOMIZE_TEMPLATE

protected static final java.lang.String CUSTOMIZE_TEMPLATE
See Also:
Constant Field Values
Constructor Detail

EmailPortlet

public EmailPortlet()
Method Detail

buildMaximizedContext

protected void buildMaximizedContext(VelocityPortlet portlet,
                                     org.apache.velocity.context.Context context,
                                     org.apache.turbine.util.RunData rundata)
                              throws java.lang.Exception
Subclasses should override this method if they wish to build specific content when maximized. Default behavior is to do the same as normal content.

Overrides:
buildMaximizedContext in class VelocityPortletAction
Throws:
java.lang.Exception

buildConfigureContext

protected void buildConfigureContext(VelocityPortlet portlet,
                                     org.apache.velocity.context.Context context,
                                     org.apache.turbine.util.RunData rundata)
Subclasses should override this method if they wish to provide their own customization behavior. Default is to use Portal base customizer action

Overrides:
buildConfigureContext in class VelocityPortletAction

buildNormalContext

protected void buildNormalContext(VelocityPortlet portlet,
                                  org.apache.velocity.context.Context context,
                                  org.apache.turbine.util.RunData rundata)
                           throws java.lang.Exception
Subclasses must override this method to provide default behavior for the portlet action

Specified by:
buildNormalContext in class VelocityPortletAction
Throws:
java.lang.Exception

doAuth

public void doAuth(org.apache.turbine.util.RunData data,
                   org.apache.velocity.context.Context context)

doSignout

public void doSignout(org.apache.turbine.util.RunData data,
                      org.apache.velocity.context.Context context)

doCompose

public void doCompose(org.apache.turbine.util.RunData data,
                      org.apache.velocity.context.Context context)
               throws java.lang.Exception
Throws:
java.lang.Exception

checkNewmessage

public int checkNewmessage(javax.mail.Message[] message,
                           int current_index)
                    throws java.lang.Exception
Throws:
java.lang.Exception

doSend

public void doSend(org.apache.turbine.util.RunData data,
                   org.apache.velocity.context.Context context)

doReply

public void doReply(org.apache.turbine.util.RunData data,
                    org.apache.velocity.context.Context context)
             throws java.lang.Exception
Throws:
java.lang.Exception

doSendreply

public void doSendreply(org.apache.turbine.util.RunData data,
                        org.apache.velocity.context.Context context)

doForward

public void doForward(org.apache.turbine.util.RunData data,
                      org.apache.velocity.context.Context context)

doForwardsend

public void doForwardsend(org.apache.turbine.util.RunData data,
                          org.apache.velocity.context.Context context)

doDelete

public void doDelete(org.apache.turbine.util.RunData data,
                     org.apache.velocity.context.Context context)

doShowcontent

public void doShowcontent(org.apache.turbine.util.RunData data,
                          org.apache.velocity.context.Context context,
                          Email email)
                   throws java.lang.Exception
Throws:
java.lang.Exception

doShow

public void doShow(org.apache.turbine.util.RunData data,
                   org.apache.velocity.context.Context context)
            throws java.lang.Exception
Throws:
java.lang.Exception

doInbox

public void doInbox(org.apache.turbine.util.RunData data,
                    org.apache.velocity.context.Context context)
             throws java.lang.Exception
Throws:
java.lang.Exception

checkMessages

public void checkMessages(org.apache.turbine.util.RunData data,
                          org.apache.velocity.context.Context context,
                          Email email)
                   throws java.lang.Exception
Throws:
java.lang.Exception

getMessageId

public java.lang.String getMessageId(javax.mail.Message message)

DBInsert

public void DBInsert(org.apache.turbine.util.RunData data,
                     javax.mail.Message message,
                     boolean withAttachment)

descendingOrder

public void descendingOrder(org.apache.turbine.util.RunData data,
                            org.apache.velocity.context.Context context,
                            java.util.Vector inMessages,
                            int start_index,
                            int range_per_page,
                            int msgectr)

convertMessage

public java.lang.String convertMessage(java.lang.String msg)
                                throws java.lang.Exception
Throws:
java.lang.Exception

checkFormat

public java.lang.String checkFormat(java.lang.String msg)
                             throws java.lang.Exception
Throws:
java.lang.Exception

setMessageflag

public void setMessageflag(javax.mail.Message message)
                    throws java.lang.Exception
Throws:
java.lang.Exception

doNext

public void doNext(org.apache.turbine.util.RunData data,
                   org.apache.velocity.context.Context context)
            throws java.lang.Exception
Throws:
java.lang.Exception

doPrevious

public void doPrevious(org.apache.turbine.util.RunData data,
                       org.apache.velocity.context.Context context)
                throws java.lang.Exception
Throws:
java.lang.Exception

doDownload

public void doDownload(org.apache.turbine.util.RunData data)

DBdelete

public void DBdelete(org.apache.turbine.util.RunData data,
                     int current_index,
                     org.apache.velocity.context.Context context)
              throws java.lang.Exception
Throws:
java.lang.Exception

DBmultipleDelete

public void DBmultipleDelete(org.apache.turbine.util.RunData data,
                             java.lang.String[] checkboxes,
                             org.apache.velocity.context.Context context)
                      throws java.lang.Exception
Throws:
java.lang.Exception

doCreatenewfolder

public void doCreatenewfolder(org.apache.turbine.util.RunData data,
                              org.apache.velocity.context.Context context)
                       throws javax.mail.AuthenticationFailedException,
                              javax.mail.NoSuchProviderException,
                              java.lang.Exception
Throws:
javax.mail.AuthenticationFailedException
javax.mail.NoSuchProviderException
java.lang.Exception

doGetfoldername

public void doGetfoldername(org.apache.turbine.util.RunData data,
                            org.apache.velocity.context.Context context)

doGetfolderdest

public void doGetfolderdest(org.apache.turbine.util.RunData data,
                            org.apache.velocity.context.Context context)

doMovesinglemsge

public void doMovesinglemsge(org.apache.turbine.util.RunData data,
                             org.apache.velocity.context.Context context)

doOpenmyfolder

public void doOpenmyfolder(org.apache.turbine.util.RunData data,
                           org.apache.velocity.context.Context context)

doFolderdelete

public void doFolderdelete(org.apache.turbine.util.RunData data,
                           org.apache.velocity.context.Context context)

getEmailUserInfo

public java.util.Hashtable getEmailUserInfo(org.apache.turbine.util.RunData rundata,
                                            org.apache.velocity.context.Context context)
get user authentication info for email. Check first in porlet instance. If not found retrieve current user name and password


getPortletParameter

public java.lang.String getPortletParameter(org.apache.turbine.util.RunData data,
                                            org.apache.velocity.context.Context context,
                                            java.lang.String paramName)
get portlet parameter from portlet instance. if not found, get from registry


setPortletSession

public void setPortletSession(org.apache.turbine.util.RunData data,
                              org.apache.velocity.context.Context context,
                              java.lang.String paramName,
                              java.lang.Object value)
sets the portlet session


getPortletSession

public java.lang.Object getPortletSession(org.apache.turbine.util.RunData data,
                                          org.apache.velocity.context.Context context,
                                          java.lang.String paramName)
gets the portlet session


getPortletParameters

public java.util.Hashtable getPortletParameters(org.apache.turbine.util.RunData data,
                                                org.apache.velocity.context.Context context)


Copyright © 2000-2005 Apache Software Foundation. All Rights Reserved.