X-Git-Url: http://erislabs.net/gitweb/?a=blobdiff_plain;f=source%2Fmir%2Fmisc%2FStringUtil.java;h=6a3eb9d8152f01430e137079884bcfd44b2cd612;hb=d3cd728a6b5dfffd3492f3c95d3794eae906b7aa;hp=93d4c6b24332ba1311295e2c15af114aa72fb2d5;hpb=ab7e92f3859bbf356769744433a8bd1fb2fbc1b3;p=mir.git diff --git a/source/mir/misc/StringUtil.java b/source/mir/misc/StringUtil.java index 93d4c6b2..6a3eb9d8 100755 --- a/source/mir/misc/StringUtil.java +++ b/source/mir/misc/StringUtil.java @@ -40,18 +40,11 @@ import gnu.regexp.*; /** * Statische Hilfsmethoden zur Stringbehandlung * - * @version $Revision: 1.23.2.1 $ $Date: 2002/09/01 21:31:40 $ - * @author $Author: mh $ - * - * $Log: StringUtil.java,v $ - * Revision 1.23.2.1 2002/09/01 21:31:40 mh - * Mir goes GPL - * - * Revision 1.23 2002/06/28 20:39:37 mh - * added numberformat helper. make webdbDate2readableDate use webdb_create instead. make the order and appearance of it more consistent. cvs macros. and finally code tidying - * + * @version $Id: StringUtil.java,v 1.23.2.2 2002/11/28 05:52:40 mh Exp $ + * @author rk, mir-coders group * */ + public final class StringUtil { private static RE re_newline2br, re_brbr2p, re_mail, re_url, re_tags; @@ -597,39 +590,6 @@ public final class StringUtil { return buf.toString(); } - - public static String decodeHTMLinTags(String s){ - StringBuffer buffer = new StringBuffer(); - boolean start = false; - boolean stop = false; - int startIndex = 0; - int stopIndex = 0; - int temp = 0; - - for(int i=0;i'){ - stop = true; - stopIndex = i; - - if(start && stop){ - buffer.append(s.substring(temp,startIndex)); - buffer.append(replaceQuot(s.substring(startIndex,stopIndex+1))); - i= temp= stopIndex+1; - start= stop= false; - } - } - } - if(stopIndex>0){ - buffer.append(s.substring(stopIndex+1)); - return buffer.toString(); - } else { - return s; - } - } - public static String replaceQuot(String s) { StringBuffer buffer = new StringBuffer(); for(int j = 0; j < s.length();j++){ @@ -645,50 +605,6 @@ public final class StringUtil { return buffer.toString(); } - /** wandelt Quotes in Sonderzeichen um - */ - /** - public static String decodeHtml(String s) { - StringBuffer buf = new StringBuffer(); - for(int i=0;i < s.length(); i++ ) { - if( s.indexOf( "ö", i ) == i ) { - buf.append( "ö" ); i += 5; - continue; - } - if( s.indexOf( "ä", i ) == i ) { - buf.append( "ä" ); i += 5; - continue; - } - if( s.indexOf( "ü", i ) == i ) { - buf.append( "ü" ); i += 5; - continue; - } - if( s.indexOf( "Ö", i ) == i ) { - buf.append( "Ö" ); i += 5; - continue; - } - if( s.indexOf( "Ä", i ) == i ) { - buf.append( "Ä" ); i += 5; - continue; - } - if( s.indexOf( "Ü", i ) == i ) { - buf.append( "Ü" ); i += 5; - continue; - } - if( s.indexOf( "ß", i ) == i ) { - buf.append( "ß" ); i += 6; - continue; - } - if( s.indexOf( """, i ) == i ) { - buf.append( "\"" ); i += 5; - continue; - } - buf.append( s.charAt(i) ); - } - return buf.toString(); - } - */ - /** * schnellere Variante der String.toLowerCase()-Routine *