diff options
author | Ade Lee <alee@redhat.com> | 2011-12-08 21:15:59 -0500 |
---|---|---|
committer | Ade Lee <alee@redhat.com> | 2011-12-08 21:15:59 -0500 |
commit | 171aaece4f23709d33d180cf36eb3af5e454b0c9 (patch) | |
tree | 1485f9f0a7bd10de4ff25030db575dbb8dafae74 /pki/base/common/src/com/netscape/cmscore/cert/PrettyPrintFormat.java | |
parent | adad2fcee8a29fdb82376fbce07dedb11fccc182 (diff) | |
download | pki-171aaece4f23709d33d180cf36eb3af5e454b0c9.tar.gz pki-171aaece4f23709d33d180cf36eb3af5e454b0c9.tar.xz pki-171aaece4f23709d33d180cf36eb3af5e454b0c9.zip |
Revert "Formatting"
This reverts commit 32150d3ee32f8ac27118af7c792794b538c78a2f.
Diffstat (limited to 'pki/base/common/src/com/netscape/cmscore/cert/PrettyPrintFormat.java')
-rw-r--r-- | pki/base/common/src/com/netscape/cmscore/cert/PrettyPrintFormat.java | 89 |
1 files changed, 45 insertions, 44 deletions
diff --git a/pki/base/common/src/com/netscape/cmscore/cert/PrettyPrintFormat.java b/pki/base/common/src/com/netscape/cmscore/cert/PrettyPrintFormat.java index 137901ae3..3ace3c67b 100644 --- a/pki/base/common/src/com/netscape/cmscore/cert/PrettyPrintFormat.java +++ b/pki/base/common/src/com/netscape/cmscore/cert/PrettyPrintFormat.java @@ -17,39 +17,40 @@ // --- END COPYRIGHT BLOCK --- package com.netscape.cmscore.cert; + import com.netscape.certsrv.base.IPrettyPrintFormat; + /** - * This class will display the certificate content in predefined format. - * + * This class will display the certificate content in predefined + * format. + * * @author Andrew Wnuk * @version $Revision$, $Date$ */ public class PrettyPrintFormat implements IPrettyPrintFormat { - /* - * ========================================================== variables - * ========================================================== - */ + /*========================================================== + * variables + *==========================================================*/ private String mSeparator = ""; private int mIndentSize = 0; private int mLineLen = 0; - /* - * ========================================================== constants - * - * ========================================================== - */ - private final static String spaces = " " - + " " - + " " - + " " - + " "; - - /* - * ========================================================== constructors - * ========================================================== - */ + /*========================================================== + * constants + * + *==========================================================*/ + private final static String spaces = + " " + + " " + + " " + + " " + + " "; + + /*========================================================== + * constructors + *==========================================================*/ public PrettyPrintFormat(String separator) { mSeparator = separator; @@ -66,20 +67,18 @@ public class PrettyPrintFormat implements IPrettyPrintFormat { mIndentSize = indentSize; } - /* - * ========================================================== Private - * methods========================================================== - */ - - /* - * ========================================================== public methods - * ========================================================== - */ + /*========================================================== + * Private methods + *==========================================================*/ + + + /*========================================================== + * public methods + *==========================================================*/ /** - * Provide white space indention stevep - speed improvements. Factor of 10 - * improvement - * + * Provide white space indention + * stevep - speed improvements. Factor of 10 improvement * @param numSpace number of white space to be returned * @return white spaces */ @@ -87,23 +86,25 @@ public class PrettyPrintFormat implements IPrettyPrintFormat { return spaces.substring(0, size); } - private static final char[] hexdigits = { '0', '1', '2', '3', '4', '5', - '6', '7', '8', '9', 'A', 'B', 'C', 'D', 'E', 'F' }; + private static final char[] hexdigits = { + '0', '1', '2', '3', '4', '5', '6', '7', '8', '9', + 'A', 'B', 'C', 'D', 'E', 'F' + }; /** - * Convert Byte Array to Hex String Format stevep - speedup by factor of 8 - * + * Convert Byte Array to Hex String Format + * stevep - speedup by factor of 8 * @param byte array of data to hexify * @param indentSize number of spaces to prepend before each line - * @param lineLen number of bytes to output on each line (0 means: put - * everything on one line - * @param separator the first character of this string will be used as the - * separator between bytes. + * @param lineLen number of bytes to output on each line (0 + means: put everything on one line + * @param separator the first character of this string will be used as + the separator between bytes. * @return string representation */ - public String toHexString(byte[] in, int indentSize, int lineLen, - String separator) { + public String toHexString(byte[] in, int indentSize, + int lineLen, String separator) { StringBuffer sb = new StringBuffer(); int hexCount = 0; char c[]; @@ -143,7 +144,7 @@ public class PrettyPrintFormat implements IPrettyPrintFormat { c[j++] = '\n'; sb.append(c, 0, j); } - // sb.append("\n"); + // sb.append("\n"); return sb.toString(); } |