Commit ffd5a390 authored by Jay Jay Billings's avatar Jay Jay Billings
Browse files

Removed JME3 bundles.


Signed-off-by: default avatarJay Jay Billings <billingsjj@ornl.gov>
parent e93af095
<?xml version="1.0" encoding="UTF-8"?>
<project
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"
xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>ICE</groupId>
<artifactId>org.eclipse.ice.build</artifactId>
<version>2.1.8</version>
<relativePath>../${pom-filename}</relativePath>
</parent>
<groupId>ICE</groupId>
<artifactId>org.eclipse.ice.client.widgets.rcp</artifactId>
<packaging>eclipse-plugin</packaging>
</project>
\ No newline at end of file
/// ********************************************************************************Copyright(c)2014
/// UT-Battelle,LLC.*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:*Jordan Deyton(UT-Battelle,LLC.)-initial API and
/// implementation and/or*initial
/// documentation********************************************************************************/package
/// org.eclipse.ice.client.widgets.jme;
//
// import java.util.concurrent.Callable;import
/// java.util.concurrent.Future;import
/// java.util.concurrent.atomic.AtomicBoolean;
//
// import org.eclipse.ice.datastructures.ICEObject.ICEObject;import
/// org.eclipse.ice.datastructures.ICEObject.IUpdateable;import
/// org.eclipse.ice.datastructures.ICEObject.IUpdateableListener;import
/// org.eclipse.ice.viz.service.jme3.application.IRenderQueue;import
/// org.eclipse.ice.viz.service.jme3.widgets.AbstractView;
//
// import com.jme3.scene.Node;
//
/// ***This
//
// class provides
// a base implementation for
// a controller
// that manages an*
//
// {@link IUpdateable}
//
// model and an
//
// {@link AbstractView}
//
// associated with that*
// model. It ensures
// that changes
// to the
// model or
// features provided
// by the*
// controller itself are
// synchronized with the
// view through
// the parent*SimpleApplication's
//
// simpleUpdate() thread.
// *
// * @author Jordan Deyton
// *
// */
// public abstract class AbstractController implements IUpdateableListener {
// /*
// * Note: We previously had an IControllerListener interface whereby objects
// * could listen for changes to an AbstractController. If this interface is
// * required for future work, this package (widgets.jme) and the plant
// * package (widgets.reactoreditor.plant) should be selectively reverted to
// * restore IControllerListener, AbstractController, and PipeController to
// * their state before 20140903-1600. Also note that this change was
// * committed to the branch.
// */
//
// /**
// * The model for which this controller provides a view.
// */
// protected final IUpdateable model;
// /**
// * The {@link AbstractView} associated with this controller.
// */
// private final AbstractView view;
//
// /**
// * The queue responsible for tasks that need to be performed on the jME
// * rendering thread.
// */
// protected final IRenderQueue renderQueue;
// /**
// * Whether or not the controller and its view have been disposed.
// */
// protected final AtomicBoolean disposed;
//
// // ---- Base Features ---- //
// /**
// * The current parent node for the {@link #view}.
// */
// private Node parentNode;
//
// // ----------------------- //
//
// /**
// * The default constructor. If any arguments are invalid (null), an
// * {@link IllegalArgumentException} is thrown.
// *
// * @param model
// * The model for which this controller provides a view.
// * @param view
// * The view associated with this controller. This needs to be
// * instantiated by the sub-class.
// * @param renderQueue
// * The queue responsible for tasks that need to be performed on
// * the jME rendering thread.
// */
// public AbstractController(IUpdateable model, AbstractView view,
// IRenderQueue renderQueue) {
//
// // Set the model and register with it. It should not be null.
// this.model = (model != null ? model : new ICEObject());
// this.model.register(this);
//
// // Set the view. If it is null, create a new, basic view.
// this.view = (view != null ? view : new AbstractView("Invalid View") {
// });
//
// // Set the update queue. If it is null, create a new queue.
// this.renderQueue = (renderQueue != null ? renderQueue
// : new IRenderQueue() {
// @Override
// public <T> Future<T> enqueue(Callable<T> callable) {
// return null;
// }
// });
//
// // Initialize the disposed boolean.
// disposed = new AtomicBoolean(false);
//
// // ---- Initialize any base features. ---- //
// parentNode = null;
// // --------------------------------------- //
//
// return;
// }
//
// /**
// * @return The model for which this controller provides a view.
// */
// public IUpdateable getModel() {
// return model;
// }
//
// /**
// * Sets the Node to which the associated {@link AbstractView} is attached.
// *
// * @param node
// * The new parent node for the associated {@link AbstractView}.
// */
// public void setParentNode(Node node) {
//
// // If the parent node is not null and is different, we can attach the
// // view to the new parent.
// if (node != null && node != parentNode) {
// this.parentNode = node;
//
// // If the controller is not disposed, we should try to attach the
// // view to the new parent.
// if (!disposed.get()) {
// renderQueue.enqueue(new Callable<Boolean>() {
// @Override
// public Boolean call() {
// view.setParentNode(parentNode);
// return true;
// }
// });
// }
// }
//
// return;
// }
//
// /**
// * Disposes of the AbstractController and its associated
// * {@link AbstractView}.
// */
// public void dispose() {
//
// // If we have not already disposed of the controller, we need to
// // unregister from the IUpdateable model and, if possible, dispose of
// // the AbstractView managed by this controller.
// if (disposed.compareAndSet(false, true)) {
// // Unregister from the model.
// model.unregister(this);
//
// // Add a new update action to remove the view.
// renderQueue.enqueue(new Callable<Boolean>() {
// @Override
// public Boolean call() {
// view.dispose();
// return true;
// }
// });
// }
//
// return;
// }
//
// /**
// * Updates the controller and/or view if the {@link #model} has changed.
// */
// @Override
// public abstract void update(IUpdateable component);
//
// }
/// *******************************************************************************
// * Copyright (c) 2014 UT-Battelle, LLC.
// * 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:
// * Jordan Deyton (UT-Battelle, LLC.) - initial API and implementation and/or
// * initial documentation
// *
// *******************************************************************************/
// package org.eclipse.ice.client.widgets.jme;
//
// import org.eclipse.ice.client.widgets.reactoreditor.plant.PlantAppState;
// import org.eclipse.ice.reactor.plant.PlantComposite;
// import org.eclipse.ice.viz.service.jme3.application.MasterApplication;
// import org.eclipse.ice.viz.service.jme3.application.ViewAppState;
// import org.eclipse.ice.viz.service.jme3.internal.MasterApplicationHolder;
//
/// **
// * This factory is used to create custom {@link ViewAppState}s for components
// * including <code>GeometryComponent</code>s, <code>MeshComponent</code>s, and
// * <code>PlantComposite</code>s. To embed the view in an SWT
// * <code>Composite</code>, see
// * {@link ViewAppState#createComposite(org.eclipse.swt.widgets.Composite)}.
// *
// * @author Jordan
// *
// */
// public class ViewFactory {
//
// // TODO We may want to handle this via an OSGi-based factories and registry.
//
// /**
// * The core <code>MasterApplication</code> that renders all of the views.
// */
// private final MasterApplication app;
//
// /**
// * The default constructor.
// */
// public ViewFactory() {
// this(false);
// }
//
// /**
// * A constructor that allows the <code>ViewFactory</code> to create its own
// * {@link MasterApplication} if the OSGi-provided
// * <code>MasterApplication</code> is not available.
// * <p>
// * <b>Note:</b> This is <i>not intended</i> for use inside ICE but inside
// * static applications. In ICE, the <code>MasterApplication</code> is
// * created only via an OSGi-provided factory.
// * </p>
// * <p>
// * <b>Note 2:</b> If you use more than one <code>ViewFactory</code> with
// * <code>staticFallBack</code> set to <code>true</code> and without running
// * OSGi, then your program may not work properly. jME does not support
// * multiple <code>SimpleApplication</code>s running simultaneously.
// * </p>
// *
// * @param staticFallBack
// * If true, then this factory will create its own
// * <code>MasterApplication</code> when it cannot acquire one via
// * OSGi.
// */
// public ViewFactory(boolean staticFallBack) {
//
// // Try to get the app via OSGi.
// MasterApplication app = MasterApplicationHolder.getApplication();
// // If the flag is set to true and we couldn't get the app through OSGi,
// // create a new app.
// if (app == null && staticFallBack) {
// app = MasterApplication.createApplication();
// }
//
// this.app = app;
// }
//
// /**
//// * Creates a {@link MeshAppState} for the specified
//// * <code>MeshComponent</code>.
//// *
//// * @param mesh
//// * The root <code>MeshComponent</code> or mesh that contains
//// * edges, vertices, and other <code>MeshComponent</code>s.
//// * @return A new <code>MeshAppState</code>, or null if there is no core
//// * <code>MasterApplication</code> in the background.
//// */
//// public MeshAppState createMeshView(MeshComponent mesh) {
////
//// MeshAppState view = null;
////
//// if (app != null) {
////
//// // If necessary, wait until the MasterApplication has started before
//// // trying to add a new AppState, or nothing may initialize.
//// if (!app.isInitialized()) {
//// app.blockUntilInitialized(0);
//// }
////
//// view = new MeshAppState();
//// view.start(app);
////
//// view.setMesh(mesh);
//// }
////
//// return view;
//// }
//
// /**
// * Creates a {@link PlantAppState} for the specified
// * <code>PlantComposite</code>.
// *
// * @param plant
// * The root <code>PlantComponent</code> or plant that can contain
// * several <code>PlantComponent</code>s.
// * @return A new <code>PlantAppState</code>, or null if there is no core
// * <code>MasterApplication</code> in the background.
// */
// public PlantAppState createPlantView(PlantComposite plant) {
//
// PlantAppState view = null;
//
// if (app != null) {
//
// // If necessary, wait until the MasterApplication has started before
// // trying to add a new AppState, or nothing may initialize.
// if (!app.isInitialized()) {
// app.blockUntilInitialized(0);
// }
//
// view = new PlantAppState();
// view.start(app);
//
// view.setPlant(plant);
// }
//
// return view;
// }
//
// /**
// * Disposes of the specified view.
// *
// * @param view
// * The view to dispose.
// */
// public void disposeView(ViewAppState view) {
//
// if (view != null) {
// view.stop();
//
// // If we need to do anything special, do it here.
// }
//
// return;
// }
//
// }
/// *******************************************************************************
// * Copyright (c) 2014 UT-Battelle, LLC.
// * 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:
// * Initial API and implementation and/or initial documentation - Jay Jay
/// Billings,
// * Jordan H. Deyton, Dasha Gorin, Alexander J. McCaskey, Taylor Patterson,
// * Claire Saunders, Matthew Wang, Anna Wojtowicz
// *******************************************************************************/
// package org.eclipse.ice.client.widgets.reactoreditor.plant;
//
// import java.util.concurrent.Callable;
// import java.util.concurrent.atomic.AtomicBoolean;
//
// import org.eclipse.ice.client.widgets.jme.AbstractController;
// import org.eclipse.ice.datastructures.ICEObject.IUpdateable;
// import org.eclipse.ice.viz.service.jme3.application.IRenderQueue;
//
// import com.jme3.math.ColorRGBA;
//
/// **
// * This class provides a base implementation for a controller that manages a
// * model for a Plant-level component and synchronizes an
// * {@link AbstractPlantView} with any changes to the model or features
/// provided
// * by this controller.<br>
// * <br>
// * The features exposed by this class should be similar to the features
/// provided
// * for each plant component in Peacock.
// *
// * @author Jordan H. Deyton
// *
// */
// public abstract class AbstractPlantController extends AbstractController {
//
// /**
// * The {@link AbstractPlantView} associated with this controller.
// */
// private final AbstractPlantView view;
//
// // ---- Additional Features ---- //
// /**
// * Whether or not to render the view with a wire frame.
// */
// private final AtomicBoolean wireFrame;
//
// /**
// * The base color used with the view.
// */
// protected ColorRGBA baseColor;
// // ----------------------------- //
//
// /**
// * The default constructor.
// *
// * @param model
// * The model for which this controller provides a view.
// * @param view
// * The view associated with this controller. This needs to be
// * instantiated by the sub-class.
// * @param renderQueue
// * The queue responsible for tasks that need to be performed on
// * the jME rendering thread.
// */
// public AbstractPlantController(IUpdateable model, AbstractPlantView view,
// IRenderQueue renderQueue) {
// super(model, view, renderQueue);
//
// // Set the view. If it is null, create a new invalid view.
// this.view = (view != null ? view : new AbstractPlantView(
// "Invalid View", null) {
// });
//
// // ---- Initialize any additional features. ---- //
// wireFrame = new AtomicBoolean(false);
// baseColor = new ColorRGBA(1.0f, 1.0f, 1.0f, 1.0f);
// // --------------------------------------------- //
//
// return;
// }
//
// /**
// * Configures the view to either be solid or render as a wire frame.
// *
// * @param wireFrame
// * Whether or not to use a wire frame.
// */
// public void setWireFrame(final boolean wireFrame) {
//
// // If the value has changed from the current value, update wireFrame and
// // update the view.
// if (this.wireFrame.compareAndSet(!wireFrame, wireFrame)) {
//
// // If the controller is not disposed, we should try to update the
// // view's render state.
// if (!disposed.get()) {
// renderQueue.enqueue(new Callable<Boolean>() {
// @Override
// public Boolean call() {
// view.setWireFrame(wireFrame);
// return true;
// }
// });
// }
// }
//
// return;
// }
//
// /**
// * Sets the base or primary color used when rendering the controller's view.
// *
// * @param color
// * The new base color of the view.
// */
// public void setBaseColor(ColorRGBA color) {
//
// // If the value has changed from the current value, update baseColor and
// // update the view.
// if (color != null && !color.equals(baseColor)) {
// baseColor = color;
//
// // If the controller is not disposed, we should try to update the
// // view's render state.
// if (!disposed.get()) {
// renderQueue.enqueue(new Callable<Boolean>() {
// @Override
// public Boolean call() {
// view.setBaseColor(baseColor);
// return true;
// }
// });
// }
// }
//
// return;
// }
// }
/// *******************************************************************************
// * Copyright (c) 2014 UT-Battelle, LLC.
// * 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:
// * Initial API and implementation and/or initial documentation - Jay Jay
/// Billings,
// * Jordan H. Deyton, Dasha Gorin, Alexander J. McCaskey, Taylor Patterson,
// * Claire Saunders, Matthew Wang, Anna Wojtowicz
// *******************************************************************************/
// package org.eclipse.ice.client.widgets.reactoreditor.plant;
//
// import org.eclipse.ice.viz.service.jme3.widgets.AbstractView;
//
// import com.jme3.material.Material;
// import com.jme3.math.ColorRGBA;
// import com.jme3.scene.Geometry;
//
/// **
// * This class provides a base implementation for Plant-level jME3 views, like
/// a
// * Pipe or a Reactor.<br>
// * <br>
// * <b>Operations in this class (not including the constructor) should be
/// called
// * from a SimpleApplication's simpleUpdate() thread.</b>
// *
// * @author Jordan H. Deyton
// *
// */
// public abstract class AbstractPlantView extends AbstractView {
//
// /**
// * The Geometry representing this view in the scene. This may correspond to
// * a cylinder, sphere, or other custom mesh.
// */
// protected final Geometry geometry;