You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@sirona.apache.org by ol...@apache.org on 2014/02/21 05:27:10 UTC
svn commit: r1570444 - in
/incubator/sirona/trunk/agent/javaagent/src/main/java/org/apache/sirona/javaagent/logging:
./ SironaAgentLogging.java
Author: olamy
Date: Fri Feb 21 04:27:10 2014
New Revision: 1570444
URL: http://svn.apache.org/r1570444
Log:
missed to add a class
Added:
incubator/sirona/trunk/agent/javaagent/src/main/java/org/apache/sirona/javaagent/logging/
incubator/sirona/trunk/agent/javaagent/src/main/java/org/apache/sirona/javaagent/logging/SironaAgentLogging.java (with props)
Added: incubator/sirona/trunk/agent/javaagent/src/main/java/org/apache/sirona/javaagent/logging/SironaAgentLogging.java
URL: http://svn.apache.org/viewvc/incubator/sirona/trunk/agent/javaagent/src/main/java/org/apache/sirona/javaagent/logging/SironaAgentLogging.java?rev=1570444&view=auto
==============================================================================
--- incubator/sirona/trunk/agent/javaagent/src/main/java/org/apache/sirona/javaagent/logging/SironaAgentLogging.java (added)
+++ incubator/sirona/trunk/agent/javaagent/src/main/java/org/apache/sirona/javaagent/logging/SironaAgentLogging.java Fri Feb 21 04:27:10 2014
@@ -0,0 +1,46 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You 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
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * 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.
+ */
+
+package org.apache.sirona.javaagent.logging;
+
+import java.text.MessageFormat;
+
+/**
+ * Nothing really complicated in this logger.
+ * It's just a way to have an unique place where it's done.
+ */
+public class SironaAgentLogging
+{
+ public static boolean AGENT_DEBUG = Boolean.getBoolean( "sirona.agent.debug" );
+
+ /**
+ *
+ * @param message very simple usage so we {@link java.text.MessageFormat}
+ * @param objects
+ */
+ public static void debug(String message, Object... objects){
+ if (AGENT_DEBUG){
+ if (objects != null)
+ {
+ System.out.println( MessageFormat.format( message, objects ));
+ } else {
+ System.out.println(message);
+ }
+ }
+ }
+
+}
Propchange: incubator/sirona/trunk/agent/javaagent/src/main/java/org/apache/sirona/javaagent/logging/SironaAgentLogging.java
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: incubator/sirona/trunk/agent/javaagent/src/main/java/org/apache/sirona/javaagent/logging/SironaAgentLogging.java
------------------------------------------------------------------------------
svn:keywords = Author Date Id Revision