Package org.fusesource.ide.camel.editor.propertysheet

Source Code of org.fusesource.ide.camel.editor.propertysheet.RiderTypeMapper

/*******************************************************************************
* Copyright (c) 2013 Red Hat, Inc.
* Distributed under license by Red Hat, Inc. All rights reserved.
* This program is 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:
*     Red Hat, Inc. - initial API and implementation
******************************************************************************/

package org.fusesource.ide.camel.editor.propertysheet;

import org.eclipse.ui.views.properties.tabbed.ITypeMapper;
import org.fusesource.ide.camel.editor.AbstractNodes;
import org.fusesource.ide.camel.model.AbstractNode;


public class RiderTypeMapper implements ITypeMapper {

  /*
   * (non-Javadoc)
   * @see org.eclipse.ui.views.properties.tabbed.ITypeMapper#mapType(java.lang.Object)
   */
  @Override
  public Class mapType(Object object) {
    AbstractNode node = AbstractNodes.toAbstractNode(object);
    if (node != null) {
      return AbstractNode.class;
    }
    return object.getClass();
  }
}
TOP

Related Classes of org.fusesource.ide.camel.editor.propertysheet.RiderTypeMapper

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.