Author: rdonkin
Date: Sat Nov 8 06:04:39 2008
New Revision: 712395
URL: http://svn.apache.org/viewvc?rev=712395&view=rev
Log:
Improved javadocs src/main/java/org/apache/mailet/base/StringUtils.java
Added:
james/mailet/base/trunk/src/main/java/org/apache/mailet/base/package.html
Modified:
james/mailet/base/trunk/src/main/java/org/apache/mailet/base/StringUtils.java
Modified:
james/mailet/base/trunk/src/main/java/org/apache/mailet/base/StringUtils.java
URL:
http://svn.apache.org/viewvc/james/mailet/base/trunk/src/main/java/org/apache/mailet/base/StringUtils.java?rev=712395&r1=712394&r2=712395&view=diff
==============================================================================
---
james/mailet/base/trunk/src/main/java/org/apache/mailet/base/StringUtils.java
(original)
+++
james/mailet/base/trunk/src/main/java/org/apache/mailet/base/StringUtils.java
Sat Nov 8 06:04:39 2008
@@ -23,6 +23,9 @@
import java.security.NoSuchAlgorithmException;
import java.util.ArrayList;
+/**
+ * Collects useful string utility methods.
+ */
public final class StringUtils {
private StringUtils() {
@@ -58,6 +61,12 @@
return (String[]) list.toArray(new String[0]);
}
+ /**
+ * Creates an MD5 digest from the message.
+ * Note that this implementation is unsalted.
+ * @param message not null
+ * @return MD5 digest, not null
+ */
public static String md5(java.lang.String message) {
try {
MessageDigest md = MessageDigest.getInstance("MD5");
@@ -76,6 +85,13 @@
}
}
+ /**
+ * Capitalizes each word in the given text by converting the
+ * first letter to upper case.
+ * @param data text to be capitalize, possibly null
+ * @return text with each work capitalized,
+ * or null when the text is null
+ */
public static String capitalizeWords(String data) {
if (data==null) return null;
StringBuffer res = new StringBuffer();
Added: james/mailet/base/trunk/src/main/java/org/apache/mailet/base/package.html
URL:
http://svn.apache.org/viewvc/james/mailet/base/trunk/src/main/java/org/apache/mailet/base/package.html?rev=712395&view=auto
==============================================================================
--- james/mailet/base/trunk/src/main/java/org/apache/mailet/base/package.html
(added)
+++ james/mailet/base/trunk/src/main/java/org/apache/mailet/base/package.html
Sat Nov 8 06:04:39 2008
@@ -0,0 +1,27 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+-->
+<body>
+<p><a href='http://james.apache.org/mailet/base'>Apache James Mailets Base</a>
+collects a number of utilites and lightweight frameworks useful when working
+with the <a href='http://james.apache.org/mailet'>Apache Mailet API</a> (a
framework
+assisting the rapid development of email processing functionality).
+Mailets base is used as the basis for the email processing functions shipped
+with the <a href='http://james.apache.org/server'>Apache James</a> server
+but is not dependent on that server.</p>
+</body>
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]