@Override public void write(String str){
  int start=0;
  while (start < str.length()) {
    int end=Math.min(start + MAX_MESSAGE_LENGTH,str.length());
    Log.i(TAG,str.substring(start,end));
    start=end;
  }
}

@ Override public void write ( String str ) { int start = 0 ; while ( start < str . length ( ) ) { int end = Math . min ( start + MAX_MESSAGE_LENGTH , str . length ( ) ) ; Log . i ( TAG , str . substring ( start , end ) ) ; start = end ; } }
writes the given string to android logcat .
