diff src/ch/ethz/ssh2/util/StringEncoder.java @ 308:42b15aaa7ac7 ganymed

merge
author Carl Byington <carl@five-ten-sg.com>
date Wed, 30 Jul 2014 14:21:50 -0700
parents 071eccdff8ea
children
line wrap: on
line diff
--- a/src/ch/ethz/ssh2/util/StringEncoder.java	Wed Jul 30 13:38:04 2014 -0700
+++ b/src/ch/ethz/ssh2/util/StringEncoder.java	Wed Jul 30 14:21:50 2014 -0700
@@ -11,29 +11,25 @@
  * @author Christian Plattner
  * @version $Id: StringEncoder.java 43 2011-06-21 18:34:06Z dkocher@sudo.ch $
  */
-public class StringEncoder
-{
-	public static byte[] GetBytes(String data)
-	{
+public class StringEncoder {
+    public static byte[] GetBytes(String data) {
         try {
             return data.getBytes("UTF-8");
         }
-        catch(UnsupportedEncodingException e) {
+        catch (UnsupportedEncodingException e) {
             throw new RuntimeException(e);
         }
     }
 
-	public static String GetString(byte[] data)
-	{
-		return GetString(data, 0, data.length);
-	}
+    public static String GetString(byte[] data) {
+        return GetString(data, 0, data.length);
+    }
 
-	public static String GetString(byte[] data, int off, int len)
-	{
+    public static String GetString(byte[] data, int off, int len) {
         try {
             return new String(data, off, len, "UTF-8");
         }
-        catch(UnsupportedEncodingException e) {
+        catch (UnsupportedEncodingException e) {
             throw new RuntimeException(e);
         }
     }