2011-06-29 09:01:06 +00:00
|
|
|
/*
|
|
|
|
* Copyright (C) 2011 The Android Open Source Project
|
|
|
|
*
|
2013-01-21 12:52:57 +00:00
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
|
|
* you may not use this file except in compliance with the License.
|
|
|
|
* You may obtain a copy of the License at
|
2011-06-29 09:01:06 +00:00
|
|
|
*
|
2013-01-21 12:52:57 +00:00
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
2011-06-29 09:01:06 +00:00
|
|
|
*
|
|
|
|
* Unless required by applicable law or agreed to in writing, software
|
2013-01-21 12:52:57 +00:00
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
|
|
* See the License for the specific language governing permissions and
|
|
|
|
* limitations under the License.
|
2011-06-29 09:01:06 +00:00
|
|
|
*/
|
|
|
|
|
2012-03-19 08:23:26 +00:00
|
|
|
package com.android.inputmethod.latin.makedict;
|
2011-06-29 09:01:06 +00:00
|
|
|
|
2012-05-05 14:40:21 +00:00
|
|
|
import android.util.Log;
|
|
|
|
|
2011-06-29 09:01:06 +00:00
|
|
|
/**
|
|
|
|
* Wrapper to redirect log events to the right output medium.
|
|
|
|
*/
|
2012-09-27 09:16:16 +00:00
|
|
|
public final class MakedictLog {
|
2012-05-11 13:48:16 +00:00
|
|
|
public static final boolean DBG = false;
|
2012-05-05 14:40:21 +00:00
|
|
|
private static final String TAG = MakedictLog.class.getSimpleName();
|
2011-06-29 09:01:06 +00:00
|
|
|
|
2012-05-05 14:40:21 +00:00
|
|
|
public static void d(String message) {
|
|
|
|
if (DBG) {
|
|
|
|
Log.d(TAG, message);
|
2012-05-05 00:28:27 +00:00
|
|
|
}
|
2011-06-29 09:01:06 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
public static void i(String message) {
|
2012-05-05 14:40:21 +00:00
|
|
|
if (DBG) {
|
|
|
|
Log.i(TAG, message);
|
|
|
|
}
|
2011-06-29 09:01:06 +00:00
|
|
|
}
|
2012-05-05 14:40:21 +00:00
|
|
|
|
2011-06-29 09:01:06 +00:00
|
|
|
public static void w(String message) {
|
2012-05-05 14:40:21 +00:00
|
|
|
Log.w(TAG, message);
|
|
|
|
}
|
|
|
|
|
|
|
|
public static void e(String message) {
|
|
|
|
Log.e(TAG, message);
|
2011-06-29 09:01:06 +00:00
|
|
|
}
|
|
|
|
}
|