lttng: Fix Javadoc and formatting in lttng2.ui
[deliverable/tracecompass.git] / org.eclipse.linuxtools.lttng2.ui / src / org / eclipse / linuxtools / internal / lttng2 / ui / views / control / handlers / AddContextOnChannelHandler.java
index f96e66bef845eecb88b32132522e0697bcc05610..9036b616a1024cb86b7ed67c15a4e3e349e3d1b1 100644 (file)
@@ -1,12 +1,12 @@
 /**********************************************************************
  * Copyright (c) 2012 Ericsson
- * 
+ *
  * All rights reserved. This program and the accompanying materials are
  * made available under the terms of the Eclipse Public License v1.0 which
  * accompanies this distribution, and is available at
  * http://www.eclipse.org/legal/epl-v10.html
- * 
- * Contributors: 
+ *
+ * Contributors:
  *   Bernd Hufmann - Initial API and implementation
  **********************************************************************/
 package org.eclipse.linuxtools.internal.lttng2.ui.views.control.handlers;
@@ -25,17 +25,18 @@ import org.eclipse.linuxtools.internal.lttng2.ui.views.control.model.impl.TraceS
 import org.eclipse.ui.IWorkbenchPage;
 
 /**
- * <b><u>AddContextOnChannelHandler</u></b>
  * <p>
  * Command handler implementation to add contexts to a given channel and all of its events.
  * </p>
+ *
+ * @author Bernd Hufmann
  */
 public class AddContextOnChannelHandler extends BaseAddContextHandler {
 
     // ------------------------------------------------------------------------
     // Attributes
     // ------------------------------------------------------------------------
-    
+
     // ------------------------------------------------------------------------
     // Operations
     // ------------------------------------------------------------------------
@@ -69,10 +70,10 @@ public class AddContextOnChannelHandler extends BaseAddContextHandler {
         if (selection instanceof StructuredSelection) {
             StructuredSelection structered = ((StructuredSelection) selection);
             for (Iterator<?> iterator = structered.iterator(); iterator.hasNext();) {
-                Object element = (Object) iterator.next();
+                Object element = iterator.next();
                 if (element instanceof TraceChannelComponent) {
                     // Add only if corresponding TraceSessionComponents is inactive and not destroyed
-                    TraceChannelComponent tmpChannel = (TraceChannelComponent) element; 
+                    TraceChannelComponent tmpChannel = (TraceChannelComponent) element;
                     session = tmpChannel.getSession();
                     if(session.getSessionState() == TraceSessionState.INACTIVE && !session.isDestroyed()) {
                         channel = tmpChannel;
@@ -80,7 +81,7 @@ public class AddContextOnChannelHandler extends BaseAddContextHandler {
                 }
             }
         }
-        
+
         boolean isEnabled = (channel != null);
         fLock.lock();
         try {
This page took 0.02446 seconds and 5 git commands to generate.