Java Doc for GenericMailet.java in  » Web-Mail » james-2.3.1 » org » apache » mailet » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » Web Mail » james 2.3.1 » org.apache.mailet 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   org.apache.mailet.GenericMailet

All known Subclasses:   org.apache.james.transport.mailets.Null,  org.apache.james.transport.mailets.smime.SMIMEDecrypt,  org.apache.james.transport.mailets.AbstractAddFooter,  org.apache.james.transport.mailets.PostmasterAlias,  org.apache.james.transport.mailets.ServerTime,  org.apache.james.transport.mailets.CommandListservManager,  org.apache.james.transport.mailets.SetMimeHeader,  org.apache.james.transport.mailets.GenericListservManager,  org.apache.james.transport.mailets.JDBCAlias,  org.apache.james.transport.mailets.LocalDelivery,  org.apache.james.transport.mailets.FromRepository,  org.apache.james.transport.mailets.MailetLoaderTestMailet,  org.apache.james.transport.mailets.UsersRepositoryAliasingForwarding,  org.apache.james.transport.mailets.ToProcessor,  org.apache.james.transport.mailets.debug.Identity,  org.apache.james.transport.mailets.GenericListserv,  org.apache.james.transport.mailets.smime.SMIMECheckSignature,  org.apache.james.transport.mailets.AbstractVirtualUserTable,  org.apache.james.transport.mailets.debug.ExceptionThrowingMailet,  org.apache.james.transport.mailets.RemoveMailAttribute,  org.apache.james.transport.mailets.debug.Counter,  org.apache.james.transport.mailets.AbstractRedirect,  org.apache.james.transport.mailets.debug.DumpSystemErr,  org.apache.james.transport.mailets.WhiteListManager,  org.apache.james.transport.mailets.BayesianAnalysisFeeder,  org.apache.james.transport.mailets.BayesianAnalysis,  org.apache.james.transport.mailets.RemoteDelivery,  org.apache.james.transport.mailets.ToRepository,  org.apache.james.transport.mailets.CommandListservProcessor,  org.apache.james.transport.mailets.ClamAVScan,  org.apache.james.transport.mailets.AddHabeasWarrantMark,  org.apache.james.transport.mailets.UseHeaderRecipients,  org.apache.james.transport.mailets.smime.SMIMEAbstractSign,  org.apache.james.transport.mailets.SetMailAttribute,  org.apache.james.transport.mailets.RemoveAllMailAttributes,  org.apache.james.transport.mailets.LogMessage,  org.apache.james.transport.mailets.ToMultiRepository,
GenericMailet
abstract public class GenericMailet implements Mailet,MailetConfig(Code)
GenericMailet makes writing mailets easier. It provides simple versions of the lifecycle methods init and destroy and of the methods in the MailetConfig interface. GenericMailet also implements the log method, declared in the MailetContext interface.

To write a generic mailet, you need only override the abstract service method.
version:
   1.0.0, 24/04/1999





Method Summary
public  voiddestroy()
     Called by the mailer container to indicate to a mailet that the mailet is being taken out of service.
public  StringgetInitParameter(String name)
     Returns a String containing the value of the named initialization parameter, or null if the parameter does not exist.

This method is supplied for convenience.

public  StringgetInitParameter(String name, String defValue)
     Returns a String containing the value of the named initialization parameter, or defValue if the parameter does not exist.

This method is supplied for convenience.

public  IteratorgetInitParameterNames()
     Returns the names of the mailet's initialization parameters as an Iterator of String objects, or an empty Iterator if the mailet has no initialization parameters.

This method is supplied for convenience.

public  MailetConfiggetMailetConfig()
     Returns this Mailet's MailetConfig object.
public  MailetContextgetMailetContext()
     Returns a reference to the MailetContext in which this mailet is running.
public  StringgetMailetInfo()
     Returns information about the mailet, such as author, version, and copyright.
public  StringgetMailetName()
     Returns the name of this mailet instance.
public  voidinit(MailetConfig newConfig)
    

Called by the mailet container to indicate to a mailet that the mailet is being placed into service.

This implementation stores the MailetConfig object it receives from the mailet container for later use.

public  voidinit()
    

A convenience method which can be overridden so that there's no need to call super.init(config).

Instead of overriding init(MailetConfig), simply override this method and it will be called by GenericMailet.init(MailetConfig config).
public  voidlog(String message)
     Writes the specified message to a mailet log file, prepended by the mailet's name.
