Overview  Package   Class  Tree  Serialized  Deprecated  Index  Help 

org.apache.jetspeed.portlet
Interface PortletLog


public interface PortletLog

The PortletLog provides the portlet with the ability to log information, warning, or error texts. The log is maintained by the portlet container. The type and location of of the log is a matter of implementation. Also, whether logging is enabled or not is at the discretion of the portlet container.

 ...

 PortletLog log = iContext.getLog ();

 if (log.isWarnEnabled())
     log.warn ("Can access the content source");

 ...
 

Since:
4.1

Method Summary
 void debug(java.lang.String text)
          Logs the given informational text in the portlet log.
 void error(java.lang.String text)
          Logs the given error text in the portlet log.
 void error(java.lang.String text, java.lang.Throwable cause)
          Logs the given error text, cause, and a stack trace in the portlet log.
 void info(java.lang.String text)
          Logs the given informational text in the portlet log.
 boolean isDebugEnabled()
          Returns whether the debug level of the portlet log is enabled.
 boolean isErrorEnabled()
          Returns whether the error level of the portlet log is enabled.
 boolean isInfoEnabled()
          Returns whether the info level of the portlet log is enabled.
 boolean isWarnEnabled()
          Returns whether the warn level of the portlet log is enabled.
 void warn(java.lang.String text)
          Logs the given warning text in the portlet log.
 

Method Detail

isDebugEnabled

public boolean isDebugEnabled()
Returns whether the debug level of the portlet log is enabled.

Returns:
true if the log is enabled,
false

debug

public void debug(java.lang.String text)
Logs the given informational text in the portlet log.

Parameters:
text - the informational text to log

isInfoEnabled

public boolean isInfoEnabled()
Returns whether the info level of the portlet log is enabled.

Returns:
true if the log is enabled,
false

info

public void info(java.lang.String text)
Logs the given informational text in the portlet log.

Parameters:
text - the informational text to log

isWarnEnabled

public boolean isWarnEnabled()
Returns whether the warn level of the portlet log is enabled.

Returns:
true if the log is enabled,
false

warn

public void warn(java.lang.String text)
Logs the given warning text in the portlet log.

Parameters:
text - the warning text to log

isErrorEnabled

public boolean isErrorEnabled()
Returns whether the error level of the portlet log is enabled.

Returns:
true if the log is enabled,
false

error

public void error(java.lang.String text)
Logs the given error text in the portlet log.

Parameters:
text - the error text to log
See Also:
error(String,Throwable)

error

public void error(java.lang.String text,
                  java.lang.Throwable cause)
Logs the given error text, cause, and a stack trace in the portlet log.

Parameters:
text - the error text to log
cause - the cause for logging
See Also:
error(String)

Overview  Package   Class  Tree  Serialized  Deprecated  Index  Help 

 

WebSphere is a trademark of the IBM Corporation in the United States, other countries, or both.

 

IBM is a trademark of the IBM Corporation in the United States, other countries, or both.