Tabnine Logo
Log.info
Code IndexAdd Tabnine to your IDE (free)

How to use
info
method
in
uk.org.retep.logging.Log

Best Java code snippets using uk.org.retep.logging.Log.info (Showing top 20 results out of 315)

origin: uk.org.retep.tools/io

private void notice( final String msg, final Object... args )
{
  if( log != null )
  {
    log.info( msg, args );
  }
}
origin: uk.org.retep.tools/io

protected final void info( final String msg, final Object... args )
{
  if( log != null )
  {
    log.info( message, args );
  }
}
origin: uk.org.retep.tools/io

protected final void info( final String msg, final Object... args )
{
  if( log != null )
  {
    log.info( msg, args );
  }
}
origin: uk.org.retep.tools/io

/**
 * Identical to File.mkdir() but will log if the logger is not null
 * @param dir Directory to make
 * @param log Log to use if not null
 * @return dir
 */
public static File mkdirs( final File dir, final Log log )
{
  if( dir != null && dir.mkdirs() && log != null )
  {
    log.info( "Created %s", dir.getPath() );
  }
  return dir;
}
origin: uk.org.retep.tools/io

/**
 * Identical to File.mkdir() but will log if the logger is not null
 * @param dir Directory to make
 * @param log Log to use if not null
 * @return dir
 */
public static File mkdir( final File dir, final Log log )
{
  if( dir.mkdir() && log != null )
  {
    log.info( "Created %s", dir.getPath() );
  }
  return dir;
}
origin: uk.org.retep.tools/httpd

public StaticFileHandler( final File rootDirectory )
{
  this.rootDirectory = rootDirectory;
  getLog().info( "Created StaticHandler for %s",
          rootDirectory.getAbsolutePath() );
}
origin: uk.org.retep.tools/io

  /**
   * Delete a File. This is the same as {@link File#delete()} except that
   * this method will delete all content if it's a directory
   *
   * @param file File to delete
   * @param log Log to log progress to, null for no logging
   * @return true only if the file was really deleted
   */
  public static boolean delete( @Nonnull final File file,
                 @Nullable final Log log )
  {
    if( file.exists() && file.isDirectory() )
    {
      for( File child : file.listFiles() )
      {
        delete( child, log );
      }
    }

    if( log != null )
    {
      log.info( "Deleting %s", file.getAbsolutePath() );
    }
    return file.delete();
  }
}
origin: uk.org.retep.microkernel.web/jersey

  /**
   * {@inheritDoc }
   */
  @Override
  @SuppressWarnings( "unchecked" )
  public Object postProcessAfterInitialization( final Object o,
                         final String string )
      throws BeansException
  {
    final Class clazz = o.getClass();

    if( ResourceConfig.isProviderClass( clazz ) )
    {
      log.info( "Registering bean %s of type %s as a provider class",
           string,
           clazz.getName() );
      classes.add( clazz );
    }
    else if( ResourceConfig.isRootResourceClass( clazz ) )
    {
      log.info( "Registering bean %s of type %s as a root resource class",
           string,
           clazz.getName() );
      classes.add( clazz );
    }

    return o;
  }
}
origin: uk.org.retep.tools/nio

public final void bind( SocketAddress endPoint )
    throws IOException
{
  // If no endPoint is provided, then get a non-local IPV4 address
  if( endPoint == null )
  {
    endPoint = new InetSocketAddress( getLocalInetAddress(), 0 );
  }
  // Create the channel and bind the associated socket to the endPoint
  serverChannel = ServerSocketChannel.open();
  serverChannel.configureBlocking( false );
  serverSocket = serverChannel.socket();
  serverSocket.bind( endPoint );
  // Show the banner in the logs, will contain the IP, port and interface
  networkInterface = NetworkInterface.getByInetAddress(
      serverSocket.getInetAddress() );
  getLog().info(
      "\n" +
      "----------------------------------------------------------------------\n" +
      "%s: %s|%d on %s\n" +
      "----------------------------------------------------------------------",
      getClass().getSimpleName(),
      serverSocket.getInetAddress().getHostAddress(),
      serverSocket.getLocalPort(),
      networkInterface == null ? "Unknown" : networkInterface.getName() );
  getLog().info( "Now receiving accept" );
}
origin: uk.org.retep.tools/nio

@Override
public void read( final SocketChannel channel, final ByteBuffer buffer )
    throws IOException
{
  try
  {
    getLog().info( "A %d %d", buffer.position(), buffer.limit() );
    getXMLStreamReader( buffer );
    getLog().info( "B %d %d", buffer.position(), buffer.limit() );
    do
    {
      while( xmlStreamReader.hasNext() )
      {
        getLog().info( "C %d %d", buffer.position(), buffer.limit() );
        parser.processEvents( xmlStreamReader );
      }
    getLog().info( "D %d %d", buffer.position(), buffer.limit() );
    } while( inputStream.available() > 0 );
    getLog().info( "E %d %d", buffer.position(), buffer.limit() );
  }
  catch( XMLStreamException ex )
  {
    parser.notifyStreamError( ex );
    throw new IOException( ex );
  }
}
origin: uk.org.retep.xmpp.server/multiUserChat

