style tweaks.

fix-message-formatting
Danny van Heumen 11 years ago
parent 1e1ea2291a
commit 893e84b65d

@ -19,11 +19,12 @@
import org.osgi.framework.*;
/**
* Loads the IRC provider factory and registers its services in the OSGI
* bundle context.
* Loads the IRC provider factory and registers its services in the OSGI bundle
* context.
*
* @author Stephane Remy
* @author Loic Kempf
* @author Danny van Heumen
*/
public class IrcActivator
implements BundleActivator
@ -31,8 +32,7 @@ public class IrcActivator
/**
* LOGGER instance.
*/
private static final Logger logger
= Logger.getLogger(IrcActivator.class);
private static final Logger LOGGER = Logger.getLogger(IrcActivator.class);
/**
* A reference to the IRC protocol provider factory.
@ -76,7 +76,8 @@ public class IrcActivator
* listeners, unregister all services registered by this bundle, and
* release all services used by this bundle.
*/
public void start(BundleContext context)
@Override
public void start(final BundleContext context)
throws Exception
{
bundleContext = context;
@ -92,8 +93,10 @@ public void start(BundleContext context)
ircProviderFactory,
hashtable);
if (logger.isInfoEnabled())
logger.info("IRC protocol implementation [STARTED].");
if (LOGGER.isInfoEnabled())
{
LOGGER.info("IRC protocol implementation [STARTED].");
}
}
/**
@ -117,11 +120,14 @@ public static ProtocolProviderFactoryIrcImpl getProtocolProviderFactory()
* listeners, unregister all services registered by the bundle, and
* release all services used by the bundle.
*/
public void stop(BundleContext context)
@Override
public void stop(final BundleContext context)
throws Exception
{
if (logger.isInfoEnabled())
logger.info("IRC protocol implementation [STOPPED].");
if (LOGGER.isInfoEnabled())
{
LOGGER.info("IRC protocol implementation [STOPPED].");
}
}
/**
@ -132,13 +138,15 @@ public void stop(BundleContext context)
public static ResourceManagementService getResources()
{
if (resourceService == null)
{
resourceService
= ResourceManagementServiceUtils.getService(bundleContext);
}
return resourceService;
}
/**
* Bundle Context
* Bundle Context.
*
* @return returns bundle context
*/
@ -165,7 +173,7 @@ public static MUCService getMUCService()
/**
* Return the UI service impl.
*
* @return
* @return returns UI Service instance
*/
public static UIService getUIService()
{
@ -185,14 +193,16 @@ public static CertificateService getCertificateService()
{
if (certiticateService == null)
{
ServiceReference guiVerifyReference
ServiceReference<?> guiVerifyReference
= IrcActivator.getBundleContext().getServiceReference(
CertificateService.class.getName());
if (guiVerifyReference != null)
{
certiticateService = (CertificateService)
IrcActivator.getBundleContext().getService(
guiVerifyReference);
}
}
return certiticateService;
}
}

Loading…
Cancel
Save