本文整理了Java中org.gatein.common.logging.Logger.isDebugEnabled()
方法的一些代码示例,展示了Logger.isDebugEnabled()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Logger.isDebugEnabled()
方法的具体详情如下:
包路径:org.gatein.common.logging.Logger
类名称:Logger
方法名:isDebugEnabled
暂无
代码示例来源:origin: org.gatein.management/gatein-management-core
final boolean debug = log.isDebugEnabled();
if (debug) log.debug("Registering operation " + operationName + " for path " + resource.getPath());
代码示例来源:origin: org.exoplatform.portal/exo.portal.component.web.server
private boolean isLimited(UploadResource upResource, double contentLength)
{
// by default, use the limit set in the service
UploadLimit limit = defaultUploadLimitMB_;
// if the limit is set in the request (specific for this upload) then use
// this value instead of the default one
if (uploadLimits.containsKey(upResource.getUploadId()))
{
limit = uploadLimits.get(upResource.getUploadId());
}
double estimatedSize = contentLength / limit.division;
if (limit.getLimit() > 0 && estimatedSize > limit.getLimit())
{ // a limit set to 0 means unlimited
if (log.isDebugEnabled())
{
log.debug("Upload cancelled because file bigger than size limit : " + estimatedSize + " " + limit.unit + " > " + limit.getLimit()
+ " " + limit.unit);
}
return true;
}
return false;
}
代码示例来源:origin: org.gatein.management/gatein-management-core
@Override
public ComponentRegistration registerManagedComponent(Class<?> component)
{
boolean debug = log.isDebugEnabled();
if (debug) log.debug("Processing managed annotations for class " + component);
Managed managed = component.getAnnotation(Managed.class);
if (managed == null) throw new RuntimeException(Managed.class + " annotation not present on " + component);
String componentName = managed.value();
if ("".equals(componentName)) throw new RuntimeException(Managed.class + " annotation must have a value (path) for component class " + component);
if (debug) log.debug("Registering managed component " + componentName);
ComponentRegistration registration = registerManagedComponent(componentName);
registration.registerManagedResource(description(managed.description()));
// Register resources & operations
AnnotatedResource annotatedResource = new AnnotatedResource(component);
annotatedResource.register(rootResource);
return registration;
}
private ManagedDescription description(final String description)
代码示例来源:origin: org.gatein.management/gatein-management-core
static AbstractManagedResource registerOrGetResource(AbstractManagedResource resource, Managed managed)
{
PathAddress address = PathAddress.pathAddress(managed.value());
for (Iterator<String> iterator = address.iterator(); iterator.hasNext();)
{
String path = iterator.next();
String description = "";
if (iterator.hasNext())
{
description = managed.description();
}
AbstractManagedResource child = (AbstractManagedResource) resource.getSubResource(path);
if (child == null)
{
if (log.isDebugEnabled()) log.debug("Registering managed resource " + path);
child = (AbstractManagedResource) resource.registerSubResource(path, description(description));
}
resource = child;
}
return resource;
}
代码示例来源:origin: org.gatein.management/gatein-management-core
@Override
public void execute(OperationContext operationContext, ResultHandler resultHandler) throws ResourceNotFoundException, OperationException
if (log.isDebugEnabled())
代码示例来源:origin: org.gatein.management/gatein-management-core
private static Object[] getParameters(OperationContext operationContext, Method method, String methodName, Class<?> managedClass)
boolean debug = log.isDebugEnabled();
String operationName = operationContext.getOperationName();
Annotation[][] parameterAnnotations = method.getParameterAnnotations();
代码示例来源:origin: org.gatein.management/gatein-management-rest
if (log.isDebugEnabled()) // Don't want to log exceptions for wrong url's all the time.
if (log.isDebugEnabled()) {
log.error("Bad request for address " + address + " and operation " + operationName, e);
代码示例来源:origin: org.gatein.management/gatein-management-core
String operationName = request.getOperationName();
boolean debug = log.isDebugEnabled();
if (debug)
内容来源于网络,如有侵权,请联系作者删除!