@Override
public <T> XMPPLogic process( @Nonnull final XMPPServer<T> server,
               @Nonnull final MucService service,
               @Nullable final MucRoom room,
               @Nonnull final Presence<?, ?> presence )
    throws MessageException
{
  // This is the departing users room jid
  final JID jidInRoom = presence.getTo();
  getLog().info( "%s left %s", presence.getFrom(), jidInRoom );
  // Remove the user from the room
  final MucRoomMember leavingMember = room.remove( jidInRoom );
  // now send the relevant messages
  return roomLeaveBroadcast( server, service, room, presence, jidInRoom, leavingMember );
}
origin: uk.org.retep.tools/httpd

getLog().info( "Removing HttpContext %s on HttpServer %s", path,
        httpServer.getAddress() );
origin: uk.org.retep.tools/nio

@Override
public void closing( final SocketChannel channel )
{
  if( parser != null )
  {
    parser.notifyStreamClosed();
    parser.removeListener( this );
    parser = null;
  }
  if( xmlStreamReader != null )
  {
    try
    {
      xmlStreamReader.close();
    }
    catch( XMLStreamException ex )
    {
      getLog().info( "Exception closing XMLStreamParser", ex );
    }
    xmlStreamReader = null;
  }
  super.closing( channel );
}
origin: uk.org.retep.xmpp.server/multiUserChat

  @Override
  public void logMessage( final MucRoom room, final Message message )
  {
    if( log.isInfoEnabled() )
    {
      // FIXME figure out why this is needed
      @SuppressWarnings( "unchecked" )
      final List<Body> body = message.getBody();
      if( body.isEmpty() )
      {
        log.info( "%s %s NO_BODY", message.getFrom(),
             room.getJid() );
      }
      else
      {
        for( Body b : body )
        {
          log.info( "%s %s %s",
               message.getFrom(),
               room.getJid(),
               b.getValue() );
        }
      }
    }
  }
};
origin: uk.org.retep.xmpp/core

  @Override
  protected void consumePresence( Presence presence )
      throws MessageException
  {
    getLog().info( "Presence %s from %s to %s type %s",
            presence.getId(),
            presence.getFrom(),
            presence.getTo(),
            presence.getType() );
  }
}
origin: uk.org.retep.xmpp/core

@Override
protected void consumeIq( Iq iq )
    throws MessageException
{
  getLog().info( "Iq %s from %s to %s type %s",
          iq.getId(),
          iq.getFrom(),
          iq.getTo(),
          iq.getType() );
}
origin: uk.org.retep.xmpp/core

@Override
protected void consumeMessage( Message message )
    throws MessageException
{
  getLog().info( "Message %s from %s to %s type %s",
          message.getId(),
          message.getFrom(),
          message.getTo(),
          message.getType() );
}
origin: uk.org.retep.templateEngine/templateEngine

@WriteLock
private void registerMacro( final MacroVisitor macro,
              final boolean throwException )
    throws MacroAlreadyRegisteredException
{
  final Macro annotation = getAnnotation( macro );
  if( macros.containsKey( annotation.name() ) )
  {
    if( throwException )
    {
      throw new MacroAlreadyRegisteredException( annotation );
    }
  }
  else
  {
    macros.put( annotation.name(), macro );
    getLog().info( "Registered macro %s [%s]", annotation.name(), macro );
  }
}
origin: uk.org.retep.xmpp.server/multiUserChat

  /**
   * {@inheritDoc}
   */
  @Override
  public void logMessage( final MucRoom room, final Message message )
  {
    if( getLog().isInfoEnabled() )
    {
      // FIXME another unchecked cast to investigate
      @SuppressWarnings( "unchecked" )
      final List<Body> body = message.getBody();
      if( body.isEmpty() )
      {
        getLog().info( "%s %s NO_BODY", message.getFrom(),
                room.getJid() );
      }
      else
      {
        for( Body b : body )
        {
          getLog().info( "%s %s %s",
                  message.getFrom(),
                  room.getJid(),
                  b.getValue() );
        }
      }

    }
  }
}
origin: uk.org.retep.tools/httpd

getLog().info( "%s: %s %s", exchange.getHttpContext().getPath(),
        method, exchange.getRequestURI() );
uk.org.retep.loggingLoginfo

Popular methods of Log

  • debug
  • error
  • fatal
  • isDebugEnabled
  • isInfoEnabled
  • warn

Popular in Java

  • Parsing JSON documents to java classes using gson
  • getSharedPreferences (Context)
  • addToBackStack (FragmentTransaction)
  • getApplicationContext (Context)
  • VirtualMachine (com.sun.tools.attach)
    A Java virtual machine. A VirtualMachine represents a Java virtual machine to which this Java vir
  • URL (java.net)
    A Uniform Resource Locator that identifies the location of an Internet resource as specified by RFC
  • DateFormat (java.text)
    Formats or parses dates and times.This class provides factories for obtaining instances configured f
  • SortedMap (java.util)
    A map that has its keys ordered. The sorting is according to either the natural ordering of its keys
  • UUID (java.util)
    UUID is an immutable representation of a 128-bit universally unique identifier (UUID). There are mul
  • SAXParseException (org.xml.sax)
    Encapsulate an XML parse error or warning.> This module, both source code and documentation, is in t
  • CodeWhisperer alternatives
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now