| OLD | NEW |
| (Empty) | |
| 1 /* |
| 2 * Copyright 2011 Google Inc. |
| 3 * |
| 4 * Licensed under the Apache License, Version 2.0 (the "License"); |
| 5 * you may not use this file except in compliance with the License. |
| 6 * You may obtain a copy of the License at |
| 7 * |
| 8 * http://www.apache.org/licenses/LICENSE-2.0 |
| 9 * |
| 10 * Unless required by applicable law or agreed to in writing, software |
| 11 * distributed under the License is distributed on an "AS IS" BASIS, |
| 12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 13 * See the License for the specific language governing permissions and |
| 14 * limitations under the License. |
| 15 */ |
| 16 |
| 17 package com.google.ipc.invalidation.util; |
| 18 |
| 19 import java.util.logging.Level; |
| 20 |
| 21 /** |
| 22 * A basic formatting logger interface. |
| 23 * |
| 24 */ |
| 25 public interface BaseLogger { |
| 26 /** |
| 27 * Logs a message. |
| 28 * |
| 29 * @param level the level at which the message should be logged (e.g., {@code
INFO}) |
| 30 * @param template the string to log, optionally containing %s sequences |
| 31 * @param args variables to substitute for %s sequences in {@code template} |
| 32 */ |
| 33 void log(Level level, String template, Object... args); |
| 34 |
| 35 /** |
| 36 * Returns true iff statements at {@code level} are not being suppressed. |
| 37 */ |
| 38 boolean isLoggable(Level level); |
| 39 |
| 40 /** |
| 41 * Logs a message at the SEVERE level. |
| 42 * See specs of {@code #log} for the parameters. |
| 43 */ |
| 44 void severe(String template, Object...args); |
| 45 |
| 46 /** |
| 47 * Logs a message at the WARNING level. |
| 48 * See specs of {@code #log} for the parameters. |
| 49 */ |
| 50 void warning(String template, Object...args); |
| 51 |
| 52 /** |
| 53 * Logs a message at the INFO level. |
| 54 * See specs of {@code #log} for the parameters. |
| 55 */ |
| 56 void info(String template, Object...args); |
| 57 |
| 58 /** |
| 59 * Logs a message at the FINE level. |
| 60 * See specs of {@code #log} for the parameters. |
| 61 */ |
| 62 void fine(String template, Object...args); |
| 63 } |
| OLD | NEW |