Class LiveStreamView
java.lang.Object
org.eclipse.core.commands.common.EventManager
org.eclipse.ui.part.WorkbenchPart
org.eclipse.ui.part.ViewPart
uk.ac.gda.client.live.stream.view.LiveStreamView
- All Implemented Interfaces:
org.eclipse.core.runtime.IAdaptable,org.eclipse.core.runtime.IExecutableExtension,org.eclipse.ui.IPersistable,org.eclipse.ui.IViewPart,org.eclipse.ui.IWorkbenchPart,org.eclipse.ui.IWorkbenchPart2,org.eclipse.ui.IWorkbenchPart3,org.eclipse.ui.part.IWorkbenchPartOrientation
- Direct Known Subclasses:
LiveStreamViewWithHistogram
public class LiveStreamView
extends org.eclipse.ui.part.ViewPart
A RCP view for connecting to and displaying a live MJPEG stream. The intention is to provide a easy way for cameras
to be integrated into GDA, with minimal Spring configuration.
Can be extended by overriding createLivePlot(Composite, String).
To setup this view in Spring create a CameraConfiguration in client Spring
For additional docs see Setup Live Stream Camera View
-
Field Summary
FieldsFields inherited from interface org.eclipse.ui.IWorkbenchPart
PROP_TITLE -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidcreateLivePlot(org.eclipse.swt.widgets.Composite parent, String secondaryId) This is the method that actually creates a live stream and sets up the plotting composite.voidcreatePartControl(org.eclipse.swt.widgets.Composite parent) voiddispose()<T> TgetAdapter(Class<T> clazz) protected StringgetID()protected IImageTraceprotected LivePlottingCompositeIPlottingSystem<org.eclipse.swt.widgets.Composite> protected voidopenViewWithSecondaryId(String secondaryId, boolean closeExistingView) Open a live stream view with the secondary ID specifiedvoidReopen the currently displayed live stream view by callingopenViewWithSecondaryId(String, boolean)voidsetFocus()protected voidsetPlottingComposite(LivePlottingComposite plottingComposite) Methods inherited from class org.eclipse.ui.part.ViewPart
checkSite, getViewSite, init, init, saveState, setContentDescription, setInitializationData, setPartNameMethods inherited from class org.eclipse.ui.part.WorkbenchPart
addPartPropertyListener, addPropertyListener, firePartPropertyChanged, firePropertyChange, getConfigurationElement, getContentDescription, getDefaultImage, getOrientation, getPartName, getPartProperties, getPartProperty, getSite, getTitle, getTitleImage, getTitleToolTip, removePartPropertyListener, removePropertyListener, setPartProperty, setSite, setTitle, setTitleImage, setTitleToolTip, showBusyMethods inherited from class org.eclipse.core.commands.common.EventManager
addListenerObject, clearListeners, getListeners, isListenerAttached, removeListenerObjectMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.eclipse.ui.IWorkbenchPart
addPropertyListener, getSite, getTitle, getTitleImage, getTitleToolTip, removePropertyListener
-
Field Details
-
ID
- See Also:
-
-
Constructor Details
-
LiveStreamView
public LiveStreamView()
-
-
Method Details
-
createPartControl
public void createPartControl(org.eclipse.swt.widgets.Composite parent) - Specified by:
createPartControlin interfaceorg.eclipse.ui.IWorkbenchPart- Specified by:
createPartControlin classorg.eclipse.ui.part.WorkbenchPart
-
createLivePlot
This is the method that actually creates a live stream and sets up the plotting composite.To get here the secondary id of the view need to be set (hopefully to a valid camera id)
When extending this class it is necessary to call this method with the composite the plot should be drawn on.
- Parameters:
parent- Composite to draw onsecondaryId- The name of the camera to use and type of stream to display
-
setFocus
public void setFocus()- Specified by:
setFocusin interfaceorg.eclipse.ui.IWorkbenchPart- Specified by:
setFocusin classorg.eclipse.ui.part.WorkbenchPart
-
getAdapter
- Specified by:
getAdapterin interfaceorg.eclipse.core.runtime.IAdaptable- Overrides:
getAdapterin classorg.eclipse.ui.part.WorkbenchPart
-
dispose
public void dispose()- Specified by:
disposein interfaceorg.eclipse.ui.IWorkbenchPart- Overrides:
disposein classorg.eclipse.ui.part.WorkbenchPart
-
reopenView
public void reopenView()Reopen the currently displayed live stream view by callingopenViewWithSecondaryId(String, boolean) -
openViewWithSecondaryId
Open a live stream view with the secondary ID specified- Parameters:
secondaryId-closeExistingView- close the existing view first
-
getID
-
getActiveCameraConfiguration
-
getActiveStreamType
-
getSnapshot
- Throws:
LiveStreamException
-
getPlottingSystem
-
getITrace
-
getPlottingComposite
-
setPlottingComposite
-