public  voidlog(String message, Throwable t)
     Writes an explanatory message and a stack trace for a given Throwable exception to the mailet log file, prepended by the mailet's name.
abstract public  voidservice(Mail mail)
    



Method Detail
destroy
public void destroy()(Code)
Called by the mailer container to indicate to a mailet that the mailet is being taken out of service.



getInitParameter
public String getInitParameter(String name)(Code)
Returns a String containing the value of the named initialization parameter, or null if the parameter does not exist.

This method is supplied for convenience. It gets the value of the named parameter from the mailet's MailetConfig object.
Parameters:
  name - - a String specifying the name of the initialization parameter a String containing the value of the initalization parameter




getInitParameter
public String getInitParameter(String name, String defValue)(Code)
Returns a String containing the value of the named initialization parameter, or defValue if the parameter does not exist.

This method is supplied for convenience. It gets the value of the named parameter from the mailet's MailetConfig object.
Parameters:
  name - - a String specifying the name of the initialization parameter
Parameters:
  defValue - - a String specifying the default value when the parameteris not present a String containing the value of the initalization parameter




getInitParameterNames
public Iterator getInitParameterNames()(Code)
Returns the names of the mailet's initialization parameters as an Iterator of String objects, or an empty Iterator if the mailet has no initialization parameters.

This method is supplied for convenience. It gets the parameter names from the mailet's MailetConfig object. an Iterator of String objects containing the names ofthe mailet's initialization parameters




getMailetConfig
public MailetConfig getMailetConfig()(Code)
Returns this Mailet's MailetConfig object. the MailetConfig object that initialized this mailet



getMailetContext
public MailetContext getMailetContext()(Code)
Returns a reference to the MailetContext in which this mailet is running. the MailetContext object passed to this mailet by the init method



getMailetInfo
public String getMailetInfo()(Code)
Returns information about the mailet, such as author, version, and copyright. By default, this method returns an empty string. Override this method to have it return a meaningful value. information about this mailet, by default an empty string



getMailetName
public String getMailetName()(Code)
Returns the name of this mailet instance. the name of this mailet instance



init
public void init(MailetConfig newConfig) throws MessagingException(Code)

Called by the mailet container to indicate to a mailet that the mailet is being placed into service.

This implementation stores the MailetConfig object it receives from the mailet container for later use. When overriding this form of the method, call super.init(config).


Parameters:
  MailetConfig - newconfig - the MailetConfig object that containsconfigutation information for this mailet
throws:
  MessagingException - if an exception occurs that interrupts the mailet's normal operation



init
public void init() throws MessagingException(Code)

A convenience method which can be overridden so that there's no need to call super.init(config).

Instead of overriding init(MailetConfig), simply override this method and it will be called by GenericMailet.init(MailetConfig config). The MailetConfig object can still be retrieved via getMailetConfig().
throws:
  MessagingException - if an exception occurs that interrupts the mailet's normal operation



log
public void log(String message)(Code)
Writes the specified message to a mailet log file, prepended by the mailet's name.
Parameters:
  message - - a String specifying the message to be written to the log file



log
public void log(String message, Throwable t)(Code)
Writes an explanatory message and a stack trace for a given Throwable exception to the mailet log file, prepended by the mailet's name.
Parameters:
  message - - a String that describes the error or exception
Parameters:
  t - - the java.lang.Throwable to be logged



service
abstract public void service(Mail mail) throws javax.mail.MessagingException(Code)

Called by the mailet container to allow the mailet to process a message.

This method is declared abstract so subclasses must override it.


Parameters:
  mail - - the Mail object that contains the MimeMessage androuting information
throws:
  javax.mail.MessagingException - - if an exception occurs that interferes with the mailet's normal operation



Methods inherited from java.lang.Object
native protected Object clone() throws CloneNotSupportedException(Code)(Java Doc)
public boolean equals(Object obj)(Code)(Java Doc)
protected void finalize() throws Throwable(Code)(Java Doc)
final native public Class getClass()(Code)(Java Doc)
native public int hashCode()(Code)(Java Doc)
final native public void notify()(Code)(Java Doc)
final native public void notifyAll()(Code)(Java Doc)
public String toString()(Code)(Java Doc)
final native public void wait(long timeout) throws InterruptedException(Code)(Java Doc)
final public void wait(long timeout, int nanos) throws InterruptedException(Code)(Java Doc)
final public void wait() throws InterruptedException(Code)(Java Doc)

www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.