trace/traceviewer/com.nokia.traceviewer.eventhandler/src/com/nokia/traceviewer/eventhandler/Activator.java
changeset 11 5b9d4d8641ce
equal deleted inserted replaced
10:ed1c9f64298a 11:5b9d4d8641ce
       
     1 /*
       
     2  * Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies). 
       
     3  * All rights reserved.
       
     4  * This component and the accompanying materials are made available
       
     5  * under the terms of "Eclipse Public License v1.0"
       
     6  * which accompanies this distribution, and is available
       
     7  * at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     8  *
       
     9  * Initial Contributors:
       
    10  * Nokia Corporation - initial contribution.
       
    11  *
       
    12  * Contributors:
       
    13  *
       
    14  * Description:
       
    15  *
       
    16  * The activator class controls the plug-in life cycle
       
    17  *
       
    18  */
       
    19 package com.nokia.traceviewer.eventhandler;
       
    20 
       
    21 import org.eclipse.core.runtime.Plugin;
       
    22 import org.osgi.framework.BundleContext;
       
    23 
       
    24 /**
       
    25  * The activator class controls the plug-in life cycle
       
    26  */
       
    27 public class Activator extends Plugin {
       
    28 
       
    29 	/**
       
    30 	 * The plug-in ID
       
    31 	 */
       
    32 	public static final String PLUGIN_ID = "com.nokia.traceviewer.eventhandler"; //$NON-NLS-1$
       
    33 
       
    34 	/**
       
    35 	 * The shared instance
       
    36 	 */
       
    37 	private static Activator plugin;
       
    38 
       
    39 	/**
       
    40 	 * The constructor
       
    41 	 */
       
    42 	public Activator() {
       
    43 		plugin = this;
       
    44 	}
       
    45 
       
    46 	/*
       
    47 	 * (non-Javadoc)
       
    48 	 * 
       
    49 	 * @see
       
    50 	 * org.eclipse.ui.plugin.AbstractUIPlugin#start(org.osgi.framework.BundleContext
       
    51 	 * )
       
    52 	 */
       
    53 	@Override
       
    54 	public void start(BundleContext context) throws Exception {
       
    55 		super.start(context);
       
    56 	}
       
    57 
       
    58 	/*
       
    59 	 * (non-Javadoc)
       
    60 	 * 
       
    61 	 * @see
       
    62 	 * org.eclipse.ui.plugin.AbstractUIPlugin#stop(org.osgi.framework.BundleContext
       
    63 	 * )
       
    64 	 */
       
    65 	@Override
       
    66 	public void stop(BundleContext context) throws Exception {
       
    67 		plugin = null;
       
    68 		super.stop(context);
       
    69 	}
       
    70 
       
    71 	/**
       
    72 	 * Returns the shared instance
       
    73 	 * 
       
    74 	 * @return the shared instance
       
    75 	 */
       
    76 	public static Activator getDefault() {
       
    77 		return plugin;
       
    78 	}
       
    79 
       
    80 }