@@ -0,0 +1,1801 @@
+/*%0A * Copyright (c) 2014 Magnet Systems, Inc.%0A * All rights reserved.%0A *%0A * Licensed under the Apache License, Version 2.0 (the %22License%22); you%0A * may not use this file except in compliance with the License. You%0A * may obtain a copy of the License at%0A *%0A * http://www.apache.org/licenses/LICENSE-2.0%0A *%0A * Unless required by applicable law or agreed to in writing, software%0A * distributed under the License is distributed on an %22AS IS%22 BASIS,%0A * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or%0A * implied. See the License for the specific language governing%0A * permissions and limitations under the License.%0A */%0A%0Apackage com.magnet.plugin.common;%0A%0Aimport com.magnet.plugin.common.Logger;%0A%0A/**%0A * Logger for debugging%0A */%0Apublic class FormattedLogger %7B%0A    private StringBuilder message;%0A    private Class aClass;%0A    private static final String CLASS_DIVIDER = %22 : %22;%0A    private static final String ACTION_DIVIDER = %22 -%3E %22;%0A%0A    public FormattedLogger(Class aClass) %7B%0A        message = new StringBuilder();%0A        this.aClass = aClass;%0A        append(this.aClass.getSimpleName(), CLASS_DIVIDER);%0A    %7D%0A%0A    public void append(String... strings) %7B%0A        for (String s : strings) %7B%0A            message.append(s);%0A        %7D%0A    %7D%0A%0A    public void appendAction(String strings) %7B%0A        append(strings, ACTION_DIVIDER);%0A    %7D%0A%0A    public void appendAction(String... strings) %7B%0A        for (String s : strings) %7B%0A            append(s, ACTION_DIVIDER);%0A        %7D%0A    %7D%0A%0A    public void clearMessage() %7B%0A        message = new StringBuilder();%0A        append(this.aClass.getSimpleName(), CLASS_DIVIDER);%0A    %7D%0A%0A    public void showInfoLog() %7B%0A        Logger.showLogInfo(message.toString());%0A    %7D%0A%0A    public void showErrorLog() %7B%0A        Logger.showLogError(message.toString());%0A    %7D%0A%0A%7D%0A

refactor FormattedLogger