lttng: Move plugins to their own sub-directory
authorAlexandre Montplaisir <alexmonthy@voxpopuli.im>
Mon, 11 May 2015 21:48:31 +0000 (17:48 -0400)
committerAlexandre Montplaisir <alexmonthy@voxpopuli.im>
Tue, 16 Jun 2015 18:39:48 +0000 (14:39 -0400)
Change-Id: I7a2ec6fb8489f0f337a6f6d7e543bfb248e6383f
Signed-off-by: Alexandre Montplaisir <alexmonthy@voxpopuli.im>
1116 files changed:
lttng/org.eclipse.tracecompass.lttng2.control.core.tests/.classpath [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core.tests/.project [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core.tests/.settings/org.eclipse.core.resources.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core.tests/.settings/org.eclipse.core.runtime.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core.tests/.settings/org.eclipse.jdt.core.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core.tests/.settings/org.eclipse.jdt.ui.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core.tests/.settings/org.eclipse.pde.api.tools.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core.tests/.settings/org.eclipse.pde.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core.tests/META-INF/MANIFEST.MF [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core.tests/about.html [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core.tests/build.properties [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core.tests/plugin.properties [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core.tests/pom.xml [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/ActivatorTest.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/AllTests.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/AllTests.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/BaseEventInfoTest.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/ChannelInfoTest.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/DomainInfoTest.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/EventInfoTest.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/FieldInfoTest.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/ModelImplFactory.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/ProbeEventInfoTest.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/SessionInfoTest.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/SnapshotInfoTest.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/TraceInfoTest.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/UstProviderInfoTest.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/relayd/LttngRelayd24Test.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/session/AllTests.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/session/SessionConfigGeneratorTest.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core.tests/test_session_config_files/test_invalid.lttng [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core.tests/test_session_config_files/test_valid.lttng [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/.classpath [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/.project [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/.settings/org.eclipse.core.resources.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/.settings/org.eclipse.core.runtime.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/.settings/org.eclipse.jdt.core.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/.settings/org.eclipse.jdt.ui.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/.settings/org.eclipse.pde.api.tools.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/.settings/org.eclipse.pde.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/META-INF/MANIFEST.MF [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/about.html [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/build.properties [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/plugin.properties [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/pom.xml [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/Activator.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/IBaseEventInfo.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/IChannelInfo.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/IDomainInfo.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/IEventInfo.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/IFieldInfo.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/IProbeEventInfo.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/ISessionInfo.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/ISnapshotInfo.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/ITraceInfo.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/IUstProviderInfo.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/LogLevelType.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/TargetNodeState.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/TraceChannelOutputType.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/TraceDomainType.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/TraceEnablement.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/TraceEventType.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/TraceLogLevel.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/TraceSessionState.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/BaseEventInfo.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/BufferType.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/ChannelInfo.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/DomainInfo.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/EventInfo.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/FieldInfo.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/ProbeEventInfo.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/SessionInfo.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/SnapshotInfo.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/TraceInfo.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/UstProviderInfo.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/ILttngRelaydConnector.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/LttngRelaydConnectorFactory.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/AttachReturnCode.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/AttachSessionRequest.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/AttachSessionResponse.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/Command.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/ConnectResponse.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/ConnectionType.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/CreateSessionResponse.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/CreateSessionReturnCode.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/GetMetadata.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/GetMetadataReturnCode.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/GetNextIndex.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/GetPacket.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/GetPacketReturnCode.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/IBaseCommand.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/IRelayCommand.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/IRelayResponse.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/IndexResponse.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/ListSessionsResponse.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/LttngViewerCommands.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/MetadataPacketResponse.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/NewStreamsRequest.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/NewStreamsResponse.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/NewStreamsReturnCode.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/NextIndexReturnCode.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/SeekCommand.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/SessionResponse.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/StreamResponse.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/TracePacketResponse.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/ViewerCommand.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/impl/LttngRelaydConnector_2_4.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/impl/LttngRelaydConnector_Unsupported.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/lttng2/control/core/session/Messages.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/lttng2/control/core/session/SessionConfigGenerator.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/lttng2/control/core/session/SessionConfigStrings.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/lttng2/control/core/session/messages.properties [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/lttng2/control/core/session/session.xsd [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/.classpath [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/.project [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/.settings/org.eclipse.core.resources.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/.settings/org.eclipse.core.runtime.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/.settings/org.eclipse.jdt.core.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/.settings/org.eclipse.jdt.ui.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/.settings/org.eclipse.pde.api.tools.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/.settings/org.eclipse.pde.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/META-INF/MANIFEST.MF [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/about.html [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/build.properties [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/plugin.properties [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/pom.xml [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/ActivatorTest.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/AllTests.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/AllTests.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/ListenerValidator.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlComponentTest.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlCreateSessionMiTests.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlCreateSessionTests.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlKernelProviderTests.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlKernelSessionTests.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlPropertiesTest.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlSnapshotSessionTests.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlTestFacility.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlTreeModelNoProvidersTest.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlTreeModelTest.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlUstProviderTests.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlUstSessionTests.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlUstSessionTests2.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/service/AllTests.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/service/LTTngControlServiceMiTest.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/service/LTTngControlServiceTest.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/stubs/org/eclipse/tracecompass/internal/lttng2/control/stubs/dialogs/AddContextDialogStub.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/stubs/org/eclipse/tracecompass/internal/lttng2/control/stubs/dialogs/CreateSessionDialogStub.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/stubs/org/eclipse/tracecompass/internal/lttng2/control/stubs/dialogs/DestroyConfirmDialogStub.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/stubs/org/eclipse/tracecompass/internal/lttng2/control/stubs/dialogs/EnableChannelDialogStub.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/stubs/org/eclipse/tracecompass/internal/lttng2/control/stubs/dialogs/EnableEventsDialogStub.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/stubs/org/eclipse/tracecompass/internal/lttng2/control/stubs/dialogs/GetEventInfoDialogStub.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/stubs/org/eclipse/tracecompass/internal/lttng2/control/stubs/service/TestRemoteSystemProxy.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/stubs/org/eclipse/tracecompass/internal/lttng2/control/stubs/shells/LTTngToolsFileShell.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/testfiles/CreateSessionTest.cfg [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/testfiles/CreateSessionTest2.cfg [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/testfiles/CreateSessionTestMi.cfg [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/testfiles/CreateTreeTest.cfg [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/testfiles/CreateTreeTest2.cfg [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/testfiles/LTTngServiceMiTest.cfg [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/testfiles/LTTngServiceTest.cfg [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/testfiles/ListInfoTest.cfg [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/.classpath [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/.project [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/.settings/org.eclipse.core.resources.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/.settings/org.eclipse.core.runtime.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/.settings/org.eclipse.jdt.core.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/.settings/org.eclipse.jdt.ui.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/.settings/org.eclipse.pde.api.tools.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/.settings/org.eclipse.pde.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/META-INF/MANIFEST.MF [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/about.html [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/build.properties [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/add-context.gif [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/add_button.gif [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/calibrate.gif [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/connect.gif [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/delete_trace.gif [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/disable.gif [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/disable_event.gif [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/disconnect.gif [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/edit.gif [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/enable.gif [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/enable_event.gif [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/import_trace.gif [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/pause_trace.gif [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/refresh.gif [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/snapshot.gif [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/start_trace.gif [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/stop_trace.gif [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/target_add.gif [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/target_delete.gif [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/eview16/control_view.gif [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/channel.gif [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/channel_disabled.gif [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/domain.gif [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/event_disabled.gif [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/event_enabled.gif [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/garland16.png [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/providers.gif [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/session_active.gif [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/session_destroyed.gif [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/session_inactive.gif [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/sessions.gif [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/systemlttng2-live.gif [new file with mode: 0755]
lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/systemlttng2.gif [new file with mode: 0755]
lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/target_connected.gif [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/target_disconnected.gif [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/targets.gif [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/plugin.properties [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/plugin.xml [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/pom.xml [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/Activator.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/relayd/LttngRelaydConnectionInfo.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/relayd/LttngRelaydConnectionManager.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/relayd/LttngRelaydConsumer.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/relayd/Messages.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/relayd/messages.properties [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/ControlView.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/AddContextDialog.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/ConfirmDialog.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/CreateSessionDialog.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/EnableChannelDialog.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/EnableEventsDialog.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/EnableKernelEventComposite.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/EnableUstEventsComposite.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/GetEventInfoDialog.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IAddContextDialog.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IConfirmDialog.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/ICreateSessionDialog.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IEnableChannelDialog.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IEnableEventsDialog.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IEnableKernelEvents.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IEnableUstEvents.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IGetEventInfoDialog.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IImportConfirmationDialog.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IImportDialog.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/INewConnectionDialog.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/ISelectCommandScriptDialog.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/ImportConfirmationDialog.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/ImportDialog.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/ImportFileInfo.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/NewConnectionDialog.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/OpenCommandScriptDialog.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/TraceControlDialogFactory.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/AddContextOnChannelHandler.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/AddContextOnDomainHandler.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/AddContextOnEventHandler.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/AssignEventHandler.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/BaseAddContextHandler.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/BaseControlViewHandler.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/BaseEnableChannelHandler.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/BaseEnableEventHandler.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/BaseNodeHandler.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/CalibrateHandler.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/ChangeChannelStateHandler.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/ChangeEventStateHandler.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/ChangeSessionStateHandler.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/ChannelCommandParameter.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/CommandParameter.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/ConnectHandler.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/CreateSessionHandler.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/DeleteHandler.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/DestroySessionHandler.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/DisableChannelHandler.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/DisableEventHandler.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/DisconnectHandler.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/DomainCommandParameter.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/EnableChannelHandler.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/EnableChannelOnDomainHandler.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/EnableChannelOnSessionHandler.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/EnableEventHandler.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/EnableEventOnChannelHandler.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/EnableEventOnDomainHandler.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/EnableEventOnSessionHandler.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/EventCommandParameter.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/ExecuteCommandScriptHandler.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/ImportHandler.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/NewConnectionHandler.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/RefreshHandler.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/SnaphshotHandler.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/StartHandler.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/StopHandler.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/XmlMiValidationErrorHandler.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/logging/ControlCommandLogger.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/messages/Messages.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/messages/messages.properties [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/ITraceControlComponent.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/ITraceControlComponentChangedListener.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/BaseEventComponent.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/KernelProviderComponent.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/NullControlService.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TargetNodeComponent.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceChannelComponent.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceControlComponent.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceControlContentProvider.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceControlLabelProvider.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceControlPropertyTester.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceControlRoot.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceDomainComponent.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceEventComponent.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceProbeEventComponent.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceProviderGroup.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceSessionComponent.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceSessionGroup.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/UstProviderComponent.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/preferences/ControlPreferenceInitializer.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/preferences/ControlPreferencePage.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/preferences/ControlPreferences.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/BaseEventPropertySource.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/BasePropertySource.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/KernelProviderPropertySource.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/TargetNodePropertySource.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/TraceChannelPropertySource.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/TraceDomainPropertySource.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/TraceEventPropertySource.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/TraceProbeEventPropertySource.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/TraceSessionPropertySource.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/UstProviderPropertySource.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/service/ILttngControlService.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/service/LTTngControlService.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/service/LTTngControlServiceConstants.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/service/LTTngControlServiceFactory.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/service/LTTngControlServiceMI.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/service/LttngVersion.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/service/MIStrings.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/service/mi_lttng.xsd [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control/.project [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control/.settings/org.eclipse.core.resources.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control/.settings/org.eclipse.core.runtime.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control/build.properties [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control/feature.properties [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control/feature.xml [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control/p2.inf [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control/pom.xml [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.control/sourceTemplateFeature/p2.inf [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/.classpath [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/.project [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/.settings/org.eclipse.core.resources.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/.settings/org.eclipse.core.runtime.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/.settings/org.eclipse.jdt.core.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/.settings/org.eclipse.jdt.ui.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/.settings/org.eclipse.pde.api.tools.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/.settings/org.eclipse.pde.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/META-INF/MANIFEST.MF [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/about.html [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/build.properties [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/perf/org/eclipse/tracecompass/lttng2/kernel/core/tests/perf/AllPerfTests.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/perf/org/eclipse/tracecompass/lttng2/kernel/core/tests/perf/analysis/AllPerfTests.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/perf/org/eclipse/tracecompass/lttng2/kernel/core/tests/perf/analysis/AnalysisBenchmark.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/perf/org/eclipse/tracecompass/lttng2/kernel/core/tests/perf/event/matching/AllPerfTests.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/perf/org/eclipse/tracecompass/lttng2/kernel/core/tests/perf/event/matching/EventMatchingBenchmark.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/perf/org/eclipse/tracecompass/lttng2/kernel/core/tests/perf/event/matching/TraceSynchronizationBenchmark.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/plugin.properties [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/pom.xml [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/shared/org/eclipse/tracecompass/lttng2/lttng/kernel/core/tests/shared/vm/VmTestExperiment.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/shared/org/eclipse/tracecompass/lttng2/lttng/kernel/core/tests/shared/vm/VmTraces.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/Activator.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/ActivatorTest.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/AllTests.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/AllTests.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/LttngKernelAnalysisTest.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/statesystem/GenerateTestValues.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/statesystem/PartialStateSystemTest.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/statesystem/StateSystemFullHistoryTest.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/statesystem/StateSystemInMemoryTest.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/statesystem/StateSystemTest.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/statesystem/TestAll.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/statesystem/TestValues.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/vm/AllTests.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/vm/VirtualMachineAnalysisTest.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/event/matchandsync/AllTests.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/event/matchandsync/ExperimentSyncTest.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/event/matchandsync/MatchAndSyncTest.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/testfiles/vm/OneQemuKvm/guest.xml [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/testfiles/vm/OneQemuKvm/host.xml [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core/.classpath [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core/.project [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core/.settings/org.eclipse.core.resources.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core/.settings/org.eclipse.core.runtime.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core/.settings/org.eclipse.jdt.core.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core/.settings/org.eclipse.jdt.ui.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core/.settings/org.eclipse.pde.api.tools.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core/.settings/org.eclipse.pde.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core/META-INF/MANIFEST.MF [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core/about.html [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core/build.properties [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core/plugin.properties [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core/plugin.xml [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core/pom.xml [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/Activator.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/TcpEventStrings.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/VcpuStateValues.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/VmAttributes.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/model/IVirtualMachineModel.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/model/VirtualCPU.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/model/VirtualMachine.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/model/package-info.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/model/qemukvm/QemuKvmStrings.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/model/qemukvm/QemuKvmVmModel.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/model/qemukvm/package-info.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/module/Messages.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/module/VirtualMachineCpuAnalysis.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/module/VirtualMachineStateProvider.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/module/messages.properties [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/module/package-info.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/package-info.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/trace/VirtualMachineExperiment.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/trace/package-info.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/event/matching/TcpEventMatching.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/event/matching/TcpLttngEventMatching.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/trace/layout/Lttng26EventLayout.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/trace/layout/Lttng27EventLayout.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/trace/layout/LttngEventLayout.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/trace/layout/PerfEventLayout.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/trace/layout/package-info.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/lttng2/kernel/core/trace/LttngKernelTrace.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/lttng2/kernel/core/trace/Messages.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/lttng2/kernel/core/trace/messages.properties [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.classpath [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.gitignore [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.project [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.settings/org.eclipse.core.resources.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.settings/org.eclipse.core.runtime.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.settings/org.eclipse.jdt.core.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.settings/org.eclipse.jdt.ui.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.settings/org.eclipse.pde.api.tools.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.settings/org.eclipse.pde.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/META-INF/MANIFEST.MF [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/about.html [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/build.properties [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/plugin.properties [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/pom.xml [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/src/org/eclipse/tracecompass/lttng2/kernel/ui/swtbot/tests/AllTests.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/src/org/eclipse/tracecompass/lttng2/kernel/ui/swtbot/tests/ControlFlowViewTest.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/src/org/eclipse/tracecompass/lttng2/kernel/ui/swtbot/tests/ImportAndReadKernelSmokeTest.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/src/org/eclipse/tracecompass/lttng2/kernel/ui/swtbot/tests/KernelPerspectiveChecker.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/src/org/eclipse/tracecompass/lttng2/kernel/ui/swtbot/tests/KernelTest.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/src/org/eclipse/tracecompass/lttng2/kernel/ui/swtbot/tests/OpenTraceStressTest.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.ui/.classpath [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.ui/.project [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.ui/.settings/org.eclipse.core.resources.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.ui/.settings/org.eclipse.core.runtime.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.ui/.settings/org.eclipse.jdt.core.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.ui/.settings/org.eclipse.jdt.ui.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.ui/.settings/org.eclipse.pde.api.tools.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.ui/.settings/org.eclipse.pde.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.ui/META-INF/MANIFEST.MF [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.ui/about.html [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.ui/build.properties [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.ui/icons/eview16/control_flow_view.gif [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.ui/icons/eview16/resources_view.gif [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.ui/icons/obj16/garland16.png [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.ui/plugin.properties [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.ui/plugin.xml [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.ui/pom.xml [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.ui/src/org/eclipse/tracecompass/internal/lttng2/kernel/ui/Activator.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel.ui/src/org/eclipse/tracecompass/internal/lttng2/kernel/ui/views/PerspectiveFactory.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel/.project [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel/.settings/org.eclipse.core.resources.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel/.settings/org.eclipse.core.runtime.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel/build.properties [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel/feature.properties [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel/feature.xml [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel/p2.inf [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel/pom.xml [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.kernel/sourceTemplateFeature/p2.inf [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/.classpath [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/.project [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/.settings/org.eclipse.core.resources.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/.settings/org.eclipse.core.runtime.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/.settings/org.eclipse.jdt.core.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/.settings/org.eclipse.jdt.ui.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/.settings/org.eclipse.pde.api.tools.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/.settings/org.eclipse.pde.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/META-INF/MANIFEST.MF [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/about.html [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/build.properties [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/plugin.properties [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/pom.xml [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/src/org/eclipse/tracecompass/lttng2/ust/core/tests/ActivatorTest.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/src/org/eclipse/tracecompass/lttng2/ust/core/tests/AllTests.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/src/org/eclipse/tracecompass/lttng2/ust/core/tests/analysis/memory/AllTests.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/src/org/eclipse/tracecompass/lttng2/ust/core/tests/analysis/memory/UstMemoryAnalysisModuleTest.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/src/org/eclipse/tracecompass/lttng2/ust/core/tests/callstack/AbstractProviderTest.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/src/org/eclipse/tracecompass/lttng2/ust/core/tests/callstack/AllTests.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/src/org/eclipse/tracecompass/lttng2/ust/core/tests/callstack/LttngUstCallStackProviderFastTest.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/src/org/eclipse/tracecompass/lttng2/ust/core/tests/callstack/LttngUstCallStackProviderTest.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.core/.classpath [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.core/.project [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.core/.settings/org.eclipse.core.resources.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.core/.settings/org.eclipse.core.runtime.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.core/.settings/org.eclipse.jdt.core.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.core/.settings/org.eclipse.jdt.ui.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.core/.settings/org.eclipse.pde.api.tools.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.core/.settings/org.eclipse.pde.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.core/META-INF/MANIFEST.MF [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.core/about.html [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.core/build.properties [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.core/plugin.properties [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.core/plugin.xml [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.core/pom.xml [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/internal/lttng2/ust/core/Activator.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/internal/lttng2/ust/core/analysis/memory/UstMemoryStateProvider.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/internal/lttng2/ust/core/analysis/memory/UstMemoryStrings.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/internal/lttng2/ust/core/callstack/LttngUstCallStackProvider.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/lttng2/ust/core/analysis/memory/Messages.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/lttng2/ust/core/analysis/memory/UstMemoryAnalysisModule.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/lttng2/ust/core/analysis/memory/messages.properties [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/lttng2/ust/core/trace/LttngUstTrace.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/lttng2/ust/core/trace/Messages.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/lttng2/ust/core/trace/messages.properties [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.ui.tests/.classpath [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.ui.tests/.project [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.ui.tests/.settings/org.eclipse.core.resources.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.ui.tests/.settings/org.eclipse.core.runtime.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.ui.tests/.settings/org.eclipse.jdt.core.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.ui.tests/.settings/org.eclipse.jdt.ui.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.ui.tests/.settings/org.eclipse.pde.api.tools.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.ui.tests/.settings/org.eclipse.pde.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.ui.tests/META-INF/MANIFEST.MF [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.ui.tests/about.html [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.ui.tests/build.properties [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.ui.tests/plugin.properties [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.ui.tests/pom.xml [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.ui.tests/src/org/eclipse/tracecompass/lttng2/ust/ui/tests/ActivatorTest.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.ui.tests/src/org/eclipse/tracecompass/lttng2/ust/ui/tests/AllTests.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.ui/.classpath [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.ui/.project [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.ui/.settings/org.eclipse.core.resources.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.ui/.settings/org.eclipse.core.runtime.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.ui/.settings/org.eclipse.jdt.core.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.ui/.settings/org.eclipse.jdt.ui.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.ui/.settings/org.eclipse.pde.api.tools.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.ui/.settings/org.eclipse.pde.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.ui/META-INF/MANIFEST.MF [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.ui/about.html [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.ui/build.properties [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.ui/icons/obj16/garland16.png [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.ui/plugin.properties [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.ui/plugin.xml [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.ui/pom.xml [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.ui/src/org/eclipse/tracecompass/internal/lttng2/ust/ui/Activator.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.ui/src/org/eclipse/tracecompass/internal/lttng2/ust/ui/views/memusage/MemoryUsageView.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.ui/src/org/eclipse/tracecompass/internal/lttng2/ust/ui/views/memusage/MemoryUsageViewer.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.ui/src/org/eclipse/tracecompass/internal/lttng2/ust/ui/views/memusage/Messages.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.ui/src/org/eclipse/tracecompass/internal/lttng2/ust/ui/views/memusage/messages.properties [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust.ui/src/org/eclipse/tracecompass/lttng2/ust/ui/analysis/callstack/LttngUstCallStackAnalysis.java [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust/.project [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust/.settings/org.eclipse.core.resources.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust/.settings/org.eclipse.core.runtime.prefs [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust/build.properties [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust/feature.properties [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust/feature.xml [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust/p2.inf [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust/pom.xml [new file with mode: 0644]
lttng/org.eclipse.tracecompass.lttng2.ust/sourceTemplateFeature/p2.inf [new file with mode: 0644]
lttng/pom.xml [new file with mode: 0644]
org.eclipse.tracecompass.lttng2.control.core.tests/.classpath [deleted file]
org.eclipse.tracecompass.lttng2.control.core.tests/.project [deleted file]
org.eclipse.tracecompass.lttng2.control.core.tests/.settings/org.eclipse.core.resources.prefs [deleted file]
org.eclipse.tracecompass.lttng2.control.core.tests/.settings/org.eclipse.core.runtime.prefs [deleted file]
org.eclipse.tracecompass.lttng2.control.core.tests/.settings/org.eclipse.jdt.core.prefs [deleted file]
org.eclipse.tracecompass.lttng2.control.core.tests/.settings/org.eclipse.jdt.ui.prefs [deleted file]
org.eclipse.tracecompass.lttng2.control.core.tests/.settings/org.eclipse.pde.api.tools.prefs [deleted file]
org.eclipse.tracecompass.lttng2.control.core.tests/.settings/org.eclipse.pde.prefs [deleted file]
org.eclipse.tracecompass.lttng2.control.core.tests/META-INF/MANIFEST.MF [deleted file]
org.eclipse.tracecompass.lttng2.control.core.tests/about.html [deleted file]
org.eclipse.tracecompass.lttng2.control.core.tests/build.properties [deleted file]
org.eclipse.tracecompass.lttng2.control.core.tests/plugin.properties [deleted file]
org.eclipse.tracecompass.lttng2.control.core.tests/pom.xml [deleted file]
org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/ActivatorTest.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/AllTests.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/AllTests.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/BaseEventInfoTest.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/ChannelInfoTest.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/DomainInfoTest.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/EventInfoTest.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/FieldInfoTest.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/ModelImplFactory.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/ProbeEventInfoTest.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/SessionInfoTest.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/SnapshotInfoTest.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/TraceInfoTest.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/UstProviderInfoTest.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/relayd/LttngRelayd24Test.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/session/AllTests.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/session/SessionConfigGeneratorTest.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core.tests/test_session_config_files/test_invalid.lttng [deleted file]
org.eclipse.tracecompass.lttng2.control.core.tests/test_session_config_files/test_valid.lttng [deleted file]
org.eclipse.tracecompass.lttng2.control.core/.classpath [deleted file]
org.eclipse.tracecompass.lttng2.control.core/.project [deleted file]
org.eclipse.tracecompass.lttng2.control.core/.settings/org.eclipse.core.resources.prefs [deleted file]
org.eclipse.tracecompass.lttng2.control.core/.settings/org.eclipse.core.runtime.prefs [deleted file]
org.eclipse.tracecompass.lttng2.control.core/.settings/org.eclipse.jdt.core.prefs [deleted file]
org.eclipse.tracecompass.lttng2.control.core/.settings/org.eclipse.jdt.ui.prefs [deleted file]
org.eclipse.tracecompass.lttng2.control.core/.settings/org.eclipse.pde.api.tools.prefs [deleted file]
org.eclipse.tracecompass.lttng2.control.core/.settings/org.eclipse.pde.prefs [deleted file]
org.eclipse.tracecompass.lttng2.control.core/META-INF/MANIFEST.MF [deleted file]
org.eclipse.tracecompass.lttng2.control.core/about.html [deleted file]
org.eclipse.tracecompass.lttng2.control.core/build.properties [deleted file]
org.eclipse.tracecompass.lttng2.control.core/plugin.properties [deleted file]
org.eclipse.tracecompass.lttng2.control.core/pom.xml [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/Activator.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/IBaseEventInfo.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/IChannelInfo.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/IDomainInfo.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/IEventInfo.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/IFieldInfo.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/IProbeEventInfo.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/ISessionInfo.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/ISnapshotInfo.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/ITraceInfo.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/IUstProviderInfo.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/LogLevelType.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/TargetNodeState.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/TraceChannelOutputType.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/TraceDomainType.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/TraceEnablement.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/TraceEventType.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/TraceLogLevel.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/TraceSessionState.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/BaseEventInfo.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/BufferType.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/ChannelInfo.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/DomainInfo.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/EventInfo.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/FieldInfo.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/ProbeEventInfo.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/SessionInfo.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/SnapshotInfo.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/TraceInfo.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/UstProviderInfo.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/ILttngRelaydConnector.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/LttngRelaydConnectorFactory.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/AttachReturnCode.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/AttachSessionRequest.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/AttachSessionResponse.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/Command.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/ConnectResponse.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/ConnectionType.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/CreateSessionResponse.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/CreateSessionReturnCode.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/GetMetadata.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/GetMetadataReturnCode.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/GetNextIndex.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/GetPacket.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/GetPacketReturnCode.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/IBaseCommand.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/IRelayCommand.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/IRelayResponse.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/IndexResponse.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/ListSessionsResponse.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/LttngViewerCommands.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/MetadataPacketResponse.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/NewStreamsRequest.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/NewStreamsResponse.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/NewStreamsReturnCode.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/NextIndexReturnCode.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/SeekCommand.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/SessionResponse.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/StreamResponse.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/TracePacketResponse.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/ViewerCommand.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/impl/LttngRelaydConnector_2_4.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/impl/LttngRelaydConnector_Unsupported.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/lttng2/control/core/session/Messages.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/lttng2/control/core/session/SessionConfigGenerator.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/lttng2/control/core/session/SessionConfigStrings.java [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/lttng2/control/core/session/messages.properties [deleted file]
org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/lttng2/control/core/session/session.xsd [deleted file]
org.eclipse.tracecompass.lttng2.control.ui.tests/.classpath [deleted file]
org.eclipse.tracecompass.lttng2.control.ui.tests/.project [deleted file]
org.eclipse.tracecompass.lttng2.control.ui.tests/.settings/org.eclipse.core.resources.prefs [deleted file]
org.eclipse.tracecompass.lttng2.control.ui.tests/.settings/org.eclipse.core.runtime.prefs [deleted file]
org.eclipse.tracecompass.lttng2.control.ui.tests/.settings/org.eclipse.jdt.core.prefs [deleted file]
org.eclipse.tracecompass.lttng2.control.ui.tests/.settings/org.eclipse.jdt.ui.prefs [deleted file]
org.eclipse.tracecompass.lttng2.control.ui.tests/.settings/org.eclipse.pde.api.tools.prefs [deleted file]
org.eclipse.tracecompass.lttng2.control.ui.tests/.settings/org.eclipse.pde.prefs [deleted file]
org.eclipse.tracecompass.lttng2.control.ui.tests/META-INF/MANIFEST.MF [deleted file]
org.eclipse.tracecompass.lttng2.control.ui.tests/about.html [deleted file]
org.eclipse.tracecompass.lttng2.control.ui.tests/build.properties [deleted file]
org.eclipse.tracecompass.lttng2.control.ui.tests/plugin.properties [deleted file]
org.eclipse.tracecompass.lttng2.control.ui.tests/pom.xml [deleted file]
org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/ActivatorTest.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/AllTests.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/AllTests.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/ListenerValidator.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlComponentTest.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlCreateSessionMiTests.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlCreateSessionTests.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlKernelProviderTests.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlKernelSessionTests.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlPropertiesTest.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlSnapshotSessionTests.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlTestFacility.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlTreeModelNoProvidersTest.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlTreeModelTest.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlUstProviderTests.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlUstSessionTests.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlUstSessionTests2.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/service/AllTests.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/service/LTTngControlServiceMiTest.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/service/LTTngControlServiceTest.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui.tests/stubs/org/eclipse/tracecompass/internal/lttng2/control/stubs/dialogs/AddContextDialogStub.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui.tests/stubs/org/eclipse/tracecompass/internal/lttng2/control/stubs/dialogs/CreateSessionDialogStub.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui.tests/stubs/org/eclipse/tracecompass/internal/lttng2/control/stubs/dialogs/DestroyConfirmDialogStub.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui.tests/stubs/org/eclipse/tracecompass/internal/lttng2/control/stubs/dialogs/EnableChannelDialogStub.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui.tests/stubs/org/eclipse/tracecompass/internal/lttng2/control/stubs/dialogs/EnableEventsDialogStub.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui.tests/stubs/org/eclipse/tracecompass/internal/lttng2/control/stubs/dialogs/GetEventInfoDialogStub.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui.tests/stubs/org/eclipse/tracecompass/internal/lttng2/control/stubs/service/TestRemoteSystemProxy.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui.tests/stubs/org/eclipse/tracecompass/internal/lttng2/control/stubs/shells/LTTngToolsFileShell.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui.tests/testfiles/CreateSessionTest.cfg [deleted file]
org.eclipse.tracecompass.lttng2.control.ui.tests/testfiles/CreateSessionTest2.cfg [deleted file]
org.eclipse.tracecompass.lttng2.control.ui.tests/testfiles/CreateSessionTestMi.cfg [deleted file]
org.eclipse.tracecompass.lttng2.control.ui.tests/testfiles/CreateTreeTest.cfg [deleted file]
org.eclipse.tracecompass.lttng2.control.ui.tests/testfiles/CreateTreeTest2.cfg [deleted file]
org.eclipse.tracecompass.lttng2.control.ui.tests/testfiles/LTTngServiceMiTest.cfg [deleted file]
org.eclipse.tracecompass.lttng2.control.ui.tests/testfiles/LTTngServiceTest.cfg [deleted file]
org.eclipse.tracecompass.lttng2.control.ui.tests/testfiles/ListInfoTest.cfg [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/.classpath [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/.project [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/.settings/org.eclipse.core.resources.prefs [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/.settings/org.eclipse.core.runtime.prefs [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/.settings/org.eclipse.jdt.core.prefs [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/.settings/org.eclipse.jdt.ui.prefs [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/.settings/org.eclipse.pde.api.tools.prefs [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/.settings/org.eclipse.pde.prefs [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/META-INF/MANIFEST.MF [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/about.html [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/build.properties [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/add-context.gif [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/add_button.gif [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/calibrate.gif [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/connect.gif [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/delete_trace.gif [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/disable.gif [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/disable_event.gif [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/disconnect.gif [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/edit.gif [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/enable.gif [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/enable_event.gif [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/import_trace.gif [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/pause_trace.gif [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/refresh.gif [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/snapshot.gif [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/start_trace.gif [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/stop_trace.gif [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/target_add.gif [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/target_delete.gif [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/icons/eview16/control_view.gif [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/channel.gif [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/channel_disabled.gif [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/domain.gif [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/event_disabled.gif [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/event_enabled.gif [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/garland16.png [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/providers.gif [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/session_active.gif [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/session_destroyed.gif [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/session_inactive.gif [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/sessions.gif [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/systemlttng2-live.gif [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/systemlttng2.gif [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/target_connected.gif [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/target_disconnected.gif [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/targets.gif [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/plugin.properties [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/plugin.xml [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/pom.xml [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/Activator.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/relayd/LttngRelaydConnectionInfo.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/relayd/LttngRelaydConnectionManager.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/relayd/LttngRelaydConsumer.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/relayd/Messages.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/relayd/messages.properties [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/ControlView.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/AddContextDialog.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/ConfirmDialog.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/CreateSessionDialog.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/EnableChannelDialog.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/EnableEventsDialog.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/EnableKernelEventComposite.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/EnableUstEventsComposite.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/GetEventInfoDialog.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IAddContextDialog.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IConfirmDialog.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/ICreateSessionDialog.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IEnableChannelDialog.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IEnableEventsDialog.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IEnableKernelEvents.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IEnableUstEvents.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IGetEventInfoDialog.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IImportConfirmationDialog.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IImportDialog.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/INewConnectionDialog.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/ISelectCommandScriptDialog.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/ImportConfirmationDialog.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/ImportDialog.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/ImportFileInfo.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/NewConnectionDialog.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/OpenCommandScriptDialog.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/TraceControlDialogFactory.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/AddContextOnChannelHandler.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/AddContextOnDomainHandler.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/AddContextOnEventHandler.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/AssignEventHandler.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/BaseAddContextHandler.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/BaseControlViewHandler.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/BaseEnableChannelHandler.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/BaseEnableEventHandler.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/BaseNodeHandler.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/CalibrateHandler.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/ChangeChannelStateHandler.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/ChangeEventStateHandler.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/ChangeSessionStateHandler.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/ChannelCommandParameter.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/CommandParameter.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/ConnectHandler.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/CreateSessionHandler.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/DeleteHandler.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/DestroySessionHandler.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/DisableChannelHandler.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/DisableEventHandler.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/DisconnectHandler.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/DomainCommandParameter.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/EnableChannelHandler.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/EnableChannelOnDomainHandler.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/EnableChannelOnSessionHandler.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/EnableEventHandler.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/EnableEventOnChannelHandler.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/EnableEventOnDomainHandler.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/EnableEventOnSessionHandler.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/EventCommandParameter.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/ExecuteCommandScriptHandler.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/ImportHandler.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/NewConnectionHandler.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/RefreshHandler.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/SnaphshotHandler.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/StartHandler.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/StopHandler.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/XmlMiValidationErrorHandler.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/logging/ControlCommandLogger.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/messages/Messages.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/messages/messages.properties [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/ITraceControlComponent.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/ITraceControlComponentChangedListener.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/BaseEventComponent.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/KernelProviderComponent.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/NullControlService.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TargetNodeComponent.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceChannelComponent.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceControlComponent.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceControlContentProvider.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceControlLabelProvider.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceControlPropertyTester.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceControlRoot.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceDomainComponent.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceEventComponent.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceProbeEventComponent.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceProviderGroup.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceSessionComponent.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceSessionGroup.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/UstProviderComponent.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/preferences/ControlPreferenceInitializer.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/preferences/ControlPreferencePage.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/preferences/ControlPreferences.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/BaseEventPropertySource.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/BasePropertySource.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/KernelProviderPropertySource.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/TargetNodePropertySource.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/TraceChannelPropertySource.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/TraceDomainPropertySource.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/TraceEventPropertySource.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/TraceProbeEventPropertySource.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/TraceSessionPropertySource.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/UstProviderPropertySource.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/service/ILttngControlService.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/service/LTTngControlService.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/service/LTTngControlServiceConstants.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/service/LTTngControlServiceFactory.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/service/LTTngControlServiceMI.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/service/LttngVersion.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/service/MIStrings.java [deleted file]
org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/service/mi_lttng.xsd [deleted file]
org.eclipse.tracecompass.lttng2.control/.project [deleted file]
org.eclipse.tracecompass.lttng2.control/.settings/org.eclipse.core.resources.prefs [deleted file]
org.eclipse.tracecompass.lttng2.control/.settings/org.eclipse.core.runtime.prefs [deleted file]
org.eclipse.tracecompass.lttng2.control/build.properties [deleted file]
org.eclipse.tracecompass.lttng2.control/feature.properties [deleted file]
org.eclipse.tracecompass.lttng2.control/feature.xml [deleted file]
org.eclipse.tracecompass.lttng2.control/p2.inf [deleted file]
org.eclipse.tracecompass.lttng2.control/pom.xml [deleted file]
org.eclipse.tracecompass.lttng2.control/sourceTemplateFeature/p2.inf [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core.tests/.classpath [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core.tests/.project [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core.tests/.settings/org.eclipse.core.resources.prefs [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core.tests/.settings/org.eclipse.core.runtime.prefs [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core.tests/.settings/org.eclipse.jdt.core.prefs [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core.tests/.settings/org.eclipse.jdt.ui.prefs [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core.tests/.settings/org.eclipse.pde.api.tools.prefs [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core.tests/.settings/org.eclipse.pde.prefs [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core.tests/META-INF/MANIFEST.MF [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core.tests/about.html [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core.tests/build.properties [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core.tests/perf/org/eclipse/tracecompass/lttng2/kernel/core/tests/perf/AllPerfTests.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core.tests/perf/org/eclipse/tracecompass/lttng2/kernel/core/tests/perf/analysis/AllPerfTests.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core.tests/perf/org/eclipse/tracecompass/lttng2/kernel/core/tests/perf/analysis/AnalysisBenchmark.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core.tests/perf/org/eclipse/tracecompass/lttng2/kernel/core/tests/perf/event/matching/AllPerfTests.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core.tests/perf/org/eclipse/tracecompass/lttng2/kernel/core/tests/perf/event/matching/EventMatchingBenchmark.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core.tests/perf/org/eclipse/tracecompass/lttng2/kernel/core/tests/perf/event/matching/TraceSynchronizationBenchmark.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core.tests/plugin.properties [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core.tests/pom.xml [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core.tests/shared/org/eclipse/tracecompass/lttng2/lttng/kernel/core/tests/shared/vm/VmTestExperiment.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core.tests/shared/org/eclipse/tracecompass/lttng2/lttng/kernel/core/tests/shared/vm/VmTraces.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/Activator.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/ActivatorTest.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/AllTests.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/AllTests.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/LttngKernelAnalysisTest.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/statesystem/GenerateTestValues.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/statesystem/PartialStateSystemTest.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/statesystem/StateSystemFullHistoryTest.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/statesystem/StateSystemInMemoryTest.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/statesystem/StateSystemTest.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/statesystem/TestAll.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/statesystem/TestValues.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/vm/AllTests.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/vm/VirtualMachineAnalysisTest.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/event/matchandsync/AllTests.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/event/matchandsync/ExperimentSyncTest.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/event/matchandsync/MatchAndSyncTest.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core.tests/testfiles/vm/OneQemuKvm/guest.xml [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core.tests/testfiles/vm/OneQemuKvm/host.xml [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core/.classpath [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core/.project [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core/.settings/org.eclipse.core.resources.prefs [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core/.settings/org.eclipse.core.runtime.prefs [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core/.settings/org.eclipse.jdt.core.prefs [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core/.settings/org.eclipse.jdt.ui.prefs [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core/.settings/org.eclipse.pde.api.tools.prefs [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core/.settings/org.eclipse.pde.prefs [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core/META-INF/MANIFEST.MF [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core/about.html [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core/build.properties [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core/plugin.properties [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core/plugin.xml [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core/pom.xml [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/Activator.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/TcpEventStrings.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/VcpuStateValues.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/VmAttributes.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/model/IVirtualMachineModel.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/model/VirtualCPU.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/model/VirtualMachine.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/model/package-info.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/model/qemukvm/QemuKvmStrings.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/model/qemukvm/QemuKvmVmModel.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/model/qemukvm/package-info.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/module/Messages.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/module/VirtualMachineCpuAnalysis.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/module/VirtualMachineStateProvider.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/module/messages.properties [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/module/package-info.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/package-info.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/trace/VirtualMachineExperiment.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/trace/package-info.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/event/matching/TcpEventMatching.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/event/matching/TcpLttngEventMatching.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/trace/layout/Lttng26EventLayout.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/trace/layout/Lttng27EventLayout.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/trace/layout/LttngEventLayout.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/trace/layout/PerfEventLayout.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/trace/layout/package-info.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/lttng2/kernel/core/trace/LttngKernelTrace.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/lttng2/kernel/core/trace/Messages.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/lttng2/kernel/core/trace/messages.properties [deleted file]
org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.classpath [deleted file]
org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.gitignore [deleted file]
org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.project [deleted file]
org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.settings/org.eclipse.core.resources.prefs [deleted file]
org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.settings/org.eclipse.core.runtime.prefs [deleted file]
org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.settings/org.eclipse.jdt.core.prefs [deleted file]
org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.settings/org.eclipse.jdt.ui.prefs [deleted file]
org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.settings/org.eclipse.pde.api.tools.prefs [deleted file]
org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.settings/org.eclipse.pde.prefs [deleted file]
org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/META-INF/MANIFEST.MF [deleted file]
org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/about.html [deleted file]
org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/build.properties [deleted file]
org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/plugin.properties [deleted file]
org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/pom.xml [deleted file]
org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/src/org/eclipse/tracecompass/lttng2/kernel/ui/swtbot/tests/AllTests.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/src/org/eclipse/tracecompass/lttng2/kernel/ui/swtbot/tests/ControlFlowViewTest.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/src/org/eclipse/tracecompass/lttng2/kernel/ui/swtbot/tests/ImportAndReadKernelSmokeTest.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/src/org/eclipse/tracecompass/lttng2/kernel/ui/swtbot/tests/KernelPerspectiveChecker.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/src/org/eclipse/tracecompass/lttng2/kernel/ui/swtbot/tests/KernelTest.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/src/org/eclipse/tracecompass/lttng2/kernel/ui/swtbot/tests/OpenTraceStressTest.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.ui/.classpath [deleted file]
org.eclipse.tracecompass.lttng2.kernel.ui/.project [deleted file]
org.eclipse.tracecompass.lttng2.kernel.ui/.settings/org.eclipse.core.resources.prefs [deleted file]
org.eclipse.tracecompass.lttng2.kernel.ui/.settings/org.eclipse.core.runtime.prefs [deleted file]
org.eclipse.tracecompass.lttng2.kernel.ui/.settings/org.eclipse.jdt.core.prefs [deleted file]
org.eclipse.tracecompass.lttng2.kernel.ui/.settings/org.eclipse.jdt.ui.prefs [deleted file]
org.eclipse.tracecompass.lttng2.kernel.ui/.settings/org.eclipse.pde.api.tools.prefs [deleted file]
org.eclipse.tracecompass.lttng2.kernel.ui/.settings/org.eclipse.pde.prefs [deleted file]
org.eclipse.tracecompass.lttng2.kernel.ui/META-INF/MANIFEST.MF [deleted file]
org.eclipse.tracecompass.lttng2.kernel.ui/about.html [deleted file]
org.eclipse.tracecompass.lttng2.kernel.ui/build.properties [deleted file]
org.eclipse.tracecompass.lttng2.kernel.ui/icons/eview16/control_flow_view.gif [deleted file]
org.eclipse.tracecompass.lttng2.kernel.ui/icons/eview16/resources_view.gif [deleted file]
org.eclipse.tracecompass.lttng2.kernel.ui/icons/obj16/garland16.png [deleted file]
org.eclipse.tracecompass.lttng2.kernel.ui/plugin.properties [deleted file]
org.eclipse.tracecompass.lttng2.kernel.ui/plugin.xml [deleted file]
org.eclipse.tracecompass.lttng2.kernel.ui/pom.xml [deleted file]
org.eclipse.tracecompass.lttng2.kernel.ui/src/org/eclipse/tracecompass/internal/lttng2/kernel/ui/Activator.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel.ui/src/org/eclipse/tracecompass/internal/lttng2/kernel/ui/views/PerspectiveFactory.java [deleted file]
org.eclipse.tracecompass.lttng2.kernel/.project [deleted file]
org.eclipse.tracecompass.lttng2.kernel/.settings/org.eclipse.core.resources.prefs [deleted file]
org.eclipse.tracecompass.lttng2.kernel/.settings/org.eclipse.core.runtime.prefs [deleted file]
org.eclipse.tracecompass.lttng2.kernel/build.properties [deleted file]
org.eclipse.tracecompass.lttng2.kernel/feature.properties [deleted file]
org.eclipse.tracecompass.lttng2.kernel/feature.xml [deleted file]
org.eclipse.tracecompass.lttng2.kernel/p2.inf [deleted file]
org.eclipse.tracecompass.lttng2.kernel/pom.xml [deleted file]
org.eclipse.tracecompass.lttng2.kernel/sourceTemplateFeature/p2.inf [deleted file]
org.eclipse.tracecompass.lttng2.ust.core.tests/.classpath [deleted file]
org.eclipse.tracecompass.lttng2.ust.core.tests/.project [deleted file]
org.eclipse.tracecompass.lttng2.ust.core.tests/.settings/org.eclipse.core.resources.prefs [deleted file]
org.eclipse.tracecompass.lttng2.ust.core.tests/.settings/org.eclipse.core.runtime.prefs [deleted file]
org.eclipse.tracecompass.lttng2.ust.core.tests/.settings/org.eclipse.jdt.core.prefs [deleted file]
org.eclipse.tracecompass.lttng2.ust.core.tests/.settings/org.eclipse.jdt.ui.prefs [deleted file]
org.eclipse.tracecompass.lttng2.ust.core.tests/.settings/org.eclipse.pde.api.tools.prefs [deleted file]
org.eclipse.tracecompass.lttng2.ust.core.tests/.settings/org.eclipse.pde.prefs [deleted file]
org.eclipse.tracecompass.lttng2.ust.core.tests/META-INF/MANIFEST.MF [deleted file]
org.eclipse.tracecompass.lttng2.ust.core.tests/about.html [deleted file]
org.eclipse.tracecompass.lttng2.ust.core.tests/build.properties [deleted file]
org.eclipse.tracecompass.lttng2.ust.core.tests/plugin.properties [deleted file]
org.eclipse.tracecompass.lttng2.ust.core.tests/pom.xml [deleted file]
org.eclipse.tracecompass.lttng2.ust.core.tests/src/org/eclipse/tracecompass/lttng2/ust/core/tests/ActivatorTest.java [deleted file]
org.eclipse.tracecompass.lttng2.ust.core.tests/src/org/eclipse/tracecompass/lttng2/ust/core/tests/AllTests.java [deleted file]
org.eclipse.tracecompass.lttng2.ust.core.tests/src/org/eclipse/tracecompass/lttng2/ust/core/tests/analysis/memory/AllTests.java [deleted file]
org.eclipse.tracecompass.lttng2.ust.core.tests/src/org/eclipse/tracecompass/lttng2/ust/core/tests/analysis/memory/UstMemoryAnalysisModuleTest.java [deleted file]
org.eclipse.tracecompass.lttng2.ust.core.tests/src/org/eclipse/tracecompass/lttng2/ust/core/tests/callstack/AbstractProviderTest.java [deleted file]
org.eclipse.tracecompass.lttng2.ust.core.tests/src/org/eclipse/tracecompass/lttng2/ust/core/tests/callstack/AllTests.java [deleted file]
org.eclipse.tracecompass.lttng2.ust.core.tests/src/org/eclipse/tracecompass/lttng2/ust/core/tests/callstack/LttngUstCallStackProviderFastTest.java [deleted file]
org.eclipse.tracecompass.lttng2.ust.core.tests/src/org/eclipse/tracecompass/lttng2/ust/core/tests/callstack/LttngUstCallStackProviderTest.java [deleted file]
org.eclipse.tracecompass.lttng2.ust.core/.classpath [deleted file]
org.eclipse.tracecompass.lttng2.ust.core/.project [deleted file]
org.eclipse.tracecompass.lttng2.ust.core/.settings/org.eclipse.core.resources.prefs [deleted file]
org.eclipse.tracecompass.lttng2.ust.core/.settings/org.eclipse.core.runtime.prefs [deleted file]
org.eclipse.tracecompass.lttng2.ust.core/.settings/org.eclipse.jdt.core.prefs [deleted file]
org.eclipse.tracecompass.lttng2.ust.core/.settings/org.eclipse.jdt.ui.prefs [deleted file]
org.eclipse.tracecompass.lttng2.ust.core/.settings/org.eclipse.pde.api.tools.prefs [deleted file]
org.eclipse.tracecompass.lttng2.ust.core/.settings/org.eclipse.pde.prefs [deleted file]
org.eclipse.tracecompass.lttng2.ust.core/META-INF/MANIFEST.MF [deleted file]
org.eclipse.tracecompass.lttng2.ust.core/about.html [deleted file]
org.eclipse.tracecompass.lttng2.ust.core/build.properties [deleted file]
org.eclipse.tracecompass.lttng2.ust.core/plugin.properties [deleted file]
org.eclipse.tracecompass.lttng2.ust.core/plugin.xml [deleted file]
org.eclipse.tracecompass.lttng2.ust.core/pom.xml [deleted file]
org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/internal/lttng2/ust/core/Activator.java [deleted file]
org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/internal/lttng2/ust/core/analysis/memory/UstMemoryStateProvider.java [deleted file]
org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/internal/lttng2/ust/core/analysis/memory/UstMemoryStrings.java [deleted file]
org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/internal/lttng2/ust/core/callstack/LttngUstCallStackProvider.java [deleted file]
org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/lttng2/ust/core/analysis/memory/Messages.java [deleted file]
org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/lttng2/ust/core/analysis/memory/UstMemoryAnalysisModule.java [deleted file]
org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/lttng2/ust/core/analysis/memory/messages.properties [deleted file]
org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/lttng2/ust/core/trace/LttngUstTrace.java [deleted file]
org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/lttng2/ust/core/trace/Messages.java [deleted file]
org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/lttng2/ust/core/trace/messages.properties [deleted file]
org.eclipse.tracecompass.lttng2.ust.ui.tests/.classpath [deleted file]
org.eclipse.tracecompass.lttng2.ust.ui.tests/.project [deleted file]
org.eclipse.tracecompass.lttng2.ust.ui.tests/.settings/org.eclipse.core.resources.prefs [deleted file]
org.eclipse.tracecompass.lttng2.ust.ui.tests/.settings/org.eclipse.core.runtime.prefs [deleted file]
org.eclipse.tracecompass.lttng2.ust.ui.tests/.settings/org.eclipse.jdt.core.prefs [deleted file]
org.eclipse.tracecompass.lttng2.ust.ui.tests/.settings/org.eclipse.jdt.ui.prefs [deleted file]
org.eclipse.tracecompass.lttng2.ust.ui.tests/.settings/org.eclipse.pde.api.tools.prefs [deleted file]
org.eclipse.tracecompass.lttng2.ust.ui.tests/.settings/org.eclipse.pde.prefs [deleted file]
org.eclipse.tracecompass.lttng2.ust.ui.tests/META-INF/MANIFEST.MF [deleted file]
org.eclipse.tracecompass.lttng2.ust.ui.tests/about.html [deleted file]
org.eclipse.tracecompass.lttng2.ust.ui.tests/build.properties [deleted file]
org.eclipse.tracecompass.lttng2.ust.ui.tests/plugin.properties [deleted file]
org.eclipse.tracecompass.lttng2.ust.ui.tests/pom.xml [deleted file]
org.eclipse.tracecompass.lttng2.ust.ui.tests/src/org/eclipse/tracecompass/lttng2/ust/ui/tests/ActivatorTest.java [deleted file]
org.eclipse.tracecompass.lttng2.ust.ui.tests/src/org/eclipse/tracecompass/lttng2/ust/ui/tests/AllTests.java [deleted file]
org.eclipse.tracecompass.lttng2.ust.ui/.classpath [deleted file]
org.eclipse.tracecompass.lttng2.ust.ui/.project [deleted file]
org.eclipse.tracecompass.lttng2.ust.ui/.settings/org.eclipse.core.resources.prefs [deleted file]
org.eclipse.tracecompass.lttng2.ust.ui/.settings/org.eclipse.core.runtime.prefs [deleted file]
org.eclipse.tracecompass.lttng2.ust.ui/.settings/org.eclipse.jdt.core.prefs [deleted file]
org.eclipse.tracecompass.lttng2.ust.ui/.settings/org.eclipse.jdt.ui.prefs [deleted file]
org.eclipse.tracecompass.lttng2.ust.ui/.settings/org.eclipse.pde.api.tools.prefs [deleted file]
org.eclipse.tracecompass.lttng2.ust.ui/.settings/org.eclipse.pde.prefs [deleted file]
org.eclipse.tracecompass.lttng2.ust.ui/META-INF/MANIFEST.MF [deleted file]
org.eclipse.tracecompass.lttng2.ust.ui/about.html [deleted file]
org.eclipse.tracecompass.lttng2.ust.ui/build.properties [deleted file]
org.eclipse.tracecompass.lttng2.ust.ui/icons/obj16/garland16.png [deleted file]
org.eclipse.tracecompass.lttng2.ust.ui/plugin.properties [deleted file]
org.eclipse.tracecompass.lttng2.ust.ui/plugin.xml [deleted file]
org.eclipse.tracecompass.lttng2.ust.ui/pom.xml [deleted file]
org.eclipse.tracecompass.lttng2.ust.ui/src/org/eclipse/tracecompass/internal/lttng2/ust/ui/Activator.java [deleted file]
org.eclipse.tracecompass.lttng2.ust.ui/src/org/eclipse/tracecompass/internal/lttng2/ust/ui/views/memusage/MemoryUsageView.java [deleted file]
org.eclipse.tracecompass.lttng2.ust.ui/src/org/eclipse/tracecompass/internal/lttng2/ust/ui/views/memusage/MemoryUsageViewer.java [deleted file]
org.eclipse.tracecompass.lttng2.ust.ui/src/org/eclipse/tracecompass/internal/lttng2/ust/ui/views/memusage/Messages.java [deleted file]
org.eclipse.tracecompass.lttng2.ust.ui/src/org/eclipse/tracecompass/internal/lttng2/ust/ui/views/memusage/messages.properties [deleted file]
org.eclipse.tracecompass.lttng2.ust.ui/src/org/eclipse/tracecompass/lttng2/ust/ui/analysis/callstack/LttngUstCallStackAnalysis.java [deleted file]
org.eclipse.tracecompass.lttng2.ust/.project [deleted file]
org.eclipse.tracecompass.lttng2.ust/.settings/org.eclipse.core.resources.prefs [deleted file]
org.eclipse.tracecompass.lttng2.ust/.settings/org.eclipse.core.runtime.prefs [deleted file]
org.eclipse.tracecompass.lttng2.ust/build.properties [deleted file]
org.eclipse.tracecompass.lttng2.ust/feature.properties [deleted file]
org.eclipse.tracecompass.lttng2.ust/feature.xml [deleted file]
org.eclipse.tracecompass.lttng2.ust/p2.inf [deleted file]
org.eclipse.tracecompass.lttng2.ust/pom.xml [deleted file]
org.eclipse.tracecompass.lttng2.ust/sourceTemplateFeature/p2.inf [deleted file]
pom.xml

diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/.classpath b/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/.classpath
new file mode 100644 (file)
index 0000000..098194c
--- /dev/null
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+       <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7"/>
+       <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
+       <classpathentry kind="src" path="src"/>
+       <classpathentry kind="output" path="bin"/>
+</classpath>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/.project b/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/.project
new file mode 100644 (file)
index 0000000..96d73f6
--- /dev/null
@@ -0,0 +1,34 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+       <name>org.eclipse.tracecompass.lttng2.control.core.tests</name>
+       <comment></comment>
+       <projects>
+       </projects>
+       <buildSpec>
+               <buildCommand>
+                       <name>org.eclipse.jdt.core.javabuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+               <buildCommand>
+                       <name>org.eclipse.pde.ManifestBuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+               <buildCommand>
+                       <name>org.eclipse.pde.SchemaBuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+               <buildCommand>
+                       <name>org.eclipse.pde.api.tools.apiAnalysisBuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+       </buildSpec>
+       <natures>
+               <nature>org.eclipse.pde.PluginNature</nature>
+               <nature>org.eclipse.jdt.core.javanature</nature>
+               <nature>org.eclipse.pde.api.tools.apiAnalysisNature</nature>
+       </natures>
+</projectDescription>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/.settings/org.eclipse.core.resources.prefs b/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/.settings/org.eclipse.core.resources.prefs
new file mode 100644 (file)
index 0000000..99f26c0
--- /dev/null
@@ -0,0 +1,2 @@
+eclipse.preferences.version=1
+encoding/<project>=UTF-8
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/.settings/org.eclipse.core.runtime.prefs b/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/.settings/org.eclipse.core.runtime.prefs
new file mode 100644 (file)
index 0000000..5a0ad22
--- /dev/null
@@ -0,0 +1,2 @@
+eclipse.preferences.version=1
+line.separator=\n
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/.settings/org.eclipse.jdt.core.prefs b/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/.settings/org.eclipse.jdt.core.prefs
new file mode 100644 (file)
index 0000000..0409c61
--- /dev/null
@@ -0,0 +1,403 @@
+eclipse.preferences.version=1
+org.eclipse.jdt.core.codeComplete.argumentPrefixes=
+org.eclipse.jdt.core.codeComplete.argumentSuffixes=
+org.eclipse.jdt.core.codeComplete.fieldPrefixes=f
+org.eclipse.jdt.core.codeComplete.fieldSuffixes=
+org.eclipse.jdt.core.codeComplete.localPrefixes=
+org.eclipse.jdt.core.codeComplete.localSuffixes=
+org.eclipse.jdt.core.codeComplete.staticFieldPrefixes=
+org.eclipse.jdt.core.codeComplete.staticFieldSuffixes=
+org.eclipse.jdt.core.codeComplete.staticFinalFieldPrefixes=
+org.eclipse.jdt.core.codeComplete.staticFinalFieldSuffixes=
+org.eclipse.jdt.core.compiler.annotation.inheritNullAnnotations=enabled
+org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore
+org.eclipse.jdt.core.compiler.annotation.nonnull=org.eclipse.jdt.annotation.NonNull
+org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=org.eclipse.jdt.annotation.NonNullByDefault
+org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nullable
+org.eclipse.jdt.core.compiler.annotation.nullanalysis=enabled
+org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
+org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
+org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
+org.eclipse.jdt.core.compiler.compliance=1.7
+org.eclipse.jdt.core.compiler.debug.lineNumber=generate
+org.eclipse.jdt.core.compiler.debug.localVariable=generate
+org.eclipse.jdt.core.compiler.debug.sourceFile=generate
+org.eclipse.jdt.core.compiler.doc.comment.support=enabled
+org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=error
+org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
+org.eclipse.jdt.core.compiler.problem.autoboxing=ignore
+org.eclipse.jdt.core.compiler.problem.comparingIdentical=error
+org.eclipse.jdt.core.compiler.problem.deadCode=error
+org.eclipse.jdt.core.compiler.problem.deprecation=error
+org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled
+org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=enabled
+org.eclipse.jdt.core.compiler.problem.discouragedReference=error
+org.eclipse.jdt.core.compiler.problem.emptyStatement=error
+org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
+org.eclipse.jdt.core.compiler.problem.explicitlyClosedAutoCloseable=error
+org.eclipse.jdt.core.compiler.problem.fallthroughCase=error
+org.eclipse.jdt.core.compiler.problem.fatalOptionalError=disabled
+org.eclipse.jdt.core.compiler.problem.fieldHiding=error
+org.eclipse.jdt.core.compiler.problem.finalParameterBound=error
+org.eclipse.jdt.core.compiler.problem.finallyBlockNotCompletingNormally=error
+org.eclipse.jdt.core.compiler.problem.forbiddenReference=error
+org.eclipse.jdt.core.compiler.problem.hiddenCatchBlock=error
+org.eclipse.jdt.core.compiler.problem.includeNullInfoFromAsserts=disabled
+org.eclipse.jdt.core.compiler.problem.incompatibleNonInheritedInterfaceMethod=error
+org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch=error
+org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=error
+org.eclipse.jdt.core.compiler.problem.invalidJavadoc=warning
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTags=enabled
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsDeprecatedRef=enabled
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsNotVisibleRef=enabled
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsVisibility=protected
+org.eclipse.jdt.core.compiler.problem.localVariableHiding=error
+org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=error
+org.eclipse.jdt.core.compiler.problem.missingDefaultCase=error
+org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=error
+org.eclipse.jdt.core.compiler.problem.missingEnumCaseDespiteDefault=enabled
+org.eclipse.jdt.core.compiler.problem.missingHashCodeMethod=error
+org.eclipse.jdt.core.compiler.problem.missingJavadocComments=warning
+org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsOverriding=disabled
+org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsVisibility=protected
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagDescription=all_standard_tags
+org.eclipse.jdt.core.compiler.problem.missingJavadocTags=warning
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagsMethodTypeParameters=disabled
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagsOverriding=disabled
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagsVisibility=protected
+org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotation=error
+org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotationForInterfaceMethodImplementation=enabled
+org.eclipse.jdt.core.compiler.problem.missingSerialVersion=error
+org.eclipse.jdt.core.compiler.problem.missingSynchronizedOnInheritedMethod=error
+org.eclipse.jdt.core.compiler.problem.noEffectAssignment=error
+org.eclipse.jdt.core.compiler.problem.noImplicitStringConversion=error
+org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=ignore
+org.eclipse.jdt.core.compiler.problem.nonnullParameterAnnotationDropped=warning
+org.eclipse.jdt.core.compiler.problem.nullAnnotationInferenceConflict=warning
+org.eclipse.jdt.core.compiler.problem.nullReference=error
+org.eclipse.jdt.core.compiler.problem.nullSpecViolation=error
+org.eclipse.jdt.core.compiler.problem.nullUncheckedConversion=warning
+org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=error
+org.eclipse.jdt.core.compiler.problem.parameterAssignment=error
+org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=error
+org.eclipse.jdt.core.compiler.problem.potentialNullReference=error
+org.eclipse.jdt.core.compiler.problem.potentiallyUnclosedCloseable=warning
+org.eclipse.jdt.core.compiler.problem.rawTypeReference=error
+org.eclipse.jdt.core.compiler.problem.redundantNullAnnotation=warning
+org.eclipse.jdt.core.compiler.problem.redundantNullCheck=error
+org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=error
+org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=error
+org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore
+org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=error
+org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled
+org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=error
+org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=disabled
+org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled
+org.eclipse.jdt.core.compiler.problem.syntacticNullAnalysisForFields=enabled
+org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=ignore
+org.eclipse.jdt.core.compiler.problem.typeParameterHiding=error
+org.eclipse.jdt.core.compiler.problem.unavoidableGenericTypeProblems=disabled
+org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=error
+org.eclipse.jdt.core.compiler.problem.unclosedCloseable=error
+org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=ignore
+org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=error
+org.eclipse.jdt.core.compiler.problem.unnecessaryElse=error
+org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=error
+org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=error
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionExemptExceptionAndThrowable=disabled
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionIncludeDocCommentReference=disabled
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverriding=disabled
+org.eclipse.jdt.core.compiler.problem.unusedImport=error
+org.eclipse.jdt.core.compiler.problem.unusedLabel=error
+org.eclipse.jdt.core.compiler.problem.unusedLocal=error
+org.eclipse.jdt.core.compiler.problem.unusedObjectAllocation=ignore
+org.eclipse.jdt.core.compiler.problem.unusedParameter=ignore
+org.eclipse.jdt.core.compiler.problem.unusedParameterIncludeDocCommentReference=enabled
+org.eclipse.jdt.core.compiler.problem.unusedParameterWhenImplementingAbstract=disabled
+org.eclipse.jdt.core.compiler.problem.unusedParameterWhenOverridingConcrete=disabled
+org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=error
+org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=ignore
+org.eclipse.jdt.core.compiler.problem.unusedWarningToken=error
+org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=error
+org.eclipse.jdt.core.compiler.source=1.7
+org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=16
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_call=16
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation=16
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression=16
+org.eclipse.jdt.core.formatter.alignment_for_assignment=0
+org.eclipse.jdt.core.formatter.alignment_for_binary_expression=16
+org.eclipse.jdt.core.formatter.alignment_for_compact_if=16
+org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=80
+org.eclipse.jdt.core.formatter.alignment_for_enum_constants=0
+org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=16
+org.eclipse.jdt.core.formatter.alignment_for_method_declaration=0
+org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16
+org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=80
+org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation=0
+org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_constructor_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_method_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_union_type_in_multicatch=16
+org.eclipse.jdt.core.formatter.blank_lines_after_imports=1
+org.eclipse.jdt.core.formatter.blank_lines_after_package=1
+org.eclipse.jdt.core.formatter.blank_lines_before_field=0
+org.eclipse.jdt.core.formatter.blank_lines_before_first_class_body_declaration=0
+org.eclipse.jdt.core.formatter.blank_lines_before_imports=1
+org.eclipse.jdt.core.formatter.blank_lines_before_member_type=1
+org.eclipse.jdt.core.formatter.blank_lines_before_method=1
+org.eclipse.jdt.core.formatter.blank_lines_before_new_chunk=1
+org.eclipse.jdt.core.formatter.blank_lines_before_package=0
+org.eclipse.jdt.core.formatter.blank_lines_between_import_groups=1
+org.eclipse.jdt.core.formatter.blank_lines_between_type_declarations=1
+org.eclipse.jdt.core.formatter.brace_position_for_annotation_type_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_array_initializer=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_block=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_block_in_case=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_constructor_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_enum_constant=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_enum_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_method_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_switch=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_type_declaration=end_of_line
+org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_block_comment=false
+org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_javadoc_comment=false
+org.eclipse.jdt.core.formatter.comment.format_block_comments=true
+org.eclipse.jdt.core.formatter.comment.format_header=false
+org.eclipse.jdt.core.formatter.comment.format_html=true
+org.eclipse.jdt.core.formatter.comment.format_javadoc_comments=true
+org.eclipse.jdt.core.formatter.comment.format_line_comments=true
+org.eclipse.jdt.core.formatter.comment.format_source_code=true
+org.eclipse.jdt.core.formatter.comment.indent_parameter_description=true
+org.eclipse.jdt.core.formatter.comment.indent_root_tags=true
+org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags=insert
+org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter=insert
+org.eclipse.jdt.core.formatter.comment.line_length=80
+org.eclipse.jdt.core.formatter.comment.new_lines_at_block_boundaries=true
+org.eclipse.jdt.core.formatter.comment.new_lines_at_javadoc_boundaries=true
+org.eclipse.jdt.core.formatter.comment.preserve_white_space_between_code_and_line_comments=false
+org.eclipse.jdt.core.formatter.compact_else_if=true
+org.eclipse.jdt.core.formatter.continuation_indentation=2
+org.eclipse.jdt.core.formatter.continuation_indentation_for_array_initializer=2
+org.eclipse.jdt.core.formatter.disabling_tag=@formatter\:off
+org.eclipse.jdt.core.formatter.enabling_tag=@formatter\:on
+org.eclipse.jdt.core.formatter.format_guardian_clause_on_one_line=false
+org.eclipse.jdt.core.formatter.format_line_comment_starting_on_first_column=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_annotation_declaration_header=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_constant_header=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_declaration_header=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_type_header=true
+org.eclipse.jdt.core.formatter.indent_breaks_compare_to_cases=true
+org.eclipse.jdt.core.formatter.indent_empty_lines=false
+org.eclipse.jdt.core.formatter.indent_statements_compare_to_block=true
+org.eclipse.jdt.core.formatter.indent_statements_compare_to_body=true
+org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_cases=true
+org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_switch=false
+org.eclipse.jdt.core.formatter.indentation.size=4
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_field=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_local_variable=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_method=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_package=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_parameter=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_type=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_label=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_opening_brace_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_at_end_of_file_if_missing=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_finally_in_try_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_while_in_do_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_annotation_declaration=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_anonymous_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_block=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter=insert
+org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_binary_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_paren_in_cast=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_assert=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_case=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_labeled_statement=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_allocation_expression=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_annotation=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_throws=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_constant_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_declarations=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_explicitconstructorcall_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_increments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_inits=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_throws=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_invocation_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_field_declarations=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_local_declarations=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_parameterized_type_reference=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_superinterfaces=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_ellipsis=insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_brace_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_cast=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_catch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_for=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_if=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_parenthesized_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_switch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_synchronized=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_try=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_while=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_try_resources=insert
+org.eclipse.jdt.core.formatter.insert_space_after_unary_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter=insert
+org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_binary_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_brace_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_cast=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_catch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_for=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_if=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_parenthesized_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_switch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_synchronized=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_try=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_while=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_assert=insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_case=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_default=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_labeled_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_throws=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_constant_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_declarations=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_explicitconstructorcall_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_increments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_inits=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_throws=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_invocation_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_field_declarations=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_local_declarations=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_superinterfaces=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_ellipsis=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_annotation_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_anonymous_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_block=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_constructor_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_constant=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_method_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_switch=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation_type_member_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_catch=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_if=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_parenthesized_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_switch=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_synchronized=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_try=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_while=insert
+org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_return=insert
+org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_throw=insert
+org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_semicolon=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_try_resources=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_unary_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_brackets_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_annotation_type_member_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.join_lines_in_comments=true
+org.eclipse.jdt.core.formatter.join_wrapped_lines=false
+org.eclipse.jdt.core.formatter.keep_else_statement_on_same_line=false
+org.eclipse.jdt.core.formatter.keep_empty_array_initializer_on_one_line=false
+org.eclipse.jdt.core.formatter.keep_imple_if_on_one_line=false
+org.eclipse.jdt.core.formatter.keep_then_statement_on_same_line=false
+org.eclipse.jdt.core.formatter.lineSplit=250
+org.eclipse.jdt.core.formatter.never_indent_block_comments_on_first_column=false
+org.eclipse.jdt.core.formatter.never_indent_line_comments_on_first_column=false
+org.eclipse.jdt.core.formatter.number_of_blank_lines_at_beginning_of_method_body=0
+org.eclipse.jdt.core.formatter.number_of_empty_lines_to_preserve=1
+org.eclipse.jdt.core.formatter.put_empty_statement_on_new_line=true
+org.eclipse.jdt.core.formatter.tabulation.char=space
+org.eclipse.jdt.core.formatter.tabulation.size=4
+org.eclipse.jdt.core.formatter.use_on_off_tags=false
+org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false
+org.eclipse.jdt.core.formatter.wrap_before_binary_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_or_operator_multicatch=true
+org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/.settings/org.eclipse.jdt.ui.prefs b/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/.settings/org.eclipse.jdt.ui.prefs
new file mode 100644 (file)
index 0000000..232a3fd
--- /dev/null
@@ -0,0 +1,60 @@
+eclipse.preferences.version=1
+editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true
+formatter_profile=_tmf-style
+formatter_settings_version=12
+org.eclipse.jdt.ui.exception.name=e
+org.eclipse.jdt.ui.gettersetter.use.is=true
+org.eclipse.jdt.ui.keywordthis=false
+org.eclipse.jdt.ui.overrideannotation=true
+sp_cleanup.add_default_serial_version_id=true
+sp_cleanup.add_generated_serial_version_id=false
+sp_cleanup.add_missing_annotations=false
+sp_cleanup.add_missing_deprecated_annotations=true
+sp_cleanup.add_missing_methods=false
+sp_cleanup.add_missing_nls_tags=false
+sp_cleanup.add_missing_override_annotations=true
+sp_cleanup.add_missing_override_annotations_interface_methods=true
+sp_cleanup.add_serial_version_id=false
+sp_cleanup.always_use_blocks=true
+sp_cleanup.always_use_parentheses_in_expressions=false
+sp_cleanup.always_use_this_for_non_static_field_access=false
+sp_cleanup.always_use_this_for_non_static_method_access=false
+sp_cleanup.convert_to_enhanced_for_loop=false
+sp_cleanup.correct_indentation=false
+sp_cleanup.format_source_code=false
+sp_cleanup.format_source_code_changes_only=false
+sp_cleanup.make_local_variable_final=false
+sp_cleanup.make_parameters_final=false
+sp_cleanup.make_private_fields_final=true
+sp_cleanup.make_type_abstract_if_missing_method=false
+sp_cleanup.make_variable_declarations_final=false
+sp_cleanup.never_use_blocks=false
+sp_cleanup.never_use_parentheses_in_expressions=true
+sp_cleanup.on_save_use_additional_actions=true
+sp_cleanup.organize_imports=false
+sp_cleanup.qualify_static_field_accesses_with_declaring_class=false
+sp_cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=true
+sp_cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=true
+sp_cleanup.qualify_static_member_accesses_with_declaring_class=false
+sp_cleanup.qualify_static_method_accesses_with_declaring_class=false
+sp_cleanup.remove_private_constructors=true
+sp_cleanup.remove_trailing_whitespaces=true
+sp_cleanup.remove_trailing_whitespaces_all=true
+sp_cleanup.remove_trailing_whitespaces_ignore_empty=false
+sp_cleanup.remove_unnecessary_casts=false
+sp_cleanup.remove_unnecessary_nls_tags=false
+sp_cleanup.remove_unused_imports=false
+sp_cleanup.remove_unused_local_variables=false
+sp_cleanup.remove_unused_private_fields=true
+sp_cleanup.remove_unused_private_members=false
+sp_cleanup.remove_unused_private_methods=true
+sp_cleanup.remove_unused_private_types=true
+sp_cleanup.sort_members=false
+sp_cleanup.sort_members_all=false
+sp_cleanup.use_blocks=true
+sp_cleanup.use_blocks_only_for_return_and_throw=false
+sp_cleanup.use_parentheses_in_expressions=false
+sp_cleanup.use_this_for_non_static_field_access=false
+sp_cleanup.use_this_for_non_static_field_access_only_if_necessary=true
+sp_cleanup.use_this_for_non_static_method_access=false
+sp_cleanup.use_this_for_non_static_method_access_only_if_necessary=true
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/.settings/org.eclipse.pde.api.tools.prefs b/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/.settings/org.eclipse.pde.api.tools.prefs
new file mode 100644 (file)
index 0000000..acc3abd
--- /dev/null
@@ -0,0 +1,97 @@
+ANNOTATION_ELEMENT_TYPE_ADDED_METHOD_WITHOUT_DEFAULT_VALUE=Error
+ANNOTATION_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+ANNOTATION_ELEMENT_TYPE_REMOVED_FIELD=Error
+ANNOTATION_ELEMENT_TYPE_REMOVED_METHOD=Error
+ANNOTATION_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_API_TYPE=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_API_TYPE=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_TYPE=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_TYPE=Error
+API_USE_SCAN_FIELD_SEVERITY=Error
+API_USE_SCAN_METHOD_SEVERITY=Error
+API_USE_SCAN_TYPE_SEVERITY=Error
+CLASS_ELEMENT_TYPE_ADDED_METHOD=Error
+CLASS_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
+CLASS_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+CLASS_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
+CLASS_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+CLASS_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
+CLASS_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
+CLASS_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+CLASS_ELEMENT_TYPE_REMOVED_CONSTRUCTOR=Error
+CLASS_ELEMENT_TYPE_REMOVED_FIELD=Error
+CLASS_ELEMENT_TYPE_REMOVED_METHOD=Error
+CLASS_ELEMENT_TYPE_REMOVED_SUPERCLASS=Error
+CLASS_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+CLASS_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+CONSTRUCTOR_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+CONSTRUCTOR_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+CONSTRUCTOR_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
+CONSTRUCTOR_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+ENUM_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
+ENUM_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+ENUM_ELEMENT_TYPE_REMOVED_ENUM_CONSTANT=Error
+ENUM_ELEMENT_TYPE_REMOVED_FIELD=Error
+ENUM_ELEMENT_TYPE_REMOVED_METHOD=Error
+ENUM_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+FIELD_ELEMENT_TYPE_ADDED_VALUE=Error
+FIELD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+FIELD_ELEMENT_TYPE_CHANGED_FINAL_TO_NON_FINAL_STATIC_CONSTANT=Error
+FIELD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
+FIELD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
+FIELD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
+FIELD_ELEMENT_TYPE_CHANGED_TYPE=Error
+FIELD_ELEMENT_TYPE_CHANGED_VALUE=Error
+FIELD_ELEMENT_TYPE_REMOVED_TYPE_ARGUMENT=Error
+FIELD_ELEMENT_TYPE_REMOVED_VALUE=Error
+ILLEGAL_EXTEND=Warning
+ILLEGAL_IMPLEMENT=Warning
+ILLEGAL_INSTANTIATE=Warning
+ILLEGAL_OVERRIDE=Warning
+ILLEGAL_REFERENCE=Warning
+INTERFACE_ELEMENT_TYPE_ADDED_FIELD=Error
+INTERFACE_ELEMENT_TYPE_ADDED_METHOD=Error
+INTERFACE_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
+INTERFACE_ELEMENT_TYPE_ADDED_SUPER_INTERFACE_WITH_METHODS=Error
+INTERFACE_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+INTERFACE_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
+INTERFACE_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_FIELD=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_METHOD=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+INVALID_JAVADOC_TAG=Warning
+INVALID_REFERENCE_IN_SYSTEM_LIBRARIES=Warning
+LEAK_EXTEND=Warning
+LEAK_FIELD_DECL=Warning
+LEAK_IMPLEMENT=Warning
+LEAK_METHOD_PARAM=Warning
+LEAK_METHOD_RETURN_TYPE=Warning
+METHOD_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
+METHOD_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+METHOD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+METHOD_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
+METHOD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
+METHOD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
+METHOD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
+METHOD_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
+METHOD_ELEMENT_TYPE_REMOVED_ANNOTATION_DEFAULT_VALUE=Error
+METHOD_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+MISSING_EE_DESCRIPTIONS=Ignore
+TYPE_PARAMETER_ELEMENT_TYPE_ADDED_CLASS_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_ADDED_INTERFACE_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_CLASS_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_INTERFACE_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_CLASS_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_INTERFACE_BOUND=Error
+UNUSED_PROBLEM_FILTERS=Warning
+automatically_removed_unused_problem_filters=false
+eclipse.preferences.version=1
+incompatible_api_component_version=Error
+incompatible_api_component_version_include_major_without_breaking_change=Disabled
+incompatible_api_component_version_include_minor_without_api_change=Disabled
+invalid_since_tag_version=Error
+malformed_since_tag=Error
+missing_since_tag=Error
+report_api_breakage_when_major_version_incremented=Disabled
+report_resolution_errors_api_component=Warning
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/.settings/org.eclipse.pde.prefs b/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/.settings/org.eclipse.pde.prefs
new file mode 100644 (file)
index 0000000..62cfa90
--- /dev/null
@@ -0,0 +1,32 @@
+compilers.f.unresolved-features=1
+compilers.f.unresolved-plugins=1
+compilers.incompatible-environment=1
+compilers.p.build=1
+compilers.p.build.bin.includes=1
+compilers.p.build.encodings=2
+compilers.p.build.java.compiler=2
+compilers.p.build.java.compliance=1
+compilers.p.build.missing.output=2
+compilers.p.build.output.library=1
+compilers.p.build.source.library=1
+compilers.p.build.src.includes=1
+compilers.p.deprecated=1
+compilers.p.discouraged-class=1
+compilers.p.internal=1
+compilers.p.missing-packages=2
+compilers.p.missing-version-export-package=2
+compilers.p.missing-version-import-package=2
+compilers.p.missing-version-require-bundle=2
+compilers.p.no-required-att=0
+compilers.p.not-externalized-att=2
+compilers.p.unknown-attribute=1
+compilers.p.unknown-class=1
+compilers.p.unknown-element=1
+compilers.p.unknown-identifier=1
+compilers.p.unknown-resource=1
+compilers.p.unresolved-ex-points=0
+compilers.p.unresolved-import=0
+compilers.s.create-docs=false
+compilers.s.doc-folder=doc
+compilers.s.open-tags=1
+eclipse.preferences.version=1
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/META-INF/MANIFEST.MF b/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/META-INF/MANIFEST.MF
new file mode 100644 (file)
index 0000000..d7fbfb1
--- /dev/null
@@ -0,0 +1,16 @@
+Manifest-Version: 1.0
+Bundle-ManifestVersion: 2
+Bundle-Name: %Bundle-Name
+Bundle-Vendor: %Bundle-Vendor
+Bundle-Version: 1.0.0.qualifier
+Bundle-Localization: plugin
+Bundle-SymbolicName: org.eclipse.tracecompass.lttng2.control.core.tests;singleton:=true
+Bundle-ActivationPolicy: lazy
+Bundle-RequiredExecutionEnvironment: JavaSE-1.7
+Require-Bundle: org.junit;bundle-version="4.0.0",
+ org.eclipse.core.runtime,
+ org.eclipse.tracecompass.lttng2.control.core
+Export-Package: org.eclipse.tracecompass.lttng2.control.core.tests;x-friends:="org.eclipse.tracecompass.alltests",
+ org.eclipse.tracecompass.lttng2.control.core.tests.model.impl;x-internal:=true,
+ org.eclipse.tracecompass.lttng2.control.core.tests.relayd,
+ org.eclipse.tracecompass.lttng2.control.core.tests.session
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/about.html b/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/about.html
new file mode 100644 (file)
index 0000000..c258ef5
--- /dev/null
@@ -0,0 +1,28 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"/>
+<title>About</title>
+</head>
+<body lang="EN-US">
+<h2>About This Content</h2>
+<p>June 5, 2006</p>    
+<h3>License</h3>
+
+<p>The Eclipse Foundation makes available all content in this plug-in (&quot;Content&quot;).  Unless otherwise 
+indicated below, the Content is provided to you under the terms and conditions of the
+Eclipse Public License Version 1.0 (&quot;EPL&quot;).  A copy of the EPL is available 
+at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>.
+For purposes of the EPL, &quot;Program&quot; will mean the Content.</p>
+
+<p>If you did not receive this Content directly from the Eclipse Foundation, the Content is 
+being redistributed by another party (&quot;Redistributor&quot;) and different terms and conditions may
+apply to your use of any object code in the Content.  Check the Redistributor's license that was 
+provided with the Content.  If no such license exists, contact the Redistributor.  Unless otherwise
+indicated below, the terms and conditions of the EPL still apply to any source code in the Content
+and such source code may be obtained at <a href="http://www.eclipse.org/">http://www.eclipse.org</a>.</p>
+
+</body>
+</html>
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/build.properties b/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/build.properties
new file mode 100644 (file)
index 0000000..978a8de
--- /dev/null
@@ -0,0 +1,19 @@
+###############################################################################
+# Copyright (c) 2013, 2015 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:
+#     Ericsson - Initial API and implementation
+###############################################################################
+
+source.. = src/
+output.. = bin/
+bin.includes = META-INF/,\
+               .,\
+               plugin.properties,\
+               about.html
+src.includes = about.html
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/plugin.properties b/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/plugin.properties
new file mode 100644 (file)
index 0000000..0558e68
--- /dev/null
@@ -0,0 +1,14 @@
+###############################################################################
+# Copyright (c) 2013, 2014 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:
+#     Ericsson - Initial API and implementation
+###############################################################################
+
+Bundle-Vendor = Eclipse Trace Compass
+Bundle-Name = Trace Compass LTTng Control Core Tests Plug-in
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/pom.xml b/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/pom.xml
new file mode 100644 (file)
index 0000000..d05ff93
--- /dev/null
@@ -0,0 +1,44 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+   Copyright (C) 2011, Red Hat, Inc.
+
+   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
+-->
+<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>
+    <artifactId>org.eclipse.tracecompass.lttng-parent</artifactId>
+    <groupId>org.eclipse.tracecompass</groupId>
+    <version>1.0.0-SNAPSHOT</version>
+  </parent>
+
+  <artifactId>org.eclipse.tracecompass.lttng2.control.core.tests</artifactId>
+  <version>1.0.0-SNAPSHOT</version>
+  <packaging>eclipse-test-plugin</packaging>
+
+  <name>Trace Compass LTTng Control Core Tests Plug-in</name>
+
+ <build>
+    <plugins>
+        <plugin>
+            <groupId>org.eclipse.tycho</groupId>
+            <artifactId>tycho-surefire-plugin</artifactId>
+            <version>${tycho-version}</version>
+            <configuration>
+                <testSuite>org.eclipse.tracecompass.lttng2.control.core.tests</testSuite>
+                <testClass>org.eclipse.tracecompass.lttng2.control.core.tests.AllTests</testClass>
+                <useUIHarness>false</useUIHarness>
+                <useUIThread>false</useUIThread>
+                <product>org.eclipse.platform.ide</product>
+            </configuration>
+        </plugin>
+    </plugins>
+  </build>
+
+ <groupId>org.eclipse.tracecompass</groupId>
+</project>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/ActivatorTest.java b/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/ActivatorTest.java
new file mode 100644 (file)
index 0000000..ee375b7
--- /dev/null
@@ -0,0 +1,61 @@
+/*******************************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Francois Chouinard - Initial API and implementation
+ *   Alexandre Montplaisir - Port to JUnit4
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.control.core.tests;
+
+import static org.junit.Assert.assertTrue;
+
+import org.junit.Test;
+
+/**
+ * Test stubs for the Activator.
+ */
+public class ActivatorTest {
+
+    // ------------------------------------------------------------------------
+    // Tests
+    // ------------------------------------------------------------------------
+
+    /**
+     * Test method for {@link org.eclipse.tracecompass.internal.lttng2.control.core.Activator#Activator()}.
+     */
+    @Test
+    public void testActivator() {
+        assertTrue(true);
+    }
+
+    /**
+     * Test method for {@link org.eclipse.tracecompass.internal.lttng2.control.core.Activator#getDefault()}.
+     */
+    @Test
+    public void testGetDefault() {
+        assertTrue(true);
+    }
+
+    /**
+     * Test method for {@link org.eclipse.tracecompass.internal.lttng2.control.core.Activator#start(org.osgi.framework.BundleContext)}.
+     */
+    @Test
+    public void testStartBundleContext() {
+        assertTrue(true);
+    }
+
+    /**
+     * Test method for {@link org.eclipse.tracecompass.internal.lttng2.control.core.Activator#stop(org.osgi.framework.BundleContext)}.
+     */
+    @Test
+    public void testStopBundleContext() {
+        assertTrue(true);
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/AllTests.java b/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/AllTests.java
new file mode 100644 (file)
index 0000000..e4544e2
--- /dev/null
@@ -0,0 +1,31 @@
+/*******************************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Francois Chouinard - Initial API and implementation
+ *   Alexandre Montplaisir - Port to JUnit4
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.control.core.tests;
+
+import org.junit.runner.RunWith;
+import org.junit.runners.Suite;
+
+/**
+ * Run all the tests in the test suite
+ */
+@RunWith(Suite.class)
+@Suite.SuiteClasses({
+    ActivatorTest.class,
+    org.eclipse.tracecompass.lttng2.control.core.tests.model.impl.AllTests.class,
+    org.eclipse.tracecompass.lttng2.control.core.tests.session.AllTests.class,
+    org.eclipse.tracecompass.lttng2.control.core.tests.model.impl.AllTests.class
+})
+public class AllTests {
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/AllTests.java b/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/AllTests.java
new file mode 100644 (file)
index 0000000..9b5538d
--- /dev/null
@@ -0,0 +1,37 @@
+/*******************************************************************************
+ * Copyright (c) 2011, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Alexandre Montplaisir - Port to JUnit4
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.control.core.tests.model.impl;
+
+import org.junit.runner.RunWith;
+import org.junit.runners.Suite;
+
+/**
+ * Runner for the test suite
+ */
+@RunWith(Suite.class)
+@Suite.SuiteClasses({
+    BaseEventInfoTest.class,
+    ChannelInfoTest.class,
+    DomainInfoTest.class,
+    EventInfoTest.class,
+    FieldInfoTest.class,
+    ProbeEventInfoTest.class,
+    SessionInfoTest.class,
+    TraceInfoTest.class,
+    UstProviderInfoTest.class,
+    SnapshotInfoTest.class
+})
+public class AllTests {
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/BaseEventInfoTest.java b/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/BaseEventInfoTest.java
new file mode 100644 (file)
index 0000000..8199b31
--- /dev/null
@@ -0,0 +1,567 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Alexandre Montplaisir - Port to JUnit4
+ **********************************************************************/
+
+package org.eclipse.tracecompass.lttng2.control.core.tests.model.impl;
+
+import static org.junit.Assert.*;
+
+import java.util.LinkedList;
+import java.util.List;
+
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IBaseEventInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IFieldInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEventType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.BaseEventInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.FieldInfo;
+import org.junit.Before;
+import org.junit.Test;
+
+/**
+ * The class <code>BaseEventInfoTest</code> contains test for the class
+ * <code>{@link BaseEventInfo}</code>.
+ */
+public class BaseEventInfoTest {
+
+    // ------------------------------------------------------------------------
+    // Test data
+    // ------------------------------------------------------------------------
+
+    private IBaseEventInfo fEventInfo1 = null;
+    private IBaseEventInfo fEventInfo2 = null;
+
+    // ------------------------------------------------------------------------
+    // Housekeeping
+    // ------------------------------------------------------------------------
+    /**
+     * Perform pre-test initialization.
+     */
+    @Before
+    public void setUp() {
+        ModelImplFactory factory = new ModelImplFactory();
+        fEventInfo1 = factory.getBaseEventInfo1();
+        fEventInfo2 = factory.getBaseEventInfo2();
+    }
+
+    // ------------------------------------------------------------------------
+    // Tests
+    // ------------------------------------------------------------------------
+
+    /**
+     * Run the BaseEventInfo() constructor test.
+     */
+    @Test
+    public void testBaseEventInfo() {
+        BaseEventInfo fixture = new BaseEventInfo("event");
+        assertNotNull(fixture);
+
+        TraceEventType result = fixture.getEventType();
+
+        assertEquals("event", fixture.getName());
+        assertEquals("unknown", result.getInName());
+        assertEquals("UNKNOWN", result.name());
+        assertEquals("UNKNOWN", result.toString());
+        assertEquals(4, result.ordinal());
+
+        TraceLogLevel level = fixture.getLogLevel();
+        assertEquals("TRACE_DEBUG", level.getInName());
+        assertEquals("TRACE_DEBUG", level.name());
+        assertEquals("TRACE_DEBUG", level.toString());
+        assertEquals(14, level.ordinal());
+    }
+
+    /**
+     * Test Copy Constructor
+     */
+    @Test
+    public void testEventInfoCopy() {
+        BaseEventInfo info = new BaseEventInfo((BaseEventInfo)fEventInfo1);
+
+        assertEquals(fEventInfo1.getName(), info.getName());
+        assertEquals(fEventInfo1.getEventType(), info.getEventType());
+        assertEquals(fEventInfo1.getLogLevel(), info.getLogLevel());
+        assertEquals(fEventInfo1.getFilterExpression(), info.getFilterExpression());
+
+        IFieldInfo[] orignalFields = fEventInfo1.getFields();
+        IFieldInfo[] copiedFields = info.getFields();
+        assertEquals(orignalFields.length, copiedFields.length);
+
+        for (int i = 0; i < copiedFields.length; i++) {
+            assertEquals(orignalFields[i], copiedFields[i]);
+        }
+    }
+
+    /**
+     * Test Copy Constructor
+     */
+    @Test
+    public void testEventCopy2() {
+        try {
+            BaseEventInfo info = null;
+            new BaseEventInfo(info);
+            fail("null copy");
+        }
+        catch (IllegalArgumentException e) {
+            // Success
+        }
+    }
+
+    /**
+     * Run the TraceEventType getEventType() method test.
+     */
+    @Test
+    public void testGetEventType_1() {
+        BaseEventInfo fixture = new BaseEventInfo("event");
+        fixture.setEventType("unknown");
+
+        TraceEventType result = fixture.getEventType();
+
+        assertNotNull(result);
+        assertEquals("unknown", result.getInName());
+        assertEquals("UNKNOWN", result.name());
+        assertEquals("UNKNOWN", result.toString());
+        assertEquals(4, result.ordinal());
+
+        fixture.setEventType("");
+        result = fixture.getEventType();
+        assertEquals("unknown", result.getInName());
+        assertEquals("UNKNOWN", result.name());
+        assertEquals("UNKNOWN", result.toString());
+        assertEquals(4, result.ordinal());
+
+        fixture.setEventType("tracepoint");
+        result = fixture.getEventType();
+        assertNotNull(result);
+        assertEquals("tracepoint", result.getInName());
+        assertEquals("TRACEPOINT", result.name());
+        assertEquals("TRACEPOINT", result.toString());
+        assertEquals(0, result.ordinal());
+
+        fixture.setEventType("syscall");
+        result = fixture.getEventType();
+        assertNotNull(result);
+        assertEquals("syscall", result.getInName());
+        assertEquals("SYSCALL", result.name());
+        assertEquals("SYSCALL", result.toString());
+        assertEquals(1, result.ordinal());
+
+        fixture.setEventType("probe");
+        result = fixture.getEventType();
+        assertNotNull(result);
+        assertEquals("probe", result.getInName());
+        assertEquals("PROBE", result.name());
+        assertEquals("PROBE", result.toString());
+        assertEquals(2, result.ordinal());
+
+        fixture.setEventType("function");
+        result = fixture.getEventType();
+        assertNotNull(result);
+        assertEquals("function", result.getInName());
+        assertEquals("FUNCTION", result.name());
+        assertEquals("FUNCTION", result.toString());
+        assertEquals(3, result.ordinal());
+
+
+    }
+
+    /**
+     * Run the void setEventType(TraceEventType) method test.
+     */
+    @Test
+    public void testSetEventType_2() {
+        BaseEventInfo fixture = new BaseEventInfo("event");
+        fixture.setEventType(TraceEventType.TRACEPOINT);
+
+        TraceEventType result = fixture.getEventType();
+
+        assertNotNull(result);
+        assertEquals("tracepoint", result.getInName());
+        assertEquals("TRACEPOINT", result.name());
+        assertEquals("TRACEPOINT", result.toString());
+        assertEquals(0, result.ordinal());
+
+        fixture.setEventType(TraceEventType.UNKNOWN);
+        result = fixture.getEventType();
+
+        assertNotNull(result);
+        assertEquals("unknown", result.getInName());
+        assertEquals("UNKNOWN", result.name());
+        assertEquals("UNKNOWN", result.toString());
+        assertEquals(4, result.ordinal());
+
+        fixture.setEventType(TraceEventType.SYSCALL);
+        result = fixture.getEventType();
+        assertNotNull(result);
+        assertEquals("syscall", result.getInName());
+        assertEquals("SYSCALL", result.name());
+        assertEquals("SYSCALL", result.toString());
+        assertEquals(1, result.ordinal());
+
+        fixture.setEventType(TraceEventType.PROBE);
+        result = fixture.getEventType();
+        assertNotNull(result);
+        assertEquals("probe", result.getInName());
+        assertEquals("PROBE", result.name());
+        assertEquals("PROBE", result.toString());
+        assertEquals(2, result.ordinal());
+
+        fixture.setEventType(TraceEventType.FUNCTION);
+        result = fixture.getEventType();
+        assertNotNull(result);
+        assertEquals("function", result.getInName());
+        assertEquals("FUNCTION", result.name());
+        assertEquals("FUNCTION", result.toString());
+        assertEquals(3, result.ordinal());
+
+
+    }
+
+    /**
+     * Run the void setLogLevel(TraceLogLevel) method test.
+     * Run the TraceLogLevel getLogLevel() method test
+     */
+    @Test
+    public void testSetLogLevel1() {
+        BaseEventInfo fixture = new BaseEventInfo("event");
+        fixture.setEventType(TraceEventType.TRACEPOINT);
+        fixture.setLogLevel(TraceLogLevel.TRACE_CRIT);
+
+        // 2 set/get-operations are enough to test the method
+        TraceLogLevel result = fixture.getLogLevel();
+        assertNotNull(result);
+        assertEquals("TRACE_CRIT", result.getInName());
+        assertEquals("TRACE_CRIT", result.name());
+        assertEquals("TRACE_CRIT", result.toString());
+        assertEquals(2, result.ordinal());
+
+        fixture.setLogLevel(TraceLogLevel.TRACE_DEBUG_FUNCTION);
+
+        result = fixture.getLogLevel();
+        assertNotNull(result);
+        assertEquals("TRACE_DEBUG_FUNCTION", result.getInName());
+        assertEquals("TRACE_DEBUG_FUNCTION", result.name());
+        assertEquals("TRACE_DEBUG_FUNCTION", result.toString());
+        assertEquals(12, result.ordinal());
+    }
+
+    /**
+     * Run the void setLogLevel(String) method test.
+     * Run the TraceLogLevel getLogLevel() method test
+     */
+    @Test
+    public void testSetLogLevel2() {
+        BaseEventInfo fixture = new BaseEventInfo("event");
+        fixture.setEventType(TraceEventType.TRACEPOINT);
+        fixture.setLogLevel("TRACE_EMERG");
+
+        TraceLogLevel result = fixture.getLogLevel();
+        assertNotNull(result);
+        assertEquals("TRACE_EMERG", result.getInName());
+        assertEquals("TRACE_EMERG", result.name());
+        assertEquals(0, result.ordinal());
+
+        //------------------------
+        fixture.setLogLevel("TRACE_ALERT");
+
+        result = fixture.getLogLevel();
+        assertNotNull(result);
+        assertEquals("TRACE_ALERT", result.getInName());
+        assertEquals("TRACE_ALERT", result.name());
+        assertEquals(1, result.ordinal());
+
+        //------------------------
+        fixture.setLogLevel("TRACE_CRIT");
+
+        result = fixture.getLogLevel();
+        assertNotNull(result);
+        assertEquals("TRACE_CRIT", result.getInName());
+        assertEquals("TRACE_CRIT", result.name());
+        assertEquals(2, result.ordinal());
+
+        //------------------------
+        fixture.setLogLevel("TRACE_ERR");
+
+        result = fixture.getLogLevel();
+        assertNotNull(result);
+        assertEquals("TRACE_ERR", result.getInName());
+        assertEquals("TRACE_ERR", result.name());
+        assertEquals(3, result.ordinal());
+
+        //------------------------
+        fixture.setLogLevel("TRACE_WARNING");
+
+        result = fixture.getLogLevel();
+        assertNotNull(result);
+        assertEquals("TRACE_WARNING", result.getInName());
+        assertEquals("TRACE_WARNING", result.name());
+        assertEquals(4, result.ordinal());
+
+        //------------------------
+        fixture.setLogLevel("TRACE_NOTICE");
+
+        result = fixture.getLogLevel();
+        assertNotNull(result);
+        assertEquals("TRACE_NOTICE", result.getInName());
+        assertEquals("TRACE_NOTICE", result.name());
+        assertEquals(5, result.ordinal());
+
+        //------------------------
+        fixture.setLogLevel("TRACE_INFO");
+
+        result = fixture.getLogLevel();
+        assertNotNull(result);
+        assertEquals("TRACE_INFO", result.getInName());
+        assertEquals("TRACE_INFO", result.name());
+        assertEquals(6, result.ordinal());
+
+        //------------------------
+        fixture.setLogLevel("TRACE_DEBUG_SYSTEM");
+
+        result = fixture.getLogLevel();
+        assertNotNull(result);
+        assertEquals("TRACE_DEBUG_SYSTEM", result.getInName());
+        assertEquals("TRACE_DEBUG_SYSTEM", result.name());
+        assertEquals(7, result.ordinal());
+
+        //------------------------
+        fixture.setLogLevel("TRACE_DEBUG_PROGRAM");
+
+        result = fixture.getLogLevel();
+        assertNotNull(result);
+        assertEquals("TRACE_DEBUG_PROGRAM", result.getInName());
+        assertEquals("TRACE_DEBUG_PROGRAM", result.name());
+        assertEquals(8, result.ordinal());
+
+        //------------------------
+        fixture.setLogLevel("TRACE_DEBUG_PROCESS");
+
+        result = fixture.getLogLevel();
+        assertNotNull(result);
+        assertEquals("TRACE_DEBUG_PROCESS", result.getInName());
+        assertEquals("TRACE_DEBUG_PROCESS", result.name());
+        assertEquals(9, result.ordinal());
+
+        //------------------------
+        fixture.setLogLevel("TRACE_DEBUG_MODULE");
+
+        result = fixture.getLogLevel();
+        assertNotNull(result);
+        assertEquals("TRACE_DEBUG_MODULE", result.getInName());
+        assertEquals("TRACE_DEBUG_MODULE", result.name());
+        assertEquals(10, result.ordinal());
+
+        //------------------------
+        fixture.setLogLevel("TRACE_DEBUG_UNIT");
+
+        result = fixture.getLogLevel();
+        assertNotNull(result);
+        assertEquals("TRACE_DEBUG_UNIT", result.getInName());
+        assertEquals("TRACE_DEBUG_UNIT", result.name());
+        assertEquals(11, result.ordinal());
+
+        //------------------------
+        fixture.setLogLevel("TRACE_DEBUG_FUNCTION");
+
+        result = fixture.getLogLevel();
+        assertNotNull(result);
+        assertEquals("TRACE_DEBUG_FUNCTION", result.getInName());
+        assertEquals("TRACE_DEBUG_FUNCTION", result.name());
+        assertEquals(12, result.ordinal());
+
+        //------------------------
+        fixture.setLogLevel("TRACE_DEBUG_LINE");
+
+        result = fixture.getLogLevel();
+        assertNotNull(result);
+        assertEquals("TRACE_DEBUG_LINE", result.getInName());
+        assertEquals("TRACE_DEBUG_LINE", result.name());
+        assertEquals(13, result.ordinal());
+
+        //------------------------
+        fixture.setLogLevel("TRACE_DEBUG");
+
+        result = fixture.getLogLevel();
+        assertNotNull(result);
+        assertEquals("TRACE_DEBUG", result.getInName());
+        assertEquals("TRACE_DEBUG", result.name());
+        assertEquals(14, result.ordinal());
+
+        //-------------------------
+        fixture.setLogLevel("LEVEL_UNKNOWN");
+
+        result = fixture.getLogLevel();
+        assertNotNull(result);
+        assertEquals("LEVEL_UNKNOWN", result.getInName());
+        assertEquals("LEVEL_UNKNOWN", result.name());
+        assertEquals(15, result.ordinal());
+
+        fixture.setLogLevel("garbage");
+
+        result = fixture.getLogLevel();
+        assertNotNull(result);
+        assertEquals("LEVEL_UNKNOWN", result.getInName());
+        assertEquals("LEVEL_UNKNOWN", result.name());
+        assertEquals(15, result.ordinal());
+    }
+
+    /**
+     * test filter expression
+     */
+    @Test
+     public void testSetFields() {
+         BaseEventInfo info = new BaseEventInfo((BaseEventInfo)fEventInfo2);
+         info.setFilterExpression("stringfield==test");
+         assertEquals("stringfield==test", info.getFilterExpression());
+     }
+
+
+   /**
+    * test add field
+    */
+    @Test
+    public void testAddField() {
+        BaseEventInfo info = new BaseEventInfo((BaseEventInfo)fEventInfo2);
+
+        IFieldInfo field =  new FieldInfo("intfield");
+        field.setFieldType("int");
+
+        info.addField(field);
+
+        // Verify the stored events
+        IFieldInfo[] result = info.getFields();
+
+        assertNotNull(result);
+        assertEquals(1, result.length);
+        assertNotNull(result[0]);
+        assertTrue(field.equals(result[0]));
+    }
+
+    /**
+     * test set fields
+     */
+    @Test
+    public void testFields() {
+        BaseEventInfo info = new BaseEventInfo((BaseEventInfo)fEventInfo2);
+
+        IFieldInfo field1 =  new FieldInfo("intfield");
+        field1.setFieldType("int");
+
+        IFieldInfo field2 =  new FieldInfo("stringfield");
+        field2.setFieldType("string");
+
+        List<IFieldInfo> fields = new LinkedList<>();
+        fields.add(field1);
+        fields.add(field2);
+        info.setFields(fields);
+
+        // Verify the stored events
+        IFieldInfo[] result = info.getFields();
+
+        assertNotNull(result);
+        assertEquals(2, result.length);
+
+        for (int i = 0; i < result.length; i++) {
+            assertNotNull(result[i]);
+            assertTrue(fields.get(i).equals(result[i]));
+        }
+    }
+
+    /**
+     * Run the String toString() method test.
+     */
+    @Test
+    public void testToString_1() {
+        BaseEventInfo fixture = new BaseEventInfo("event");
+        fixture.setName("testName");
+        fixture.setEventType(TraceEventType.TRACEPOINT);
+        fixture.setLogLevel(TraceLogLevel.TRACE_ERR);
+
+        String result = fixture.toString();
+
+        // add additional test code here
+        assertEquals("[BaseEventInfo([TraceInfo(Name=testName)],type=TRACEPOINT,level=TRACE_ERR)]", result);
+    }
+
+    // ------------------------------------------------------------------------
+    // equals
+    // ------------------------------------------------------------------------
+
+    /**
+     * Test the .equals() method.
+     */
+    @Test
+    public void testEqualsReflexivity() {
+        assertTrue("equals", fEventInfo1.equals(fEventInfo1));
+        assertTrue("equals", fEventInfo2.equals(fEventInfo2));
+
+        assertTrue("equals", !fEventInfo1.equals(fEventInfo2));
+        assertTrue("equals", !fEventInfo2.equals(fEventInfo1));
+    }
+
+    /**
+     * Test the .equals() method.
+     */
+    @Test
+    public void testEqualsSymmetry() {
+        BaseEventInfo info1 = new BaseEventInfo((BaseEventInfo)fEventInfo1);
+        BaseEventInfo info2 = new BaseEventInfo((BaseEventInfo)fEventInfo2);
+
+        assertTrue("equals", info1.equals(fEventInfo1));
+        assertTrue("equals", fEventInfo1.equals(info1));
+
+        assertTrue("equals", info2.equals(fEventInfo2));
+        assertTrue("equals", fEventInfo2.equals(info2));
+    }
+
+    /**
+     * Test the .equals() method.
+     */
+    @Test
+    public void testEqualsTransivity() {
+        BaseEventInfo info1 = new BaseEventInfo((BaseEventInfo)fEventInfo1);
+        BaseEventInfo info2 = new BaseEventInfo((BaseEventInfo)fEventInfo1);
+        BaseEventInfo info3 = new BaseEventInfo((BaseEventInfo)fEventInfo1);
+
+        assertTrue("equals", info1.equals(info2));
+        assertTrue("equals", info2.equals(info3));
+        assertTrue("equals", info1.equals(info3));
+    }
+
+    /**
+     * Test the .equals() method.
+     */
+    @Test
+    public void testEqualsNull() {
+        assertTrue("equals", !fEventInfo1.equals(null));
+        assertTrue("equals", !fEventInfo2.equals(null));
+    }
+
+    // ------------------------------------------------------------------------
+    // hashCode
+    // ------------------------------------------------------------------------
+
+    /**
+     * Test the hashCode() method.
+     */
+    @Test
+    public void testHashCode() {
+        BaseEventInfo info1 = new BaseEventInfo((BaseEventInfo)fEventInfo1);
+        BaseEventInfo info2 = new BaseEventInfo((BaseEventInfo)fEventInfo2);
+
+        assertTrue("hashCode", fEventInfo1.hashCode() == info1.hashCode());
+        assertTrue("hashCode", fEventInfo2.hashCode() == info2.hashCode());
+
+        assertTrue("hashCode", fEventInfo1.hashCode() != info2.hashCode());
+        assertTrue("hashCode", fEventInfo2.hashCode() != info1.hashCode());
+    }
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/ChannelInfoTest.java b/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/ChannelInfoTest.java
new file mode 100644 (file)
index 0000000..0e3b247
--- /dev/null
@@ -0,0 +1,382 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2015 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Alexandre Montplaisir - Port to JUnit4
+ **********************************************************************/
+
+package org.eclipse.tracecompass.lttng2.control.core.tests.model.impl;
+
+import static org.junit.Assert.*;
+
+import java.util.LinkedList;
+import java.util.List;
+
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IChannelInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IEventInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceChannelOutputType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEnablement;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.BufferType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.ChannelInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.EventInfo;
+import org.junit.Before;
+import org.junit.Test;
+
+/**
+ * The class <code>ChannelInfoTest</code> contains tests for the class
+ * <code>{@link ChannelInfo}</code>.
+ */
+public class ChannelInfoTest {
+
+    // ------------------------------------------------------------------------
+    // Test data
+    // ------------------------------------------------------------------------
+
+    private IChannelInfo fChannelInfo1 = null;
+    private IChannelInfo fChannelInfo2 = null;
+
+    // ------------------------------------------------------------------------
+    // Housekeeping
+    // ------------------------------------------------------------------------
+
+    /**
+     * Perform pre-test initialization.
+     */
+    @Before
+    public void setUp() {
+        ModelImplFactory factory = new ModelImplFactory();
+        fChannelInfo1 = factory.getChannel1();
+        fChannelInfo2 = factory.getChannel2();
+    }
+
+    // ------------------------------------------------------------------------
+    // Tests
+    // ------------------------------------------------------------------------
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+
+    /**
+     * Run the ChannelInfo() constructor test.
+     */
+    @Test
+    public void testChannelInfo() {
+        ChannelInfo result = new ChannelInfo("test");
+        assertNotNull(result);
+
+        assertEquals("test", result.getName());
+        assertEquals(0, result.getNumberOfSubBuffers());
+        assertEquals("unknown", result.getOutputType().getInName());
+        assertEquals(TraceChannelOutputType.UNKNOWN, result.getOutputType());
+        assertEquals(false, result.isOverwriteMode());
+        assertEquals(0, result.getReadTimer());
+        assertEquals("disabled", result.getState().getInName());
+        assertEquals(0, result.getSubBufferSize());
+        assertEquals(0, result.getSwitchTimer());
+        assertEquals(0, result.getMaxSizeTraceFiles());
+        assertEquals(0, result.getMaxNumberTraceFiles());
+        assertEquals(BufferType.BUFFER_TYPE_UNKNOWN, result.getBufferType());
+    }
+
+    /**
+     * Test copy constructor.
+     */
+    @Test
+    public void testChannelInfoCopy() {
+        ChannelInfo channelInfo = new ChannelInfo((ChannelInfo)fChannelInfo1);
+
+        assertEquals(fChannelInfo1.getName(), channelInfo.getName());
+        assertEquals(fChannelInfo1.getNumberOfSubBuffers(), channelInfo.getNumberOfSubBuffers());
+        assertEquals(fChannelInfo1.getOutputType(), channelInfo.getOutputType());
+        assertEquals(fChannelInfo1.isOverwriteMode(), channelInfo.isOverwriteMode());
+        assertEquals(fChannelInfo1.getReadTimer(), channelInfo.getReadTimer());
+        assertEquals(fChannelInfo1.getState(), channelInfo.getState());
+        assertEquals(fChannelInfo1.getSwitchTimer(), channelInfo.getSwitchTimer());
+        assertEquals(fChannelInfo1.getEvents().length, channelInfo.getEvents().length);
+        assertEquals(fChannelInfo1.getMaxSizeTraceFiles(), channelInfo.getMaxSizeTraceFiles());
+        assertEquals(fChannelInfo1.getMaxNumberTraceFiles(), channelInfo.getMaxNumberTraceFiles());
+        assertEquals(fChannelInfo1.getBufferType(), channelInfo.getBufferType());
+
+        IEventInfo[] orignalEvents = fChannelInfo1.getEvents();
+        IEventInfo[] resultEvents = channelInfo.getEvents();
+        for (int i = 0; i < orignalEvents.length; i++) {
+            assertEquals(orignalEvents[i], resultEvents[i]);
+        }
+    }
+
+    /**
+     * Test copy constructor with a null value.
+     */
+    @Test
+    public void testChannelCopy2() {
+        try {
+            ChannelInfo channel = null;
+            new ChannelInfo(channel);
+            fail("null copy");
+        }
+        catch (IllegalArgumentException e) {
+            // Success
+        }
+    }
+
+    /**
+     * Run the IEventInfo[] getEvents() method test.
+     */
+    @Test
+    public void testAddAndGetEvents_1() {
+        ChannelInfo fixture = new ChannelInfo("test");
+        fixture.setSwitchTimer(1L);
+        fixture.setOverwriteMode(true);
+        fixture.setReadTimer(1L);
+        fixture.setState(TraceEnablement.DISABLED);
+        fixture.setNumberOfSubBuffers(1);
+        fixture.setOutputType("");
+        fixture.setSubBufferSize(1L);
+
+        // add an event
+        IEventInfo event = new EventInfo("event");
+        fixture.addEvent(event);
+
+        // Verify the stored events
+        IEventInfo[] result = fixture.getEvents();
+
+        assertNotNull(result);
+        assertEquals(1, result.length);
+        assertNotNull(result[0]);
+        assertTrue(event.equals(result[0]));
+    }
+
+    /**
+     * Run the long getNumberOfSubBuffers() method test.
+     */
+    @Test
+    public void testGetAndSetters() {
+        ChannelInfo fixture = new ChannelInfo("test");
+        fixture.setSwitchTimer(2L);
+        fixture.setOverwriteMode(true);
+        fixture.setReadTimer(3L);
+        fixture.setState(TraceEnablement.DISABLED);
+        fixture.setNumberOfSubBuffers(4);
+        fixture.setOutputType("splice()");
+        fixture.setSubBufferSize(1L);
+        fixture.setMaxSizeTraceFiles(1024);
+        fixture.setMaxNumberTraceFiles(20);
+        fixture.setBufferType(BufferType.BUFFER_PER_UID);
+        fixture.addEvent(new EventInfo("event"));
+
+        long switchTimer = fixture.getSwitchTimer();
+        assertEquals(2L, switchTimer);
+
+        boolean mode = fixture.isOverwriteMode();
+        assertTrue(mode);
+
+        long readTimer = fixture.getReadTimer();
+        assertEquals(3L, readTimer);
+
+        TraceEnablement state = fixture.getState();
+        assertEquals("disabled", state.getInName());
+
+        long numSubBuffers = fixture.getNumberOfSubBuffers();
+        assertEquals(4, numSubBuffers);
+
+        String outputType = fixture.getOutputType().getInName();
+        assertEquals("splice()", outputType);
+
+        long subBufferSize = fixture.getSubBufferSize();
+        assertEquals(1L, subBufferSize);
+
+        long maxSizeTraceFiles = fixture.getMaxSizeTraceFiles();
+        assertEquals(1024, maxSizeTraceFiles);
+
+        int maxNumberTraceFiles = fixture.getMaxNumberTraceFiles();
+        assertEquals(20, maxNumberTraceFiles);
+
+        BufferType bufferType = fixture.getBufferType();
+        assertTrue(bufferType == BufferType.BUFFER_PER_UID);
+
+        fixture.setSwitchTimer(5L);
+        fixture.setOverwriteMode(false);
+        fixture.setReadTimer(6L);
+        fixture.setState(TraceEnablement.ENABLED);
+        fixture.setNumberOfSubBuffers(7);
+        fixture.setOutputType("mmap()");
+        fixture.setSubBufferSize(8L);
+        fixture.setMaxSizeTraceFiles(4096);
+        fixture.setMaxNumberTraceFiles(10);
+        fixture.setBufferType(BufferType.BUFFER_PER_PID);
+
+        switchTimer = fixture.getSwitchTimer();
+        assertEquals(5L, switchTimer);
+
+        mode = fixture.isOverwriteMode();
+        assertFalse(mode);
+
+        readTimer = fixture.getReadTimer();
+        assertEquals(6L, readTimer);
+
+        state = fixture.getState();
+        assertEquals("enabled", state.getInName());
+
+        numSubBuffers = fixture.getNumberOfSubBuffers();
+        assertEquals(7, numSubBuffers);
+
+        outputType = fixture.getOutputType().getInName();
+        assertEquals("mmap()", outputType);
+
+        subBufferSize = fixture.getSubBufferSize();
+        assertEquals(8L, subBufferSize);
+
+        maxSizeTraceFiles = fixture.getMaxSizeTraceFiles();
+        assertEquals(4096, maxSizeTraceFiles);
+
+        maxNumberTraceFiles = fixture.getMaxNumberTraceFiles();
+        assertEquals(10, maxNumberTraceFiles);
+
+        bufferType = fixture.getBufferType();
+        assertTrue(bufferType == BufferType.BUFFER_PER_PID);
+    }
+
+    /**
+     * Run the void setEvents(List<IEventInfo>) method test.
+     */
+    @Test
+    public void testSetEvents_1() {
+        ChannelInfo fixture = new ChannelInfo("test");
+        fixture.setSwitchTimer(1L);
+        fixture.setOverwriteMode(true);
+        fixture.setReadTimer(1L);
+        fixture.setState(TraceEnablement.DISABLED);
+        fixture.setNumberOfSubBuffers(1);
+        fixture.setOutputType("");
+        fixture.setSubBufferSize(1L);
+        List<IEventInfo> events = new LinkedList<>();
+
+        for (int i = 0; i < 2; i++) {
+            IEventInfo info = new EventInfo("event" + i);
+            info.setEventType("tracepoint");
+            info.setState((i % 2 == 0 ? "enabled" : "disabled"));
+            events.add(info);
+        }
+
+        fixture.setEvents(events);
+
+        IEventInfo[] infos = fixture.getEvents();
+
+        assertEquals(events.size(), infos.length);
+
+        for (int i = 0; i < infos.length; i++) {
+            assertEquals(events.get(i), infos[i]);
+        }
+    }
+
+    /**
+     * Run the String toString() method test.
+     */
+    @Test
+    public void testToString_1() {
+        ChannelInfo fixture = new ChannelInfo("channel");
+        fixture.setSwitchTimer(1L);
+        fixture.setOverwriteMode(true);
+        fixture.setReadTimer(1L);
+        fixture.setState(TraceEnablement.DISABLED);
+        fixture.setNumberOfSubBuffers(1);
+        fixture.setOutputType("splice()");
+        fixture.setSubBufferSize(1L);
+
+        String result = fixture.toString();
+
+        // add additional test code here
+        assertEquals("[ChannelInfo([TraceInfo(Name=channel)],State=DISABLED,OverwriteMode=true,SubBuffersSize=1,NumberOfSubBuffers=1,SwitchTimer=1,ReadTimer=1,output=splice(),Events=None)]", result);
+    }
+
+    /**
+     * Run another String toString() method test.
+     */
+    @Test
+    public void testToString_2() {
+        String result = fChannelInfo1.toString();
+
+        // add additional test code here
+        assertEquals("[ChannelInfo([TraceInfo(Name=channel1)],State=DISABLED,OverwriteMode=true,SubBuffersSize=13,NumberOfSubBuffers=12,SwitchTimer=10,ReadTimer=11,output=splice(),Events=[EventInfo([BaseEventInfo([TraceInfo(Name=event1)],type=TRACEPOINT,level=TRACE_DEBUG)],State=ENABLED,levelType=LOGLEVEL_ONLY)])]", result);
+    }
+
+    // ------------------------------------------------------------------------
+    // equals
+    // ------------------------------------------------------------------------
+
+    /**
+     * Run the equals() method test.
+     */
+    @Test
+    public void testEqualsReflexivity() {
+        assertTrue("equals", fChannelInfo1.equals(fChannelInfo1));
+        assertTrue("equals", fChannelInfo2.equals(fChannelInfo2));
+
+        assertTrue("equals", !fChannelInfo1.equals(fChannelInfo2));
+        assertTrue("equals", !fChannelInfo2.equals(fChannelInfo1));
+    }
+
+    /**
+     * Run the equals() method test.
+     */
+    @Test
+    public void testEqualsSymmetry() {
+        ChannelInfo event1 = new ChannelInfo((ChannelInfo)fChannelInfo1);
+        ChannelInfo event2 = new ChannelInfo((ChannelInfo)fChannelInfo2);
+
+        assertTrue("equals", event1.equals(fChannelInfo1));
+        assertTrue("equals", fChannelInfo1.equals(event1));
+
+        assertTrue("equals", event2.equals(fChannelInfo2));
+        assertTrue("equals", fChannelInfo2.equals(event2));
+    }
+
+    /**
+     * Run the equals() method test.
+     */
+    @Test
+    public void testEqualsTransivity() {
+        ChannelInfo channel1 = new ChannelInfo((ChannelInfo)fChannelInfo1);
+        ChannelInfo channel2 = new ChannelInfo((ChannelInfo)fChannelInfo1);
+        ChannelInfo channel3 = new ChannelInfo((ChannelInfo)fChannelInfo1);
+
+        assertTrue("equals", channel1.equals(channel2));
+        assertTrue("equals", channel2.equals(channel3));
+        assertTrue("equals", channel1.equals(channel3));
+    }
+
+    /**
+     * Run the equals() method test.
+     */
+    @Test
+    public void testEqualsNull() {
+        assertTrue("equals", !fChannelInfo1.equals(null));
+        assertTrue("equals", !fChannelInfo2.equals(null));
+    }
+
+    // ------------------------------------------------------------------------
+    // hashCode
+    // ------------------------------------------------------------------------
+
+    /**
+     * Run the hashCode() method test.
+     */
+    @Test
+    public void testHashCode() {
+        ChannelInfo channel1 = new ChannelInfo((ChannelInfo)fChannelInfo1);
+        ChannelInfo channel2 = new ChannelInfo((ChannelInfo)fChannelInfo2);
+
+        assertTrue("hashCode", fChannelInfo1.hashCode() == channel1.hashCode());
+        assertTrue("hashCode", fChannelInfo2.hashCode() == channel2.hashCode());
+
+        assertTrue("hashCode", fChannelInfo1.hashCode() != channel2.hashCode());
+        assertTrue("hashCode", fChannelInfo2.hashCode() != channel1.hashCode());
+    }
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/DomainInfoTest.java b/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/DomainInfoTest.java
new file mode 100644 (file)
index 0000000..13ddb54
--- /dev/null
@@ -0,0 +1,225 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Alexandre Montplaisir - Port to JUnit4
+ **********************************************************************/
+
+package org.eclipse.tracecompass.lttng2.control.core.tests.model.impl;
+
+import static org.junit.Assert.*;
+
+import java.util.LinkedList;
+import java.util.List;
+
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IChannelInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IDomainInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.DomainInfo;
+import org.junit.Before;
+import org.junit.Test;
+
+/**
+ * The class <code>ChannelInfoTest</code> contains tests for the class
+ * <code>{@link DomainInfo}</code>.
+ */
+public class DomainInfoTest {
+
+    // ------------------------------------------------------------------------
+    // Test data
+    // ------------------------------------------------------------------------
+
+    private IDomainInfo fDomainInfo1 = null;
+    private IDomainInfo fDomainInfo2 = null;
+    private IChannelInfo fChannelInfo1 = null;
+    private IChannelInfo fChannelInfo2 = null;
+
+    // ------------------------------------------------------------------------
+    // Housekeeping
+    // ------------------------------------------------------------------------
+
+    /**
+     * Perform pre-test initialization.
+     */
+    @Before
+    public void setUp() {
+        // Get test instances from the factory
+        ModelImplFactory factory = new ModelImplFactory();
+        fChannelInfo1 = factory.getChannel1();
+        fChannelInfo2 = factory.getChannel2();
+        fDomainInfo1 =  factory.getDomainInfo1();
+        fDomainInfo2 =  factory.getDomainInfo2();
+    }
+
+    // ------------------------------------------------------------------------
+    // Tests
+    // ------------------------------------------------------------------------
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+
+    /**
+     * Run the ChannelInfo() constructor test.
+     */
+    @Test
+    public void testDomainInfo() {
+        DomainInfo result = new DomainInfo("test");
+        assertNotNull(result);
+
+        assertEquals("test", result.getName());
+        assertEquals(0, result.getChannels().length);
+    }
+
+    /**
+     * Test the copy constructor.
+     */
+    @Test
+    public void testDomainInfoCopy() {
+        DomainInfo channelInfo = new DomainInfo((DomainInfo)fDomainInfo1);
+        IChannelInfo[] orignalEvents = fDomainInfo1.getChannels();
+        IChannelInfo[] resultEvents = channelInfo.getChannels();
+        for (int i = 0; i < orignalEvents.length; i++) {
+            assertEquals(orignalEvents[i], resultEvents[i]);
+        }
+    }
+
+    /**
+     * Test the copy constructor.
+     */
+    @Test
+    public void testDomainlCopy2() {
+        try {
+            DomainInfo domain = null;
+            new DomainInfo(domain);
+            fail("null copy");
+        }
+        catch (IllegalArgumentException e) {
+            // Success
+        }
+    }
+
+    /**
+     * Run the long getNumberOfSubBuffers() method test.
+     */
+    @Test
+    public void testGetAndSetters() {
+
+        // Note that addChannel() has been executed in setUp()
+        // check get method here
+        assertEquals(1, fDomainInfo1.getChannels().length);
+        assertNotNull(fDomainInfo1.getChannels()[0]);
+        assertEquals(fChannelInfo1, fDomainInfo1.getChannels()[0]);
+
+        IDomainInfo domain = new DomainInfo("domain");
+        List<IChannelInfo> list = new LinkedList<>();
+        list.add(fChannelInfo1);
+        list.add(fChannelInfo2);
+        domain.setChannels(list);
+
+        IChannelInfo[] result = domain.getChannels();
+        assertEquals(2, result.length);
+        assertEquals(fChannelInfo1, result[0]);
+        assertEquals(fChannelInfo2, result[1]);
+    }
+
+    /**
+     * Run the String toString() method test.
+     */
+    @Test
+    public void testToString_1() {
+        DomainInfo fixture = new DomainInfo("domain");
+
+        String result = fixture.toString();
+
+        assertEquals("[DomainInfo([TraceInfo(Name=domain)],Channels=None,isKernel=false)]", result);
+    }
+
+    /**
+     * Run the String toString() method test.
+     */
+    @Test
+    public void testToString_2() {
+        String result = fDomainInfo1.toString();
+
+        assertEquals("[DomainInfo([TraceInfo(Name=test1)],Channels=[ChannelInfo([TraceInfo(Name=channel1)],State=DISABLED,OverwriteMode=true,SubBuffersSize=13,NumberOfSubBuffers=12,SwitchTimer=10,ReadTimer=11,output=splice(),Events=[EventInfo([BaseEventInfo([TraceInfo(Name=event1)],type=TRACEPOINT,level=TRACE_DEBUG)],State=ENABLED,levelType=LOGLEVEL_ONLY)])],isKernel=false)]", result);
+    }
+
+    // ------------------------------------------------------------------------
+    // equals
+    // ------------------------------------------------------------------------
+
+    /**
+     * Run the equals() method test.
+     */
+    @Test
+    public void testEqualsReflexivity() {
+        assertTrue("equals", fDomainInfo1.equals(fDomainInfo1));
+        assertTrue("equals", fDomainInfo2.equals(fDomainInfo2));
+
+        assertTrue("equals", !fDomainInfo1.equals(fDomainInfo2));
+        assertTrue("equals", !fDomainInfo2.equals(fDomainInfo1));
+    }
+
+    /**
+     * Run the equals() method test.
+     */
+    @Test
+    public void testEqualsSymmetry() {
+        DomainInfo event1 = new DomainInfo((DomainInfo)fDomainInfo1);
+        DomainInfo event2 = new DomainInfo((DomainInfo)fDomainInfo2);
+
+        assertTrue("equals", event1.equals(fDomainInfo1));
+        assertTrue("equals", fDomainInfo1.equals(event1));
+
+        assertTrue("equals", event2.equals(fDomainInfo2));
+        assertTrue("equals", fDomainInfo2.equals(event2));
+    }
+
+    /**
+     * Run the equals() method test.
+     */
+    @Test
+    public void testEqualsTransivity() {
+        DomainInfo channel1 = new DomainInfo((DomainInfo)fDomainInfo1);
+        DomainInfo channel2 = new DomainInfo((DomainInfo)fDomainInfo1);
+        DomainInfo channel3 = new DomainInfo((DomainInfo)fDomainInfo1);
+
+        assertTrue("equals", channel1.equals(channel2));
+        assertTrue("equals", channel2.equals(channel3));
+        assertTrue("equals", channel1.equals(channel3));
+    }
+
+    /**
+     * Run the equals() method test.
+     */
+    @Test
+    public void testEqualsNull() {
+        assertTrue("equals", !fDomainInfo1.equals(null));
+        assertTrue("equals", !fDomainInfo2.equals(null));
+    }
+
+    // ------------------------------------------------------------------------
+    // hashCode
+    // ------------------------------------------------------------------------
+
+    /**
+     * Run the hashCode() method test.
+     */
+    @Test
+    public void testHashCode() {
+        DomainInfo channel1 = new DomainInfo((DomainInfo)fDomainInfo1);
+        DomainInfo channel2 = new DomainInfo((DomainInfo)fDomainInfo2);
+
+        assertTrue("hashCode", fDomainInfo1.hashCode() == channel1.hashCode());
+        assertTrue("hashCode", fDomainInfo2.hashCode() == channel2.hashCode());
+
+        assertTrue("hashCode", fDomainInfo1.hashCode() != channel2.hashCode());
+        assertTrue("hashCode", fDomainInfo2.hashCode() != channel1.hashCode());
+    }
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/EventInfoTest.java b/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/EventInfoTest.java
new file mode 100644 (file)
index 0000000..4adb740
--- /dev/null
@@ -0,0 +1,366 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Alexandre Montplaisir - Port to JUnit4
+ **********************************************************************/
+
+package org.eclipse.tracecompass.lttng2.control.core.tests.model.impl;
+
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertNotNull;
+import static org.junit.Assert.assertTrue;
+import static org.junit.Assert.fail;
+
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IEventInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.LogLevelType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEnablement;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEventType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.EventInfo;
+import org.junit.Before;
+import org.junit.Test;
+
+/**
+ * The class <code>EventInfoTest</code> contains test for the class
+ * <code>{@link EventInfo}</code>.
+ */
+public class EventInfoTest {
+
+    // ------------------------------------------------------------------------
+    // Test data
+    // ------------------------------------------------------------------------
+
+    private IEventInfo fEventInfo1 = null;
+    private IEventInfo fEventInfo2 = null;
+
+    // ------------------------------------------------------------------------
+    // Housekeeping
+    // ------------------------------------------------------------------------
+
+    /**
+     * Perform pre-test initialization.
+     */
+    @Before
+    public void setUp() {
+        ModelImplFactory factory = new ModelImplFactory();
+        fEventInfo1 = factory.getEventInfo1();
+        fEventInfo2 = factory.getEventInfo2();
+    }
+
+    // ------------------------------------------------------------------------
+    // Tests
+    // ------------------------------------------------------------------------
+
+    /**
+     * Run the EventInfo() constructor test.
+     */
+    @Test
+    public void testBaseEventInfo() {
+        EventInfo fixture = new EventInfo("event");
+        assertNotNull(fixture);
+
+        TraceEventType result = fixture.getEventType();
+
+        assertEquals("event", fixture.getName());
+        assertEquals("unknown", result.getInName());
+        assertEquals("UNKNOWN", result.name());
+        assertEquals("UNKNOWN", result.toString());
+        assertEquals(4, result.ordinal());
+
+        TraceEnablement state = fixture.getState();
+        assertEquals("disabled", state.getInName());
+        assertEquals("DISABLED", state.name());
+        assertEquals("DISABLED", state.toString());
+        assertEquals(0, state.ordinal());
+
+        LogLevelType logType = fixture.getLogLevelType();
+        assertEquals("", logType.getShortName());
+        assertEquals("LOGLEVEL_NONE", logType.name());
+        assertEquals("LOGLEVEL_NONE", logType.toString());
+        assertEquals(0, state.ordinal());
+
+
+    }
+
+    /**
+     * Test Copy Constructor
+     */
+    @Test
+    public void testEventInfoCopy() {
+        EventInfo info = new EventInfo((EventInfo)fEventInfo1);
+
+        assertEquals(fEventInfo1.getName(), info.getName());
+        assertEquals(fEventInfo1.getEventType(), info.getEventType());
+        assertEquals(fEventInfo1.getState(), info.getState());
+        assertEquals(fEventInfo1.getLogLevelType(), info.getLogLevelType());
+    }
+
+    /**
+     * Test Copy Constructor
+     */
+    @Test
+    public void testEventCopy2() {
+        try {
+            EventInfo info = null;
+            new EventInfo(info);
+            fail("null copy");
+        }
+        catch (IllegalArgumentException e) {
+            // Success
+        }
+    }
+
+    /**
+     *  Getter/Setter tests
+     */
+    @Test
+    public void testGetAndSetter() {
+        EventInfo fixture = new EventInfo("event");
+
+        fixture.setEventType(TraceEventType.TRACEPOINT);
+        TraceEventType result = fixture.getEventType();
+
+        // setEventType(TraceEventType type)
+        assertNotNull(result);
+        assertEquals("tracepoint", result.getInName());
+        assertEquals("TRACEPOINT", result.name());
+        assertEquals("TRACEPOINT", result.toString());
+        assertEquals(0, result.ordinal());
+
+        fixture.setEventType(TraceEventType.UNKNOWN);
+        result = fixture.getEventType();
+        assertEquals("unknown", result.getInName());
+        assertEquals("UNKNOWN", result.name());
+        assertEquals("UNKNOWN", result.toString());
+        assertEquals(4, result.ordinal());
+
+        // setEventType(String typeName)
+        String typeName = "";
+        fixture.setEventType(typeName);
+        result = fixture.getEventType();
+
+        assertEquals("unknown", result.getInName());
+        assertEquals("UNKNOWN", result.name());
+        assertEquals("UNKNOWN", result.toString());
+        assertEquals(4, result.ordinal());
+
+        typeName = "unknown";
+
+        fixture.setEventType(typeName);
+        result = fixture.getEventType();
+
+        assertEquals("unknown", result.getInName());
+        assertEquals("UNKNOWN", result.name());
+        assertEquals("UNKNOWN", result.toString());
+        assertEquals(4, result.ordinal());
+
+        // setState(String stateName)
+        fixture.setState("disabled");
+        TraceEnablement state = fixture.getState();
+        assertEquals("disabled", state.getInName());
+        assertEquals("DISABLED", state.name());
+        assertEquals("DISABLED", state.toString());
+        assertEquals(0, state.ordinal());
+
+        fixture.setState("false");
+        state = fixture.getState();
+        assertEquals("false", state.getInMiName());
+        assertEquals("DISABLED", state.name());
+        assertEquals("DISABLED", state.toString());
+        assertEquals(0, state.ordinal());
+
+        fixture.setState("bla");
+        state = fixture.getState();
+        assertEquals("disabled", state.getInName());
+        assertEquals("DISABLED", state.name());
+        assertEquals("DISABLED", state.toString());
+        assertEquals(0, state.ordinal());
+
+        fixture.setState("enabled");
+        state = fixture.getState();
+        assertEquals("enabled", state.getInName());
+        assertEquals("ENABLED", state.name());
+        assertEquals("ENABLED", state.toString());
+        assertEquals(1, state.ordinal());
+
+        fixture.setState("true");
+        state = fixture.getState();
+        assertEquals("true", state.getInMiName());
+        assertEquals("ENABLED", state.name());
+        assertEquals("ENABLED", state.toString());
+        assertEquals(1, state.ordinal());
+
+        // setState(TraceEnablement state)
+        fixture.setState(TraceEnablement.DISABLED);
+        state = fixture.getState();
+        assertEquals("disabled", state.getInName());
+        assertEquals("DISABLED", state.name());
+        assertEquals("DISABLED", state.toString());
+        assertEquals(0, state.ordinal());
+
+        fixture.setState(TraceEnablement.ENABLED);
+        state = fixture.getState();
+        assertEquals("enabled", state.getInName());
+        assertEquals("ENABLED", state.name());
+        assertEquals("ENABLED", state.toString());
+        assertEquals(1, state.ordinal());
+
+        // setLogLevelType(String name)
+        fixture.setLogLevelType("==");
+        assertEquals("LOGLEVEL_ONLY", fixture.getLogLevelType().name());
+        assertEquals("==", fixture.getLogLevelType().getShortName());
+
+        fixture.setLogLevelType("<=");
+        assertEquals("LOGLEVEL", fixture.getLogLevelType().name());
+        assertEquals("<=", fixture.getLogLevelType().getShortName());
+
+        fixture.setLogLevelType("");
+        assertEquals("LOGLEVEL_ALL", fixture.getLogLevelType().name());
+        assertEquals("", fixture.getLogLevelType().getShortName());
+
+        fixture.setLogLevelType(LogLevelType.LOGLEVEL_ONLY);
+        assertEquals("LOGLEVEL_ONLY", fixture.getLogLevelType().name());
+        assertEquals("==", fixture.getLogLevelType().getShortName());
+
+        fixture.setLogLevelType(LogLevelType.LOGLEVEL);
+        assertEquals("LOGLEVEL", fixture.getLogLevelType().name());
+        assertEquals("<=", fixture.getLogLevelType().getShortName());
+
+        fixture.setLogLevelType(LogLevelType.LOGLEVEL_ALL);
+        assertEquals("LOGLEVEL_ALL", fixture.getLogLevelType().name());
+        assertEquals("", fixture.getLogLevelType().getShortName());
+
+        fixture.setLogLevelType(LogLevelType.LOGLEVEL_NONE);
+        assertEquals("LOGLEVEL_NONE", fixture.getLogLevelType().name());
+        assertEquals("", fixture.getLogLevelType().getShortName());
+
+        // setLogLevelType(String name)
+        // machine interface
+        fixture.setLogLevelType("SINGLE");
+        assertEquals("LOGLEVEL_ONLY", fixture.getLogLevelType().name());
+        assertEquals("SINGLE", fixture.getLogLevelType().getMiName());
+
+        fixture.setLogLevelType("RANGE");
+        assertEquals("LOGLEVEL", fixture.getLogLevelType().name());
+        assertEquals("RANGE", fixture.getLogLevelType().getMiName());
+
+        fixture.setLogLevelType("ALL");
+        assertEquals("LOGLEVEL_ALL", fixture.getLogLevelType().name());
+        assertEquals("ALL", fixture.getLogLevelType().getMiName());
+
+        fixture.setLogLevelType("UNKNOWN");
+        assertEquals("LOGLEVEL_NONE", fixture.getLogLevelType().name());
+        assertEquals("UNKNOWN", fixture.getLogLevelType().getMiName());
+
+    }
+
+    /**
+     * Run the String toString() method test.
+     */
+    @Test
+    public void testToString_1() {
+        EventInfo fixture = new EventInfo("event");
+        fixture.setName("testName");
+        fixture.setEventType(TraceEventType.TRACEPOINT);
+
+        String result = fixture.toString();
+
+        // add additional test code here
+        assertEquals("[EventInfo([BaseEventInfo([TraceInfo(Name=testName)],type=TRACEPOINT,level=TRACE_DEBUG)],State=DISABLED,levelType=LOGLEVEL_NONE)]", result);
+    }
+
+    /**
+     * Run the String toString() method test.
+     */
+    @Test
+    public void testToString_2() {
+        EventInfo fixture = new EventInfo("event");
+        fixture.setName("testName");
+        fixture.setEventType(TraceEventType.TRACEPOINT);
+        fixture.setLogLevelType(LogLevelType.LOGLEVEL_ONLY);
+
+        String result = fixture.toString();
+
+        // add additional test code here
+        assertEquals("[EventInfo([BaseEventInfo([TraceInfo(Name=testName)],type=TRACEPOINT,level=TRACE_DEBUG)],State=DISABLED,levelType=LOGLEVEL_ONLY)]", result);
+    }
+
+    // ------------------------------------------------------------------------
+    // equals
+    // ------------------------------------------------------------------------
+
+    /**
+     * Run the equals() method test.
+     */
+    @Test
+    public void testEqualsReflexivity() {
+        assertTrue("equals", fEventInfo1.equals(fEventInfo1));
+        assertTrue("equals", fEventInfo2.equals(fEventInfo2));
+
+        assertTrue("equals", !fEventInfo1.equals(fEventInfo2));
+        assertTrue("equals", !fEventInfo2.equals(fEventInfo1));
+    }
+
+    /**
+     * Run the equals() method test.
+     */
+    @Test
+    public void testEqualsSymmetry() {
+        EventInfo info1 = new EventInfo((EventInfo)fEventInfo1);
+        EventInfo info2 = new EventInfo((EventInfo)fEventInfo2);
+
+        assertTrue("equals", info1.equals(fEventInfo1));
+        assertTrue("equals", fEventInfo1.equals(info1));
+
+        assertTrue("equals", info2.equals(fEventInfo2));
+        assertTrue("equals", fEventInfo2.equals(info2));
+    }
+
+    /**
+     * Run the equals() method test.
+     */
+    @Test
+    public void testEqualsTransivity() {
+        EventInfo info1 = new EventInfo((EventInfo)fEventInfo1);
+        EventInfo info2 = new EventInfo((EventInfo)fEventInfo1);
+        EventInfo info3 = new EventInfo((EventInfo)fEventInfo1);
+
+        assertTrue("equals", info1.equals(info2));
+        assertTrue("equals", info2.equals(info3));
+        assertTrue("equals", info1.equals(info3));
+    }
+
+    /**
+     * Run the equals() method test.
+     */
+    @Test
+    public void testEqualsNull() {
+        assertTrue("equals", !fEventInfo1.equals(null));
+        assertTrue("equals", !fEventInfo2.equals(null));
+    }
+
+    // ------------------------------------------------------------------------
+    // hashCode
+    // ------------------------------------------------------------------------
+
+    /**
+     * Run the hashCode() method test.
+     */
+    @Test
+    public void testHashCode() {
+        EventInfo info1 = new EventInfo((EventInfo)fEventInfo1);
+        EventInfo info2 = new EventInfo((EventInfo)fEventInfo2);
+
+        assertTrue("hashCode", fEventInfo1.hashCode() == info1.hashCode());
+        assertTrue("hashCode", fEventInfo2.hashCode() == info2.hashCode());
+
+        assertTrue("hashCode", fEventInfo1.hashCode() != info2.hashCode());
+        assertTrue("hashCode", fEventInfo2.hashCode() != info1.hashCode());
+    }
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/FieldInfoTest.java b/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/FieldInfoTest.java
new file mode 100644 (file)
index 0000000..22f37ec
--- /dev/null
@@ -0,0 +1,186 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Alexandre Montplaisir - Port to JUnit4
+ **********************************************************************/
+
+package org.eclipse.tracecompass.lttng2.control.core.tests.model.impl;
+
+import static org.junit.Assert.*;
+
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IFieldInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.FieldInfo;
+import org.junit.Before;
+import org.junit.Test;
+
+/**
+ * The class <code>FieldInfoTest</code> contains test for the class
+ * <code>{@link FieldInfo}</code>.
+ */
+public class FieldInfoTest {
+
+    // ------------------------------------------------------------------------
+    // Test data
+    // ------------------------------------------------------------------------
+
+    private IFieldInfo fFieldInfo1 = null;
+    private IFieldInfo fFieldInfo2 = null;
+
+    // ------------------------------------------------------------------------
+    // Housekeeping
+    // ------------------------------------------------------------------------
+
+    /**
+     * Perform pre-test initialization.
+     */
+    @Before
+    public void setUp() {
+        ModelImplFactory factory = new ModelImplFactory();
+        fFieldInfo1 = factory.getFieldInfo1();
+        fFieldInfo2 = factory.getFieldInfo2();
+    }
+
+    // ------------------------------------------------------------------------
+    // Tests
+    // ------------------------------------------------------------------------
+
+    /**
+     * Run the BaseEventInfo() constructor test.
+     */
+    @Test
+    public void testFiledInfo() {
+        FieldInfo fixture = new FieldInfo("field");
+        assertNotNull(fixture);
+
+        assertEquals("field", fixture.getName());
+        assertNull(fixture.getFieldType());
+    }
+
+    /**
+     * Test Copy Constructor
+     */
+    @Test
+    public void testEventInfoCopy() {
+        FieldInfo info = new FieldInfo((FieldInfo)fFieldInfo1);
+
+        assertEquals(fFieldInfo1.getName(), info.getName());
+        assertEquals(fFieldInfo1.getFieldType(), info.getFieldType());
+    }
+
+    /**
+     * Test Copy Constructor
+     */
+    @Test
+    public void testEventCopy2() {
+        try {
+            FieldInfo info = null;
+            new FieldInfo(info);
+            fail("null copy");
+        }
+        catch (IllegalArgumentException e) {
+            // Success
+        }
+    }
+
+    /**
+     * Run the TraceEventType getEventType() method test.
+     */
+    @Test
+    public void testSetFieldType() {
+        FieldInfo info = new FieldInfo((FieldInfo)fFieldInfo1);
+
+        info.setFieldType("string");
+        assertEquals("string", info.getFieldType());
+    }
+
+    /**
+     * Run the toString() method test.
+     */
+    @Test
+    public void testToString() {
+        String result = fFieldInfo1.toString();
+
+        // add additional test code here
+        assertEquals("[FieldInfo([TraceInfo(Name=intfield)],type=int", result);
+    }
+
+    // ------------------------------------------------------------------------
+    // equals
+    // ------------------------------------------------------------------------
+
+    /**
+     * Run the equals() method test.
+     */
+    @Test
+    public void testEqualsReflexivity() {
+        assertTrue("equals", fFieldInfo1.equals(fFieldInfo1));
+        assertTrue("equals", fFieldInfo2.equals(fFieldInfo2));
+
+        assertTrue("equals", !fFieldInfo1.equals(fFieldInfo2));
+        assertTrue("equals", !fFieldInfo2.equals(fFieldInfo1));
+    }
+
+    /**
+     * Run the equals() method test.
+     */
+    @Test
+    public void testEqualsSymmetry() {
+        FieldInfo info1 = new FieldInfo((FieldInfo)fFieldInfo1);
+        FieldInfo info2 = new FieldInfo((FieldInfo)fFieldInfo2);
+
+        assertTrue("equals", info1.equals(fFieldInfo1));
+        assertTrue("equals", fFieldInfo1.equals(info1));
+
+        assertTrue("equals", info2.equals(fFieldInfo2));
+        assertTrue("equals", fFieldInfo2.equals(info2));
+    }
+
+    /**
+     * Run the equals() method test.
+     */
+    @Test
+    public void testEqualsTransivity() {
+        FieldInfo info1 = new FieldInfo((FieldInfo)fFieldInfo1);
+        FieldInfo info2 = new FieldInfo((FieldInfo)fFieldInfo1);
+        FieldInfo info3 = new FieldInfo((FieldInfo)fFieldInfo1);
+
+        assertTrue("equals", info1.equals(info2));
+        assertTrue("equals", info2.equals(info3));
+        assertTrue("equals", info1.equals(info3));
+    }
+
+    /**
+     * Run the equals() method test.
+     */
+    @Test
+    public void testEqualsNull() {
+        assertTrue("equals", !fFieldInfo1.equals(null));
+        assertTrue("equals", !fFieldInfo2.equals(null));
+    }
+
+    // ------------------------------------------------------------------------
+    // hashCode
+    // ------------------------------------------------------------------------
+
+    /**
+     * Run the equals() method test.
+     */
+    @Test
+    public void testHashCode() {
+        FieldInfo info1 = new FieldInfo((FieldInfo)fFieldInfo1);
+        FieldInfo info2 = new FieldInfo((FieldInfo)fFieldInfo2);
+
+        assertTrue("hashCode", fFieldInfo1.hashCode() == info1.hashCode());
+        assertTrue("hashCode", fFieldInfo2.hashCode() == info2.hashCode());
+
+        assertTrue("hashCode", fFieldInfo1.hashCode() != info2.hashCode());
+        assertTrue("hashCode", fFieldInfo2.hashCode() != info1.hashCode());
+    }
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/ModelImplFactory.java b/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/ModelImplFactory.java
new file mode 100644 (file)
index 0000000..1177772
--- /dev/null
@@ -0,0 +1,244 @@
+/*******************************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.control.core.tests.model.impl;
+
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IBaseEventInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IChannelInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IDomainInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IEventInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IFieldInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IProbeEventInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISessionInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISnapshotInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IUstProviderInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEnablement;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEventType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.BaseEventInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.ChannelInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.DomainInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.EventInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.FieldInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.ProbeEventInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.SessionInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.SnapshotInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.UstProviderInfo;
+
+/**
+ *  Test facility to constants across test case
+ */
+@SuppressWarnings("javadoc")
+public class ModelImplFactory {
+
+    private ISessionInfo fSessionInfo1 = null;
+    private ISessionInfo fSessionInfo2 = null;
+    private IDomainInfo fDomainInfo1 = null;
+    private IDomainInfo fDomainInfo2 = null;
+    private IChannelInfo fChannelInfo1 = null;
+    private IChannelInfo fChannelInfo2 = null;
+    private IEventInfo fEventInfo1 = null;
+    private IEventInfo fEventInfo2 = null;
+    private IEventInfo fEventInfo3 = null;
+    private IFieldInfo fFieldInfo1 = null;
+    private IFieldInfo fFieldInfo2 = null;
+    private IBaseEventInfo fBaseEventInfo1 = null;
+    private IBaseEventInfo fBaseEventInfo2 = null;
+    private IUstProviderInfo fUstProviderInfo1 = null;
+    private IUstProviderInfo fUstProviderInfo2 = null;
+    private IProbeEventInfo fProbeEventInfo1 = null;
+    private IProbeEventInfo fProbeEventInfo2 = null;
+    private ISnapshotInfo fSnapshotInfo1 = null;
+    private ISnapshotInfo fSnapshotInfo2 = null;
+
+    public ModelImplFactory() {
+
+        fFieldInfo1 = new FieldInfo("intfield");
+        fFieldInfo1.setFieldType("int");
+        fFieldInfo2 = new FieldInfo("stringfield");
+        fFieldInfo2.setFieldType("string");
+
+        fBaseEventInfo1 = new BaseEventInfo("event1");
+        fBaseEventInfo1.setEventType(TraceEventType.UNKNOWN);
+        fBaseEventInfo1.setLogLevel(TraceLogLevel.TRACE_ERR);
+        fBaseEventInfo1.addField(fFieldInfo1);
+        fBaseEventInfo1.addField(fFieldInfo2);
+        fBaseEventInfo1.setFilterExpression("intField==10");
+
+        fBaseEventInfo2 = new BaseEventInfo("event2");
+        fBaseEventInfo2.setEventType(TraceEventType.TRACEPOINT);
+        fBaseEventInfo1.setLogLevel(TraceLogLevel.TRACE_DEBUG);
+
+        fEventInfo1 = new EventInfo("event1");
+        fEventInfo1.setEventType(TraceEventType.TRACEPOINT);
+        fEventInfo1.setLogLevelType("==");
+        fEventInfo1.setLogLevel(TraceLogLevel.TRACE_DEBUG);
+        fEventInfo1.setState(TraceEnablement.ENABLED);
+
+        fEventInfo2 = new EventInfo("event2");
+        fEventInfo2.setLogLevelType("<=");
+        fEventInfo2.setLogLevel(TraceLogLevel.TRACE_INFO);
+        fEventInfo2.setEventType(TraceEventType.UNKNOWN);
+        fEventInfo2.setState(TraceEnablement.DISABLED);
+
+        fEventInfo3 = new EventInfo("event3");
+        fEventInfo3.setEventType(TraceEventType.TRACEPOINT);
+        fEventInfo3.setState(TraceEnablement.DISABLED);
+
+        fUstProviderInfo1 = new UstProviderInfo("myUST1");
+        fUstProviderInfo1.setPid(1234);
+        fUstProviderInfo1.addEvent(fBaseEventInfo1);
+
+        fUstProviderInfo2 = new UstProviderInfo("myUST2");
+        fUstProviderInfo2.setPid(2345);
+        fUstProviderInfo2.addEvent(fBaseEventInfo1);
+        fUstProviderInfo2.addEvent(fBaseEventInfo2);
+
+        fChannelInfo1 = new ChannelInfo("channel1");
+        fChannelInfo1.setSwitchTimer(10L);
+        fChannelInfo1.setOverwriteMode(true);
+        fChannelInfo1.setReadTimer(11L);
+        fChannelInfo1.setState(TraceEnablement.DISABLED);
+        fChannelInfo1.setNumberOfSubBuffers(12);
+        fChannelInfo1.setOutputType("splice()");
+        fChannelInfo1.setSubBufferSize(13L);
+        fChannelInfo1.addEvent(fEventInfo1);
+
+        fChannelInfo2 = new ChannelInfo("channel2");
+        fChannelInfo2.setSwitchTimer(1L);
+        fChannelInfo2.setOverwriteMode(false);
+        fChannelInfo2.setReadTimer(2L);
+        fChannelInfo2.setState(TraceEnablement.ENABLED);
+        fChannelInfo2.setNumberOfSubBuffers(3);
+        fChannelInfo2.setOutputType("mmap()");
+        fChannelInfo2.setSubBufferSize(4L);
+        fChannelInfo2.addEvent(fEventInfo2);
+        fChannelInfo2.addEvent(fEventInfo3);
+
+        fDomainInfo1 = new DomainInfo("test1");
+        fDomainInfo1.addChannel(fChannelInfo1);
+
+        fDomainInfo2 = new DomainInfo("test2");
+        fDomainInfo2.addChannel(fChannelInfo1);
+        fDomainInfo2.addChannel(fChannelInfo2);
+
+        fSessionInfo1 = new SessionInfo("session1");
+        fSessionInfo1.setSessionPath("/home/user");
+        fSessionInfo1.setSessionState(TraceSessionState.ACTIVE);
+        fSessionInfo1.addDomain(fDomainInfo1);
+
+        fSessionInfo2 = new SessionInfo("session2");
+        fSessionInfo2.setSessionPath("/home/user1");
+        fSessionInfo2.setSessionState(TraceSessionState.INACTIVE);
+        fSessionInfo2.addDomain(fDomainInfo1);
+        fSessionInfo2.addDomain(fDomainInfo2);
+        fSessionInfo2.setStreamedTrace(true);
+
+        fProbeEventInfo1 = new ProbeEventInfo("probeEvent1");
+        fProbeEventInfo1.setEventType(TraceEventType.TRACEPOINT);
+        fProbeEventInfo1.setState(TraceEnablement.ENABLED);
+        fProbeEventInfo1.setAddress("0xc1231234");
+
+        fProbeEventInfo2 = new ProbeEventInfo("probeEvent2");
+        fProbeEventInfo2.setEventType(TraceEventType.FUNCTION);
+        fProbeEventInfo2.setState(TraceEnablement.DISABLED);
+        fProbeEventInfo2.setOffset("0x100");
+        fProbeEventInfo2.setSymbol("init_post");
+
+        fSnapshotInfo1 = new SnapshotInfo("snapshot-1");
+        fSnapshotInfo1.setId(1);
+        fSnapshotInfo1.setSnapshotPath("/home/user/lttng-trace/mysession/");
+        fSnapshotInfo2 = new SnapshotInfo("other-snapshot");
+        fSnapshotInfo2.setId(1);
+        fSnapshotInfo2.setSnapshotPath("net4://172.0.0.1:1234/");
+        fSnapshotInfo2.setStreamedSnapshot(true);
+
+        fSessionInfo1.setSnapshotInfo(fSnapshotInfo1);
+    }
+
+    public ISessionInfo getSessionInfo1() {
+        return fSessionInfo1;
+    }
+
+    public ISessionInfo getSessionInfo2() {
+        return fSessionInfo2;
+    }
+
+    public IDomainInfo getDomainInfo1() {
+        return fDomainInfo1;
+    }
+
+    public IDomainInfo getDomainInfo2() {
+        return fDomainInfo2;
+    }
+
+    public IChannelInfo getChannel1() {
+        return fChannelInfo1;
+    }
+
+    public IChannelInfo getChannel2() {
+        return fChannelInfo2;
+    }
+
+    public IEventInfo getEventInfo1() {
+        return fEventInfo1;
+    }
+
+    public IEventInfo getEventInfo2() {
+        return fEventInfo2;
+    }
+
+    public IEventInfo getEventInfo3() {
+        return fEventInfo3;
+    }
+
+    public IBaseEventInfo getBaseEventInfo1() {
+        return fBaseEventInfo1;
+    }
+
+    public IBaseEventInfo getBaseEventInfo2() {
+        return fBaseEventInfo2;
+    }
+
+    public IUstProviderInfo getUstProviderInfo1() {
+        return fUstProviderInfo1;
+    }
+
+    public IUstProviderInfo getUstProviderInfo2() {
+        return fUstProviderInfo2;
+    }
+
+    public IProbeEventInfo getProbeEventInfo1() {
+        return fProbeEventInfo1;
+    }
+
+    public IProbeEventInfo getProbeEventInfo2() {
+        return fProbeEventInfo2;
+    }
+
+    public IFieldInfo getFieldInfo1() {
+        return fFieldInfo1;
+    }
+
+    public IFieldInfo getFieldInfo2() {
+        return fFieldInfo2;
+    }
+
+    public ISnapshotInfo getSnapshotInfo1() {
+        return fSnapshotInfo1;
+    }
+
+    public ISnapshotInfo getSnapshotInfo2() {
+        return fSnapshotInfo2;
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/ProbeEventInfoTest.java b/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/ProbeEventInfoTest.java
new file mode 100644 (file)
index 0000000..caa8d51
--- /dev/null
@@ -0,0 +1,219 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Alexandre Montplaisir - Port to JUnit4
+ **********************************************************************/
+
+package org.eclipse.tracecompass.lttng2.control.core.tests.model.impl;
+
+import static org.junit.Assert.*;
+
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IProbeEventInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEnablement;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEventType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.ProbeEventInfo;
+import org.junit.Before;
+import org.junit.Test;
+
+/**
+ * The class <code>ProbEventInfoTest</code> contains test for the class
+ * <code>{@link ProbeEventInfo}</code>.
+ */
+public class ProbeEventInfoTest {
+
+    // ------------------------------------------------------------------------
+    // Test data
+    // ------------------------------------------------------------------------
+
+    private IProbeEventInfo fEventInfo1 = null;
+    private IProbeEventInfo fEventInfo2 = null;
+
+    // ------------------------------------------------------------------------
+    // Housekeeping
+    // ------------------------------------------------------------------------
+    /**
+     * Perform pre-test initialization.
+     */
+    @Before
+    public void setUp() {
+        ModelImplFactory factory = new ModelImplFactory();
+        fEventInfo1 = factory.getProbeEventInfo1();
+        fEventInfo2 = factory.getProbeEventInfo2();
+    }
+
+    // ------------------------------------------------------------------------
+    // Tests
+    // ------------------------------------------------------------------------
+
+    /**
+     * Run the BaseEventInfo() constructor test.
+     */
+    @Test
+    public void testBaseEventInfo() {
+        ProbeEventInfo fixture = new ProbeEventInfo("event");
+        assertNotNull(fixture);
+
+        TraceEventType result = fixture.getEventType();
+
+        assertEquals("event", fixture.getName());
+        assertEquals("unknown", result.getInName());
+        assertEquals("UNKNOWN", result.name());
+        assertEquals("UNKNOWN", result.toString());
+        assertEquals(4, result.ordinal());
+
+        TraceEnablement state = fixture.getState();
+        assertEquals("disabled", state.getInName());
+        assertEquals("DISABLED", state.name());
+        assertEquals("DISABLED", state.toString());
+        assertEquals(0, state.ordinal());
+
+        assertNull(fixture.getAddress());
+        assertNull(fixture.getOffset());
+        assertNull(fixture.getSymbol());
+    }
+
+    /**
+     * Test Copy Constructor
+     */
+    @Test
+    public void testEventInfoCopy() {
+        ProbeEventInfo info = new ProbeEventInfo((ProbeEventInfo)fEventInfo1);
+
+        assertEquals(fEventInfo1.getName(), info.getName());
+        assertEquals(fEventInfo1.getEventType(), info.getEventType());
+        assertEquals(fEventInfo1.getState(), info.getState());
+        assertEquals(fEventInfo1.getAddress(), info.getAddress());
+        assertEquals(fEventInfo1.getOffset(), info.getOffset());
+        assertEquals(fEventInfo1.getSymbol(), info.getSymbol());
+    }
+
+    /**
+     * Test Copy Constructor
+     */
+    @Test
+    public void testEventCopy2() {
+        try {
+            ProbeEventInfo info = null;
+            new ProbeEventInfo(info);
+            fail("null copy");
+        }
+        catch (IllegalArgumentException e) {
+            // Success
+        }
+    }
+
+    /**
+     *  Getter/Setter tests
+     */
+    @Test
+    public void testGetAndSetter() {
+        ProbeEventInfo fixture = new ProbeEventInfo("event");
+
+        fixture.setAddress("0xc12344321");
+        String result = fixture.getAddress();
+
+        assertNotNull(result);
+        assertEquals("0xc12344321", result);
+
+        fixture.setOffset("0x1000");
+        result = fixture.getOffset();
+
+        assertNotNull(result);
+        assertEquals("0x1000", result);
+
+        fixture.setSymbol("cpu_idle");
+        result = fixture.getSymbol();
+
+        assertNotNull(result);
+        assertEquals("cpu_idle", result);
+    }
+
+    /**
+     * Run the String toString() method test.
+     */
+    @Test
+    public void testToString_1() {
+        assertEquals("[ProbeEventInfo([EventInfo([BaseEventInfo([TraceInfo(Name=probeEvent1)],type=TRACEPOINT,level=TRACE_DEBUG)],State=ENABLED,levelType=LOGLEVEL_NONE)],fAddress=0xc1231234)]", fEventInfo1.toString());
+        assertEquals("[ProbeEventInfo([EventInfo([BaseEventInfo([TraceInfo(Name=probeEvent2)],type=FUNCTION,level=TRACE_DEBUG)],State=DISABLED,levelType=LOGLEVEL_NONE)],fOffset=0x100,fSymbol=init_post)]", fEventInfo2.toString());
+    }
+
+    // ------------------------------------------------------------------------
+    // equals
+    // ------------------------------------------------------------------------
+
+    /**
+     * Run the equals() method test.
+     */
+    @Test
+    public void testEqualsReflexivity() {
+        assertTrue("equals", fEventInfo1.equals(fEventInfo1));
+        assertTrue("equals", fEventInfo2.equals(fEventInfo2));
+
+        assertTrue("equals", !fEventInfo1.equals(fEventInfo2));
+        assertTrue("equals", !fEventInfo2.equals(fEventInfo1));
+    }
+
+    /**
+     * Run the equals() method test.
+     */
+    @Test
+    public void testEqualsSymmetry() {
+        ProbeEventInfo info1 = new ProbeEventInfo((ProbeEventInfo)fEventInfo1);
+        ProbeEventInfo info2 = new ProbeEventInfo((ProbeEventInfo)fEventInfo2);
+
+        assertTrue("equals", info1.equals(fEventInfo1));
+        assertTrue("equals", fEventInfo1.equals(info1));
+
+        assertTrue("equals", info2.equals(fEventInfo2));
+        assertTrue("equals", fEventInfo2.equals(info2));
+    }
+
+    /**
+     * Run the equals() method test.
+     */
+    @Test
+    public void testEqualsTransivity() {
+        ProbeEventInfo info1 = new ProbeEventInfo((ProbeEventInfo)fEventInfo1);
+        ProbeEventInfo info2 = new ProbeEventInfo((ProbeEventInfo)fEventInfo1);
+        ProbeEventInfo info3 = new ProbeEventInfo((ProbeEventInfo)fEventInfo1);
+
+        assertTrue("equals", info1.equals(info2));
+        assertTrue("equals", info2.equals(info3));
+        assertTrue("equals", info1.equals(info3));
+    }
+
+    /**
+     * Run the equals() method test.
+     */
+    @Test
+    public void testEqualsNull() {
+        assertTrue("equals", !fEventInfo1.equals(null));
+        assertTrue("equals", !fEventInfo2.equals(null));
+    }
+
+    // ------------------------------------------------------------------------
+    // hashCode
+    // ------------------------------------------------------------------------
+
+    /**
+     * Run the hashCode() method test.
+     */
+    @Test
+    public void testHashCode() {
+        ProbeEventInfo info1 = new ProbeEventInfo((ProbeEventInfo)fEventInfo1);
+        ProbeEventInfo info2 = new ProbeEventInfo((ProbeEventInfo)fEventInfo2);
+
+        assertTrue("hashCode", fEventInfo1.hashCode() == info1.hashCode());
+        assertTrue("hashCode", fEventInfo2.hashCode() == info2.hashCode());
+
+        assertTrue("hashCode", fEventInfo1.hashCode() != info2.hashCode());
+        assertTrue("hashCode", fEventInfo2.hashCode() != info1.hashCode());
+    }
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/SessionInfoTest.java b/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/SessionInfoTest.java
new file mode 100644 (file)
index 0000000..3d50aa5
--- /dev/null
@@ -0,0 +1,311 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Alexandre Montplaisir - Port to JUnit4
+ **********************************************************************/
+
+package org.eclipse.tracecompass.lttng2.control.core.tests.model.impl;
+
+import static org.junit.Assert.*;
+
+import java.util.LinkedList;
+import java.util.List;
+
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IDomainInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISessionInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.SessionInfo;
+import org.junit.Before;
+import org.junit.Test;
+
+/**
+ * The class <code>ChannelInfoTest</code> contains tests for the class
+ * <code>{@link SessionInfo}</code>.
+ */
+public class SessionInfoTest {
+
+    // ------------------------------------------------------------------------
+    // Test data
+    // ------------------------------------------------------------------------
+
+    private ISessionInfo fSessionInfo1 = null;
+    private ISessionInfo fSessionInfo2 = null;
+
+    private IDomainInfo fDomainInfo1 = null;
+    private IDomainInfo fDomainInfo2 = null;
+
+    // ------------------------------------------------------------------------
+    // Housekeeping
+    // ------------------------------------------------------------------------
+
+    /**
+     * Perform pre-test initialization.
+     */
+    @Before
+    public void setUp() {
+        ModelImplFactory factory = new ModelImplFactory();
+        fSessionInfo1 = factory.getSessionInfo1();
+        fDomainInfo1 = factory.getDomainInfo1();
+        fSessionInfo2 = factory.getSessionInfo2();
+        fDomainInfo2 = factory.getDomainInfo2();
+    }
+
+    // ------------------------------------------------------------------------
+    // Tests
+    // ------------------------------------------------------------------------
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+
+    /**
+     * Run the ChannelInfo() constructor test.
+     */
+    @Test
+    public void testSessionInfo() {
+        ISessionInfo result = new SessionInfo("test");
+        assertNotNull(result);
+
+        assertEquals("test", result.getName());
+        assertEquals("", result.getSessionPath());
+        TraceSessionState state = result.getSessionState();
+        assertEquals("inactive", state.getInName());
+        assertEquals("INACTIVE", state.name());
+        assertEquals("INACTIVE", state.toString());
+        assertEquals(0, state.ordinal());
+        assertEquals(0, result.getDomains().length);
+        assertFalse(result.isSnapshotSession());
+        assertNull(result.getNetworkUrl());
+        assertNull(result.getControlUrl());
+        assertNull(result.getDataUrl());
+    }
+
+    /**
+     * Test copy constructor.
+     */
+    @Test
+    public void testSessionInfoCopy() {
+        SessionInfo sessionInfo = new SessionInfo((SessionInfo)fSessionInfo1);
+
+        assertEquals(sessionInfo.getName(), fSessionInfo1.getName());
+        assertEquals(sessionInfo.getSessionPath(), fSessionInfo1.getSessionPath());
+        assertEquals(sessionInfo.getSessionState(), fSessionInfo1.getSessionState());
+
+        IDomainInfo[] orignalDomains = fSessionInfo1.getDomains();
+        IDomainInfo[] resultDomains = sessionInfo.getDomains();
+        for (int i = 0; i < orignalDomains.length; i++) {
+            assertEquals(orignalDomains[i], resultDomains[i]);
+        }
+
+        assertEquals(sessionInfo.getNetworkUrl(), fSessionInfo1.getNetworkUrl());
+        assertEquals(sessionInfo.getControlUrl(), fSessionInfo1.getControlUrl());
+        assertEquals(sessionInfo.getDataUrl(), fSessionInfo1.getDataUrl());
+    }
+
+    /**
+     * Test copy constructor.
+     */
+    @Test
+    public void testSessionCopy2() {
+        try {
+            SessionInfo session = null;
+            new SessionInfo(session);
+            fail("null copy");
+        }
+        catch (IllegalArgumentException e) {
+            // Success
+        }
+    }
+
+    /**
+     * Run the long getNumberOfSubBuffers() method test.
+     */
+    @Test
+    public void testGetAndSetters() {
+
+        // Note that addDomain() has been executed in setUp()
+        // check get method here
+        assertEquals(1, fSessionInfo1.getDomains().length);
+        assertNotNull(fSessionInfo1.getDomains()[0]);
+        assertEquals(fDomainInfo1, fSessionInfo1.getDomains()[0]);
+
+        ISessionInfo session = new SessionInfo("session");
+        List<IDomainInfo> list = new LinkedList<>();
+        list.add(fDomainInfo1);
+        list.add(fDomainInfo2);
+        session.setDomains(list);
+
+        IDomainInfo[] result = session.getDomains();
+        assertEquals(2, result.length);
+        assertEquals(fDomainInfo1, result[0]);
+        assertEquals(fDomainInfo2, result[1]);
+
+        session.setSessionPath("/home/user");
+        assertEquals("/home/user", session.getSessionPath());
+
+        session.setSessionState("active");
+        TraceSessionState state = session.getSessionState();
+        state = session.getSessionState();
+        assertEquals("active", state.getInName());
+        assertEquals("ACTIVE", state.name());
+        assertEquals("ACTIVE", state.toString());
+        assertEquals(1, state.ordinal());
+
+        session.setSessionState("inactive");
+        state = session.getSessionState();
+        assertEquals("inactive", state.getInName());
+        assertEquals("INACTIVE", state.name());
+        assertEquals("INACTIVE", state.toString());
+        assertEquals(0, state.ordinal());
+
+        session.setSessionState("test");
+        state = session.getSessionState();
+        assertEquals("inactive", state.getInName());
+        assertEquals("INACTIVE", state.name());
+        assertEquals("INACTIVE", state.toString());
+        assertEquals(0, state.ordinal());
+
+        session.setSessionState(TraceSessionState.ACTIVE);
+        state = session.getSessionState();
+        assertEquals("active", state.getInName());
+        assertEquals("ACTIVE", state.name());
+        assertEquals("ACTIVE", state.toString());
+        assertEquals(1, state.ordinal());
+
+        session.setSessionState(TraceSessionState.INACTIVE);
+        state = session.getSessionState();
+        assertEquals("inactive", state.getInName());
+        assertEquals("INACTIVE", state.name());
+        assertEquals("INACTIVE", state.toString());
+        assertEquals(0, state.ordinal());
+    }
+
+    /**
+     * Run the String toString() method test.
+     */
+    @Test
+    public void testToString_1() {
+        ISessionInfo fixture = new SessionInfo("sessionName");
+
+        String result = fixture.toString();
+
+        // add additional test code here
+        assertEquals("[SessionInfo([TraceInfo(Name=sessionName)],Path=,State=INACTIVE,isStreamedTrace=false,isSnapshot=false,Domains=,NetworkUrl=null,ControlUrl=null,DataUrl=null)]", result);
+    }
+
+    /**
+     * Run the String toString() method test.
+     */
+    @Test
+    public void testToString_2() {
+        String result = fSessionInfo1.toString();
+
+        // add additional test code here
+        assertEquals("[SessionInfo([TraceInfo(Name=session1)],Path=/home/user/lttng-trace/mysession/,State=ACTIVE,isStreamedTrace=false,isSnapshot=false,snapshotInfo="
+                + "[SnapshotInfo([TraceInfo(Name=snapshot-1)],snapshotPath=/home/user/lttng-trace/mysession/,ID=1,isStreamedSnapshot=false)],"
+                    + "Domains=[DomainInfo([TraceInfo(Name=test1)],"
+                        + "Channels=[ChannelInfo([TraceInfo(Name=channel1)],State=DISABLED,OverwriteMode=true,SubBuffersSize=13,NumberOfSubBuffers=12,SwitchTimer=10,ReadTimer=11,output=splice(),"
+                            + "Events=[EventInfo([BaseEventInfo([TraceInfo(Name=event1)],type=TRACEPOINT,level=TRACE_DEBUG)],State=ENABLED,levelType=LOGLEVEL_ONLY)])],"
+                + "isKernel=false)],NetworkUrl=null,ControlUrl=null,DataUrl=null)]", result);
+    }
+
+    /**
+     * Run the String toString() method test.
+     */
+    @Test
+    public void testToString_3() {
+        SessionInfo info = new SessionInfo((SessionInfo)fSessionInfo1);
+        info.setSnapshot(false);
+        info.setSnapshotInfo(null);
+        info.setSessionPath("/home/user/lttng-trace/mysession/");
+
+        String result = info.toString();
+
+        // add additional test code here
+        assertEquals("[SessionInfo([TraceInfo(Name=session1)],Path=/home/user/lttng-trace/mysession/,State=ACTIVE,isStreamedTrace=false,isSnapshot=false,"
+                    + "Domains=[DomainInfo([TraceInfo(Name=test1)],"
+                        + "Channels=[ChannelInfo([TraceInfo(Name=channel1)],State=DISABLED,OverwriteMode=true,SubBuffersSize=13,NumberOfSubBuffers=12,SwitchTimer=10,ReadTimer=11,output=splice(),"
+                            + "Events=[EventInfo([BaseEventInfo([TraceInfo(Name=event1)],type=TRACEPOINT,level=TRACE_DEBUG)],State=ENABLED,levelType=LOGLEVEL_ONLY)])],"
+                + "isKernel=false)],NetworkUrl=null,ControlUrl=null,DataUrl=null)]", result);
+    }
+
+    // ------------------------------------------------------------------------
+    // equals
+    // ------------------------------------------------------------------------
+
+    /**
+     * Run the {@link SessionInfo#equals} method test.
+     */
+    @Test
+    public void testEqualsReflexivity() {
+        assertTrue("equals", fSessionInfo1.equals(fSessionInfo1));
+        assertTrue("equals", fSessionInfo2.equals(fSessionInfo2));
+
+        assertTrue("equals", !fSessionInfo1.equals(fSessionInfo2));
+        assertTrue("equals", !fSessionInfo2.equals(fSessionInfo1));
+    }
+
+    /**
+     * Run the {@link SessionInfo#equals} method test.
+     */
+    @Test
+    public void testEqualsSymmetry() {
+        SessionInfo event1 = new SessionInfo((SessionInfo)fSessionInfo1);
+        SessionInfo event2 = new SessionInfo((SessionInfo)fSessionInfo2);
+
+        assertTrue("equals", event1.equals(fSessionInfo1));
+        assertTrue("equals", fSessionInfo1.equals(event1));
+
+        assertTrue("equals", event2.equals(fSessionInfo2));
+        assertTrue("equals", fSessionInfo2.equals(event2));
+    }
+
+    /**
+     * Run the {@link SessionInfo#equals} method test.
+     */
+    @Test
+    public void testEqualsTransivity() {
+        SessionInfo channel1 = new SessionInfo((SessionInfo)fSessionInfo1);
+        SessionInfo channel2 = new SessionInfo((SessionInfo)fSessionInfo1);
+        SessionInfo channel3 = new SessionInfo((SessionInfo)fSessionInfo1);
+
+        assertTrue("equals", channel1.equals(channel2));
+        assertTrue("equals", channel2.equals(channel3));
+        assertTrue("equals", channel1.equals(channel3));
+    }
+
+    /**
+     * Run the {@link SessionInfo#equals} method test.
+     */
+    @Test
+    public void testEqualsNull() {
+        assertTrue("equals", !fSessionInfo1.equals(null));
+        assertTrue("equals", !fSessionInfo2.equals(null));
+    }
+
+    // ------------------------------------------------------------------------
+    // hashCode
+    // ------------------------------------------------------------------------
+
+    /**
+     * Run the {@link SessionInfo#hashCode} method test.
+     */
+    @Test
+    public void testHashCode() {
+        SessionInfo channel1 = new SessionInfo((SessionInfo)fSessionInfo1);
+        SessionInfo channel2 = new SessionInfo((SessionInfo)fSessionInfo2);
+
+        assertTrue("hashCode", fSessionInfo1.hashCode() == channel1.hashCode());
+        assertTrue("hashCode", fSessionInfo2.hashCode() == channel2.hashCode());
+
+        assertTrue("hashCode", fSessionInfo1.hashCode() != channel2.hashCode());
+        assertTrue("hashCode", fSessionInfo2.hashCode() != channel1.hashCode());
+    }
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/SnapshotInfoTest.java b/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/SnapshotInfoTest.java
new file mode 100644 (file)
index 0000000..180af84
--- /dev/null
@@ -0,0 +1,229 @@
+/**********************************************************************
+ * Copyright (c) 2013, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+
+package org.eclipse.tracecompass.lttng2.control.core.tests.model.impl;
+
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertNotNull;
+import static org.junit.Assert.assertTrue;
+import static org.junit.Assert.fail;
+
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISnapshotInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.SnapshotInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.TraceInfo;
+import org.junit.Before;
+import org.junit.Test;
+
+/**
+ * The class <code>SnapshotInfoTest</code> contains test for the class
+ * <code>{@link SnapshotInfo}</code>.
+ */
+public class SnapshotInfoTest {
+
+    // ------------------------------------------------------------------------
+    // Test data
+    // ------------------------------------------------------------------------
+
+    private ISnapshotInfo fSnapshotInfo1 = null;
+    private ISnapshotInfo fSnapshotInfo2 = null;
+
+
+    // ------------------------------------------------------------------------
+    // Housekeeping
+    // ------------------------------------------------------------------------
+
+    /**
+     * Perform pre-test initialization.
+     */
+    @Before
+    public void setUp() {
+        ModelImplFactory factory = new ModelImplFactory();
+        fSnapshotInfo1 = factory.getSnapshotInfo1();
+        fSnapshotInfo2 = factory.getSnapshotInfo2();
+    }
+
+    // ------------------------------------------------------------------------
+    // Tests
+    // ------------------------------------------------------------------------
+
+    /**
+     * Constructor test.
+     */
+    @Test
+    public void testSnapshotInfo() {
+        SnapshotInfo fixture = new SnapshotInfo("event");
+        assertNotNull(fixture);
+        assertEquals("event", fixture.getName());
+    }
+
+    /**
+     * Test Copy Constructor
+     */
+    @Test
+    public void testSnapshotInfo2() {
+        try {
+            String name = null;
+            new SnapshotInfo(name);
+            fail("null name in custructor");
+        }
+        catch (IllegalArgumentException e) {
+            // Success
+        }
+    }
+
+    /**
+     * Test Copy Constructor
+     */
+    @Test
+    public void testSnapshotCopy() {
+        SnapshotInfo info = new SnapshotInfo((SnapshotInfo)fSnapshotInfo1);
+
+        assertEquals(fSnapshotInfo1.getName(), info.getName());
+    }
+
+    /**
+     * Test Copy Constructor
+     */
+    @Test
+    public void testTraceCopy2() {
+        try {
+            SnapshotInfo info = null;
+            new SnapshotInfo(info);
+            fail("null copy");
+        }
+        catch (IllegalArgumentException e) {
+            // Success
+        }
+    }
+
+    /**
+     * Run the void setEventType(String) method test.
+     */
+    @Test
+    public void testSetName() {
+        SnapshotInfo fixture = new SnapshotInfo("event");
+        fixture.setName("newName");
+        assertEquals("newName", fixture.getName());
+    }
+
+    /**
+     * Run the String toString() method test.
+     */
+    @Test
+    public void testToString_1() {
+        String result = fSnapshotInfo1.toString();
+
+        // add additional test code here
+        assertEquals("[SnapshotInfo([TraceInfo(Name=snapshot-1)],snapshotPath=/home/user/lttng-trace/mysession/,ID=1,isStreamedSnapshot=false)]", result);
+    }
+
+    // ------------------------------------------------------------------------
+    // equals
+    // ------------------------------------------------------------------------
+
+    /**
+     * Run the equals() method test.
+     */
+    @Test
+    public void testEqualsReflexivity() {
+        assertTrue("equals", fSnapshotInfo1.equals(fSnapshotInfo1));
+        assertTrue("equals", fSnapshotInfo2.equals(fSnapshotInfo2));
+
+        assertTrue("equals", !fSnapshotInfo1.equals(fSnapshotInfo2));
+        assertTrue("equals", !fSnapshotInfo2.equals(fSnapshotInfo1));
+    }
+
+    /**
+     * Run the equals() method test.
+     */
+    @Test
+    public void testEqualsSymmetry() {
+        SnapshotInfo info1 = new SnapshotInfo((SnapshotInfo)fSnapshotInfo1);
+        SnapshotInfo info2 = new SnapshotInfo((SnapshotInfo)fSnapshotInfo2);
+
+        assertTrue("equals", info1.equals(fSnapshotInfo1));
+        assertTrue("equals", fSnapshotInfo1.equals(info1));
+
+        assertTrue("equals", info2.equals(fSnapshotInfo2));
+        assertTrue("equals", fSnapshotInfo2.equals(info2));
+    }
+    /**
+     * Run the equals() method test.
+     */
+    @Test
+    public void testEqualsTransivity() {
+        SnapshotInfo info1 = new SnapshotInfo((SnapshotInfo)fSnapshotInfo1);
+        SnapshotInfo info2 = new SnapshotInfo((SnapshotInfo)fSnapshotInfo1);
+        SnapshotInfo info3 = new SnapshotInfo((SnapshotInfo)fSnapshotInfo1);
+
+        assertTrue("equals", info1.equals(info2));
+        assertTrue("equals", info2.equals(info3));
+        assertTrue("equals", info1.equals(info3));
+    }
+    /**
+     * Run the equals() method test.
+     */
+    @Test
+    public void testEqualsNull() {
+        assertTrue("equals", !fSnapshotInfo1.equals(null));
+        assertTrue("equals", !fSnapshotInfo2.equals(null));
+
+        SnapshotInfo info = new SnapshotInfo("snapshot-1");
+        assertTrue("equals", !fSnapshotInfo1.equals(info));
+
+        info.setSnapshotPath(null);
+        assertTrue("equals", !fSnapshotInfo1.equals(info));
+
+        info.setId(fSnapshotInfo1.getId());
+        assertTrue("equals", !info.equals(fSnapshotInfo1));
+
+        info.setSnapshotPath("/home/user/lttng-trace/mysession/");
+        assertTrue("equals", fSnapshotInfo1.equals(info));
+        info.setId(2);
+        assertTrue("equals", !fSnapshotInfo1.equals(info));
+
+        info.setId(fSnapshotInfo1.getId());
+        info.setStreamedSnapshot(true);
+        assertTrue("equals", !fSnapshotInfo1.equals(info));
+
+        assertTrue("equals", !fSnapshotInfo1.equals(new TraceInfo(fSnapshotInfo1.getName())));
+    }
+
+    // ------------------------------------------------------------------------
+    // hashCode
+    // ------------------------------------------------------------------------
+
+    /**
+     * Run the hashCode() method test.
+     */
+    @Test
+    public void testHashCode() {
+        SnapshotInfo info1 = new SnapshotInfo((SnapshotInfo)fSnapshotInfo1);
+        SnapshotInfo info2 = new SnapshotInfo((SnapshotInfo)fSnapshotInfo2);
+
+        assertTrue("hashCode", fSnapshotInfo1.hashCode() == info1.hashCode());
+        assertTrue("hashCode", fSnapshotInfo2.hashCode() == info2.hashCode());
+
+        assertTrue("hashCode", fSnapshotInfo1.hashCode() != info2.hashCode());
+        assertTrue("hashCode", fSnapshotInfo2.hashCode() != info1.hashCode());
+
+        // null values
+        SnapshotInfo info3 = new SnapshotInfo("snapshot-1");
+        assertTrue("hashCode", fSnapshotInfo1.hashCode() != info3.hashCode());
+
+        info3.setSnapshotPath(null);
+        assertTrue("hashCode", fSnapshotInfo1.hashCode() != info3.hashCode());
+
+        info3.setSnapshotPath("/home/user/lttng-trace/mysession/");
+        assertTrue("hashCode", fSnapshotInfo1.hashCode() != info3.hashCode());
+    }
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/TraceInfoTest.java b/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/TraceInfoTest.java
new file mode 100644 (file)
index 0000000..bdea62f
--- /dev/null
@@ -0,0 +1,199 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Alexandre Montplaisir - Port to JUnit4
+ **********************************************************************/
+
+package org.eclipse.tracecompass.lttng2.control.core.tests.model.impl;
+
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertNotNull;
+import static org.junit.Assert.assertTrue;
+import static org.junit.Assert.fail;
+
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.ITraceInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.TraceInfo;
+import org.junit.Before;
+import org.junit.Test;
+
+/**
+ * The class <code>TraceInfoTest</code> contains test for the class
+ * <code>{@link TraceInfo}</code>.
+ */
+public class TraceInfoTest {
+
+    // ------------------------------------------------------------------------
+    // Test data
+    // ------------------------------------------------------------------------
+
+    private ITraceInfo fTraceInfo1 = null;
+    private ITraceInfo fTraceInfo2 = null;
+
+
+    // ------------------------------------------------------------------------
+    // Housekeeping
+    // ------------------------------------------------------------------------
+
+    /**
+     * Perform pre-test initialization.
+     */
+    @Before
+    public void setUp() {
+        fTraceInfo1 = new TraceInfo("event1");
+        fTraceInfo2 = new TraceInfo("event2");
+    }
+
+    // ------------------------------------------------------------------------
+    // Tests
+    // ------------------------------------------------------------------------
+
+    /**
+     * Run the BaseEventInfo() constructor test.
+     */
+    @Test
+    public void testTraceInfo() {
+        TraceInfo fixture = new TraceInfo("event");
+        assertNotNull(fixture);
+
+        assertEquals("event", fixture.getName());
+    }
+
+    /**
+     * Test Copy Constructor
+     */
+    @Test
+    public void testTraceInfo2() {
+        try {
+            String name = null;
+            new TraceInfo(name);
+            fail("null name in custructor");
+        }
+        catch (IllegalArgumentException e) {
+            // Success
+        }
+    }
+
+    /**
+     * Test Copy Constructor
+     */
+    @Test
+    public void testTraceInfoCopy() {
+        TraceInfo info = new TraceInfo((TraceInfo)fTraceInfo1);
+
+        assertEquals(fTraceInfo1.getName(), info.getName());
+    }
+
+    /**
+     * Test Copy Constructor
+     */
+    @Test
+    public void testTraceCopy2() {
+        try {
+            TraceInfo info = null;
+            new TraceInfo(info);
+            fail("null copy");
+        }
+        catch (IllegalArgumentException e) {
+            // Success
+        }
+    }
+
+    /**
+     * Run the void setEventType(String) method test.
+     */
+    @Test
+    public void testSetName() {
+        TraceInfo fixture = new TraceInfo("event");
+        fixture.setName("newName");
+        assertEquals("newName", fixture.getName());
+    }
+
+    /**
+     * Run the String toString() method test.
+     */
+    @Test
+    public void testToString_1() {
+        String result = fTraceInfo1.toString();
+
+        // add additional test code here
+        assertEquals("[TraceInfo(Name=event1)]", result);
+    }
+
+    // ------------------------------------------------------------------------
+    // equals
+    // ------------------------------------------------------------------------
+
+    /**
+     * Run the equals() method test.
+     */
+    @Test
+    public void testEqualsReflexivity() {
+        assertTrue("equals", fTraceInfo1.equals(fTraceInfo1));
+        assertTrue("equals", fTraceInfo2.equals(fTraceInfo2));
+
+        assertTrue("equals", !fTraceInfo1.equals(fTraceInfo2));
+        assertTrue("equals", !fTraceInfo2.equals(fTraceInfo1));
+    }
+
+    /**
+     * Run the equals() method test.
+     */
+    @Test
+    public void testEqualsSymmetry() {
+        TraceInfo info1 = new TraceInfo((TraceInfo)fTraceInfo1);
+        TraceInfo info2 = new TraceInfo((TraceInfo)fTraceInfo2);
+
+        assertTrue("equals", info1.equals(fTraceInfo1));
+        assertTrue("equals", fTraceInfo1.equals(info1));
+
+        assertTrue("equals", info2.equals(fTraceInfo2));
+        assertTrue("equals", fTraceInfo2.equals(info2));
+    }
+    /**
+     * Run the equals() method test.
+     */
+    @Test
+    public void testEqualsTransivity() {
+        TraceInfo info1 = new TraceInfo((TraceInfo)fTraceInfo1);
+        TraceInfo info2 = new TraceInfo((TraceInfo)fTraceInfo1);
+        TraceInfo info3 = new TraceInfo((TraceInfo)fTraceInfo1);
+
+        assertTrue("equals", info1.equals(info2));
+        assertTrue("equals", info2.equals(info3));
+        assertTrue("equals", info1.equals(info3));
+    }
+    /**
+     * Run the equals() method test.
+     */
+    @Test
+    public void testEqualsNull() {
+        assertTrue("equals", !fTraceInfo1.equals(null));
+        assertTrue("equals", !fTraceInfo2.equals(null));
+    }
+
+    // ------------------------------------------------------------------------
+    // hashCode
+    // ------------------------------------------------------------------------
+
+    /**
+     * Run the hashCode() method test.
+     */
+    @Test
+    public void testHashCode() {
+        TraceInfo info1 = new TraceInfo((TraceInfo)fTraceInfo1);
+        TraceInfo info2 = new TraceInfo((TraceInfo)fTraceInfo2);
+
+        assertTrue("hashCode", fTraceInfo1.hashCode() == info1.hashCode());
+        assertTrue("hashCode", fTraceInfo2.hashCode() == info2.hashCode());
+
+        assertTrue("hashCode", fTraceInfo1.hashCode() != info2.hashCode());
+        assertTrue("hashCode", fTraceInfo2.hashCode() != info1.hashCode());
+    }
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/UstProviderInfoTest.java b/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/UstProviderInfoTest.java
new file mode 100644 (file)
index 0000000..0099c8a
--- /dev/null
@@ -0,0 +1,254 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Alexandre Montplaisir - Port to JUnit4
+ **********************************************************************/
+
+package org.eclipse.tracecompass.lttng2.control.core.tests.model.impl;
+
+import static org.junit.Assert.*;
+
+import java.util.LinkedList;
+import java.util.List;
+
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IBaseEventInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IUstProviderInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.BaseEventInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.UstProviderInfo;
+import org.junit.Before;
+import org.junit.Test;
+
+/**
+ * The class <code>ChannelInfoTest</code> contains tests for the class
+ * <code>{@link UstProviderInfo}</code>.
+ */
+public class UstProviderInfoTest {
+
+    // ------------------------------------------------------------------------
+    // Test data
+    // ------------------------------------------------------------------------
+
+    private IUstProviderInfo fUstProviderInfo1 = null;
+    private IUstProviderInfo fUstProviderInfo2 = null;
+
+    private IBaseEventInfo fEventInfo1 = null;
+    private IBaseEventInfo fEventInfo2 = null;
+
+    // ------------------------------------------------------------------------
+    // Housekeeping
+    // ------------------------------------------------------------------------
+
+    /**
+     * Perform pre-test initialization.
+     */
+    @Before
+    public void setUp() {
+        ModelImplFactory factory = new ModelImplFactory();
+        fUstProviderInfo1 = factory.getUstProviderInfo1();
+        fUstProviderInfo2 = factory.getUstProviderInfo2();
+        fEventInfo1 = factory.getBaseEventInfo1();
+        fEventInfo2 = factory.getBaseEventInfo2();
+    }
+
+    // ------------------------------------------------------------------------
+    // Tests
+    // ------------------------------------------------------------------------
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+
+    /**
+     * Run the UstProviderInfo() constructor test.
+     */
+    @Test
+    public void testUstProviderInfo() {
+        IUstProviderInfo result = new UstProviderInfo("test");
+        assertNotNull(result);
+
+        assertEquals("test", result.getName());
+        assertEquals(0, result.getPid());
+        assertEquals(0, result.getEvents().length);
+    }
+
+    /**
+     * Test the copy constructor.
+     */
+    @Test
+    public void testUstProviderInfoCopy() {
+        IUstProviderInfo providerInf = new UstProviderInfo((UstProviderInfo)fUstProviderInfo1);
+
+        assertEquals(fUstProviderInfo1.getName(), providerInf.getName());
+        assertEquals(fUstProviderInfo1.getPid(), providerInf.getPid());
+        assertEquals(fUstProviderInfo1.getEvents().length, providerInf.getEvents().length);
+
+        IBaseEventInfo[] orignalEvents = fUstProviderInfo1.getEvents();
+        IBaseEventInfo[] resultEvents = providerInf.getEvents();
+        for (int i = 0; i < orignalEvents.length; i++) {
+            assertEquals(orignalEvents[i], resultEvents[i]);
+        }
+    }
+
+    /**
+     * Test the copy constructor.
+     */
+    @Test
+    public void testUstProviderCopy2() {
+        try {
+            UstProviderInfo providerInfo = null;
+            new UstProviderInfo(providerInfo);
+            fail("null copy");
+        }
+        catch (IllegalArgumentException e) {
+            // Success
+        }
+    }
+
+    /**
+     * Run the IEventInfo[] getEvents() method test.
+     */
+    @Test
+    public void testGetAndSetters() {
+        IUstProviderInfo fixture = new UstProviderInfo("test");
+        fixture.setPid(2468);
+
+        // add an event
+        IBaseEventInfo event = new BaseEventInfo("event");
+        fixture.addEvent(event);
+
+        // Verify the stored events
+        IBaseEventInfo[] result = fixture.getEvents();
+
+        assertNotNull(result);
+        assertEquals(1, result.length);
+        assertNotNull(result[0]);
+        assertTrue(event.equals(result[0]));
+
+        assertEquals(2468, fixture.getPid());
+    }
+
+    /**
+     * Run the void setEvents(List<IBaseEventInfo>) method test.
+     */
+    @Test
+    public void testSetEvents_1() {
+        UstProviderInfo fixture = new UstProviderInfo("test");
+        fixture.setPid(2468);
+        List<IBaseEventInfo> events = new LinkedList<>();
+        events.add(fEventInfo1);
+        events.add(fEventInfo2);
+        fixture.setEvents(events);
+
+        IBaseEventInfo[] infos = fixture.getEvents();
+
+        assertEquals(events.size(), infos.length);
+
+        for (int i = 0; i < infos.length; i++) {
+            assertEquals(events.get(i), infos[i]);
+        }
+    }
+
+    /**
+     * Run the String toString() method test.
+     */
+    @Test
+    public void testToString_1() {
+        UstProviderInfo fixture = new UstProviderInfo("test");
+        fixture.setPid(2468);
+        String result = fixture.toString();
+
+        assertEquals("[EventInfo([TraceInfo(Name=test)],PID=2468,Events=None)]", result);
+    }
+
+    /**
+     * Run the String toString() method test.
+     */
+    @Test
+    public void testToString_2() {
+        String result = fUstProviderInfo2.toString();
+        assertEquals("[EventInfo([TraceInfo(Name=myUST2)],PID=2345,Events=[BaseEventInfo([TraceInfo(Name=event1)]," +
+                "type=UNKNOWN,level=TRACE_DEBUG,Fields=[FieldInfo([TraceInfo(Name=intfield)],type=int[FieldInfo" +
+                "([TraceInfo(Name=stringfield)],type=string,Filter=intField==10)][BaseEventInfo([TraceInfo(Name=event2)]," +
+                "type=TRACEPOINT,level=TRACE_DEBUG)])]", result);
+    }
+
+    // ------------------------------------------------------------------------
+    // equals
+    // ------------------------------------------------------------------------
+
+    /**
+     * Run the equals() method test.
+     */
+    @Test
+    public void testEqualsReflexivity() {
+        assertTrue("equals", fUstProviderInfo1.equals(fUstProviderInfo1));
+        assertTrue("equals", fUstProviderInfo2.equals(fUstProviderInfo2));
+
+        assertTrue("equals", !fUstProviderInfo1.equals(fUstProviderInfo2));
+        assertTrue("equals", !fUstProviderInfo2.equals(fUstProviderInfo1));
+    }
+
+    /**
+     * Run the equals() method test.
+     */
+    @Test
+    public void testEqualsSymmetry() {
+        UstProviderInfo event1 = new UstProviderInfo((UstProviderInfo)fUstProviderInfo1);
+        UstProviderInfo event2 = new UstProviderInfo((UstProviderInfo)fUstProviderInfo2);
+
+        assertTrue("equals", event1.equals(fUstProviderInfo1));
+        assertTrue("equals", fUstProviderInfo1.equals(event1));
+
+        assertTrue("equals", event2.equals(fUstProviderInfo2));
+        assertTrue("equals", fUstProviderInfo2.equals(event2));
+    }
+
+    /**
+     * Run the equals() method test.
+     */
+    @Test
+    public void testEqualsTransivity() {
+        UstProviderInfo UstProvider1 = new UstProviderInfo((UstProviderInfo)fUstProviderInfo1);
+        UstProviderInfo UstProvider2 = new UstProviderInfo((UstProviderInfo)fUstProviderInfo1);
+        UstProviderInfo UstProvider3 = new UstProviderInfo((UstProviderInfo)fUstProviderInfo1);
+
+        assertTrue("equals", UstProvider1.equals(UstProvider2));
+        assertTrue("equals", UstProvider2.equals(UstProvider3));
+        assertTrue("equals", UstProvider1.equals(UstProvider3));
+    }
+
+    /**
+     * Run the equals() method test.
+     */
+    @Test
+    public void testEqualsNull() {
+        assertTrue("equals", !fUstProviderInfo1.equals(null));
+        assertTrue("equals", !fUstProviderInfo2.equals(null));
+    }
+
+    // ------------------------------------------------------------------------
+    // hashCode
+    // ------------------------------------------------------------------------
+
+    /**
+     * Run the hashCode() method test.
+     */
+    @Test
+    public void testHashCode() {
+        UstProviderInfo UstProvider1 = new UstProviderInfo((UstProviderInfo)fUstProviderInfo1);
+        UstProviderInfo UstProvider2 = new UstProviderInfo((UstProviderInfo)fUstProviderInfo2);
+
+        assertTrue("hashCode", fUstProviderInfo1.hashCode() == UstProvider1.hashCode());
+        assertTrue("hashCode", fUstProviderInfo2.hashCode() == UstProvider2.hashCode());
+
+        assertTrue("hashCode", fUstProviderInfo1.hashCode() != UstProvider2.hashCode());
+        assertTrue("hashCode", fUstProviderInfo2.hashCode() != UstProvider1.hashCode());
+    }
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/relayd/LttngRelayd24Test.java b/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/relayd/LttngRelayd24Test.java
new file mode 100644 (file)
index 0000000..8533459
--- /dev/null
@@ -0,0 +1,108 @@
+/**********************************************************************
+ * Copyright (c) 2014 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:
+ *   Matthew Khouzam - Initial implementation
+ **********************************************************************/
+
+package org.eclipse.tracecompass.lttng2.control.core.tests.relayd;
+
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertNotNull;
+import static org.junit.Assert.assertTrue;
+
+import java.io.DataInputStream;
+import java.io.DataOutputStream;
+import java.io.IOException;
+import java.net.InetAddress;
+import java.net.Socket;
+import java.util.List;
+
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.ILttngRelaydConnector;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.LttngRelaydConnectorFactory;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.AttachSessionResponse;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.Command;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.ConnectResponse;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.CreateSessionResponse;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.CreateSessionReturnCode;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.GetNextIndex;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.IndexResponse;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.NextIndexReturnCode;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.SessionResponse;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.StreamResponse;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.ViewerCommand;
+import org.junit.Test;
+
+/**
+ * Unit tests for lttng-relayd. It actually allows us to test the API.
+ *
+ * @author Matthew Khouzam
+ */
+public class LttngRelayd24Test {
+
+    private static final int PACKETS_TO_READ = 100;
+    private static final String ADDRESS = "127.0.0.1"; // change me //$NON-NLS-1$
+    private static final int PORT = 5344;
+
+    private static void getPackets(AttachSessionResponse attachedSession, Socket connection, ILttngRelaydConnector relayD) throws IOException {
+        int numPacketsReceived = 0;
+        DataOutputStream fOutNet = new DataOutputStream(connection.getOutputStream());
+        DataInputStream fInNet = new DataInputStream(connection.getInputStream());
+        while (numPacketsReceived < PACKETS_TO_READ) {
+            for (StreamResponse stream : attachedSession.getStreamList()) {
+                if (stream.getMetadataFlag() != 1) {
+                    ConnectResponse connectPayload = new ConnectResponse(fInNet);
+                    assertNotNull(connectPayload);
+
+                    ViewerCommand connectCommand = new ViewerCommand(Command.VIEWER_GET_NEXT_INDEX, ConnectResponse.SIZE, 0);
+                    fOutNet.write(connectCommand.serialize());
+                    fOutNet.flush();
+
+                    GetNextIndex indexRequest = new GetNextIndex(stream.getId());
+                    fOutNet.write(indexRequest.serialize());
+                    fOutNet.flush();
+
+                    IndexResponse indexReply = new IndexResponse(fInNet);
+                    // Nothing else supported for now
+                    if (indexReply.getStatus() == NextIndexReturnCode.VIEWER_INDEX_OK) {
+                        if (relayD.getPacketFromStream(indexReply, stream.getId()) != null) {
+                            numPacketsReceived++;
+                        }
+                    }
+                }
+            }
+        }
+    }
+
+    /**
+     * Test a connection
+     *
+     * @throws IOException
+     *             network timeout?
+     */
+    @Test
+    public void testViewerConnection() throws IOException {
+        InetAddress addr = InetAddress.getByName(ADDRESS);
+        try (Socket connection = new Socket(addr, PORT);
+                ILttngRelaydConnector relayD = LttngRelaydConnectorFactory.getNewConnector(connection);) {
+
+            List<SessionResponse> sessions = relayD.getSessions();
+            assertTrue(sessions.size() > 0);
+            SessionResponse lttngViewerSession = sessions.get(0);
+            assertNotNull(lttngViewerSession);
+            CreateSessionResponse createSession = relayD.createSession();
+            assertEquals(createSession.getStatus(), CreateSessionReturnCode.LTTNG_VIEWER_CREATE_SESSION_OK);
+            AttachSessionResponse attachedSession = relayD.attachToSession(lttngViewerSession);
+
+            String metaData = relayD.getMetadata(attachedSession);
+            assertNotNull(metaData);
+
+            getPackets(attachedSession, connection, relayD);
+        }
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/session/AllTests.java b/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/session/AllTests.java
new file mode 100644 (file)
index 0000000..c489583
--- /dev/null
@@ -0,0 +1,26 @@
+/**********************************************************************
+ * Copyright (c) 2014 École Polytechnique de Montréal
+ *
+ * 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:
+ *   Guilliano Molaire - Initial API and implementation
+ *********************************************************************/
+package org.eclipse.tracecompass.lttng2.control.core.tests.session;
+
+import org.junit.runner.RunWith;
+import org.junit.runners.Suite;
+
+/**
+ * Run all the tests in the lttng2.core.session plugin.
+ */
+@RunWith(Suite.class)
+@Suite.SuiteClasses({
+    SessionConfigGeneratorTest.class
+})
+public class AllTests {
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/session/SessionConfigGeneratorTest.java b/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/session/SessionConfigGeneratorTest.java
new file mode 100644 (file)
index 0000000..a232b81
--- /dev/null
@@ -0,0 +1,156 @@
+/**********************************************************************
+ * Copyright (c) 2014 École Polytechnique de Montréal
+ *
+ * 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:
+ *   Guilliano Molaire - Initial API and implementation
+ *********************************************************************/
+
+package org.eclipse.tracecompass.lttng2.control.core.tests.session;
+
+import static org.junit.Assert.assertFalse;
+import static org.junit.Assert.assertTrue;
+import static org.junit.Assert.fail;
+
+import java.io.File;
+import java.util.HashSet;
+import java.util.Set;
+
+import org.eclipse.core.runtime.IPath;
+import org.eclipse.core.runtime.IStatus;
+import org.eclipse.tracecompass.internal.lttng2.control.core.Activator;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IDomainInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISessionInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.BufferType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.SessionInfo;
+import org.eclipse.tracecompass.lttng2.control.core.session.SessionConfigGenerator;
+import org.eclipse.tracecompass.lttng2.control.core.session.SessionConfigStrings;
+import org.eclipse.tracecompass.lttng2.control.core.tests.model.impl.ModelImplFactory;
+import org.junit.After;
+import org.junit.Before;
+import org.junit.Test;
+
+/**
+ * This class contains tests for the class {@link SessionConfigGenerator}.
+ */
+public class SessionConfigGeneratorTest {
+
+    // ------------------------------------------------------------------------
+    // Test data
+    // ------------------------------------------------------------------------
+
+    /** Session files for validation */
+    private static final File VALID_SESSION_FILE = new File("../org.eclipse.tracecompass.lttng2.control.core.tests/test_session_config_files/test_valid.lttng");
+    private static final File INVALID_SESSION_FILE = new File("../org.eclipse.tracecompass.lttng2.control.core.tests/test_session_config_files/test_invalid.lttng");
+
+    private static final String SESSION_FILENAME = "test_session." + SessionConfigStrings.SESSION_CONFIG_FILE_EXTENSION;
+    private static final IPath SESSION_FILE_PATH = Activator.getDefault().getStateLocation().addTrailingSeparator().append(SESSION_FILENAME);
+    private static final String TRACE_SESSION_PATH = "/home/user/folder";
+
+    private static final String SESSION_NAME_1 = "session1";
+    private static final String SESSION_NAME_2 = "session2";
+    private static final String SESSION_NAME_3 = "session3";
+
+    /** Session informations for generation tests */
+    private ISessionInfo fValidSessionInfo = null;
+    private ISessionInfo fValidSessionSnapshotInfo = null;
+    private ISessionInfo fInvalidSessionInfo = null;
+
+    // ------------------------------------------------------------------------
+    // Housekeeping
+    // ------------------------------------------------------------------------
+    /**
+     * Perform pre-test initialization.
+     */
+    @Before
+    public void setUp() {
+        /* A valid domain with shared buffer type */
+        ModelImplFactory factory = new ModelImplFactory();
+        IDomainInfo domain = factory.getDomainInfo1();
+        domain.setBufferType(BufferType.BUFFER_SHARED);
+
+        /* The valid sessions */
+        fValidSessionInfo = new SessionInfo(SESSION_NAME_1);
+        fValidSessionInfo.setSessionPath(TRACE_SESSION_PATH);
+        fValidSessionInfo.setSessionState(TraceSessionState.ACTIVE);
+        fValidSessionInfo.addDomain(domain);
+
+        fValidSessionSnapshotInfo = new SessionInfo(SESSION_NAME_2);
+        fValidSessionSnapshotInfo.setSessionPath(TRACE_SESSION_PATH);
+        fValidSessionSnapshotInfo.setSessionState(TraceSessionState.ACTIVE);
+        fValidSessionSnapshotInfo.addDomain(domain);
+        fValidSessionSnapshotInfo.setSnapshotInfo(factory.getSnapshotInfo1());
+
+        /* The invalid session contains an event with an invalid type */
+        fInvalidSessionInfo = factory.getSessionInfo2();
+        fInvalidSessionInfo.setName(SESSION_NAME_3);
+    }
+
+    /**
+     * Delete the session file created
+     */
+    @After
+    public void tearUp() {
+        /* Tear up the file created if it exists */
+        File sessionConfigurationFile = SESSION_FILE_PATH.toFile();
+        if (sessionConfigurationFile.exists()) {
+            sessionConfigurationFile.delete();
+        }
+
+    }
+
+    // ------------------------------------------------------------------------
+    // Tests
+    // ------------------------------------------------------------------------
+
+    /**
+     * Test method for {@link SessionConfigGenerator#sessionValidate(File)}
+     */
+    @Test
+    public void testSessionValidate() {
+        File testSessionFile = VALID_SESSION_FILE;
+        if ((testSessionFile == null) || !testSessionFile.exists()) {
+            fail("Session test file does not exist");
+        }
+        IStatus status = SessionConfigGenerator.sessionValidate(testSessionFile);
+        if (!status.isOK()) {
+            fail(status.getMessage());
+        }
+
+        testSessionFile = INVALID_SESSION_FILE;
+        if ((testSessionFile == null) || !testSessionFile.exists()) {
+            fail("Session test file does not exist");
+        }
+        assertFalse(SessionConfigGenerator.sessionValidate(testSessionFile).isOK());
+    }
+
+    /**
+     * Test method for
+     * {@link SessionConfigGenerator#generateSessionConfig(Set, IPath)}
+     */
+    @Test
+    public void testGenerateSessionConfig() {
+        /* Should fail since it's empty */
+        final Set<ISessionInfo> sessions = new HashSet<>();
+        assertFalse(SessionConfigGenerator.generateSessionConfig(sessions, SESSION_FILE_PATH).isOK());
+
+        /* Add a valid session and validate */
+        sessions.add(fValidSessionInfo);
+        assertTrue(SessionConfigGenerator.generateSessionConfig(sessions, SESSION_FILE_PATH).isOK());
+        assertTrue(SessionConfigGenerator.sessionValidate(SESSION_FILE_PATH.toFile()).isOK());
+
+        /* Add a valid snapshot session and validate */
+        sessions.add(fValidSessionSnapshotInfo);
+        assertTrue(SessionConfigGenerator.generateSessionConfig(sessions, SESSION_FILE_PATH).isOK());
+        assertTrue(SessionConfigGenerator.sessionValidate(SESSION_FILE_PATH.toFile()).isOK());
+
+        /* Add an invalid session */
+        sessions.add(fInvalidSessionInfo);
+        assertFalse(SessionConfigGenerator.generateSessionConfig(sessions, SESSION_FILE_PATH).isOK());
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/test_session_config_files/test_invalid.lttng b/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/test_session_config_files/test_invalid.lttng
new file mode 100644 (file)
index 0000000..d13f485
--- /dev/null
@@ -0,0 +1,55 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>\r
+ <!--***************************************************************************\r
+ * Copyright(C) 2014 École Polytechnique de Montréal\r
+ *\r
+ * All rights reserved. This program and the accompanying materials are\r
+ * made available under the terms of the Eclipse Public License v1.0 which\r
+ * accompanies this distribution, and is available at\r
+ * http://www.eclipse.org/legal/epl-v10.html\r
+ *\r
+ * Contributors:\r
+ *   Guilliano Molaire - Initial API and implementation\r
+ ***************************************************************************\r
+ This is an invalid session configuration file. The domain type\r
+ is missing.-->\r
+<sessions>\r
+    <session>\r
+        <name>auto-20140323-130527</name>\r
+        <started>false</started>\r
+        <domains>\r
+            <domain>\r
+                <buffer_type>GLOBAL</buffer_type>\r
+                <channels>\r
+                    <channel>\r
+                        <name>channel0</name>\r
+                        <overwrite_mode>DISCARD</overwrite_mode>\r
+                        <subbuffer_count>4</subbuffer_count>\r
+                        <switch_timer_interval>0</switch_timer_interval>\r
+                        <tracefile_size>0</tracefile_size>\r
+                        <tracefile_count>0</tracefile_count>\r
+                        <live_timer_interval>0</live_timer_interval>\r
+                        <enabled>false</enabled>\r
+                        <subbuffer_size>262144</subbuffer_size>\r
+                        <read_timer_interval>200000</read_timer_interval>\r
+                        <output_type>SPLICE</output_type>\r
+                        <events>\r
+                            <event>\r
+                                <name>exit_syscall</name>\r
+                                <enabled>true</enabled>\r
+                                <type>TRACEPOINT</type>\r
+                            </event>\r
+                        </events>\r
+                    </channel>\r
+                </channels>\r
+            </domain>\r
+        </domains>\r
+        <output>\r
+            <consumer_output>\r
+                <enabled>true</enabled>\r
+                <destination>\r
+                    <path>/home/user/folder</path>\r
+                </destination>\r
+            </consumer_output>\r
+        </output>\r
+    </session>\r
+</sessions>\r
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/test_session_config_files/test_valid.lttng b/lttng/org.eclipse.tracecompass.lttng2.control.core.tests/test_session_config_files/test_valid.lttng
new file mode 100644 (file)
index 0000000..4dea4df
--- /dev/null
@@ -0,0 +1,56 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>\r
+ <!--***************************************************************************\r
+ * Copyright(C) 2014 École Polytechnique de Montréal\r
+ *\r
+ * All rights reserved. This program and the accompanying materials are\r
+ * made available under the terms of the Eclipse Public License v1.0 which\r
+ * accompanies this distribution, and is available at\r
+ * http://www.eclipse.org/legal/epl-v10.html\r
+ *\r
+ * Contributors:\r
+ *   Guilliano Molaire - Initial API and implementation\r
+ ***************************************************************************\r
+ This is a valid session configuration file. All mandatory\r
+ elements are provided.-->\r
+<sessions>\r
+    <session>\r
+        <name>auto-20140323-130527</name>\r
+        <started>false</started>\r
+        <domains>\r
+            <domain>\r
+                <type>KERNEL</type>\r
+                <buffer_type>GLOBAL</buffer_type>\r
+                <channels>\r
+                    <channel>\r
+                        <name>channel0</name>\r
+                        <overwrite_mode>DISCARD</overwrite_mode>\r
+                        <subbuffer_count>4</subbuffer_count>\r
+                        <switch_timer_interval>0</switch_timer_interval>\r
+                        <tracefile_size>0</tracefile_size>\r
+                        <tracefile_count>0</tracefile_count>\r
+                        <live_timer_interval>0</live_timer_interval>\r
+                        <enabled>false</enabled>\r
+                        <subbuffer_size>262144</subbuffer_size>\r
+                        <read_timer_interval>200000</read_timer_interval>\r
+                        <output_type>SPLICE</output_type>\r
+                        <events>\r
+                            <event>\r
+                                <name>exit_syscall</name>\r
+                                <enabled>true</enabled>\r
+                                <type>TRACEPOINT</type>\r
+                            </event>\r
+                        </events>\r
+                    </channel>\r
+                </channels>\r
+            </domain>\r
+        </domains>\r
+        <output>\r
+            <consumer_output>\r
+                <enabled>true</enabled>\r
+                <destination>\r
+                    <path>/home/user/folder</path>\r
+                </destination>\r
+            </consumer_output>\r
+        </output>\r
+    </session>\r
+</sessions>\r
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/.classpath b/lttng/org.eclipse.tracecompass.lttng2.control.core/.classpath
new file mode 100644 (file)
index 0000000..098194c
--- /dev/null
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+       <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7"/>
+       <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
+       <classpathentry kind="src" path="src"/>
+       <classpathentry kind="output" path="bin"/>
+</classpath>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/.project b/lttng/org.eclipse.tracecompass.lttng2.control.core/.project
new file mode 100644 (file)
index 0000000..a1054ac
--- /dev/null
@@ -0,0 +1,34 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+       <name>org.eclipse.tracecompass.lttng2.control.core</name>
+       <comment></comment>
+       <projects>
+       </projects>
+       <buildSpec>
+               <buildCommand>
+                       <name>org.eclipse.jdt.core.javabuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+               <buildCommand>
+                       <name>org.eclipse.pde.ManifestBuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+               <buildCommand>
+                       <name>org.eclipse.pde.SchemaBuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+               <buildCommand>
+                       <name>org.eclipse.pde.api.tools.apiAnalysisBuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+       </buildSpec>
+       <natures>
+               <nature>org.eclipse.pde.PluginNature</nature>
+               <nature>org.eclipse.jdt.core.javanature</nature>
+               <nature>org.eclipse.pde.api.tools.apiAnalysisNature</nature>
+       </natures>
+</projectDescription>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/.settings/org.eclipse.core.resources.prefs b/lttng/org.eclipse.tracecompass.lttng2.control.core/.settings/org.eclipse.core.resources.prefs
new file mode 100644 (file)
index 0000000..99f26c0
--- /dev/null
@@ -0,0 +1,2 @@
+eclipse.preferences.version=1
+encoding/<project>=UTF-8
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/.settings/org.eclipse.core.runtime.prefs b/lttng/org.eclipse.tracecompass.lttng2.control.core/.settings/org.eclipse.core.runtime.prefs
new file mode 100644 (file)
index 0000000..5a0ad22
--- /dev/null
@@ -0,0 +1,2 @@
+eclipse.preferences.version=1
+line.separator=\n
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/.settings/org.eclipse.jdt.core.prefs b/lttng/org.eclipse.tracecompass.lttng2.control.core/.settings/org.eclipse.jdt.core.prefs
new file mode 100644 (file)
index 0000000..a2b5e6b
--- /dev/null
@@ -0,0 +1,405 @@
+eclipse.preferences.version=1
+org.eclipse.jdt.core.codeComplete.argumentPrefixes=
+org.eclipse.jdt.core.codeComplete.argumentSuffixes=
+org.eclipse.jdt.core.codeComplete.fieldPrefixes=f
+org.eclipse.jdt.core.codeComplete.fieldSuffixes=
+org.eclipse.jdt.core.codeComplete.localPrefixes=
+org.eclipse.jdt.core.codeComplete.localSuffixes=
+org.eclipse.jdt.core.codeComplete.staticFieldPrefixes=
+org.eclipse.jdt.core.codeComplete.staticFieldSuffixes=
+org.eclipse.jdt.core.codeComplete.staticFinalFieldPrefixes=
+org.eclipse.jdt.core.codeComplete.staticFinalFieldSuffixes=
+org.eclipse.jdt.core.compiler.annotation.inheritNullAnnotations=enabled
+org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore
+org.eclipse.jdt.core.compiler.annotation.nonnull=org.eclipse.jdt.annotation.NonNull
+org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=org.eclipse.jdt.annotation.NonNullByDefault
+org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nullable
+org.eclipse.jdt.core.compiler.annotation.nullanalysis=enabled
+org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
+org.eclipse.jdt.core.compiler.codegen.methodParameters=do not generate
+org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
+org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
+org.eclipse.jdt.core.compiler.compliance=1.7
+org.eclipse.jdt.core.compiler.debug.lineNumber=generate
+org.eclipse.jdt.core.compiler.debug.localVariable=generate
+org.eclipse.jdt.core.compiler.debug.sourceFile=generate
+org.eclipse.jdt.core.compiler.doc.comment.support=enabled
+org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=error
+org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
+org.eclipse.jdt.core.compiler.problem.autoboxing=ignore
+org.eclipse.jdt.core.compiler.problem.comparingIdentical=error
+org.eclipse.jdt.core.compiler.problem.deadCode=error
+org.eclipse.jdt.core.compiler.problem.deprecation=error
+org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled
+org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=enabled
+org.eclipse.jdt.core.compiler.problem.discouragedReference=warning
+org.eclipse.jdt.core.compiler.problem.emptyStatement=error
+org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
+org.eclipse.jdt.core.compiler.problem.explicitlyClosedAutoCloseable=error
+org.eclipse.jdt.core.compiler.problem.fallthroughCase=error
+org.eclipse.jdt.core.compiler.problem.fatalOptionalError=disabled
+org.eclipse.jdt.core.compiler.problem.fieldHiding=error
+org.eclipse.jdt.core.compiler.problem.finalParameterBound=error
+org.eclipse.jdt.core.compiler.problem.finallyBlockNotCompletingNormally=error
+org.eclipse.jdt.core.compiler.problem.forbiddenReference=error
+org.eclipse.jdt.core.compiler.problem.hiddenCatchBlock=error
+org.eclipse.jdt.core.compiler.problem.includeNullInfoFromAsserts=disabled
+org.eclipse.jdt.core.compiler.problem.incompatibleNonInheritedInterfaceMethod=error
+org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch=error
+org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=error
+org.eclipse.jdt.core.compiler.problem.invalidJavadoc=warning
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTags=enabled
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsDeprecatedRef=enabled
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsNotVisibleRef=enabled
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsVisibility=protected
+org.eclipse.jdt.core.compiler.problem.localVariableHiding=error
+org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=error
+org.eclipse.jdt.core.compiler.problem.missingDefaultCase=error
+org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=error
+org.eclipse.jdt.core.compiler.problem.missingEnumCaseDespiteDefault=enabled
+org.eclipse.jdt.core.compiler.problem.missingHashCodeMethod=error
+org.eclipse.jdt.core.compiler.problem.missingJavadocComments=warning
+org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsOverriding=disabled
+org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsVisibility=protected
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagDescription=all_standard_tags
+org.eclipse.jdt.core.compiler.problem.missingJavadocTags=warning
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagsMethodTypeParameters=disabled
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagsOverriding=disabled
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagsVisibility=protected
+org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotation=error
+org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotationForInterfaceMethodImplementation=enabled
+org.eclipse.jdt.core.compiler.problem.missingSerialVersion=error
+org.eclipse.jdt.core.compiler.problem.missingSynchronizedOnInheritedMethod=error
+org.eclipse.jdt.core.compiler.problem.noEffectAssignment=error
+org.eclipse.jdt.core.compiler.problem.noImplicitStringConversion=error
+org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=warning
+org.eclipse.jdt.core.compiler.problem.nonnullParameterAnnotationDropped=warning
+org.eclipse.jdt.core.compiler.problem.nullAnnotationInferenceConflict=warning
+org.eclipse.jdt.core.compiler.problem.nullReference=error
+org.eclipse.jdt.core.compiler.problem.nullSpecViolation=error
+org.eclipse.jdt.core.compiler.problem.nullUncheckedConversion=warning
+org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=error
+org.eclipse.jdt.core.compiler.problem.parameterAssignment=error
+org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=error
+org.eclipse.jdt.core.compiler.problem.potentialNullReference=error
+org.eclipse.jdt.core.compiler.problem.potentiallyUnclosedCloseable=warning
+org.eclipse.jdt.core.compiler.problem.rawTypeReference=warning
+org.eclipse.jdt.core.compiler.problem.redundantNullAnnotation=warning
+org.eclipse.jdt.core.compiler.problem.redundantNullCheck=error
+org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=error
+org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=error
+org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore
+org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=error
+org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled
+org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=error
+org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=disabled
+org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled
+org.eclipse.jdt.core.compiler.problem.syntacticNullAnalysisForFields=enabled
+org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=ignore
+org.eclipse.jdt.core.compiler.problem.typeParameterHiding=error
+org.eclipse.jdt.core.compiler.problem.unavoidableGenericTypeProblems=disabled
+org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=warning
+org.eclipse.jdt.core.compiler.problem.unclosedCloseable=error
+org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=ignore
+org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=error
+org.eclipse.jdt.core.compiler.problem.unnecessaryElse=error
+org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=error
+org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=warning
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionExemptExceptionAndThrowable=disabled
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionIncludeDocCommentReference=disabled
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverriding=disabled
+org.eclipse.jdt.core.compiler.problem.unusedExceptionParameter=ignore
+org.eclipse.jdt.core.compiler.problem.unusedImport=error
+org.eclipse.jdt.core.compiler.problem.unusedLabel=error
+org.eclipse.jdt.core.compiler.problem.unusedLocal=error
+org.eclipse.jdt.core.compiler.problem.unusedObjectAllocation=ignore
+org.eclipse.jdt.core.compiler.problem.unusedParameter=error
+org.eclipse.jdt.core.compiler.problem.unusedParameterIncludeDocCommentReference=enabled
+org.eclipse.jdt.core.compiler.problem.unusedParameterWhenImplementingAbstract=disabled
+org.eclipse.jdt.core.compiler.problem.unusedParameterWhenOverridingConcrete=disabled
+org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=error
+org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=error
+org.eclipse.jdt.core.compiler.problem.unusedWarningToken=error
+org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=error
+org.eclipse.jdt.core.compiler.source=1.7
+org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=16
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_call=16
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation=16
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression=16
+org.eclipse.jdt.core.formatter.alignment_for_assignment=0
+org.eclipse.jdt.core.formatter.alignment_for_binary_expression=16
+org.eclipse.jdt.core.formatter.alignment_for_compact_if=16
+org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=80
+org.eclipse.jdt.core.formatter.alignment_for_enum_constants=0
+org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=16
+org.eclipse.jdt.core.formatter.alignment_for_method_declaration=0
+org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16
+org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=80
+org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation=0
+org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_constructor_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_method_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_union_type_in_multicatch=16
+org.eclipse.jdt.core.formatter.blank_lines_after_imports=1
+org.eclipse.jdt.core.formatter.blank_lines_after_package=1
+org.eclipse.jdt.core.formatter.blank_lines_before_field=0
+org.eclipse.jdt.core.formatter.blank_lines_before_first_class_body_declaration=0
+org.eclipse.jdt.core.formatter.blank_lines_before_imports=1
+org.eclipse.jdt.core.formatter.blank_lines_before_member_type=1
+org.eclipse.jdt.core.formatter.blank_lines_before_method=1
+org.eclipse.jdt.core.formatter.blank_lines_before_new_chunk=1
+org.eclipse.jdt.core.formatter.blank_lines_before_package=0
+org.eclipse.jdt.core.formatter.blank_lines_between_import_groups=1
+org.eclipse.jdt.core.formatter.blank_lines_between_type_declarations=1
+org.eclipse.jdt.core.formatter.brace_position_for_annotation_type_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_array_initializer=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_block=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_block_in_case=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_constructor_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_enum_constant=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_enum_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_method_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_switch=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_type_declaration=end_of_line
+org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_block_comment=false
+org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_javadoc_comment=false
+org.eclipse.jdt.core.formatter.comment.format_block_comments=true
+org.eclipse.jdt.core.formatter.comment.format_header=false
+org.eclipse.jdt.core.formatter.comment.format_html=true
+org.eclipse.jdt.core.formatter.comment.format_javadoc_comments=true
+org.eclipse.jdt.core.formatter.comment.format_line_comments=true
+org.eclipse.jdt.core.formatter.comment.format_source_code=true
+org.eclipse.jdt.core.formatter.comment.indent_parameter_description=true
+org.eclipse.jdt.core.formatter.comment.indent_root_tags=true
+org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags=insert
+org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter=insert
+org.eclipse.jdt.core.formatter.comment.line_length=80
+org.eclipse.jdt.core.formatter.comment.new_lines_at_block_boundaries=true
+org.eclipse.jdt.core.formatter.comment.new_lines_at_javadoc_boundaries=true
+org.eclipse.jdt.core.formatter.comment.preserve_white_space_between_code_and_line_comments=false
+org.eclipse.jdt.core.formatter.compact_else_if=true
+org.eclipse.jdt.core.formatter.continuation_indentation=2
+org.eclipse.jdt.core.formatter.continuation_indentation_for_array_initializer=2
+org.eclipse.jdt.core.formatter.disabling_tag=@formatter\:off
+org.eclipse.jdt.core.formatter.enabling_tag=@formatter\:on
+org.eclipse.jdt.core.formatter.format_guardian_clause_on_one_line=false
+org.eclipse.jdt.core.formatter.format_line_comment_starting_on_first_column=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_annotation_declaration_header=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_constant_header=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_declaration_header=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_type_header=true
+org.eclipse.jdt.core.formatter.indent_breaks_compare_to_cases=true
+org.eclipse.jdt.core.formatter.indent_empty_lines=false
+org.eclipse.jdt.core.formatter.indent_statements_compare_to_block=true
+org.eclipse.jdt.core.formatter.indent_statements_compare_to_body=true
+org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_cases=true
+org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_switch=false
+org.eclipse.jdt.core.formatter.indentation.size=4
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_field=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_local_variable=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_method=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_package=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_parameter=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_type=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_label=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_opening_brace_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_at_end_of_file_if_missing=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_finally_in_try_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_while_in_do_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_annotation_declaration=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_anonymous_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_block=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter=insert
+org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_binary_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_paren_in_cast=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_assert=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_case=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_labeled_statement=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_allocation_expression=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_annotation=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_throws=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_constant_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_declarations=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_explicitconstructorcall_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_increments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_inits=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_throws=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_invocation_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_field_declarations=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_local_declarations=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_parameterized_type_reference=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_superinterfaces=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_ellipsis=insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_brace_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_cast=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_catch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_for=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_if=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_parenthesized_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_switch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_synchronized=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_try=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_while=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_try_resources=insert
+org.eclipse.jdt.core.formatter.insert_space_after_unary_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter=insert
+org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_binary_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_brace_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_cast=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_catch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_for=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_if=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_parenthesized_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_switch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_synchronized=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_try=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_while=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_assert=insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_case=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_default=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_labeled_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_throws=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_constant_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_declarations=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_explicitconstructorcall_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_increments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_inits=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_throws=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_invocation_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_field_declarations=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_local_declarations=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_superinterfaces=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_ellipsis=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_annotation_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_anonymous_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_block=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_constructor_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_constant=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_method_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_switch=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation_type_member_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_catch=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_if=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_parenthesized_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_switch=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_synchronized=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_try=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_while=insert
+org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_return=insert
+org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_throw=insert
+org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_semicolon=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_try_resources=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_unary_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_brackets_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_annotation_type_member_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.join_lines_in_comments=true
+org.eclipse.jdt.core.formatter.join_wrapped_lines=false
+org.eclipse.jdt.core.formatter.keep_else_statement_on_same_line=false
+org.eclipse.jdt.core.formatter.keep_empty_array_initializer_on_one_line=false
+org.eclipse.jdt.core.formatter.keep_imple_if_on_one_line=false
+org.eclipse.jdt.core.formatter.keep_then_statement_on_same_line=false
+org.eclipse.jdt.core.formatter.lineSplit=250
+org.eclipse.jdt.core.formatter.never_indent_block_comments_on_first_column=false
+org.eclipse.jdt.core.formatter.never_indent_line_comments_on_first_column=false
+org.eclipse.jdt.core.formatter.number_of_blank_lines_at_beginning_of_method_body=0
+org.eclipse.jdt.core.formatter.number_of_empty_lines_to_preserve=1
+org.eclipse.jdt.core.formatter.put_empty_statement_on_new_line=true
+org.eclipse.jdt.core.formatter.tabulation.char=space
+org.eclipse.jdt.core.formatter.tabulation.size=4
+org.eclipse.jdt.core.formatter.use_on_off_tags=false
+org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false
+org.eclipse.jdt.core.formatter.wrap_before_binary_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_or_operator_multicatch=true
+org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/.settings/org.eclipse.jdt.ui.prefs b/lttng/org.eclipse.tracecompass.lttng2.control.core/.settings/org.eclipse.jdt.ui.prefs
new file mode 100644 (file)
index 0000000..232a3fd
--- /dev/null
@@ -0,0 +1,60 @@
+eclipse.preferences.version=1
+editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true
+formatter_profile=_tmf-style
+formatter_settings_version=12
+org.eclipse.jdt.ui.exception.name=e
+org.eclipse.jdt.ui.gettersetter.use.is=true
+org.eclipse.jdt.ui.keywordthis=false
+org.eclipse.jdt.ui.overrideannotation=true
+sp_cleanup.add_default_serial_version_id=true
+sp_cleanup.add_generated_serial_version_id=false
+sp_cleanup.add_missing_annotations=false
+sp_cleanup.add_missing_deprecated_annotations=true
+sp_cleanup.add_missing_methods=false
+sp_cleanup.add_missing_nls_tags=false
+sp_cleanup.add_missing_override_annotations=true
+sp_cleanup.add_missing_override_annotations_interface_methods=true
+sp_cleanup.add_serial_version_id=false
+sp_cleanup.always_use_blocks=true
+sp_cleanup.always_use_parentheses_in_expressions=false
+sp_cleanup.always_use_this_for_non_static_field_access=false
+sp_cleanup.always_use_this_for_non_static_method_access=false
+sp_cleanup.convert_to_enhanced_for_loop=false
+sp_cleanup.correct_indentation=false
+sp_cleanup.format_source_code=false
+sp_cleanup.format_source_code_changes_only=false
+sp_cleanup.make_local_variable_final=false
+sp_cleanup.make_parameters_final=false
+sp_cleanup.make_private_fields_final=true
+sp_cleanup.make_type_abstract_if_missing_method=false
+sp_cleanup.make_variable_declarations_final=false
+sp_cleanup.never_use_blocks=false
+sp_cleanup.never_use_parentheses_in_expressions=true
+sp_cleanup.on_save_use_additional_actions=true
+sp_cleanup.organize_imports=false
+sp_cleanup.qualify_static_field_accesses_with_declaring_class=false
+sp_cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=true
+sp_cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=true
+sp_cleanup.qualify_static_member_accesses_with_declaring_class=false
+sp_cleanup.qualify_static_method_accesses_with_declaring_class=false
+sp_cleanup.remove_private_constructors=true
+sp_cleanup.remove_trailing_whitespaces=true
+sp_cleanup.remove_trailing_whitespaces_all=true
+sp_cleanup.remove_trailing_whitespaces_ignore_empty=false
+sp_cleanup.remove_unnecessary_casts=false
+sp_cleanup.remove_unnecessary_nls_tags=false
+sp_cleanup.remove_unused_imports=false
+sp_cleanup.remove_unused_local_variables=false
+sp_cleanup.remove_unused_private_fields=true
+sp_cleanup.remove_unused_private_members=false
+sp_cleanup.remove_unused_private_methods=true
+sp_cleanup.remove_unused_private_types=true
+sp_cleanup.sort_members=false
+sp_cleanup.sort_members_all=false
+sp_cleanup.use_blocks=true
+sp_cleanup.use_blocks_only_for_return_and_throw=false
+sp_cleanup.use_parentheses_in_expressions=false
+sp_cleanup.use_this_for_non_static_field_access=false
+sp_cleanup.use_this_for_non_static_field_access_only_if_necessary=true
+sp_cleanup.use_this_for_non_static_method_access=false
+sp_cleanup.use_this_for_non_static_method_access_only_if_necessary=true
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/.settings/org.eclipse.pde.api.tools.prefs b/lttng/org.eclipse.tracecompass.lttng2.control.core/.settings/org.eclipse.pde.api.tools.prefs
new file mode 100644 (file)
index 0000000..acc3abd
--- /dev/null
@@ -0,0 +1,97 @@
+ANNOTATION_ELEMENT_TYPE_ADDED_METHOD_WITHOUT_DEFAULT_VALUE=Error
+ANNOTATION_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+ANNOTATION_ELEMENT_TYPE_REMOVED_FIELD=Error
+ANNOTATION_ELEMENT_TYPE_REMOVED_METHOD=Error
+ANNOTATION_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_API_TYPE=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_API_TYPE=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_TYPE=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_TYPE=Error
+API_USE_SCAN_FIELD_SEVERITY=Error
+API_USE_SCAN_METHOD_SEVERITY=Error
+API_USE_SCAN_TYPE_SEVERITY=Error
+CLASS_ELEMENT_TYPE_ADDED_METHOD=Error
+CLASS_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
+CLASS_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+CLASS_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
+CLASS_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+CLASS_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
+CLASS_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
+CLASS_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+CLASS_ELEMENT_TYPE_REMOVED_CONSTRUCTOR=Error
+CLASS_ELEMENT_TYPE_REMOVED_FIELD=Error
+CLASS_ELEMENT_TYPE_REMOVED_METHOD=Error
+CLASS_ELEMENT_TYPE_REMOVED_SUPERCLASS=Error
+CLASS_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+CLASS_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+CONSTRUCTOR_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+CONSTRUCTOR_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+CONSTRUCTOR_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
+CONSTRUCTOR_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+ENUM_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
+ENUM_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+ENUM_ELEMENT_TYPE_REMOVED_ENUM_CONSTANT=Error
+ENUM_ELEMENT_TYPE_REMOVED_FIELD=Error
+ENUM_ELEMENT_TYPE_REMOVED_METHOD=Error
+ENUM_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+FIELD_ELEMENT_TYPE_ADDED_VALUE=Error
+FIELD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+FIELD_ELEMENT_TYPE_CHANGED_FINAL_TO_NON_FINAL_STATIC_CONSTANT=Error
+FIELD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
+FIELD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
+FIELD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
+FIELD_ELEMENT_TYPE_CHANGED_TYPE=Error
+FIELD_ELEMENT_TYPE_CHANGED_VALUE=Error
+FIELD_ELEMENT_TYPE_REMOVED_TYPE_ARGUMENT=Error
+FIELD_ELEMENT_TYPE_REMOVED_VALUE=Error
+ILLEGAL_EXTEND=Warning
+ILLEGAL_IMPLEMENT=Warning
+ILLEGAL_INSTANTIATE=Warning
+ILLEGAL_OVERRIDE=Warning
+ILLEGAL_REFERENCE=Warning
+INTERFACE_ELEMENT_TYPE_ADDED_FIELD=Error
+INTERFACE_ELEMENT_TYPE_ADDED_METHOD=Error
+INTERFACE_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
+INTERFACE_ELEMENT_TYPE_ADDED_SUPER_INTERFACE_WITH_METHODS=Error
+INTERFACE_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+INTERFACE_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
+INTERFACE_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_FIELD=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_METHOD=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+INVALID_JAVADOC_TAG=Warning
+INVALID_REFERENCE_IN_SYSTEM_LIBRARIES=Warning
+LEAK_EXTEND=Warning
+LEAK_FIELD_DECL=Warning
+LEAK_IMPLEMENT=Warning
+LEAK_METHOD_PARAM=Warning
+LEAK_METHOD_RETURN_TYPE=Warning
+METHOD_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
+METHOD_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+METHOD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+METHOD_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
+METHOD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
+METHOD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
+METHOD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
+METHOD_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
+METHOD_ELEMENT_TYPE_REMOVED_ANNOTATION_DEFAULT_VALUE=Error
+METHOD_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+MISSING_EE_DESCRIPTIONS=Ignore
+TYPE_PARAMETER_ELEMENT_TYPE_ADDED_CLASS_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_ADDED_INTERFACE_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_CLASS_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_INTERFACE_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_CLASS_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_INTERFACE_BOUND=Error
+UNUSED_PROBLEM_FILTERS=Warning
+automatically_removed_unused_problem_filters=false
+eclipse.preferences.version=1
+incompatible_api_component_version=Error
+incompatible_api_component_version_include_major_without_breaking_change=Disabled
+incompatible_api_component_version_include_minor_without_api_change=Disabled
+invalid_since_tag_version=Error
+malformed_since_tag=Error
+missing_since_tag=Error
+report_api_breakage_when_major_version_incremented=Disabled
+report_resolution_errors_api_component=Warning
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/.settings/org.eclipse.pde.prefs b/lttng/org.eclipse.tracecompass.lttng2.control.core/.settings/org.eclipse.pde.prefs
new file mode 100644 (file)
index 0000000..d92b94f
--- /dev/null
@@ -0,0 +1,32 @@
+compilers.f.unresolved-features=1
+compilers.f.unresolved-plugins=1
+compilers.incompatible-environment=1
+compilers.p.build=1
+compilers.p.build.bin.includes=1
+compilers.p.build.encodings=2
+compilers.p.build.java.compiler=2
+compilers.p.build.java.compliance=1
+compilers.p.build.missing.output=2
+compilers.p.build.output.library=1
+compilers.p.build.source.library=1
+compilers.p.build.src.includes=1
+compilers.p.deprecated=1
+compilers.p.discouraged-class=1
+compilers.p.internal=1
+compilers.p.missing-packages=1
+compilers.p.missing-version-export-package=2
+compilers.p.missing-version-import-package=2
+compilers.p.missing-version-require-bundle=2
+compilers.p.no-required-att=0
+compilers.p.not-externalized-att=1
+compilers.p.unknown-attribute=1
+compilers.p.unknown-class=1
+compilers.p.unknown-element=1
+compilers.p.unknown-identifier=1
+compilers.p.unknown-resource=1
+compilers.p.unresolved-ex-points=0
+compilers.p.unresolved-import=0
+compilers.s.create-docs=false
+compilers.s.doc-folder=doc
+compilers.s.open-tags=1
+eclipse.preferences.version=1
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/META-INF/MANIFEST.MF b/lttng/org.eclipse.tracecompass.lttng2.control.core/META-INF/MANIFEST.MF
new file mode 100644 (file)
index 0000000..9bcb35b
--- /dev/null
@@ -0,0 +1,22 @@
+Manifest-Version: 1.0
+Bundle-ManifestVersion: 2
+Bundle-Name: %Bundle-Name
+Bundle-Vendor: %Bundle-Vendor
+Bundle-Version: 1.0.0.qualifier
+Bundle-Localization: plugin
+Bundle-SymbolicName: org.eclipse.tracecompass.lttng2.control.core;singleton:=true
+Bundle-Activator: org.eclipse.tracecompass.internal.lttng2.control.core.Activator
+Bundle-ActivationPolicy: lazy
+Bundle-RequiredExecutionEnvironment: JavaSE-1.7
+Require-Bundle: org.eclipse.core.runtime,
+ org.eclipse.tracecompass.ctf.core,
+ org.eclipse.tracecompass.tmf.core,
+ org.eclipse.tracecompass.tmf.ctf.core
+Export-Package: org.eclipse.tracecompass.internal.lttng2.control.core;x-friends:="org.eclipse.tracecompass.lttng2.control.core.tests",
+ org.eclipse.tracecompass.internal.lttng2.control.core.model;x-friends:="org.eclipse.tracecompass.lttng2.control.ui,org.eclipse.tracecompass.lttng2.control.ui.tests,org.eclipse.tracecompass.lttng2.control.core.tests",
+ org.eclipse.tracecompass.internal.lttng2.control.core.model.impl;x-friends:="org.eclipse.tracecompass.lttng2.control.ui,org.eclipse.tracecompass.lttng2.control.ui.tests,org.eclipse.tracecompass.lttng2.control.core.tests",
+ org.eclipse.tracecompass.internal.lttng2.control.core.relayd;x-friends:="org.eclipse.tracecompass.lttng2.control.core.tests,org.eclipse.tracecompass.lttng2.control.ui,org.eclipse.tracecompass.lttng2.control.ui.tests",
+ org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;x-friends:="org.eclipse.tracecompass.lttng2.control.core.tests,org.eclipse.tracecompass.lttng2.control.ui,org.eclipse.tracecompass.lttng2.control.ui.tests",
+ org.eclipse.tracecompass.internal.lttng2.control.core.relayd.impl;x-friends:="org.eclipse.tracecompass.lttng2.control.core.tests,org.eclipse.tracecompass.lttng2.control.ui,org.eclipse.tracecompass.lttng2.control.ui.tests",
+ org.eclipse.tracecompass.lttng2.control.core.session
+Import-Package: com.google.common.collect
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/about.html b/lttng/org.eclipse.tracecompass.lttng2.control.core/about.html
new file mode 100644 (file)
index 0000000..c258ef5
--- /dev/null
@@ -0,0 +1,28 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"/>
+<title>About</title>
+</head>
+<body lang="EN-US">
+<h2>About This Content</h2>
+<p>June 5, 2006</p>    
+<h3>License</h3>
+
+<p>The Eclipse Foundation makes available all content in this plug-in (&quot;Content&quot;).  Unless otherwise 
+indicated below, the Content is provided to you under the terms and conditions of the
+Eclipse Public License Version 1.0 (&quot;EPL&quot;).  A copy of the EPL is available 
+at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>.
+For purposes of the EPL, &quot;Program&quot; will mean the Content.</p>
+
+<p>If you did not receive this Content directly from the Eclipse Foundation, the Content is 
+being redistributed by another party (&quot;Redistributor&quot;) and different terms and conditions may
+apply to your use of any object code in the Content.  Check the Redistributor's license that was 
+provided with the Content.  If no such license exists, contact the Redistributor.  Unless otherwise
+indicated below, the terms and conditions of the EPL still apply to any source code in the Content
+and such source code may be obtained at <a href="http://www.eclipse.org/">http://www.eclipse.org</a>.</p>
+
+</body>
+</html>
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/build.properties b/lttng/org.eclipse.tracecompass.lttng2.control.core/build.properties
new file mode 100644 (file)
index 0000000..964b6eb
--- /dev/null
@@ -0,0 +1,21 @@
+###############################################################################
+# Copyright (c) 2013, 2014 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:
+#     Ericsson - Initial API and implementation
+###############################################################################
+
+source.. = src/
+output.. = bin/
+bin.includes = META-INF/,\
+               .,\
+               about.html,\
+               plugin.properties
+src.includes = about.html
+additional.bundles = org.eclipse.jdt.annotation
+jars.extra.classpath = platform:/plugin/org.eclipse.jdt.annotation
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/plugin.properties b/lttng/org.eclipse.tracecompass.lttng2.control.core/plugin.properties
new file mode 100644 (file)
index 0000000..eb16206
--- /dev/null
@@ -0,0 +1,15 @@
+###############################################################################
+# Copyright (c) 2013, 2014 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:
+#     Ericsson - Initial API and implementation
+###############################################################################
+
+#Properties file for org.eclipse.tracecompass.lttng2.control.core
+Bundle-Vendor = Eclipse Trace Compass
+Bundle-Name = Trace Compass LTTng Control Core Plug-in
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/pom.xml b/lttng/org.eclipse.tracecompass.lttng2.control.core/pom.xml
new file mode 100644 (file)
index 0000000..7b4e07c
--- /dev/null
@@ -0,0 +1,36 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+   Copyright (C) 2011, Red Hat, Inc.
+
+   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
+-->
+<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>
+    <artifactId>org.eclipse.tracecompass.lttng-parent</artifactId>
+    <groupId>org.eclipse.tracecompass</groupId>
+    <version>1.0.0-SNAPSHOT</version>
+  </parent>
+
+  <artifactId>org.eclipse.tracecompass.lttng2.control.core</artifactId>
+  <version>1.0.0-SNAPSHOT</version>
+  <packaging>eclipse-plugin</packaging>
+
+  <name>Trace Compass LTTng Control Core Plug-in</name>
+
+ <build>
+    <plugins>
+      <plugin>
+        <groupId>org.eclipse.tycho</groupId>
+        <artifactId>tycho-source-plugin</artifactId>
+      </plugin>
+    </plugins>
+  </build>
+
+ <groupId>org.eclipse.tracecompass</groupId>
+</project>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/Activator.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/Activator.java
new file mode 100644 (file)
index 0000000..11901a7
--- /dev/null
@@ -0,0 +1,136 @@
+/*******************************************************************************
+ * Copyright (c) 2012, 2015 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:
+ *   Francois Chouinard - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.core;
+
+import org.eclipse.core.runtime.IStatus;
+import org.eclipse.core.runtime.Plugin;
+import org.eclipse.core.runtime.Status;
+import org.osgi.framework.BundleContext;
+
+/**
+ * <b><u>Activator</u></b>
+ * <p>
+ * The activator class controls the plug-in life cycle
+ */
+public class Activator extends Plugin {
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+
+    /**
+     * The plug-in ID
+     */
+    public static final String PLUGIN_ID = "org.eclipse.tracecompass.lttng2.control.core"; //$NON-NLS-1$
+
+    /**
+     * The shared instance
+     */
+    private static Activator plugin;
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+
+    /**
+     * The constructor
+     */
+    public Activator() {
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    /**
+     * Returns the shared instance
+     *
+     * @return the shared instance
+     */
+    public static Activator getDefault() {
+        return plugin;
+    }
+
+    // ------------------------------------------------------------------------
+    // Operators
+    // ------------------------------------------------------------------------
+
+    @Override
+    public void start(BundleContext context) throws Exception {
+        super.start(context);
+        plugin = this;
+    }
+
+    @Override
+    public void stop(BundleContext context) throws Exception {
+        plugin = null;
+        super.stop(context);
+    }
+
+    /**
+     * Logs a message with severity INFO in the runtime log of the plug-in.
+     *
+     * @param message A message to log
+     */
+    public void logInfo(String message) {
+        getLog().log(new Status(IStatus.INFO, PLUGIN_ID, message));
+    }
+
+    /**
+     * Logs a message and exception with severity INFO in the runtime log of the plug-in.
+     *
+     * @param message A message to log
+     * @param exception A exception to log
+     */
+    public void logInfo(String message, Throwable exception) {
+        getLog().log(new Status(IStatus.INFO, PLUGIN_ID, message, exception));
+    }
+
+    /**
+     * Logs a message and exception with severity WARNING in the runtime log of the plug-in.
+     *
+     * @param message A message to log
+     */
+    public void logWarning(String message) {
+        getLog().log(new Status(IStatus.WARNING, PLUGIN_ID, message));
+    }
+
+    /**
+     * Logs a message and exception with severity WARNING in the runtime log of the plug-in.
+     *
+     * @param message A message to log
+     * @param exception A exception to log
+     */
+    public void logWarning(String message, Throwable exception) {
+        getLog().log(new Status(IStatus.WARNING, PLUGIN_ID, message, exception));
+    }
+
+    /**
+     * Logs a message and exception with severity ERROR in the runtime log of the plug-in.
+     *
+     * @param message A message to log
+     */
+    public void logError(String message) {
+        getLog().log(new Status(IStatus.ERROR, PLUGIN_ID, message));
+    }
+
+    /**
+     * Logs a message and exception with severity ERROR in the runtime log of the plug-in.
+     *
+     * @param message A message to log
+     * @param exception A exception to log
+     */
+    public void logError(String message, Throwable exception) {
+        getLog().log(new Status(IStatus.ERROR, PLUGIN_ID, message, exception));
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/IBaseEventInfo.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/IBaseEventInfo.java
new file mode 100644 (file)
index 0000000..e231ce8
--- /dev/null
@@ -0,0 +1,89 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.core.model;
+
+import java.util.List;
+
+/**
+ * <p>
+ * Interface for retrieval of basic trace event information.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public interface IBaseEventInfo extends ITraceInfo {
+
+    /**
+     * @return the trace event type
+     */
+    TraceEventType getEventType();
+
+    /**
+     * Sets the trace event type to the given type
+     * @param type - type to set
+     */
+    void setEventType(TraceEventType type);
+
+    /**
+     * Sets the trace event type to the type specified by the given name.
+     * @param typeName - event type name
+     */
+    void setEventType(String typeName);
+
+    /**
+     * @return the trace event log level
+     */
+    TraceLogLevel getLogLevel();
+
+    /**
+     * Sets the trace event log level to the given level
+     * @param level - event log level to set
+     */
+    void setLogLevel(TraceLogLevel level);
+
+    /**
+     * Sets the trace event log level to the level specified by the given name.
+     * @param levelName - event log level name
+     */
+    void setLogLevel(String levelName);
+
+    /**
+     * Returns the field information (if exists)
+     * @return the field information or null
+     */
+    IFieldInfo[] getFields();
+
+    /**
+     * @param field The field to add
+     */
+    void addField(IFieldInfo field);
+
+    /**
+     * Sets the fields
+     * @param fields The fields
+     */
+    void setFields(List<IFieldInfo> fields);
+
+    /**
+     * Returns filter expression.
+     * @return filter expression
+     */
+    String getFilterExpression();
+
+    /**
+     * Sets the filter expression.
+     * @param filter The filter expression to set
+     */
+    void setFilterExpression(String filter);
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/IChannelInfo.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/IChannelInfo.java
new file mode 100644 (file)
index 0000000..7a32707
--- /dev/null
@@ -0,0 +1,157 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Simon Delisle - Updated for support of LTTng Tools 2.2
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.core.model;
+
+import java.util.List;
+
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.BufferType;
+
+/**
+ * <p>
+ * Interface for retrieval of trace channel information.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public interface IChannelInfo extends ITraceInfo {
+
+    // ------------------------------------------------------------------------
+    // Constants
+    // ------------------------------------------------------------------------
+    /**
+     * Default value for overwrite mode.
+     */
+    boolean DEFAULT_OVERWRITE_MODE = false;
+
+    /**
+     * @return the overwrite mode value.
+     */
+    boolean isOverwriteMode();
+    /**
+     * Sets the overwrite mode value to the given mode.
+     * @param mode - mode to set.
+     */
+    void setOverwriteMode(boolean mode);
+
+    /**
+     * @return the sub-buffer size.
+     */
+    long getSubBufferSize();
+    /**
+     * Sets the sub-buffer size to the given value.
+     * @param bufferSize - size to set to set.
+     */
+    void setSubBufferSize(long bufferSize);
+
+    /**
+     * @return the number of sub-buffers.
+     */
+    int getNumberOfSubBuffers();
+    /**
+     * Sets the number of sub-buffers to the given value.
+     * @param numberOfSubBuffers - value to set.
+     */
+    void setNumberOfSubBuffers(int numberOfSubBuffers);
+
+    /**
+     * @return the switch timer interval.
+     */
+    long getSwitchTimer();
+    /**
+     * Sets the switch timer interval to the given value.
+     * @param timer - timer value to set.
+     */
+    void setSwitchTimer(long timer);
+
+    /**
+     * @return the read timer interval.
+     */
+    long getReadTimer();
+    /**
+     * Sets the read timer interval to the given value.
+     * @param timer - timer value to set..
+     */
+    void setReadTimer(long timer);
+
+    /**
+     * @return the output type.
+     */
+    TraceChannelOutputType getOutputType();
+    /**
+     * Sets the output type to the given value.
+     * @param type - type to set.
+     */
+    void setOutputType(String type);
+    /**
+     * Sets the output type to the given value.
+     * @param type - type to set.
+     */
+    void setOutputType(TraceChannelOutputType type);
+
+    /**
+     * @return the channel state (enabled or disabled).
+     */
+    TraceEnablement getState();
+    /**
+     * Sets the channel state (enablement) to the given value.
+     * @param state - state to set.
+     */
+    void setState(TraceEnablement state);
+    /**
+     * Sets the channel state (enablement) to the value specified by the given name.
+     * @param stateName - state to set.
+     */
+    void setState(String stateName);
+
+    /**
+     * @return all event information as array.
+     */
+    IEventInfo[] getEvents();
+    /**
+     * Sets the event information specified by given list.
+     * @param events - all event information to set.
+     */
+    void setEvents(List<IEventInfo> events);
+    /**
+     * Adds a single event information.
+     * @param event - event information to add.
+     */
+    void addEvent(IEventInfo event);
+    /**
+     * Sets the maximum size of trace files
+     * @param maxSizeTraceFiles - maximum size
+     */
+    void setMaxSizeTraceFiles(long maxSizeTraceFiles);
+    /**
+     * Sets the maximum number of trace files
+     * @param maxNumberTraceFiles - maximum number
+     */
+    void setMaxNumberTraceFiles(int maxNumberTraceFiles);
+    /**
+     * @return maximum size of trace files
+     */
+    long getMaxSizeTraceFiles();
+    /**
+     * @return maximum number of trace files
+     */
+    int getMaxNumberTraceFiles();
+    /**
+     * Sets per UID buffers
+     * @param buffersUID - enable or not
+     */
+    void setBufferType(BufferType buffersUID);
+    /**
+     * @return the value of buffersUID (enable or not)
+     */
+    BufferType getBufferType();
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/IDomainInfo.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/IDomainInfo.java
new file mode 100644 (file)
index 0000000..70b399e
--- /dev/null
@@ -0,0 +1,69 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.core.model;
+
+import java.util.List;
+
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.BufferType;
+
+/**
+ * <p>
+ * Interface for retrieval of trace domain information.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public interface IDomainInfo extends ITraceInfo {
+
+    /**
+     * @return information about all channels
+     */
+    IChannelInfo[] getChannels();
+
+    /**
+     * Sets the channel information specified by given list.
+     * @param channels - all channel information to set.
+     */
+    void setChannels(List<IChannelInfo> channels);
+
+    /**
+     * Adds a single channel information.
+     * @param channel - channel information to add.
+     */
+    void addChannel(IChannelInfo channel);
+
+    /**
+     * @return true if domain is kernel, false for UST
+     */
+    boolean isKernel();
+
+    /**
+     * Sets whether domain is  Kernel domain or UST
+     * @param isKernel true for kernel, false for UST
+     */
+    void setIsKernel(boolean isKernel);
+
+    /**
+     * @return Information about the buffer type
+     */
+    BufferType getBufferType();
+
+    /**
+     * Sets the buffer type
+     *
+     * @param bufferType
+     *            The buffer type
+     */
+    void setBufferType(BufferType bufferType);
+
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/IEventInfo.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/IEventInfo.java
new file mode 100644 (file)
index 0000000..86b423b
--- /dev/null
@@ -0,0 +1,58 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.core.model;
+
+/**
+ * <p>
+ * Interface for retrieval of trace event information.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public interface IEventInfo extends IBaseEventInfo {
+
+    /**
+     * @return the event state (enabled or disabled).
+     */
+    TraceEnablement getState();
+
+    /**
+     * Sets the event state (enablement) to the given value.
+     * @param state - state to set.
+     */
+    void setState(TraceEnablement state);
+
+    /**
+     * Sets the event state (enablement) to the value specified by the given name.
+     * @param stateName - state to set.
+     */
+    void setState(String stateName);
+
+    /**
+     * Returns the log level type.
+     * @return log level type.
+     */
+    LogLevelType getLogLevelType();
+
+    /**
+     * Sets the LogLevelType.
+     * @param type - log level type
+     */
+    void setLogLevelType(LogLevelType type);
+
+    /**
+     * Sets the LogLevelType based on given short name.
+     * @param shortName - short name of type
+     */
+    void setLogLevelType(String shortName);
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/IFieldInfo.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/IFieldInfo.java
new file mode 100644 (file)
index 0000000..4e1db84
--- /dev/null
@@ -0,0 +1,34 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.core.model;
+
+/**
+ * <p>
+ * Interface for retrieval of event field information.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public interface IFieldInfo extends ITraceInfo {
+
+    /**
+     * @return the event field type
+     */
+    String getFieldType();
+
+    /**
+     * Sets field type string
+     *
+     * @param fieldType - sting of event field type
+     */
+    void setFieldType(String fieldType);
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/IProbeEventInfo.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/IProbeEventInfo.java
new file mode 100644 (file)
index 0000000..c397e97
--- /dev/null
@@ -0,0 +1,55 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.core.model;
+
+/**
+ * <p>
+ * Interface for retrieval of probe event information.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public interface IProbeEventInfo extends IEventInfo {
+
+    /**
+     * @return the address of the probe. (null if not used)
+     */
+    String getAddress();
+
+    /**
+     * Sets the address of the probe.
+     * @param address - a address (null if not used)
+     */
+    void setAddress(String address);
+
+    /**
+     * @return the offset applied to the symbol (null if not used).
+     */
+    String getOffset();
+
+    /**
+     * Sets the offset applied to the symbol.
+     * @param offset - a offset ((null if not used)
+     */
+    void setOffset(String offset);
+
+    /**
+     * @return the symbol name. ((null if not used))
+     */
+    String getSymbol();
+
+    /**
+     * Sets the symbol name.
+     * @param symbol - a symbol name ((null if not used))
+     */
+    void setSymbol(String symbol);
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/ISessionInfo.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/ISessionInfo.java
new file mode 100644 (file)
index 0000000..c5ce569
--- /dev/null
@@ -0,0 +1,222 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
+ *   Marc-Andre Laperle - Support for creating a live session
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.core.model;
+
+import java.util.List;
+
+/**
+ * <p>
+ * Interface for retrieval of trace session information.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public interface ISessionInfo extends ITraceInfo {
+
+    /**
+     * @return the session state state (active or inactive).
+     */
+    TraceSessionState getSessionState();
+    /**
+     * Sets the session state  to the given value.
+     * @param state - state to set.
+     */
+    void setSessionState(TraceSessionState state);
+
+    /**
+     * Sets the event state to the value specified by the given name.
+     * @param stateName - state to set.
+     */
+    void setSessionState(String stateName);
+
+    /**
+     * @return path string where session is located.
+     */
+    String getSessionPath();
+
+    /**
+     * Sets the path string (where session is located) to the given value.
+     * @param path - session path to set.
+     */
+    void setSessionPath(String path);
+
+    /**
+     * @return all domain information as array.
+     */
+    IDomainInfo[] getDomains();
+
+    /**
+     * Sets all domain information specified by given list.
+     * @param domains - all domain information to set.
+     */
+    void setDomains(List<IDomainInfo> domains);
+
+    /**
+     * Adds a single domain information.
+     * @param domainInfo domain information to add.
+     */
+    void addDomain(IDomainInfo domainInfo);
+
+    /**
+     * Returns if session is streamed over network
+     * @return <code>true</code> if streamed over network else <code>false</code>
+     */
+    boolean isStreamedTrace();
+
+    /**
+     * Sets whether the trace is streamed or not
+     * @param isStreamedTrace <code>true</code> if streamed over network else <code>false</code>
+     */
+    void setStreamedTrace(boolean isStreamedTrace);
+
+    /**
+     * Returns whether the session is snapshot session or not
+     * @return <code>true</code> if it is snapshot session else <code>false</code>
+     */
+    boolean isSnapshotSession();
+
+    /**
+     * Set whether or not the session should be in snapshot mode
+     *
+     * @param isSnapshot
+     *            true for snapshot mode, false otherwise
+     */
+    void setSnapshot(boolean isSnapshot);
+
+    /**
+     * Gets the snapshot information the session or null if it is not a
+     * snapshot session.
+     * @return snapshot information
+     */
+    ISnapshotInfo getSnapshotInfo();
+
+    /**
+     * Sets the snapshot information of the session
+     * @param setSnapshotInfo - the snapshot data to set.
+     */
+    void setSnapshotInfo(ISnapshotInfo setSnapshotInfo);
+
+    /**
+     * Get whether or not the session should be in Live mode
+     *
+     * @return <code>true</code> if is a live session else <code>false</code>
+     */
+    public boolean isLive();
+
+    /**
+     * Set whether or not the session should be in Live mode
+     *
+     * @param isLive
+     *            true for Live mode, false otherwise
+     */
+    public void setLive(boolean isLive);
+
+    /**
+     * Get the live delay which is the delay in micro seconds before the data is
+     * flushed and streamed.
+     *
+     * @return the live delay or -1 if the default value should be used
+     */
+    public long getLiveDelay();
+
+    /**
+     * Set the live delay which is the delay in micro seconds before the data is
+     * flushed and streamed.
+     *
+     * @param liveDelay
+     *            the live delay
+     */
+    public void setLiveDelay(long liveDelay);
+
+    /**
+     * Get the network URL in case control and data is configured together
+     * otherwise null If it returns a non-null value, getControlUrl() and
+     * getDataUrl() have to return null.
+     *
+     * @return The network URL or null.
+     */
+    String getNetworkUrl();
+
+    /**
+     * Set the network URL
+     *
+     * @param networkUrl
+     *            the network URL
+     */
+    void setNetworkUrl(String networkUrl);
+
+    /**
+     * Get the control URL in case control and data is configured separately. If
+     * it returns a non-null value, getDataUrl() has to return a valid value too
+     * and getNetworkUrl() has to return null.
+     *
+     * @return The control URL or null.
+     */
+    String getControlUrl();
+
+    /**
+     * Set the control URL
+     *
+     * @param controlUrl
+     *            the control URL
+     */
+    void setControlUrl(String controlUrl);
+
+    /**
+     * Get the data URL in case control and data is configured separately. If it
+     * returns a non-null value, getControlUrl() has to return a valid value too
+     * and getNetworkUrl() has to return null.
+     *
+     * @return The data URL or null.
+     */
+    String getDataUrl();
+
+    /**
+     * Set the data URL
+     *
+     * @param datalUrl
+     *            the data URL
+     */
+    void setDataUrl(String datalUrl);
+
+    /**
+     * Get the live URL.
+     *
+     * @return the live URL
+     */
+    String getLiveUrl();
+
+    /**
+     * Set the live URL.
+     *
+     * @param liveUrl
+     *            the live URL
+     */
+    void setLiveUrl(String liveUrl);
+
+    /**
+     * Get the live port.
+     *
+     * @return the live port
+     */
+    Integer getLivePort();
+
+    /**
+     * Set the live port.
+     *
+     * @param livePort
+     *            the live port
+     */
+    void setLivePort(Integer livePort);
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/ISnapshotInfo.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/ISnapshotInfo.java
new file mode 100644 (file)
index 0000000..852ae54
--- /dev/null
@@ -0,0 +1,62 @@
+/**********************************************************************
+ * Copyright (c) 2013, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.core.model;
+
+
+/**
+ * <p>
+ * Interface for retrieval of snapshot information of a session.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public interface ISnapshotInfo extends ITraceInfo {
+
+    /**
+     * @return path string where snapshot is located.
+     */
+    String getSnapshotPath();
+
+    /**
+     * Sets the path string (where snapshot is located) to the given value.
+     * @param path - session path to set.
+     */
+    void setSnapshotPath(String path);
+
+    /**
+     * @return the snapshot ID.
+     */
+    int getId();
+
+    /**
+     * Sets the snapshot ID.
+     * @param id - the ID to set.
+     */
+    void setId(int id);
+
+    /**
+     * Sets whether snapshot is streamed over the network or stored locally
+     * at the tracers host.
+     *
+     * @param isStreamed - <code>true</code> if streamed else <code>false</code>
+     */
+    void setStreamedSnapshot(boolean isStreamed);
+
+    /**
+     * Gets whether snapshot is streamed over the network or stored locally
+     * at the tracers host.
+     *
+     * @return <code>true</code> if streamed else <code>false</code>
+     */
+    boolean isStreamedSnapshot();
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/ITraceInfo.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/ITraceInfo.java
new file mode 100644 (file)
index 0000000..1c4bd6c
--- /dev/null
@@ -0,0 +1,35 @@
+/**********************************************************************
+ * Copyright (c) 2013, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.core.model;
+
+/**
+ * <p>
+ * Interface for retrieve trace comon information.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public interface ITraceInfo {
+    /**
+     * @return the name of the information element.
+     */
+    String getName();
+
+    /**
+     * Sets the name of the information element.
+     *
+     * @param name
+     *            The name to assign
+     */
+    void setName(String name);
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/IUstProviderInfo.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/IUstProviderInfo.java
new file mode 100644 (file)
index 0000000..cc2c282
--- /dev/null
@@ -0,0 +1,52 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.core.model;
+
+import java.util.List;
+
+/**
+ * <p>
+ * Interface for retrieval of UST provider information.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public interface IUstProviderInfo extends ITraceInfo {
+
+    /**
+     * @return the process ID of the UST provider.
+     */
+    int getPid();
+
+    /**
+     * Sets the process ID of the UST provider to the given value.
+     * @param pid - process ID to set
+     */
+    void setPid(int pid);
+
+    /**
+     * @return all event information as array.
+     */
+    IBaseEventInfo[] getEvents();
+
+    /**
+     * Sets the event information specified by given list.
+     * @param events - all event information to set.
+     */
+    void setEvents(List<IBaseEventInfo> events);
+
+    /**
+     * Adds a single event information.
+     * @param event - event information to add.
+     */
+    void addEvent(IBaseEventInfo event);
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/LogLevelType.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/LogLevelType.java
new file mode 100644 (file)
index 0000000..d152e10
--- /dev/null
@@ -0,0 +1,104 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.core.model;
+
+
+/**
+ * Type of log Level enumeration.
+ *
+ * @author Bernd Hufmann
+ */
+public enum LogLevelType {
+
+    // ------------------------------------------------------------------------
+    // Enum definition
+    // ------------------------------------------------------------------------
+    /** range of log levels [0,logLevel] */
+    LOGLEVEL("<=", "RANGE"), //$NON-NLS-1$ //$NON-NLS-2$
+
+    /** all log level */
+    LOGLEVEL_ALL("", "ALL"), //$NON-NLS-1$//$NON-NLS-2$
+
+    /** single log level */
+    LOGLEVEL_ONLY("==", "SINGLE"), //$NON-NLS-1$ //$NON-NLS-2$
+
+    /** no log level */
+    LOGLEVEL_NONE("", "UNKNOWN"); //$NON-NLS-1$ //$NON-NLS-2$
+
+    // ------------------------------------------------------------------------
+    // Constuctors
+    // ------------------------------------------------------------------------
+
+    /**
+     * Private constructor
+     *
+     * @param name
+     *            the name of state
+     */
+    private LogLevelType(String shortName, String miName) {
+        fShortName = shortName;
+        fMiName = miName;
+    }
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+    /**
+     * Name of enum.
+     */
+    private final String fShortName;
+    private final String fMiName;
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+    /**
+     * @return short string
+     */
+    public String getShortName() {
+        return fShortName;
+    }
+
+    /**
+     * @return machine interface name string
+     */
+    public String getMiName() {
+        return fMiName;
+    }
+
+    // ------------------------------------------------------------------------
+    // Utility
+    // ------------------------------------------------------------------------
+    /**
+     * Return the corresponding {@link LogLevelType} to String "name"
+     *
+     * @param name
+     *            String to compare to retrieve the good LogLevelType
+     * @return the corresponding {@link LogLevelType}
+     */
+    public static LogLevelType valueOfString(String name) {
+        if (name == null) {
+            throw new IllegalArgumentException();
+        }
+        for (LogLevelType lltype : LogLevelType.values()) {
+            if (!lltype.equals(LOGLEVEL_NONE)) {
+                boolean isEqual = lltype.fShortName.equalsIgnoreCase(name) || lltype.fMiName.equalsIgnoreCase(name);
+                if (isEqual) {
+                    return lltype;
+                }
+            }
+        }
+
+        // No match
+        return LogLevelType.LOGLEVEL_NONE;
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/TargetNodeState.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/TargetNodeState.java
new file mode 100644 (file)
index 0000000..1dbf95f
--- /dev/null
@@ -0,0 +1,30 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.core.model;
+
+/**
+ * <p>
+ *  Enumeration for the node connection state.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public enum TargetNodeState {
+     /** State when disconnected */
+    DISCONNECTED,
+     /** State while disconnecting */
+    DISCONNECTING,
+     /** State when connected */
+    CONNECTED,
+     /** State while connecting */
+    CONNECTING;
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/TraceChannelOutputType.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/TraceChannelOutputType.java
new file mode 100644 (file)
index 0000000..5b1cc97
--- /dev/null
@@ -0,0 +1,74 @@
+/**********************************************************************
+ * Copyright (c) 2014 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:
+ *   Jonathan Rajotte - Initial API and implementation
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.core.model;
+
+/**
+ * Trace domain type enumeration.
+ *
+ * @author Jonathan Rajotte
+ */
+public enum TraceChannelOutputType {
+    /** Channel output type : splice */
+    SPLICE("splice()", "SPLICE" ), //$NON-NLS-1$ //$NON-NLS-2$
+    /** Channel output type : mmap */
+    MMAP("mmap()", "MMAP"), //$NON-NLS-1$ //$NON-NLS-2$
+    /** Channel output type : unknown */
+    UNKNOWN("unknown", "unknown"); //$NON-NLS-1$ //$NON-NLS-2$
+
+    private final String fInName;
+    private final String fInMiName;
+
+    private TraceChannelOutputType(String name, String miName) {
+        fInName = name;
+        fInMiName = miName;
+    }
+
+    /**
+     * Get the type's name
+     *
+     * @return The type's name
+     */
+    public String getInName() {
+        return fInName;
+    }
+
+    /**
+     * Get the type's name
+     *
+     * @return The type's name
+     */
+    public String getInMiName() {
+        return fInMiName;
+    }
+
+    /**
+     * Return the corresponding {@link TraceChannelOutputType} of string miName
+     *
+     * @param name
+     *            name of the Trace domain type to look for
+     * @return the corresponding {@link TraceChannelOutputType}
+     */
+    public static TraceChannelOutputType valueOfString(String name) {
+        if (name == null) {
+            throw new IllegalArgumentException();
+        }
+        for (TraceChannelOutputType tdType : TraceChannelOutputType.values()) {
+            boolean isEqual = tdType.getInName().equalsIgnoreCase(name) || tdType.getInMiName().equalsIgnoreCase(name);
+            if (isEqual) {
+                return tdType;
+            }
+        }
+        // Unknown domain
+        return UNKNOWN;
+    }
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/TraceDomainType.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/TraceDomainType.java
new file mode 100644 (file)
index 0000000..3cd690f
--- /dev/null
@@ -0,0 +1,64 @@
+/**********************************************************************
+ * Copyright (c) 2014 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:
+ *   Jonathan Rajotte - Initial API and implementation
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.core.model;
+
+/**
+ * Trace domain type enumeration.
+ *
+ * @author Jonathan Rajotte
+ */
+public enum TraceDomainType {
+    /** Domain type : ust */
+    UST("ust"), //$NON-NLS-1$
+    /** Domain type : kernel */
+    KERNEL("kernel"), //$NON-NLS-1$
+    /** Domain type : jul */
+    JUL("jul"), //$NON-NLS-1$
+    /** Unknown domain type */
+    UNKNOWN("Unknown domain type"); //$NON-NLS-1$
+
+    private final String fInName;
+
+    private TraceDomainType(String name) {
+        fInName = name;
+    }
+
+    /**
+     * Get the type's name
+     *
+     * @return The type's name
+     */
+    public String getInName() {
+        return fInName;
+    }
+
+    /**
+     * Return the corresponding {@link TraceDomainType} of string miName
+     *
+     * @param miName
+     *            name of the Trace domain type to look for
+     * @return the corresponding {@link TraceDomainType}
+     */
+    public static TraceDomainType valueOfString(String miName) {
+        if (miName == null) {
+            throw new IllegalArgumentException();
+        }
+        for (TraceDomainType tdType : TraceDomainType.values()) {
+            if (tdType.getInName().equalsIgnoreCase(miName)) {
+                return tdType;
+            }
+        }
+        // Unknown domain
+        return UNKNOWN;
+    }
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/TraceEnablement.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/TraceEnablement.java
new file mode 100644 (file)
index 0000000..b2abe49
--- /dev/null
@@ -0,0 +1,91 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Jonathan Rajotte - Machine interface support and utility function
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.core.model;
+
+import java.security.InvalidParameterException;
+
+/**
+ * Enumeration for enabled/disabled states.
+ *
+ * @author Bernd Hufmann
+ */
+public enum TraceEnablement {
+
+    // ------------------------------------------------------------------------
+    // Enum definition
+    // ------------------------------------------------------------------------
+    /** Tracing is disabled */
+    DISABLED("disabled", "false"), //$NON-NLS-1$ //$NON-NLS-2$
+    /** Tracing is enabled */
+    ENABLED("enabled", "true"); //$NON-NLS-1$ //$NON-NLS-2$
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+    /**
+     * Name of enum
+     */
+    private final String fInName;
+    private final String fInMiName;
+
+    // ------------------------------------------------------------------------
+    // Constuctors
+    // ------------------------------------------------------------------------
+
+    /**
+     * Private constructor
+     *
+     * @param name
+     *            the name of state
+     */
+    private TraceEnablement(String name, String miName) {
+        fInName = name;
+        fInMiName = miName;
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+    /**
+     * @return state name
+     */
+    public String getInName() {
+        return fInName;
+    }
+
+    /**
+     * @return state name
+     */
+    public String getInMiName() {
+        return fInMiName;
+    }
+
+    /**
+     * @param name
+     *            name of the desired enum
+     * @return the corresponding {@link TraceEnablement} matching name
+     */
+    public static TraceEnablement valueOfString(String name) {
+        if (name == null) {
+            throw new InvalidParameterException();
+        }
+        for (TraceEnablement enablementType : TraceEnablement.values()) {
+            boolean exist = enablementType.fInName.equalsIgnoreCase(name) || enablementType.fInMiName.equalsIgnoreCase(name);
+            if (exist) {
+                return enablementType;
+            }
+        }
+        return DISABLED;
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/TraceEventType.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/TraceEventType.java
new file mode 100644 (file)
index 0000000..c6327f3
--- /dev/null
@@ -0,0 +1,65 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.core.model;
+
+/**
+ * Trace event type enumeration.
+ *
+ * @author Bernd Hufmann
+ */
+public enum TraceEventType {
+    /** Event type: tracepoint */
+    TRACEPOINT("tracepoint"), //$NON-NLS-1$
+    /** Event type: syscall */
+    SYSCALL("syscall"), //$NON-NLS-1$
+    /** Event type: probe */
+    PROBE("probe"), //$NON-NLS-1$
+    /** Event type: function */
+    FUNCTION("function"), //$NON-NLS-1$
+    /** Event type unknown */
+    UNKNOWN("unknown"); //$NON-NLS-1$
+
+    private final String fInName;
+
+    private TraceEventType(String name) {
+        fInName = name;
+    }
+
+    /**
+     * Get the type's name
+     *
+     * @return The type's name
+     */
+    public String getInName() {
+        return fInName;
+    }
+
+    /**
+     * Return the corresponding {@link TraceEventType} of string miName
+     *
+     * @param name
+     *            name of the {@link TraceEventType} to look for
+     * @return the corresponding {@link TraceEventType}
+     */
+    public static TraceEventType valueOfString(String name) {
+        if (name == null) {
+            throw new IllegalArgumentException();
+        }
+        for (TraceEventType teType : TraceEventType.values()) {
+            if (teType.getInName().equalsIgnoreCase(name)) {
+                return teType;
+            }
+        }
+        return UNKNOWN;
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/TraceLogLevel.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/TraceLogLevel.java
new file mode 100644 (file)
index 0000000..8ce9d76
--- /dev/null
@@ -0,0 +1,114 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Jonathan Rajotte - Utility function
+ *********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.core.model;
+
+
+/**
+ * Log Level enumeration.
+ *
+ * @author Bernd Hufmann
+ */
+@SuppressWarnings("nls")
+public enum TraceLogLevel {
+
+    // ------------------------------------------------------------------------
+    // Enum definition
+    // ------------------------------------------------------------------------
+    /** Log level 0 */
+    TRACE_EMERG("TRACE_EMERG"),
+    /** Log level 1 */
+    TRACE_ALERT("TRACE_ALERT"),
+    /** Log level 2 */
+    TRACE_CRIT("TRACE_CRIT"),
+    /** Log level 3 */
+    TRACE_ERR("TRACE_ERR"),
+    /** Log level 4 */
+    TRACE_WARNING("TRACE_WARNING"),
+    /** Log level 5 */
+    TRACE_NOTICE("TRACE_NOTICE"),
+    /** Log level 6 */
+    TRACE_INFO("TRACE_INFO"),
+    /** Log level 7 */
+    TRACE_DEBUG_SYSTEM("TRACE_DEBUG_SYSTEM"),
+    /** Log level 8 */
+    TRACE_DEBUG_PROGRAM("TRACE_DEBUG_PROGRAM"),
+    /** Log level 9 */
+    TRACE_DEBUG_PROCESS("TRACE_DEBUG_PROCESS"),
+    /** Log level 10 */
+    TRACE_DEBUG_MODULE("TRACE_DEBUG_MODULE"),
+    /** Log level 11 */
+    TRACE_DEBUG_UNIT("TRACE_DEBUG_UNIT"),
+    /** Log level 12 */
+    TRACE_DEBUG_FUNCTION("TRACE_DEBUG_FUNCTION"),
+    /** Log level 13 */
+    TRACE_DEBUG_LINE("TRACE_DEBUG_LINE"),
+    /** Log level 14 */
+    TRACE_DEBUG("TRACE_DEBUG"),
+    /** Log level 15 */
+    LEVEL_UNKNOWN("LEVEL_UNKNOWN");
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+    /**
+     * Name of enum.
+     */
+    private final String fInName;
+
+    // ------------------------------------------------------------------------
+    // Constuctors
+    // ------------------------------------------------------------------------
+
+    /**
+     * Private constructor
+     *
+     * @param name
+     *            the name of state
+     */
+    private TraceLogLevel(String name) {
+        fInName = name;
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+    /**
+     * @return state name
+     */
+    public String getInName() {
+        return fInName;
+    }
+
+    // ------------------------------------------------------------------------
+    // Utility
+    // ------------------------------------------------------------------------
+    /**
+     * Return the corresponding {@link TraceLogLevel} to String "name"
+     *
+     * @param name
+     *            String to compare to retrieve the good {@link TraceLogLevel}
+     * @return the corresponding {@link TraceLogLevel}
+     */
+    public static TraceLogLevel valueOfString(String name) {
+        if (name == null) {
+            throw new IllegalArgumentException();
+        }
+        for (TraceLogLevel tllevel : TraceLogLevel.values()) {
+            if (tllevel.getInName().equalsIgnoreCase(name)) {
+                return tllevel;
+            }
+        }
+        // No match
+        return LEVEL_UNKNOWN;
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/TraceSessionState.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/TraceSessionState.java
new file mode 100644 (file)
index 0000000..d83de83
--- /dev/null
@@ -0,0 +1,96 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Jonathan Rajotte - machine interface support and utility function
+ *********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.core.model;
+
+/**
+ * Session state enumeration.
+ *
+ * @author Bernd Hufmann
+ */
+public enum TraceSessionState {
+
+    // ------------------------------------------------------------------------
+    // Enum definition
+    // ------------------------------------------------------------------------
+    /** Trace session inactive */
+    INACTIVE("inactive", "false"), //$NON-NLS-1$ //$NON-NLS-2$
+    /** Trace session active */
+    ACTIVE("active", "true"); //$NON-NLS-1$ //$NON-NLS-2$
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+    /**
+     * Name of enum.
+     */
+    private final String fInName;
+    private final String fMiName;
+
+    // ------------------------------------------------------------------------
+    // Constuctors
+    // ------------------------------------------------------------------------
+
+    /**
+     * Private constructor
+     *
+     * @param name
+     *            the name of state
+     */
+    private TraceSessionState(String name, String miName) {
+        fInName = name;
+        fMiName = miName;
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+    /**
+     * @return state name
+     */
+    public String getInName() {
+        return fInName;
+    }
+
+    /**
+     * @return the machine interface name
+     */
+    public String getfMiName() {
+        return fMiName;
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+    /**
+     * Return the corresponding {@link TraceSessionState} to String "name"
+     *
+     * @param name
+     *            String to compare to retrieve the good
+     *            {@link TraceSessionState}
+     * @return the corresponding {@link TraceSessionState}
+     */
+    public static TraceSessionState valueOfString(String name) {
+        if (name == null) {
+            return INACTIVE;
+        }
+        for (TraceSessionState tst : TraceSessionState.values()) {
+            boolean isEqual = tst.fInName.equalsIgnoreCase(name) || tst.fMiName.equalsIgnoreCase(name);
+            if (isEqual) {
+                return tst;
+            }
+        }
+        // No match
+        return INACTIVE;
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/BaseEventInfo.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/BaseEventInfo.java
new file mode 100644 (file)
index 0000000..e6ed96a
--- /dev/null
@@ -0,0 +1,223 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.core.model.impl;
+
+import java.util.ArrayList;
+import java.util.Iterator;
+import java.util.List;
+
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IBaseEventInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IFieldInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEventType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
+
+/**
+* <p>
+* Implementation of the basic trace event interface (IEventInfo) to store event
+* related data.
+* </p>
+*
+* @author Bernd Hufmann
+*/
+public class BaseEventInfo extends TraceInfo implements IBaseEventInfo {
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+    /**
+     * The trace event type.
+     */
+    private TraceEventType fEventType = TraceEventType.UNKNOWN;
+    /**
+     * The trace log level.
+     */
+    private TraceLogLevel fLogLevel = TraceLogLevel.TRACE_DEBUG;
+    /**
+     * The Event fields
+     */
+    private final List<IFieldInfo> fFields = new ArrayList<>();
+    /**
+     * The filter expression.
+     */
+    private String fFilterExpression;
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+    /**
+     * Constructor
+     * @param name - name of base event
+     */
+    public BaseEventInfo(String name) {
+        super(name);
+    }
+
+    /**
+     * Copy constructor
+     * @param other - the instance to copy
+     */
+    public BaseEventInfo(BaseEventInfo other) {
+        super(other);
+        fEventType = other.fEventType;
+        fLogLevel = other.fLogLevel;
+        for (Iterator<IFieldInfo> iterator = other.fFields.iterator(); iterator.hasNext();) {
+            IFieldInfo field = iterator.next();
+            if (field instanceof FieldInfo) {
+                fFields.add(new FieldInfo((FieldInfo)field));
+            } else {
+                fFields.add(field);
+            }
+        }
+        fFilterExpression = other.fFilterExpression;
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    @Override
+    public TraceEventType getEventType() {
+        return fEventType;
+    }
+
+    @Override
+    public void setEventType(TraceEventType type) {
+        fEventType = type;
+    }
+
+    @Override
+    public void setEventType(String typeName) {
+        if(TraceEventType.TRACEPOINT.getInName().equalsIgnoreCase(typeName)) {
+            fEventType = TraceEventType.TRACEPOINT;
+        } else if(TraceEventType.SYSCALL.getInName().equalsIgnoreCase(typeName)) {
+            fEventType = TraceEventType.SYSCALL;
+        } else if (TraceEventType.PROBE.getInName().equalsIgnoreCase(typeName)) {
+            fEventType = TraceEventType.PROBE;
+        } else if (TraceEventType.FUNCTION.getInName().equalsIgnoreCase(typeName)) {
+            fEventType = TraceEventType.FUNCTION;
+        } else {
+            fEventType = TraceEventType.UNKNOWN;
+        }
+    }
+
+    @Override
+    public TraceLogLevel getLogLevel() {
+        return fLogLevel;
+    }
+
+    @Override
+    public void setLogLevel(TraceLogLevel level) {
+        fLogLevel = level;
+    }
+
+    @Override
+    public void setLogLevel(String levelName) {
+        fLogLevel = TraceLogLevel.valueOfString(levelName);
+    }
+
+    @Override
+    public IFieldInfo[] getFields() {
+        return fFields.toArray(new IFieldInfo[fFields.size()]);
+    }
+
+    @Override
+    public void addField(IFieldInfo field) {
+        fFields.add(field);
+    }
+
+    @Override
+    public void setFields(List<IFieldInfo> fields) {
+        fFields.clear();
+        for (Iterator<IFieldInfo> iterator = fields.iterator(); iterator.hasNext();) {
+            IFieldInfo fieldInfo = iterator.next();
+            fFields.add(fieldInfo);
+        }
+    }
+
+    @Override
+    public String getFilterExpression() {
+        return fFilterExpression;
+    }
+
+    @Override
+    public void setFilterExpression(String filter) {
+        fFilterExpression = filter;
+    }
+
+    @Override
+    public int hashCode() {
+        final int prime = 31;
+        int result = super.hashCode();
+        result = prime * result + ((fEventType == null) ? 0 : fEventType.hashCode());
+        result = prime * result + fFields.hashCode();
+        result = prime * result + ((fFilterExpression == null) ? 0 : fFilterExpression.hashCode());
+        result = prime * result + ((fLogLevel == null) ? 0 : fLogLevel.hashCode());
+        return result;
+    }
+
+    @Override
+    public boolean equals(Object obj) {
+        if (this == obj) {
+            return true;
+        }
+        if (!super.equals(obj)) {
+            return false;
+        }
+        if (getClass() != obj.getClass()) {
+            return false;
+        }
+        BaseEventInfo other = (BaseEventInfo) obj;
+        if (fEventType != other.fEventType) {
+            return false;
+        }
+        if (!fFields.equals(other.fFields)) {
+            return false;
+        }
+        if (fFilterExpression == null) {
+            if (other.fFilterExpression != null) {
+                return false;
+            }
+        } else if (!fFilterExpression.equals(other.fFilterExpression)) {
+            return false;
+        }
+        if (fLogLevel != other.fLogLevel) {
+            return false;
+        }
+        return true;
+    }
+
+    @SuppressWarnings("nls")
+    @Override
+    public String toString() {
+        StringBuffer output = new StringBuffer();
+            output.append("[BaseEventInfo(");
+            output.append(super.toString());
+            output.append(",type=");
+            output.append(fEventType);
+            output.append(",level=");
+            output.append(fLogLevel);
+            if (!fFields.isEmpty()) {
+                output.append(",Fields=");
+                for (Iterator<IFieldInfo> iterator = fFields.iterator(); iterator.hasNext();) {
+                    IFieldInfo field = iterator.next();
+                    output.append(field.toString());
+                }
+            }
+            if (fFilterExpression != null) {
+                output.append(",Filter=");
+                output.append(fFilterExpression);
+            }
+            output.append(")]");
+            return output.toString();
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/BufferType.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/BufferType.java
new file mode 100644 (file)
index 0000000..2f06600
--- /dev/null
@@ -0,0 +1,116 @@
+/**********************************************************************
+ * Copyright (c) 2013, 2014 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:
+ *   Simon Delisle - Initial API and implementation
+ *   Bernd Hufmann - Updated to enum definition
+ *   Jonathan Rajotte - Updated enum definition for lttng machine interface
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.core.model.impl;
+
+/**
+ * Constants for buffer type.
+ *
+ * @author Simon Delisle
+ * @author Bernd Hufmann
+ */
+
+public enum BufferType {
+    // ------------------------------------------------------------------------
+    // Enum definition
+    // ------------------------------------------------------------------------
+    /**
+     * Buffer type : per UID
+     */
+    BUFFER_PER_UID("per UID", "PER_UID"), //$NON-NLS-1$ //$NON-NLS-2$
+    /**
+     * Buffer type : per PID
+     */
+    BUFFER_PER_PID("per PID", "PER_PID"), //$NON-NLS-1$ //$NON-NLS-2$
+    /**
+     * Buffer type : shared
+     */
+    BUFFER_SHARED("shared"), //$NON-NLS-1$
+    /**
+     * If the LTTng version doesn't show the buffer type
+     */
+    BUFFER_TYPE_UNKNOWN("information not unavailable"); //$NON-NLS-1$
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+    /**
+     * Name of enum
+     */
+    private final String fInName;
+
+    /**
+     * Name of the machine interface enum
+     */
+    private final String fInMiName;
+
+    // ------------------------------------------------------------------------
+    // Constuctors
+    // ------------------------------------------------------------------------
+
+    /**
+     * Private constructor
+     *
+     * @param name
+     *            the name of state
+     */
+    private BufferType(String name, String miName) {
+        fInName = name;
+        fInMiName = miName;
+    }
+
+    private BufferType(String name) {
+        fInName = name;
+        fInMiName = ""; //$NON-NLS-1$
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+    /**
+     * @return state name
+     */
+    public String getInName() {
+        return fInName;
+    }
+
+    /**
+     * @return machine interface buffer name
+     */
+    public String getInMiName() {
+        return fInMiName;
+    }
+
+    // /
+    // ------------------------------------------------------------------------
+    // Utility function
+    // -------------------------------------------------------------------------
+    /**
+     * @param name
+     *            the string representation of the type
+     * @return enum BufferType of the corresponding type
+     */
+    public static BufferType valueOfString(String name) {
+        if (name == null) {
+            throw new IllegalArgumentException();
+        }
+        for (BufferType bufferType : BufferType.values()) {
+            boolean isEqual = bufferType.getInName().equalsIgnoreCase(name) || bufferType.getInMiName().equalsIgnoreCase(name);
+            if (isEqual) {
+                return bufferType;
+            }
+        }
+        return BUFFER_TYPE_UNKNOWN;
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/ChannelInfo.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/ChannelInfo.java
new file mode 100644 (file)
index 0000000..e588100
--- /dev/null
@@ -0,0 +1,353 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2015 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Simon Delisle - Updated for support of LTTng Tools 2.2
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.core.model.impl;
+
+import java.util.ArrayList;
+import java.util.Iterator;
+import java.util.List;
+
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IChannelInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IEventInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceChannelOutputType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEnablement;
+
+/**
+ * Implementation of the trace channel interface (IChannelInfo) to store channel
+ * related data.
+ *
+ * @author Bernd Hufmann
+ */
+public class ChannelInfo extends TraceInfo implements IChannelInfo {
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+    /**
+     * The overwrite mode of the channel.
+     */
+    private boolean fOverwriteMode;
+    /**
+     * The sub-buffer size of the channel.
+     */
+    private long fSubBufferSize;
+    /**
+     * The number of sub-buffers of the channel.
+     */
+    private int fNumberOfSubBuffers;
+    /**
+     * The switch timer interval of the channel.
+     */
+    private long fSwitchTimer;
+    /**
+     * The read timer interval of the channel.
+     */
+    private long fReadTimer;
+    /**
+     * The Output type of the channel.
+     */
+    private TraceChannelOutputType fOutputType = TraceChannelOutputType.UNKNOWN;
+    /**
+     * The channel enable state.
+     */
+    private TraceEnablement fState = TraceEnablement.DISABLED;
+    /**
+     * The events information of the channel.
+     */
+    private final List<IEventInfo> fEvents = new ArrayList<>();
+    /**
+     * The maximum size of trace files
+     */
+    private long fMaxSizeTraceFiles;
+    /**
+     * The maximum number of trace files
+     */
+    private int fMaxNumberTraceFiles;
+    /**
+     * The value of buffer type
+     */
+    private BufferType fBufferType = BufferType.BUFFER_TYPE_UNKNOWN;
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+    /**
+     * Constructor
+     *
+     * @param name
+     *            - name channel
+     */
+    public ChannelInfo(String name) {
+        super(name);
+    }
+
+    /**
+     * Copy constructor
+     *
+     * @param other
+     *            - the instance to copy
+     */
+    public ChannelInfo(ChannelInfo other) {
+        super(other);
+        fOverwriteMode = other.fOverwriteMode;
+        fSubBufferSize = other.fSubBufferSize;
+        fNumberOfSubBuffers = other.fNumberOfSubBuffers;
+        fSwitchTimer = other.fSwitchTimer;
+        fReadTimer = other.fReadTimer;
+        fMaxSizeTraceFiles = other.fMaxSizeTraceFiles;
+        fMaxNumberTraceFiles = other.fMaxNumberTraceFiles;
+        fBufferType = other.fBufferType;
+        fOutputType = (other.fOutputType == null ? null : other.fOutputType);
+        fState = other.fState;
+        for (Iterator<IEventInfo> iterator = other.fEvents.iterator(); iterator.hasNext();) {
+            IEventInfo event = iterator.next();
+            if (event instanceof EventInfo) {
+                fEvents.add(new EventInfo((EventInfo) event));
+            } else {
+                fEvents.add(event);
+            }
+        }
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    @Override
+    public boolean isOverwriteMode() {
+        return fOverwriteMode;
+    }
+
+    @Override
+    public void setOverwriteMode(boolean mode) {
+        fOverwriteMode = mode;
+    }
+
+    @Override
+    public long getSubBufferSize() {
+        return fSubBufferSize;
+    }
+
+    @Override
+    public void setSubBufferSize(long bufferSize) {
+        fSubBufferSize = bufferSize;
+    }
+
+    @Override
+    public int getNumberOfSubBuffers() {
+        return fNumberOfSubBuffers;
+    }
+
+    @Override
+    public void setNumberOfSubBuffers(int numberOfSubBuffers) {
+        fNumberOfSubBuffers = numberOfSubBuffers;
+    }
+
+    @Override
+    public long getSwitchTimer() {
+        return fSwitchTimer;
+    }
+
+    @Override
+    public void setSwitchTimer(long timer) {
+        fSwitchTimer = timer;
+    }
+
+    @Override
+    public long getReadTimer() {
+        return fReadTimer;
+    }
+
+    @Override
+    public void setReadTimer(long timer) {
+        fReadTimer = timer;
+    }
+
+    @Override
+    public TraceChannelOutputType getOutputType() {
+        return fOutputType;
+    }
+
+    @Override
+    public void setOutputType(String type) {
+        fOutputType = TraceChannelOutputType.valueOfString(type);
+    }
+
+    @Override
+    public void setOutputType(TraceChannelOutputType type) {
+        fOutputType = type;
+    }
+
+    @Override
+    public TraceEnablement getState() {
+        return fState;
+    }
+
+    @Override
+    public void setState(TraceEnablement state) {
+        fState = state;
+    }
+
+    @Override
+    public void setState(String stateName) {
+        fState = TraceEnablement.valueOfString(stateName);
+    }
+
+    @Override
+    public IEventInfo[] getEvents() {
+        return fEvents.toArray(new IEventInfo[fEvents.size()]);
+    }
+
+    @Override
+    public void setEvents(List<IEventInfo> events) {
+        fEvents.clear();
+        for (Iterator<IEventInfo> iterator = events.iterator(); iterator.hasNext();) {
+            IEventInfo eventInfo = iterator.next();
+            fEvents.add(eventInfo);
+        }
+    }
+
+    @Override
+    public void addEvent(IEventInfo channel) {
+        fEvents.add(channel);
+    }
+
+    @Override
+    public int hashCode() {
+        final int prime = 31;
+        int result = super.hashCode();
+        result = prime * result + fEvents.hashCode();
+        result = prime * result + fNumberOfSubBuffers;
+        result = prime * result + ((fOutputType == null) ? 0 : fOutputType.hashCode());
+        result = prime * result + (fOverwriteMode ? 1231 : 1237);
+        result = prime * result + (int) (fReadTimer ^ (fReadTimer >>> 32));
+        result = prime * result + ((fState == null) ? 0 : (fState.ordinal() + 1));
+        result = prime * result + (int) (fSubBufferSize ^ (fSubBufferSize >>> 32));
+        result = prime * result + (int) (fSwitchTimer ^ (fSwitchTimer >>> 32));
+        result = prime * result + ((fBufferType == null) ? 0 : (fBufferType.ordinal() + 1));
+        return result;
+    }
+
+    @Override
+    public boolean equals(Object obj) {
+        if (this == obj) {
+            return true;
+        }
+        if (!super.equals(obj)) {
+            return false;
+        }
+        if (getClass() != obj.getClass()) {
+            return false;
+        }
+        ChannelInfo other = (ChannelInfo) obj;
+        if (!fEvents.equals(other.fEvents)) {
+            return false;
+        }
+        if (fNumberOfSubBuffers != other.fNumberOfSubBuffers) {
+            return false;
+        }
+        if (fOutputType == null) {
+            if (other.fOutputType != null) {
+                return false;
+            }
+        } else if (!fOutputType.equals(other.fOutputType)) {
+            return false;
+        }
+        if (fOverwriteMode != other.fOverwriteMode) {
+            return false;
+        }
+        if (fReadTimer != other.fReadTimer) {
+            return false;
+        }
+        if (fState != other.fState) {
+            return false;
+        }
+        if (fSubBufferSize != other.fSubBufferSize) {
+            return false;
+        }
+        if (fSwitchTimer != other.fSwitchTimer) {
+            return false;
+        }
+        if (fBufferType != other.fBufferType) {
+            return false;
+        }
+        return true;
+    }
+
+    @SuppressWarnings("nls")
+    @Override
+    public String toString() {
+        StringBuffer output = new StringBuffer();
+        output.append("[ChannelInfo(");
+        output.append(super.toString());
+        output.append(",State=");
+        output.append(fState);
+        output.append(",OverwriteMode=");
+        output.append(fOverwriteMode);
+        output.append(",SubBuffersSize=");
+        output.append(fSubBufferSize);
+        output.append(",NumberOfSubBuffers=");
+        output.append(fNumberOfSubBuffers);
+        output.append(",SwitchTimer=");
+        output.append(fSwitchTimer);
+        output.append(",ReadTimer=");
+        output.append(fReadTimer);
+        output.append(",output=");
+        output.append(fOutputType.getInName());
+        if ((fBufferType != null) && !fBufferType.equals(BufferType.BUFFER_TYPE_UNKNOWN) && !fBufferType.equals(BufferType.BUFFER_SHARED)) {
+            output.append(",BufferType=");
+            output.append(fBufferType);
+        }
+        output.append(",Events=");
+        if (fEvents.isEmpty()) {
+            output.append("None");
+        } else {
+            for (Iterator<IEventInfo> iterator = fEvents.iterator(); iterator.hasNext();) {
+                IEventInfo event = iterator.next();
+                output.append(event.toString());
+            }
+        }
+        output.append(")]");
+        return output.toString();
+    }
+
+    @Override
+    public void setMaxSizeTraceFiles(long maxSizeTraceFiles) {
+        fMaxSizeTraceFiles = maxSizeTraceFiles;
+    }
+
+    @Override
+    public void setMaxNumberTraceFiles(int maxNumberTraceFiles) {
+        fMaxNumberTraceFiles = maxNumberTraceFiles;
+    }
+
+    @Override
+    public long getMaxSizeTraceFiles() {
+        return fMaxSizeTraceFiles;
+    }
+
+    @Override
+    public int getMaxNumberTraceFiles() {
+        return fMaxNumberTraceFiles;
+    }
+
+    @Override
+    public void setBufferType(BufferType bufferType) {
+        fBufferType = bufferType;
+    }
+
+    @Override
+    public BufferType getBufferType() {
+        return fBufferType;
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/DomainInfo.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/DomainInfo.java
new file mode 100644 (file)
index 0000000..5f77cd0
--- /dev/null
@@ -0,0 +1,173 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.core.model.impl;
+
+import java.util.ArrayList;
+import java.util.Iterator;
+import java.util.List;
+
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IChannelInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IDomainInfo;
+
+/**
+ * <p>
+ * Implementation of the trace domain interface (IDomainInfo) to store domain
+ * related data.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class DomainInfo extends TraceInfo implements IDomainInfo {
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+    /**
+     * The channels information of the domain.
+     */
+    private final List<IChannelInfo> fChannels = new ArrayList<>();
+    private boolean fIsKernel = false;
+    private BufferType fBufferType = BufferType.BUFFER_TYPE_UNKNOWN;
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+    /**
+     * Constructor
+     * @param name - name of domain
+     */
+    public DomainInfo(String name) {
+        super(name);
+    }
+
+    /**
+     * Copy constructor
+     * @param other - the instance to copy
+     */
+    public DomainInfo(DomainInfo other) {
+        super(other);
+        for (int i = 0; i < other.fChannels.size(); i++) {
+            if (other.fChannels.get(i) instanceof ChannelInfo) {
+                fChannels.add(new ChannelInfo((ChannelInfo)other.fChannels.get(i)));
+            } else {
+                fChannels.add(other.fChannels.get(i));
+            }
+        }
+        fIsKernel = other.fIsKernel;
+        fBufferType = other.fBufferType;
+    }
+
+    @Override
+    public boolean isKernel() {
+        return fIsKernel;
+    }
+
+    @Override
+    public void setIsKernel(boolean isKernel) {
+        fIsKernel = isKernel;
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    @Override
+    public IChannelInfo[] getChannels() {
+        return fChannels.toArray(new IChannelInfo[fChannels.size()]);
+    }
+
+    @Override
+    public void setChannels(List<IChannelInfo> channels) {
+        fChannels.clear();
+        for (Iterator<IChannelInfo> iterator = channels.iterator(); iterator.hasNext();) {
+            IChannelInfo channelInfo = iterator.next();
+            fChannels.add(channelInfo);
+        }
+    }
+
+    @Override
+    public void addChannel(IChannelInfo channel) {
+        fChannels.add(channel);
+    }
+
+    @Override
+    public int hashCode() {
+        final int prime = 31;
+        int result = super.hashCode();
+        result = prime * result + fChannels.hashCode();
+        result = prime * result + (fIsKernel ? 1231 : 1237);
+        result = prime * result + ((fBufferType == null) ? 0 : (fBufferType.ordinal() + 1));
+        return result;
+    }
+
+    @Override
+    public boolean equals(Object obj) {
+        if (this == obj) {
+            return true;
+        }
+        if (!super.equals(obj)) {
+            return false;
+        }
+        if (getClass() != obj.getClass()) {
+            return false;
+        }
+        DomainInfo other = (DomainInfo) obj;
+        if (!fChannels.equals(other.fChannels)) {
+            return false;
+        }
+        if (fIsKernel != other.fIsKernel) {
+            return false;
+        }
+        if (fBufferType != other.fBufferType) {
+            return false;
+        }
+        return true;
+    }
+
+    @Override
+    public BufferType getBufferType() {
+        if (fIsKernel) {
+            return BufferType.BUFFER_SHARED;
+        }
+        return fBufferType;
+    }
+
+    @Override
+    public void setBufferType(BufferType bufferType) {
+        fBufferType = bufferType;
+    }
+
+    @SuppressWarnings("nls")
+    @Override
+    public String toString() {
+        StringBuffer output = new StringBuffer();
+            output.append("[DomainInfo(");
+            output.append(super.toString());
+            output.append(",Channels=");
+            if (fChannels.isEmpty()) {
+                output.append("None");
+            } else {
+                for (Iterator<IChannelInfo> iterator = fChannels.iterator(); iterator.hasNext();) {
+                    IChannelInfo channel = iterator.next();
+                    output.append(channel.toString());
+                }
+            }
+            output.append(",isKernel=");
+            output.append(String.valueOf(fIsKernel));
+            if ((fBufferType != null) && !fBufferType.equals(BufferType.BUFFER_TYPE_UNKNOWN) && !fBufferType.equals(BufferType.BUFFER_SHARED)) {
+                output.append(",BufferType=");
+                output.append(fBufferType);
+            }
+            output.append(")]");
+            return output.toString();
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/EventInfo.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/EventInfo.java
new file mode 100644 (file)
index 0000000..c73e46c
--- /dev/null
@@ -0,0 +1,139 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.core.model.impl;
+
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IEventInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.LogLevelType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEnablement;
+
+/**
+* <p>
+* Implementation of the trace event interface (IEventInfo) to store event
+* related data.
+* </p>
+*
+* @author Bernd Hufmann
+*/
+public class EventInfo extends BaseEventInfo implements IEventInfo {
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+    /**
+     * The enable state of the event.
+     */
+    private TraceEnablement fState = TraceEnablement.DISABLED;
+    /**
+     * The log level type.
+     */
+    private LogLevelType fLogLevelType = LogLevelType.LOGLEVEL_NONE;
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+    /**
+     * Constructor
+     * @param name - name of event
+     */
+    public EventInfo(String name) {
+        super(name);
+    }
+
+    /**
+     * Copy constructor
+     * @param other - the instance to copy
+     */
+    public EventInfo(EventInfo other) {
+        super(other);
+        fState = other.fState;
+        fLogLevelType = other.fLogLevelType;
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    @Override
+    public TraceEnablement getState() {
+        return fState;
+    }
+
+    @Override
+    public void setState(TraceEnablement state) {
+        fState = state;
+    }
+
+    @Override
+    public void setState(String stateName) {
+        fState = TraceEnablement.valueOfString(stateName);
+    }
+
+    @Override
+    public LogLevelType getLogLevelType() {
+        return fLogLevelType;
+    }
+
+    @Override
+    public void setLogLevelType(LogLevelType type) {
+        fLogLevelType = type;
+    }
+
+    @Override
+    public void setLogLevelType(String shortName) {
+        fLogLevelType = LogLevelType.valueOfString(shortName);
+    }
+
+
+    @Override
+    public int hashCode() {
+        final int prime = 31;
+        int result = super.hashCode();
+        result = prime * result + ((fState == null) ? 0 : (fState.ordinal() + 1));
+        result = prime * result + ((fLogLevelType == null) ? 0 : fLogLevelType.hashCode());
+        return result;
+    }
+
+    @Override
+    public boolean equals(Object obj) {
+        if (this == obj) {
+            return true;
+        }
+        if (!super.equals(obj)) {
+            return false;
+        }
+        if (getClass() != obj.getClass()) {
+            return false;
+        }
+        EventInfo other = (EventInfo) obj;
+        if (fState != other.fState) {
+            return false;
+        }
+        if (fLogLevelType != other.fLogLevelType) {
+            return false;
+        }
+        return true;
+    }
+
+    @SuppressWarnings("nls")
+    @Override
+    public String toString() {
+        StringBuffer output = new StringBuffer();
+            output.append("[EventInfo(");
+            output.append(super.toString());
+            output.append(",State=");
+            output.append(fState);
+            output.append(",levelType=");
+            output.append(fLogLevelType);
+            output.append(")]");
+            return output.toString();
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/FieldInfo.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/FieldInfo.java
new file mode 100644 (file)
index 0000000..5a588c2
--- /dev/null
@@ -0,0 +1,109 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.core.model.impl;
+
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IFieldInfo;
+
+/**
+* <p>
+* Implementation of the basic trace event interface (IEventInfo) to store event
+* related data.
+* </p>
+*
+* @author Bernd Hufmann
+*/
+public class FieldInfo extends TraceInfo implements IFieldInfo {
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+    /**
+     * The trace event type.
+     */
+    private String fFieldType;
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+    /**
+     * Constructor
+     * @param name - name of base event
+     */
+    public FieldInfo(String name) {
+        super(name);
+    }
+
+    /**
+     * Copy constructor
+     * @param other - the instance to copy
+     */
+    public FieldInfo(FieldInfo other) {
+        super(other);
+        fFieldType = other.fFieldType;
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    @Override
+    public String getFieldType() {
+        return fFieldType;
+    }
+
+    @Override
+    public void setFieldType(String fieldType) {
+        fFieldType = fieldType.toLowerCase();
+    }
+
+    @Override
+    public int hashCode() {
+        final int prime = 31;
+        int result = super.hashCode();
+        result = prime * result
+                + ((fFieldType == null) ? 0 : fFieldType.hashCode());
+        return result;
+    }
+
+    @Override
+    public boolean equals(Object obj) {
+        if (this == obj) {
+            return true;
+        }
+        if (!super.equals(obj)) {
+            return false;
+        }
+        if (getClass() != obj.getClass()) {
+            return false;
+        }
+        FieldInfo other = (FieldInfo) obj;
+        if (fFieldType == null) {
+            if (other.fFieldType != null) {
+                return false;
+            }
+        } else if (!fFieldType.equals(other.fFieldType)) {
+            return false;
+        }
+        return true;
+    }
+
+    @SuppressWarnings("nls")
+    @Override
+    public String toString() {
+        StringBuffer output = new StringBuffer();
+            output.append("[FieldInfo(");
+            output.append(super.toString());
+            output.append(",type=");
+            output.append(fFieldType);
+            return output.toString();
+    }
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/ProbeEventInfo.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/ProbeEventInfo.java
new file mode 100644 (file)
index 0000000..42550a5
--- /dev/null
@@ -0,0 +1,187 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.core.model.impl;
+
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IEventInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IProbeEventInfo;
+
+/**
+ * Implementation of the trace event interface (IProbeEventInfo) to store probe
+ * event related data.
+ *
+ * @author Bernd Hufmann
+ */
+public class ProbeEventInfo extends EventInfo implements IProbeEventInfo {
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+    /**
+     * The dynamic probe address (null if symbol is used).
+     */
+    private String fAddress;
+    /**
+     * The dynamic probe offset (if symbol is used).
+     */
+    private String fOffset;
+
+    /**
+     * The symbol name (null if address is used)
+     */
+    private String fSymbol;
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+    /**
+     * Constructor
+     *
+     * @param name
+     *            - name of event
+     */
+    public ProbeEventInfo(String name) {
+        super(name);
+    }
+
+    /**
+     * Copy constructor
+     *
+     * @param other
+     *            - the instance to copy
+     */
+    public ProbeEventInfo(ProbeEventInfo other) {
+        super(other);
+        fAddress = other.fAddress;
+        fOffset = other.fOffset;
+        fSymbol = other.fSymbol;
+    }
+
+    /**
+     * Constructor from a {@link IEventInfo}
+     *
+     * @param eventInfo
+     *            - the instance to copy
+     */
+    public ProbeEventInfo(IEventInfo eventInfo) {
+        super(eventInfo.getName());
+        setState(eventInfo.getState());
+        setLogLevelType(eventInfo.getLogLevelType());
+        setLogLevel(eventInfo.getLogLevel());
+        setFilterExpression(eventInfo.getFilterExpression());
+        setEventType(eventInfo.getEventType());
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    @Override
+    public String getAddress() {
+        return fAddress;
+    }
+
+    @Override
+    public void setAddress(String address) {
+        fAddress = address;
+    }
+
+    @Override
+    public String getOffset() {
+        return fOffset;
+    }
+
+    @Override
+    public void setOffset(String offset) {
+        fOffset = offset;
+    }
+
+    @Override
+    public String getSymbol() {
+        return fSymbol;
+    }
+
+    @Override
+    public void setSymbol(String symbol) {
+        fSymbol = symbol;
+    }
+
+    // ------------------------------------------------------------------------
+    // Operation
+    // ------------------------------------------------------------------------
+
+    @Override
+    public int hashCode() {
+        final int prime = 31;
+        int result = super.hashCode();
+        result = prime * result + ((fAddress == null) ? 0 : fAddress.hashCode());
+        result = prime * result + ((fOffset == null) ? 0 : fOffset.hashCode());
+        result = prime * result + ((fSymbol == null) ? 0 : fSymbol.hashCode());
+        return result;
+    }
+
+    @Override
+    public boolean equals(Object obj) {
+        if (this == obj) {
+            return true;
+        }
+        if (!super.equals(obj)) {
+            return false;
+        }
+        if (getClass() != obj.getClass()) {
+            return false;
+        }
+        ProbeEventInfo other = (ProbeEventInfo) obj;
+        if (fAddress == null) {
+            if (other.fAddress != null) {
+                return false;
+            }
+        } else if (!fAddress.equals(other.fAddress)) {
+            return false;
+        }
+        if (fOffset == null) {
+            if (other.fOffset != null) {
+                return false;
+            }
+        } else if (!fOffset.equals(other.fOffset)) {
+            return false;
+        }
+        if (fSymbol == null) {
+            if (other.fSymbol != null) {
+                return false;
+            }
+        } else if (!fSymbol.equals(other.fSymbol)) {
+            return false;
+        }
+        return true;
+    }
+
+    @SuppressWarnings("nls")
+    @Override
+    public String toString() {
+        StringBuffer output = new StringBuffer();
+        output.append("[ProbeEventInfo(");
+        output.append(super.toString());
+        if (fAddress != null) {
+            output.append(",fAddress=");
+            output.append(fAddress);
+        } else {
+            output.append(",fOffset=");
+            output.append(fOffset);
+            output.append(",fSymbol=");
+            output.append(fSymbol);
+        }
+        output.append(")]");
+        return output.toString();
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/SessionInfo.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/SessionInfo.java
new file mode 100644 (file)
index 0000000..53a78fa
--- /dev/null
@@ -0,0 +1,338 @@
+/**********************************************************************
+
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
+ *   Marc-Andre Laperle - Support for creating a live session
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.core.model.impl;
+
+import java.util.ArrayList;
+import java.util.Iterator;
+import java.util.List;
+
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IDomainInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISessionInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISnapshotInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
+
+/**
+ * Implementation of the trace session interface (ISessionInfo) to store session
+ * related data.
+ *
+ * @author Bernd Hufmann
+ */
+public class SessionInfo extends TraceInfo implements ISessionInfo {
+
+    /**
+     * The default network URL when creating a live session.
+     */
+    public static final String DEFAULT_LIVE_NETWORK_URL = "net://127.0.0.1"; //$NON-NLS-1$
+
+    /**
+     * The default live port for a live session.
+     */
+    public static final int DEFAULT_LIVE_PORT = 5344;
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+    /**
+     * The trace session state.
+     */
+    private TraceSessionState fState = TraceSessionState.INACTIVE;
+    /**
+     * The trace session path for storing traces.
+     */
+    private String fSessionPath = ""; //$NON-NLS-1$
+    /**
+     * The domains information of this session.
+     */
+    private final List<IDomainInfo> fDomains = new ArrayList<>();
+    /**
+     * Flag to indicate whether trace is streamed over network or not.
+     */
+    private boolean fIsStreamedTrace = false;
+    /**
+     * Flag to indicate whether the session is a snapshot session or not.
+     */
+    private boolean fIsSnapshot = false;
+    /**
+     * The snapshot information of the session
+     */
+    private ISnapshotInfo fSnapshotInfo = null;
+    /**
+     * The network URL for the session (-U)
+     */
+    private String fNetworkUrl = null;
+    /**
+     * The control URL for the session (-C)
+     */
+    private String fControlUrl = null;
+    /**
+     * The data URL for the session (-D)
+     */
+    private String fDataUrl = null;
+
+    /**
+     * Flag to indicate whether trace is live or not.
+     */
+    private boolean fIsLive = false;
+
+    /**
+     * The delay in micro seconds before the data is flushed and streamed.
+     */
+    private long fLiveDelay = -1;
+
+    /**
+     * The live connection url (Relayd).
+     */
+    private String fLiveUrl;
+
+    /**
+     * The live connection port (Relayd).
+     */
+    private Integer fLivePort;
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+    /**
+     * Constructor
+     *
+     * @param name
+     *            - name of base event
+     */
+    public SessionInfo(String name) {
+        super(name);
+    }
+
+    /**
+     * Copy constructor
+     *
+     * @param other
+     *            - the instance to copy
+     */
+    public SessionInfo(SessionInfo other) {
+        super(other);
+        fState = other.fState;
+        fSessionPath = other.fSessionPath;
+        fIsStreamedTrace = other.fIsStreamedTrace;
+        fIsSnapshot = other.fIsSnapshot;
+        fSnapshotInfo = other.fSnapshotInfo;
+        fNetworkUrl = other.fNetworkUrl;
+        fControlUrl = other.fControlUrl;
+        fDataUrl = other.fDataUrl;
+
+        for (Iterator<IDomainInfo> iterator = other.fDomains.iterator(); iterator.hasNext();) {
+            IDomainInfo domain = iterator.next();
+            if (domain instanceof DomainInfo) {
+                fDomains.add(new DomainInfo((DomainInfo) domain));
+            } else {
+                fDomains.add(domain);
+            }
+        }
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    @Override
+    public TraceSessionState getSessionState() {
+        return fState;
+    }
+
+    @Override
+    public void setSessionState(TraceSessionState state) {
+        fState = state;
+    }
+
+    @Override
+    public void setSessionState(String stateName) {
+        fState = TraceSessionState.valueOfString(stateName);
+    }
+
+    @Override
+    public String getSessionPath() {
+        if (isSnapshotSession() && fSnapshotInfo != null) {
+            return fSnapshotInfo.getSnapshotPath();
+        }
+        return fSessionPath;
+    }
+
+    @Override
+    public void setSessionPath(String path) {
+        fSessionPath = path;
+    }
+
+    @Override
+    public IDomainInfo[] getDomains() {
+        return fDomains.toArray(new IDomainInfo[fDomains.size()]);
+    }
+
+    @Override
+    public void setDomains(List<IDomainInfo> domains) {
+        fDomains.clear();
+        for (Iterator<IDomainInfo> iterator = domains.iterator(); iterator.hasNext();) {
+            IDomainInfo domainInfo = iterator.next();
+            fDomains.add(domainInfo);
+        }
+    }
+
+    @Override
+    public boolean isStreamedTrace() {
+        if (isSnapshotSession() && getSnapshotInfo() != null) {
+            return getSnapshotInfo().isStreamedSnapshot();
+        }
+        return fIsStreamedTrace;
+    }
+
+    @Override
+    public void setStreamedTrace(boolean isStreamedTrace) {
+        fIsStreamedTrace = isStreamedTrace;
+    }
+
+    @Override
+    public boolean isSnapshotSession() {
+        return fIsSnapshot || fSnapshotInfo != null;
+    }
+
+    @Override
+    public void setSnapshot(boolean isSnapshot) {
+        fIsSnapshot = isSnapshot;
+    }
+
+    @Override
+    public ISnapshotInfo getSnapshotInfo() {
+        return fSnapshotInfo;
+    }
+
+    @Override
+    public void setSnapshotInfo(ISnapshotInfo info) {
+        fSnapshotInfo = info;
+    }
+
+    @Override
+    public boolean isLive() {
+        return fIsLive;
+    }
+
+    @Override
+    public void setLive(boolean isLive) {
+        fIsLive = isLive;
+    }
+
+    @Override
+    public long getLiveDelay() {
+        return fLiveDelay;
+    }
+
+    @Override
+    public void setLiveDelay(long liveDelay) {
+        fLiveDelay = liveDelay;
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    public void addDomain(IDomainInfo domainInfo) {
+        fDomains.add(domainInfo);
+    }
+
+    @SuppressWarnings("nls")
+    @Override
+    public String toString() {
+        StringBuffer output = new StringBuffer();
+        output.append("[SessionInfo(");
+        output.append(super.toString());
+        output.append(",Path=");
+        output.append(getSessionPath());
+        output.append(",State=");
+        output.append(fState);
+        output.append(",isStreamedTrace=");
+        output.append(fIsStreamedTrace);
+        output.append(",isSnapshot=");
+        output.append(fIsSnapshot);
+
+        if (fSnapshotInfo != null) {
+            output.append(",snapshotInfo=");
+            output.append(fSnapshotInfo.toString());
+        }
+        output.append(",Domains=");
+        for (Iterator<IDomainInfo> iterator = fDomains.iterator(); iterator.hasNext();) {
+            IDomainInfo domain = iterator.next();
+            output.append(domain.toString());
+        }
+
+        output.append(",NetworkUrl=");
+        output.append(getNetworkUrl());
+        output.append(",ControlUrl=");
+        output.append(getControlUrl());
+        output.append(",DataUrl=");
+        output.append(getDataUrl());
+
+        output.append(")]");
+        return output.toString();
+    }
+
+    @Override
+    public String getNetworkUrl() {
+        return fNetworkUrl;
+    }
+
+    @Override
+    public void setNetworkUrl(String networkUrl) {
+        fNetworkUrl = networkUrl;
+    }
+
+    @Override
+    public String getControlUrl() {
+        return fControlUrl;
+    }
+
+    @Override
+    public void setControlUrl(String controlUrl) {
+        fControlUrl = controlUrl;
+    }
+
+    @Override
+    public void setDataUrl(String datalUrl) {
+        fDataUrl = datalUrl;
+    }
+
+    @Override
+    public String getDataUrl() {
+        return fDataUrl;
+    }
+
+    @Override
+    public void setLiveUrl(String liveUrl) {
+        fLiveUrl = liveUrl;
+    }
+
+    @Override
+    public void setLivePort(Integer livePort) {
+        fLivePort = livePort;
+    }
+
+    @Override
+    public String getLiveUrl() {
+        return fLiveUrl;
+    }
+
+    @Override
+    public Integer getLivePort() {
+        return fLivePort;
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/SnapshotInfo.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/SnapshotInfo.java
new file mode 100644 (file)
index 0000000..9adc78f
--- /dev/null
@@ -0,0 +1,150 @@
+/**********************************************************************
+ * Copyright (c) 2013, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.core.model.impl;
+
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISnapshotInfo;
+
+/**
+ * <p>
+ * Implementation of the snapshot interface (ISnapshotInfo) to store snapshot
+ * related data.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class SnapshotInfo extends TraceInfo implements ISnapshotInfo {
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+    /** The snapshot path for storing traces. */
+    private String fPath = ""; //$NON-NLS-1$
+    /** The snapshot ID */
+    private int fId = -1;
+    /** Flag whether snapshot is stored over the network or locally */
+    private boolean fIsStreamed = false;
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+    /**
+     * Constructor
+     * @param name - name of base event
+     */
+    public SnapshotInfo(String name) {
+        super(name);
+    }
+
+    /**
+     * Copy constructor
+     * @param other - the instance to copy
+     */
+    public SnapshotInfo(SnapshotInfo other) {
+        super(other);
+        fPath = other.fPath;
+        fId = other.fId;
+        fIsStreamed = other.fIsStreamed;
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    @Override
+    public String getSnapshotPath() {
+        return fPath;
+    }
+
+    @Override
+    public void setSnapshotPath(String path) {
+        fPath = path;
+    }
+
+    @Override
+    public int getId() {
+        return fId;
+    }
+
+    @Override
+    public void setId(int id) {
+        fId = id;
+    }
+
+    @Override
+    public void setStreamedSnapshot(boolean isStreamed) {
+        fIsStreamed = isStreamed;
+    }
+
+    @Override
+    public boolean isStreamedSnapshot() {
+        return fIsStreamed;
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    public int hashCode() {
+        final int prime = 31;
+        int result = super.hashCode();
+        result = prime * result + fId;
+        result = prime * result + (fIsStreamed ? 1231 : 1237);
+        result = prime * result + ((fPath == null) ? 0 : fPath.hashCode());
+        return result;
+    }
+
+    @Override
+    public boolean equals(Object obj) {
+        if (this == obj) {
+            return true;
+        }
+        if (!super.equals(obj)) {
+            return false;
+        }
+        if (getClass() != obj.getClass()) {
+            return false;
+        }
+        SnapshotInfo other = (SnapshotInfo) obj;
+        if (fId != other.fId) {
+            return false;
+        }
+        if (fIsStreamed != other.fIsStreamed) {
+            return false;
+        }
+        if (fPath == null) {
+            if (other.fPath != null) {
+                return false;
+            }
+        } else if (!fPath.equals(other.fPath)) {
+            return false;
+        }
+        return true;
+    }
+
+    @SuppressWarnings("nls")
+    @Override
+    public String toString() {
+        StringBuffer output = new StringBuffer();
+            output.append("[SnapshotInfo(");
+            output.append(super.toString());
+            output.append(",snapshotPath=");
+            output.append(fPath);
+            output.append(",ID=");
+            output.append(fId);
+            output.append(",isStreamedSnapshot=");
+            output.append(fIsStreamed);
+            output.append(")]");
+            return output.toString();
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/TraceInfo.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/TraceInfo.java
new file mode 100644 (file)
index 0000000..82e70d6
--- /dev/null
@@ -0,0 +1,113 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.core.model.impl;
+
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.ITraceInfo;
+
+/**
+ * <p>
+ * Implementation of the base trace information interface (ITraceInfo) to
+ * store common data.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class TraceInfo implements ITraceInfo {
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+    /**
+     * The name of the element.
+     */
+    private String fName = null;
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+    /**
+     * Constructor
+     * @param name - name of trace element
+     */
+    public TraceInfo(String name) {
+        if (name == null) {
+            throw new IllegalArgumentException();
+        }
+        fName = name;
+    }
+
+    /**
+     * Copy constructor
+     * @param other - the instance to copy
+     */
+    public TraceInfo(TraceInfo other) {
+        if (other == null) {
+            throw new IllegalArgumentException();
+        }
+        fName = String.valueOf(other.fName);
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    @Override
+    public String getName() {
+        return fName;
+    }
+
+    @Override
+    public void setName(String name) {
+        fName = name;
+    }
+
+    @Override
+    public int hashCode() {
+        final int prime = 31;
+        int result = 1;
+        result = prime * result + ((fName == null) ? 0 : fName.hashCode());
+        return result;
+    }
+
+    @Override
+    public boolean equals(Object obj) {
+        if (this == obj) {
+            return true;
+        }
+        if (obj == null) {
+            return false;
+        }
+        if (getClass() != obj.getClass()) {
+            return false;
+        }
+        TraceInfo other = (TraceInfo) obj;
+        if (fName == null) {
+            if (other.fName != null) {
+                return false;
+            }
+        } else if (!fName.equals(other.fName)) {
+            return false;
+        }
+        return true;
+    }
+
+    @SuppressWarnings("nls")
+    @Override
+    public String toString() {
+        StringBuffer output = new StringBuffer();
+            output.append("[TraceInfo(");
+            output.append("Name=");
+            output.append(getName());
+            output.append(")]");
+            return output.toString();
+    }
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/UstProviderInfo.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/UstProviderInfo.java
new file mode 100644 (file)
index 0000000..570d1a6
--- /dev/null
@@ -0,0 +1,162 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.core.model.impl;
+
+import java.util.ArrayList;
+import java.util.Iterator;
+import java.util.List;
+
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IBaseEventInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IUstProviderInfo;
+
+/**
+ * <p>
+ * Implementation of the Ust Provider interface (IUstProviderInfo) to store UST
+ * provider related data.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class UstProviderInfo extends TraceInfo implements IUstProviderInfo {
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+
+    /**
+     * The process ID of the UST provider.
+     */
+    private int fPid = 0;
+
+    /**
+     * List of event information.
+     */
+    private final List<IBaseEventInfo> fEvents = new ArrayList<>();
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+
+    /**
+     * Constructor
+     * @param name - name of UST provider
+     */
+    public UstProviderInfo(String name) {
+        super(name);
+    }
+
+    /**
+     * Copy constructor
+     * @param other - the instance to copy
+     */
+    public UstProviderInfo(UstProviderInfo other) {
+        super(other);
+        fPid = other.fPid;
+        for (Iterator<IBaseEventInfo> iterator = other.fEvents.iterator(); iterator.hasNext();) {
+            IBaseEventInfo event = iterator.next();
+            if (event instanceof BaseEventInfo) {
+                fEvents.add(new BaseEventInfo((BaseEventInfo)event));
+            } else {
+                fEvents.add(event);
+            }
+        }
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    @Override
+    public int getPid() {
+        return fPid;
+    }
+
+    @Override
+    public void setPid(int pid) {
+        fPid = pid;
+    }
+
+    @Override
+    public IBaseEventInfo[] getEvents() {
+        return fEvents.toArray(new IBaseEventInfo[fEvents.size()]);
+    }
+
+    @Override
+    public void setEvents(List<IBaseEventInfo> events) {
+        fEvents.clear();
+        for (Iterator<IBaseEventInfo> iterator = events.iterator(); iterator.hasNext();) {
+            IBaseEventInfo eventInfo = iterator.next();
+            fEvents.add(eventInfo);
+        }
+    }
+
+    @Override
+    public void addEvent(IBaseEventInfo event) {
+        fEvents.add(event);
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    public int hashCode() {
+        final int prime = 31;
+        int result = super.hashCode();
+        result = prime * result + fEvents.hashCode();
+        result = prime * result + fPid;
+        return result;
+    }
+
+    @Override
+    public boolean equals(Object obj) {
+        if (this == obj) {
+            return true;
+        }
+        if (!super.equals(obj)) {
+            return false;
+        }
+        if (getClass() != obj.getClass()) {
+            return false;
+        }
+        UstProviderInfo other = (UstProviderInfo) obj;
+        if (!fEvents.equals(other.fEvents)) {
+            return false;
+        }
+        if (fPid != other.fPid) {
+            return false;
+        }
+        return true;
+    }
+
+    @SuppressWarnings("nls")
+    @Override
+    public String toString() {
+        StringBuffer output = new StringBuffer();
+            output.append("[EventInfo(");
+            output.append(super.toString());
+            output.append(",PID=");
+            output.append(fPid);
+            output.append(",Events=");
+            if (fEvents.isEmpty()) {
+                output.append("None");
+            } else {
+                for (Iterator<IBaseEventInfo> iterator = fEvents.iterator(); iterator.hasNext();) {
+                    IBaseEventInfo event = iterator.next();
+                    output.append(event.toString());
+                }
+            }
+            output.append(")]");
+            return output.toString();
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/ILttngRelaydConnector.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/ILttngRelaydConnector.java
new file mode 100644 (file)
index 0000000..88862b0
--- /dev/null
@@ -0,0 +1,118 @@
+/**********************************************************************
+ * Copyright (c) 2014 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:
+ *   Matthew Khouzam - Initial implementation
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.core.relayd;
+
+import java.io.IOException;
+import java.util.List;
+
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.AttachSessionResponse;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.CreateSessionResponse;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.IndexResponse;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.SessionResponse;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.StreamResponse;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.TracePacketResponse;
+
+/**
+ * Connector for Lttng Relayd
+ *
+ * @author Matthew Khouzam
+ */
+public interface ILttngRelaydConnector extends AutoCloseable {
+
+    /**
+     * Gets a list of active Lttng sessions
+     *
+     * @return the session List (we need the get function)
+     * @throws IOException
+     *             timeout and such
+     */
+    List<SessionResponse> getSessions() throws IOException;
+
+    /**
+     * Create a session
+     *
+     * @return create session response
+     * @throws IOException
+     *             timeout and such
+     */
+    CreateSessionResponse createSession() throws IOException;
+
+    /**
+     * Attach the trace viewer to a Session
+     *
+     * @param lttngViewerSession
+     *            viewer session
+     * @return An AttachSessionResponse
+     * @throws IOException
+     *             timeout and such
+     */
+    AttachSessionResponse attachToSession(SessionResponse lttngViewerSession) throws IOException;
+
+    /**
+     * Get the metadata from the relayd
+     *
+     * @param attachedSession
+     *            the attached session
+     * @return a chunk of TSDL metadata
+     * @throws IOException
+     *             timeout and such
+     */
+    String getMetadata(AttachSessionResponse attachedSession) throws IOException;
+
+    /**
+     * Get the next index
+     *
+     * @param stream
+     *            the stream
+     * @return the stream input packet entry
+     * @throws IOException
+     *             timeout and such
+     */
+    IndexResponse getNextIndex(StreamResponse stream) throws IOException;
+
+    /**
+     * Get the next packet in a stream
+     *
+     * @param stream
+     *            the stream response
+     * @return the packet response
+     * @throws IOException
+     *             timeout and such
+     */
+    TracePacketResponse getNextPacket(StreamResponse stream) throws IOException;
+
+    /**
+     * Gets the packet from the stream
+     *
+     * @param index
+     *            the index of the stream
+     * @param id
+     *            the stream id
+     * @return the packet response
+     * @throws IOException
+     *             timeout and such
+     */
+    TracePacketResponse getPacketFromStream(IndexResponse index, long id) throws IOException;
+
+    /**
+     * Gets the new streams
+     *
+     * @return a list of stream responses
+     * @throws IOException
+     *             timeout and such
+     */
+    Iterable<StreamResponse> getNewStreams() throws IOException;
+
+    @Override
+    void close() throws IOException;
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/LttngRelaydConnectorFactory.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/LttngRelaydConnectorFactory.java
new file mode 100644 (file)
index 0000000..faac481
--- /dev/null
@@ -0,0 +1,77 @@
+/**********************************************************************
+ * Copyright (c) 2014 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:
+ *   Matthew Khouzam - Initial implementation
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.core.relayd;
+
+import java.io.DataInputStream;
+import java.io.DataOutputStream;
+import java.io.IOException;
+import java.net.Socket;
+
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.Command;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.ConnectResponse;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.ConnectionType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.ViewerCommand;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.impl.LttngRelaydConnector_2_4;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.impl.LttngRelaydConnector_Unsupported;
+
+/**
+ * LTTng RelayD connector factory
+ *
+ * @author Matthew Khouzam
+ */
+public final class LttngRelaydConnectorFactory {
+
+    private LttngRelaydConnectorFactory() {
+    }
+
+    /**
+     * Create a connection to a relayd
+     *
+     * @param myConnection
+     *            a connection to the relayd
+     *
+     * @return A relayd connector
+     * @throws IOException
+     *             caused by invalid sockets
+     */
+    public static ILttngRelaydConnector getNewConnector(Socket myConnection) throws IOException {
+        DataOutputStream outNet = new DataOutputStream(myConnection.getOutputStream());
+        DataInputStream inNet = new DataInputStream(myConnection.getInputStream());
+
+        ViewerCommand connectCommand = new ViewerCommand(Command.VIEWER_CONNECT, ConnectResponse.SIZE, 0);
+
+        outNet.write(connectCommand.serialize());
+        outNet.flush();
+
+        ConnectResponse payload = new ConnectResponse(0, 2, 4, ConnectionType.VIEWER_CLIENT_COMMAND);
+        outNet.write(payload.serialize());
+        outNet.flush();
+
+        ConnectResponse connectReply = new ConnectResponse(inNet);
+        switch (connectReply.getMajor()) {
+        case 2:
+            switch (connectReply.getMinor()) {
+            case 0:
+            case 1:
+            case 2:
+            case 3:
+                return new LttngRelaydConnector_Unsupported();
+            case 4:
+            default:
+                return new LttngRelaydConnector_2_4(inNet, outNet);
+            }
+        default:
+            return new LttngRelaydConnector_Unsupported();
+        }
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/AttachReturnCode.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/AttachReturnCode.java
new file mode 100644 (file)
index 0000000..d81fed8
--- /dev/null
@@ -0,0 +1,46 @@
+/**********************************************************************
+ * Copyright (c) 2014 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:
+ *   Matthew Khouzam - Initial implementation and API
+ *   Marc-Andre Laperle - Initial implementation and API
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
+
+/**
+ * Return codes for "viewer attach" command
+ *
+ * @author Matthew Khouzam
+ */
+public enum AttachReturnCode implements IBaseCommand {
+
+    /** If the attach command succeeded. */
+    VIEWER_ATTACH_OK(1),
+    /** If a viewer is already attached. */
+    VIEWER_ATTACH_ALREADY(2),
+    /** If the session ID is unknown. */
+    VIEWER_ATTACH_UNK(3),
+    /** If the session is not live. */
+    VIEWER_ATTACH_NOT_LIVE(4),
+    /** Seek error. */
+    VIEWER_ATTACH_SEEK_ERR(5),
+    /** No session */
+    VIEWER_ATTACH_NO_SESSION(6);
+
+    private final int fCode;
+
+    private AttachReturnCode(int c) {
+        fCode = c;
+    }
+
+    @Override
+    public int getCommand() {
+        return fCode;
+    }
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/AttachSessionRequest.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/AttachSessionRequest.java
new file mode 100644 (file)
index 0000000..cf9ee7b
--- /dev/null
@@ -0,0 +1,80 @@
+/**********************************************************************
+ * Copyright (c) 2014 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:
+ *   Matthew Khouzam - Initial implementation and API
+ *   Marc-Andre Laperle - Initial implementation and API
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
+
+import java.nio.ByteBuffer;
+import java.nio.ByteOrder;
+
+/**
+ * VIEWER_ATTACH_SESSION payload.
+ *
+ * @author Matthew Khouzam
+ */
+public class AttachSessionRequest implements IRelayCommand {
+
+    /**
+     * Command size
+     *
+     * fSessionId + fOffset + fSeek
+     */
+    public static final int SIZE = (Long.SIZE + Long.SIZE) / 8 + SeekCommand.SIZE;
+    /** the id of a session */
+    private final long fSessionId;
+    /** unused for now */
+    private final long fOffset;
+    /** enum lttng_viewer_seek */
+    private final SeekCommand fSeek;
+
+    /**
+     * Attach session request constructor
+     *
+     * @param id
+     *            the session id
+     * @param seekCommand
+     *            the seek command
+     */
+    public AttachSessionRequest(long id, SeekCommand seekCommand) {
+        this(id, 0, seekCommand);
+    }
+
+    /**
+     * Attach session request constructor
+     *
+     * @param id
+     *            the session id
+     * @param offset
+     *            unused for now
+     * @param seekCommand
+     *            the seek command
+     */
+
+    public AttachSessionRequest(long id, int offset, SeekCommand seekCommand) {
+        fSessionId = id;
+        fOffset = offset;
+        fSeek = seekCommand;
+
+    }
+
+    @Override
+    public byte[] serialize() {
+        byte data[] = new byte[SIZE];
+        ByteBuffer bb = ByteBuffer.wrap(data);
+        bb.order(ByteOrder.BIG_ENDIAN);
+        bb.putLong(fSessionId);
+        bb.putLong(fOffset);
+        bb.putInt(fSeek.getCommand());
+        return data;
+    }
+
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/AttachSessionResponse.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/AttachSessionResponse.java
new file mode 100644 (file)
index 0000000..d30876a
--- /dev/null
@@ -0,0 +1,94 @@
+/**********************************************************************
+ * Copyright (c) 2014 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:
+ *   Matthew Khouzam - Initial implementation and API
+ *   Marc-Andre Laperle - Initial implementation and API
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
+
+import java.io.DataInputStream;
+import java.io.IOException;
+import java.nio.ByteBuffer;
+import java.nio.ByteOrder;
+import java.util.List;
+
+import com.google.common.collect.ImmutableList;
+import com.google.common.collect.ImmutableList.Builder;
+
+/**
+ * Attach session response
+ *
+ * @author Matthew Khouzam
+ */
+public class AttachSessionResponse implements IRelayResponse {
+
+    /**
+     * Response size
+     *
+     * fStatus + fStreamsCount (first half of a packet) */
+    private static final int SIZE = (Integer.SIZE + Integer.SIZE) / 8;
+    /** enum lttng_viewer_attach_return_code */
+    private final AttachReturnCode fStatus;
+    /** how many streams are there */
+    private final int fStreamsCount;
+    /** public class lttng_viewer_stream */
+    private final List<StreamResponse> fStreamList;
+
+    /**
+     * Attach session response network constructor
+     *
+     * @param inNet
+     *            network input stream
+     * @throws IOException
+     *             network error
+     */
+    public AttachSessionResponse(DataInputStream inNet) throws IOException {
+        byte[] data = new byte[SIZE];
+        inNet.readFully(data, 0, SIZE);
+        ByteBuffer bb = ByteBuffer.wrap(data);
+        bb.order(ByteOrder.BIG_ENDIAN);
+        fStatus = AttachReturnCode.values()[bb.getInt() - 1];
+        fStreamsCount = bb.getInt();
+        Builder<StreamResponse> streamResponses = ImmutableList.builder();
+        for (int i = 0; i < getNbStreams(); i++) {
+            streamResponses.add(new StreamResponse(inNet));
+        }
+        fStreamList = streamResponses.build();
+
+    }
+
+    /**
+     * Gets the Status
+     *
+     * @return the Status
+     */
+    public AttachReturnCode getStatus() {
+        return fStatus;
+    }
+
+    /**
+     * Gets the StreamsCount
+     *
+     * @return the StreamsCount
+     */
+    public int getNbStreams() {
+        return fStreamsCount;
+    }
+
+    /**
+     * Gets the StreamList
+     *
+     * @return the StreamList
+     */
+    public List<StreamResponse> getStreamList() {
+        return fStreamList;
+    }
+
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/Command.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/Command.java
new file mode 100644 (file)
index 0000000..706d189
--- /dev/null
@@ -0,0 +1,55 @@
+/**********************************************************************
+ * Copyright (c) 2014 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:
+ *   Matthew Khouzam - Initial implementation and API
+ *   Marc-Andre Laperle - Initial implementation and API
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
+
+/**
+ * Viewer commands
+ *
+ * @author Matthew Khouzam
+ */
+public enum Command implements IBaseCommand {
+
+    /** get version */
+    VIEWER_CONNECT(1),
+    /** list all lttng sessions */
+    VIEWER_LIST_SESSIONS(2),
+    /** attach to a session */
+    VIEWER_ATTACH_SESSION(3),
+    /** get the next index */
+    VIEWER_GET_NEXT_INDEX(4),
+    /** get packet */
+    VIEWER_GET_PACKET(5),
+    /** get metadata */
+    VIEWER_GET_METADATA(6),
+    /** get new streams */
+    VIEWER_GET_NEW_STREAMS(7),
+    /** create a new session */
+    VIEWER_CREATE_SESSION(8);
+
+    /**
+     * Command size (fCode)
+     */
+    public static final int SIZE = Integer.SIZE / 8;
+
+    private final int fCode;
+
+    private Command(int c) {
+        fCode = c;
+    }
+
+    @Override
+    public int getCommand() {
+        return fCode;
+    }
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/ConnectResponse.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/ConnectResponse.java
new file mode 100644 (file)
index 0000000..e608151
--- /dev/null
@@ -0,0 +1,118 @@
+/**********************************************************************
+ * Copyright (c) 2014 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:
+ *   Matthew Khouzam - Initial implementation and API
+ *   Marc-Andre Laperle - Initial implementation and API
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
+
+import java.io.DataInputStream;
+import java.io.IOException;
+import java.nio.ByteBuffer;
+import java.nio.ByteOrder;
+
+/**
+ * CONNECT payload.
+ *
+ * @author Matthew Khouzam
+ */
+public class ConnectResponse implements IRelayResponse, IRelayCommand {
+
+    /**
+     * Response or command size
+     *
+     * fViewerSessionId + fMajor + fMinor + fType
+     */
+    public static final int SIZE = (Long.SIZE + Integer.SIZE + Integer.SIZE + Integer.SIZE) / 8;
+    /** session id, counts from 1 and increments by session */
+    private final long fViewerSessionId;
+    /**
+     * Major version, hint, it's at least 2
+     */
+    private final int fMajor;
+    /**
+     * Minor version, hint, it's at least 4
+     */
+    private final int fMinor;
+    /**
+     * type of connect to {@link ConnectionType}
+     */
+    private final ConnectionType fType;
+
+    /**
+     * Connection response reply constructor
+     *
+     * @param inStream
+     *            the data input stream
+     * @throws IOException
+     *             a network error
+     */
+    public ConnectResponse(DataInputStream inStream) throws IOException {
+        byte data[] = new byte[SIZE];
+        inStream.readFully(data);
+        ByteBuffer bb = ByteBuffer.wrap(data);
+        bb.order(ByteOrder.BIG_ENDIAN);
+        fViewerSessionId = bb.getLong();
+        fMajor = bb.getInt();
+        fMinor = bb.getInt();
+        bb.getInt(); // Should not be used, see http://bugs.lttng.org/issues/728
+        fType = ConnectionType.VIEWER_CLIENT_COMMAND;
+    }
+
+    /**
+     * Constructor for command
+     *
+     * @param sessionID
+     *            session id
+     * @param major
+     *            the major version
+     * @param minor
+     *            the minor version
+     * @param connection
+     *            the connection type, typically VIEWER_CLIENT_COMMAND
+     */
+    public ConnectResponse(long sessionID, int major, int minor, ConnectionType connection) {
+        fViewerSessionId = sessionID;
+        fMajor = major;
+        fMinor = minor;
+        fType = connection;
+    }
+
+    /**
+     * get the major version
+     *
+     * @return the major version
+     */
+    public int getMajor() {
+        return fMajor;
+    }
+
+    /**
+     * get the minor version
+     *
+     * @return the minor version
+     */
+    public int getMinor() {
+        return fMinor;
+    }
+
+    @Override
+    public byte[] serialize() {
+        byte data[] = new byte[SIZE];
+        ByteBuffer bb = ByteBuffer.wrap(data);
+        bb.order(ByteOrder.BIG_ENDIAN);
+        bb.putLong(fViewerSessionId);
+        bb.putInt(fMajor);
+        bb.putInt(fMinor);
+        bb.putInt(fType.getCommand());
+        return data;
+    }
+
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/ConnectionType.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/ConnectionType.java
new file mode 100644 (file)
index 0000000..a89c374
--- /dev/null
@@ -0,0 +1,39 @@
+/**********************************************************************
+ * Copyright (c) 2014 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:
+ *   Matthew Khouzam - Initial implementation and API
+ *   Marc-Andre Laperle - Initial implementation and API
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
+
+/**
+ * Get viewer connection type
+ *
+ * @author Matthew Khouzam
+ */
+public enum ConnectionType implements IBaseCommand {
+
+    /** Command sent */
+    VIEWER_CLIENT_COMMAND(1),
+    /** Notification sent */
+    VIEWER_CLIENT_NOTIFICATION(2);
+
+    private final int fCode;
+
+    private ConnectionType(int c) {
+        fCode = c;
+    }
+
+    @Override
+    public int getCommand() {
+        return fCode;
+    }
+
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/CreateSessionResponse.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/CreateSessionResponse.java
new file mode 100644 (file)
index 0000000..6e988f6
--- /dev/null
@@ -0,0 +1,61 @@
+/**********************************************************************
+ * Copyright (c) 2014 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:
+ *   Matthew Khouzam - Initial implementation and API
+ *   Marc-Andre Laperle - Initial implementation and API
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
+
+import java.io.DataInputStream;
+import java.io.IOException;
+import java.nio.ByteBuffer;
+import java.nio.ByteOrder;
+
+/**
+ * Response to a "create session" command
+ *
+ * @author Matthew Khouzam
+ */
+public class CreateSessionResponse implements IRelayResponse {
+
+    /**
+     * Response size (fStatus)
+     */
+    public static final int SIZE = Integer.SIZE / 8;
+
+    /** enum lttng_viewer_create_session_return_code */
+    private final CreateSessionReturnCode fStatus;
+
+    /**
+     * Create session response network constructor
+     *
+     * @param inNet
+     *            network input stream
+     * @throws IOException
+     *             network error
+     */
+    public CreateSessionResponse(DataInputStream inNet) throws IOException {
+        byte[] data = new byte[SIZE];
+        inNet.readFully(data);
+        ByteBuffer bb = ByteBuffer.wrap(data);
+        bb.order(ByteOrder.BIG_ENDIAN);
+        fStatus = (CreateSessionReturnCode.values()[bb.getInt() - 1]);
+    }
+
+    /**
+     * Get status
+     *
+     * @return the status
+     */
+    public CreateSessionReturnCode getStatus() {
+        return fStatus;
+    }
+
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/CreateSessionReturnCode.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/CreateSessionReturnCode.java
new file mode 100644 (file)
index 0000000..cd910a2
--- /dev/null
@@ -0,0 +1,38 @@
+/**********************************************************************
+ * Copyright (c) 2014 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:
+ *   Matthew Khouzam - Initial implementation and API
+ *   Marc-Andre Laperle - Initial implementation and API
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
+
+/**
+ * Create new session return code
+ *
+ * @author Matthew Khouzam
+ */
+public enum CreateSessionReturnCode implements IBaseCommand {
+
+    /** If new streams are being sent. */
+    LTTNG_VIEWER_CREATE_SESSION_OK(1),
+    /** Fatal error on the server-side. */
+    LTTNG_VIEWER_CREATE_SESSION_ERR(2);
+
+    private final int fCode;
+
+    private CreateSessionReturnCode(int c) {
+        fCode = c;
+    }
+
+    @Override
+    public int getCommand() {
+        return fCode;
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/GetMetadata.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/GetMetadata.java
new file mode 100644 (file)
index 0000000..13c61dc
--- /dev/null
@@ -0,0 +1,64 @@
+/**********************************************************************
+ * Copyright (c) 2014 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:
+ *   Matthew Khouzam - Initial implementation and API
+ *   Marc-Andre Laperle - Initial implementation and API
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
+
+import java.nio.ByteBuffer;
+import java.nio.ByteOrder;
+
+/**
+ * VIEWER_GET_METADATA payload.
+ *
+ * @author Matthew Khouzam
+ */
+public class GetMetadata implements IRelayCommand {
+
+    /**
+     * Command size (fStreamId)
+     */
+    public static final int SIZE = Long.SIZE / 8;
+
+    /**
+     * The stream id
+     */
+    private final long fStreamId;
+
+    /**
+     * Set the stream id
+     *
+     * @param streamId
+     *            the stream id
+     */
+    public GetMetadata(long streamId) {
+        fStreamId = streamId;
+    }
+
+    /**
+     * Get the stream id
+     *
+     * @return the stream id
+     */
+    public long getStreamId() {
+        return fStreamId;
+    }
+
+    @Override
+    public byte[] serialize() {
+        byte data[] = new byte[SIZE];
+        ByteBuffer bb = ByteBuffer.wrap(data);
+        bb.order(ByteOrder.BIG_ENDIAN);
+        bb.putLong(getStreamId());
+        return data;
+    }
+
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/GetMetadataReturnCode.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/GetMetadataReturnCode.java
new file mode 100644 (file)
index 0000000..f126dc4
--- /dev/null
@@ -0,0 +1,41 @@
+/**********************************************************************
+ * Copyright (c) 2014 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:
+ *   Matthew Khouzam - Initial implementation and API
+ *   Marc-Andre Laperle - Initial implementation and API
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
+
+/**
+ * Get metadata return code
+ *
+ * @author Matthew Khouzam
+ */
+public enum GetMetadataReturnCode implements IBaseCommand {
+
+    /** Response was OK */
+    VIEWER_METADATA_OK(1),
+    /** Response was nothing new */
+    VIEWER_NO_NEW_METADATA(2),
+    /** Response was Error */
+    VIEWER_METADATA_ERR(3);
+
+    private final int fCode;
+
+    private GetMetadataReturnCode(int c) {
+        fCode = c;
+    }
+
+    @Override
+    public int getCommand() {
+        return fCode;
+    }
+
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/GetNextIndex.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/GetNextIndex.java
new file mode 100644 (file)
index 0000000..697789a
--- /dev/null
@@ -0,0 +1,63 @@
+/**********************************************************************
+ * Copyright (c) 2014 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:
+ *   Matthew Khouzam - Initial implementation and API
+ *   Marc-Andre Laperle - Initial implementation and API
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
+
+import java.nio.ByteBuffer;
+import java.nio.ByteOrder;
+
+/**
+ * VIEWER_GET_NEXT_INDEX payload.
+ *
+ * @author Matthew Khouzam
+ */
+public class GetNextIndex implements IRelayCommand {
+
+    /**
+     * Command size (fStreamId)
+     */
+    public static final int SIZE = Long.SIZE / 8;
+    /**
+     * the id of the stream
+     */
+    private final long fStreamId;
+
+    /**
+     * Constructor
+     *
+     * @param streamId
+     *            the index stream id
+     */
+    public GetNextIndex(long streamId) {
+        fStreamId = streamId;
+    }
+
+    /**
+     * Gets the stream id
+     *
+     * @return the stream id
+     */
+    public long getStreamId() {
+        return fStreamId;
+    }
+
+    @Override
+    public byte[] serialize() {
+        byte data[] = new byte[SIZE];
+        ByteBuffer bb = ByteBuffer.wrap(data);
+        bb.order(ByteOrder.BIG_ENDIAN);
+        bb.putLong(getStreamId());
+        return data;
+    }
+
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/GetPacket.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/GetPacket.java
new file mode 100644 (file)
index 0000000..2eb0483
--- /dev/null
@@ -0,0 +1,93 @@
+/**********************************************************************
+ * Copyright (c) 2014 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:
+ *   Matthew Khouzam - Initial implementation and API
+ *   Marc-Andre Laperle - Initial implementation and API
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
+
+import java.nio.ByteBuffer;
+import java.nio.ByteOrder;
+
+/**
+ * VIEWER_GET_PACKET payload.
+ *
+ * @author Matthew Khouzam
+ */
+public class GetPacket implements IRelayCommand {
+
+    /**
+     * Command size
+     *
+     * fStreamId + fOffset + fLength
+     */
+    public static final int SIZE = (Long.SIZE + Long.SIZE + Integer.SIZE) / 8;
+    /** the stream Id */
+    private final long fStreamId;
+    /** the offset */
+    private final long fOffset;
+    /** the length of the packet */
+    private final int fLength;
+
+    /**
+     * Get packet constructor
+     *
+     * @param streamId
+     *            the stream id
+     * @param offset
+     *            the offset
+     * @param length
+     *            the packet length
+     */
+    public GetPacket(long streamId, long offset, int length) {
+        fStreamId = streamId;
+        fOffset = offset;
+        fLength = length;
+    }
+
+    /**
+     * Get the length of the packet
+     *
+     * @return the length of the packet in bytes
+     */
+    public int getLength() {
+        return fLength;
+    }
+
+    /**
+     * Gets the offset of the packet
+     *
+     * @return the offset
+     */
+    public long getOffset() {
+        return fOffset;
+    }
+
+    /**
+     * Gets the stream id
+     *
+     * @return the stream id
+     */
+    public long getStreamId() {
+        return fStreamId;
+    }
+
+    @Override
+    public byte[] serialize() {
+        byte data[] = new byte[SIZE];
+        ByteBuffer bb = ByteBuffer.wrap(data);
+        bb.order(ByteOrder.BIG_ENDIAN);
+        bb.putLong(getStreamId());
+        bb.putLong(getOffset());
+        bb.putInt(getLength());
+        return data;
+    }
+
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/GetPacketReturnCode.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/GetPacketReturnCode.java
new file mode 100644 (file)
index 0000000..b46d171
--- /dev/null
@@ -0,0 +1,43 @@
+/**********************************************************************
+ * Copyright (c) 2014 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:
+ *   Matthew Khouzam - Initial implementation and API
+ *   Marc-Andre Laperle - Initial implementation and API
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
+
+/**
+ * Get packet return code
+ *
+ * @author Matthew Khouzam
+ */
+public enum GetPacketReturnCode implements IBaseCommand {
+
+    /** Response was OK */
+    VIEWER_GET_PACKET_OK(1),
+    /** Response was RETRY */
+    VIEWER_GET_PACKET_RETRY(2),
+    /** Response was ERROR */
+    VIEWER_GET_PACKET_ERR(3),
+    /** Response was End of File */
+    VIEWER_GET_PACKET_EOF(4);
+
+    private final int fCode;
+
+    private GetPacketReturnCode(int c) {
+        fCode = c;
+    }
+
+    @Override
+    public int getCommand() {
+        return fCode;
+    }
+
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/IBaseCommand.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/IBaseCommand.java
new file mode 100644 (file)
index 0000000..16fe7b3
--- /dev/null
@@ -0,0 +1,29 @@
+/**********************************************************************
+ * Copyright (c) 2014 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:
+ *   Matthew Khouzam - Initial implementation and API
+ *   Marc-Andre Laperle - Initial implementation and API
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
+
+/**
+ * Instruction to send to relayd
+ *
+ * @author Matthew Khouzam
+ */
+public interface IBaseCommand {
+
+    /**
+     * gets the numerical value of the command
+     *
+     * @return the numerical value of the command
+     */
+    int getCommand();
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/IRelayCommand.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/IRelayCommand.java
new file mode 100644 (file)
index 0000000..4c0f5e6
--- /dev/null
@@ -0,0 +1,30 @@
+/**********************************************************************
+ * Copyright (c) 2014 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:
+ *   Matthew Khouzam - Initial implementation and API
+ *   Marc-Andre Laperle - Initial implementation and API
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
+
+
+/**
+ * Command sent, needs a getBytes to stream the data
+ *
+ * @author Matthew Khouzam
+ */
+public interface IRelayCommand {
+
+    /**
+     * Gets a byte array of the command so that it may be streamed
+     *
+     * @return the byte array of the command
+     */
+    byte[] serialize();
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/IRelayResponse.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/IRelayResponse.java
new file mode 100644 (file)
index 0000000..b034da6
--- /dev/null
@@ -0,0 +1,23 @@
+/**********************************************************************
+ * Copyright (c) 2014 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:
+ *   Matthew Khouzam - Initial implementation and API
+ *   Marc-Andre Laperle - Initial implementation and API
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
+
+/**
+ * Command response, this will allow sorting commands easier
+ *
+ * @author Matthew Khouzam
+ */
+public interface IRelayResponse {
+
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/IndexResponse.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/IndexResponse.java
new file mode 100644 (file)
index 0000000..ebfcf88
--- /dev/null
@@ -0,0 +1,162 @@
+/**********************************************************************
+ * Copyright (c) 2014 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:
+ *   Matthew Khouzam - Initial implementation and API
+ *   Marc-Andre Laperle - Initial implementation and API
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
+
+import java.io.DataInputStream;
+import java.io.IOException;
+import java.nio.ByteBuffer;
+import java.nio.ByteOrder;
+
+/**
+ * An Lttng packet index
+ *
+ * @author Matthew Khouzam
+ */
+public class IndexResponse implements IRelayResponse {
+
+    /**
+     * Command size
+     *
+     * Sum of the field sizes / 8 ( 7 longs and 2 ints):
+     * fOffset + fPacketSize + fContentSize + fTimestampBegin + fTimestampEnd +
+     * fEventsDiscarded + fStreamId + fStatus + fFlags
+     */
+    public static final int SIZE =
+            (Long.SIZE * 7 + Integer.SIZE * 2) / 8;
+
+    /** the offset */
+    private final long fOffset;
+    /** packet_size */
+    private final long fPacketSize;
+    /** the content size - how much of the packet is used */
+    private final long fContentSize;
+    /** timestamp of the beginning of the packet */
+    private final long fTimestampBegin;
+    /** timestamp of the end of the packet */
+    private final long fTimestampEnd;
+    /** number of discarded events BEFORE this packet */
+    private final long fEventsDiscarded;
+    /** the CTF stream id */
+    private final long fStreamId;
+    /** the status of the getNextIndex request */
+    private final NextIndexReturnCode fStatus;
+    /** whether there are new streams or metadata */
+    private final int fFlags;
+
+    /**
+     * IndexResposne from network
+     *
+     * @param inNet
+     *            data input stream
+     * @throws IOException
+     *             network error
+     */
+    public IndexResponse(DataInputStream inNet) throws IOException {
+        byte[] data = new byte[SIZE];
+        inNet.readFully(data);
+        ByteBuffer bb = ByteBuffer.wrap(data);
+        bb.order(ByteOrder.BIG_ENDIAN);
+        fOffset = bb.getLong();
+        fPacketSize = bb.getLong();
+        fContentSize = bb.getLong();
+        fTimestampBegin = bb.getLong();
+        fTimestampEnd = bb.getLong();
+        fEventsDiscarded = bb.getLong();
+        fStreamId = bb.getLong();
+        fStatus = NextIndexReturnCode.values()[bb.getInt() - 1];
+        fFlags = bb.getInt();
+    }
+
+    /**
+     * Gets the offset
+     *
+     * @return the offset
+     */
+    public long getOffset() {
+        return fOffset;
+    }
+
+    /**
+     * Gets the packet size
+     *
+     * @return the packet size
+     */
+    public long getPacketSize() {
+        return fPacketSize;
+    }
+
+    /**
+     * Gets the content size - how much of the packet is used
+     *
+     * @return the content size
+     */
+    public long getContentSize() {
+        return fContentSize;
+    }
+
+    /**
+     * Gets the timestamp of the beginning of the packet
+     *
+     * @return the timestamp of the beginning of the packet
+     */
+    public long getTimestampBegin() {
+        return fTimestampBegin;
+    }
+
+    /**
+     * Gets the timestamp of the end of the packet
+     *
+     * @return the timestamp of the end of the packet
+     */
+    public long getTimestampEnd() {
+        return fTimestampEnd;
+    }
+
+    /**
+     * Gets the number of discarded events BEFORE this packet
+     *
+     * @return the number of discarded events BEFORE this packet
+     */
+    public long getEventsDiscarded() {
+        return fEventsDiscarded;
+    }
+
+    /**
+     * Gets the CTF stream id
+     *
+     * @return the CTF stream id
+     */
+    public long getStreamId() {
+        return fStreamId;
+    }
+
+    /**
+     * Gets the status
+     *
+     * @return the status
+     */
+    public NextIndexReturnCode getStatus() {
+        return fStatus;
+    }
+
+    /**
+     * Gets the flags that describe whether there are new streams or metadata
+     *
+     * @return the flags
+     */
+    public int getFlags() {
+        return fFlags;
+    }
+
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/ListSessionsResponse.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/ListSessionsResponse.java
new file mode 100644 (file)
index 0000000..532c8a5
--- /dev/null
@@ -0,0 +1,71 @@
+/**********************************************************************
+ * Copyright (c) 2014 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:
+ *   Matthew Khouzam - Initial implementation and API
+ *   Marc-Andre Laperle - Initial implementation and API
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
+
+import java.io.DataInputStream;
+import java.io.IOException;
+import java.nio.ByteBuffer;
+import java.nio.ByteOrder;
+import java.util.List;
+
+import com.google.common.collect.ImmutableList;
+import com.google.common.collect.ImmutableList.Builder;
+
+/**
+ * VIEWER_LIST_SESSIONS payload.
+ *
+ * @author Matthew Khouzam
+ */
+public class ListSessionsResponse implements IRelayResponse {
+
+    /**
+     * Response size (nbSessions)
+     */
+    public static final int PACKET_FIXED_SIZE = Integer.SIZE / 8;
+
+    /** the list of sessions */
+    private final List<SessionResponse> fSessionList;
+
+    /**
+     * List Sessions response from network
+     *
+     * @param inNet
+     *            the network stream
+     * @throws IOException
+     *             network error
+     */
+    public ListSessionsResponse(DataInputStream inNet) throws IOException {
+        byte[] data = new byte[PACKET_FIXED_SIZE];
+        inNet.readFully(data);
+        ByteBuffer bb = ByteBuffer.wrap(data);
+        bb.order(ByteOrder.BIG_ENDIAN);
+        int nbSessions = bb.getInt();
+        Builder<SessionResponse> sl = new ImmutableList.Builder<>();
+        for (int session = 0; session < nbSessions; session++) {
+            sl.add(new SessionResponse(inNet));
+        }
+        fSessionList = sl.build();
+    }
+
+    /**
+     * Gets the session list
+     *
+     * @return the sessions list
+     */
+    public List<SessionResponse> getSessionsList() {
+        return fSessionList;
+    }
+
+
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/LttngViewerCommands.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/LttngViewerCommands.java
new file mode 100644 (file)
index 0000000..4a77664
--- /dev/null
@@ -0,0 +1,36 @@
+/**********************************************************************
+ * Copyright (c) 2014 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:
+ *   Matthew Khouzam - Initial implementation
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
+
+/**
+ * LTTng Relay Daemon API. needs a TCP connection, API is defined from
+ * BSD-licensed implementation in Lttng tools: <a href=
+ * "http://git.lttng.org/?p=lttng-tools.git;a=blob;f=src/bin/lttng-relayd/lttng-viewer-abi.h"
+ * > src/bin/lttng-relayd/lttng-viewer-abi.h</a>
+ *
+ * @author Matthew Khouzam
+ */
+public interface LttngViewerCommands {
+
+    /** Maximum path name length */
+    static final int LTTNG_VIEWER_PATH_MAX = 4096;
+    /** Maximum name length */
+    static final int LTTNG_VIEWER_NAME_MAX = 255;
+    /** Maximum host name length */
+    static final int LTTNG_VIEWER_HOST_NAME_MAX = 64;
+    /** New stream in the trace */
+    static final int NEW_STREAM = (1 << 1);
+    /** New metadata in the trace */
+    static final int NEW_METADATA = (1 << 0);
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/MetadataPacketResponse.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/MetadataPacketResponse.java
new file mode 100644 (file)
index 0000000..528593c
--- /dev/null
@@ -0,0 +1,78 @@
+/**********************************************************************
+ * Copyright (c) 2014 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:
+ *   Matthew Khouzam - Initial implementation and API
+ *   Marc-Andre Laperle - Initial implementation and API
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
+
+import java.io.DataInputStream;
+import java.io.IOException;
+import java.nio.ByteBuffer;
+import java.nio.ByteOrder;
+
+/**
+ * Metadata packet response containing a packet of metadata
+ *
+ * @author Matthew Khouzam
+ */
+public class MetadataPacketResponse implements IRelayResponse {
+
+    /**
+     * Response size
+     *
+     * fData.length + fStatus
+     */
+    private static final int SIZE = (Long.SIZE + Integer.SIZE) / 8;
+    /** status of the metadata request */
+    private final GetMetadataReturnCode fStatus;
+    /** the packet */
+    private final byte fData[];
+
+    /**
+     * Read new metadata packet from the network
+     *
+     * @param inNet
+     *            network input reader
+     * @throws IOException
+     *             network error
+     */
+    public MetadataPacketResponse(DataInputStream inNet) throws IOException {
+        byte[] data = new byte[SIZE];
+        inNet.readFully(data);
+        ByteBuffer bb = ByteBuffer.wrap(data);
+        bb.order(ByteOrder.BIG_ENDIAN);
+        long length = bb.getLong();
+        fStatus = GetMetadataReturnCode.values()[bb.getInt() - 1];
+        if (length >= Integer.MAX_VALUE) {
+            throw new IOException("Metadata Packet too big " + length); //$NON-NLS-1$
+        }
+        fData = new byte[(int) length];
+        inNet.readFully(fData);
+    }
+
+    /**
+     * Get the packet
+     *
+     * @return the packet
+     */
+    public byte[] getData() {
+        return fData;
+    }
+
+    /**
+     * Gets the status
+     *
+     * @return the status
+     */
+    public GetMetadataReturnCode getStatus() {
+        return fStatus;
+    }
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/NewStreamsRequest.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/NewStreamsRequest.java
new file mode 100644 (file)
index 0000000..edb2c68
--- /dev/null
@@ -0,0 +1,52 @@
+/**********************************************************************
+ * Copyright (c) 2014 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:
+ *   Matthew Khouzam - Initial implementation and API
+ *   Marc-Andre Laperle - Initial implementation and API
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
+
+import java.nio.ByteBuffer;
+import java.nio.ByteOrder;
+
+/**
+ * LTTNG_VIEWER_GET_NEW_STREAMS payload.
+ *
+ * @author Matthew Khouzam
+ */
+public class NewStreamsRequest implements IRelayCommand {
+
+    /**
+     * Command size (fSessionId)
+     */
+    public static final int SIZE = Long.SIZE / 8;
+
+    /** session ID */
+    private final long fSessionId;
+
+    /**
+     * Constructor
+     *
+     * @param sessionId
+     *            the session id we want
+     */
+    public NewStreamsRequest(long sessionId) {
+        fSessionId = sessionId;
+    }
+
+    @Override
+    public byte[] serialize() {
+        byte data[] = new byte[SIZE];
+        ByteBuffer bb = ByteBuffer.wrap(data);
+        bb.order(ByteOrder.BIG_ENDIAN);
+        bb.putLong(fSessionId);
+        return data;
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/NewStreamsResponse.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/NewStreamsResponse.java
new file mode 100644 (file)
index 0000000..b02ef88
--- /dev/null
@@ -0,0 +1,95 @@
+/**********************************************************************
+ * Copyright (c) 2014 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:
+ *   Matthew Khouzam - Initial implementation and API
+ *   Marc-Andre Laperle - Initial implementation and API
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
+
+import java.io.DataInputStream;
+import java.io.IOException;
+import java.nio.ByteBuffer;
+import java.nio.ByteOrder;
+import java.util.List;
+
+import com.google.common.collect.ImmutableList;
+
+/**
+ * Response to a "new streams" command
+ *
+ * @author Matthew Khouzam
+ */
+public class NewStreamsResponse implements IRelayResponse {
+
+    /**
+     * Response size
+     *
+     * fStatus + fNbStreams
+     */
+    private static final int SIZE = (Integer.SIZE + Integer.SIZE) / 8;
+    /** status of the request */
+    private final NewStreamsReturnCode fStatus;
+    /** the number of streams */
+    private final int fNbStreams;
+    /** the list of streams in the response */
+    private final List<StreamResponse> fStreamList;
+
+    /**
+     * New stream response network constructor
+     *
+     * @param inNet
+     *            network stream
+     * @throws IOException
+     *             network error
+     */
+    public NewStreamsResponse(DataInputStream inNet) throws IOException {
+        byte[] data = new byte[SIZE];
+        inNet.readFully(data);
+        ByteBuffer bb = ByteBuffer.wrap(data);
+        bb.order(ByteOrder.BIG_ENDIAN);
+        fStatus = NewStreamsReturnCode.values()[bb.getInt() - 1];
+        fNbStreams = bb.getInt();
+        ImmutableList.Builder<StreamResponse> sl = new ImmutableList.Builder<>();
+        if (getStatus().equals(NewStreamsReturnCode.LTTNG_VIEWER_NEW_STREAMS_OK)) {
+            for (int stream = 0; stream < fNbStreams; stream++) {
+                sl.add(new StreamResponse(inNet));
+            }
+        }
+        fStreamList = sl.build();
+    }
+
+    /**
+     * Gets the status
+     *
+     * @return the status
+     */
+    public NewStreamsReturnCode getStatus() {
+        return fStatus;
+    }
+
+    /**
+     * gets the stream list
+     *
+     * @return the stream list
+     */
+    public List<StreamResponse> getStreamList() {
+        return fStreamList;
+    }
+
+    /**
+     * The number of streams
+     *
+     * @return the number of streams
+     */
+    public int getNbStreams() {
+        return fNbStreams;
+    }
+
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/NewStreamsReturnCode.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/NewStreamsReturnCode.java
new file mode 100644 (file)
index 0000000..aa324f7
--- /dev/null
@@ -0,0 +1,42 @@
+/**********************************************************************
+ * Copyright (c) 2014 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:
+ *   Matthew Khouzam - Initial implementation and API
+ *   Marc-Andre Laperle - Initial implementation and API
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
+
+/**
+ * Return codes for "new streams" command
+ *
+ * @author Matthew Khouzam
+ */
+public enum NewStreamsReturnCode implements IBaseCommand {
+
+    /** If new streams are being sent. */
+    LTTNG_VIEWER_NEW_STREAMS_OK(1),
+    /** If no new streams are available. */
+    LTTNG_VIEWER_NEW_STREAMS_NO_NEW(2),
+    /** Error. */
+    LTTNG_VIEWER_NEW_STREAMS_ERR(3),
+    /** Session closed. */
+    LTTNG_VIEWER_NEW_STREAMS_HUP(4);
+
+    private final int fCode;
+
+    private NewStreamsReturnCode(int c) {
+        fCode = c;
+    }
+
+    @Override
+    public int getCommand() {
+        return fCode;
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/NextIndexReturnCode.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/NextIndexReturnCode.java
new file mode 100644 (file)
index 0000000..3c5c32a
--- /dev/null
@@ -0,0 +1,46 @@
+/**********************************************************************
+ * Copyright (c) 2014 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:
+ *   Matthew Khouzam - Initial implementation and API
+ *   Marc-Andre Laperle - Initial implementation and API
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
+
+/**
+ * Get next index return code (hope it's viewer_index_ok)
+ *
+ * @author Matthew Khouzam
+ */
+public enum NextIndexReturnCode implements IBaseCommand {
+
+    /** Index is available. */
+    VIEWER_INDEX_OK(1),
+    /** Index not yet available. */
+    VIEWER_INDEX_RETRY(2),
+    /** Index closed (trace destroyed). */
+    VIEWER_INDEX_HUP(3),
+    /** Unknown error. */
+    VIEWER_INDEX_ERR(4),
+    /** Inactive stream beacon. */
+    VIEWER_INDEX_INACTIVE(5),
+    /** End of index file. */
+    VIEWER_INDEX_EOF(6);
+
+    private final int fCode;
+
+    private NextIndexReturnCode(int c) {
+        fCode = c;
+    }
+
+    @Override
+    public int getCommand() {
+        return fCode;
+    }
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/SeekCommand.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/SeekCommand.java
new file mode 100644 (file)
index 0000000..e187830
--- /dev/null
@@ -0,0 +1,43 @@
+/**********************************************************************
+ * Copyright (c) 2014 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:
+ *   Matthew Khouzam - Initial implementation and API
+ *   Marc-Andre Laperle - Initial implementation and API
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
+
+/**
+ * Seek command
+ *
+ * @author Matthew Khouzam
+ */
+public enum SeekCommand implements IBaseCommand {
+
+    /** Receive the trace packets from the beginning. */
+    VIEWER_SEEK_BEGINNING(1),
+    /** Receive the trace packets from now. */
+    VIEWER_SEEK_LAST(2);
+
+    private final int fCode;
+
+    /**
+     * Command size (fCode)
+     */
+    public static final int SIZE = Integer.SIZE / 8;
+
+    private SeekCommand(int c) {
+        fCode = c;
+    }
+
+    @Override
+    public int getCommand() {
+        return fCode;
+    }
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/SessionResponse.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/SessionResponse.java
new file mode 100644 (file)
index 0000000..7253ecb
--- /dev/null
@@ -0,0 +1,127 @@
+/**********************************************************************
+ * Copyright (c) 2014 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:
+ *   Matthew Khouzam - Initial implementation and API
+ *   Marc-Andre Laperle - Initial implementation and API
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
+
+import java.io.DataInputStream;
+import java.io.IOException;
+import java.nio.ByteBuffer;
+import java.nio.ByteOrder;
+
+/**
+ * Get viewer session response to command
+ *
+ * @author Matthew Khouzam
+ */
+public class SessionResponse implements IRelayResponse {
+
+    /**
+     * Response size
+     *
+     * fHostname + fSessionName + fId + fLiveTimer + fClients + fStreams
+     */
+    public static final int SIZE =
+            LttngViewerCommands.LTTNG_VIEWER_HOST_NAME_MAX + LttngViewerCommands.LTTNG_VIEWER_NAME_MAX + (Long.SIZE + Integer.SIZE + Integer.SIZE + Integer.SIZE) / 8;
+    /** id of the session */
+    private final long fId;
+    /** live timer */
+    private final int fLiveTimer;
+    /** number of clients */
+    private final int fClients;
+    /** number streams */
+    private final int fStreams;
+    /** Hostname, like 'localhost' */
+    private final String fHostname;
+    /** Session name, like 'streaming session' */
+    private final String fSessionName;
+
+    /**
+     * Session response network constructor
+     *
+     * @param inNet
+     *            input network stream
+     * @throws IOException
+     *             network error
+     */
+    public SessionResponse(DataInputStream inNet) throws IOException {
+        byte[] data = new byte[SIZE];
+        inNet.readFully(data);
+        ByteBuffer bb = ByteBuffer.wrap(data);
+        bb.order(ByteOrder.BIG_ENDIAN);
+        fId = bb.getLong();
+        fLiveTimer = bb.getInt();
+        fClients = bb.getInt();
+        fStreams = bb.getInt();
+        byte[] hostName = new byte[LttngViewerCommands.LTTNG_VIEWER_HOST_NAME_MAX];
+        byte[] sessionName = new byte[LttngViewerCommands.LTTNG_VIEWER_NAME_MAX];
+        bb.get(hostName, 0, hostName.length);
+        bb.get(sessionName, 0, sessionName.length);
+        fHostname = new String(hostName);
+        fSessionName = new String(sessionName);
+    }
+
+    /**
+     * Gets the id of the session
+     *
+     * @return the id of the session
+     */
+    public long getId() {
+        return fId;
+    }
+
+    /**
+     * Gets the live timer
+     *
+     * @return the live timer
+     */
+    public int getLiveTimer() {
+        return fLiveTimer;
+    }
+
+    /**
+     * Gets the number of clients
+     *
+     * @return the number of clients
+     */
+    public int getClients() {
+        return fClients;
+    }
+
+    /**
+     * Gets the number streams
+     *
+     * @return the number streams
+     */
+    public int getStreams() {
+        return fStreams;
+    }
+
+    /**
+     * Gets the Hostname
+     *
+     * @return the Hostname
+     */
+    public String getHostname() {
+        return fHostname;
+    }
+
+    /**
+     * Gets the session name
+     *
+     * @return the session name
+     */
+    public String getSessionName() {
+        return fSessionName;
+    }
+
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/StreamResponse.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/StreamResponse.java
new file mode 100644 (file)
index 0000000..89d2c34
--- /dev/null
@@ -0,0 +1,126 @@
+/**********************************************************************
+ * Copyright (c) 2014 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:
+ *   Matthew Khouzam - Initial implementation and API
+ *   Marc-Andre Laperle - Initial implementation and API
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
+
+import java.io.DataInputStream;
+import java.io.IOException;
+import java.nio.ByteBuffer;
+import java.nio.ByteOrder;
+
+/**
+ * Get response of viewer stream
+ *
+ * @author Matthew Khouzam
+ */
+public class StreamResponse implements IRelayResponse {
+
+    /**
+     * Response size
+     *
+     * fId + fCtfTraceId + fMetadataFlag + fPathName + fChannelName
+     */
+    public static final int SIZE = (Long.SIZE + Long.SIZE + Integer.SIZE) / 8 + LttngViewerCommands.LTTNG_VIEWER_PATH_MAX + LttngViewerCommands.LTTNG_VIEWER_NAME_MAX;
+
+    /**
+     * id of the stream
+     */
+    private final long fId;
+    /**
+     * It is guaranteed to be unique, because the value is assigned sequentially
+     * by the relay.
+     */
+    private final long fCtfTraceId;
+    /**
+     * if the stream is a metadata stream
+     */
+    private final int fMetadataFlag;
+    /**
+     * the path
+     */
+    private final String fPathName;
+    /**
+     * The channel, traditionally channel0
+     */
+    private final String fChannelName;
+
+    /**
+     * Stream response
+     *
+     * @param inNet
+     *            input data stream
+     * @throws IOException
+     *             network time
+     */
+    public StreamResponse(DataInputStream inNet) throws IOException {
+        byte[] streamData = new byte[SIZE];
+        inNet.readFully(streamData, 0, SIZE);
+        ByteBuffer bb = ByteBuffer.wrap(streamData);
+        bb.order(ByteOrder.BIG_ENDIAN);
+        fId = (bb.getLong());
+        fCtfTraceId = bb.getLong();
+        fMetadataFlag = bb.getInt();
+        byte pathName[] = new byte[LttngViewerCommands.LTTNG_VIEWER_PATH_MAX];
+        byte channelName[] = new byte[LttngViewerCommands.LTTNG_VIEWER_NAME_MAX];
+        bb.get(pathName, 0, LttngViewerCommands.LTTNG_VIEWER_PATH_MAX);
+        bb.get(channelName, 0, LttngViewerCommands.LTTNG_VIEWER_NAME_MAX);
+        fPathName = new String(pathName);
+        fChannelName = new String(channelName);
+    }
+
+    /**
+     * Get the id
+     *
+     * @return the Id
+     */
+    public long getId() {
+        return fId;
+    }
+
+    /**
+     * Get the CtfTraceId
+     *
+     * @return the CtfTraceId
+     */
+    public long getCtfTraceId() {
+        return fCtfTraceId;
+    }
+
+    /**
+     * Get the metadata flag
+     *
+     * @return the MetadataFlag
+     */
+    public int getMetadataFlag() {
+        return fMetadataFlag;
+    }
+
+    /**
+     * Get the path name
+     *
+     * @return the PathName
+     */
+    public String getPathName() {
+        return fPathName;
+    }
+
+    /**
+     * get the Channel name
+     *
+     * @return the ChannelName
+     */
+    public String getChannelName() {
+        return fChannelName;
+    }
+
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/TracePacketResponse.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/TracePacketResponse.java
new file mode 100644 (file)
index 0000000..11fa823
--- /dev/null
@@ -0,0 +1,92 @@
+/**********************************************************************
+ * Copyright (c) 2014 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:
+ *   Matthew Khouzam - Initial implementation and API
+ *   Marc-Andre Laperle - Initial implementation and API
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
+
+import java.io.DataInputStream;
+import java.io.IOException;
+import java.nio.ByteBuffer;
+import java.nio.ByteOrder;
+
+/**
+ * Response to getpacket command
+ *
+ * @author Matthew Khouzam
+ */
+public class TracePacketResponse implements IRelayResponse {
+
+    /**
+     * Command size
+     *
+     * fStatus + fData.length + fFlags
+     */
+    private static final int SIZE = (Integer.SIZE + Integer.SIZE + Integer.SIZE) / 8;
+    /** Enum lttng_viewer_get_packet_return_code */
+    private final GetPacketReturnCode fStatus;
+    /** flags: is there new metadata or new streams? */
+    private final int fFlags;
+    /** the packet */
+    private final byte[] fData;
+
+    /**
+     * Trace packet response network constructor
+     *
+     * @param inNet
+     *            network input stream
+     * @throws IOException
+     *             network error
+     */
+    public TracePacketResponse(DataInputStream inNet) throws IOException {
+        byte[] data = new byte[SIZE];
+        inNet.readFully(data);
+        ByteBuffer bb = ByteBuffer.wrap(data);
+        bb.order(ByteOrder.BIG_ENDIAN);
+        fStatus = GetPacketReturnCode.values()[bb.getInt() - 1];
+        int length = bb.getInt();
+        fFlags = bb.getInt();
+        if (fStatus.equals(GetPacketReturnCode.VIEWER_GET_PACKET_OK)) {
+            fData = new byte[length];
+            inNet.readFully(fData);
+        } else {
+            fData = new byte[0];
+        }
+    }
+
+    /**
+     * Get the status
+     *
+     * @return the Status
+     */
+    public GetPacketReturnCode getStatus() {
+        return fStatus;
+    }
+
+    /**
+     * Get the flags
+     *
+     * @return the Flags
+     */
+    public int getFlags() {
+        return fFlags;
+    }
+
+    /**
+     * Get the packet data, please do not modify the data
+     *
+     * @return the Data
+     */
+    public byte[] getData() {
+        return fData;
+    }
+
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/ViewerCommand.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/ViewerCommand.java
new file mode 100644 (file)
index 0000000..06e6b16
--- /dev/null
@@ -0,0 +1,95 @@
+/**********************************************************************
+ * Copyright (c) 2014 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:
+ *   Matthew Khouzam - Initial implementation and API
+ *   Marc-Andre Laperle - Initial implementation and API
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
+
+import java.nio.ByteBuffer;
+import java.nio.ByteOrder;
+
+/**
+ * The LTTng command
+ *
+ * @author Matthew Khouzam
+ */
+public class ViewerCommand implements IRelayCommand {
+
+    /**
+     * Command size
+     *
+     * fDataSize + fCmdVersion + fCmd
+     */
+    public static final int SIZE = (Long.SIZE + Integer.SIZE) / 8 + Command.SIZE;
+    /**
+     * data size following this header, you normally attach a payload that one,
+     * in bytes
+     */
+    private final long fDataSize;
+    /** enum lttcomm_relayd_command */
+    private final Command fCmd;
+    /** command version */
+    private final int fCmdVersion;
+
+    /**
+     * Sets the packet command
+     *
+     * @param viewerConnect
+     *            the command
+     * @param size size of the command
+     * @param version the version number
+     */
+    public ViewerCommand(Command viewerConnect, long size, int version) {
+        fCmd = viewerConnect;
+        fDataSize = size;
+        fCmdVersion = version;
+    }
+
+    /**
+     * Get the data size
+     *
+     * @return the DataSize
+     */
+    public long getDataSize() {
+        return fDataSize;
+    }
+
+    /**
+     * Get the command
+     *
+     * @return the Cmd
+     */
+    public Command getCmd() {
+        return fCmd;
+    }
+
+    /**
+     * Get the command version
+     *
+     * @return the CmdVersion
+     */
+    public int getCmdVersion() {
+        return fCmdVersion;
+    }
+
+    @Override
+    public byte[] serialize() {
+        byte data[] = new byte[SIZE];
+        ByteBuffer bb = ByteBuffer.wrap(data);
+        bb.order(ByteOrder.BIG_ENDIAN);
+        bb.putLong(getDataSize());
+        bb.putInt(getCmd().getCommand());
+        bb.putInt(fCmdVersion);
+        return data;
+    }
+
+
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/impl/LttngRelaydConnector_2_4.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/impl/LttngRelaydConnector_2_4.java
new file mode 100644 (file)
index 0000000..288d914
--- /dev/null
@@ -0,0 +1,181 @@
+/**********************************************************************
+ * Copyright (c) 2014 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:
+ *   Matthew Khouzam - Initial implementation
+ *   Marc-Andre Laperle - Create session and split getNextIndex from getNextPacket
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.impl;
+
+import java.io.DataInputStream;
+import java.io.DataOutputStream;
+import java.io.IOException;
+import java.util.List;
+
+import org.eclipse.jdt.annotation.NonNull;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.ILttngRelaydConnector;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.AttachSessionRequest;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.AttachSessionResponse;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.Command;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.ConnectResponse;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.CreateSessionResponse;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.GetMetadata;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.GetNextIndex;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.GetPacket;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.IndexResponse;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.ListSessionsResponse;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.MetadataPacketResponse;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.NewStreamsResponse;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.NextIndexReturnCode;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.SeekCommand;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.SessionResponse;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.StreamResponse;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.TracePacketResponse;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.ViewerCommand;
+
+/**
+ * Lttng 2.4 implementation
+ *
+ * @author Matthew Khouzam
+ */
+public class LttngRelaydConnector_2_4 implements ILttngRelaydConnector {
+
+    private final @NonNull DataInputStream fInNet;
+    private final @NonNull DataOutputStream fOutNet;
+
+    /**
+     * Constructor needs two network streams
+     *
+     * @param inNet
+     *            network incoming data
+     * @param outNet
+     *            network outgoing data
+     */
+    public LttngRelaydConnector_2_4(@NonNull DataInputStream inNet, @NonNull DataOutputStream outNet) {
+        fInNet = inNet;
+        fOutNet = outNet;
+    }
+
+    // ------------------------------------------------------------------------
+    // AutoCloseable
+    // ------------------------------------------------------------------------
+
+    @Override
+    public void close() throws IOException {
+        fInNet.close();
+        fOutNet.close();
+    }
+
+    // ------------------------------------------------------------------------
+    // ILttngRelaydConnector
+    // ------------------------------------------------------------------------
+
+    @Override
+    public List<SessionResponse> getSessions() throws IOException {
+        ViewerCommand listSessionsCmd = new ViewerCommand(Command.VIEWER_LIST_SESSIONS, 0,0);
+
+        fOutNet.write(listSessionsCmd.serialize());
+        fOutNet.flush();
+
+        return new ListSessionsResponse(fInNet).getSessionsList();
+    }
+
+    @Override
+    public CreateSessionResponse createSession() throws IOException {
+        ViewerCommand listSessionsCmd = new ViewerCommand(Command.VIEWER_CREATE_SESSION, 0, 0);
+        fOutNet.write(listSessionsCmd.serialize());
+        fOutNet.flush();
+
+        return new CreateSessionResponse(fInNet);
+    }
+
+    @Override
+    public AttachSessionResponse attachToSession(SessionResponse lttngViewerSession) throws IOException {
+        ViewerCommand listSessionsCmd = new ViewerCommand(Command.VIEWER_ATTACH_SESSION, 0,0);
+        fOutNet.write(listSessionsCmd.serialize());
+        /*
+         * only flush if you read after
+         */
+
+        AttachSessionRequest attachRequest = new AttachSessionRequest(lttngViewerSession.getId(), SeekCommand.VIEWER_SEEK_LAST);
+        fOutNet.write(attachRequest.serialize());
+        fOutNet.flush();
+
+        return new AttachSessionResponse(fInNet);
+    }
+
+    @Override
+    public String getMetadata(AttachSessionResponse attachedSession) throws IOException {
+
+        for (StreamResponse stream : attachedSession.getStreamList()) {
+            if (stream.getMetadataFlag() == 1) {
+                issueCommand(Command.VIEWER_GET_METADATA);
+
+                GetMetadata metadataRequest = new GetMetadata(stream.getId());
+                fOutNet.write(metadataRequest.serialize());
+                fOutNet.flush();
+
+                MetadataPacketResponse metaDataPacket = new MetadataPacketResponse(fInNet);
+                return new String(metaDataPacket.getData());
+            }
+        }
+
+        return null;
+    }
+
+    @Override
+    public TracePacketResponse getPacketFromStream(IndexResponse index, long id) throws IOException {
+
+        issueCommand(Command.VIEWER_GET_PACKET);
+
+        GetPacket packetRequest = new GetPacket(id, index.getOffset(), (int) (index.getPacketSize() / 8));
+        fOutNet.write(packetRequest.serialize());
+        fOutNet.flush();
+
+        return new TracePacketResponse(fInNet);
+    }
+
+    @Override
+    public TracePacketResponse getNextPacket(StreamResponse stream) throws IOException {
+        IndexResponse indexReply = getNextIndex(stream);
+
+        TracePacketResponse packet = null;
+        if (indexReply.getStatus() == NextIndexReturnCode.VIEWER_INDEX_OK) {
+            packet = getPacketFromStream(indexReply, stream.getId());
+        }
+        return packet;
+    }
+
+    @Override
+    public IndexResponse getNextIndex(StreamResponse stream) throws IOException {
+        issueCommand(Command.VIEWER_GET_NEXT_INDEX);
+
+        GetNextIndex indexRequest = new GetNextIndex(stream.getId());
+        fOutNet.write(indexRequest.serialize());
+        fOutNet.flush();
+
+        return new IndexResponse(fInNet);
+    }
+
+    @Override
+    public List<StreamResponse> getNewStreams() throws IOException {
+
+        Command viewerGetNewStreams = Command.VIEWER_GET_NEW_STREAMS;
+
+        issueCommand(viewerGetNewStreams);
+
+        return new NewStreamsResponse(fInNet).getStreamList();
+    }
+
+    private void issueCommand(Command command) throws IOException {
+        ViewerCommand connectCommand = new ViewerCommand(command, ConnectResponse.SIZE, 0);
+        fOutNet.write(connectCommand.serialize());
+        fOutNet.flush();
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/impl/LttngRelaydConnector_Unsupported.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/impl/LttngRelaydConnector_Unsupported.java
new file mode 100644 (file)
index 0000000..1635445
--- /dev/null
@@ -0,0 +1,76 @@
+/**********************************************************************
+ * Copyright (c) 2014 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:
+ *   Matthew Khouzam - Initial implementation
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.impl;
+
+import java.util.List;
+
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.ILttngRelaydConnector;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.AttachSessionResponse;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.CreateSessionResponse;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.IndexResponse;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.SessionResponse;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.StreamResponse;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.TracePacketResponse;
+
+/**
+ * Unsupported version of the relay daemon
+ *
+ * @author Matthew Khouzam
+ */
+public class LttngRelaydConnector_Unsupported implements ILttngRelaydConnector {
+
+    @Override
+    public List<SessionResponse> getSessions() {
+        throw new UnsupportedOperationException();
+    }
+
+    @Override
+    public AttachSessionResponse attachToSession(SessionResponse lttngViewerSession) {
+        throw new UnsupportedOperationException();
+    }
+
+    @Override
+    public String getMetadata(AttachSessionResponse attachedSession) {
+        throw new UnsupportedOperationException();
+    }
+
+    @Override
+    public TracePacketResponse getNextPacket(StreamResponse stream) {
+        throw new UnsupportedOperationException();
+    }
+
+    @Override
+    public TracePacketResponse getPacketFromStream(IndexResponse index, long id) {
+        throw new UnsupportedOperationException();
+    }
+
+    @Override
+    public List<StreamResponse> getNewStreams() {
+        throw new UnsupportedOperationException();
+    }
+
+    @Override
+    public CreateSessionResponse createSession() {
+        throw new UnsupportedOperationException();
+    }
+
+    @Override
+    public IndexResponse getNextIndex(StreamResponse stream) {
+        throw new UnsupportedOperationException();
+    }
+
+    @Override
+    public void close() {
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/lttng2/control/core/session/Messages.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/lttng2/control/core/session/Messages.java
new file mode 100644 (file)
index 0000000..8eaace4
--- /dev/null
@@ -0,0 +1,45 @@
+/*******************************************************************************
+ * Copyright (c) 2014 École Polytechnique de Montréal
+ *
+ * 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:
+ *   Guilliano Molaire - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.control.core.session;
+
+import org.eclipse.osgi.util.NLS;
+
+/**
+ * Externalized message strings from the lttng2.core.control.session
+ *
+ * @author Guilliano Molaire
+ */
+@SuppressWarnings("javadoc")
+public class Messages extends NLS {
+    private static final String BUNDLE_NAME = "org.eclipse.tracecompass.lttng2.control.core.session.messages"; //$NON-NLS-1$
+
+    public static String SessionConfigXML_BadRequirementType;
+    public static String SessionConfigXML_DomainTypeMissing;
+    public static String SessionConfigXML_EventTypeMissing;
+    public static String SessionConfigXML_InvalidSessionInfoList;
+    public static String SessionConfigXML_InvalidTraceSessionPath;
+    public static String SessionConfigXML_UnknownEventType;
+    public static String SessionConfigXML_UnknownDomainBufferType;
+    public static String SessionConfigXML_SessionConfigGenerationError;
+    public static String SessionConfigXML_XmlParseError;
+    public static String SessionConfigXML_XmlValidateError;
+    public static String SessionConfigXML_XmlValidationError;
+
+    static {
+        // initialize resource bundle
+        NLS.initializeMessages(BUNDLE_NAME, Messages.class);
+    }
+
+    private Messages() {
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/lttng2/control/core/session/SessionConfigGenerator.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/lttng2/control/core/session/SessionConfigGenerator.java
new file mode 100644 (file)
index 0000000..be4479e
--- /dev/null
@@ -0,0 +1,534 @@
+/**********************************************************************
+ * Copyright (c) 2014 École Polytechnique de Montréal
+ *
+ * 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:
+ *   Guilliano Molaire - Initial API and implementation
+ *********************************************************************/
+package org.eclipse.tracecompass.lttng2.control.core.session;
+
+import java.io.File;
+import java.io.IOException;
+import java.net.URL;
+import java.util.Set;
+
+import javax.xml.XMLConstants;
+import javax.xml.parsers.DocumentBuilder;
+import javax.xml.parsers.DocumentBuilderFactory;
+import javax.xml.parsers.ParserConfigurationException;
+import javax.xml.transform.OutputKeys;
+import javax.xml.transform.Source;
+import javax.xml.transform.Transformer;
+import javax.xml.transform.TransformerException;
+import javax.xml.transform.TransformerFactory;
+import javax.xml.transform.dom.DOMSource;
+import javax.xml.transform.stream.StreamResult;
+import javax.xml.transform.stream.StreamSource;
+import javax.xml.validation.Schema;
+import javax.xml.validation.SchemaFactory;
+import javax.xml.validation.Validator;
+
+import org.eclipse.core.runtime.IPath;
+import org.eclipse.core.runtime.IStatus;
+import org.eclipse.core.runtime.Status;
+import org.eclipse.jdt.annotation.NonNull;
+import org.eclipse.osgi.util.NLS;
+import org.eclipse.tracecompass.internal.lttng2.control.core.Activator;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IChannelInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IDomainInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IEventInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISessionInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEnablement;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEventType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
+import org.w3c.dom.Document;
+import org.w3c.dom.Element;
+import org.xml.sax.SAXException;
+import org.xml.sax.SAXParseException;
+
+/**
+ * Class for generating a session configuration file. A session configuration is
+ * used to configure a trace session. It is a XML formatted file that contains
+ * values defining the behavior of that specific trace session.
+ * <p>
+ * Kernel session configuration example:
+ *
+ * <pre>
+ * {@code
+ * <sessions>
+ *     <session>
+ *         <name>test_kernel</name>
+ *         <domains>
+ *             <domain>
+ *                 <type>KERNEL</type>
+ *                 <buffer_type>GLOBAL</buffer_type>
+ *                 <channels>
+ *                     <channel>
+ *                         <name>channel0</name>
+ *                         <enabled>false</enabled>
+ *                         <overwrite_mode>DISCARD</overwrite_mode>
+ *                         <subbuffer_size>262144</subbuffer_size>
+ *                         <subbuffer_count>4</subbuffer_count>
+ *                         <switch_timer_interval>0</switch_timer_interval>
+ *                         <read_timer_interval>200000</read_timer_interval>
+ *                         <output_type>SPLICE</output_type>
+ *                         <tracefile_size>0</tracefile_size>
+ *                         <tracefile_count>0</tracefile_count>
+ *                         <live_timer_interval>0</live_timer_interval>
+ *                         <events>
+ *                             <event>
+ *                                 <enabled>true</enabled>
+ *                                 <type>SYSCALL</type>
+ *                             </event>
+ *                             <event>
+ *                                 <name>snd_soc_cache_sync</name>
+ *                                 <enabled>true</enabled>
+ *                                 <type>TRACEPOINT</type>
+ *                             </event>
+ *                         </events>
+ *                     </channel>
+ *                 </channels>
+ *             </domain>
+ *         </domains>
+ *         <started>false</started>
+ *         <output>
+ *             <consumer_output>
+ *                 <enabled>true</enabled>
+ *                 <destination>
+ *                     <path>/home/user/lttng-traces/test_kernel</path>
+ *                 </destination>
+ *             </consumer_output>
+ *         </output>
+ *     </session>
+ * </sessions>
+ * }
+ * </pre>
+ *
+ * </p>
+ *
+ * @author Guilliano Molaire
+ */
+public final class SessionConfigGenerator {
+
+    /** The name of the session schema */
+    private static final String SESSION_XSD_FILENAME = "session.xsd"; //$NON-NLS-1$
+
+    /** The indent size used for the session configuration XML file */
+    private static final String INDENT_AMOUNT_PROPERTY_NAME = "{http://xml.apache.org/xslt}indent-amount"; //$NON-NLS-1$
+    private static final String INDENT_AMOUNT_PROPERTY_VALUE = "4"; //$NON-NLS-1$
+
+    /**
+     * Private constructor. The class should not be instantiated.
+     */
+    private SessionConfigGenerator() {
+    }
+
+    // ---------------------------------------------------------
+    // Methods to generate session configuration files
+    // ---------------------------------------------------------
+
+    /**
+     * Generates a session configuration file from a set of session information.
+     *
+     * @param sessions
+     *            The session informations
+     * @param sessionFileDestination
+     *            The path of the locally saved session configuration file
+     * @return The status of the session configuration generation
+     */
+    public static IStatus generateSessionConfig(Set<ISessionInfo> sessions, IPath sessionFileDestination) {
+        /* Parameters validation */
+        if (sessions == null || sessions.isEmpty()) {
+            return new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.SessionConfigXML_InvalidSessionInfoList);
+        } else if (sessionFileDestination == null) {
+            return new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.SessionConfigXML_InvalidTraceSessionPath);
+        }
+
+        /* Generate the session configuration file */
+        try {
+            Document sessionConfigDocument = generateSessionConfig(sessions);
+            saveSessionConfig(sessionConfigDocument, sessionFileDestination.toString());
+        } catch (TransformerException | IllegalArgumentException | ParserConfigurationException e) {
+            Activator.getDefault().logError("Error generating the session configuration file: " + sessionFileDestination.toString(), e); //$NON-NLS-1$
+            return new Status(IStatus.ERROR, Activator.PLUGIN_ID, e.getMessage());
+        }
+
+        return Status.OK_STATUS;
+    }
+
+    /**
+     * Generates a session configuration from a set of session informations.
+     *
+     * @param sessions
+     *            The session informations
+     * @return The document with all session configuration nodes
+     * @throws IllegalArgumentException
+     *             On an illegal argument inside sessions
+     * @throws ParserConfigurationException
+     *             On an parser configuration error
+     */
+    private static @NonNull Document generateSessionConfig(Iterable<ISessionInfo> sessions) throws IllegalArgumentException, ParserConfigurationException {
+        DocumentBuilderFactory docFactory = DocumentBuilderFactory.newInstance();
+        DocumentBuilder docBuilder = docFactory.newDocumentBuilder();
+
+        Document document = docBuilder.newDocument();
+
+        Element rootElement = document.createElement(SessionConfigStrings.CONFIG_ELEMENT_SESSIONS);
+        document.appendChild(rootElement);
+
+        for (ISessionInfo session : sessions) {
+            /* All elements under "sessions" elements */
+            Element sessionElement = document.createElement(SessionConfigStrings.CONFIG_ELEMENT_SESSION);
+
+            /* Contents of session element */
+            String enabled = session.getSessionState().equals(TraceSessionState.ACTIVE) ? SessionConfigStrings.CONFIG_STRING_TRUE : SessionConfigStrings.CONFIG_STRING_FALSE;
+
+            addElementContent(document, sessionElement, SessionConfigStrings.CONFIG_ELEMENT_NAME, session.getName());
+            addElementContent(document, sessionElement, SessionConfigStrings.CONFIG_ELEMENT_STARTED, enabled);
+
+            if (session.isSnapshotSession()) {
+                /* If it's a snapshot, we must add an attribute telling it is */
+                Element attributesElement = document.createElement(SessionConfigStrings.CONFIG_ELEMENT_ATTRIBUTES);
+                addElementContent(document, attributesElement, SessionConfigStrings.CONFIG_ELEMENT_SNAPSHOT_MODE, SessionConfigStrings.CONFIG_STRING_TRUE);
+                sessionElement.appendChild(attributesElement);
+            }
+
+            sessionElement.appendChild(getDomainsElement(document, session));
+            sessionElement.appendChild(getOutputElement(document, session));
+            rootElement.appendChild(sessionElement);
+        }
+
+        return document;
+    }
+
+    // ---------------------------------------------------------
+    // Getters for each element of the configuration file
+    // ---------------------------------------------------------
+
+    /**
+     * Gets the 'domains' element after creating it.
+     *
+     * @param document
+     *            The document in which the nodes are being added
+     * @param session
+     *            The session informations
+     * @return The domains element as an XML element
+     */
+    private static Element getDomainsElement(Document document, ISessionInfo session) {
+        Element domainsElement = document.createElement(SessionConfigStrings.CONFIG_ELEMENT_DOMAINS);
+
+        for (IDomainInfo domain : session.getDomains()) {
+            Element domainElement = document.createElement(SessionConfigStrings.CONFIG_ELEMENT_DOMAIN);
+
+            /*
+             * Add everything specific to a domain
+             *
+             * TODO: We suppose here that domain is either kernel or UST. It
+             * will have to change if other domains are supported
+             */
+            String domainType = domain.isKernel() ? SessionConfigStrings.CONFIG_DOMAIN_TYPE_KERNEL : SessionConfigStrings.CONFIG_DOMAIN_TYPE_UST;
+            addElementContent(document, domainElement, SessionConfigStrings.CONFIG_ELEMENT_TYPE, domainType);
+
+            String bufferType = null;
+            switch (domain.getBufferType()) {
+            case BUFFER_PER_UID:
+                bufferType = SessionConfigStrings.CONFIG_BUFFER_TYPE_PER_UID;
+                break;
+            case BUFFER_PER_PID:
+                bufferType = SessionConfigStrings.CONFIG_BUFFER_TYPE_PER_PID;
+                break;
+            case BUFFER_SHARED:
+                bufferType = SessionConfigStrings.CONFIG_BUFFER_TYPE_GLOBAL;
+                break;
+            case BUFFER_TYPE_UNKNOWN:
+            default:
+                throw new IllegalArgumentException(Messages.SessionConfigXML_UnknownDomainBufferType);
+            }
+            addElementContent(document, domainElement, SessionConfigStrings.CONFIG_ELEMENT_DOMAIN_BUFFER_TYPE, bufferType);
+
+            /* Add the channels */
+            domainElement.appendChild(getChannelsElement(document, domain.isKernel(), domain.getChannels()));
+            domainsElement.appendChild(domainElement);
+        }
+
+        return domainsElement;
+    }
+
+    /**
+     * Gets the 'output' element after creating it. If the session is a
+     * snapshot, it will be composed of a snapshot outputs element. Otherwise,
+     * it will contain the consumer output element.
+     *
+     * @param document
+     *            The document in which the nodes are being added
+     * @param session
+     *            The session informations
+     * @return The output element as an XML node
+     */
+    private static Element getOutputElement(Document document, ISessionInfo session) {
+        Element outputElement = document.createElement(SessionConfigStrings.CONFIG_ELEMENT_OUTPUT);
+
+        if (session.isSnapshotSession()) {
+            outputElement.appendChild(getSnapshotOuputsElement(document, session));
+        } else if (session.isStreamedTrace()) {
+            outputElement.appendChild(getNetOutputElement(document, session));
+        } else {
+            outputElement.appendChild(getConsumerOutputElement(document, session));
+        }
+
+        return outputElement;
+    }
+
+    /**
+     * Gets the 'channels' element after creating it.
+     *
+     * @param document
+     *            The document in which the nodes are being added
+     * @param isKernel
+     *            Is it a kernel domain type
+     * @param channels
+     *            The channels to be added as elements
+     * @return The channels element as an XML element
+     */
+    private static Element getChannelsElement(Document document, boolean isKernel, IChannelInfo[] channels) {
+        Element channelsElement = document.createElement(SessionConfigStrings.CONFIG_ELEMENT_CHANNELS);
+
+        for (IChannelInfo channel : channels) {
+            Element channelElement = document.createElement(SessionConfigStrings.CONFIG_ELEMENT_CHANNEL);
+
+            /* Add everything related to a channel */
+            addElementContent(document, channelElement, SessionConfigStrings.CONFIG_ELEMENT_NAME, channel.getName());
+
+            String overwriteMode = channel.isOverwriteMode() ? SessionConfigStrings.CONFIG_OVERWRITE_MODE_OVERWRITE : SessionConfigStrings.CONFIG_OVERWRITE_MODE_DISCARD;
+            String enabled = channel.getState().equals(TraceEnablement.ENABLED) ? SessionConfigStrings.CONFIG_STRING_TRUE : SessionConfigStrings.CONFIG_STRING_FALSE;
+
+            addElementContent(document, channelElement, SessionConfigStrings.CONFIG_ELEMENT_ENABLED, enabled);
+            addElementContent(document, channelElement, SessionConfigStrings.CONFIG_ELEMENT_OVERWRITE_MODE, overwriteMode);
+            addElementContent(document, channelElement, SessionConfigStrings.CONFIG_ELEMENT_SUBBUFFER_SIZE, channel.getSubBufferSize());
+            addElementContent(document, channelElement, SessionConfigStrings.CONFIG_ELEMENT_SUBBUFFER_COUNT, channel.getNumberOfSubBuffers());
+            addElementContent(document, channelElement, SessionConfigStrings.CONFIG_ELEMENT_SWITCH_TIMER_INTERVAL, channel.getSwitchTimer());
+            addElementContent(document, channelElement, SessionConfigStrings.CONFIG_ELEMENT_READ_TIMER_INTERVAL, channel.getReadTimer());
+
+            String outputType = channel.getOutputType().getInName().startsWith(SessionConfigStrings.CONFIG_OUTPUT_TYPE_MMAP) ?
+                    outputType = SessionConfigStrings.CONFIG_OUTPUT_TYPE_MMAP : SessionConfigStrings.CONFIG_OUTPUT_TYPE_SPLICE;
+            addElementContent(document, channelElement, SessionConfigStrings.CONFIG_ELEMENT_OUTPUT_TYPE, outputType);
+            addElementContent(document, channelElement, SessionConfigStrings.CONFIG_ELEMENT_TRACEFILE_SIZE, channel.getMaxSizeTraceFiles());
+            addElementContent(document, channelElement, SessionConfigStrings.CONFIG_ELEMENT_TRACEFILE_COUNT, channel.getMaxNumberTraceFiles());
+
+            /*
+             * TODO: Replace the 0 value by the channel live timer property from
+             * SessionInfo once live session tracing is supported
+             */
+            addElementContent(document, channelElement, SessionConfigStrings.CONFIG_ELEMENT_LIVE_TIMER_INTERVAL, SessionConfigStrings.CONFIG_STRING_ZERO);
+
+            /* Add the events */
+            channelElement.appendChild(getEventsElement(document, isKernel, channel.getEvents()));
+            channelsElement.appendChild(channelElement);
+        }
+
+        return channelsElement;
+    }
+
+    /**
+     * Gets the 'events' element after creating it. It is composed of the event
+     * informations from a list of IEventInfo.
+     *
+     * @param document
+     *            The document in which the nodes are being added
+     * @param isKernel
+     *            Is the domain type kernel
+     * @param events
+     *            The event informations to be added
+     * @return An element containing all the event informations as XML elements
+     */
+    private static Element getEventsElement(Document document, boolean isKernel, IEventInfo[] events) {
+        Element eventsElement = document.createElement(SessionConfigStrings.CONFIG_ELEMENT_EVENTS);
+
+        for (IEventInfo event : events) {
+            Element eventElement = document.createElement(SessionConfigStrings.CONFIG_ELEMENT_EVENT);
+
+            /* Enabled attribute */
+            String enabled = event.getState().equals(TraceEnablement.ENABLED) ? SessionConfigStrings.CONFIG_STRING_TRUE : SessionConfigStrings.CONFIG_STRING_FALSE;
+
+            /* Add the attributes to the event node */
+            addElementContent(document, eventElement, SessionConfigStrings.CONFIG_ELEMENT_NAME, event.getName());
+            addElementContent(document, eventElement, SessionConfigStrings.CONFIG_ELEMENT_ENABLED, enabled);
+            TraceEventType eventType = event.getEventType();
+            if (!eventType.equals(TraceEventType.UNKNOWN)) {
+                addElementContent(document, eventElement, SessionConfigStrings.CONFIG_ELEMENT_TYPE, eventType.getInName().toUpperCase());
+            } else {
+                throw new IllegalArgumentException(Messages.SessionConfigXML_UnknownEventType);
+            }
+
+            /* Specific to UST session config: the log level */
+            if (!isKernel && !event.getLogLevel().equals(TraceLogLevel.LEVEL_UNKNOWN)) {
+                addElementContent(document, eventElement, SessionConfigStrings.CONFIG_ELEMENT_LOGLEVEL, event.getLogLevel().ordinal());
+            }
+
+            /* Add the node to the parent node events */
+            eventsElement.appendChild(eventElement);
+        }
+
+        return eventsElement;
+    }
+
+    /**
+     * Gets the 'consumer_output' element after creating it.
+     *
+     * @param document
+     *            The document in which the nodes are being added
+     * @param session
+     *            The session informations
+     * @return The consumer output element with his informations as XML elements
+     */
+    private static Element getConsumerOutputElement(Document document, ISessionInfo session) {
+        Element consumerOutputElement = document.createElement(SessionConfigStrings.CONFIG_ELEMENT_CONSUMER_OUTPUT);
+        Element destinationElement = document.createElement(SessionConfigStrings.CONFIG_ELEMENT_DESTINATION);
+
+        /* Value of consumer output element */
+        addElementContent(document, consumerOutputElement, SessionConfigStrings.CONFIG_ELEMENT_ENABLED, SessionConfigStrings.CONFIG_STRING_TRUE);
+
+        if (session.isStreamedTrace()) {
+            /* If it is a streamed session, add the net output element */
+            destinationElement.appendChild(getNetOutputElement(document, session));
+        } else {
+            addElementContent(document, destinationElement, SessionConfigStrings.CONFIG_ELEMENT_PATH, session.getSessionPath());
+        }
+
+        consumerOutputElement.appendChild(destinationElement);
+        return consumerOutputElement;
+    }
+
+    /**
+     * Gets the 'net_output' element after creating it. It is composed of the
+     * control and data URIs.
+     *
+     * @param document
+     *            The document in which the nodes are being added
+     * @param session
+     *            The session informations
+     * @return The net output element
+     */
+    private static Element getNetOutputElement(Document document, ISessionInfo session) {
+        Element netOutputElement = document.createElement(SessionConfigStrings.CONFIG_ELEMENT_NET_OUTPUT);
+
+        String networkUrl = session.getNetworkUrl();
+        String controlUri = networkUrl == null ? session.getControlUrl() : networkUrl;
+        String dataUri = networkUrl == null ? session.getDataUrl() : networkUrl;
+        addElementContent(document, netOutputElement, SessionConfigStrings.CONFIG_ELEMENT_CONTROL_URI, controlUri);
+        addElementContent(document, netOutputElement, SessionConfigStrings.CONFIG_ELEMENT_DATA_URI, dataUri);
+
+        return netOutputElement;
+    }
+
+    /**
+     * Gets the 'snapshot_outputs' element after creating it.
+     *
+     * @param document
+     *            The document in which the nodes are being added
+     * @param session
+     *            The session informations
+     * @return The snapshot outputs element with snapshot informations as XML
+     *         elements
+     */
+    private static Element getSnapshotOuputsElement(Document document, ISessionInfo session) {
+        Element snapshotOutputsElement = document.createElement(SessionConfigStrings.CONFIG_ELEMENT_SNAPSHOT_OUTPUTS);
+        Element outputElement = document.createElement(SessionConfigStrings.CONFIG_ELEMENT_OUTPUT);
+
+        /* Add the name of the snapshot and the max size element */
+        addElementContent(document, outputElement, SessionConfigStrings.CONFIG_ELEMENT_NAME, session.getSnapshotInfo().getName());
+
+        /*
+         * TODO: find the proper max size value of output element. For now it is
+         * set to the default 0 value which means unlimited for lttng.
+         */
+        addElementContent(document, outputElement, SessionConfigStrings.CONFIG_ELEMENT_MAX_SIZE, SessionConfigStrings.CONFIG_STRING_ZERO);
+        outputElement.appendChild(getConsumerOutputElement(document, session));
+
+        snapshotOutputsElement.appendChild(outputElement);
+        return snapshotOutputsElement;
+    }
+
+    // ---------------------------------------------------------
+    // Utilities
+    // ---------------------------------------------------------
+
+    /**
+     * Validates the session configuration file against its schema.
+     *
+     * @param sessionFile
+     *            The session configuration file
+     * @return The status of the validation
+     */
+    public static IStatus sessionValidate(File sessionFile) {
+        URL url = SessionConfigGenerator.class.getResource(SESSION_XSD_FILENAME);
+        SchemaFactory schemaFactory = SchemaFactory.newInstance(XMLConstants.W3C_XML_SCHEMA_NS_URI);
+        Source xmlSource = new StreamSource(sessionFile);
+
+        try {
+            Schema schema = schemaFactory.newSchema(url);
+            Validator validator = schema.newValidator();
+            validator.validate(xmlSource);
+        } catch (SAXParseException e) {
+            String error = NLS.bind(Messages.SessionConfigXML_XmlParseError, e.getLineNumber(), e.getLocalizedMessage());
+            Activator.getDefault().logError(error);
+            return new Status(IStatus.ERROR, Activator.PLUGIN_ID, error, e);
+        } catch (SAXException e) {
+            String error = NLS.bind(Messages.SessionConfigXML_XmlValidationError, e.getLocalizedMessage());
+            Activator.getDefault().logError(error);
+            return new Status(IStatus.ERROR, Activator.PLUGIN_ID, error, e);
+        } catch (IOException e) {
+            String error = Messages.SessionConfigXML_XmlValidateError;
+            Activator.getDefault().logError("IO exception occurred", e); //$NON-NLS-1$
+            return new Status(IStatus.ERROR, Activator.PLUGIN_ID, error, e);
+        }
+        return Status.OK_STATUS;
+    }
+
+    /**
+     * Saves the session configuration into a XML file.
+     *
+     * @param document
+     *            The document representing the session configuration file
+     * @param destination
+     *            The path of the locally saved session configuration file
+     * @throws TransformerException
+     *             On an transformation process
+     */
+    private static void saveSessionConfig(Document document, String destination) throws TransformerException {
+        /* Write the content into a XML file */
+        TransformerFactory transformerFactory = TransformerFactory.newInstance();
+        Transformer transformer = transformerFactory.newTransformer();
+
+        transformer.setOutputProperty(OutputKeys.INDENT, "yes"); //$NON-NLS-1$
+        transformer.setOutputProperty(INDENT_AMOUNT_PROPERTY_NAME, INDENT_AMOUNT_PROPERTY_VALUE);
+
+        DOMSource source = new DOMSource(document);
+        StreamResult result = new StreamResult(new File(destination));
+
+        transformer.transform(source, result);
+    }
+
+    /**
+     * Adds to a parent node an element with his content.
+     *
+     * @param document
+     *            The document in which the nodes are being added
+     * @param parent
+     *            The parent node that contains the element and his content
+     * @param elementName
+     *            The element container name
+     * @param elementContent
+     *            The content itself
+     */
+    private static void addElementContent(Document document, Element parent, String elementName, Object elementContent) {
+        Element contentElement = document.createElement(elementName);
+        contentElement.appendChild(document.createTextNode(elementContent.toString()));
+        parent.appendChild(contentElement);
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/lttng2/control/core/session/SessionConfigStrings.java b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/lttng2/control/core/session/SessionConfigStrings.java
new file mode 100644 (file)
index 0000000..9bb1869
--- /dev/null
@@ -0,0 +1,81 @@
+/**********************************************************************
+ * Copyright (c) 2014 École Polytechnique de Montréal
+ *
+ * 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:
+ *   Guilliano Molaire - Initial API and implementation
+ *********************************************************************/
+package org.eclipse.tracecompass.lttng2.control.core.session;
+
+/**
+ * This file defines most markers from a session configuration file used to
+ * configure a trace session. They can be found in the session configuration
+ * schema "session.xsd" in src/common/config/ folder of LTTng-tools.
+ *
+ * @author Guilliano Molaire
+ */
+@SuppressWarnings({ "javadoc", "nls" })
+public interface SessionConfigStrings {
+
+    /* Session configuration file extension */
+    String SESSION_CONFIG_FILE_EXTENSION = "lttng";
+
+    /* Elements of the session configuration file */
+    String CONFIG_ELEMENT_SESSIONS = "sessions";
+    String CONFIG_ELEMENT_SESSION = "session";
+    String CONFIG_ELEMENT_DOMAINS = "domains";
+    String CONFIG_ELEMENT_DOMAIN = "domain";
+    String CONFIG_ELEMENT_CHANNELS = "channels";
+    String CONFIG_ELEMENT_CHANNEL = "channel";
+    String CONFIG_ELEMENT_EVENTS = "events";
+    String CONFIG_ELEMENT_EVENT = "event";
+    String CONFIG_ELEMENT_OUTPUT = "output";
+    String CONFIG_ELEMENT_ATTRIBUTES = "attributes";
+    String CONFIG_ELEMENT_NET_OUTPUT = "net_output";
+    String CONFIG_ELEMENT_MAX_SIZE = "max_size";
+    String CONFIG_ELEMENT_SNAPSHOT_OUTPUTS = "snapshot_outputs";
+    String CONFIG_ELEMENT_CONSUMER_OUTPUT = "consumer_output";
+    String CONFIG_ELEMENT_DESTINATION = "destination";
+    String CONFIG_ELEMENT_CONTROL_URI = "control_uri";
+    String CONFIG_ELEMENT_DATA_URI = "data_uri";
+    String CONFIG_ELEMENT_SNAPSHOT_MODE = "snapshot_mode";
+    String CONFIG_ELEMENT_PATH = "path";
+    String CONFIG_ELEMENT_NAME = "name";
+    String CONFIG_ELEMENT_ENABLED = "enabled";
+    String CONFIG_ELEMENT_TYPE = "type";
+    String CONFIG_ELEMENT_STARTED = "started";
+    String CONFIG_ELEMENT_DOMAIN_BUFFER_TYPE = "buffer_type";
+    String CONFIG_ELEMENT_OVERWRITE_MODE = "overwrite_mode";
+    String CONFIG_ELEMENT_SUBBUFFER_SIZE = "subbuffer_size";
+    String CONFIG_ELEMENT_SUBBUFFER_COUNT = "subbuffer_count";
+    String CONFIG_ELEMENT_SWITCH_TIMER_INTERVAL = "switch_timer_interval";
+    String CONFIG_ELEMENT_READ_TIMER_INTERVAL = "read_timer_interval";
+    String CONFIG_ELEMENT_OUTPUT_TYPE = "output_type";
+    String CONFIG_ELEMENT_TRACEFILE_SIZE = "tracefile_size";
+    String CONFIG_ELEMENT_TRACEFILE_COUNT = "tracefile_count";
+    String CONFIG_ELEMENT_LIVE_TIMER_INTERVAL = "live_timer_interval";
+    String CONFIG_ELEMENT_LOGLEVEL_TYPE = "loglevel_type";
+    String CONFIG_ELEMENT_LOGLEVEL = "loglevel";
+
+    /* Common element values */
+    String CONFIG_STRING_TRUE = "true";
+    String CONFIG_STRING_FALSE = "false";
+    String CONFIG_STRING_ZERO = "0";
+
+    String CONFIG_DOMAIN_TYPE_KERNEL = "KERNEL";
+    String CONFIG_DOMAIN_TYPE_UST = "UST";
+
+    String CONFIG_BUFFER_TYPE_PER_UID = "PER_UID";
+    String CONFIG_BUFFER_TYPE_PER_PID = "PER_PID";
+    String CONFIG_BUFFER_TYPE_GLOBAL = "GLOBAL";
+
+    String CONFIG_OVERWRITE_MODE_DISCARD = "DISCARD";
+    String CONFIG_OVERWRITE_MODE_OVERWRITE = "OVERWRITE";
+
+    String CONFIG_OUTPUT_TYPE_SPLICE = "SPLICE";
+    String CONFIG_OUTPUT_TYPE_MMAP = "MMAP";
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/lttng2/control/core/session/messages.properties b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/lttng2/control/core/session/messages.properties
new file mode 100644 (file)
index 0000000..c0d252d
--- /dev/null
@@ -0,0 +1,23 @@
+###############################################################################
+# Copyright (c) 2014 École Polytechnique de Montréal
+#
+# 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:
+#     Guilliano Molaire - Initial API and implementation
+###############################################################################
+
+SessionConfigXML_BadRequirementType=The requirement type is not supported
+SessionConfigXML_DomainTypeMissing=The domain requirement type is missing
+SessionConfigXML_EventTypeMissing=The event requirement type is missing
+SessionConfigXML_InvalidSessionInfoList=The list of session is empty or null
+SessionConfigXML_InvalidTraceSessionPath=The trace session path is not valid
+SessionConfigXML_UnknownEventType=The event type is not handled by the session configuration
+SessionConfigXML_UnknownDomainBufferType=The domain buffer type is not handled by the session configuration
+SessionConfigXML_SessionConfigGenerationError=An error occurred while generating the session configuration file
+SessionConfigXML_XmlParseError=XML Parsing error at line {0}: {1}
+SessionConfigXML_XmlValidateError=An error occurred while validating the XML file.
+SessionConfigXML_XmlValidationError=Error validating XML file {0}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/lttng2/control/core/session/session.xsd b/lttng/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/lttng2/control/core/session/session.xsd
new file mode 100644 (file)
index 0000000..3023216
--- /dev/null
@@ -0,0 +1,296 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+Copyright (c) 2014 - Jérémie Galarneau <jeremie.galarneau@efficios.com>
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+THE SOFTWARE.
+-->
+<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
+elementFormDefault="qualified" version="2.5">
+
+<xs:simpleType name="name_type">
+       <xs:restriction base="xs:string">
+               <xs:maxLength value="255"/>
+       </xs:restriction>
+</xs:simpleType>
+
+<xs:simpleType name="uint64_type">
+       <xs:restriction base="xs:integer">
+               <xs:minInclusive value="0"/>
+               <xs:maxInclusive value="18446744073709551615"/>
+       </xs:restriction>
+</xs:simpleType>
+
+<xs:simpleType name="uint32_type">
+       <xs:restriction base="xs:integer">
+               <xs:minInclusive value="0"/>
+               <xs:maxInclusive value="4294967295"/>
+       </xs:restriction>
+</xs:simpleType>
+
+<xs:simpleType name="channel_overwrite_mode_type">
+       <xs:restriction base="xs:string">
+               <xs:enumeration value="DISCARD"/>
+               <xs:enumeration value="OVERWRITE"/>
+       </xs:restriction>
+</xs:simpleType>
+
+<!-- Maps to the lttng_event_output enum -->
+<xs:simpleType name="event_output_type">
+       <xs:restriction base="xs:string">
+               <xs:enumeration value="SPLICE"/>
+               <xs:enumeration value="MMAP"/>
+       </xs:restriction>
+</xs:simpleType>
+
+<!-- Maps to the lttng_loglevel_type enum -->
+<xs:simpleType name="loglevel_type">
+       <xs:restriction base="xs:string">
+               <xs:enumeration value="ALL"/>
+               <xs:enumeration value="RANGE"/>
+               <xs:enumeration value="SINGLE"/>
+       </xs:restriction>
+</xs:simpleType>
+
+<!-- Maps to the lttng_event_type enum -->
+<xs:simpleType name="event_type_type">
+       <xs:restriction base="xs:string">
+               <xs:enumeration value="ALL"/>
+               <xs:enumeration value="TRACEPOINT"/>
+               <xs:enumeration value="PROBE"/>
+               <xs:enumeration value="FUNCTION"/>
+               <xs:enumeration value="FUNCTION_ENTRY"/>
+               <xs:enumeration value="NOOP"/>
+               <xs:enumeration value="SYSCALL"/>
+               <xs:enumeration value="KPROBE"/>
+               <xs:enumeration value="KRETPROBE"/>
+       </xs:restriction>
+</xs:simpleType>
+
+<xs:complexType name="event_probe_attributes_type">
+       <xs:all>
+               <xs:element name="symbol_name" type="name_type" minOccurs="0"/>
+               <xs:element name="address" type="uint64_type" minOccurs="0"/>
+               <xs:element name="offset" type="uint64_type" minOccurs="0"/>
+       </xs:all>
+</xs:complexType>
+
+<xs:complexType name="event_ftrace_attributes_type">
+       <xs:all>
+               <xs:element name="symbol_name" type="name_type"/>
+       </xs:all>
+</xs:complexType>
+
+<xs:complexType name="event_attributes_type">
+       <xs:choice>
+               <xs:element name="probe_attributes" type="event_probe_attributes_type"/>
+               <xs:element name="function_attributes" type="event_ftrace_attributes_type"/>
+       </xs:choice>
+</xs:complexType>
+
+<xs:complexType name="event_exclusion_list_type">
+       <xs:sequence>
+               <xs:element name="exclusion" type="xs:string" minOccurs="0" maxOccurs="unbounded"/>
+       </xs:sequence>
+</xs:complexType>
+
+<xs:complexType name="event_type">
+       <xs:all>
+               <xs:element name="name" type="name_type" minOccurs="0"/>
+               <xs:element name="enabled" type="xs:boolean" default="true" minOccurs="0"/>
+               <xs:element name="type" type="event_type_type" default="TRACEPOINT" minOccurs="0"/>
+               <xs:element name="loglevel_type" type="loglevel_type" default="ALL" minOccurs="0"/>
+               <xs:element name="loglevel" type="xs:int" default="-1" minOccurs="0"/>
+               <xs:element name="filter" type="xs:string" minOccurs="0"/>
+               <xs:element name="exclusions" type="event_exclusion_list_type" minOccurs="0"/>
+               <xs:element name="attributes" type="event_attributes_type" minOccurs="0"/>
+       </xs:all>
+</xs:complexType>
+
+<xs:complexType name="event_list_type">
+       <xs:sequence>
+               <xs:element name="event" type="event_type" minOccurs="0" maxOccurs="unbounded"/>
+       </xs:sequence>
+</xs:complexType>
+
+<xs:complexType name="event_perf_context_type">
+       <xs:all>
+               <xs:element name="type" type="uint32_type"/>
+               <xs:element name="config" type="uint64_type"/>
+               <xs:element name="name" type="name_type"/>
+       </xs:all>
+</xs:complexType>
+
+<!-- Maps to the lttng_event_context_type enum -->
+<xs:simpleType name="event_context_type_type">
+       <xs:restriction base="xs:string">
+               <xs:enumeration value="PID"/>
+               <xs:enumeration value="PROCNAME"/>
+               <xs:enumeration value="PRIO"/>
+               <xs:enumeration value="NICE"/>
+               <xs:enumeration value="VPID"/>
+               <xs:enumeration value="TID"/>
+               <xs:enumeration value="VTID"/>
+               <xs:enumeration value="PPID"/>
+               <xs:enumeration value="VPPID"/>
+               <xs:enumeration value="PTHREAD_ID"/>
+               <xs:enumeration value="HOSTNAME"/>
+               <xs:enumeration value="IP"/>
+       </xs:restriction>
+</xs:simpleType>
+
+<xs:complexType name="event_context_type">
+       <xs:choice>
+               <xs:element name="type" type="event_context_type_type"/>
+               <xs:element name="perf" type="event_perf_context_type"/>
+       </xs:choice>
+</xs:complexType>
+
+<xs:complexType name="event_context_list_type">
+       <xs:sequence>
+               <xs:element name="context" type="event_context_type" minOccurs="0" maxOccurs="unbounded"/>
+       </xs:sequence>
+</xs:complexType>
+
+<!-- Maps to struct lttng_channel -->
+<xs:complexType name="channel_type">
+       <xs:all>
+               <xs:element name="name" type="name_type"/>
+               <xs:element name="enabled" type="xs:boolean" default="true" minOccurs="0"/>
+               <xs:element name="overwrite_mode" type="channel_overwrite_mode_type" default="DISCARD" minOccurs="0"/>
+               <xs:element name="subbuffer_size" type="uint64_type" minOccurs="0"/> <!-- bytes -->
+               <xs:element name="subbuffer_count" type="uint64_type" default="4" minOccurs="0"/>
+               <xs:element name="switch_timer_interval" type="uint32_type" default="0" minOccurs="0"/>  <!-- usec -->
+               <xs:element name="read_timer_interval" type="uint32_type"/>  <!-- usec -->
+               <xs:element name="output_type" type="event_output_type"/>
+               <xs:element name="tracefile_size" type="uint64_type" default="0" minOccurs="0"/> <!-- bytes -->
+               <xs:element name="tracefile_count" type="uint64_type" default="0" minOccurs="0"/>
+               <xs:element name="live_timer_interval" type="uint32_type" default="0" minOccurs="0"/> <!-- usec -->
+               <xs:element name="events" type="event_list_type" minOccurs="0"/>
+               <xs:element name="contexts" type="event_context_list_type" minOccurs="0"/>
+       </xs:all>
+</xs:complexType>
+
+<!-- Maps to the lttng_domain_type enum -->
+<xs:simpleType name="domain_type_type">
+       <xs:restriction base="xs:string">
+               <xs:enumeration value="KERNEL"/>
+               <xs:enumeration value="UST"/>
+               <xs:enumeration value="JUL"/>
+               <xs:enumeration value="LOG4J"/>
+       </xs:restriction>
+</xs:simpleType>
+
+<!-- Maps to the lttng_buffer_type enum -->
+<xs:simpleType name="domain_buffer_type">
+       <xs:restriction base="xs:string">
+               <xs:enumeration value="PER_PID"/>
+               <xs:enumeration value="PER_UID"/>
+               <xs:enumeration value="GLOBAL"/>
+       </xs:restriction>
+</xs:simpleType>
+
+<xs:complexType name="channel_list_type">
+       <xs:sequence>
+               <xs:element name="channel" type="channel_type" minOccurs="0" maxOccurs="unbounded"/>
+       </xs:sequence>
+</xs:complexType>
+
+<!-- Maps to struct lttng_domain and contains channels -->
+<xs:complexType name="domain_type">
+       <xs:all>
+               <xs:element name="type" type="domain_type_type"/>
+               <xs:element name="buffer_type" type="domain_buffer_type"/>
+               <xs:element name="channels" type="channel_list_type" minOccurs="0"/>
+       </xs:all>
+</xs:complexType>
+
+<xs:complexType name="session_attributes_type">
+       <xs:choice>
+               <xs:element name="snapshot_mode" type="xs:boolean"/>
+               <xs:element name="live_timer_interval" type="uint32_type"/> <!-- usec -->
+       </xs:choice>
+</xs:complexType>
+
+<xs:complexType name="domain_list_type">
+       <xs:sequence>
+               <xs:element name="domain" type="domain_type" minOccurs="0" maxOccurs="unbounded"/>
+       </xs:sequence>
+</xs:complexType>
+
+<xs:complexType name="net_output_type">
+       <xs:all>
+               <xs:element name="control_uri" type="xs:string"/>
+               <xs:element name="data_uri" type="xs:string"/>
+       </xs:all>
+</xs:complexType>
+
+<xs:complexType name="destination_type">
+       <xs:choice>
+               <xs:element name="path" type="xs:string"/>
+               <xs:element name="net_output" type="net_output_type"/>
+       </xs:choice>
+</xs:complexType>
+
+<xs:complexType name="consumer_output_type">
+       <xs:all>
+               <xs:element name="enabled" type="xs:boolean" default="true"/>
+               <xs:element name="destination" type="destination_type"/>
+       </xs:all>
+</xs:complexType>
+
+<xs:complexType name="snapshot_output_type">
+       <xs:all>
+               <xs:element name="name" type="name_type"/>
+               <xs:element name="max_size" type="uint64_type"/>
+               <xs:element name="consumer_output" type="consumer_output_type"/>
+       </xs:all>
+</xs:complexType>
+
+<xs:complexType name="snapshot_output_list_type">
+       <xs:sequence>
+               <xs:element name="output" type="snapshot_output_type" minOccurs="0" maxOccurs="unbounded"/>
+       </xs:sequence>
+</xs:complexType>
+
+<xs:complexType name="session_output_type">
+       <xs:choice>
+               <xs:element name="snapshot_outputs" type="snapshot_output_list_type"/>
+               <xs:element name="consumer_output" type="consumer_output_type"/>
+       </xs:choice>
+</xs:complexType>
+
+<xs:complexType name="session_type">
+       <xs:all>
+               <xs:element name="name" type="name_type"/>
+               <xs:element name="domains" type="domain_list_type" minOccurs="0"/>
+               <xs:element name="started" type="xs:boolean" default="0" minOccurs="0"/>
+               <xs:element name="attributes" type="session_attributes_type" minOccurs="0"/>
+               <xs:element name="output" type="session_output_type" minOccurs="0"/>
+       </xs:all>
+</xs:complexType>
+
+<xs:element name="sessions">
+       <xs:complexType>
+               <xs:sequence>
+                       <xs:element name="session" type="session_type" maxOccurs="unbounded"/>
+               </xs:sequence>
+       </xs:complexType>
+</xs:element>
+
+</xs:schema>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/.classpath b/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/.classpath
new file mode 100644 (file)
index 0000000..f1d3296
--- /dev/null
@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+       <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7"/>
+       <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
+       <classpathentry kind="src" path="src"/>
+       <classpathentry kind="src" path="stubs"/>
+       <classpathentry kind="output" path="bin"/>
+</classpath>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/.project b/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/.project
new file mode 100644 (file)
index 0000000..b9f247d
--- /dev/null
@@ -0,0 +1,34 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+       <name>org.eclipse.tracecompass.lttng2.control.ui.tests</name>
+       <comment></comment>
+       <projects>
+       </projects>
+       <buildSpec>
+               <buildCommand>
+                       <name>org.eclipse.jdt.core.javabuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+               <buildCommand>
+                       <name>org.eclipse.pde.ManifestBuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+               <buildCommand>
+                       <name>org.eclipse.pde.SchemaBuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+               <buildCommand>
+                       <name>org.eclipse.pde.api.tools.apiAnalysisBuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+       </buildSpec>
+       <natures>
+               <nature>org.eclipse.pde.PluginNature</nature>
+               <nature>org.eclipse.jdt.core.javanature</nature>
+               <nature>org.eclipse.pde.api.tools.apiAnalysisNature</nature>
+       </natures>
+</projectDescription>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/.settings/org.eclipse.core.resources.prefs b/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/.settings/org.eclipse.core.resources.prefs
new file mode 100644 (file)
index 0000000..99f26c0
--- /dev/null
@@ -0,0 +1,2 @@
+eclipse.preferences.version=1
+encoding/<project>=UTF-8
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/.settings/org.eclipse.core.runtime.prefs b/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/.settings/org.eclipse.core.runtime.prefs
new file mode 100644 (file)
index 0000000..5a0ad22
--- /dev/null
@@ -0,0 +1,2 @@
+eclipse.preferences.version=1
+line.separator=\n
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/.settings/org.eclipse.jdt.core.prefs b/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/.settings/org.eclipse.jdt.core.prefs
new file mode 100644 (file)
index 0000000..0409c61
--- /dev/null
@@ -0,0 +1,403 @@
+eclipse.preferences.version=1
+org.eclipse.jdt.core.codeComplete.argumentPrefixes=
+org.eclipse.jdt.core.codeComplete.argumentSuffixes=
+org.eclipse.jdt.core.codeComplete.fieldPrefixes=f
+org.eclipse.jdt.core.codeComplete.fieldSuffixes=
+org.eclipse.jdt.core.codeComplete.localPrefixes=
+org.eclipse.jdt.core.codeComplete.localSuffixes=
+org.eclipse.jdt.core.codeComplete.staticFieldPrefixes=
+org.eclipse.jdt.core.codeComplete.staticFieldSuffixes=
+org.eclipse.jdt.core.codeComplete.staticFinalFieldPrefixes=
+org.eclipse.jdt.core.codeComplete.staticFinalFieldSuffixes=
+org.eclipse.jdt.core.compiler.annotation.inheritNullAnnotations=enabled
+org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore
+org.eclipse.jdt.core.compiler.annotation.nonnull=org.eclipse.jdt.annotation.NonNull
+org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=org.eclipse.jdt.annotation.NonNullByDefault
+org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nullable
+org.eclipse.jdt.core.compiler.annotation.nullanalysis=enabled
+org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
+org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
+org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
+org.eclipse.jdt.core.compiler.compliance=1.7
+org.eclipse.jdt.core.compiler.debug.lineNumber=generate
+org.eclipse.jdt.core.compiler.debug.localVariable=generate
+org.eclipse.jdt.core.compiler.debug.sourceFile=generate
+org.eclipse.jdt.core.compiler.doc.comment.support=enabled
+org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=error
+org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
+org.eclipse.jdt.core.compiler.problem.autoboxing=ignore
+org.eclipse.jdt.core.compiler.problem.comparingIdentical=error
+org.eclipse.jdt.core.compiler.problem.deadCode=error
+org.eclipse.jdt.core.compiler.problem.deprecation=error
+org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled
+org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=enabled
+org.eclipse.jdt.core.compiler.problem.discouragedReference=error
+org.eclipse.jdt.core.compiler.problem.emptyStatement=error
+org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
+org.eclipse.jdt.core.compiler.problem.explicitlyClosedAutoCloseable=error
+org.eclipse.jdt.core.compiler.problem.fallthroughCase=error
+org.eclipse.jdt.core.compiler.problem.fatalOptionalError=disabled
+org.eclipse.jdt.core.compiler.problem.fieldHiding=error
+org.eclipse.jdt.core.compiler.problem.finalParameterBound=error
+org.eclipse.jdt.core.compiler.problem.finallyBlockNotCompletingNormally=error
+org.eclipse.jdt.core.compiler.problem.forbiddenReference=error
+org.eclipse.jdt.core.compiler.problem.hiddenCatchBlock=error
+org.eclipse.jdt.core.compiler.problem.includeNullInfoFromAsserts=disabled
+org.eclipse.jdt.core.compiler.problem.incompatibleNonInheritedInterfaceMethod=error
+org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch=error
+org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=error
+org.eclipse.jdt.core.compiler.problem.invalidJavadoc=warning
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTags=enabled
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsDeprecatedRef=enabled
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsNotVisibleRef=enabled
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsVisibility=protected
+org.eclipse.jdt.core.compiler.problem.localVariableHiding=error
+org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=error
+org.eclipse.jdt.core.compiler.problem.missingDefaultCase=error
+org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=error
+org.eclipse.jdt.core.compiler.problem.missingEnumCaseDespiteDefault=enabled
+org.eclipse.jdt.core.compiler.problem.missingHashCodeMethod=error
+org.eclipse.jdt.core.compiler.problem.missingJavadocComments=warning
+org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsOverriding=disabled
+org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsVisibility=protected
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagDescription=all_standard_tags
+org.eclipse.jdt.core.compiler.problem.missingJavadocTags=warning
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagsMethodTypeParameters=disabled
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagsOverriding=disabled
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagsVisibility=protected
+org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotation=error
+org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotationForInterfaceMethodImplementation=enabled
+org.eclipse.jdt.core.compiler.problem.missingSerialVersion=error
+org.eclipse.jdt.core.compiler.problem.missingSynchronizedOnInheritedMethod=error
+org.eclipse.jdt.core.compiler.problem.noEffectAssignment=error
+org.eclipse.jdt.core.compiler.problem.noImplicitStringConversion=error
+org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=ignore
+org.eclipse.jdt.core.compiler.problem.nonnullParameterAnnotationDropped=warning
+org.eclipse.jdt.core.compiler.problem.nullAnnotationInferenceConflict=warning
+org.eclipse.jdt.core.compiler.problem.nullReference=error
+org.eclipse.jdt.core.compiler.problem.nullSpecViolation=error
+org.eclipse.jdt.core.compiler.problem.nullUncheckedConversion=warning
+org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=error
+org.eclipse.jdt.core.compiler.problem.parameterAssignment=error
+org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=error
+org.eclipse.jdt.core.compiler.problem.potentialNullReference=error
+org.eclipse.jdt.core.compiler.problem.potentiallyUnclosedCloseable=warning
+org.eclipse.jdt.core.compiler.problem.rawTypeReference=error
+org.eclipse.jdt.core.compiler.problem.redundantNullAnnotation=warning
+org.eclipse.jdt.core.compiler.problem.redundantNullCheck=error
+org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=error
+org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=error
+org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore
+org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=error
+org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled
+org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=error
+org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=disabled
+org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled
+org.eclipse.jdt.core.compiler.problem.syntacticNullAnalysisForFields=enabled
+org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=ignore
+org.eclipse.jdt.core.compiler.problem.typeParameterHiding=error
+org.eclipse.jdt.core.compiler.problem.unavoidableGenericTypeProblems=disabled
+org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=error
+org.eclipse.jdt.core.compiler.problem.unclosedCloseable=error
+org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=ignore
+org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=error
+org.eclipse.jdt.core.compiler.problem.unnecessaryElse=error
+org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=error
+org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=error
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionExemptExceptionAndThrowable=disabled
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionIncludeDocCommentReference=disabled
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverriding=disabled
+org.eclipse.jdt.core.compiler.problem.unusedImport=error
+org.eclipse.jdt.core.compiler.problem.unusedLabel=error
+org.eclipse.jdt.core.compiler.problem.unusedLocal=error
+org.eclipse.jdt.core.compiler.problem.unusedObjectAllocation=ignore
+org.eclipse.jdt.core.compiler.problem.unusedParameter=ignore
+org.eclipse.jdt.core.compiler.problem.unusedParameterIncludeDocCommentReference=enabled
+org.eclipse.jdt.core.compiler.problem.unusedParameterWhenImplementingAbstract=disabled
+org.eclipse.jdt.core.compiler.problem.unusedParameterWhenOverridingConcrete=disabled
+org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=error
+org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=ignore
+org.eclipse.jdt.core.compiler.problem.unusedWarningToken=error
+org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=error
+org.eclipse.jdt.core.compiler.source=1.7
+org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=16
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_call=16
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation=16
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression=16
+org.eclipse.jdt.core.formatter.alignment_for_assignment=0
+org.eclipse.jdt.core.formatter.alignment_for_binary_expression=16
+org.eclipse.jdt.core.formatter.alignment_for_compact_if=16
+org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=80
+org.eclipse.jdt.core.formatter.alignment_for_enum_constants=0
+org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=16
+org.eclipse.jdt.core.formatter.alignment_for_method_declaration=0
+org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16
+org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=80
+org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation=0
+org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_constructor_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_method_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_union_type_in_multicatch=16
+org.eclipse.jdt.core.formatter.blank_lines_after_imports=1
+org.eclipse.jdt.core.formatter.blank_lines_after_package=1
+org.eclipse.jdt.core.formatter.blank_lines_before_field=0
+org.eclipse.jdt.core.formatter.blank_lines_before_first_class_body_declaration=0
+org.eclipse.jdt.core.formatter.blank_lines_before_imports=1
+org.eclipse.jdt.core.formatter.blank_lines_before_member_type=1
+org.eclipse.jdt.core.formatter.blank_lines_before_method=1
+org.eclipse.jdt.core.formatter.blank_lines_before_new_chunk=1
+org.eclipse.jdt.core.formatter.blank_lines_before_package=0
+org.eclipse.jdt.core.formatter.blank_lines_between_import_groups=1
+org.eclipse.jdt.core.formatter.blank_lines_between_type_declarations=1
+org.eclipse.jdt.core.formatter.brace_position_for_annotation_type_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_array_initializer=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_block=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_block_in_case=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_constructor_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_enum_constant=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_enum_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_method_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_switch=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_type_declaration=end_of_line
+org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_block_comment=false
+org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_javadoc_comment=false
+org.eclipse.jdt.core.formatter.comment.format_block_comments=true
+org.eclipse.jdt.core.formatter.comment.format_header=false
+org.eclipse.jdt.core.formatter.comment.format_html=true
+org.eclipse.jdt.core.formatter.comment.format_javadoc_comments=true
+org.eclipse.jdt.core.formatter.comment.format_line_comments=true
+org.eclipse.jdt.core.formatter.comment.format_source_code=true
+org.eclipse.jdt.core.formatter.comment.indent_parameter_description=true
+org.eclipse.jdt.core.formatter.comment.indent_root_tags=true
+org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags=insert
+org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter=insert
+org.eclipse.jdt.core.formatter.comment.line_length=80
+org.eclipse.jdt.core.formatter.comment.new_lines_at_block_boundaries=true
+org.eclipse.jdt.core.formatter.comment.new_lines_at_javadoc_boundaries=true
+org.eclipse.jdt.core.formatter.comment.preserve_white_space_between_code_and_line_comments=false
+org.eclipse.jdt.core.formatter.compact_else_if=true
+org.eclipse.jdt.core.formatter.continuation_indentation=2
+org.eclipse.jdt.core.formatter.continuation_indentation_for_array_initializer=2
+org.eclipse.jdt.core.formatter.disabling_tag=@formatter\:off
+org.eclipse.jdt.core.formatter.enabling_tag=@formatter\:on
+org.eclipse.jdt.core.formatter.format_guardian_clause_on_one_line=false
+org.eclipse.jdt.core.formatter.format_line_comment_starting_on_first_column=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_annotation_declaration_header=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_constant_header=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_declaration_header=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_type_header=true
+org.eclipse.jdt.core.formatter.indent_breaks_compare_to_cases=true
+org.eclipse.jdt.core.formatter.indent_empty_lines=false
+org.eclipse.jdt.core.formatter.indent_statements_compare_to_block=true
+org.eclipse.jdt.core.formatter.indent_statements_compare_to_body=true
+org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_cases=true
+org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_switch=false
+org.eclipse.jdt.core.formatter.indentation.size=4
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_field=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_local_variable=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_method=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_package=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_parameter=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_type=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_label=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_opening_brace_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_at_end_of_file_if_missing=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_finally_in_try_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_while_in_do_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_annotation_declaration=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_anonymous_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_block=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter=insert
+org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_binary_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_paren_in_cast=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_assert=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_case=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_labeled_statement=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_allocation_expression=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_annotation=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_throws=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_constant_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_declarations=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_explicitconstructorcall_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_increments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_inits=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_throws=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_invocation_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_field_declarations=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_local_declarations=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_parameterized_type_reference=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_superinterfaces=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_ellipsis=insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_brace_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_cast=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_catch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_for=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_if=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_parenthesized_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_switch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_synchronized=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_try=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_while=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_try_resources=insert
+org.eclipse.jdt.core.formatter.insert_space_after_unary_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter=insert
+org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_binary_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_brace_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_cast=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_catch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_for=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_if=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_parenthesized_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_switch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_synchronized=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_try=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_while=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_assert=insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_case=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_default=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_labeled_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_throws=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_constant_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_declarations=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_explicitconstructorcall_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_increments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_inits=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_throws=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_invocation_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_field_declarations=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_local_declarations=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_superinterfaces=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_ellipsis=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_annotation_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_anonymous_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_block=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_constructor_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_constant=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_method_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_switch=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation_type_member_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_catch=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_if=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_parenthesized_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_switch=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_synchronized=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_try=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_while=insert
+org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_return=insert
+org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_throw=insert
+org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_semicolon=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_try_resources=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_unary_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_brackets_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_annotation_type_member_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.join_lines_in_comments=true
+org.eclipse.jdt.core.formatter.join_wrapped_lines=false
+org.eclipse.jdt.core.formatter.keep_else_statement_on_same_line=false
+org.eclipse.jdt.core.formatter.keep_empty_array_initializer_on_one_line=false
+org.eclipse.jdt.core.formatter.keep_imple_if_on_one_line=false
+org.eclipse.jdt.core.formatter.keep_then_statement_on_same_line=false
+org.eclipse.jdt.core.formatter.lineSplit=250
+org.eclipse.jdt.core.formatter.never_indent_block_comments_on_first_column=false
+org.eclipse.jdt.core.formatter.never_indent_line_comments_on_first_column=false
+org.eclipse.jdt.core.formatter.number_of_blank_lines_at_beginning_of_method_body=0
+org.eclipse.jdt.core.formatter.number_of_empty_lines_to_preserve=1
+org.eclipse.jdt.core.formatter.put_empty_statement_on_new_line=true
+org.eclipse.jdt.core.formatter.tabulation.char=space
+org.eclipse.jdt.core.formatter.tabulation.size=4
+org.eclipse.jdt.core.formatter.use_on_off_tags=false
+org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false
+org.eclipse.jdt.core.formatter.wrap_before_binary_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_or_operator_multicatch=true
+org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/.settings/org.eclipse.jdt.ui.prefs b/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/.settings/org.eclipse.jdt.ui.prefs
new file mode 100644 (file)
index 0000000..232a3fd
--- /dev/null
@@ -0,0 +1,60 @@
+eclipse.preferences.version=1
+editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true
+formatter_profile=_tmf-style
+formatter_settings_version=12
+org.eclipse.jdt.ui.exception.name=e
+org.eclipse.jdt.ui.gettersetter.use.is=true
+org.eclipse.jdt.ui.keywordthis=false
+org.eclipse.jdt.ui.overrideannotation=true
+sp_cleanup.add_default_serial_version_id=true
+sp_cleanup.add_generated_serial_version_id=false
+sp_cleanup.add_missing_annotations=false
+sp_cleanup.add_missing_deprecated_annotations=true
+sp_cleanup.add_missing_methods=false
+sp_cleanup.add_missing_nls_tags=false
+sp_cleanup.add_missing_override_annotations=true
+sp_cleanup.add_missing_override_annotations_interface_methods=true
+sp_cleanup.add_serial_version_id=false
+sp_cleanup.always_use_blocks=true
+sp_cleanup.always_use_parentheses_in_expressions=false
+sp_cleanup.always_use_this_for_non_static_field_access=false
+sp_cleanup.always_use_this_for_non_static_method_access=false
+sp_cleanup.convert_to_enhanced_for_loop=false
+sp_cleanup.correct_indentation=false
+sp_cleanup.format_source_code=false
+sp_cleanup.format_source_code_changes_only=false
+sp_cleanup.make_local_variable_final=false
+sp_cleanup.make_parameters_final=false
+sp_cleanup.make_private_fields_final=true
+sp_cleanup.make_type_abstract_if_missing_method=false
+sp_cleanup.make_variable_declarations_final=false
+sp_cleanup.never_use_blocks=false
+sp_cleanup.never_use_parentheses_in_expressions=true
+sp_cleanup.on_save_use_additional_actions=true
+sp_cleanup.organize_imports=false
+sp_cleanup.qualify_static_field_accesses_with_declaring_class=false
+sp_cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=true
+sp_cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=true
+sp_cleanup.qualify_static_member_accesses_with_declaring_class=false
+sp_cleanup.qualify_static_method_accesses_with_declaring_class=false
+sp_cleanup.remove_private_constructors=true
+sp_cleanup.remove_trailing_whitespaces=true
+sp_cleanup.remove_trailing_whitespaces_all=true
+sp_cleanup.remove_trailing_whitespaces_ignore_empty=false
+sp_cleanup.remove_unnecessary_casts=false
+sp_cleanup.remove_unnecessary_nls_tags=false
+sp_cleanup.remove_unused_imports=false
+sp_cleanup.remove_unused_local_variables=false
+sp_cleanup.remove_unused_private_fields=true
+sp_cleanup.remove_unused_private_members=false
+sp_cleanup.remove_unused_private_methods=true
+sp_cleanup.remove_unused_private_types=true
+sp_cleanup.sort_members=false
+sp_cleanup.sort_members_all=false
+sp_cleanup.use_blocks=true
+sp_cleanup.use_blocks_only_for_return_and_throw=false
+sp_cleanup.use_parentheses_in_expressions=false
+sp_cleanup.use_this_for_non_static_field_access=false
+sp_cleanup.use_this_for_non_static_field_access_only_if_necessary=true
+sp_cleanup.use_this_for_non_static_method_access=false
+sp_cleanup.use_this_for_non_static_method_access_only_if_necessary=true
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/.settings/org.eclipse.pde.api.tools.prefs b/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/.settings/org.eclipse.pde.api.tools.prefs
new file mode 100644 (file)
index 0000000..acc3abd
--- /dev/null
@@ -0,0 +1,97 @@
+ANNOTATION_ELEMENT_TYPE_ADDED_METHOD_WITHOUT_DEFAULT_VALUE=Error
+ANNOTATION_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+ANNOTATION_ELEMENT_TYPE_REMOVED_FIELD=Error
+ANNOTATION_ELEMENT_TYPE_REMOVED_METHOD=Error
+ANNOTATION_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_API_TYPE=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_API_TYPE=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_TYPE=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_TYPE=Error
+API_USE_SCAN_FIELD_SEVERITY=Error
+API_USE_SCAN_METHOD_SEVERITY=Error
+API_USE_SCAN_TYPE_SEVERITY=Error
+CLASS_ELEMENT_TYPE_ADDED_METHOD=Error
+CLASS_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
+CLASS_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+CLASS_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
+CLASS_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+CLASS_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
+CLASS_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
+CLASS_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+CLASS_ELEMENT_TYPE_REMOVED_CONSTRUCTOR=Error
+CLASS_ELEMENT_TYPE_REMOVED_FIELD=Error
+CLASS_ELEMENT_TYPE_REMOVED_METHOD=Error
+CLASS_ELEMENT_TYPE_REMOVED_SUPERCLASS=Error
+CLASS_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+CLASS_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+CONSTRUCTOR_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+CONSTRUCTOR_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+CONSTRUCTOR_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
+CONSTRUCTOR_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+ENUM_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
+ENUM_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+ENUM_ELEMENT_TYPE_REMOVED_ENUM_CONSTANT=Error
+ENUM_ELEMENT_TYPE_REMOVED_FIELD=Error
+ENUM_ELEMENT_TYPE_REMOVED_METHOD=Error
+ENUM_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+FIELD_ELEMENT_TYPE_ADDED_VALUE=Error
+FIELD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+FIELD_ELEMENT_TYPE_CHANGED_FINAL_TO_NON_FINAL_STATIC_CONSTANT=Error
+FIELD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
+FIELD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
+FIELD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
+FIELD_ELEMENT_TYPE_CHANGED_TYPE=Error
+FIELD_ELEMENT_TYPE_CHANGED_VALUE=Error
+FIELD_ELEMENT_TYPE_REMOVED_TYPE_ARGUMENT=Error
+FIELD_ELEMENT_TYPE_REMOVED_VALUE=Error
+ILLEGAL_EXTEND=Warning
+ILLEGAL_IMPLEMENT=Warning
+ILLEGAL_INSTANTIATE=Warning
+ILLEGAL_OVERRIDE=Warning
+ILLEGAL_REFERENCE=Warning
+INTERFACE_ELEMENT_TYPE_ADDED_FIELD=Error
+INTERFACE_ELEMENT_TYPE_ADDED_METHOD=Error
+INTERFACE_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
+INTERFACE_ELEMENT_TYPE_ADDED_SUPER_INTERFACE_WITH_METHODS=Error
+INTERFACE_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+INTERFACE_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
+INTERFACE_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_FIELD=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_METHOD=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+INVALID_JAVADOC_TAG=Warning
+INVALID_REFERENCE_IN_SYSTEM_LIBRARIES=Warning
+LEAK_EXTEND=Warning
+LEAK_FIELD_DECL=Warning
+LEAK_IMPLEMENT=Warning
+LEAK_METHOD_PARAM=Warning
+LEAK_METHOD_RETURN_TYPE=Warning
+METHOD_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
+METHOD_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+METHOD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+METHOD_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
+METHOD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
+METHOD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
+METHOD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
+METHOD_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
+METHOD_ELEMENT_TYPE_REMOVED_ANNOTATION_DEFAULT_VALUE=Error
+METHOD_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+MISSING_EE_DESCRIPTIONS=Ignore
+TYPE_PARAMETER_ELEMENT_TYPE_ADDED_CLASS_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_ADDED_INTERFACE_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_CLASS_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_INTERFACE_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_CLASS_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_INTERFACE_BOUND=Error
+UNUSED_PROBLEM_FILTERS=Warning
+automatically_removed_unused_problem_filters=false
+eclipse.preferences.version=1
+incompatible_api_component_version=Error
+incompatible_api_component_version_include_major_without_breaking_change=Disabled
+incompatible_api_component_version_include_minor_without_api_change=Disabled
+invalid_since_tag_version=Error
+malformed_since_tag=Error
+missing_since_tag=Error
+report_api_breakage_when_major_version_incremented=Disabled
+report_resolution_errors_api_component=Warning
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/.settings/org.eclipse.pde.prefs b/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/.settings/org.eclipse.pde.prefs
new file mode 100644 (file)
index 0000000..62cfa90
--- /dev/null
@@ -0,0 +1,32 @@
+compilers.f.unresolved-features=1
+compilers.f.unresolved-plugins=1
+compilers.incompatible-environment=1
+compilers.p.build=1
+compilers.p.build.bin.includes=1
+compilers.p.build.encodings=2
+compilers.p.build.java.compiler=2
+compilers.p.build.java.compliance=1
+compilers.p.build.missing.output=2
+compilers.p.build.output.library=1
+compilers.p.build.source.library=1
+compilers.p.build.src.includes=1
+compilers.p.deprecated=1
+compilers.p.discouraged-class=1
+compilers.p.internal=1
+compilers.p.missing-packages=2
+compilers.p.missing-version-export-package=2
+compilers.p.missing-version-import-package=2
+compilers.p.missing-version-require-bundle=2
+compilers.p.no-required-att=0
+compilers.p.not-externalized-att=2
+compilers.p.unknown-attribute=1
+compilers.p.unknown-class=1
+compilers.p.unknown-element=1
+compilers.p.unknown-identifier=1
+compilers.p.unknown-resource=1
+compilers.p.unresolved-ex-points=0
+compilers.p.unresolved-import=0
+compilers.s.create-docs=false
+compilers.s.doc-folder=doc
+compilers.s.open-tags=1
+eclipse.preferences.version=1
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/META-INF/MANIFEST.MF b/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/META-INF/MANIFEST.MF
new file mode 100644 (file)
index 0000000..c406999
--- /dev/null
@@ -0,0 +1,26 @@
+Manifest-Version: 1.0
+Bundle-ManifestVersion: 2
+Bundle-Name: %Bundle-Name
+Bundle-Vendor: %Bundle-Vendor
+Bundle-Version: 1.0.0.qualifier
+Bundle-Localization: plugin
+Bundle-SymbolicName: org.eclipse.tracecompass.lttng2.control.ui.tests;singleton:=true
+Bundle-ActivationPolicy: lazy
+Bundle-RequiredExecutionEnvironment: JavaSE-1.7
+Require-Bundle: org.junit;bundle-version="4.0.0",
+ org.eclipse.core.commands,
+ org.eclipse.core.runtime,
+ org.eclipse.ui,
+ org.eclipse.ui.ide,
+ org.eclipse.remote.core,
+ org.eclipse.tracecompass.common.core,
+ org.eclipse.tracecompass.lttng2.control.core,
+ org.eclipse.tracecompass.lttng2.control.ui,
+ org.eclipse.tracecompass.tmf.remote.core,
+ org.eclipse.tracecompass.tmf.remote.core.tests
+Export-Package: org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs;x-internal:=true,
+ org.eclipse.tracecompass.internal.lttng2.control.stubs.service;x-internal:=true,
+ org.eclipse.tracecompass.internal.lttng2.control.stubs.shells;x-internal:=true,
+ org.eclipse.tracecompass.lttng2.control.ui.tests;x-friends:="org.eclipse.tracecompass.alltests",
+ org.eclipse.tracecompass.lttng2.control.ui.tests.model.component;x-internal:=true,
+ org.eclipse.tracecompass.lttng2.control.ui.tests.service;x-internal:=true
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/about.html b/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/about.html
new file mode 100644 (file)
index 0000000..c258ef5
--- /dev/null
@@ -0,0 +1,28 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"/>
+<title>About</title>
+</head>
+<body lang="EN-US">
+<h2>About This Content</h2>
+<p>June 5, 2006</p>    
+<h3>License</h3>
+
+<p>The Eclipse Foundation makes available all content in this plug-in (&quot;Content&quot;).  Unless otherwise 
+indicated below, the Content is provided to you under the terms and conditions of the
+Eclipse Public License Version 1.0 (&quot;EPL&quot;).  A copy of the EPL is available 
+at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>.
+For purposes of the EPL, &quot;Program&quot; will mean the Content.</p>
+
+<p>If you did not receive this Content directly from the Eclipse Foundation, the Content is 
+being redistributed by another party (&quot;Redistributor&quot;) and different terms and conditions may
+apply to your use of any object code in the Content.  Check the Redistributor's license that was 
+provided with the Content.  If no such license exists, contact the Redistributor.  Unless otherwise
+indicated below, the terms and conditions of the EPL still apply to any source code in the Content
+and such source code may be obtained at <a href="http://www.eclipse.org/">http://www.eclipse.org</a>.</p>
+
+</body>
+</html>
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/build.properties b/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/build.properties
new file mode 100644 (file)
index 0000000..203b5b3
--- /dev/null
@@ -0,0 +1,22 @@
+###############################################################################
+# Copyright (c) 2013, 2015 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:
+#     Ericsson - Initial API and implementation
+###############################################################################
+
+source.. = src/,\
+           stubs/
+output.. = bin/
+bin.includes = META-INF/,\
+               .,\
+               plugin.properties,\
+               about.html
+src.includes = about.html
+additional.bundles = org.eclipse.jdt.annotation
+jars.extra.classpath = platform:/plugin/org.eclipse.jdt.annotation
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/plugin.properties b/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/plugin.properties
new file mode 100644 (file)
index 0000000..d0deb3e
--- /dev/null
@@ -0,0 +1,14 @@
+###############################################################################
+# Copyright (c) 2013, 2014 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:
+#     Ericsson - Initial API and implementation
+###############################################################################
+
+Bundle-Vendor = Eclipse Trace Compass
+Bundle-Name = Trace Compass LTTng Control UI Tests Plug-in
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/pom.xml b/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/pom.xml
new file mode 100644 (file)
index 0000000..01ee1a6
--- /dev/null
@@ -0,0 +1,45 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+   Copyright (C) 2011, Red Hat, Inc.
+
+   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
+-->
+<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>
+    <artifactId>org.eclipse.tracecompass.lttng-parent</artifactId>
+    <groupId>org.eclipse.tracecompass</groupId>
+    <version>1.0.0-SNAPSHOT</version>
+  </parent>
+
+  <artifactId>org.eclipse.tracecompass.lttng2.control.ui.tests</artifactId>
+  <version>1.0.0-SNAPSHOT</version>
+  <packaging>eclipse-test-plugin</packaging>
+
+  <name>Trace Compass LTTng Control UI Tests Plug-in</name>
+
+ <build>
+     <plugins>
+      <plugin>
+        <groupId>org.eclipse.tycho</groupId>
+        <artifactId>tycho-surefire-plugin</artifactId>
+        <version>${tycho-version}</version>
+        <configuration>
+          <testSuite>org.eclipse.tracecompass.lttng2.control.ui.tests</testSuite>
+          <testClass>org.eclipse.tracecompass.lttng2.control.ui.tests.AllTests</testClass>
+          <useUIHarness>true</useUIHarness>
+          <useUIThread>true</useUIThread>
+          <argLine>${tycho.testArgLine} ${base.ui.test.vmargs}</argLine>
+          <product>org.eclipse.platform.ide</product>
+        </configuration>
+      </plugin>
+    </plugins>
+  </build>
+
+ <groupId>org.eclipse.tracecompass</groupId>
+</project>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/ActivatorTest.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/ActivatorTest.java
new file mode 100644 (file)
index 0000000..a9f05de
--- /dev/null
@@ -0,0 +1,60 @@
+/*******************************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Francois Chouinard - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.control.ui.tests;
+
+import static org.junit.Assert.assertTrue;
+
+import org.junit.Test;
+
+/**
+ * Test suite for the Activator class
+ */
+public class ActivatorTest {
+
+    // ------------------------------------------------------------------------
+    // Tests
+    // ------------------------------------------------------------------------
+
+    /**
+     * Test method for {@link org.eclipse.tracecompass.internal.lttng2.control.ui.Activator#Activator}.
+     */
+    @Test
+    public void testActivator() {
+        assertTrue(true);
+    }
+
+    /**
+     * Test method for {@link org.eclipse.tracecompass.internal.lttng2.control.ui.Activator#getDefault}.
+     */
+    @Test
+    public void testGetDefault() {
+        assertTrue(true);
+    }
+
+    /**
+     * Test method for {@link org.eclipse.tracecompass.internal.lttng2.control.ui.Activator#start}.
+     */
+    @Test
+    public void testStartBundleContext() {
+        assertTrue(true);
+    }
+
+    /**
+     * Test method for {@link org.eclipse.tracecompass.internal.lttng2.control.ui.Activator#stop}.
+     */
+    @Test
+    public void testStopBundleContext() {
+        assertTrue(true);
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/AllTests.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/AllTests.java
new file mode 100644 (file)
index 0000000..fdc59a1
--- /dev/null
@@ -0,0 +1,30 @@
+/*******************************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Francois Chouinard - Initial API and implementation
+ *   Alexandre Montplaisir - Port to JUnit4
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.control.ui.tests;
+
+import org.junit.runner.RunWith;
+import org.junit.runners.Suite;
+
+/**
+ * Runner for the test suite
+ */
+@RunWith(Suite.class)
+@Suite.SuiteClasses({
+    ActivatorTest.class,
+    org.eclipse.tracecompass.lttng2.control.ui.tests.model.component.AllTests.class,
+    org.eclipse.tracecompass.lttng2.control.ui.tests.service.AllTests.class
+})
+public class AllTests {
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/AllTests.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/AllTests.java
new file mode 100644 (file)
index 0000000..e6f2315
--- /dev/null
@@ -0,0 +1,39 @@
+/*******************************************************************************
+ * Copyright (c) 2011, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Alexandre Montplaisir - Port to JUnit4
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.control.ui.tests.model.component;
+
+import org.junit.runner.RunWith;
+import org.junit.runners.Suite;
+
+/**
+ * Runner for the model.component unit tests.
+ */
+@RunWith(Suite.class)
+@Suite.SuiteClasses({
+    TraceControlComponentTest.class,
+    TraceControlCreateSessionTests.class,
+    TraceControlCreateSessionMiTests.class,
+    TraceControlKernelProviderTests.class,
+    TraceControlKernelSessionTests.class,
+    TraceControlPropertiesTest.class,
+    TraceControlTreeModelNoProvidersTest.class,
+    TraceControlTreeModelTest.class,
+    TraceControlUstProviderTests.class,
+    TraceControlUstSessionTests.class,
+    TraceControlUstSessionTests2.class,
+    TraceControlSnapshotSessionTests.class
+})
+public class AllTests {
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/ListenerValidator.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/ListenerValidator.java
new file mode 100644 (file)
index 0000000..0dc5b11
--- /dev/null
@@ -0,0 +1,94 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.lttng2.control.ui.tests.model.component;
+
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponentChangedListener;
+
+/**
+ * The class can be used to validate the listener interface.
+ */
+@SuppressWarnings("javadoc")
+public class ListenerValidator implements ITraceControlComponentChangedListener {
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+    private boolean fisAddedCalled = false;
+    private boolean fisRemoveCalled = false;
+    private boolean fisChangedCalled = false;
+
+    private ITraceControlComponent fParent = null;
+    private ITraceControlComponent fChild = null;
+    private ITraceControlComponent fChangedComponent = null;
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+    public boolean isAddedCalled() {
+        return fisAddedCalled;
+    }
+
+    public boolean isRemovedCalled() {
+        return fisRemoveCalled;
+    }
+
+    public boolean isChangedCalled() {
+        return fisChangedCalled;
+    }
+
+    public ITraceControlComponent getSavedParent() {
+        return fParent;
+    }
+
+    public ITraceControlComponent getSavedChild() {
+        return fChild;
+    }
+
+    public ITraceControlComponent getSavedComponent() {
+        return fChangedComponent;
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+    public void initialize() {
+        fisAddedCalled = false;
+        fisRemoveCalled = false;
+        fisChangedCalled = false;
+        fParent = null;
+        fChild = null;
+        fChangedComponent = null;
+    }
+
+    @Override
+    public void componentAdded(ITraceControlComponent parent, ITraceControlComponent component) {
+        fisAddedCalled = true;
+        fParent = parent;
+        fChild = component;
+    }
+
+    @Override
+    public void componentRemoved(ITraceControlComponent parent, ITraceControlComponent component) {
+        fisRemoveCalled = true;
+        fParent = parent;
+        fChild = component;
+    }
+
+    @Override
+    public void componentChanged(ITraceControlComponent component) {
+        fisChangedCalled = true;
+        fParent = null;
+        fChangedComponent = component;
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlComponentTest.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlComponentTest.java
new file mode 100644 (file)
index 0000000..2ddb6e9
--- /dev/null
@@ -0,0 +1,544 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Alexandre Montplaisir - Port to JUnit4
+ **********************************************************************/
+
+package org.eclipse.tracecompass.lttng2.control.ui.tests.model.component;
+
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertFalse;
+import static org.junit.Assert.assertNotNull;
+import static org.junit.Assert.assertTrue;
+
+import java.util.LinkedList;
+import java.util.List;
+
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.remote.core.IRemoteConnection;
+import org.eclipse.swt.graphics.Image;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TargetNodeState;
+import org.eclipse.tracecompass.internal.lttng2.control.stubs.service.TestRemoteSystemProxy;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponentChangedListener;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceControlComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceControlRoot;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.service.ILttngControlService;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.service.LTTngControlService;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.service.LTTngControlServiceConstants;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.service.LTTngControlServiceMI;
+import org.eclipse.tracecompass.tmf.remote.core.proxy.TmfRemoteConnectionFactory;
+import org.eclipse.ui.ISharedImages;
+import org.eclipse.ui.PlatformUI;
+import org.junit.Test;
+
+/**
+ * The class <code>TraceControlComponentTest</code> contains tests for the class
+ * <code>{@link TraceControlComponent}</code>.
+ */
+public class TraceControlComponentTest {
+
+    private IRemoteConnection fHost = TmfRemoteConnectionFactory.getLocalConnection();
+
+    /**
+     * Run the TraceControlComponent(String) constructor test.
+     */
+    @Test
+    public void testTraceControlComponent_1() {
+
+        String name = "node";
+
+        TraceControlComponent result = new TraceControlComponent(name);
+
+        assertNotNull(result);
+        assertEquals(name, result.getName());
+        assertEquals(null, result.getParent());
+        assertEquals(false, result.hasChildren());
+        assertEquals(null, result.getImage());
+        assertEquals(null, result.getControlService());
+        assertEquals(null, result.getToolTip());
+    }
+
+    /**
+     * Run the TraceControlComponent(String,ITraceControlComponent) constructor test.
+     */
+    @Test
+    public void testTraceControlComponent_2() {
+        String name = "node";
+
+        ITraceControlComponent parent = new TraceControlRoot();
+        TraceControlComponent result = new TraceControlComponent(name, parent);
+
+        assertNotNull(result);
+        assertEquals(name, result.getName());
+        assertEquals(false, result.hasChildren());
+        assertEquals(null, result.getImage());
+        assertEquals(null, result.getControlService());
+        assertEquals(null, result.getToolTip());
+    }
+
+    /**
+     * Run the void addChild(ITraceControlComponent) method test.
+     */
+    @Test
+    public void testAddAndGetChild1() {
+        TraceControlComponent fixture = new TraceControlComponent("node", new TraceControlRoot());
+        fixture.setToolTip("This is the test node");
+        fixture.addChild(new TraceControlRoot());
+        ITraceControlComponent component = new TraceControlRoot();
+        fixture.addChild(component);
+
+        ITraceControlComponent child = fixture.getChild(TraceControlRoot.TRACE_CONTROL_ROOT_NAME);
+        assertNotNull(child);
+        assertEquals(TraceControlRoot.TRACE_CONTROL_ROOT_NAME, child.getName());
+    }
+
+    /**
+     * Run the void addChild(ITraceControlComponent) method test.
+     */
+    @Test
+    public void testAddAndGetChild2() {
+        TraceControlComponent fixture = new TraceControlComponent("", new TraceControlRoot());
+        fixture.setToolTip("");
+        ITraceControlComponent component = null;
+
+        fixture.addChild(component);
+        assertFalse(fixture.hasChildren());
+    }
+
+    /**
+     * Run the void addComponentListener(ITraceControlComponentChangedListener) method test.
+     */
+    @Test
+    public void testAddComponentListener_1() {
+        TraceControlComponent fixture = new TraceControlComponent("", (ITraceControlComponent) null);
+        fixture.setToolTip("");
+
+        ListenerValidator validator = new ListenerValidator();
+        fixture.addComponentListener(validator);
+
+        TraceControlRoot root = new TraceControlRoot();
+        fixture.addChild(root);
+        assertTrue(validator.isAddedCalled());
+
+        fixture.removeChild(root);
+        assertTrue(validator.isRemovedCalled());
+
+        fixture.fireComponentChanged(fixture);
+        assertTrue(validator.isChangedCalled());
+    }
+
+    /**
+     * Run the boolean containsChild(String) method test.
+     */
+    @Test
+    public void testContainsChild_1() {
+        TraceControlComponent fixture = new TraceControlComponent("", new TraceControlRoot());
+        fixture.setToolTip("");
+        fixture.addChild(new TraceControlRoot());
+        String name = "node";
+
+        boolean result = fixture.containsChild(name);
+
+        assertEquals(false, result);
+    }
+
+    /**
+     * Run the boolean containsChild(String) method test.
+     */
+    @Test
+    public void testContainsChild_2() {
+        TraceControlComponent fixture = new TraceControlComponent("name", new TraceControlRoot());
+        fixture.setToolTip("");
+
+        boolean result = fixture.containsChild(TraceControlRoot.TRACE_CONTROL_ROOT_NAME);
+
+        assertEquals(false, result);
+    }
+
+    /**
+     * Run the void fireCompenentAdded(ITraceControlComponent,ITraceControlComponent) method test.
+     * Run the void fireCompenentRemoved(ITraceControlComponent,ITraceControlComponent) method test.
+     * Run the void fireCompenentChanged(ITraceControlComponent) method test
+     */
+    @Test
+    public void testFireCompenentUpdated() {
+        ITraceControlComponent parent = new TraceControlRoot();
+
+        TraceControlComponent fixture = new TraceControlComponent("node", parent);
+        fixture.setToolTip("");
+
+        ITraceControlComponent component = new TraceControlComponent("child");
+        fixture.addChild(component);
+
+        ListenerValidator validator = new ListenerValidator();
+        fixture.addComponentListener(validator);
+
+        fixture.fireComponentAdded(parent, component);
+        assertTrue(validator.isAddedCalled());
+        assertEquals(parent.getName(), validator.getSavedParent().getName());
+        assertEquals(component.getName(), validator.getSavedChild().getName());
+
+        validator.initialize();
+
+        fixture.fireComponentRemoved(parent, component);
+        assertTrue(validator.isRemovedCalled());
+        assertEquals(parent.getName(), validator.getSavedParent().getName());
+        assertEquals(component.getName(), validator.getSavedChild().getName());
+
+        validator.initialize();
+        fixture.fireComponentChanged(fixture);
+        assertTrue(validator.isChangedCalled());
+        assertEquals(fixture.getName(), validator.getSavedComponent().getName());
+    }
+
+    /**
+     * Run the Object getAdapter(Class) method test.
+     */
+    @Test
+    public void testGetAdapter() {
+        TraceControlComponent fixture = new TraceControlComponent("", new TraceControlRoot());
+        fixture.setToolTip("");
+        fixture.addChild(new TraceControlRoot());
+        Class<Object> adapter = Object.class;
+
+        Object result = fixture.getAdapter(adapter);
+
+        assertEquals(null, result);
+    }
+
+    /**
+     * Run the ITraceControlComponent[] getChildren() method test.
+     */
+    @Test
+    public void testGetChildren_1() {
+        TraceControlComponent fixture = new TraceControlComponent("", new TraceControlRoot());
+        fixture.setToolTip("");
+        fixture.addChild(new TraceControlRoot());
+
+        ITraceControlComponent[] result = fixture.getChildren();
+
+        assertNotNull(result);
+        assertEquals(1, result.length);
+        assertNotNull(result[0]);
+        assertEquals("trace_control_root", result[0].getName());
+        assertEquals(null, result[0].getParent());
+        assertEquals(false, result[0].hasChildren());
+        assertEquals(null, result[0].getImage());
+        assertEquals(null, result[0].getControlService());
+        assertEquals(null, result[0].getToolTip());
+    }
+
+    /**
+     * Run the ILttngControlService getControlService()/setControlService()
+     * method test.
+     *
+     * @throws ExecutionException
+     *             Would fail the test
+     */
+    @Test
+    public void testGetAndSetControlService_1() throws ExecutionException {
+
+        TraceControlComponent parent = new TraceControlComponent("parent") {
+            ILttngControlService fService = null;
+
+            @Override
+            public void setControlService(ILttngControlService service ) {
+                fService = service;
+            }
+
+            @Override
+            public ILttngControlService getControlService() {
+                return fService;
+            }
+        };
+
+        TraceControlComponent fixture = new TraceControlComponent("", parent);
+        parent.addChild(fixture);
+        fixture.setToolTip("");
+        TraceControlComponent child = new TraceControlComponent("child", fixture);
+        fixture.addChild(child);
+
+        ILttngControlService result = fixture.getControlService();
+        assertEquals(null, result);
+
+        TestRemoteSystemProxy proxy = new TestRemoteSystemProxy(fHost);
+        ILttngControlService service = new LTTngControlService(proxy.createCommandShell());
+        fixture.setControlService(service);
+        result = fixture.getControlService();
+        assertNotNull(service);
+        assertEquals(service, result);
+
+        service = new LTTngControlServiceMI(proxy.createCommandShell(), LTTngControlServiceMI.class.getResource(LTTngControlServiceConstants.MI_XSD_FILENAME));
+        fixture.setControlService(service);
+        result = fixture.getControlService();
+        assertNotNull(service);
+        assertEquals(service, result);
+
+        result = fixture.getChildren()[0].getControlService();
+        assertNotNull(service);
+        assertEquals(service, result);
+    }
+
+    /**
+     * Run the Image getImage() method test.
+     */
+    @Test
+    public void testGetImage_1() {
+        TraceControlComponent fixture = new TraceControlComponent("", new TraceControlRoot());
+        fixture.setToolTip("");
+        fixture.addChild(new TraceControlRoot());
+
+        Image result = fixture.getImage();
+        assertEquals(null, result);
+
+        fixture.setImage(PlatformUI.getWorkbench().getSharedImages().getImage(ISharedImages.IMG_OBJ_FOLDER));
+        assertNotNull(fixture.getImage());
+    }
+
+    /**
+     * Run the boolean hasChildren() method test.
+     */
+    @Test
+    public void testHasChildren_1() {
+        TraceControlComponent fixture = new TraceControlComponent("", new TraceControlRoot());
+        fixture.setToolTip("");
+        fixture.addChild(new TraceControlRoot());
+
+        boolean result = fixture.hasChildren();
+
+        assertTrue(result);
+    }
+
+    /**
+     * Run the boolean hasChildren() method test.
+     */
+    @Test
+    public void testHasChildren_2() {
+        TraceControlComponent fixture = new TraceControlComponent("", new TraceControlRoot());
+        fixture.setToolTip("");
+
+        boolean result = fixture.hasChildren();
+
+        assertFalse(result);
+    }
+
+    /**
+     * Run the void removeAllChildren() method test.
+     */
+    @Test
+    public void testRemoveAllChildren_2() {
+        TraceControlComponent fixture = new TraceControlComponent("", new TraceControlRoot());
+        fixture.setToolTip("");
+
+        fixture.addChild(new TraceControlRoot());
+        fixture.addChild(new TraceControlComponent("child"));
+
+        fixture.removeAllChildren();
+        assertFalse(fixture.hasChildren());
+    }
+
+    /**
+     * Run the void removeChild(ITraceControlComponent) method test.
+     */
+    @Test
+    public void testRemoveChild_1() {
+        TraceControlComponent fixture = new TraceControlComponent("", new TraceControlRoot());
+        fixture.setToolTip("");
+        TraceControlComponent child = new TraceControlComponent("child", fixture);
+
+        fixture.addChild(child);
+        fixture.removeChild(child);
+        assertFalse(fixture.hasChildren());
+    }
+
+    /**
+     * Run the void removeChild(ITraceControlComponent) method test.
+     */
+    @Test
+    public void testRemoveChild_2() {
+        TraceControlComponent fixture = new TraceControlComponent("", new TraceControlRoot());
+        fixture.setToolTip("");
+        fixture.addChild(new TraceControlRoot());
+        ITraceControlComponent component = null;
+
+        fixture.removeChild(component);
+        assertTrue(fixture.hasChildren());
+    }
+
+    /**
+     * Run the void removeComponentListener(ITraceControlComponentChangedListener) method test.
+     */
+    @Test
+    public void testRemoveComponentListener_1() {
+        TraceControlComponent fixture = new TraceControlComponent("", (ITraceControlComponent) null);
+        fixture.setToolTip("");
+
+        ListenerValidator validator = new ListenerValidator();
+        fixture.addComponentListener(validator);
+
+        // Remove listener and check that validator is not called anymore
+        validator.initialize();
+        fixture.removeComponentListener(validator);
+        TraceControlRoot root = new TraceControlRoot();
+        fixture.addChild(root);
+        assertFalse(validator.isAddedCalled());
+
+        fixture.removeChild(root);
+        assertFalse(validator.isRemovedCalled());
+
+        fixture.fireComponentChanged(fixture);
+        assertFalse(validator.isChangedCalled());
+    }
+
+    /**
+     * Run the void removeComponentListener(ITraceControlComponentChangedListener) method test.
+     */
+    @Test
+    public void testRemoveComponentListener_2() {
+        TraceControlComponent fixture = new TraceControlComponent("", new TraceControlRoot());
+        fixture.setToolTip("");
+        fixture.addChild(new TraceControlRoot());
+        ITraceControlComponentChangedListener listener = new ControlView();
+
+        fixture.removeComponentListener(listener);
+
+    }
+
+    /**
+     * Run the void setChildren(List<ITraceControlComponent>)/ITraceControlComponent[] getChildren() method test.
+     */
+    @Test
+    public void testGetAndSetChildren() {
+        TraceControlComponent fixture = new TraceControlComponent("", new TraceControlRoot());
+        fixture.setToolTip("");
+        List<ITraceControlComponent> children = new LinkedList<>();
+        children.add(new TraceControlComponent("child1"));
+        children.add(new TraceControlComponent("child2"));
+
+        fixture.setChildren(children);
+
+        ITraceControlComponent[] result = fixture.getChildren();
+        assertEquals(2, result.length);
+        assertEquals("child1", result[0].getName());
+        assertEquals("child2", result[1].getName());
+    }
+
+    /**
+     * Run the void String getName()/setName(String) method tests.
+     */
+    @Test
+    public void testGetAndSetName() {
+        TraceControlComponent fixture = new TraceControlComponent("", new TraceControlRoot());
+        fixture.setToolTip("");
+        fixture.addChild(new TraceControlRoot());
+        String name = "node";
+
+        fixture.setName(name);
+        assertEquals(name,fixture.getName());
+
+    }
+
+    /**
+     * Run the void ITraceControlComponent getParent()/setParent(ITraceControlComponent) method tests.
+     */
+    @Test
+    public void testGetAndSetParent() {
+        TraceControlComponent fixture = new TraceControlComponent("", new TraceControlRoot());
+        fixture.setToolTip("");
+        fixture.addChild(new TraceControlRoot());
+        ITraceControlComponent parent = new TraceControlRoot();
+        parent.addChild(fixture);
+
+        fixture.setParent(parent);
+        ITraceControlComponent retrievedParent = fixture.getParent();
+        assertNotNull(retrievedParent);
+        assertEquals(parent.getName(), retrievedParent.getName());
+        assertEquals(TraceControlRoot.TRACE_CONTROL_ROOT_NAME, retrievedParent.getName());
+        assertEquals(null, retrievedParent.getParent());
+        assertEquals(true, retrievedParent.hasChildren());
+    }
+
+    /**
+     * Run the void TargetNodeState getTargetNodeState()/etTargetNodeState(TargetNodeState) method tests.
+     */
+    @Test
+    public void testGetAndSetTargetNodeState_1() {
+        TraceControlComponent parent = new TraceControlComponent("parent") {
+            private TargetNodeState fState;
+
+            @Override
+            public void setTargetNodeState(TargetNodeState state ) {
+                fState = state;
+            }
+
+            @Override
+            public TargetNodeState getTargetNodeState() {
+                return fState;
+            }
+        };
+
+        TraceControlComponent fixture = new TraceControlComponent("", parent);
+        parent.addChild(fixture);
+
+        fixture.setToolTip("");
+        TargetNodeState state = TargetNodeState.CONNECTED;
+
+        fixture.setTargetNodeState(state);
+        TargetNodeState result = fixture.getTargetNodeState();
+
+        assertNotNull(result);
+        assertEquals(state, result);
+        // Check also parent
+        assertEquals(state, fixture.getParent().getTargetNodeState());
+        assertEquals("CONNECTED", result.name());
+        assertEquals("CONNECTED", result.toString());
+        assertEquals(2, result.ordinal());
+
+        fixture.setTargetNodeState(TargetNodeState.DISCONNECTED);
+        result = fixture.getTargetNodeState();
+        assertNotNull(result);
+        assertEquals("DISCONNECTED", result.name());
+        assertEquals("DISCONNECTED", result.toString());
+        assertEquals(0, result.ordinal());
+
+        state = TargetNodeState.CONNECTING;
+
+        fixture.setTargetNodeState(state);
+        result = fixture.getTargetNodeState();
+        assertNotNull(result);
+        assertEquals("CONNECTING", result.name());
+        assertEquals("CONNECTING", result.toString());
+        assertEquals(3, result.ordinal());
+
+        fixture.setTargetNodeState(TargetNodeState.DISCONNECTING);
+        result = fixture.getTargetNodeState();
+        assertNotNull(result);
+        assertEquals("DISCONNECTING", result.name());
+        assertEquals("DISCONNECTING", result.toString());
+        assertEquals(1, result.ordinal());
+
+    }
+
+    /**
+     * Run the void setToolTip(String) method test.
+     */
+    @Test
+    public void testGetSndSetToolTip() {
+        TraceControlComponent fixture = new TraceControlComponent("", new TraceControlRoot());
+        fixture.setToolTip("This is a tooltip");
+        fixture.addChild(new TraceControlRoot());
+
+        String result = fixture.getToolTip();
+
+        assertEquals("This is a tooltip", result);
+    }
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlCreateSessionMiTests.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlCreateSessionMiTests.java
new file mode 100644 (file)
index 0000000..8710336
--- /dev/null
@@ -0,0 +1,27 @@
+/**********************************************************************
+ * Copyright (c) 2014 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:
+ *   Jonathan Rajotte - Support for machine interface LTTng 2.6
+ **********************************************************************/
+
+package org.eclipse.tracecompass.lttng2.control.ui.tests.model.component;
+
+/**
+ * Machine interface Kernel session manipulation handling test cases.
+ * LTTng 2.6
+ */
+public class TraceControlCreateSessionMiTests extends TraceControlCreateSessionTests {
+
+    private static final String TEST_STREAM = "CreateSessionTestMi.cfg";
+
+    @Override
+    protected String getTestStream() {
+        return TEST_STREAM;
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlCreateSessionTests.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlCreateSessionTests.java
new file mode 100644 (file)
index 0000000..787684d
--- /dev/null
@@ -0,0 +1,280 @@
+/**********************************************************************
+ * Copyright (c) 2013, 2015 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Jonathan Rajotte - Support for LTTng 2.6
+ *   Markus Schorn - Bug 448058: Use org.eclipse.remote in favor of RSE
+ **********************************************************************/
+
+package org.eclipse.tracecompass.lttng2.control.ui.tests.model.component;
+
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertNotNull;
+import static org.junit.Assert.assertTrue;
+
+import java.io.File;
+import java.net.URL;
+
+import org.eclipse.core.runtime.FileLocator;
+import org.eclipse.core.runtime.Path;
+import org.eclipse.jdt.annotation.NonNull;
+import org.eclipse.remote.core.IRemoteConnection;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TargetNodeState;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
+import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.CreateSessionDialogStub;
+import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.DestroyConfirmDialogStub;
+import org.eclipse.tracecompass.internal.lttng2.control.stubs.service.TestRemoteSystemProxy;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.TraceControlDialogFactory;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.service.ILttngControlService;
+import org.eclipse.tracecompass.tmf.remote.core.proxy.TmfRemoteConnectionFactory;
+import org.junit.After;
+import org.junit.Before;
+import org.junit.Test;
+import org.osgi.framework.FrameworkUtil;
+
+/**
+ * The class {@link TraceControlKernelSessionTests} contains Kernel
+ * session/channel/event handling test cases.
+ */
+public class TraceControlCreateSessionTests {
+
+    // ------------------------------------------------------------------------
+    // Constants
+    // ------------------------------------------------------------------------
+    private static final String TEST_STREAM = "CreateSessionTest.cfg";
+    private static final String SCEN_SCENARIO_FILE_PROTO_TEST = "CreateSessionFileProto";
+    private static final String SCEN_SCENARIO_CONTROL_DATA_TEST = "CreateSessionControlData";
+    private static final String SCEN_SCENARIO_NETWORK_TEST = "CreateSessionNetwork";
+    private static final String SCEN_SCENARIO_NETWORK2_TEST = "CreateSessionNetwork2";
+
+    private static final String SESSION = "mysession";
+
+    // ------------------------------------------------------------------------
+    // Test data
+    // ------------------------------------------------------------------------
+    private TraceControlTestFacility fFacility;
+    private IRemoteConnection fHost = TmfRemoteConnectionFactory.getLocalConnection();
+    private @NonNull TestRemoteSystemProxy fProxy = new TestRemoteSystemProxy(fHost);
+    private String fTestFile;
+
+    // ------------------------------------------------------------------------
+    // Housekeeping
+    // ------------------------------------------------------------------------
+
+    /**
+     * Perform pre-test initialization.
+     *
+     * @throws Exception
+     *             if the initialization fails for some reason
+     */
+    @Before
+    public void setUp() throws Exception {
+        fFacility = TraceControlTestFacility.getInstance();
+        fFacility.init();
+        URL location = FileLocator.find(FrameworkUtil.getBundle(this.getClass()), new Path(TraceControlTestFacility.DIRECTORY + File.separator + getTestStream()), null);
+        File testfile = new File(FileLocator.toFileURL(location).toURI());
+        fTestFile = testfile.getAbsolutePath();
+    }
+
+    /**
+     * Get the test stream file name to use for the test suite
+     *
+     * @return the name of the test stream file
+     */
+    protected String getTestStream() {
+        return TEST_STREAM;
+    }
+
+    /**
+     * Perform post-test clean-up.
+     */
+    @After
+    public void tearDown() {
+        fFacility.waitForJobs();
+    }
+
+    /**
+     * Run the TraceControlComponent.
+     *
+     * @throws Exception
+     *             on internal error
+     */
+    @Test
+    public void testTraceSessionTree() throws Exception {
+
+        fProxy.setTestFile(fTestFile);
+        fProxy.setScenario(TraceControlTestFacility.SCEN_INIT_TEST);
+
+        ITraceControlComponent root = TraceControlTestFacility.getInstance().getControlView().getTraceControlRoot();
+
+        TargetNodeComponent node = new TargetNodeComponent("myNode", root, fProxy);
+
+        root.addChild(node);
+        fFacility.waitForJobs();
+
+        fFacility.executeCommand(node, "connect");
+        int i = 0;
+        while ((i < 10) && (node.getTargetNodeState() != TargetNodeState.CONNECTED)) {
+            i++;
+            fFacility.delay(TraceControlTestFacility.GUI_REFESH_DELAY);
+        }
+
+        // Verify that node is connected
+        assertEquals(TargetNodeState.CONNECTED, node.getTargetNodeState());
+
+        ILttngControlService controleService = node.getControlService();
+
+        // Get provider groups
+        ITraceControlComponent[] groups = node.getChildren();
+        assertNotNull(groups);
+        assertEquals(2, groups.length);
+
+        // Initialize dialog implementations for command execution
+        CreateSessionDialogStub sessionDialogStub = new CreateSessionDialogStub();
+        TraceControlDialogFactory.getInstance().setCreateSessionDialog(sessionDialogStub);
+        TraceControlDialogFactory.getInstance().setConfirmDialog(new DestroyConfirmDialogStub());
+
+        // ------------------------------------------------------------------------
+        // Create session (--U file://...) and destroy
+        // ------------------------------------------------------------------------
+        // Initialize session handling scenario
+        fProxy.setScenario(SCEN_SCENARIO_FILE_PROTO_TEST);
+
+        sessionDialogStub.setNetworkUrl("file:///tmp");
+        sessionDialogStub.setStreamedTrace(true);
+        TraceSessionComponent session = fFacility.createSession(groups[1]);
+
+        // Verify that session was created
+        assertNotNull(session);
+        assertEquals(getSessionName(), session.getName());
+        if (controleService.isVersionSupported("2.6.0")) {
+            assertEquals("/tmp", session.getSessionPath());
+        } else {
+            assertEquals("file:///tmp", session.getSessionPath());
+        }
+
+        assertTrue(!session.isStreamedTrace());
+        assertEquals(TraceSessionState.INACTIVE, session.getSessionState());
+        sessionDialogStub.setNetworkUrl(null);
+        sessionDialogStub.setStreamedTrace(false);
+
+        fFacility.destroySession(session);
+
+        // Verify that no more session components exist
+        assertEquals(0, groups[1].getChildren().length);
+
+        // ------------------------------------------------------------------------
+        // Create session (--U file://,,, and destroy
+        // ------------------------------------------------------------------------
+        // Initialize session handling scenario
+        fProxy.setScenario(SCEN_SCENARIO_CONTROL_DATA_TEST);
+
+        sessionDialogStub.setControlUrl("tcp://172.0.0.1");
+        sessionDialogStub.setDataUrl("tcp://172.0.0.1:5343");
+        sessionDialogStub.setStreamedTrace(true);
+
+        session = fFacility.createSession(groups[1]);
+
+        // Verify that session was created
+        assertNotNull(session);
+        assertEquals(getSessionName(), session.getName());
+        if (controleService.isVersionSupported("2.6.0")) {
+            assertEquals("tcp4://172.0.0.1:5342/ [data: 5343]", session.getSessionPath());
+        } else {
+            assertEquals("tcp://172.0.0.1:5342 [data: 5343]", session.getSessionPath());
+        }
+        assertTrue(session.isStreamedTrace());
+        assertEquals(TraceSessionState.INACTIVE, session.getSessionState());
+        sessionDialogStub.setControlUrl(null);
+        sessionDialogStub.setDataUrl(null);
+        sessionDialogStub.setStreamedTrace(false);
+
+        fFacility.destroySession(session);
+
+        // Verify that no more session components exist
+        assertEquals(0, groups[1].getChildren().length);
+
+        // ------------------------------------------------------------------------
+        // Create session (--U file://... and destroy
+        // ------------------------------------------------------------------------
+        // Initialize session handling scenario
+        fProxy.setScenario(SCEN_SCENARIO_NETWORK_TEST);
+
+        sessionDialogStub.setNetworkUrl("net://172.0.0.1:1234:2345");
+        sessionDialogStub.setStreamedTrace(true);
+
+        session = fFacility.createSession(groups[1]);
+
+        // Verify that session was created
+        assertNotNull(session);
+        assertEquals(getSessionName(), session.getName());
+        if (controleService.isVersionSupported("2.6.0")) {
+            assertEquals("tcp4://172.0.0.1:1234/mysession-20140820-153527 [data: 2345]", session.getSessionPath());
+        } else {
+            assertEquals("net://172.0.0.1:1234 [data: 2345]", session.getSessionPath());
+        }
+        assertTrue(session.isStreamedTrace());
+        assertEquals(TraceSessionState.INACTIVE, session.getSessionState());
+        sessionDialogStub.setNetworkUrl(null);
+
+        fFacility.destroySession(session);
+
+        // Verify that no more session components exist
+        assertEquals(0, groups[1].getChildren().length);
+
+        // ------------------------------------------------------------------------
+        // Create session (--U net6://[...] and destroy
+        // ------------------------------------------------------------------------
+        // Initialize session handling scenario
+        fProxy.setScenario(SCEN_SCENARIO_NETWORK2_TEST);
+
+        sessionDialogStub.setNetworkUrl("net6://[ffff::eeee:dddd:cccc:0]");
+        sessionDialogStub.setStreamedTrace(true);
+
+        session = fFacility.createSession(groups[1]);
+
+        // Verify that session was created
+        assertNotNull(session);
+        assertEquals(getSessionName(), session.getName());
+        if (controleService.isVersionSupported("2.6.0")) {
+            assertEquals("tcp6://[ffff::eeee:dddd:cccc:0]:5342/mysession-20140820-153801 [data: 5343]", session.getSessionPath());
+        } else {
+            assertEquals("net://[ffff::eeee:dddd:cccc:0]:5342/mysession-20130221-144451 [data: 5343]", session.getSessionPath());
+        }
+        assertTrue(session.isStreamedTrace());
+        assertEquals(TraceSessionState.INACTIVE, session.getSessionState());
+        sessionDialogStub.setNetworkUrl(null);
+
+        fFacility.destroySession(session);
+
+        // Verify that no more session components exist
+        assertEquals(0, groups[1].getChildren().length);
+
+        // -------------------------------------------------------------------------
+        // Disconnect node
+        // -------------------------------------------------------------------------
+        fFacility.executeCommand(node, "disconnect");
+        assertEquals(TargetNodeState.DISCONNECTED, node.getTargetNodeState());
+
+        // -------------------------------------------------------------------------
+        // Delete node
+        // -------------------------------------------------------------------------
+
+        fFacility.executeCommand(node, "delete");
+        assertEquals(0, fFacility.getControlView().getTraceControlRoot().getChildren().length);
+    }
+
+    private static String getSessionName() {
+        return SESSION;
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlKernelProviderTests.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlKernelProviderTests.java
new file mode 100644 (file)
index 0000000..7cb7a04
--- /dev/null
@@ -0,0 +1,267 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2015 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Alexandre Montplaisir - Port to JUnit4
+ *   Markus Schorn - Bug 448058: Use org.eclipse.remote in favor of RSE
+ **********************************************************************/
+
+package org.eclipse.tracecompass.lttng2.control.ui.tests.model.component;
+
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertNotNull;
+import static org.junit.Assert.assertTrue;
+
+import java.io.File;
+import java.net.URL;
+
+import org.eclipse.core.runtime.FileLocator;
+import org.eclipse.core.runtime.Path;
+import org.eclipse.jdt.annotation.NonNull;
+import org.eclipse.remote.core.IRemoteConnection;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TargetNodeState;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceChannelOutputType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEnablement;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEventType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
+import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.CreateSessionDialogStub;
+import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.DestroyConfirmDialogStub;
+import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.GetEventInfoDialogStub;
+import org.eclipse.tracecompass.internal.lttng2.control.stubs.service.TestRemoteSystemProxy;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.TraceControlDialogFactory;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.BaseEventComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.KernelProviderComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceEventComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceProviderGroup;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
+import org.eclipse.tracecompass.tmf.remote.core.proxy.TmfRemoteConnectionFactory;
+import org.junit.After;
+import org.junit.Before;
+import org.junit.Test;
+import org.osgi.framework.FrameworkUtil;
+
+/**
+ * The class <code>TraceControlKernelProviderTests</code> contains UST provider
+ * handling test cases.
+ */
+public class TraceControlKernelProviderTests {
+
+    // ------------------------------------------------------------------------
+    // Constants
+    // ------------------------------------------------------------------------
+
+    private static final String TEST_STREAM = "CreateTreeTest.cfg";
+    private static final String SCEN_SCENARIO1_TEST = "Scenario1";
+
+    // ------------------------------------------------------------------------
+    // Test data
+    // ------------------------------------------------------------------------
+
+    private TraceControlTestFacility fFacility;
+    private IRemoteConnection fHost = TmfRemoteConnectionFactory.getLocalConnection();
+    private @NonNull TestRemoteSystemProxy fProxy = new TestRemoteSystemProxy(fHost);
+    private String fTestFile;
+
+    // ------------------------------------------------------------------------
+    // Housekeeping
+    // ------------------------------------------------------------------------
+
+    /**
+     * Perform pre-test initialization.
+     *
+     * @throws Exception
+     *         if the initialization fails for some reason
+     */
+    @Before
+    public void setUp() throws Exception {
+        fFacility = TraceControlTestFacility.getInstance();
+        fFacility.init();
+        URL location = FileLocator.find(FrameworkUtil.getBundle(this.getClass()), new Path(TraceControlTestFacility.DIRECTORY + File.separator + TEST_STREAM), null);
+        File testfile = new File(FileLocator.toFileURL(location).toURI());
+        fTestFile = testfile.getAbsolutePath();
+    }
+
+    /**
+     * Perform post-test clean-up.
+     */
+    @After
+    public void tearDown() {
+        fFacility.waitForJobs();
+        fFacility.dispose();
+    }
+
+    /**
+     * Run the TraceControlComponent.
+     *
+     * @throws Exception
+     *             Would fail the test
+     */
+    @Test
+    public void testKernelProviderTree() throws Exception {
+
+        fProxy.setTestFile(fTestFile);
+        fProxy.setScenario(TraceControlTestFacility.SCEN_INIT_TEST);
+
+        ITraceControlComponent root = fFacility.getControlView().getTraceControlRoot();
+
+        TargetNodeComponent node = new TargetNodeComponent("myNode", root, fProxy);
+
+        root.addChild(node);
+
+        fFacility.waitForJobs();
+
+        fFacility.executeCommand(node, "connect");
+        int i = 0;
+        while ((i < 20) && (node.getTargetNodeState() != TargetNodeState.CONNECTED)) {
+            i++;
+            fFacility.delay(TraceControlTestFacility.GUI_REFESH_DELAY);
+        }
+
+        // Verify that node is connected
+        assertEquals(TargetNodeState.CONNECTED, node.getTargetNodeState());
+
+        // Get provider and session group
+        ITraceControlComponent[] groups = node.getChildren();
+        assertNotNull(groups);
+        assertEquals(2, groups.length);
+
+        // Check for kernel provider
+        TraceProviderGroup providerGroup = (TraceProviderGroup) groups[0];
+        assertTrue(providerGroup.hasKernelProvider());
+
+        // Get kernel provider
+        ITraceControlComponent[] providers = providerGroup.getChildren();
+        KernelProviderComponent kernelProvider = (KernelProviderComponent) providers[0];
+
+        // Get kernel provider events and select 2 events
+        ITraceControlComponent[] events = kernelProvider.getChildren();
+        assertNotNull(events);
+        assertEquals(3, events.length);
+
+        BaseEventComponent baseEventInfo0 = (BaseEventComponent) events[0];
+        BaseEventComponent baseEventInfo1  = (BaseEventComponent) events[1];
+
+        // Initialize dialog implementations for command execution
+        TraceControlDialogFactory.getInstance().setCreateSessionDialog(new CreateSessionDialogStub());
+        TraceControlDialogFactory.getInstance().setGetEventInfoDialog(new GetEventInfoDialogStub());
+        TraceControlDialogFactory.getInstance().setConfirmDialog(new DestroyConfirmDialogStub());
+
+        // Initialize session handling scenario
+        fProxy.setScenario(TraceControlTestFacility.SCEN_SCENARIO_SESSION_HANDLING);
+
+        // ------------------------------------------------------------------------
+        // Create session
+        // ------------------------------------------------------------------------
+        TraceSessionComponent session = fFacility.createSession(groups[1]);
+
+        // Verify that session was created
+        assertNotNull(session);
+        assertEquals("mysession", session.getName());
+        assertEquals("/home/user/lttng-traces/mysession-20120314-132824", session.getSessionPath());
+        assertEquals(TraceSessionState.INACTIVE, session.getSessionState());
+
+        // ------------------------------------------------------------------------
+        // Enable event on default channel on created session above
+        // ------------------------------------------------------------------------
+        // Initialize scenario
+        fProxy.setScenario(SCEN_SCENARIO1_TEST);
+
+        ITraceControlComponent[] components =  { baseEventInfo0, baseEventInfo1 };
+
+        fFacility.executeCommand(components, "assign.event");
+
+        // Verify that kernel domain was created
+        ITraceControlComponent[] domains = session.getChildren();
+        assertNotNull(domains);
+        assertEquals(1, domains.length);
+
+        assertEquals("Kernel", domains[0].getName());
+
+        // Verify that channel0 was created with default values
+        ITraceControlComponent[] channels =  domains[0].getChildren();
+        assertNotNull(channels);
+        assertEquals(1, channels.length);
+
+        assertTrue(channels[0] instanceof TraceChannelComponent);
+        TraceChannelComponent channel = (TraceChannelComponent) channels[0];
+        assertEquals("channel0", channel.getName());
+        assertEquals(4, channel.getNumberOfSubBuffers());
+        assertEquals("splice()", channel.getOutputType().getInName());
+        assertEquals(TraceChannelOutputType.SPLICE, channel.getOutputType());
+        assertEquals(false, channel.isOverwriteMode());
+        assertEquals(200, channel.getReadTimer());
+        assertEquals(TraceEnablement.ENABLED, channel.getState());
+        assertEquals(262144, channel.getSubBufferSize());
+        assertEquals(0, channel.getSwitchTimer());
+
+        // Verify that event components were created
+        ITraceControlComponent[] channel0Events = channel.getChildren();
+        assertNotNull(channel0Events);
+        assertEquals(2, channel0Events.length);
+        assertTrue(channel0Events[0] instanceof TraceEventComponent);
+        assertTrue(channel0Events[1] instanceof TraceEventComponent);
+
+        TraceEventComponent event = (TraceEventComponent) channel0Events[0];
+        assertEquals("sched_kthread_stop_ret", event.getName());
+        assertEquals(TraceLogLevel.TRACE_EMERG, event.getLogLevel());
+        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
+        assertEquals(TraceEnablement.ENABLED, event.getState());
+
+        TraceEventComponent event1 = (TraceEventComponent) channel0Events[1];
+        assertEquals("sched_kthread_stop", event1.getName());
+        assertEquals(TraceLogLevel.TRACE_EMERG, event1.getLogLevel());
+        assertEquals(TraceEventType.TRACEPOINT, event1.getEventType());
+        assertEquals(TraceEnablement.ENABLED, event1.getState());
+
+        // ------------------------------------------------------------------------
+        // Disable event components
+        // ------------------------------------------------------------------------
+        ITraceControlComponent[] selection = { event, event1 };
+        fFacility.executeCommand(selection, "disableEvent");
+
+        assertEquals(TraceEnablement.DISABLED, event.getState());
+        assertEquals(TraceEnablement.DISABLED, event1.getState());
+
+        // ------------------------------------------------------------------------
+        // Enable event component
+        // ------------------------------------------------------------------------
+        fFacility.executeCommand(event1, "enableEvent");
+
+        // Verify event state
+        assertEquals(TraceEnablement.ENABLED, event1.getState());
+
+        // ------------------------------------------------------------------------
+        // Destroy session
+        // ------------------------------------------------------------------------
+        // Initialize session handling scenario
+        fProxy.setScenario(TraceControlTestFacility.SCEN_SCENARIO_SESSION_HANDLING);
+
+        fFacility.destroySession(session);
+
+        // Verify that no more session components exist
+        assertEquals(0, groups[1].getChildren().length);
+
+        //-------------------------------------------------------------------------
+        // Disconnect node
+        //-------------------------------------------------------------------------
+        fFacility.executeCommand(node, "disconnect");
+        assertEquals(TargetNodeState.DISCONNECTED, node.getTargetNodeState());
+
+        //-------------------------------------------------------------------------
+        // Delete node
+        //-------------------------------------------------------------------------
+        fFacility.executeCommand(node, "delete");
+        assertEquals(0, fFacility.getControlView().getTraceControlRoot().getChildren().length);
+
+    }
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlKernelSessionTests.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlKernelSessionTests.java
new file mode 100644 (file)
index 0000000..71b8bb7
--- /dev/null
@@ -0,0 +1,819 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2015 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Alexandre Montplaisir - Port to JUnit4
+ *   Markus Schorn - Bug 448058: Use org.eclipse.remote in favor of RSE
+ **********************************************************************/
+
+package org.eclipse.tracecompass.lttng2.control.ui.tests.model.component;
+
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertNotNull;
+import static org.junit.Assert.assertNull;
+import static org.junit.Assert.assertTrue;
+import static org.junit.Assert.fail;
+
+import java.io.File;
+import java.net.URL;
+import java.util.ArrayList;
+import java.util.List;
+
+import org.eclipse.core.runtime.FileLocator;
+import org.eclipse.core.runtime.Path;
+import org.eclipse.jdt.annotation.NonNull;
+import org.eclipse.remote.core.IRemoteConnection;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TargetNodeState;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceChannelOutputType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEnablement;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEventType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.ChannelInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.AddContextDialogStub;
+import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.CreateSessionDialogStub;
+import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.DestroyConfirmDialogStub;
+import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.EnableChannelDialogStub;
+import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.EnableEventsDialogStub;
+import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.GetEventInfoDialogStub;
+import org.eclipse.tracecompass.internal.lttng2.control.stubs.service.TestRemoteSystemProxy;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.TraceControlDialogFactory;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceEventComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceProbeEventComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
+import org.eclipse.tracecompass.tmf.remote.core.proxy.TmfRemoteConnectionFactory;
+import org.junit.After;
+import org.junit.Before;
+import org.junit.Test;
+import org.osgi.framework.FrameworkUtil;
+
+/**
+ * The class <code>TraceControlKernelSessionTests</code> contains Kernel
+ * session/channel/event handling test cases.
+ */
+public class TraceControlKernelSessionTests {
+
+    // ------------------------------------------------------------------------
+    // Constants
+    // ------------------------------------------------------------------------
+
+    private static final String TEST_STREAM = "CreateTreeTest.cfg";
+    private static final String SCEN_SCENARIO3_TEST = "Scenario3";
+
+    // ------------------------------------------------------------------------
+    // Test data
+    // ------------------------------------------------------------------------
+
+    private TraceControlTestFacility fFacility;
+    private IRemoteConnection fHost = TmfRemoteConnectionFactory.getLocalConnection();
+    private @NonNull TestRemoteSystemProxy fProxy = new TestRemoteSystemProxy(fHost);
+    private String fTestFile;
+
+    // ------------------------------------------------------------------------
+    // Housekeeping
+    // ------------------------------------------------------------------------
+
+    /**
+     * Perform pre-test initialization.
+     *
+     * @throws Exception
+     *         if the initialization fails for some reason
+     */
+    @Before
+    public void setUp() throws Exception {
+        fFacility = TraceControlTestFacility.getInstance();
+        fFacility.init();
+        URL location = FileLocator.find(FrameworkUtil.getBundle(this.getClass()), new Path(TraceControlTestFacility.DIRECTORY + File.separator + TEST_STREAM), null);
+        File testfile = new File(FileLocator.toFileURL(location).toURI());
+        fTestFile = testfile.getAbsolutePath();
+    }
+
+    /**
+     * Perform post-test clean-up.
+     */
+    @After
+    public void tearDown() {
+        fFacility.waitForJobs();
+        fFacility.dispose();
+    }
+
+    /**
+     * Run the TraceControlComponent.
+     *
+     * @throws Exception
+     *             Would fail the test
+     */
+    @Test
+    public void testTraceSessionTree() throws Exception {
+
+        fProxy.setTestFile(fTestFile);
+        fProxy.setScenario(TraceControlTestFacility.SCEN_INIT_TEST);
+
+        ITraceControlComponent root = fFacility.getControlView().getTraceControlRoot();
+
+        TargetNodeComponent node = new TargetNodeComponent("myNode", root, fProxy);
+
+        root.addChild(node);
+        fFacility.waitForJobs();
+
+        fFacility.executeCommand(node, "connect");
+        int i = 0;
+        while ((i < 10) && (node.getTargetNodeState() != TargetNodeState.CONNECTED)) {
+            i++;
+            fFacility.delay(TraceControlTestFacility.GUI_REFESH_DELAY);
+        }
+
+        // Verify that node is connected
+        assertEquals(TargetNodeState.CONNECTED, node.getTargetNodeState());
+
+        // Get provider groups
+        ITraceControlComponent[] groups = node.getChildren();
+        assertNotNull(groups);
+        assertEquals(2, groups.length);
+
+        // Initialize dialog implementations for command execution
+        TraceControlDialogFactory.getInstance().setCreateSessionDialog(new CreateSessionDialogStub());
+        TraceControlDialogFactory.getInstance().setGetEventInfoDialog(new GetEventInfoDialogStub());
+        TraceControlDialogFactory.getInstance().setConfirmDialog(new DestroyConfirmDialogStub());
+
+        // Initialize session handling scenario
+        fProxy.setScenario(TraceControlTestFacility.SCEN_SCENARIO_SESSION_HANDLING);
+
+        // ------------------------------------------------------------------------
+        // Create session
+        // ------------------------------------------------------------------------
+        TraceSessionComponent session = fFacility.createSession(groups[1]);
+
+        // Verify that session was created
+        assertNotNull(session);
+        assertEquals("mysession", session.getName());
+        assertEquals("/home/user/lttng-traces/mysession-20120314-132824", session.getSessionPath());
+        assertEquals(TraceSessionState.INACTIVE, session.getSessionState());
+
+        // Initialize scenario
+        fProxy.setScenario(SCEN_SCENARIO3_TEST);
+
+        // ------------------------------------------------------------------------
+        // Enable channel on session
+        // ------------------------------------------------------------------------
+        EnableChannelDialogStub channelStub = new EnableChannelDialogStub();
+        channelStub.setIsKernel(true);
+        TraceControlDialogFactory.getInstance().setEnableChannelDialog(channelStub);
+
+        fFacility.executeCommand(session, "enableChannelOnSession");
+
+        // Verify that Kernel domain was created
+        ITraceControlComponent[] domains = session.getChildren();
+        assertNotNull(domains);
+        assertEquals(1, domains.length);
+
+        assertEquals("Kernel", domains[0].getName());
+
+        // Verify that channel was created with correct data
+        ITraceControlComponent[] channels =  domains[0].getChildren();
+        assertNotNull(channels);
+        assertEquals(1, channels.length);
+
+        assertTrue(channels[0] instanceof TraceChannelComponent);
+        TraceChannelComponent channel = (TraceChannelComponent) channels[0];
+        assertEquals("mychannel", channel.getName());
+        assertEquals(4, channel.getNumberOfSubBuffers());
+        assertEquals("splice()", channel.getOutputType().getInName());
+        assertEquals(TraceChannelOutputType.SPLICE, channel.getOutputType());
+        assertEquals(true, channel.isOverwriteMode());
+        assertEquals(200, channel.getReadTimer());
+        assertEquals(TraceEnablement.ENABLED, channel.getState());
+        assertEquals(16384, channel.getSubBufferSize());
+        assertEquals(100, channel.getSwitchTimer());
+
+        // ------------------------------------------------------------------------
+        // Create channel on domain
+        // ------------------------------------------------------------------------
+        ChannelInfo info = (ChannelInfo)channelStub.getChannelInfo();
+        info.setName("mychannel2");
+        info.setOverwriteMode(false);
+        info.setSubBufferSize(32768);
+        info.setNumberOfSubBuffers(2);
+        info.setSwitchTimer(100);
+        info.setReadTimer(200);
+        channelStub.setChannelInfo(info);
+
+        fFacility.executeCommand(domains[0], "enableChannelOnDomain");
+
+        // Get Kernel domain component instance
+        domains = session.getChildren();
+        assertNotNull(domains);
+        assertEquals(1, domains.length);
+
+        // Verify that channel was created with correct data
+        channels =  domains[0].getChildren();
+        assertNotNull(channels);
+        assertEquals(2, channels.length);
+
+        assertTrue(channels[1] instanceof TraceChannelComponent);
+        channel = (TraceChannelComponent) channels[1];
+        assertEquals("mychannel2", channel.getName());
+        assertEquals(2, channel.getNumberOfSubBuffers());
+        assertEquals("splice()", channel.getOutputType().getInName());
+        assertEquals(TraceChannelOutputType.SPLICE, channel.getOutputType());
+        assertEquals(false, channel.isOverwriteMode());
+        assertEquals(200, channel.getReadTimer());
+        assertEquals(TraceEnablement.ENABLED, channel.getState());
+        assertEquals(32768, channel.getSubBufferSize());
+        assertEquals(100, channel.getSwitchTimer());
+
+        EnableEventsDialogStub eventsDialogStub = new EnableEventsDialogStub();
+        eventsDialogStub.setIsTracePoints(true);
+        List<String> events = new ArrayList<>();
+        events.add("sched_kthread_stop");
+        events.add("sched_kthread_stop_ret");
+        eventsDialogStub.setNames(events);
+        eventsDialogStub.setIsKernel(true);
+        TraceControlDialogFactory.getInstance().setEnableEventsDialog(eventsDialogStub);
+
+        // ------------------------------------------------------------------------
+        // disable channels
+        // ------------------------------------------------------------------------
+        // Get Kernel domain component instance
+        domains = session.getChildren();
+        assertNotNull(domains);
+        assertEquals(1, domains.length);
+
+        // Verify that channel was created with correct data
+        channels =  domains[0].getChildren();
+        assertNotNull(channels);
+        assertEquals(2, channels.length);
+
+        fFacility.executeCommand(channels, "disableChannel");
+
+        assertEquals(TraceEnablement.DISABLED, ((TraceChannelComponent)channels[0]).getState());
+        assertEquals(TraceEnablement.DISABLED, ((TraceChannelComponent)channels[1]).getState());
+
+        // ------------------------------------------------------------------------
+        // enable channels
+        // ------------------------------------------------------------------------
+        // Get Kernel domain component instance
+        domains = session.getChildren();
+        assertNotNull(domains);
+        assertEquals(1, domains.length);
+
+        // Verify that channel was created with correct data
+        channels =  domains[0].getChildren();
+        assertNotNull(channels);
+        assertEquals(2, channels.length);
+
+        fFacility.executeCommand(channels, "enableChannel");
+
+        assertEquals(TraceEnablement.ENABLED, ((TraceChannelComponent)channels[0]).getState());
+        assertEquals(TraceEnablement.ENABLED, ((TraceChannelComponent)channels[1]).getState());
+
+        // ------------------------------------------------------------------------
+        // enable event (tracepoints) on session
+        // ------------------------------------------------------------------------
+        fFacility.executeCommand(session, "enableEventOnSession");
+
+        // Get Kernel domain component instance
+        domains = session.getChildren();
+        assertNotNull(domains);
+        assertEquals(1, domains.length);
+
+        // Verify that channel was created with correct data
+        channels =  domains[0].getChildren();
+        assertNotNull(channels);
+        assertEquals(3, channels.length);
+
+        assertTrue(channels[2] instanceof TraceChannelComponent);
+        channel = (TraceChannelComponent) channels[2];
+        assertEquals("channel0", channel.getName());
+        // No need to check parameters of default channel because that has been done in other tests
+
+        ITraceControlComponent[] channel0Events = channel.getChildren();
+        assertEquals(2, channel0Events.length);
+
+        assertTrue(channel0Events[0] instanceof TraceEventComponent);
+        assertTrue(channel0Events[1] instanceof TraceEventComponent);
+
+        TraceEventComponent event = (TraceEventComponent) channel0Events[0];
+        assertEquals("sched_kthread_stop_ret", event.getName());
+        assertEquals(TraceLogLevel.TRACE_EMERG, event.getLogLevel());
+        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
+        assertEquals(TraceEnablement.ENABLED, event.getState());
+
+        event = (TraceEventComponent) channel0Events[1];
+        assertEquals("sched_kthread_stop", event.getName());
+        assertEquals(TraceLogLevel.TRACE_EMERG, event.getLogLevel());
+        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
+        assertEquals(TraceEnablement.ENABLED, event.getState());
+
+        // ------------------------------------------------------------------------
+        // enable event (tracepoints) on domain
+        // ------------------------------------------------------------------------
+        events.clear();
+        events.add("sched_wakeup_new");
+        eventsDialogStub.setNames(events);
+
+        fFacility.executeCommand(domains[0], "enableEventOnDomain");
+
+        // Get Kernel domain component instance
+        domains = session.getChildren();
+        assertNotNull(domains);
+        assertEquals(1, domains.length);
+
+        // Verify that channel was created with correct data
+        channels =  domains[0].getChildren();
+        channel = (TraceChannelComponent) channels[2];
+        // No need to check parameters of default channel because that has been done in other tests
+
+        channel = (TraceChannelComponent) channels[2];
+
+        channel0Events = channel.getChildren();
+        assertEquals(3, channel0Events.length);
+
+        assertTrue(channel0Events[2] instanceof TraceEventComponent);
+
+        event = (TraceEventComponent) channel0Events[2];
+        assertEquals("sched_wakeup_new", event.getName());
+        assertEquals(TraceLogLevel.TRACE_EMERG, event.getLogLevel());
+        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
+        assertEquals(TraceEnablement.ENABLED, event.getState());
+
+        // ------------------------------------------------------------------------
+        // enable event (tracepoints) on channel
+        // ------------------------------------------------------------------------
+        events.clear();
+        eventsDialogStub.setNames(events);
+        eventsDialogStub.setIsAllTracePoints(true);
+
+        fFacility.executeCommand(channels[1], "enableEventOnChannel");
+
+        // Get Kernel domain component instance
+        domains = session.getChildren();
+        assertNotNull(domains);
+        assertEquals(1, domains.length);
+
+        // Verify that channel was created with correct data
+        channels =  domains[0].getChildren();
+        // No need to check parameters of default channel because that has been done in other tests
+        channel = (TraceChannelComponent) channels[1];
+
+        channel0Events = channel.getChildren();
+        assertEquals(3, channel0Events.length);
+
+        assertTrue(channel0Events[0] instanceof TraceEventComponent);
+        assertTrue(channel0Events[1] instanceof TraceEventComponent);
+        assertTrue(channel0Events[2] instanceof TraceEventComponent);
+
+        event = (TraceEventComponent) channel0Events[0];
+        assertEquals("sched_kthread_stop_ret", event.getName());
+        assertEquals(TraceLogLevel.TRACE_EMERG, event.getLogLevel());
+        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
+        assertEquals(TraceEnablement.ENABLED, event.getState());
+
+        event = (TraceEventComponent) channel0Events[1];
+        assertEquals("sched_kthread_stop", event.getName());
+        assertEquals(TraceLogLevel.TRACE_EMERG, event.getLogLevel());
+        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
+        assertEquals(TraceEnablement.ENABLED, event.getState());
+
+        event = (TraceEventComponent) channel0Events[2];
+        assertEquals("sched_wakeup_new", event.getName());
+        assertEquals(TraceLogLevel.TRACE_EMERG, event.getLogLevel());
+        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
+        assertEquals(TraceEnablement.ENABLED, event.getState());
+
+        // ------------------------------------------------------------------------
+        // enable event (syscall) on channel
+        // ------------------------------------------------------------------------
+        events.clear();
+        eventsDialogStub.setIsTracePoints(false);
+        eventsDialogStub.setIsAllTracePoints(false);
+        eventsDialogStub.setIsSysCalls(true);
+
+        fFacility.executeCommand(channels[0], "enableEventOnChannel");
+
+        // Get Kernel domain component instance
+        domains = session.getChildren();
+        assertNotNull(domains);
+        assertEquals(1, domains.length);
+
+        // Verify that channel was created with correct data
+        channels =  domains[0].getChildren();
+        channel = (TraceChannelComponent) channels[0];
+        // No need to check parameters of default channel because that has been done in other tests
+
+        channel = (TraceChannelComponent) channels[0];
+
+        channel0Events = channel.getChildren();
+        assertEquals(1, channel0Events.length);
+
+        assertTrue(channel0Events[0] instanceof TraceEventComponent);
+
+        event = (TraceEventComponent) channel0Events[0];
+        assertEquals("syscalls", event.getName());
+        assertEquals(TraceLogLevel.LEVEL_UNKNOWN, event.getLogLevel());
+        assertEquals(TraceEventType.SYSCALL, event.getEventType());
+        assertEquals(TraceEnablement.ENABLED, event.getState());
+
+        // ------------------------------------------------------------------------
+        // enable event (syscall) on domain
+        // ------------------------------------------------------------------------
+        fFacility.executeCommand(domains[0], "enableEventOnDomain");
+
+        // Get Kernel domain component instance
+        domains = session.getChildren();
+        assertNotNull(domains);
+        assertEquals(1, domains.length);
+
+        // Verify that channel was created with correct data
+        channels =  domains[0].getChildren();
+        channel = (TraceChannelComponent) channels[0];
+        // No need to check parameters of default channel because that has been done in other tests
+
+        channel = (TraceChannelComponent) channels[2];
+
+        channel0Events = channel.getChildren();
+        assertEquals(4, channel0Events.length);
+
+        assertTrue(channel0Events[0] instanceof TraceEventComponent);
+
+        event = (TraceEventComponent) channel0Events[0];
+        assertEquals("syscalls", event.getName());
+        assertEquals(TraceLogLevel.LEVEL_UNKNOWN, event.getLogLevel());
+        assertEquals(TraceEventType.SYSCALL, event.getEventType());
+        assertEquals(TraceEnablement.ENABLED, event.getState());
+
+        // ------------------------------------------------------------------------
+        // enable event (syscall) on session
+        // ------------------------------------------------------------------------
+        fFacility.executeCommand(session, "enableEventOnSession");
+
+        // Get Kernel domain component instance
+        domains = session.getChildren();
+        assertNotNull(domains);
+        assertEquals(1, domains.length);
+
+        // Verify that channel was created with correct data
+        channels =  domains[0].getChildren();
+        channel = (TraceChannelComponent) channels[0];
+        // No need to check parameters of default channel because that has been done in other tests
+
+        channel = (TraceChannelComponent) channels[2];
+
+        channel0Events = channel.getChildren();
+        assertEquals(4, channel0Events.length);
+
+        assertTrue(channel0Events[0] instanceof TraceEventComponent);
+
+        event = (TraceEventComponent) channel0Events[0];
+        assertEquals("syscalls", event.getName());
+        assertEquals(TraceLogLevel.LEVEL_UNKNOWN, event.getLogLevel());
+        assertEquals(TraceEventType.SYSCALL, event.getEventType());
+        assertEquals(TraceEnablement.ENABLED, event.getState());
+
+
+        // ------------------------------------------------------------------------
+        // enable event (dynamic probe) on domain
+        // ------------------------------------------------------------------------
+        events.clear();
+        eventsDialogStub.setIsSysCalls(false);
+        eventsDialogStub.setIsDynamicProbe(true);
+        eventsDialogStub.setDynamicProbe("0xc0101280");
+        eventsDialogStub.setProbeEventName("myevent1");
+
+        fFacility.executeCommand(domains[0], "enableEventOnDomain");
+
+        // Get Kernel domain component instance
+        domains = session.getChildren();
+        assertNotNull(domains);
+        assertEquals(1, domains.length);
+
+        // Verify that channel was created with correct data
+        channels =  domains[0].getChildren();
+        channel = (TraceChannelComponent) channels[2];
+        // No need to check parameters of default channel because that has been done in other tests
+
+        channel0Events = channel.getChildren();
+        assertEquals(5, channel0Events.length);
+
+        assertTrue(channel0Events[0] instanceof TraceProbeEventComponent);
+
+        TraceProbeEventComponent probeEvent = (TraceProbeEventComponent) channel0Events[0];
+        assertEquals("myevent1", probeEvent.getName());
+        assertEquals(TraceLogLevel.LEVEL_UNKNOWN, probeEvent.getLogLevel());
+        assertEquals(TraceEventType.PROBE, probeEvent.getEventType());
+        assertEquals(TraceEnablement.ENABLED, probeEvent.getState());
+        assertNull(probeEvent.getOffset());
+        assertEquals("0xc0101280", probeEvent.getAddress());
+        assertNull(probeEvent.getSymbol());
+
+        // ------------------------------------------------------------------------
+        // enable event (dynamic probe) on channel
+        // ------------------------------------------------------------------------
+        eventsDialogStub.setIsDynamicProbe(true);
+        eventsDialogStub.setDynamicProbe("init_post");
+        eventsDialogStub.setProbeEventName("myevent2");
+
+        fFacility.executeCommand(channels[2], "enableEventOnChannel");
+
+        // Get Kernel domain component instance
+        domains = session.getChildren();
+        assertNotNull(domains);
+        assertEquals(1, domains.length);
+
+        // Verify that channel was created with correct data
+        channels =  domains[0].getChildren();
+        channel = (TraceChannelComponent) channels[2];
+        // No need to check parameters of default channel because that has been done in other tests
+
+        channel0Events = channel.getChildren();
+        assertEquals(6, channel0Events.length);
+
+        assertTrue(channel0Events[0] instanceof TraceProbeEventComponent);
+
+        probeEvent = (TraceProbeEventComponent) channel0Events[0];
+        assertEquals("myevent2", probeEvent.getName());
+        assertEquals(TraceLogLevel.LEVEL_UNKNOWN, probeEvent.getLogLevel());
+        assertEquals(TraceEventType.PROBE, probeEvent.getEventType());
+        assertEquals(TraceEnablement.ENABLED, probeEvent.getState());
+        assertEquals("0x0", probeEvent.getOffset());
+        assertNull(null, probeEvent.getAddress());
+        assertEquals("init_post", probeEvent.getSymbol());
+
+        // ------------------------------------------------------------------------
+        // enable event (dynamic probe) on session
+        // ------------------------------------------------------------------------
+        eventsDialogStub.setIsDynamicProbe(true);
+        eventsDialogStub.setDynamicProbe("init_post:0x1000");
+        eventsDialogStub.setProbeEventName("myevent3");
+
+        fFacility.executeCommand(session, "enableEventOnSession");
+
+        // Get Kernel domain component instance
+        domains = session.getChildren();
+        assertNotNull(domains);
+        assertEquals(1, domains.length);
+
+        // Verify that channel was created with correct data
+        channels =  domains[0].getChildren();
+        channel = (TraceChannelComponent) channels[2];
+        // No need to check parameters of default channel because that has been done in other tests
+
+        channel0Events = channel.getChildren();
+        assertEquals(7, channel0Events.length);
+
+        assertTrue(channel0Events[0] instanceof TraceProbeEventComponent);
+
+        probeEvent = (TraceProbeEventComponent) channel0Events[0];
+        assertEquals("myevent3", probeEvent.getName());
+        assertEquals(TraceLogLevel.LEVEL_UNKNOWN, probeEvent.getLogLevel());
+        assertEquals(TraceEventType.PROBE, probeEvent.getEventType());
+        assertEquals(TraceEnablement.ENABLED, probeEvent.getState());
+        assertEquals("0x1000", probeEvent.getOffset());
+        assertNull(null, probeEvent.getAddress());
+        assertEquals("init_post", probeEvent.getSymbol());
+
+        // ------------------------------------------------------------------------
+        // enable event (dynamic function probe) on session
+        // ------------------------------------------------------------------------
+        eventsDialogStub.setIsDynamicProbe(false);
+        eventsDialogStub.setDynamicProbe(null);
+        eventsDialogStub.setProbeEventName(null);
+        eventsDialogStub.setIsFunctionProbe(true);
+        eventsDialogStub.setFunctionEventName("myevent4");
+        eventsDialogStub.setFunctionProbe("create_dev");
+
+        fFacility.executeCommand(session, "enableEventOnSession");
+
+        // Get Kernel domain component instance
+        domains = session.getChildren();
+        assertNotNull(domains);
+        assertEquals(1, domains.length);
+
+        // Verify that channel was created with correct data
+        channels =  domains[0].getChildren();
+        channel = (TraceChannelComponent) channels[2];
+        // No need to check parameters of default channel because that has been done in other tests
+
+        channel0Events = channel.getChildren();
+        assertEquals(8, channel0Events.length);
+
+        assertTrue(channel0Events[0] instanceof TraceProbeEventComponent);
+
+        probeEvent = (TraceProbeEventComponent) channel0Events[0];
+        assertEquals("myevent4", probeEvent.getName());
+        assertEquals(TraceLogLevel.LEVEL_UNKNOWN, probeEvent.getLogLevel());
+        // Changed for Bug fix 419454 to function event which was introduced by LTTng 2.2
+        assertEquals(TraceEventType.FUNCTION, probeEvent.getEventType());
+        assertEquals(TraceEnablement.ENABLED, probeEvent.getState());
+        assertEquals("0x0", probeEvent.getOffset());
+        assertNull(null, probeEvent.getAddress());
+        assertEquals("create_dev", probeEvent.getSymbol());
+
+        // ------------------------------------------------------------------------
+        // enable event (dynamic function probe) on domain
+        // ------------------------------------------------------------------------
+        eventsDialogStub.setIsFunctionProbe(true);
+        eventsDialogStub.setFunctionEventName("myevent5");
+        eventsDialogStub.setFunctionProbe("create_dev:0x2000");
+
+        fFacility.executeCommand(domains[0], "enableEventOnDomain");
+
+        // Get Kernel domain component instance
+        domains = session.getChildren();
+        assertNotNull(domains);
+        assertEquals(1, domains.length);
+
+        // Verify that channel was created with correct data
+        channels =  domains[0].getChildren();
+        channel = (TraceChannelComponent) channels[2];
+        // No need to check parameters of default channel because that has been done in other tests
+
+        channel0Events = channel.getChildren();
+        assertEquals(9, channel0Events.length);
+
+        assertTrue(channel0Events[0] instanceof TraceProbeEventComponent);
+
+        probeEvent = (TraceProbeEventComponent) channel0Events[0];
+        assertEquals("myevent5", probeEvent.getName());
+        assertEquals(TraceLogLevel.LEVEL_UNKNOWN, probeEvent.getLogLevel());
+        assertEquals(TraceEventType.PROBE, probeEvent.getEventType());
+        assertEquals(TraceEnablement.ENABLED, probeEvent.getState());
+        assertEquals("0x2000", probeEvent.getOffset());
+        assertNull(null, probeEvent.getAddress());
+        assertEquals("create_dev", probeEvent.getSymbol());
+
+        // ------------------------------------------------------------------------
+        // enable event (dynamic function probe) on channel
+        // ------------------------------------------------------------------------
+        eventsDialogStub.setIsFunctionProbe(true);
+        eventsDialogStub.setFunctionEventName("myevent");
+        eventsDialogStub.setFunctionProbe("create_dev:0x2000");
+
+        fFacility.executeCommand(channels[0], "enableEventOnChannel");
+
+        // Get Kernel domain component instance
+        domains = session.getChildren();
+        assertNotNull(domains);
+        assertEquals(1, domains.length);
+
+        // Verify that channel was created with correct data
+        channels =  domains[0].getChildren();
+        channel = (TraceChannelComponent) channels[0];
+        // No need to check parameters of default channel because that has been done in other tests
+
+        channel0Events = channel.getChildren();
+        assertEquals(2, channel0Events.length);
+
+        assertTrue(channel0Events[0] instanceof TraceProbeEventComponent);
+
+        probeEvent = (TraceProbeEventComponent) channel0Events[0];
+        assertEquals("myevent", probeEvent.getName());
+        assertEquals(TraceLogLevel.LEVEL_UNKNOWN, probeEvent.getLogLevel());
+        assertEquals(TraceEventType.PROBE, probeEvent.getEventType());
+        assertEquals(TraceEnablement.ENABLED, probeEvent.getState());
+        assertEquals("0x2000", probeEvent.getOffset());
+        assertNull(null, probeEvent.getAddress());
+        assertEquals("create_dev", probeEvent.getSymbol());
+
+        // ------------------------------------------------------------------------
+        // Add Context on domain
+        // ------------------------------------------------------------------------
+        // Get Kernel domain component instance
+        domains = session.getChildren();
+        assertNotNull(domains);
+        assertEquals(1, domains.length);
+
+        AddContextDialogStub addContextStub = new AddContextDialogStub();
+        List<String> contexts = new ArrayList<>();
+        contexts.add("prio");
+        contexts.add("perf:branch-misses");
+        contexts.add("perf:cache-misses");
+        addContextStub.setContexts(contexts);
+        TraceControlDialogFactory.getInstance().setAddContextDialog(addContextStub);
+
+        fFacility.executeCommand(domains[0], "addContextOnDomain");
+        // Currently there is nothing to verify because the list commands don't show any context information
+        // However, the execution of the command make sure that the correct service command line is build and executed.
+
+        // ------------------------------------------------------------------------
+        // Add Context on channel
+        // ------------------------------------------------------------------------
+
+        // Get Kernel domain component instance
+        domains = session.getChildren();
+        assertNotNull(domains);
+        assertEquals(1, domains.length);
+
+        //Verify that channel was created with correct data
+        channels =  domains[0].getChildren();
+        channel = (TraceChannelComponent) channels[0];
+
+        try {
+            // The setContext() verifies that the contexts set are part of the available contexts
+            // The available contexts are set by the command handler addContextOnDomain above.
+            // So we indirectly test here that the parsing and setting of available contexts were
+            // done correctly above.
+            addContextStub.setContexts(contexts);
+        } catch (IllegalArgumentException e) {
+            fail("Exception caught - unknown context");
+        }
+
+        fFacility.executeCommand(channel, "addContextOnChannel");
+        // Currently there is nothing to verify because the list commands don't show any context information
+        // However, the execution of the command make sure that the correct service command line is build and executed.
+
+        // ------------------------------------------------------------------------
+        // Add Context on event
+        // ------------------------------------------------------------------------
+        // Get Kernel domain component instance
+        domains = session.getChildren();
+        assertNotNull(domains);
+        assertEquals(1, domains.length);
+
+        //Verify that channel was created with correct data
+        channels =  domains[0].getChildren();
+        channel = (TraceChannelComponent) channels[2];
+
+        channel0Events = channel.getChildren();
+
+        event = (TraceEventComponent) channel0Events[6];
+
+        fFacility.executeCommand(event, "addContextOnEvent");
+        // Currently there is nothing to verify because the list commands don't show any context information
+        // However, the execution of the command make sure that the correct service command line is build and executed.
+
+        // ------------------------------------------------------------------------
+        // Calibrate
+        // ------------------------------------------------------------------------
+        // Get Kernel domain component instance
+        domains = session.getChildren();
+        assertNotNull(domains);
+        assertEquals(1, domains.length);
+
+        fFacility.executeCommand(domains[0], "calibrate");
+        // There is nothing to verify here.
+        // However, the execution of the command make sure that the correct service command line is build and executed.
+
+        // ------------------------------------------------------------------------
+        // refresh
+        // ------------------------------------------------------------------------
+        fFacility.executeCommand(node, "refresh");
+        groups = node.getChildren();
+        assertNotNull(groups);
+        assertEquals(2, groups.length);
+        assertEquals(3, groups[0].getChildren().length); // provider
+        assertEquals(1, groups[1].getChildren().length); // sessions
+        assertEquals(1, groups[1].getChildren()[0].getChildren().length); // domains
+        assertEquals(3, groups[1].getChildren()[0].getChildren()[0].getChildren().length); // channels
+        assertEquals(2, groups[1].getChildren()[0].getChildren()[0].getChildren()[0].getChildren().length); // events (of channel[0])
+
+        // Initialize session handling scenario
+        fProxy.setScenario(TraceControlTestFacility.SCEN_SCENARIO_SESSION_HANDLING);
+
+        session = (TraceSessionComponent)groups[1].getChildren()[0];
+
+        // ------------------------------------------------------------------------
+        // start session
+        // ------------------------------------------------------------------------
+        fFacility.startSession(session);
+        assertEquals(TraceSessionState.ACTIVE, session.getSessionState());
+
+        // ------------------------------------------------------------------------
+        // stop session
+        // ------------------------------------------------------------------------
+        fFacility.stopSession(session);
+        assertEquals(TraceSessionState.INACTIVE, session.getSessionState());
+
+        // ------------------------------------------------------------------------
+        // Destroy session
+        // ------------------------------------------------------------------------
+
+        fFacility.destroySession(session);
+
+        // Verify that no more session components exist
+        assertEquals(0, groups[1].getChildren().length);
+
+        //-------------------------------------------------------------------------
+        // Disconnect node
+        //-------------------------------------------------------------------------
+        fFacility.executeCommand(node, "disconnect");
+        assertEquals(TargetNodeState.DISCONNECTED, node.getTargetNodeState());
+
+        //-------------------------------------------------------------------------
+        // Delete node
+        //-------------------------------------------------------------------------
+
+        fFacility.executeCommand(node, "delete");
+        assertEquals(0,fFacility.getControlView().getTraceControlRoot().getChildren().length);
+    }
+
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlPropertiesTest.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlPropertiesTest.java
new file mode 100644 (file)
index 0000000..a4b0108
--- /dev/null
@@ -0,0 +1,363 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2015 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Alexandre Montplaisir - Port to JUnit4
+ *   Markus Schorn - Bug 448058: Use org.eclipse.remote in favor of RSE
+ **********************************************************************/
+
+package org.eclipse.tracecompass.lttng2.control.ui.tests.model.component;
+
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertFalse;
+import static org.junit.Assert.assertNotNull;
+import static org.junit.Assert.assertNull;
+import static org.junit.Assert.assertTrue;
+
+import java.io.File;
+import java.net.URL;
+
+import org.eclipse.core.runtime.FileLocator;
+import org.eclipse.core.runtime.Path;
+import org.eclipse.remote.core.IRemoteConnection;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IChannelInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TargetNodeState;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEnablement;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEventType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.BufferType;
+import org.eclipse.tracecompass.internal.lttng2.control.stubs.service.TestRemoteSystemProxy;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.BaseEventComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.KernelProviderComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceEventComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceProbeEventComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.UstProviderComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.property.BaseEventPropertySource;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.property.KernelProviderPropertySource;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.property.TargetNodePropertySource;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.property.TraceChannelPropertySource;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.property.TraceDomainPropertySource;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.property.TraceEventPropertySource;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.property.TraceProbeEventPropertySource;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.property.TraceSessionPropertySource;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.property.UstProviderPropertySource;
+import org.eclipse.tracecompass.tmf.remote.core.proxy.TmfRemoteConnectionFactory;
+import org.eclipse.ui.views.properties.IPropertySource;
+import org.junit.After;
+import org.junit.Test;
+import org.osgi.framework.FrameworkUtil;
+
+/**
+ * The class <code>TraceControlPropertiesTest</code> contains tests for the all
+ * property class</code>.
+ */
+public class TraceControlPropertiesTest {
+
+    // ------------------------------------------------------------------------
+    // Constants
+    // ------------------------------------------------------------------------
+
+    private static final String DIRECTORY   = "testfiles";
+    private static final String TEST_STREAM = "ListInfoTest.cfg";
+    private static final String SCEN_LIST_INFO_TEST = "ListInfoTest";
+
+    // ------------------------------------------------------------------------
+    // Housekeeping
+    // ------------------------------------------------------------------------
+
+    /**
+     * Perform post-test clean-up.
+     */
+    @After
+    public void tearDown() {
+        TraceControlTestFacility.getInstance().waitForJobs();
+    }
+
+    /**
+     * Run the TraceControlComponent.
+     *
+     * @throws Exception
+     *             This will fail the test
+     */
+    @Test
+    public void testComponentProperties() throws Exception {
+        IRemoteConnection host = TmfRemoteConnectionFactory.getLocalConnection();
+        TestRemoteSystemProxy proxy = new TestRemoteSystemProxy(host);
+
+        URL location = FileLocator.find(FrameworkUtil.getBundle(this.getClass()), new Path(DIRECTORY + File.separator + TEST_STREAM), null);
+        File testfile = new File(FileLocator.toFileURL(location).toURI());
+        proxy.setTestFile(testfile.getAbsolutePath());
+        proxy.setScenario(SCEN_LIST_INFO_TEST);
+
+        ITraceControlComponent root = TraceControlTestFacility.getInstance().getControlView().getTraceControlRoot();
+
+        TargetNodeComponent node = new TargetNodeComponent("myNode", root, proxy);
+
+        root.addChild(node);
+        node.connect();
+
+        TraceControlTestFacility.getInstance().waitForConnect(node);
+        TraceControlTestFacility.getInstance().waitForJobs();
+
+        // ------------------------------------------------------------------------
+        // Verify Node Properties (adapter)
+        // ------------------------------------------------------------------------
+        Object adapter = node.getAdapter(IPropertySource.class);
+        assertNotNull(adapter);
+        assertTrue(adapter instanceof TargetNodePropertySource);
+
+        TargetNodePropertySource source = (TargetNodePropertySource)adapter;
+
+        assertNull(source.getEditableValue());
+        assertFalse(source.isPropertySet(TargetNodePropertySource.TARGET_NODE_NAME_PROPERTY_ID));
+        assertNotNull(source.getPropertyDescriptors());
+
+        assertEquals("myNode", source.getPropertyValue(TargetNodePropertySource.TARGET_NODE_NAME_PROPERTY_ID));
+        // Don't check the address property because the string can vary on the machine the test is running
+//        assertEquals("localhost",  source.getPropertyValue(TargetNodePropertySource.TARGET_NODE_ADDRESS_PROPERTY_ID));
+        assertEquals(TargetNodeState.CONNECTED.name(), source.getPropertyValue(TargetNodePropertySource.TARGET_NODE_STATE_PROPERTY_ID));
+        assertEquals("2.5.0", source.getPropertyValue(TargetNodePropertySource.TARGET_NODE_VERSION_PROPERTY_ID));
+        assertNull(source.getPropertyValue("test"));
+
+        adapter = node.getAdapter(IChannelInfo.class);
+        assertNull(adapter);
+
+        ITraceControlComponent[] groups = node.getChildren();
+        assertNotNull(groups);
+        assertEquals(2, groups.length);
+
+        ITraceControlComponent[] providers = groups[0].getChildren();
+
+        assertNotNull(providers);
+        assertEquals(3, providers.length);
+
+        // ------------------------------------------------------------------------
+        // Verify Kernel Provider Properties (adapter)
+        // ------------------------------------------------------------------------
+        KernelProviderComponent kernelProvider = (KernelProviderComponent) providers[0];
+
+        adapter = kernelProvider.getAdapter(IPropertySource.class);
+        assertNotNull(adapter);
+        assertTrue(adapter instanceof KernelProviderPropertySource);
+
+        KernelProviderPropertySource kernelSource = (KernelProviderPropertySource)adapter;
+        assertNotNull(kernelSource.getPropertyDescriptors());
+
+        assertEquals("Kernel", kernelSource.getPropertyValue(KernelProviderPropertySource.KERNEL_PROVIDER_NAME_PROPERTY_ID));
+
+        // ------------------------------------------------------------------------
+        // Verify UST Provider Properties (adapter)
+        // ------------------------------------------------------------------------
+        UstProviderComponent ustProvider = (UstProviderComponent) providers[1];
+
+        adapter = ustProvider.getAdapter(IPropertySource.class);
+        assertNotNull(adapter);
+        assertTrue(adapter instanceof UstProviderPropertySource);
+
+        UstProviderPropertySource ustSource = (UstProviderPropertySource)adapter;
+        assertNotNull(ustSource.getPropertyDescriptors());
+
+        assertEquals("/home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello [PID=9379]", ustSource.getPropertyValue(UstProviderPropertySource.UST_PROVIDER_NAME_PROPERTY_ID));
+        assertEquals(String.valueOf(9379), ustSource.getPropertyValue(UstProviderPropertySource.UST_PROVIDER_PID_PROPERTY_ID));
+
+        // ------------------------------------------------------------------------
+        // Verify Base Event Properties (adapter)
+        // ------------------------------------------------------------------------
+        ITraceControlComponent[] events = ustProvider.getChildren();
+        assertNotNull(events);
+        assertEquals(2, events.length);
+
+        BaseEventComponent baseEventInfo = (BaseEventComponent) events[0];
+        assertNotNull(baseEventInfo);
+
+        adapter = baseEventInfo.getAdapter(IPropertySource.class);
+        assertNotNull(adapter);
+        assertTrue(adapter instanceof BaseEventPropertySource);
+
+        BaseEventPropertySource baseSource = (BaseEventPropertySource)adapter;
+        assertNotNull(baseSource.getPropertyDescriptors());
+
+        assertEquals("ust_tests_hello:tptest_sighandler", baseSource.getPropertyValue(BaseEventPropertySource.BASE_EVENT_NAME_PROPERTY_ID));
+        assertEquals(TraceEventType.TRACEPOINT.name(), baseSource.getPropertyValue(BaseEventPropertySource.BASE_EVENT_TYPE_PROPERTY_ID));
+        assertEquals(TraceLogLevel.TRACE_DEBUG_MODULE.name(), baseSource.getPropertyValue(BaseEventPropertySource.BASE_EVENT_LOGLEVEL_PROPERTY_ID));
+
+        baseEventInfo = (BaseEventComponent) events[1];
+        assertNotNull(baseEventInfo);
+
+        adapter = baseEventInfo.getAdapter(IPropertySource.class);
+        assertNotNull(adapter);
+        assertTrue(adapter instanceof BaseEventPropertySource);
+        baseSource = (BaseEventPropertySource)adapter;
+        assertNotNull(baseSource.getPropertyDescriptors());
+        assertEquals("doublefield=float;floatfield=float;stringfield=string", baseSource.getPropertyValue(BaseEventPropertySource.BASE_EVENT_FIELDS_PROPERTY_ID));
+
+        // ------------------------------------------------------------------------
+        // Verify Session Properties (adapter)
+        // ------------------------------------------------------------------------
+        ITraceControlComponent[] sessions = groups[1].getChildren();
+        assertNotNull(sessions);
+        assertEquals(2, sessions.length);
+
+        TraceSessionComponent session = (TraceSessionComponent)sessions[1];
+
+        adapter = session.getAdapter(IPropertySource.class);
+        assertNotNull(adapter);
+        assertTrue(adapter instanceof TraceSessionPropertySource);
+
+        TraceSessionPropertySource sessionSource = (TraceSessionPropertySource)adapter;
+        assertNotNull(sessionSource.getPropertyDescriptors());
+
+        assertEquals("mysession", sessionSource.getPropertyValue(TraceSessionPropertySource.TRACE_SESSION_NAME_PROPERTY_ID));
+        assertEquals("/home/user/lttng-traces/mysession-20120129-084256", sessionSource.getPropertyValue(TraceSessionPropertySource.TRACE_SESSION_PATH_PROPERTY_ID));
+        assertEquals(TraceSessionState.ACTIVE.name(), sessionSource.getPropertyValue(TraceSessionPropertySource.TRACE_SESSION_STATE_PROPERTY_ID));
+
+        // ------------------------------------------------------------------------
+        // Verify Domain Provider Properties (adapter)
+        // ------------------------------------------------------------------------
+        ITraceControlComponent[] domains = session.getChildren();
+        assertNotNull(domains);
+        assertEquals(2, domains.length);
+
+        TraceDomainComponent domain = (TraceDomainComponent) domains[0];
+        adapter = domain.getAdapter(IPropertySource.class);
+        assertNotNull(adapter);
+        assertTrue(adapter instanceof TraceDomainPropertySource);
+
+        TraceDomainPropertySource domainSource = (TraceDomainPropertySource)adapter;
+        assertNotNull(domainSource.getPropertyDescriptors());
+
+        assertEquals("Kernel", domainSource.getPropertyValue(TraceDomainPropertySource.TRACE_DOMAIN_NAME_PROPERTY_ID));
+        assertEquals(BufferType.BUFFER_SHARED.getInName(), domainSource.getPropertyValue(TraceDomainPropertySource.BUFFER_TYPE_PROPERTY_ID));
+
+        ITraceControlComponent[] channels =  domains[0].getChildren();
+        assertNotNull(channels);
+        assertEquals(2, channels.length);
+
+        // ------------------------------------------------------------------------
+        // Verify Channel Properties (adapter)
+        // ------------------------------------------------------------------------
+        assertTrue(channels[0] instanceof TraceChannelComponent);
+        TraceChannelComponent channel = (TraceChannelComponent) channels[0];
+
+        adapter = channel.getAdapter(IPropertySource.class);
+        assertNotNull(adapter);
+        assertTrue(adapter instanceof TraceChannelPropertySource);
+
+        TraceChannelPropertySource channelSource = (TraceChannelPropertySource)adapter;
+        assertNotNull(channelSource.getPropertyDescriptors());
+
+        assertEquals("channel0", channelSource.getPropertyValue(TraceChannelPropertySource.TRACE_CHANNEL_NAME_PROPERTY_ID));
+        assertEquals(String.valueOf(4), channelSource.getPropertyValue(TraceChannelPropertySource.TRACE_CHANNEL_NO_SUBBUFFERS_PROPERTY_ID));
+        assertEquals(TraceEnablement.ENABLED.name(), channelSource.getPropertyValue(TraceChannelPropertySource.TRACE_CHANNEL_STATE_PROPERTY_ID));
+        assertEquals(String.valueOf(false), channelSource.getPropertyValue(TraceChannelPropertySource.TRACE_CHANNEL_OVERWRITE_MODE_PROPERTY_ID));
+        assertEquals("splice()", channelSource.getPropertyValue(TraceChannelPropertySource.TRACE_CHANNEL_OUTPUT_TYPE_PROPERTY_ID));
+        assertEquals(String.valueOf(200), channelSource.getPropertyValue(TraceChannelPropertySource.TRACE_CHANNEL_READ_TIMER_PROPERTY_ID));
+        assertEquals(String.valueOf(262144), channelSource.getPropertyValue(TraceChannelPropertySource.TRACE_CHANNEL_SUBBUFFER_SIZE_PROPERTY_ID));
+        assertEquals(String.valueOf(0), channelSource.getPropertyValue(TraceChannelPropertySource.TRACE_CHANNEL_SWITCH_TIMER_PROPERTY_ID));
+        assertEquals(Integer.valueOf(2), channelSource.getPropertyValue(TraceChannelPropertySource.TRACE_CHANNEL_TRACE_FILE_COUNT_PROPERTY_ID));
+        assertEquals(Long.valueOf(262144), channelSource.getPropertyValue(TraceChannelPropertySource.TRACE_CHANNEL_TRACE_FILE_SIZE_PROPERTY_ID));
+
+        // ------------------------------------------------------------------------
+        // Verify Event Properties (adapter)
+        // ------------------------------------------------------------------------
+        ITraceControlComponent[] channel0Events = channel.getChildren();
+        assertNotNull(channel0Events);
+        assertEquals(5, channel0Events.length);
+        assertTrue(channel0Events[0] instanceof TraceEventComponent);
+
+        TraceEventComponent event = (TraceEventComponent) channel0Events[0];
+
+        adapter = event.getAdapter(IPropertySource.class);
+        assertNotNull(adapter);
+        assertTrue(adapter instanceof TraceEventPropertySource);
+
+        TraceEventPropertySource eventSource = (TraceEventPropertySource)adapter;
+        assertNotNull(eventSource.getPropertyDescriptors());
+
+        assertEquals("block_rq_remap", eventSource.getPropertyValue(TraceEventPropertySource.TRACE_EVENT_NAME_PROPERTY_ID));
+        assertEquals(TraceLogLevel.TRACE_EMERG.name(), eventSource.getPropertyValue(TraceEventPropertySource.TRACE_EVENT_LOGLEVEL_PROPERTY_ID));
+        assertEquals(TraceEventType.TRACEPOINT.name(), eventSource.getPropertyValue(TraceEventPropertySource.TRACE_EVENT_TYPE_PROPERTY_ID));
+        assertEquals(TraceEnablement.ENABLED.name(), eventSource.getPropertyValue(TraceEventPropertySource.TRACE_EVENT_STATE_PROPERTY_ID));
+
+        // ------------------------------------------------------------------------
+        // Verify Probe Event Properties (adapter)
+        // ------------------------------------------------------------------------
+        assertTrue(channel0Events[2] instanceof TraceProbeEventComponent);
+
+        TraceProbeEventComponent probeEvent = (TraceProbeEventComponent) channel0Events[2];
+
+        adapter = probeEvent.getAdapter(IPropertySource.class);
+        assertNotNull(adapter);
+        assertTrue(adapter instanceof TraceProbeEventPropertySource);
+
+        TraceProbeEventPropertySource probeEventSource = (TraceProbeEventPropertySource)adapter;
+        assertNotNull(probeEventSource.getPropertyDescriptors());
+        assertEquals(4, probeEventSource.getPropertyDescriptors().length);
+
+        assertEquals("myevent2", probeEventSource.getPropertyValue(TraceEventPropertySource.TRACE_EVENT_NAME_PROPERTY_ID));
+        assertEquals(TraceEventType.PROBE.name(), probeEventSource.getPropertyValue(TraceEventPropertySource.TRACE_EVENT_TYPE_PROPERTY_ID));
+        assertEquals(TraceEnablement.ENABLED.name(), probeEventSource.getPropertyValue(TraceEventPropertySource.TRACE_EVENT_STATE_PROPERTY_ID));
+        assertEquals("0xc0101340", probeEventSource.getPropertyValue(TraceProbeEventPropertySource.TRACE_EVENT_PROBE_ADDRESS_PROPERTY_ID));
+
+        assertTrue(channel0Events[3] instanceof TraceProbeEventComponent);
+
+        probeEvent = (TraceProbeEventComponent) channel0Events[3];
+
+        adapter = probeEvent.getAdapter(IPropertySource.class);
+        assertNotNull(adapter);
+        assertTrue(adapter instanceof TraceProbeEventPropertySource);
+
+        probeEventSource = (TraceProbeEventPropertySource)adapter;
+        assertNotNull(probeEventSource.getPropertyDescriptors());
+        assertEquals(5, probeEventSource.getPropertyDescriptors().length);
+
+        assertEquals("myevent0", probeEventSource.getPropertyValue(TraceEventPropertySource.TRACE_EVENT_NAME_PROPERTY_ID));
+        assertEquals(TraceEventType.PROBE.name(), probeEventSource.getPropertyValue(TraceEventPropertySource.TRACE_EVENT_TYPE_PROPERTY_ID));
+        assertEquals(TraceEnablement.ENABLED.name(), probeEventSource.getPropertyValue(TraceEventPropertySource.TRACE_EVENT_STATE_PROPERTY_ID));
+        assertEquals("0x0", probeEventSource.getPropertyValue(TraceProbeEventPropertySource.TRACE_EVENT_PROBE_OFFSET_PROPERTY_ID));
+        assertEquals("init_post", probeEventSource.getPropertyValue(TraceProbeEventPropertySource.TRACE_EVENT_PROBE_SYMBOL_PROPERTY_ID));
+
+        //-------------------------------------------------------------------------
+        // Verify Filter of UST event
+        //-------------------------------------------------------------------------
+        event = (TraceEventComponent) domains[1].getChildren()[1].getChildren()[0];
+        adapter = event.getAdapter(IPropertySource.class);
+        assertEquals("with filter", event.getFilterExpression());
+
+        //-------------------------------------------------------------------------
+        // Verify Log Level Type of UST events (> LTTng 2.4)
+        //-------------------------------------------------------------------------
+        event = (TraceEventComponent) domains[1].getChildren()[1].getChildren()[0];
+        adapter = event.getAdapter(IPropertySource.class);
+        eventSource = (TraceEventPropertySource) adapter;
+        assertEquals("== TRACE_DEBUG_LINE", eventSource.getPropertyValue(TraceEventPropertySource.TRACE_EVENT_LOGLEVEL_PROPERTY_ID));
+
+        event = (TraceEventComponent) domains[1].getChildren()[1].getChildren()[1];
+        adapter = event.getAdapter(IPropertySource.class);
+        eventSource = (TraceEventPropertySource) adapter;
+        assertEquals("<= TRACE_INFO", eventSource.getPropertyValue(TraceEventPropertySource.TRACE_EVENT_LOGLEVEL_PROPERTY_ID));
+
+        event = (TraceEventComponent) domains[1].getChildren()[1].getChildren()[2];
+        adapter = event.getAdapter(IPropertySource.class);
+        eventSource = (TraceEventPropertySource) adapter;
+        assertEquals("TRACE_DEBUG_SYSTEM", eventSource.getPropertyValue(TraceEventPropertySource.TRACE_EVENT_LOGLEVEL_PROPERTY_ID));
+
+        //-------------------------------------------------------------------------
+        // Delete node
+        //-------------------------------------------------------------------------
+        node.disconnect();
+        node.getParent().removeChild(node);
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlSnapshotSessionTests.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlSnapshotSessionTests.java
new file mode 100644 (file)
index 0000000..ed588a8
--- /dev/null
@@ -0,0 +1,217 @@
+/**********************************************************************
+ * Copyright (c) 2013, 2015 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Markus Schorn - Bug 448058: Use org.eclipse.remote in favor of RSE
+ **********************************************************************/
+
+package org.eclipse.tracecompass.lttng2.control.ui.tests.model.component;
+
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertNotNull;
+import static org.junit.Assert.assertTrue;
+
+import java.io.File;
+import java.net.URL;
+import java.util.HashMap;
+import java.util.Map;
+
+import org.eclipse.core.runtime.FileLocator;
+import org.eclipse.core.runtime.Path;
+import org.eclipse.jdt.annotation.NonNull;
+import org.eclipse.remote.core.IRemoteConnection;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TargetNodeState;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
+import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.CreateSessionDialogStub;
+import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.DestroyConfirmDialogStub;
+import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.GetEventInfoDialogStub;
+import org.eclipse.tracecompass.internal.lttng2.control.stubs.service.TestRemoteSystemProxy;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.TraceControlDialogFactory;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.property.TraceSessionPropertySource;
+import org.eclipse.tracecompass.tmf.remote.core.proxy.TmfRemoteConnectionFactory;
+import org.eclipse.ui.views.properties.IPropertyDescriptor;
+import org.eclipse.ui.views.properties.IPropertySource;
+import org.junit.After;
+import org.junit.Before;
+import org.junit.Test;
+import org.osgi.framework.FrameworkUtil;
+
+/**
+ * The class <code>TraceControlSnapshotSessionTests</code> contains Snapshot
+ * session test cases for support of LTTng Tools 2.3.
+ */
+public class TraceControlSnapshotSessionTests {
+
+    // ------------------------------------------------------------------------
+    // Constants
+    // ------------------------------------------------------------------------
+
+    private static final String TEST_STREAM = "CreateSessionTest2.cfg";
+    private static final String SCEN_CREATE_SESSION = "ScenCreateSession";
+
+    // ------------------------------------------------------------------------
+    // Test data
+    // ------------------------------------------------------------------------
+
+    private TraceControlTestFacility fFacility;
+    private IRemoteConnection fHost = TmfRemoteConnectionFactory.getLocalConnection();
+    private @NonNull TestRemoteSystemProxy fProxy = new TestRemoteSystemProxy(fHost);
+    private String fTestFile;
+
+    // ------------------------------------------------------------------------
+    // Housekeeping
+    // ------------------------------------------------------------------------
+
+    /**
+     * Perform pre-test initialization.
+     *
+     * @throws Exception
+     *         if the initialization fails for some reason
+     */
+    @Before
+    public void setUp() throws Exception {
+        fFacility = TraceControlTestFacility.getInstance();
+        fFacility.init();
+        fProxy = new TestRemoteSystemProxy(fHost);
+        URL location = FileLocator.find(FrameworkUtil.getBundle(this.getClass()), new Path(TraceControlTestFacility.DIRECTORY + File.separator + TEST_STREAM), null);
+        File testfile = new File(FileLocator.toFileURL(location).toURI());
+        fTestFile = testfile.getAbsolutePath();
+    }
+
+    /**
+     * Perform post-test clean-up.
+     */
+    @After
+    public void tearDown() {
+        fFacility.waitForJobs();
+        fFacility.dispose();
+    }
+
+    /**
+     * Run the TraceControlComponent.
+     *
+     * @throws Exception
+     *             This will fail the test
+     */
+    @Test
+    public void testTraceSessionTree() throws Exception {
+
+        fProxy.setTestFile(fTestFile);
+        fProxy.setScenario(TraceControlTestFacility.SCEN_INIT_TEST);
+
+        ITraceControlComponent root = fFacility.getControlView().getTraceControlRoot();
+
+        TargetNodeComponent node = new TargetNodeComponent("myNode", root, fProxy);
+
+        root.addChild(node);
+        fFacility.waitForJobs();
+
+        fFacility.executeCommand(node, "connect");
+        int i = 0;
+        while ((i < 10) && (node.getTargetNodeState() != TargetNodeState.CONNECTED)) {
+            i++;
+            fFacility.delay(TraceControlTestFacility.GUI_REFESH_DELAY);
+        }
+
+        // Get provider groups
+        ITraceControlComponent[] groups = node.getChildren();
+        assertNotNull(groups);
+        assertEquals(2, groups.length);
+
+        // Initialize dialog implementations for command execution
+        // --- snapshot session ---
+        CreateSessionDialogStub sessionDialog = new CreateSessionDialogStub();
+        sessionDialog.setSnapshot(true);
+
+        TraceControlDialogFactory.getInstance().setCreateSessionDialog(sessionDialog);
+        TraceControlDialogFactory.getInstance().setGetEventInfoDialog(new GetEventInfoDialogStub());
+        TraceControlDialogFactory.getInstance().setConfirmDialog(new DestroyConfirmDialogStub());
+
+        // Initialize scenario
+        fProxy.setScenario(SCEN_CREATE_SESSION);
+
+        // ------------------------------------------------------------------------
+        // Create session
+        // ------------------------------------------------------------------------
+        TraceSessionComponent session = fFacility.createSession(groups[1]);
+
+        // Verify that session was created
+        assertNotNull(session);
+        assertEquals("mysession", session.getName());
+        assertTrue(session.isSnapshotSession());
+        assertNotNull(session.getSnapshotInfo());
+        assertEquals("snapshot-1", session.getSnapshotInfo().getName());
+        assertEquals("/home/user/lttng-traces/mysession-20130913-141651", session.getSnapshotInfo().getSnapshotPath());
+        assertEquals(1, session.getSnapshotInfo().getId());
+
+        // ------------------------------------------------------------------------
+        // Start session
+        // ------------------------------------------------------------------------
+        fFacility.startSession(session);
+        assertEquals(TraceSessionState.ACTIVE, session.getSessionState());
+
+        // verify properties
+        Object adapter = session.getAdapter(IPropertySource.class);
+        assertNotNull(adapter);
+        assertTrue(adapter instanceof TraceSessionPropertySource);
+
+        TraceSessionPropertySource sessionSource = (TraceSessionPropertySource)adapter;
+        IPropertyDescriptor[] descriptors = sessionSource.getPropertyDescriptors();
+        assertNotNull(descriptors);
+
+        Map<String,String> map = new HashMap<>();
+        map.put(TraceSessionPropertySource.TRACE_SESSION_NAME_PROPERTY_ID, "mysession");
+        map.put(TraceSessionPropertySource.TRACE_SNAPSHOT_NAME_PROPERTY_ID, "snapshot-1");
+        map.put(TraceSessionPropertySource.TRACE_SNAPSHOT_PATH_PROPERTY_ID, "/home/user/lttng-traces/mysession-20130913-141651");
+        map.put(TraceSessionPropertySource.TRACE_SNAPSHOT_ID_PROPERTY_ID, "1");
+        map.put(TraceSessionPropertySource.TRACE_SESSION_STATE_PROPERTY_ID, TraceSessionState.ACTIVE.name());
+
+        for (int j = 0; j < descriptors.length; j++) {
+            String expected = map.get(descriptors[j].getId());
+            assertNotNull(expected);
+            assertEquals(expected, sessionSource.getPropertyValue(descriptors[j].getId()).toString());
+        }
+
+        // ------------------------------------------------------------------------
+        // Record snapshot
+        // ------------------------------------------------------------------------
+        fFacility.executeCommand(session, "snapshot");
+
+        // ------------------------------------------------------------------------
+        // Stop snapshot
+        // ------------------------------------------------------------------------
+        fFacility.stopSession(session);
+        assertEquals(TraceSessionState.INACTIVE, session.getSessionState());
+
+        // ------------------------------------------------------------------------
+        // Destroy session
+        // ------------------------------------------------------------------------
+        fFacility.destroySession(session);
+
+        // Verify that no more session components exist
+        assertEquals(0, groups[1].getChildren().length);
+
+        //-------------------------------------------------------------------------
+        // Disconnect node
+        //-------------------------------------------------------------------------
+        fFacility.executeCommand(node, "disconnect");
+        assertEquals(TargetNodeState.DISCONNECTED, node.getTargetNodeState());
+
+        //-------------------------------------------------------------------------
+        // Delete node
+        //-------------------------------------------------------------------------
+
+        fFacility.executeCommand(node, "delete");
+
+        assertEquals(0,fFacility.getControlView().getTraceControlRoot().getChildren().length);
+    }
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlTestFacility.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlTestFacility.java
new file mode 100644 (file)
index 0000000..f14a4a3
--- /dev/null
@@ -0,0 +1,303 @@
+/*******************************************************************************
+ * Copyright (c) 2011, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.control.ui.tests.model.component;
+
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.core.commands.NotEnabledException;
+import org.eclipse.core.commands.NotHandledException;
+import org.eclipse.core.commands.common.NotDefinedException;
+import org.eclipse.core.runtime.jobs.Job;
+import org.eclipse.swt.widgets.Display;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TargetNodeState;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
+import org.eclipse.ui.IViewPart;
+import org.eclipse.ui.PartInitException;
+import org.eclipse.ui.PlatformUI;
+import org.eclipse.ui.handlers.IHandlerService;
+import org.junit.Assert;
+
+/**
+ *  Singleton class to facilitate the test cases. Creates UML2SD view and loader objects as well as provides
+ *  utility methods for interacting with the loader/view.
+ */
+@SuppressWarnings("javadoc")
+public class TraceControlTestFacility {
+
+    // ------------------------------------------------------------------------
+    // Constants
+    // ------------------------------------------------------------------------
+    public final static int WAIT_FOR_JOBS_DELAY = 50;
+    public final static int GUI_REFESH_DELAY = 500;
+
+    public final static String DIRECTORY = "testfiles";
+    public final static String COMMAND_CATEGORY_PREFIX = "org.eclipse.linuxtools.internal.lttng2.ui.commands.control.";
+    public final static String SCEN_INIT_TEST = "Initialize";
+    public final static String SCEN_SCENARIO_SESSION_HANDLING = "SessionHandling";
+    public final static String SCEN_SCENARIO_SESSION_HANDLING_WITH_PATH = "SessionHandlingWithPath";
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+    private static TraceControlTestFacility fInstance = null;
+    private ControlView fControlView = null;
+    private boolean fIsInitialized = false;
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+    private TraceControlTestFacility() {
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+    public static TraceControlTestFacility getInstance() {
+        if (fInstance == null) {
+            fInstance = new TraceControlTestFacility();
+        }
+        return fInstance;
+    }
+
+    /**
+     * Initial the test facility.
+     */
+    public void init() {
+
+        if (!fIsInitialized) {
+
+            IViewPart view;
+            try {
+
+                view = PlatformUI.getWorkbench()
+                        .getActiveWorkbenchWindow()
+                        .getActivePage()
+                        .findView("org.eclipse.ui.internal.introview");
+
+                if (view != null) {
+                    PlatformUI.getWorkbench()
+                    .getActiveWorkbenchWindow()
+                    .getActivePage().hideView(view);
+                }
+
+                view = PlatformUI.getWorkbench()
+                                 .getActiveWorkbenchWindow()
+                                 .getActivePage()
+                                 .showView(ControlView.ID);
+
+            } catch (PartInitException e) {
+                throw new RuntimeException(e);
+            }
+
+            fControlView = (ControlView) view;
+
+            delay(3000);
+            fIsInitialized = true;
+        }
+    }
+
+
+    /**
+     * Disposes the facility (and GUI)
+     */
+    public void dispose() {
+        if (fIsInitialized) {
+            waitForJobs();
+
+            PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActivePage().hideView(fControlView);
+            fIsInitialized = false;
+        }
+    }
+
+    /**
+     * Creates a delay for given time.
+     * @param waitTimeMillis - time in milli seconds
+     */
+    public void delay(long waitTimeMillis) {
+        Display display = Display.getCurrent();
+        if (display != null) {
+            long endTimeMillis = System.currentTimeMillis() + waitTimeMillis;
+            while(System.currentTimeMillis() < endTimeMillis) {
+                if (!display.readAndDispatch()) {
+                    // We do not use Display.sleep because it might never wake up
+                    // if there is no user interaction
+                    try {
+                        Thread.sleep(Math.min(waitTimeMillis, 10));
+                    } catch (final InterruptedException e) {
+                        // Ignored
+                    }
+                }
+                display.update();
+            }
+        } else {
+            try {
+                Thread.sleep(waitTimeMillis);
+            } catch (InterruptedException e) {
+                // Ignored
+            }
+        }
+    }
+
+    /**
+     * Waits for a connection to be connected
+     */
+    public void waitForConnect(TargetNodeComponent node) {
+        for (int i = 1; i < 5000 && node.getTargetNodeState() == TargetNodeState.CONNECTING; i *= 2) {
+            try {
+                Thread.sleep(i);
+            } catch (InterruptedException e) {
+                Assert.fail();
+            }
+        }
+    }
+
+    /**
+     * Waits for all Eclipse jobs to finish
+     */
+    public void waitForJobs() {
+        while (!Job.getJobManager().isIdle()) {
+            delay(WAIT_FOR_JOBS_DELAY);
+        }
+    }
+
+    /**
+     * @return current control view
+     */
+    public ControlView getControlView() {
+        return fControlView;
+    }
+
+    /**
+     * Executes an Eclipse command with command ID after selecting passed component
+     * @param component - component to select in the tree
+     * @param commandId - command ID
+     * @throws ExecutionException
+     * @throws NotDefinedException
+     * @throws NotEnabledException
+     * @throws NotHandledException
+     */
+    public void executeCommand(ITraceControlComponent component, String commandId) throws ExecutionException, NotDefinedException, NotEnabledException, NotHandledException {
+        setSelection(component);
+        executeCommand(commandId);
+    }
+
+    /**
+     * Executes an Eclipse command with command ID after selecting passed components
+     * @param components - array of components to select in the tree
+     * @param commandId - command ID
+     * @throws ExecutionException
+     * @throws NotDefinedException
+     * @throws NotEnabledException
+     * @throws NotHandledException
+     */
+    public void executeCommand(ITraceControlComponent[] components, String commandId) throws ExecutionException, NotDefinedException, NotEnabledException, NotHandledException {
+        setSelection(components);
+        executeCommand(commandId);
+    }
+
+    /**
+     * Executes an Eclipse command with command ID
+     * @param commandId
+     * @throws ExecutionException
+     * @throws NotDefinedException
+     * @throws NotEnabledException
+     * @throws NotHandledException
+     */
+    public void executeCommand(String commandId) throws ExecutionException, NotDefinedException, NotEnabledException, NotHandledException {
+        Object handlerServiceObject = fControlView.getSite().getService(IHandlerService.class);
+        IHandlerService handlerService = (IHandlerService) handlerServiceObject;
+        handlerService.executeCommand(COMMAND_CATEGORY_PREFIX + commandId, null);
+        waitForJobs();
+    }
+
+    /**
+     * Selects passed component
+     * @param component - component to select in the tree
+     * @param commandId - command ID
+     */
+    public void setSelection(ITraceControlComponent component) {
+        fControlView.setSelection(component);
+        // Selection is done in own job
+        waitForJobs();
+    }
+
+
+    /**
+     * Selects passed components
+     * @param components - array of component to select in the tree
+     * @param commandId - command ID
+     */
+    public void setSelection(ITraceControlComponent[] components) {
+        fControlView.setSelection(components);
+
+        // Selection is done in own job
+        waitForJobs();
+    }
+
+    /**
+     * Creates session on passed session group.
+     * @param group - session group
+     * @return - trace session group if it's successful else null
+     * @throws ExecutionException
+     * @throws NotDefinedException
+     * @throws NotEnabledException
+     * @throws NotHandledException
+     */
+    public TraceSessionComponent createSession(ITraceControlComponent group) throws ExecutionException, NotDefinedException, NotEnabledException, NotHandledException {
+        executeCommand(group, "createSession");
+
+        ITraceControlComponent[] sessions = group.getChildren();
+        if ((sessions == null) || (sessions.length == 0)) {
+            return null;
+        }
+        return (TraceSessionComponent)sessions[0];
+    }
+
+    /**
+     * Destroys a given session.
+     * @param session - session to destroy
+     * @throws ExecutionException
+     * @throws NotDefinedException
+     * @throws NotEnabledException
+     * @throws NotHandledException
+     */
+    public void destroySession(TraceSessionComponent session) throws ExecutionException, NotDefinedException, NotEnabledException, NotHandledException {
+        executeCommand(session, "destroySession");
+    }
+
+    /**
+     * Starts a given session
+     * @param session - session to start
+     * @throws ExecutionException
+     * @throws NotDefinedException
+     * @throws NotEnabledException
+     * @throws NotHandledException
+     */
+    public void startSession(TraceSessionComponent session) throws ExecutionException, NotDefinedException, NotEnabledException, NotHandledException {
+        executeCommand(session, "start");
+    }
+
+    /**
+     * Stops a given session
+     * @param session - session to stop
+     * @throws ExecutionException
+     * @throws NotDefinedException
+     * @throws NotEnabledException
+     * @throws NotHandledException
+     */
+    public void stopSession(TraceSessionComponent session) throws ExecutionException, NotDefinedException, NotEnabledException, NotHandledException {
+        executeCommand(session, "stop");
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlTreeModelNoProvidersTest.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlTreeModelNoProvidersTest.java
new file mode 100644 (file)
index 0000000..b1acded
--- /dev/null
@@ -0,0 +1,160 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2015 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Alexandre Montplaisir - Port to JUnit4
+ *   Markus Schorn - Bug 448058: Use org.eclipse.remote in favor of RSE
+ **********************************************************************/
+
+package org.eclipse.tracecompass.lttng2.control.ui.tests.model.component;
+
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertFalse;
+import static org.junit.Assert.assertNotNull;
+import static org.junit.Assert.assertNotSame;
+import static org.junit.Assert.assertTrue;
+
+import java.io.File;
+import java.net.URL;
+
+import org.eclipse.core.runtime.FileLocator;
+import org.eclipse.core.runtime.Path;
+import org.eclipse.jdt.annotation.NonNull;
+import org.eclipse.remote.core.IRemoteConnection;
+import org.eclipse.swt.graphics.Image;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TargetNodeState;
+import org.eclipse.tracecompass.internal.lttng2.control.stubs.service.TestRemoteSystemProxy;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceProviderGroup;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionGroup;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.UstProviderComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.service.ILttngControlService;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.service.LTTngControlService;
+import org.eclipse.tracecompass.tmf.remote.core.proxy.TmfRemoteConnectionFactory;
+import org.junit.After;
+import org.junit.Before;
+import org.junit.Test;
+import org.osgi.framework.FrameworkUtil;
+
+/**
+ * The class <code>TraceControlTreeModelNoProvidersTest</code> verifies that the
+ * Tracer Control can handle the case where no kernel provider and only UST
+ * provider are available.
+ */
+public class TraceControlTreeModelNoProvidersTest {
+
+    // ------------------------------------------------------------------------
+    // Constants
+    // ------------------------------------------------------------------------
+
+    private static final String TEST_STREAM = "ListInfoTest.cfg";
+    private static final String SCEN_LIST_INFO_TEST = "ListInfoTestNoKernel";
+    private static final String TARGET_NODE_NAME = "myNode";
+
+    // ------------------------------------------------------------------------
+    // Test data
+    // ------------------------------------------------------------------------
+
+    private IRemoteConnection fHost = TmfRemoteConnectionFactory.getLocalConnection();
+    private @NonNull TestRemoteSystemProxy fProxy = new TestRemoteSystemProxy(fHost);
+    private String fTestFile;
+
+    // ------------------------------------------------------------------------
+    // Housekeeping
+    // ------------------------------------------------------------------------
+
+    /**
+     * Perform pre-test initialization.
+     *
+     * @throws Exception
+     *         if the initialization fails for some reason
+     */
+    @Before
+    public void setUp() throws Exception {
+        URL location = FileLocator.find(FrameworkUtil.getBundle(this.getClass()), new Path(TraceControlTestFacility.DIRECTORY + File.separator + TEST_STREAM), null);
+        File testfile = new File(FileLocator.toFileURL(location).toURI());
+        fTestFile = testfile.getAbsolutePath();
+    }
+
+    /**
+     * Perform post-test clean-up.
+     */
+    @After
+    public void tearDown()  {
+        TraceControlTestFacility.getInstance().waitForJobs();
+    }
+
+    /**
+     * Run the TraceControlComponent.
+     */
+    @Test
+    public void testTraceControlComponents() {
+
+        fProxy.setTestFile(fTestFile);
+        fProxy.setScenario(SCEN_LIST_INFO_TEST);
+
+        ITraceControlComponent root = TraceControlTestFacility.getInstance().getControlView().getTraceControlRoot();
+
+        TargetNodeComponent node = new TargetNodeComponent(TARGET_NODE_NAME, root, fProxy);
+
+        root.addChild(node);
+        node.connect();
+
+        TraceControlTestFacility.getInstance().waitForConnect(node);
+        TraceControlTestFacility.getInstance().waitForJobs();
+
+        // ------------------------------------------------------------------------
+        // Verify Parameters of TargetNodeComponent
+        // ------------------------------------------------------------------------
+        assertEquals("Local", node.getToolTip()); // assigned in createLocalHost() above
+        Image connectedImage = node.getImage();
+        assertNotNull(connectedImage);
+        assertEquals(TargetNodeState.CONNECTED, node.getTargetNodeState());
+        assertNotNull(node.getControlService());
+        ILttngControlService service = node.getControlService();
+        assertTrue(service instanceof LTTngControlService);
+        node.setControlService(service);
+        assertTrue(node.getControlService() instanceof LTTngControlService);
+
+        // ------------------------------------------------------------------------
+        // Verify Children of TargetNodeComponent
+        // ------------------------------------------------------------------------
+        ITraceControlComponent[] groups = node.getChildren();
+        assertNotNull(groups);
+        assertEquals(2, groups.length);
+
+        assertTrue(groups[0] instanceof TraceProviderGroup);
+        assertTrue(groups[1] instanceof TraceSessionGroup);
+
+        // Check for kernel provider
+        TraceProviderGroup providerGroup = (TraceProviderGroup) groups[0];
+        assertFalse(providerGroup.hasKernelProvider());
+
+        assertEquals("Provider", providerGroup.getName());
+        assertEquals("Sessions", groups[1].getName());
+
+        // ------------------------------------------------------------------------
+        // Verify TraceProviderGroup
+        // ------------------------------------------------------------------------
+        ITraceControlComponent[] providers = groups[0].getChildren();
+
+        assertNotNull(providers);
+        assertEquals(1, providers.length);
+        assertTrue(providers[0] instanceof UstProviderComponent);
+
+        // disconnect
+        node.disconnect();
+        assertEquals(TargetNodeState.DISCONNECTED, node.getTargetNodeState());
+        assertNotNull(node.getImage());
+        assertNotSame(connectedImage, node.getImage());
+
+        node.getParent().removeChild(node);
+    }
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlTreeModelTest.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlTreeModelTest.java
new file mode 100644 (file)
index 0000000..e323130
--- /dev/null
@@ -0,0 +1,693 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2015 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Alexandre Montplaisir - Port to JUnit4
+ *   Markus Schorn - Bug 448058: Use org.eclipse.remote in favor of RSE
+ **********************************************************************/
+
+package org.eclipse.tracecompass.lttng2.control.ui.tests.model.component;
+
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertFalse;
+import static org.junit.Assert.assertNotNull;
+import static org.junit.Assert.assertNotSame;
+import static org.junit.Assert.assertNull;
+import static org.junit.Assert.assertTrue;
+
+import java.io.File;
+import java.net.URL;
+
+import org.eclipse.core.runtime.FileLocator;
+import org.eclipse.core.runtime.Path;
+import org.eclipse.jdt.annotation.NonNull;
+import org.eclipse.remote.core.IRemoteConnection;
+import org.eclipse.swt.graphics.Image;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.LogLevelType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TargetNodeState;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceChannelOutputType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEnablement;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEventType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
+import org.eclipse.tracecompass.internal.lttng2.control.stubs.service.TestRemoteSystemProxy;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.BaseEventComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.KernelProviderComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceEventComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceProbeEventComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceProviderGroup;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionGroup;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.UstProviderComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.service.ILttngControlService;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.service.LTTngControlService;
+import org.eclipse.tracecompass.tmf.remote.core.proxy.TmfRemoteConnectionFactory;
+import org.junit.After;
+import org.junit.Before;
+import org.junit.Test;
+import org.osgi.framework.FrameworkUtil;
+
+/**
+ * The class <code>TraceControlTreeModelTest</code> contains tests for the tree
+ * component classes.
+ */
+public class TraceControlTreeModelTest {
+
+    // ------------------------------------------------------------------------
+    // Constants
+    // ------------------------------------------------------------------------
+
+    private static final String TEST_STREAM = "ListInfoTest.cfg";
+    private static final String SCEN_LIST_INFO_TEST = "ListInfoTest";
+    private static final String TARGET_NODE_NAME = "myNode";
+
+    // ------------------------------------------------------------------------
+    // Test data
+    // ------------------------------------------------------------------------
+
+    private IRemoteConnection fHost = TmfRemoteConnectionFactory.getLocalConnection();
+    private @NonNull TestRemoteSystemProxy fProxy = new TestRemoteSystemProxy(fHost);
+    private String fTestFile;
+
+    // ------------------------------------------------------------------------
+    // Housekeeping
+    // ------------------------------------------------------------------------
+
+    /**
+     * Perform pre-test initialization.
+     *
+     * @throws Exception
+     *         if the initialization fails for some reason
+     */
+    @Before
+    public void setUp() throws Exception {
+        URL location = FileLocator.find(FrameworkUtil.getBundle(this.getClass()), new Path(TraceControlTestFacility.DIRECTORY + File.separator + TEST_STREAM), null);
+        File testfile = new File(FileLocator.toFileURL(location).toURI());
+        fTestFile = testfile.getAbsolutePath();
+    }
+
+    /**
+     * Perform post-test clean-up.
+     */
+    @After
+    public void tearDown() {
+        TraceControlTestFacility.getInstance().waitForJobs();
+    }
+
+    /**
+     * Run the TraceControlComponent.
+     */
+    @Test
+    public void testTraceControlComponents() {
+
+        fProxy.setTestFile(fTestFile);
+        fProxy.setScenario(SCEN_LIST_INFO_TEST);
+
+        ITraceControlComponent root = TraceControlTestFacility.getInstance().getControlView().getTraceControlRoot();
+
+        TargetNodeComponent node = new TargetNodeComponent(TARGET_NODE_NAME, root, fProxy);
+
+        root.addChild(node);
+        node.connect();
+
+        TraceControlTestFacility.getInstance().waitForConnect(node);
+        TraceControlTestFacility.getInstance().waitForJobs();
+
+        // ------------------------------------------------------------------------
+        // Verify Parameters of TargetNodeComponent
+        // ------------------------------------------------------------------------
+        assertEquals("Local", node.getToolTip()); // assigned in createLocalHost() above
+        Image connectedImage = node.getImage();
+        assertNotNull(connectedImage);
+        assertEquals(TargetNodeState.CONNECTED, node.getTargetNodeState());
+        assertNotNull(node.getControlService());
+        ILttngControlService service = node.getControlService();
+        assertTrue(service instanceof LTTngControlService);
+        node.setControlService(service);
+        assertTrue(node.getControlService() instanceof LTTngControlService);
+
+
+        // ------------------------------------------------------------------------
+        // Verify Children of TargetNodeComponent
+        // ------------------------------------------------------------------------
+        ITraceControlComponent[] groups = node.getChildren();
+        assertNotNull(groups);
+        assertEquals(2, groups.length);
+
+        assertTrue(groups[0] instanceof TraceProviderGroup);
+        assertTrue(groups[1] instanceof TraceSessionGroup);
+
+        assertEquals("Provider", groups[0].getName());
+        assertEquals("Sessions", groups[1].getName());
+
+        // ------------------------------------------------------------------------
+        // Verify TraceProviderGroup
+        // ------------------------------------------------------------------------
+        ITraceControlComponent[] providers = groups[0].getChildren();
+
+        assertNotNull(providers);
+        assertEquals(3, providers.length);
+
+        // ------------------------------------------------------------------------
+        // Verify KernelProviderComponent
+        // ------------------------------------------------------------------------
+        KernelProviderComponent kernelProvider = (KernelProviderComponent) providers[0];
+
+        // ------------------------------------------------------------------------
+        // Verify event info (kernel provider)
+        // ------------------------------------------------------------------------
+        ITraceControlComponent[] events = kernelProvider.getChildren();
+        assertNotNull(events);
+        assertEquals(3, events.length);
+
+        BaseEventComponent baseEventInfo = (BaseEventComponent) events[0];
+        assertNotNull(baseEventInfo);
+        assertEquals("sched_kthread_stop", baseEventInfo.getName());
+        assertEquals(TraceLogLevel.TRACE_EMERG, baseEventInfo.getLogLevel());
+        assertEquals(TraceEventType.TRACEPOINT, baseEventInfo.getEventType());
+
+        baseEventInfo = (BaseEventComponent) events[1];
+        assertEquals("sched_kthread_stop_ret", baseEventInfo.getName());
+        assertEquals(TraceLogLevel.TRACE_EMERG, baseEventInfo.getLogLevel());
+        assertEquals(TraceEventType.TRACEPOINT, baseEventInfo.getEventType());
+
+        baseEventInfo = (BaseEventComponent) events[2];
+        assertEquals("sched_wakeup_new", baseEventInfo.getName());
+        assertEquals(TraceLogLevel.TRACE_EMERG, baseEventInfo.getLogLevel());
+        assertEquals(TraceEventType.TRACEPOINT, baseEventInfo.getEventType());
+
+        // ------------------------------------------------------------------------
+        // Verify UstProviderComponent
+        // ------------------------------------------------------------------------
+        UstProviderComponent ustProvider = (UstProviderComponent) providers[1];
+        assertEquals("/home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello [PID=9379]", ustProvider.getName());
+        assertEquals(9379, ustProvider.getPid());
+
+        // ------------------------------------------------------------------------
+        // Verify event info (UST provider)
+        // ------------------------------------------------------------------------
+        events = ustProvider.getChildren();
+        assertNotNull(events);
+        assertEquals(2, events.length);
+
+        baseEventInfo = (BaseEventComponent) events[0];
+        assertNotNull(baseEventInfo);
+        assertEquals("ust_tests_hello:tptest_sighandler", baseEventInfo.getName());
+        assertEquals(TraceLogLevel.TRACE_DEBUG_MODULE, baseEventInfo.getLogLevel());
+        assertEquals(TraceEventType.TRACEPOINT, baseEventInfo.getEventType());
+
+        baseEventInfo = (BaseEventComponent) events[1];
+        assertEquals("ust_tests_hello:tptest", baseEventInfo.getName());
+        assertEquals(TraceLogLevel.TRACE_INFO, baseEventInfo.getLogLevel());
+        assertEquals(TraceEventType.TRACEPOINT, baseEventInfo.getEventType());
+
+        // ------------------------------------------------------------------------
+        // Verify UstProviderComponent
+        // ------------------------------------------------------------------------
+        ustProvider = (UstProviderComponent) providers[2];
+        assertEquals("/home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello [PID=4852]", ustProvider.getName());
+        assertEquals(4852, ustProvider.getPid());
+
+        // verify getters and setter
+        verifyUstProviderGettersSetters(ustProvider);
+
+        // ------------------------------------------------------------------------
+        // Verify event info (UST provider)
+        // ------------------------------------------------------------------------
+        events = ustProvider.getChildren();
+        assertNotNull(events);
+        assertEquals(2, events.length);
+
+        baseEventInfo = (BaseEventComponent) events[0];
+        assertNotNull(baseEventInfo);
+        assertEquals("ust_tests_hello:tptest_sighandler", baseEventInfo.getName());
+        assertEquals(TraceLogLevel.TRACE_WARNING, baseEventInfo.getLogLevel());
+        assertEquals(TraceEventType.TRACEPOINT, baseEventInfo.getEventType());
+
+        baseEventInfo = (BaseEventComponent) events[1];
+        assertEquals("ust_tests_hello:tptest", baseEventInfo.getName());
+        assertEquals(TraceLogLevel.TRACE_DEBUG_FUNCTION, baseEventInfo.getLogLevel());
+        assertEquals(TraceEventType.TRACEPOINT, baseEventInfo.getEventType());
+
+        // verify getters and setters
+        verifyBaseEventGettersSetters(baseEventInfo);
+
+        // ------------------------------------------------------------------------
+        // Verify TraceSessionGroup
+        // ------------------------------------------------------------------------
+        ITraceControlComponent[] sessions = groups[1].getChildren();
+        assertNotNull(sessions);
+        assertEquals(2, sessions.length);
+        for (int i = 0; i < sessions.length; i++) {
+            assertTrue(sessions[i] instanceof TraceSessionComponent);
+        }
+        assertEquals("mysession1", sessions[0].getName());
+        assertEquals("mysession", sessions[1].getName());
+
+        // ------------------------------------------------------------------------
+        // Verify TraceSessionComponent
+        // ------------------------------------------------------------------------
+        TraceSessionComponent session = (TraceSessionComponent)sessions[1];
+        assertEquals("mysession", session.getName());
+        assertEquals("/home/user/lttng-traces/mysession-20120129-084256", session.getSessionPath());
+        assertEquals(TraceSessionState.ACTIVE, session.getSessionState());
+
+        // Verify setters and setters
+        verifySessionGetterSetters(session);
+
+        ITraceControlComponent[] domains = session.getChildren();
+        assertNotNull(domains);
+        assertEquals(2, domains.length);
+
+        // ------------------------------------------------------------------------
+        // Verify Kernel domain
+        // ------------------------------------------------------------------------
+        assertEquals("Kernel", domains[0].getName());
+        ITraceControlComponent[] channels =  domains[0].getChildren();
+        assertNotNull(channels);
+        assertEquals(2, channels.length);
+
+        // Verify setters and setters
+        verifyDomainGettersSetters((TraceDomainComponent) domains[0]);
+
+        // ------------------------------------------------------------------------
+        // Verify Kernel's channel0
+        // ------------------------------------------------------------------------
+        assertTrue(channels[0] instanceof TraceChannelComponent);
+        TraceChannelComponent channel = (TraceChannelComponent) channels[0];
+        assertEquals("channel0", channel.getName());
+        assertEquals(4, channel.getNumberOfSubBuffers());
+        assertEquals("splice()", channel.getOutputType().getInName());
+        assertEquals(TraceChannelOutputType.SPLICE, channel.getOutputType());
+        assertEquals(false, channel.isOverwriteMode());
+        assertEquals(200, channel.getReadTimer());
+        assertEquals(TraceEnablement.ENABLED, channel.getState());
+        assertEquals(262144, channel.getSubBufferSize());
+        assertEquals(0, channel.getSwitchTimer());
+
+        // ------------------------------------------------------------------------
+        // Verify event info (kernel, channel0)
+        // ------------------------------------------------------------------------
+        ITraceControlComponent[] channel0Events = channel.getChildren();
+        assertNotNull(channel0Events);
+        assertEquals(5, channel0Events.length);
+        assertTrue(channel0Events[0] instanceof TraceEventComponent);
+        assertTrue(channel0Events[1] instanceof TraceEventComponent);
+        assertTrue(channel0Events[2] instanceof TraceProbeEventComponent);
+        assertTrue(channel0Events[3] instanceof TraceProbeEventComponent);
+        assertTrue(channel0Events[4] instanceof TraceEventComponent);
+
+        TraceEventComponent event = (TraceEventComponent) channel0Events[0];
+        assertEquals("block_rq_remap", event.getName());
+        assertEquals(TraceLogLevel.TRACE_EMERG, event.getLogLevel());
+        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
+        assertEquals(TraceEnablement.ENABLED, event.getState());
+
+        event = (TraceEventComponent) channel0Events[1];
+        assertEquals("block_bio_remap", event.getName());
+        assertEquals(TraceLogLevel.TRACE_EMERG, event.getLogLevel());
+        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
+        assertEquals(TraceEnablement.DISABLED, event.getState());
+
+        TraceProbeEventComponent probeEvent = (TraceProbeEventComponent) channel0Events[2];
+        assertEquals("myevent2", probeEvent.getName());
+        assertEquals(TraceLogLevel.LEVEL_UNKNOWN, probeEvent.getLogLevel());
+        assertEquals(TraceEventType.PROBE, probeEvent.getEventType());
+        assertEquals(TraceEnablement.ENABLED, probeEvent.getState());
+        assertEquals("0xc0101340", probeEvent.getAddress());
+        assertNull(probeEvent.getOffset());
+        assertNull(probeEvent.getSymbol());
+
+        // verify getters and setter
+        verifyProbeEventGettersSetters(probeEvent);
+
+        probeEvent = (TraceProbeEventComponent) channel0Events[3];
+        assertEquals("myevent0", probeEvent.getName());
+        assertEquals(TraceLogLevel.LEVEL_UNKNOWN, probeEvent.getLogLevel());
+        assertEquals(TraceEventType.PROBE, probeEvent.getEventType());
+        assertEquals(TraceEnablement.ENABLED, probeEvent.getState());
+        assertNull(probeEvent.getAddress());
+        assertEquals("0x0", probeEvent.getOffset());
+        assertEquals("init_post", probeEvent.getSymbol());
+
+        event = (TraceEventComponent) channel0Events[4];
+        assertEquals("syscalls", event.getName());
+        assertEquals(TraceLogLevel.LEVEL_UNKNOWN, event.getLogLevel());
+        assertEquals(TraceEventType.SYSCALL, event.getEventType());
+        assertEquals(TraceEnablement.ENABLED, event.getState());
+
+        // ------------------------------------------------------------------------
+        // Verify Kernel's channel1
+        // ------------------------------------------------------------------------
+        assertEquals("channel1", channels[1].getName());
+        channel = (TraceChannelComponent) channels[1];
+        assertEquals(4, channel.getNumberOfSubBuffers());
+        assertEquals("splice()", channel.getOutputType().getInName());
+        assertEquals(TraceChannelOutputType.SPLICE, channel.getOutputType());
+        assertEquals(true, channel.isOverwriteMode());
+        assertEquals(400, channel.getReadTimer());
+        assertEquals(TraceEnablement.DISABLED, channel.getState());
+        assertEquals(524288, channel.getSubBufferSize());
+        assertEquals(100, channel.getSwitchTimer());
+
+        // ------------------------------------------------------------------------
+        // Verify event info (kernel, channel1)
+        // ------------------------------------------------------------------------
+        ITraceControlComponent[] channel1Events = channels[1].getChildren();
+        assertEquals(0, channel1Events.length);
+
+        // ------------------------------------------------------------------------
+        // Verify domain UST global
+        // ------------------------------------------------------------------------
+        assertEquals("UST global", domains[1].getName());
+
+        ITraceControlComponent[] ustChannels = domains[1].getChildren();
+
+        for (int i = 0; i < ustChannels.length; i++) {
+            assertTrue(ustChannels[i] instanceof TraceChannelComponent);
+        }
+
+        // ------------------------------------------------------------------------
+        // Verify UST global's mychannel1
+        // ------------------------------------------------------------------------
+        channel = (TraceChannelComponent) ustChannels[0];
+        assertEquals("mychannel1", channel.getName());
+        assertEquals(8, channel.getNumberOfSubBuffers());
+        assertEquals("mmap()", channel.getOutputType().getInName());
+        assertEquals(TraceChannelOutputType.MMAP, channel.getOutputType());
+        assertEquals(true, channel.isOverwriteMode());
+        assertEquals(100, channel.getReadTimer());
+        assertEquals(TraceEnablement.DISABLED, channel.getState());
+        assertEquals(8192, channel.getSubBufferSize());
+        assertEquals(200, channel.getSwitchTimer());
+
+        // verify getters and setters
+        verifyChannelGettersSetters(channel);
+
+        // ------------------------------------------------------------------------
+        // Verify event info (UST global, mychannel1)
+        // ------------------------------------------------------------------------
+        ITraceControlComponent[] ustEvents = channel.getChildren();
+        assertEquals(0, ustEvents.length);
+
+        // ------------------------------------------------------------------------
+        // Verify UST global's channel0
+        // ------------------------------------------------------------------------
+        channel = (TraceChannelComponent) ustChannels[1];
+        assertEquals("channel0", channel.getName());
+        assertEquals(4, channel.getNumberOfSubBuffers());
+        assertEquals("mmap()", channel.getOutputType().getInName());
+        assertEquals(TraceChannelOutputType.MMAP, channel.getOutputType());
+        assertEquals(false, channel.isOverwriteMode());
+        assertEquals(200, channel.getReadTimer());
+        assertEquals(TraceEnablement.ENABLED, channel.getState());
+        assertEquals(4096, channel.getSubBufferSize());
+        assertEquals(0, channel.getSwitchTimer());
+
+        // ------------------------------------------------------------------------
+        // Verify event info (UST global, channel0)
+        // ------------------------------------------------------------------------
+        ustEvents = channel.getChildren();
+        assertEquals(4, ustEvents.length);
+
+        event = (TraceEventComponent) ustEvents[0];
+        assertEquals("ust_tests_hello:tptest_sighandler", event.getName());
+        assertEquals(TraceLogLevel.TRACE_DEBUG_LINE, event.getLogLevel());
+        assertEquals(LogLevelType.LOGLEVEL_ONLY, event.getLogLevelType());
+        assertEquals(LogLevelType.LOGLEVEL_ONLY.getShortName(), event.getLogLevelType().getShortName());
+        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
+        assertEquals(TraceEnablement.DISABLED, event.getState());
+
+        event = (TraceEventComponent) ustEvents[1];
+        assertEquals("ust_tests_hello:tptest_sighandler1", event.getName());
+        assertEquals(TraceLogLevel.TRACE_INFO, event.getLogLevel());
+        assertEquals(LogLevelType.LOGLEVEL, event.getLogLevelType());
+        assertEquals(LogLevelType.LOGLEVEL.getShortName(), event.getLogLevelType().getShortName());
+        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
+        assertEquals(TraceEnablement.DISABLED, event.getState());
+
+        event = (TraceEventComponent) ustEvents[2];
+        assertEquals("ust_tests_hello:tptest_sighandler2", event.getName());
+        assertEquals(TraceLogLevel.TRACE_DEBUG_SYSTEM, event.getLogLevel());
+        assertEquals(LogLevelType.LOGLEVEL_NONE, event.getLogLevelType());
+        assertEquals(LogLevelType.LOGLEVEL_NONE.getShortName(), event.getLogLevelType().getShortName());
+        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
+        assertEquals(TraceEnablement.DISABLED, event.getState());
+
+        event = (TraceEventComponent) ustEvents[3];
+        assertEquals("*", event.getName());
+        assertEquals(TraceLogLevel.LEVEL_UNKNOWN, event.getLogLevel());
+        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
+        assertEquals(TraceEnablement.ENABLED, event.getState());
+
+        // verify getters and setters
+        verifyEventGettersSetters(event);
+
+        // disconnect
+        node.disconnect();
+        assertEquals(TargetNodeState.DISCONNECTED, node.getTargetNodeState());
+        assertNotNull(node.getImage());
+        assertNotSame(connectedImage, node.getImage());
+
+        node.getParent().removeChild(node);
+    }
+
+    private static void verifySessionGetterSetters(TraceSessionComponent session) {
+        // save original values
+        String name = session.getName();
+        String origPath = session.getSessionPath();
+        TraceSessionState origState = session.getSessionState();
+
+        // test cases
+        session.setName("newName");
+        assertEquals("newName", session.getName());
+
+        session.setSessionPath("/home/user/tmp");
+        assertEquals("/home/user/tmp", session.getSessionPath());
+
+        session.setSessionState(TraceSessionState.INACTIVE);
+        assertEquals(TraceSessionState.INACTIVE, session.getSessionState());
+        Image inactiveImage = session.getImage();
+        assertNotNull(inactiveImage);
+
+        session.setSessionState("active");
+        assertEquals(TraceSessionState.ACTIVE, session.getSessionState());
+
+        Image activeImage = session.getImage();
+        assertNotNull(activeImage);
+        assertNotSame(activeImage, inactiveImage);
+
+        ITraceControlComponent[] children = session.getChildren();
+        TraceDomainComponent[] domains = session.getDomains();
+
+        assertEquals(children.length, domains.length);
+
+        for (int i = 0; i < domains.length; i++) {
+            assertEquals(domains[i].getName(), children[i].getName());
+        }
+
+        // restore original values
+        session.setName(name);
+        session.setSessionPath(origPath);
+        session.setSessionState(origState);
+    }
+
+    private static void verifyDomainGettersSetters(TraceDomainComponent domain) {
+        // save original values
+        boolean isKernel = domain.isKernel();
+
+        domain.setIsKernel(false);
+        assertFalse(domain.isKernel());
+        domain.setIsKernel(true);
+        assertTrue(domain.isKernel());
+
+        ITraceControlComponent[] children = domain.getChildren();
+        TraceChannelComponent[] channels = domain.getChannels();
+
+        assertEquals(children.length, channels.length);
+
+        for (int i = 0; i < channels.length; i++) {
+            assertEquals(channels[i].getName(), children[i].getName());
+        }
+
+        String nodeName = domain.getTargetNode().getName();
+        assertEquals(TARGET_NODE_NAME, nodeName);
+
+        // restore original values
+        domain.setIsKernel(isKernel);
+    }
+
+    private static void verifyBaseEventGettersSetters(BaseEventComponent event) {
+        // save original values
+        String name =  event.getName();
+        TraceLogLevel level = event.getLogLevel();
+        TraceEventType type = event.getEventType();
+
+        // test cases
+        event.setName("newName");
+        assertEquals("newName", event.getName());
+
+        event.setLogLevel(TraceLogLevel.TRACE_INFO);
+        assertEquals(TraceLogLevel.TRACE_INFO, event.getLogLevel());
+        event.setLogLevel("TRACE_ALERT");
+        assertEquals(TraceLogLevel.TRACE_ALERT, event.getLogLevel());
+
+        event.setEventType(TraceEventType.UNKNOWN);
+        assertEquals(TraceEventType.UNKNOWN, event.getEventType());
+        event.setEventType("tracepoint");
+        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
+
+        // restore original values
+        event.setName(name);
+        event.setLogLevel(level);
+        event.setEventType(type);
+    }
+
+    private static void verifyEventGettersSetters(TraceEventComponent event) {
+        // save original values
+        String name =  event.getName();
+        TraceLogLevel level = event.getLogLevel();
+        TraceEventType type = event.getEventType();
+        TraceEnablement state = event.getState();
+
+        // test cases
+        event.setName("newName");
+        assertEquals("newName", event.getName());
+
+        event.setLogLevel(TraceLogLevel.TRACE_INFO);
+        assertEquals(TraceLogLevel.TRACE_INFO, event.getLogLevel());
+        event.setLogLevel("TRACE_ALERT");
+        assertEquals(TraceLogLevel.TRACE_ALERT, event.getLogLevel());
+
+        event.setEventType(TraceEventType.UNKNOWN);
+        assertEquals(TraceEventType.UNKNOWN, event.getEventType());
+        event.setEventType("tracepoint");
+        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
+
+        event.setState("disabled");
+        assertEquals(TraceEnablement.DISABLED, event.getState());
+
+        Image disabledImage = event.getImage();
+        assertNotNull(disabledImage);
+
+        event.setState(TraceEnablement.ENABLED);
+        assertEquals(TraceEnablement.ENABLED, event.getState());
+
+        Image enabledImage = event.getImage();
+        assertNotNull(enabledImage);
+        assertNotSame(enabledImage, disabledImage);
+
+        // restore original values
+        event.setName(name);
+        event.setLogLevel(level);
+        event.setEventType(type);
+        event.setState(state);
+    }
+
+    private static void verifyProbeEventGettersSetters(TraceProbeEventComponent event) {
+        // save original values
+        String address = event.getAddress();
+        String offset = event.getOffset();
+        String symbol = event.getSymbol();
+
+        // test cases
+        event.setAddress("0xffff1234");
+        assertEquals("0xffff1234", event.getAddress());
+
+        event.setOffset("0x1234");
+        assertEquals("0x1234", event.getOffset());
+
+        event.setSymbol("init");
+        assertEquals("init", event.getSymbol());
+
+        // restore original values
+        event.setAddress(address);
+        event.setOffset(offset);
+        event.setSymbol(symbol);
+    }
+
+    private static void verifyChannelGettersSetters(TraceChannelComponent channel) {
+        // save original values
+        String name = channel.getName();
+        int nbSubBuffers = channel.getNumberOfSubBuffers();
+        TraceChannelOutputType type = channel.getOutputType();
+        boolean mode = channel.isOverwriteMode();
+        long readTimer = channel.getReadTimer();
+        TraceEnablement state =  channel.getState();
+        long subBufferSize = channel.getSubBufferSize();
+        long switchTimer = channel.getSwitchTimer();
+
+        // test cases
+        channel.setName("newName");
+        assertEquals("newName", channel.getName());
+
+        channel.setNumberOfSubBuffers(2);
+        assertEquals(2, channel.getNumberOfSubBuffers());
+
+        channel.setOutputType("splice()");
+        assertEquals("splice()", channel.getOutputType().getInName());
+        assertEquals(TraceChannelOutputType.SPLICE, channel.getOutputType());
+
+        channel.setOverwriteMode(false);
+        assertEquals(false, channel.isOverwriteMode());
+
+        channel.setReadTimer(250);
+        assertEquals(250, channel.getReadTimer());
+
+        channel.setState("enabled");
+        assertEquals(TraceEnablement.ENABLED, channel.getState());
+
+        Image enabledImage = channel.getImage();
+        assertNotNull(enabledImage);
+        channel.setState(TraceEnablement.DISABLED);
+        assertEquals(TraceEnablement.DISABLED, channel.getState());
+
+        Image disabledImage = channel.getImage();
+        assertNotNull(disabledImage);
+        assertNotSame(enabledImage, disabledImage);
+
+        channel.setSubBufferSize(1024);
+        assertEquals(1024, channel.getSubBufferSize());
+
+        channel.setSwitchTimer(1000);
+        assertEquals(1000, channel.getSwitchTimer());
+
+        // restore original values
+        channel.setName(name);
+        channel.setNumberOfSubBuffers(nbSubBuffers);
+        channel.setOutputType(type);
+        channel.setOverwriteMode(mode);
+        channel.setReadTimer(readTimer);
+        channel.setState(state);
+        channel.setSubBufferSize(subBufferSize);
+        channel.setSwitchTimer(switchTimer);
+    }
+
+    private static void verifyUstProviderGettersSetters(UstProviderComponent ustProvider) {
+        // save original values
+        String name = ustProvider.getName();
+        int pid = ustProvider.getPid();
+
+        // test cases
+        ustProvider.setName("newName");
+        assertEquals("newName", ustProvider.getName());
+
+        ustProvider.setPid(9876);
+        assertEquals(9876, ustProvider.getPid());
+
+        // restore original values
+        ustProvider.setName(name);
+        ustProvider.setPid(pid);
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlUstProviderTests.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlUstProviderTests.java
new file mode 100644 (file)
index 0000000..47a878c
--- /dev/null
@@ -0,0 +1,294 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2015 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Alexandre Montplaisir - Port to JUnit4
+ *   Markus Schorn - Bug 448058: Use org.eclipse.remote in favor of RSE
+ **********************************************************************/
+
+package org.eclipse.tracecompass.lttng2.control.ui.tests.model.component;
+
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertNotNull;
+import static org.junit.Assert.assertTrue;
+
+import java.io.File;
+import java.net.URL;
+
+import org.eclipse.core.runtime.FileLocator;
+import org.eclipse.core.runtime.Path;
+import org.eclipse.jdt.annotation.NonNull;
+import org.eclipse.remote.core.IRemoteConnection;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TargetNodeState;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceChannelOutputType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEnablement;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEventType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
+import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.CreateSessionDialogStub;
+import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.DestroyConfirmDialogStub;
+import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.EnableChannelDialogStub;
+import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.GetEventInfoDialogStub;
+import org.eclipse.tracecompass.internal.lttng2.control.stubs.service.TestRemoteSystemProxy;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.TraceControlDialogFactory;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.BaseEventComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.KernelProviderComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceEventComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.UstProviderComponent;
+import org.eclipse.tracecompass.tmf.remote.core.proxy.TmfRemoteConnectionFactory;
+import org.junit.After;
+import org.junit.Before;
+import org.junit.Test;
+import org.osgi.framework.FrameworkUtil;
+
+/**
+ * The class <code>TraceControlUstProviderTests</code> contains UST provider
+ * handling test cases.
+ */
+public class TraceControlUstProviderTests {
+
+    // ------------------------------------------------------------------------
+    // Constants
+    // ------------------------------------------------------------------------
+
+    private static final String TEST_STREAM = "CreateTreeTest.cfg";
+    private static final String SCEN_SCENARIO2_TEST = "Scenario2";
+
+    // ------------------------------------------------------------------------
+    // Test data
+    // ------------------------------------------------------------------------
+    private IRemoteConnection fHost = TmfRemoteConnectionFactory.getLocalConnection();
+    private TraceControlTestFacility fFacility;
+    private @NonNull TestRemoteSystemProxy fProxy = new TestRemoteSystemProxy(fHost);
+    private String fTestFile;
+
+    // ------------------------------------------------------------------------
+    // Housekeeping
+    // ------------------------------------------------------------------------
+
+    /**
+     * Perform pre-test initialization.
+     *
+     * @throws Exception
+     *         if the initialization fails for some reason
+     */
+    @Before
+    public void setUp() throws Exception {
+        fFacility = TraceControlTestFacility.getInstance();
+        fFacility.init();
+        fProxy = new TestRemoteSystemProxy(fHost);
+        URL location = FileLocator.find(FrameworkUtil.getBundle(this.getClass()), new Path(TraceControlTestFacility.DIRECTORY + File.separator + TEST_STREAM), null);
+        File testfile = new File(FileLocator.toFileURL(location).toURI());
+        fTestFile = testfile.getAbsolutePath();
+    }
+
+    /**
+     * Perform post-test clean-up.
+     */
+    @After
+    public void tearDown() {
+        fFacility.waitForJobs();
+        fFacility.dispose();
+    }
+
+    /**
+     * Run the TraceControlComponent.
+     *
+     * @throws Exception
+     *             This will fail the test
+     */
+    @Test
+    public void testUstProviderTree() throws Exception {
+
+        fProxy.setTestFile(fTestFile);
+        fProxy.setScenario(TraceControlTestFacility.SCEN_INIT_TEST);
+
+        ITraceControlComponent root = fFacility.getControlView().getTraceControlRoot();
+
+        TargetNodeComponent node = new TargetNodeComponent("myNode", root, fProxy);
+        root.addChild(node);
+
+        fFacility.waitForJobs();
+
+        fFacility.executeCommand(node, "connect");
+
+        int i = 0;
+        while ((i < 10) && (node.getTargetNodeState() != TargetNodeState.CONNECTED)) {
+            i++;
+            fFacility.delay(TraceControlTestFacility.GUI_REFESH_DELAY);
+        }
+
+        // Verify that node is connected
+        assertEquals(TargetNodeState.CONNECTED, node.getTargetNodeState());
+
+        // Get provider groups
+        ITraceControlComponent[] groups = node.getChildren();
+        assertNotNull(groups);
+        assertEquals(2, groups.length);
+
+        // Get kernel provider
+        ITraceControlComponent[] providers = groups[0].getChildren();
+        KernelProviderComponent kernelProvider = (KernelProviderComponent) providers[0];
+
+        // Get kernel provider events and select 2 events
+        ITraceControlComponent[] events = kernelProvider.getChildren();
+        assertNotNull(events);
+        assertEquals(3, events.length);
+
+        BaseEventComponent baseEventInfo0 = (BaseEventComponent) events[0];
+        BaseEventComponent baseEventInfo1  = (BaseEventComponent) events[1];
+
+        // Initialize dialog implementations for command execution
+        TraceControlDialogFactory.getInstance().setCreateSessionDialog(new CreateSessionDialogStub());
+        TraceControlDialogFactory.getInstance().setGetEventInfoDialog(new GetEventInfoDialogStub());
+        TraceControlDialogFactory.getInstance().setConfirmDialog(new DestroyConfirmDialogStub());
+
+        // ------------------------------------------------------------------------
+        // Create session
+        // ------------------------------------------------------------------------
+        // Initialize session handling scenario
+        fProxy.setScenario(TraceControlTestFacility.SCEN_SCENARIO_SESSION_HANDLING_WITH_PATH);
+
+        CreateSessionDialogStub sessionDialogStub = new CreateSessionDialogStub();
+        sessionDialogStub.setSessionPath("/home/user/temp");
+        TraceControlDialogFactory.getInstance().setCreateSessionDialog(sessionDialogStub);
+
+        TraceSessionComponent session = fFacility.createSession(groups[1]);
+
+        // Verify that session was created
+        assertNotNull(session);
+        assertEquals("mysession", session.getName());
+        assertEquals("/home/user/temp", session.getSessionPath());
+        assertEquals(TraceSessionState.INACTIVE, session.getSessionState());
+
+        // ------------------------------------------------------------------------
+        // Enable Channel on UST global domain
+        // ------------------------------------------------------------------------
+        fProxy.setScenario(SCEN_SCENARIO2_TEST);
+        EnableChannelDialogStub channelDialogStub = new EnableChannelDialogStub();
+        channelDialogStub.setIsKernel(false);
+        channelDialogStub.getChannelInfo().setOverwriteMode(false);
+        channelDialogStub.getChannelInfo().setSwitchTimer(200);
+        channelDialogStub.getChannelInfo().setReadTimer(100);
+        channelDialogStub.getChannelInfo().setNumberOfSubBuffers(2);
+        TraceControlDialogFactory.getInstance().setEnableChannelDialog(channelDialogStub);
+
+        fFacility.executeCommand(session, "enableChannelOnSession");
+
+        // Verify that UST domain was created
+        ITraceControlComponent[] domains = session.getChildren();
+        assertNotNull(domains);
+        assertEquals(1, domains.length);
+
+        assertEquals("UST global", domains[0].getName());
+
+        // Verify that channel was created with correct data
+        ITraceControlComponent[]channels =  domains[0].getChildren();
+        assertNotNull(channels);
+        assertEquals(1, channels.length);
+
+        assertTrue(channels[0] instanceof TraceChannelComponent);
+        TraceChannelComponent channel = (TraceChannelComponent) channels[0];
+        assertEquals("mychannel", channel.getName());
+        assertEquals(2, channel.getNumberOfSubBuffers());
+        assertEquals("mmap()", channel.getOutputType().getInName());
+        assertEquals(TraceChannelOutputType.MMAP, channel.getOutputType());
+        assertEquals(false, channel.isOverwriteMode());
+        assertEquals(100, channel.getReadTimer());
+        assertEquals(TraceEnablement.ENABLED, channel.getState());
+        assertEquals(16384, channel.getSubBufferSize());
+        assertEquals(200, channel.getSwitchTimer());
+
+        // ------------------------------------------------------------------------
+        // Enable event on default channel on created session above
+        // ------------------------------------------------------------------------
+        // Get first UST provider
+        UstProviderComponent ustProvider = (UstProviderComponent) providers[1];
+        assertEquals("/home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello [PID=9379]", ustProvider.getName());
+        assertEquals(9379, ustProvider.getPid());
+
+        // Get events
+        events = ustProvider.getChildren();
+        assertNotNull(events);
+        assertEquals(2, events.length);
+
+        baseEventInfo0 = (BaseEventComponent) events[0];
+        baseEventInfo1 = (BaseEventComponent) events[1];
+
+        ITraceControlComponent[] ustSelection =  { baseEventInfo0, baseEventInfo1 };
+
+        fFacility.executeCommand(ustSelection, "assign.event");
+
+        // verify that events were created under the channel
+        // Note that domain and channel has to be re-read because the tree is re-created
+
+        domains = session.getChildren();
+
+        // Verify that channel was created with correct data
+        channels =  domains[0].getChildren();
+
+        ITraceControlComponent[] ustEvents = channels[0].getChildren();
+        assertEquals(2, ustEvents.length);
+
+        TraceEventComponent event = (TraceEventComponent) ustEvents[0];
+        assertEquals("ust_tests_hello:tptest_sighandler", event.getName());
+        assertEquals(TraceLogLevel.LEVEL_UNKNOWN, event.getLogLevel());
+        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
+        assertEquals(TraceEnablement.ENABLED, event.getState());
+
+        event = (TraceEventComponent) ustEvents[1];
+        assertEquals("ust_tests_hello:tptest", ustEvents[1].getName());
+        assertEquals(TraceLogLevel.LEVEL_UNKNOWN, event.getLogLevel());
+        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
+        assertEquals(TraceEnablement.ENABLED, event.getState());
+
+        // ------------------------------------------------------------------------
+        // Disable event components
+        // ------------------------------------------------------------------------
+        fFacility.executeCommand(event, "disableEvent");
+
+        assertEquals(TraceEnablement.DISABLED, event.getState());
+
+        // ------------------------------------------------------------------------
+        // Enable event component
+        // ------------------------------------------------------------------------
+        fFacility.executeCommand(event, "enableEvent");
+
+        // Verify event state
+        assertEquals(TraceEnablement.ENABLED, event.getState());
+
+        // ------------------------------------------------------------------------
+        // Destroy session
+        // ------------------------------------------------------------------------
+
+        // Initialize session handling scenario
+        fProxy.setScenario(TraceControlTestFacility.SCEN_SCENARIO_SESSION_HANDLING);
+
+        fFacility.destroySession(session);
+
+        // Verify that no more session components exist
+        assertEquals(0, groups[1].getChildren().length);
+
+        //-------------------------------------------------------------------------
+        // Disconnect node
+        //-------------------------------------------------------------------------
+        fFacility.executeCommand(node, "disconnect");
+        assertEquals(TargetNodeState.DISCONNECTED, node.getTargetNodeState());
+
+        //-------------------------------------------------------------------------
+        // Delete node
+        //-------------------------------------------------------------------------
+        fFacility.executeCommand(node, "delete");
+        assertEquals(0,fFacility.getControlView().getTraceControlRoot().getChildren().length);
+   }
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlUstSessionTests.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlUstSessionTests.java
new file mode 100644 (file)
index 0000000..00e929e
--- /dev/null
@@ -0,0 +1,545 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2015 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Alexandre Montplaisir - Port to JUnit4
+ *   Markus Schorn - Bug 448058: Use org.eclipse.remote in favor of RSE
+ **********************************************************************/
+
+package org.eclipse.tracecompass.lttng2.control.ui.tests.model.component;
+
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertNotNull;
+import static org.junit.Assert.assertTrue;
+
+import java.io.File;
+import java.net.URL;
+import java.util.ArrayList;
+import java.util.List;
+
+import org.eclipse.core.runtime.FileLocator;
+import org.eclipse.core.runtime.Path;
+import org.eclipse.jdt.annotation.NonNull;
+import org.eclipse.remote.core.IRemoteConnection;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.LogLevelType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TargetNodeState;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceChannelOutputType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEnablement;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEventType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.BufferType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.ChannelInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.CreateSessionDialogStub;
+import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.DestroyConfirmDialogStub;
+import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.EnableChannelDialogStub;
+import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.EnableEventsDialogStub;
+import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.GetEventInfoDialogStub;
+import org.eclipse.tracecompass.internal.lttng2.control.stubs.service.TestRemoteSystemProxy;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.TraceControlDialogFactory;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceEventComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
+import org.eclipse.tracecompass.tmf.remote.core.proxy.TmfRemoteConnectionFactory;
+import org.junit.After;
+import org.junit.Before;
+import org.junit.Test;
+import org.osgi.framework.FrameworkUtil;
+
+/**
+ * The class <code>TraceControlUstSessionTests</code> contains UST
+ * session/channel/event handling test cases.
+ */
+public class TraceControlUstSessionTests {
+
+    // ------------------------------------------------------------------------
+    // Constants
+    // ------------------------------------------------------------------------
+
+    private static final String TEST_STREAM = "CreateTreeTest.cfg";
+    private static final String SCEN_SCENARIO4_TEST = "Scenario4";
+
+    // ------------------------------------------------------------------------
+    // Test data
+    // ------------------------------------------------------------------------
+    private IRemoteConnection fHost = TmfRemoteConnectionFactory.getLocalConnection();
+    private TraceControlTestFacility fFacility;
+    private @NonNull TestRemoteSystemProxy fProxy = new TestRemoteSystemProxy(fHost);
+    private String fTestFile;
+
+    // ------------------------------------------------------------------------
+    // Housekeeping
+    // ------------------------------------------------------------------------
+
+    /**
+     * Perform pre-test initialization.
+     *
+     * @throws Exception
+     *         if the initialization fails for some reason
+     */
+    @Before
+    public void setUp() throws Exception {
+        fFacility = TraceControlTestFacility.getInstance();
+        fFacility.init();
+        URL location = FileLocator.find(FrameworkUtil.getBundle(this.getClass()), new Path(TraceControlTestFacility.DIRECTORY + File.separator + TEST_STREAM), null);
+        File testfile = new File(FileLocator.toFileURL(location).toURI());
+        fTestFile = testfile.getAbsolutePath();
+    }
+
+    /**
+     * Perform post-test clean-up.
+     */
+    @After
+    public void tearDown() {
+        fFacility.waitForJobs();
+        fFacility.dispose();
+    }
+
+    /**
+     * Run the TraceControlComponent.
+     *
+     * @throws Exception
+     *             This will fail the test
+     */
+    @Test
+    public void testTraceSessionTree() throws Exception {
+
+        fProxy.setTestFile(fTestFile);
+        fProxy.setScenario(TraceControlTestFacility.SCEN_INIT_TEST);
+
+        ITraceControlComponent root = fFacility.getControlView().getTraceControlRoot();
+
+        TargetNodeComponent node = new TargetNodeComponent("myNode", root, fProxy);
+
+        root.addChild(node);
+        fFacility.waitForJobs();
+
+        fFacility.executeCommand(node, "connect");
+        int i = 0;
+        while ((i < 10) && (node.getTargetNodeState() != TargetNodeState.CONNECTED)) {
+            i++;
+            fFacility.delay(TraceControlTestFacility.GUI_REFESH_DELAY);
+        }
+
+        // Get provider groups
+        ITraceControlComponent[] groups = node.getChildren();
+        assertNotNull(groups);
+        assertEquals(2, groups.length);
+
+        // Initialize dialog implementations for command execution
+        TraceControlDialogFactory.getInstance().setCreateSessionDialog(new CreateSessionDialogStub());
+        TraceControlDialogFactory.getInstance().setGetEventInfoDialog(new GetEventInfoDialogStub());
+        TraceControlDialogFactory.getInstance().setConfirmDialog(new DestroyConfirmDialogStub());
+
+        // Initialize session handling scenario
+        fProxy.setScenario(TraceControlTestFacility.SCEN_SCENARIO_SESSION_HANDLING);
+
+        // ------------------------------------------------------------------------
+        // Create session
+        // ------------------------------------------------------------------------
+        TraceSessionComponent session = fFacility.createSession(groups[1]);
+
+        // Verify that session was created
+        assertNotNull(session);
+        assertEquals("mysession", session.getName());
+        assertEquals("/home/user/lttng-traces/mysession-20120314-132824", session.getSessionPath());
+        assertEquals(TraceSessionState.INACTIVE, session.getSessionState());
+
+        // Initialize scenario
+        fProxy.setScenario(SCEN_SCENARIO4_TEST);
+
+        // ------------------------------------------------------------------------
+        // Enable default channel on created session above
+        // ------------------------------------------------------------------------
+        EnableChannelDialogStub channelStub = new EnableChannelDialogStub();
+        channelStub.setIsKernel(false);
+        TraceControlDialogFactory.getInstance().setEnableChannelDialog(channelStub);
+
+        fFacility.executeCommand(session, "enableChannelOnSession");
+
+        // Verify that Kernel domain was created
+        ITraceControlComponent[] domains = session.getChildren();
+        assertNotNull(domains);
+        assertEquals(1, domains.length);
+
+        assertEquals("UST global", domains[0].getName());
+        assertEquals("Domain buffer Type", BufferType.BUFFER_TYPE_UNKNOWN, ((TraceDomainComponent)domains[0]).getBufferType());
+
+        // Verify that channel was created with correct data
+        ITraceControlComponent[] channels =  domains[0].getChildren();
+        assertNotNull(channels);
+        assertEquals(1, channels.length);
+
+        assertTrue(channels[0] instanceof TraceChannelComponent);
+        TraceChannelComponent channel = (TraceChannelComponent) channels[0];
+        assertEquals("mychannel", channel.getName());
+        assertEquals(4, channel.getNumberOfSubBuffers());
+        assertEquals("mmap()", channel.getOutputType().getInName());
+        assertEquals(TraceChannelOutputType.MMAP, channel.getOutputType());
+        assertEquals(true, channel.isOverwriteMode());
+        assertEquals(200, channel.getReadTimer());
+        assertEquals(TraceEnablement.ENABLED, channel.getState());
+        assertEquals(16384, channel.getSubBufferSize());
+        assertEquals(100, channel.getSwitchTimer());
+
+        // ------------------------------------------------------------------------
+        // Enable channel on domain
+        // ------------------------------------------------------------------------
+        ChannelInfo info = (ChannelInfo)channelStub.getChannelInfo();
+        info.setName("mychannel2");
+        info.setOverwriteMode(false);
+        info.setSubBufferSize(32768);
+        info.setNumberOfSubBuffers(2);
+        info.setSwitchTimer(100);
+        info.setReadTimer(200);
+        channelStub.setChannelInfo(info);
+
+        fFacility.executeCommand(domains[0], "enableChannelOnDomain");
+
+        // Get Kernel domain component instance
+        domains = session.getChildren();
+        assertNotNull(domains);
+        assertEquals(1, domains.length);
+
+        // Verify that channel was created with correct data
+        channels =  domains[0].getChildren();
+        assertNotNull(channels);
+        assertEquals(2, channels.length);
+
+        assertTrue(channels[1] instanceof TraceChannelComponent);
+        channel = (TraceChannelComponent) channels[1];
+        assertEquals("mychannel2", channel.getName());
+        assertEquals(2, channel.getNumberOfSubBuffers());
+        assertEquals("mmap()", channel.getOutputType().getInName());
+        assertEquals(TraceChannelOutputType.MMAP, channel.getOutputType());
+        assertEquals(false, channel.isOverwriteMode());
+        assertEquals(200, channel.getReadTimer());
+        assertEquals(TraceEnablement.ENABLED, channel.getState());
+        assertEquals(32768, channel.getSubBufferSize());
+        assertEquals(100, channel.getSwitchTimer());
+
+        // ------------------------------------------------------------------------
+        // Enable event (tracepoint) on session and default channel
+        // ------------------------------------------------------------------------
+        EnableEventsDialogStub eventsDialogStub = new EnableEventsDialogStub();
+        eventsDialogStub.setIsTracePoints(true);
+        List<String> events = new ArrayList<>();
+        events.add("ust_tests_hello:tptest_sighandler");
+        eventsDialogStub.setNames(events);
+        eventsDialogStub.setIsKernel(false);
+        TraceControlDialogFactory.getInstance().setEnableEventsDialog(eventsDialogStub);
+
+        fFacility.executeCommand(session, "enableEventOnSession");
+
+        // Get Kernel domain component instance
+        domains = session.getChildren();
+        assertNotNull(domains);
+        assertEquals(1, domains.length);
+
+        // Verify that channel was created with correct data
+        channels =  domains[0].getChildren();
+        assertNotNull(channels);
+        assertEquals(3, channels.length);
+
+        assertTrue(channels[2] instanceof TraceChannelComponent);
+        channel = (TraceChannelComponent) channels[2];
+        assertEquals("channel0", channel.getName());
+        // No need to check parameters of default channel because that has been done in other tests
+
+        ITraceControlComponent[] channel0Events = channel.getChildren();
+        assertEquals(1, channel0Events.length);
+
+        assertTrue(channel0Events[0] instanceof TraceEventComponent);
+
+        TraceEventComponent event = (TraceEventComponent) channel0Events[0];
+        assertEquals("ust_tests_hello:tptest_sighandler", event.getName());
+        assertEquals(TraceLogLevel.LEVEL_UNKNOWN, event.getLogLevel()); // TODO
+        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
+        assertEquals(TraceEnablement.ENABLED, event.getState());
+
+        // ------------------------------------------------------------------------
+        // Enable event (tracepoint) on domain and default channel
+        // ------------------------------------------------------------------------
+        events.clear();
+        events.add("ust_tests_hello:tptest");
+        eventsDialogStub.setNames(events);
+
+        fFacility.executeCommand(domains[0], "enableEventOnDomain");
+
+        // Get Kernel domain component instance
+        domains = session.getChildren();
+        assertNotNull(domains);
+        assertEquals(1, domains.length);
+
+        // Verify that channel was created with correct data
+        channels =  domains[0].getChildren();
+        channel = (TraceChannelComponent) channels[2];
+        // No need to check parameters of default channel because that has been done in other tests
+
+        channel0Events = channel.getChildren();
+        assertEquals(2, channel0Events.length);
+
+        assertTrue(channel0Events[1] instanceof TraceEventComponent);
+
+        event = (TraceEventComponent) channel0Events[1];
+        assertEquals("ust_tests_hello:tptest", event.getName());
+        assertEquals(TraceLogLevel.LEVEL_UNKNOWN, event.getLogLevel()); // TODO
+        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
+        assertEquals(TraceEnablement.ENABLED, event.getState());
+
+        // ------------------------------------------------------------------------
+        // Enable event (all tracepoints) on specific channel
+        // ------------------------------------------------------------------------
+        events.clear();
+        eventsDialogStub.setNames(events);
+        eventsDialogStub.setIsAllTracePoints(true);
+
+        fFacility.executeCommand(channels[1], "enableEventOnChannel");
+
+        // Get Kernel domain component instance
+        domains = session.getChildren();
+        assertNotNull(domains);
+        assertEquals(1, domains.length);
+
+        // Verify that channel was created with correct data
+        channels =  domains[0].getChildren();
+        channel = (TraceChannelComponent) channels[1];
+        // No need to check parameters of default channel because that has been done in other tests
+
+        channel = (TraceChannelComponent) channels[1];
+
+        channel0Events = channel.getChildren();
+        assertEquals(1, channel0Events.length);
+
+        assertTrue(channel0Events[0] instanceof TraceEventComponent);
+
+        event = (TraceEventComponent) channel0Events[0];
+        assertEquals("*", event.getName());
+        assertEquals(TraceLogLevel.LEVEL_UNKNOWN, event.getLogLevel());
+        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
+        assertEquals(TraceEnablement.ENABLED, event.getState());
+
+        // ------------------------------------------------------------------------
+        // Enable event (wildcard) on specific channel
+        // ------------------------------------------------------------------------
+        events.clear();
+        eventsDialogStub.setIsTracePoints(false);
+        eventsDialogStub.setIsAllTracePoints(false);
+        eventsDialogStub.setIsWildcard(true);
+        eventsDialogStub.setWildcard("ust*");
+
+        fFacility.executeCommand(channels[0], "enableEventOnChannel");
+
+        // Get Kernel domain component instance
+        domains = session.getChildren();
+        assertNotNull(domains);
+        assertEquals(1, domains.length);
+
+        // Verify that channel was created with correct data
+        channels =  domains[0].getChildren();
+        channel = (TraceChannelComponent) channels[0];
+        // No need to check parameters of default channel because that has been done in other tests
+
+        channel0Events = channel.getChildren();
+        assertEquals(1, channel0Events.length);
+
+        assertTrue(channel0Events[0] instanceof TraceEventComponent);
+
+        event = (TraceEventComponent) channel0Events[0];
+        assertEquals("ust*", event.getName());
+        assertEquals(TraceLogLevel.LEVEL_UNKNOWN, event.getLogLevel());
+        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
+        assertEquals(TraceEnablement.ENABLED, event.getState());
+
+        // ------------------------------------------------------------------------
+        // Enable event (wildcard) on domain
+        // ------------------------------------------------------------------------
+        events.clear();
+        eventsDialogStub.setIsTracePoints(false);
+        eventsDialogStub.setIsAllTracePoints(false);
+        eventsDialogStub.setIsWildcard(true);
+        eventsDialogStub.setWildcard("ust*");
+
+        fFacility.executeCommand(domains[0], "enableEventOnDomain");
+
+        // Get Kernel domain component instance
+        domains = session.getChildren();
+        assertNotNull(domains);
+        assertEquals(1, domains.length);
+
+        // Verify that channel was created with correct data
+        channels =  domains[0].getChildren();
+        channel = (TraceChannelComponent) channels[0];
+        // No need to check parameters of default channel because that has been done in other tests
+
+        channel0Events = channel.getChildren();
+        assertEquals(1, channel0Events.length);
+
+        assertTrue(channel0Events[0] instanceof TraceEventComponent);
+
+        event = (TraceEventComponent) channel0Events[0];
+        assertEquals("ust*", event.getName());
+        assertEquals(TraceLogLevel.LEVEL_UNKNOWN, event.getLogLevel());
+        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
+        assertEquals(TraceEnablement.ENABLED, event.getState());
+
+        // ------------------------------------------------------------------------
+        // Enable event (wildcard) on session
+        // ------------------------------------------------------------------------
+        events.clear();
+        eventsDialogStub.setIsTracePoints(false);
+        eventsDialogStub.setIsAllTracePoints(false);
+        eventsDialogStub.setIsWildcard(true);
+        eventsDialogStub.setWildcard("ust*");
+
+        fFacility.executeCommand(domains[0], "enableEventOnDomain");
+
+        // Get Kernel domain component instance
+        domains = session.getChildren();
+        assertNotNull(domains);
+        assertEquals(1, domains.length);
+
+        // Verify that channel was created with correct data
+        channels =  domains[0].getChildren();
+        channel = (TraceChannelComponent) channels[2];
+        // No need to check parameters of default channel because that has been done in other tests
+
+        channel0Events = channel.getChildren();
+        assertEquals(4, channel0Events.length);
+
+        assertTrue(channel0Events[0] instanceof TraceEventComponent);
+
+        event = (TraceEventComponent) channel0Events[0];
+        assertEquals("u*", event.getName());
+        assertEquals(TraceLogLevel.LEVEL_UNKNOWN, event.getLogLevel());
+        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
+        assertEquals(TraceEnablement.ENABLED, event.getState());
+
+        // ------------------------------------------------------------------------
+        // Enable event (loglevel) on domain
+        // ------------------------------------------------------------------------
+        events.clear();
+        eventsDialogStub.setIsWildcard(false);
+        eventsDialogStub.setIsLogLevel(true);
+        eventsDialogStub.setLogLevelEventName("myevent1");
+        eventsDialogStub.setLogLevelType(LogLevelType.LOGLEVEL);
+        eventsDialogStub.setLogLevel(TraceLogLevel.TRACE_WARNING);
+
+        fFacility.executeCommand(domains[0], "enableEventOnDomain");
+
+        // Get Kernel domain component instance
+        domains = session.getChildren();
+        assertNotNull(domains);
+        assertEquals(1, domains.length);
+
+        // Verify that channel was created with correct data
+        channels =  domains[0].getChildren();
+        channel = (TraceChannelComponent) channels[2];
+        // No need to check parameters of default channel because that has been done in other tests
+
+        channel0Events = channel.getChildren();
+        assertEquals(5, channel0Events.length);
+
+        assertTrue(channel0Events[0] instanceof TraceEventComponent);
+
+        event = (TraceEventComponent) channel0Events[0];
+        assertEquals("myevent1", event.getName());
+        assertEquals(TraceLogLevel.TRACE_WARNING, event.getLogLevel());
+        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
+        assertEquals(TraceEnablement.ENABLED, event.getState());
+
+        // ------------------------------------------------------------------------
+        // Enable event (loglevel) on session
+        // ------------------------------------------------------------------------
+        eventsDialogStub.setLogLevelEventName("myevent2");
+        eventsDialogStub.setLogLevelType(LogLevelType.LOGLEVEL_ONLY);
+        eventsDialogStub.setLogLevel(TraceLogLevel.TRACE_DEBUG_FUNCTION);
+
+        fFacility.executeCommand(session, "enableEventOnSession");
+
+        // Get Kernel domain component instance
+        domains = session.getChildren();
+        assertNotNull(domains);
+        assertEquals(1, domains.length);
+
+        // Verify that channel was created with correct data
+        channels =  domains[0].getChildren();
+        channel = (TraceChannelComponent) channels[2];
+        // No need to check parameters of default channel because that has been done in other tests
+
+        channel0Events = channel.getChildren();
+        assertEquals(6, channel0Events.length);
+
+        assertTrue(channel0Events[0] instanceof TraceEventComponent);
+
+        event = (TraceEventComponent) channel0Events[0];
+        assertEquals("myevent2", event.getName());
+        assertEquals(TraceLogLevel.TRACE_DEBUG_FUNCTION, event.getLogLevel());
+        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
+        assertEquals(TraceEnablement.ENABLED, event.getState());
+
+        // ------------------------------------------------------------------------
+        // Enable event (loglevel) on channel
+        // ------------------------------------------------------------------------
+        eventsDialogStub.setLogLevelEventName("myevent0");
+        eventsDialogStub.setLogLevelType(LogLevelType.LOGLEVEL_ONLY);
+        eventsDialogStub.setLogLevel(TraceLogLevel.TRACE_DEBUG_FUNCTION);
+
+        fFacility.executeCommand(channels[0], "enableEventOnChannel");
+
+        // Get Kernel domain component instance
+        domains = session.getChildren();
+        assertNotNull(domains);
+        assertEquals(1, domains.length);
+
+        // Verify that channel was created with correct data
+        channels =  domains[0].getChildren();
+        channel = (TraceChannelComponent) channels[0];
+        // No need to check parameters of default channel because that has been done in other tests
+
+        channel0Events = channel.getChildren();
+        assertEquals(2, channel0Events.length);
+
+        assertTrue(channel0Events[0] instanceof TraceEventComponent);
+
+        event = (TraceEventComponent) channel0Events[0];
+        assertEquals("myevent0", event.getName());
+        assertEquals(TraceLogLevel.TRACE_DEBUG_FUNCTION, event.getLogLevel());
+        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
+        assertEquals(TraceEnablement.ENABLED, event.getState());
+
+        // ------------------------------------------------------------------------
+        // Destroy session
+        // ------------------------------------------------------------------------
+        // Initialize session handling scenario
+        fProxy.setScenario(TraceControlTestFacility.SCEN_SCENARIO_SESSION_HANDLING);
+
+        fFacility.destroySession(session);
+
+        // Verify that no more session components exist
+        assertEquals("Session components still exist.", 0, groups[1].getChildren().length);
+
+        //-------------------------------------------------------------------------
+        // Disconnect node
+        //-------------------------------------------------------------------------
+        fFacility.executeCommand(node, "disconnect");
+        assertEquals(TargetNodeState.DISCONNECTED, node.getTargetNodeState());
+
+        //-------------------------------------------------------------------------
+        // Delete node
+        //-------------------------------------------------------------------------
+
+        fFacility.executeCommand(node, "delete");
+
+        assertEquals("Node not deleted.", 0, fFacility.getControlView().getTraceControlRoot().getChildren().length);
+    }
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlUstSessionTests2.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlUstSessionTests2.java
new file mode 100644 (file)
index 0000000..b4b0d56
--- /dev/null
@@ -0,0 +1,305 @@
+/**********************************************************************
+ * Copyright (c) 2013, 2015 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Markus Schorn - Bug 448058: Use org.eclipse.remote in favor of RSE
+ **********************************************************************/
+
+package org.eclipse.tracecompass.lttng2.control.ui.tests.model.component;
+
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertNotNull;
+import static org.junit.Assert.assertTrue;
+
+import java.io.File;
+import java.net.URL;
+
+import org.eclipse.core.runtime.FileLocator;
+import org.eclipse.core.runtime.Path;
+import org.eclipse.jdt.annotation.NonNull;
+import org.eclipse.remote.core.IRemoteConnection;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TargetNodeState;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.BufferType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.ChannelInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.CreateSessionDialogStub;
+import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.DestroyConfirmDialogStub;
+import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.EnableChannelDialogStub;
+import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.GetEventInfoDialogStub;
+import org.eclipse.tracecompass.internal.lttng2.control.stubs.service.TestRemoteSystemProxy;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.TraceControlDialogFactory;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
+import org.eclipse.tracecompass.tmf.remote.core.proxy.TmfRemoteConnectionFactory;
+import org.junit.After;
+import org.junit.Before;
+import org.junit.Test;
+import org.osgi.framework.FrameworkUtil;
+
+/**
+ * The class <code>TraceControlUstSessionTests</code> contains UST
+ * session/channel/event handling test cases for LTTng 2.2.
+ */
+public class TraceControlUstSessionTests2 {
+
+    // ------------------------------------------------------------------------
+    // Constants
+    // ------------------------------------------------------------------------
+
+    private static final String TEST_STREAM = "CreateTreeTest2.cfg";
+    private static final String SCEN_SCEN_PER_UID_TEST = "ScenPerUidTest";
+    private static final String SCEN_SCEN_PER_PID_TEST = "ScenPerPidTest";
+    private static final String SCEN_SCEN_BUF_SIZE_TEST = "ScenBufSizeTest";
+
+    // ------------------------------------------------------------------------
+    // Test data
+    // ------------------------------------------------------------------------
+
+    private TraceControlTestFacility fFacility;
+    private IRemoteConnection fHost = TmfRemoteConnectionFactory.getLocalConnection();
+    private @NonNull TestRemoteSystemProxy fProxy = new TestRemoteSystemProxy(fHost);
+    private String fTestFile;
+
+    // ------------------------------------------------------------------------
+    // Housekeeping
+    // ------------------------------------------------------------------------
+
+    /**
+     * Perform pre-test initialization.
+     *
+     * @throws Exception
+     *         if the initialization fails for some reason
+     */
+    @Before
+    public void setUp() throws Exception {
+        fFacility = TraceControlTestFacility.getInstance();
+        fFacility.init();
+        URL location = FileLocator.find(FrameworkUtil.getBundle(this.getClass()), new Path(TraceControlTestFacility.DIRECTORY + File.separator + TEST_STREAM), null);
+        File testfile = new File(FileLocator.toFileURL(location).toURI());
+        fTestFile = testfile.getAbsolutePath();
+    }
+
+    /**
+     * Perform post-test clean-up.
+     */
+    @After
+    public void tearDown() {
+        fFacility.waitForJobs();
+        fFacility.dispose();
+    }
+
+    /**
+     * Run the TraceControlComponent.
+     *
+     * @throws Exception
+     *             This will fail the test
+     */
+    @Test
+    public void testTraceSessionTree() throws Exception {
+
+        fProxy.setTestFile(fTestFile);
+        fProxy.setScenario(TraceControlTestFacility.SCEN_INIT_TEST);
+
+        ITraceControlComponent root = fFacility.getControlView().getTraceControlRoot();
+
+        TargetNodeComponent node = new TargetNodeComponent("myNode", root, fProxy);
+
+        root.addChild(node);
+        fFacility.waitForJobs();
+
+        fFacility.executeCommand(node, "connect");
+        int i = 0;
+        while ((i < 10) && (node.getTargetNodeState() != TargetNodeState.CONNECTED)) {
+            i++;
+            fFacility.delay(TraceControlTestFacility.GUI_REFESH_DELAY);
+        }
+
+        // Get provider groups
+        ITraceControlComponent[] groups = node.getChildren();
+        assertNotNull(groups);
+        assertEquals(2, groups.length);
+
+        // Initialize dialog implementations for command execution
+        TraceControlDialogFactory.getInstance().setCreateSessionDialog(new CreateSessionDialogStub());
+        TraceControlDialogFactory.getInstance().setGetEventInfoDialog(new GetEventInfoDialogStub());
+        TraceControlDialogFactory.getInstance().setConfirmDialog(new DestroyConfirmDialogStub());
+
+        // Initialize scenario
+        fProxy.setScenario(SCEN_SCEN_PER_UID_TEST);
+
+        // ------------------------------------------------------------------------
+        // Create session
+        // ------------------------------------------------------------------------
+        TraceSessionComponent session = fFacility.createSession(groups[1]);
+
+        // Verify that session was created
+        assertNotNull(session);
+        assertEquals("mysession", session.getName());
+
+        // ------------------------------------------------------------------------
+        // Enable default channel on created session above
+        // ------------------------------------------------------------------------
+        EnableChannelDialogStub channelStub = new EnableChannelDialogStub();
+        channelStub.setIsKernel(false);
+        ChannelInfo info = (ChannelInfo)channelStub.getChannelInfo();
+        info.setName("mychannel");
+        info.setOverwriteMode(false);
+        info.setSubBufferSize(-1);
+        info.setNumberOfSubBuffers(-1);
+        info.setSwitchTimer(-1);
+        info.setReadTimer(-1);
+        info.setMaxNumberTraceFiles(-1);
+        info.setMaxSizeTraceFiles(-1);
+        info.setBufferType(BufferType.BUFFER_PER_UID);
+        channelStub.setChannelInfo(info);
+
+        TraceControlDialogFactory.getInstance().setEnableChannelDialog(channelStub);
+
+        fFacility.executeCommand(session, "enableChannelOnSession");
+
+        // Verify that UST domain was created
+        ITraceControlComponent[] domains = session.getChildren();
+        assertNotNull(domains);
+        assertEquals(1, domains.length);
+
+        assertEquals("UST global", domains[0].getName());
+        assertEquals("Domain buffer Type", BufferType.BUFFER_PER_UID, ((TraceDomainComponent)domains[0]).getBufferType());
+
+        // Verify that channel was created with correct data
+        ITraceControlComponent[] channels =  domains[0].getChildren();
+        assertNotNull(channels);
+        assertEquals(1, channels.length);
+
+        assertTrue(channels[0] instanceof TraceChannelComponent);
+        TraceChannelComponent channel = (TraceChannelComponent) channels[0];
+        assertEquals("mychannel", channel.getName());
+
+        // ------------------------------------------------------------------------
+        // Destroy session
+        // ------------------------------------------------------------------------
+        fFacility.destroySession(session);
+
+        // Verify that no more session components exist
+        assertEquals(0, groups[1].getChildren().length);
+
+        // ------------------------------------------------------------------------
+        // Create session (per-pid buffers)
+        // ------------------------------------------------------------------------
+
+        // Initialize scenario
+        fProxy.setScenario(SCEN_SCEN_PER_PID_TEST);
+
+        session = fFacility.createSession(groups[1]);
+
+        // Verify that session was created
+        assertNotNull(session);
+        assertEquals("mysession", session.getName());
+
+        // ------------------------------------------------------------------------
+        // Enable default channel on created session above
+        // ------------------------------------------------------------------------
+        info = (ChannelInfo)channelStub.getChannelInfo();
+        info.setName("mychannel");
+        info.setBufferType(BufferType.BUFFER_PER_PID);
+        channelStub.setChannelInfo(info);
+
+        fFacility.executeCommand(session, "enableChannelOnSession");
+
+        // Verify that UST domain was created
+        domains = session.getChildren();
+        assertNotNull(domains);
+        assertEquals(1, domains.length);
+
+        assertEquals("UST global", domains[0].getName());
+        assertEquals("Domain buffer Type", BufferType.BUFFER_PER_PID, ((TraceDomainComponent)domains[0]).getBufferType());
+
+        // Verify that channel was created with correct data
+        channels =  domains[0].getChildren();
+        assertNotNull(channels);
+        assertEquals(1, channels.length);
+
+        assertTrue(channels[0] instanceof TraceChannelComponent);
+        channel = (TraceChannelComponent) channels[0];
+        assertEquals("mychannel", channel.getName());
+
+        // ------------------------------------------------------------------------
+        // Destroy session
+        // ------------------------------------------------------------------------
+        fFacility.destroySession(session);
+
+        // Verify that no more session components exist
+        assertEquals(0, groups[1].getChildren().length);
+
+        // ------------------------------------------------------------------------
+        // Create session (configured file size and number of files)
+        // ------------------------------------------------------------------------
+
+        // Initialize scenario
+        fProxy.setScenario(SCEN_SCEN_BUF_SIZE_TEST);
+
+        session = fFacility.createSession(groups[1]);
+
+        // Verify that session was created
+        assertNotNull(session);
+        assertEquals("mysession", session.getName());
+
+        // ------------------------------------------------------------------------
+        // Enable default channel on created session above
+        // ------------------------------------------------------------------------
+        info = (ChannelInfo)channelStub.getChannelInfo();
+        info.setName("mychannel");
+        info.setMaxNumberTraceFiles(10);
+        info.setMaxSizeTraceFiles(1024);
+        info.setBufferType(BufferType.BUFFER_TYPE_UNKNOWN);
+        channelStub.setChannelInfo(info);
+
+        fFacility.executeCommand(session, "enableChannelOnSession");
+
+        // Verify that UST domain was created
+        domains = session.getChildren();
+        assertNotNull(domains);
+        assertEquals(1, domains.length);
+
+        assertEquals("UST global", domains[0].getName());
+        assertEquals("Domain buffer Type", BufferType.BUFFER_PER_PID, ((TraceDomainComponent)domains[0]).getBufferType());
+
+        // Verify that channel was created with correct data
+        channels =  domains[0].getChildren();
+        assertNotNull(channels);
+        assertEquals(1, channels.length);
+
+        assertTrue(channels[0] instanceof TraceChannelComponent);
+        channel = (TraceChannelComponent) channels[0];
+        assertEquals("mychannel", channel.getName());
+
+        // ------------------------------------------------------------------------
+        // Destroy session
+        // ------------------------------------------------------------------------
+        fFacility.destroySession(session);
+
+        // Verify that no more session components exist
+        assertEquals(0, groups[1].getChildren().length);
+
+        //-------------------------------------------------------------------------
+        // Disconnect node
+        //-------------------------------------------------------------------------
+        fFacility.executeCommand(node, "disconnect");
+        assertEquals(TargetNodeState.DISCONNECTED, node.getTargetNodeState());
+
+        //-------------------------------------------------------------------------
+        // Delete node
+        //-------------------------------------------------------------------------
+
+        fFacility.executeCommand(node, "delete");
+
+        assertEquals(0,fFacility.getControlView().getTraceControlRoot().getChildren().length);
+    }
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/service/AllTests.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/service/AllTests.java
new file mode 100644 (file)
index 0000000..4181191
--- /dev/null
@@ -0,0 +1,29 @@
+/*******************************************************************************
+ * Copyright (c) 2011, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Alexandre Montplaisir - Port to JUnit4
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.control.ui.tests.service;
+
+import org.junit.runner.RunWith;
+import org.junit.runners.Suite;
+
+/**
+ * Runner for the service unit tests.
+ */
+@RunWith(Suite.class)
+@Suite.SuiteClasses({
+    LTTngControlServiceTest.class,
+    LTTngControlServiceMiTest.class
+})
+public class AllTests {
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/service/LTTngControlServiceMiTest.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/service/LTTngControlServiceMiTest.java
new file mode 100644 (file)
index 0000000..626f4f1
--- /dev/null
@@ -0,0 +1,211 @@
+/**********************************************************************
+ * Copyright (c) 2014 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:
+ *   Jonathan Rajotte - Support of machine interface
+ **********************************************************************/
+
+package org.eclipse.tracecompass.lttng2.control.ui.tests.service;
+
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertNotNull;
+import static org.junit.Assert.assertTrue;
+import static org.junit.Assert.fail;
+
+import java.net.URL;
+import java.util.List;
+
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.core.runtime.NullProgressMonitor;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IChannelInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IDomainInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IEventInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISessionInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceChannelOutputType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEnablement;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEventType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.SessionInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.service.ILttngControlService;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.service.LTTngControlServiceConstants;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.service.LTTngControlServiceMI;
+import org.junit.Test;
+
+/**
+ * @author ejorajo
+ *
+ */
+public class LTTngControlServiceMiTest extends LTTngControlServiceTest {
+
+    private static final String MI_TEST_STREAM = "LTTngServiceMiTest.cfg";
+
+    private static final String SCEN_SESSION_WITH_SYSCALLS = "GetSessionWithSyscalls";
+
+    @Override
+    protected ILttngControlService getControlService() {
+        try {
+            URL resource = LTTngControlServiceMI.class.getResource(LTTngControlServiceConstants.MI_XSD_FILENAME);
+            return new LTTngControlServiceMI(getShell(), resource);
+        } catch (ExecutionException e) {
+            return null;
+        }
+    }
+
+    @Override
+    public void testGetSessionNameGarbage() {
+        try {
+            fShell.setScenario(SCEN_GET_SESSION_GARBAGE_OUT);
+            fService.getSessionNames(new NullProgressMonitor());
+        } catch (ExecutionException e) {
+            // Success. Parsing of garbage result in an ExecutionException
+            // generated by the XML document parser: Unable to parse the xml
+            // document.
+        }
+    }
+
+    @Override
+    public void testCreateLiveSession() throws ExecutionException {
+        fShell.setScenario(SCEN_CREATE_LIVE_SESSION);
+
+        ISessionInfo params = new SessionInfo("mysession");
+        params.setLive(true);
+        params.setStreamedTrace(true);
+        params.setNetworkUrl("net://127.0.0.1");
+        ISessionInfo sessionInfo = fService.createSession(params, new NullProgressMonitor());
+        assertNotNull(sessionInfo);
+        assertEquals("mysession", sessionInfo.getName());
+        assertEquals(TraceSessionState.INACTIVE, sessionInfo.getSessionState());
+        assertTrue(sessionInfo.isStreamedTrace());
+        assertTrue(sessionInfo.isLive());
+        assertEquals("tcp4://127.0.0.1:5342/ [data: 5343]", sessionInfo.getSessionPath());
+        List<String> names = fService.getSessionNames(new NullProgressMonitor());
+        assertEquals(names.get(0), "mysession");
+        fService.destroySession("mysession", new NullProgressMonitor());
+    }
+
+    @Override
+    protected String getTestStream() {
+        return MI_TEST_STREAM;
+    }
+
+    @Override
+    protected TraceLogLevel getAllEventTraceLogLevel() {
+        return TraceLogLevel.TRACE_DEBUG;
+    }
+
+    @Override
+    public void testGetKernelProviderNoUstVerbose() {
+        // Verbose mode in machine interface is deactivated. This test is
+        // ignored.
+    }
+
+    @Override
+    public void testCreateSession2_1() {
+        // 2.1 is not supported by mi. This test is ignored.
+    }
+
+    @Override
+    public void testGetKernelProviderNoUst3() {
+        // Verbose mode in machine interface is deactivated. This test is
+        // ignored.
+    }
+
+    @Override
+    public void testGetKernelProviderNoKernelVerbose() {
+        // Verbose mode in machine interface is deactivated. This test is
+        // ignored.
+    }
+
+    @Override
+    public void testCreateSessionVerbose2_1() {
+        // Verbose mode in machine interface is deactivated. This test is
+        // ignored.
+    }
+
+    @Override
+    public void testDestroySessionVerbose() {
+        // Verbose mode in machine interface is deactivated. This test is
+        // ignored.
+    }
+
+    @Override
+    public void testCreateSessionWithPrompt() {
+        // TODO Investigate if this case can happen in production. If yes than
+        // we need to rethinks the MI fetching and parsing.
+    }
+
+    @Override
+    public void testAddContext() {
+        // TODO This does not use mi feature.And currently the context enabling
+        // is wrong for 2.6.
+    }
+
+    @Override
+    public void testAddContextFailure() {
+        // TODO This does not use mi feature.And currently the context enabling
+        // is wrong for 2.6.
+    }
+
+    @Override
+    public void testCreateSnapshotSession2_5() {
+        // not applicable for MI
+    }
+
+    /**
+     * Tests the listing of syscalls
+     */
+    @Test
+    public void testListSycallEvents() {
+        try {
+            fShell.setScenario(SCEN_SESSION_WITH_SYSCALLS);
+            ISessionInfo session = fService.getSession("mysession", new NullProgressMonitor());
+
+            // Verify Session
+            assertNotNull(session);
+            assertEquals("mysession", session.getName());
+            assertEquals("/home/user/lttng-traces/mysession-20120129-084256", session.getSessionPath());
+            assertEquals(TraceSessionState.INACTIVE, session.getSessionState());
+
+            IDomainInfo[] domains = session.getDomains();
+            assertNotNull(domains);
+            assertEquals(1, domains.length);
+
+            // Verify Kernel domain
+            assertEquals("Kernel", domains[0].getName());
+            IChannelInfo[] channels =  domains[0].getChannels();
+            assertNotNull(channels);
+            assertEquals(1, channels.length);
+
+            // Verify Kernel's channel0
+            assertEquals("channel0", channels[0].getName());
+            assertEquals(4, channels[0].getNumberOfSubBuffers());
+            assertEquals("splice()", channels[0].getOutputType().getInName());
+            assertEquals(TraceChannelOutputType.SPLICE, channels[0].getOutputType());
+            assertEquals(false, channels[0].isOverwriteMode());
+            assertEquals(200, channels[0].getReadTimer());
+            assertEquals(TraceEnablement.ENABLED, channels[0].getState());
+            assertEquals(262144, channels[0].getSubBufferSize());
+            assertEquals(0, channels[0].getSwitchTimer());
+
+            // Verify event info
+            IEventInfo[] channel0Events = channels[0].getEvents();
+            assertNotNull(channel0Events);
+            assertEquals(2, channel0Events.length);
+            assertEquals("read", channel0Events[0].getName());
+            assertEquals(TraceEventType.SYSCALL, channel0Events[0].getEventType());
+            assertEquals(TraceEnablement.ENABLED, channel0Events[0].getState());
+
+            assertEquals("write", channel0Events[1].getName());
+            assertEquals(TraceEventType.SYSCALL, channel0Events[1].getEventType());
+            assertEquals(TraceEnablement.ENABLED, channel0Events[1].getState());
+        } catch (ExecutionException e) {
+            fail(e.toString());
+        }
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/service/LTTngControlServiceTest.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/service/LTTngControlServiceTest.java
new file mode 100644 (file)
index 0000000..d7cfcdc
--- /dev/null
@@ -0,0 +1,1595 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2015 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Alexandre Montplaisir - Port to JUnit4
+ *   Marc-Andre Laperle - Support for creating a live session
+ **********************************************************************/
+
+package org.eclipse.tracecompass.lttng2.control.ui.tests.service;
+
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertFalse;
+import static org.junit.Assert.assertNotNull;
+import static org.junit.Assert.assertTrue;
+import static org.junit.Assert.fail;
+
+import java.io.File;
+import java.net.URL;
+import java.util.ArrayList;
+import java.util.HashSet;
+import java.util.List;
+import java.util.Set;
+
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.core.runtime.FileLocator;
+import org.eclipse.core.runtime.NullProgressMonitor;
+import org.eclipse.core.runtime.Path;
+import org.eclipse.jdt.annotation.NonNull;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IBaseEventInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IChannelInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IDomainInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IEventInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IFieldInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISessionInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISnapshotInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IUstProviderInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.LogLevelType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceChannelOutputType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEnablement;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEventType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.BufferType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.ChannelInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.SessionInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.stubs.shells.LTTngToolsFileShell;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.logging.ControlCommandLogger;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.preferences.ControlPreferences;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.service.ILttngControlService;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.service.LTTngControlService;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.service.LTTngControlServiceFactory;
+import org.junit.After;
+import org.junit.Before;
+import org.junit.Test;
+import org.osgi.framework.FrameworkUtil;
+
+/**
+ * The class <code>LTTngControlServiceTest</code> contains test for the class
+ * <code>{@link  LTTngControlService}</code>.
+ */
+@SuppressWarnings("javadoc")
+public class LTTngControlServiceTest {
+
+    private static final String DIRECTORY   = "testfiles";
+    private static final String TEST_STREAM = "LTTngServiceTest.cfg";
+
+    private static final String SCEN_LTTNG_NOT_INSTALLED = "LttngNotInstalled";
+    private static final String SCEN_LTTNG_VERSION = "LttngVersion";
+    private static final String SCEN_LTTNG_VERSION_WITH_PROMPT = "LttngVersionWithPrompt";
+    private static final String SCEN_LTTNG_UNSUPPORTED_VERSION = "LttngUnsupportedVersion";
+    private static final String SCEN_LTTNG_NO_VERSION = "LttngNoVersion";
+    private static final String SCEN_LTTNG_COMPILED_VERSION = "LttngVersionCompiled";
+    private static final String SCEN_NO_SESSION_AVAILABLE = "NoSessionAvailable";
+    private static final String SCEN_GET_SESSION_NAMES1 = "GetSessionNames1";
+    private static final String SCEN_GET_SESSION_WITH_GROUP = "GetSessionWithTracingGroup";
+    private static final String SCEN_GET_SESSION_NAME_NOT_EXIST = "GetSessionNameNotExist";
+    private static final String SCEN_GET_SESSION_NAME_NOT_EXIST_VERBOSE = "GetSessionNameNotExistVerbose";
+    protected static final String SCEN_GET_SESSION_GARBAGE_OUT = "GetSessionGarbageOut";
+    private static final String SCEN_GET_SESSION1 = "GetSession1";
+    private static final String SCEN_GET_SESSION_WITH_LIVE = "GetSessionWithLiveInterval";
+    private static final String SCEN_GET_KERNEL_PROVIDER1 = "GetKernelProvider1";
+    private static final String SCEN_LIST_WITH_NO_KERNEL1 = "ListWithNoKernel1";
+    private static final String SCEN_LIST_WITH_NO_KERNEL2 = "ListWithNoKernel2";
+    private static final String SCEN_LIST_WITH_NO_KERNEL_VERBOSE = "ListWithNoKernelVerbose";
+    private static final String SCEN_GET_UST_PROVIDER1 = "GetUstProvider1";
+    private static final String SCEN_GET_UST_PROVIDER2 = "GetUstProvider2";
+    private static final String SCEN_GET_UST_PROVIDER3 = "GetUstProvider3";
+    private static final String SCEN_LIST_WITH_NO_UST1 = "ListWithNoUst1";
+    private static final String SCEN_LIST_WITH_NO_UST2 = "ListWithNoUst2";
+    private static final String SCEN_LIST_WITH_NO_UST3 = "ListWithNoUst3";
+    private static final String SCEN_LIST_WITH_NO_UST_VERBOSE = "ListWithNoUstVerbose";
+    private static final String SCEN_CREATE_SESSION1 = "CreateSession1";
+    private static final String SCEN_CREATE_SESSION_WITH_PROMPT = "CreateSessionWithPrompt";
+    private static final String SCEN_CREATE_SESSION_VARIANTS = "CreateSessionVariants";
+    private static final String SCEN_DESTROY_SESSION1 = "DestroySession1";
+    private static final String SCEN_DESTROY_SESSION_VERBOSE = "DestroySessionVerbose";
+    private static final String SCEN_CHANNEL_HANDLING = "ChannelHandling";
+    private static final String SCEN_EVENT_HANDLING = "EventHandling";
+    private static final String SCEN_CONTEXT_HANDLING = "ContextHandling";
+    private static final String SCEN_CONTEXT_ERROR_HANDLING = "ContextErrorHandling";
+    private static final String SCEN_CALIBRATE_HANDLING = "CalibrateHandling";
+    private static final String SCEN_CREATE_SESSION_2_1 = "CreateSessionLttng2.1";
+    private static final String SCEN_CREATE_SESSION_VERBOSE_2_1 = "CreateSessionLttngVerbose2.1";
+    private static final String SCEN_CREATE_SNAPSHOT_SESSION = "CreateSessionSnapshot";
+    private static final String SCEN_CREATE_SNAPSHOT_SESSION_2_5 = "CreateSessionSnapshot2.5";
+    private static final String SCEN_CREATE_STREAMED_SNAPSHOT_SESSION = "CreateSessionStreamedSnapshot";
+    private static final String SCEN_CREATE_SNAPSHOT_SESSION_ERRORS = "CreateSessionSnapshotErrors";
+    protected static final String SCEN_CREATE_LIVE_SESSION = "CreateSessionLive";
+    private static final String SCEN_CREATE_LIVE_SESSION_ERRORS = "CreateSessionLiveErrors";
+
+
+    // ------------------------------------------------------------------------
+    // Test data
+    // ------------------------------------------------------------------------
+    private String fTestfile;
+    protected final @NonNull LTTngToolsFileShell fShell = new LTTngToolsFileShell();
+    protected ILttngControlService fService;
+
+    // ------------------------------------------------------------------------
+    // Housekeeping
+    // ------------------------------------------------------------------------
+
+    /**
+     * Perform pre-test initialization.
+     *
+     * @throws Exception
+     *             if the initialization fails for some reason
+     */
+    @Before
+    public void setUp() throws Exception {
+        URL location = FileLocator.find(FrameworkUtil.getBundle(this.getClass()), new Path(getTestDirectory() + File.separator + getTestStream()), null);
+        File testfile = new File(FileLocator.toFileURL(location).toURI());
+        fTestfile = testfile.getAbsolutePath();
+        fShell.loadScenarioFile(fTestfile);
+        fService = getControlService();
+        if (fService == null) {
+            throw new Exception("Unable to obtain a valid ControlService");
+        }
+
+        ControlPreferences.getInstance().init(Activator.getDefault().getPreferenceStore());
+    }
+
+    /**
+     * @return the string of the test directory to use
+     */
+    protected String getTestDirectory() {
+        return DIRECTORY;
+    }
+
+    /**
+     * @return the LttngCon
+     */
+    protected ILttngControlService getControlService() {
+        return new LTTngControlService(fShell);
+    }
+
+    /**
+     * @return the shell implementation
+     */
+    public @NonNull LTTngToolsFileShell getShell() {
+        return fShell;
+    }
+
+    /**
+     * @return
+     */
+    protected String getTestStream() {
+        return TEST_STREAM;
+    }
+
+    @After
+    public void tearDown() {
+        disableVerbose();
+        ControlPreferences.getInstance().dispose();
+    }
+
+    // ------------------------------------------------------------------------
+    // Test Cases
+    // ------------------------------------------------------------------------
+
+    @Test
+    public void testVersion() {
+        try {
+            fShell.setScenario(SCEN_LTTNG_VERSION);
+            ILttngControlService service = LTTngControlServiceFactory.getLttngControlService(fShell);
+            assertNotNull(service);
+            assertEquals("2.1.0", service.getVersionString());
+        } catch (ExecutionException e) {
+            fail("Exeption thrown " + e);
+        }
+    }
+
+    @Test
+    public void testVersionWithPrompt() {
+        try {
+            fShell.setScenario(SCEN_LTTNG_VERSION_WITH_PROMPT);
+            ILttngControlService service = LTTngControlServiceFactory.getLttngControlService(fShell);
+            assertNotNull(service);
+            assertEquals("2.0.0", service.getVersionString());
+        } catch (ExecutionException e) {
+            fail("Exeption thrown " + e);
+        }
+    }
+
+    @Test(expected=ExecutionException.class)
+    public void testUnsupportedVersion() throws ExecutionException {
+        fShell.setScenario(SCEN_LTTNG_UNSUPPORTED_VERSION);
+        LTTngControlServiceFactory.getLttngControlService(fShell);
+    }
+
+    @Test
+    public void testNoVersion() {
+        try {
+            fShell.setScenario(SCEN_LTTNG_NO_VERSION);
+            LTTngControlServiceFactory.getLttngControlService(fShell);
+            fail("No exeption thrown");
+        } catch (ExecutionException e) {
+            // success
+        }
+    }
+
+    @Test
+    public void testVersionCompiled() {
+        try {
+            fShell.setScenario(SCEN_LTTNG_COMPILED_VERSION);
+            ILttngControlService service = LTTngControlServiceFactory.getLttngControlService(fShell);
+            assertNotNull(service);
+            assertEquals("2.5.0", service.getVersionString());
+        } catch (ExecutionException e) {
+            fail("Exeption thrown " + e);
+        }
+    }
+
+
+    @Test
+    public void testLttngNotInstalled() {
+        try {
+            fShell.setScenario(SCEN_LTTNG_NOT_INSTALLED);
+            fService.getSessionNames(new NullProgressMonitor());
+            fail("No exeption thrown");
+        } catch (ExecutionException e) {
+         // success
+        }
+    }
+
+    @Test
+    public void testGetSessionNames1() {
+        try {
+            fShell.setScenario(SCEN_NO_SESSION_AVAILABLE);
+            List<String> result = fService.getSessionNames(new NullProgressMonitor());
+
+            assertNotNull(result);
+            assertEquals(0, result.size());
+
+        } catch (ExecutionException e) {
+            fail(e.toString());
+        }
+    }
+
+    @Test
+    public void testGetSessionNames2() {
+        try {
+            fShell.setScenario(SCEN_GET_SESSION_NAMES1);
+            List<String> result = fService.getSessionNames(new NullProgressMonitor());
+
+            assertNotNull(result);
+            assertEquals(2, result.size());
+            assertEquals("mysession1", result.get(0));
+            assertEquals("mysession", result.get(1));
+
+        } catch (ExecutionException e) {
+            fail(e.toString());
+        }
+    }
+
+    @Test
+    public void testGetSessionNamesWithTracingGroup() {
+        try {
+            fShell.setScenario(SCEN_GET_SESSION_WITH_GROUP);
+            ControlPreferences.getInstance().getPreferenceStore().setValue(
+                    ControlPreferences.TRACE_CONTROL_TRACING_GROUP_PREF, "group");
+
+            List<String> result = fService.getSessionNames(new NullProgressMonitor());
+
+            assertNotNull(result);
+            assertEquals(2, result.size());
+            assertEquals("mysession1", result.get(0));
+            assertEquals("mysession", result.get(1));
+
+            ControlCommandLogger.init(ControlPreferences.getInstance().getLogfilePath(), false);
+            ControlPreferences.getInstance().getPreferenceStore().setValue(
+                    ControlPreferences.TRACE_CONTROL_TRACING_GROUP_PREF, ControlPreferences.TRACE_CONTROL_DEFAULT_TRACING_GROUP);
+
+
+        } catch (ExecutionException e) {
+            fail(e.toString());
+        }
+    }
+
+
+    @Test
+    public void testGetSessionNotExist() {
+        try {
+            fShell.setScenario(SCEN_GET_SESSION_NAME_NOT_EXIST);
+            fService.getSessionNames(new NullProgressMonitor());
+            fail("No exeption thrown");
+
+        } catch (ExecutionException e) {
+            // success
+        }
+    }
+
+    @Test
+    public void testGetSessionNotExistVerbose() {
+        try {
+            enableVerbose();
+            fShell.setScenario(SCEN_GET_SESSION_NAME_NOT_EXIST_VERBOSE);
+            fService.getSessionNames(new NullProgressMonitor());
+            fail("No exeption thrown");
+
+        } catch (ExecutionException e) {
+            // success
+        } finally {
+            disableVerbose();
+        }
+    }
+
+    @Test
+    public void testGetSessionNameGarbage() {
+        try {
+            fShell.setScenario(SCEN_GET_SESSION_GARBAGE_OUT);
+            List<String> result = fService.getSessionNames(new NullProgressMonitor());
+
+            assertNotNull(result);
+            assertEquals(0, result.size());
+
+        } catch (ExecutionException e) {
+            fail(e.toString());
+        }
+    }
+
+    @Test
+    public void testGetSession1() {
+        try {
+            fShell.setScenario(SCEN_GET_SESSION1);
+            ISessionInfo session = fService.getSession("mysession", new NullProgressMonitor());
+
+            // Verify Session
+            assertNotNull(session);
+            assertEquals("mysession", session.getName());
+            assertEquals("/home/user/lttng-traces/mysession-20120129-084256", session.getSessionPath());
+            assertEquals(TraceSessionState.ACTIVE, session.getSessionState());
+
+            IDomainInfo[] domains = session.getDomains();
+            assertNotNull(domains);
+            assertEquals(2, domains.length);
+
+            // Verify Kernel domain
+            assertEquals("Kernel", domains[0].getName());
+            IChannelInfo[] channels =  domains[0].getChannels();
+            assertNotNull(channels);
+            assertEquals(2, channels.length);
+
+            // Verify Kernel's channel0
+            assertEquals("channel0", channels[0].getName());
+            assertEquals(4, channels[0].getNumberOfSubBuffers());
+            assertEquals("splice()", channels[0].getOutputType().getInName());
+            assertEquals(TraceChannelOutputType.SPLICE, channels[0].getOutputType());
+            assertEquals(false, channels[0].isOverwriteMode());
+            assertEquals(200, channels[0].getReadTimer());
+            assertEquals(TraceEnablement.ENABLED, channels[0].getState());
+            assertEquals(262144, channels[0].getSubBufferSize());
+            assertEquals(0, channels[0].getSwitchTimer());
+
+            // Verify event info
+            IEventInfo[] channel0Events = channels[0].getEvents();
+            assertNotNull(channel0Events);
+            assertEquals(2, channel0Events.length);
+            assertEquals("block_rq_remap", channel0Events[0].getName());
+            assertEquals(TraceLogLevel.TRACE_EMERG, channel0Events[0].getLogLevel());
+            assertEquals(TraceEventType.TRACEPOINT, channel0Events[0].getEventType());
+            assertEquals(TraceEnablement.ENABLED, channel0Events[0].getState());
+
+            assertEquals("block_bio_remap", channel0Events[1].getName());
+            assertEquals(TraceLogLevel.TRACE_EMERG, channel0Events[1].getLogLevel());
+            assertEquals(TraceEventType.TRACEPOINT, channel0Events[1].getEventType());
+            assertEquals(TraceEnablement.DISABLED, channel0Events[1].getState());
+
+            // Verify Kernel's channel1
+            assertEquals("channel1", channels[1].getName());
+            assertEquals(4, channels[1].getNumberOfSubBuffers());
+            assertEquals("splice()", channels[1].getOutputType().getInName());
+            assertEquals(TraceChannelOutputType.SPLICE, channels[1].getOutputType());
+            assertEquals(true, channels[1].isOverwriteMode());
+            assertEquals(400, channels[1].getReadTimer());
+            assertEquals(TraceEnablement.DISABLED, channels[1].getState());
+            assertEquals(524288, channels[1].getSubBufferSize());
+            assertEquals(100, channels[1].getSwitchTimer());
+
+            // Verify event info
+            IEventInfo[] channel1Events = channels[1].getEvents();
+            assertEquals(0, channel1Events.length);
+
+            // Verify domain UST global
+            assertEquals("UST global", domains[1].getName());
+
+            IChannelInfo[] ustChannels =  domains[1].getChannels();
+
+            // Verify UST global's mychannel1
+            assertEquals("mychannel1", ustChannels[0].getName());
+            assertEquals(8, ustChannels[0].getNumberOfSubBuffers());
+            assertEquals("mmap()", ustChannels[0].getOutputType().getInName());
+            assertEquals(TraceChannelOutputType.MMAP, ustChannels[0].getOutputType());
+            assertEquals(true, ustChannels[0].isOverwriteMode());
+            assertEquals(100, ustChannels[0].getReadTimer());
+            assertEquals(TraceEnablement.DISABLED, ustChannels[0].getState());
+            assertEquals(8192, ustChannels[0].getSubBufferSize());
+            assertEquals(200, ustChannels[0].getSwitchTimer());
+
+            // Verify event info
+            IEventInfo[] ustEvents = ustChannels[0].getEvents();
+            assertEquals(0, ustEvents.length);
+
+            // Verify UST global's channel0
+            assertEquals("channel0", ustChannels[1].getName());
+            assertEquals(4, ustChannels[1].getNumberOfSubBuffers());
+            assertEquals("mmap()", ustChannels[1].getOutputType().getInName());
+            assertEquals(TraceChannelOutputType.MMAP, ustChannels[1].getOutputType());
+            assertEquals(false, ustChannels[1].isOverwriteMode());
+            assertEquals(200, ustChannels[1].getReadTimer());
+            assertEquals(TraceEnablement.ENABLED, ustChannels[1].getState());
+            assertEquals(4096, ustChannels[1].getSubBufferSize());
+            assertEquals(0, ustChannels[1].getSwitchTimer());
+
+            // Verify event info
+            ustEvents = ustChannels[1].getEvents();
+            assertEquals(2, ustEvents.length);
+
+            assertEquals("ust_tests_hello:tptest_sighandler", ustEvents[0].getName());
+            assertEquals(TraceLogLevel.TRACE_DEBUG_LINE, ustEvents[0].getLogLevel());
+            assertEquals(TraceEventType.TRACEPOINT, ustEvents[0].getEventType());
+            assertEquals(TraceEnablement.DISABLED, ustEvents[0].getState());
+
+            assertEquals("*", ustEvents[1].getName());
+            assertEquals(getAllEventTraceLogLevel(), ustEvents[1].getLogLevel());
+            assertEquals(TraceEventType.TRACEPOINT, ustEvents[1].getEventType());
+            assertEquals(TraceEnablement.ENABLED, ustEvents[1].getState());
+
+            // next session (no detailed information available)
+            session = fService.getSession("mysession1", new NullProgressMonitor());
+            assertNotNull(session);
+            assertEquals("mysession1", session.getName());
+            assertEquals("/home/user/lttng-traces/mysession1-20120203-133225", session.getSessionPath());
+            assertEquals(TraceSessionState.INACTIVE, session.getSessionState());
+
+            domains = session.getDomains();
+            assertNotNull(domains);
+            assertEquals(0, domains.length);
+        } catch (ExecutionException e) {
+            fail(e.toString());
+        }
+    }
+
+    @Test
+    public void testGetSessionWithLive() {
+        try {
+            fShell.setScenario(SCEN_GET_SESSION_WITH_LIVE);
+
+            // Verify Session (snapshot session, non-live)
+            ISessionInfo session = fService.getSession("mysession", new NullProgressMonitor());
+            assertNotNull(session);
+            assertEquals("mysession", session.getName());
+            assertEquals("/home/user/lttng-traces/mysession-20120129-084256", session.getSessionPath());
+            assertEquals(TraceSessionState.INACTIVE, session.getSessionState());
+            assertFalse(session.isLive());
+
+            // Verify Session (regular session, non-live)
+            session = fService.getSession("mysession1", new NullProgressMonitor());
+            assertNotNull(session);
+            assertEquals("mysession1", session.getName());
+            assertEquals("/home/user/lttng-traces/mysession1-20120129-084256", session.getSessionPath());
+            assertEquals(TraceSessionState.ACTIVE, session.getSessionState());
+            assertFalse(session.isLive());
+
+            // Verify Session (regular session, live)
+            session = fService.getSession("mysession2", new NullProgressMonitor());
+            assertNotNull(session);
+            assertEquals("mysession2", session.getName());
+            assertEquals("tcp4://172.0.0.1:5342/ [data: 5343]", session.getSessionPath());
+            assertEquals("net://127.0.0.1", session.getLiveUrl());
+            assertEquals(Integer.valueOf(5344), session.getLivePort());
+            assertEquals(1000000, session.getLiveDelay());
+            assertEquals(TraceSessionState.INACTIVE, session.getSessionState());
+            assertTrue(session.isLive());
+
+        } catch (ExecutionException e) {
+            fail(e.toString());
+        }
+    }
+
+    /**
+     * @return
+     */
+    protected TraceLogLevel getAllEventTraceLogLevel() {
+        return TraceLogLevel.LEVEL_UNKNOWN;
+    }
+
+    public void testGetKernelProvider() {
+        try {
+            fShell.setScenario(SCEN_GET_KERNEL_PROVIDER1);
+            List<IBaseEventInfo> events = fService.getKernelProvider(new NullProgressMonitor());
+
+            // Verify event info
+            assertNotNull(events);
+            assertEquals(3, events.size());
+
+            IBaseEventInfo baseEventInfo = events.get(0);
+            assertNotNull(baseEventInfo);
+            assertEquals("sched_kthread_stop", baseEventInfo.getName());
+            assertEquals(TraceLogLevel.TRACE_EMERG, baseEventInfo.getLogLevel());
+            assertEquals(TraceEventType.TRACEPOINT, baseEventInfo.getEventType());
+
+            baseEventInfo = events.get(1);
+            assertEquals("sched_kthread_stop_ret", baseEventInfo.getName());
+            assertEquals(TraceLogLevel.TRACE_EMERG, baseEventInfo.getLogLevel());
+            assertEquals(TraceEventType.TRACEPOINT, baseEventInfo.getEventType());
+
+            baseEventInfo = events.get(2);
+            assertEquals("sched_wakeup_new", baseEventInfo.getName());
+            assertEquals(TraceLogLevel.TRACE_EMERG, baseEventInfo.getLogLevel());
+            assertEquals(TraceEventType.TRACEPOINT, baseEventInfo.getEventType());
+
+        } catch (ExecutionException e) {
+            fail(e.toString());
+        }
+    }
+
+    @Test
+    public void testGetKernelProviderNoKernel1() {
+        try {
+            fShell.setScenario(SCEN_LIST_WITH_NO_KERNEL1);
+            List<IBaseEventInfo> events = fService.getKernelProvider(new NullProgressMonitor());
+
+            // Verify event info
+            assertNotNull(events);
+            assertEquals(0, events.size());
+
+        } catch (ExecutionException e) {
+            fail(e.toString());
+        }
+    }
+
+    @Test
+    public void testGetKernelProviderNoKernel2() {
+        try {
+            fShell.setScenario(SCEN_LIST_WITH_NO_KERNEL2);
+            List<IBaseEventInfo> events = fService.getKernelProvider(new NullProgressMonitor());
+
+            // Verify event info
+            assertNotNull(events);
+            assertEquals(0, events.size());
+
+        } catch (ExecutionException e) {
+            fail(e.toString());
+        }
+    }
+
+    @Test
+    public void testGetKernelProviderNoKernelVerbose() {
+        try {
+            enableVerbose();
+            fShell.setScenario(SCEN_LIST_WITH_NO_KERNEL_VERBOSE);
+            List<IBaseEventInfo> events = fService.getKernelProvider(new NullProgressMonitor());
+
+            // Verify event info
+            assertNotNull(events);
+            assertEquals(0, events.size());
+
+        } catch (ExecutionException e) {
+            fail(e.toString());
+        } finally {
+            disableVerbose();
+        }
+    }
+
+    @Test
+    public void testGetUstProvider() {
+        try {
+            fShell.setScenario(SCEN_GET_UST_PROVIDER1);
+            List<IUstProviderInfo> providers = fService.getUstProvider();
+
+            // Check all providers
+            assertNotNull(providers);
+            assertEquals(2, providers.size());
+
+            //Verify first provider
+            assertEquals("/home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello", providers.get(0).getName());
+            assertEquals(9379, providers.get(0).getPid());
+
+            // Verify event info
+            IBaseEventInfo[] events = providers.get(0).getEvents();
+            assertNotNull(events);
+            assertEquals(2, events.length);
+
+            IBaseEventInfo baseEventInfo = events[0];
+            assertNotNull(baseEventInfo);
+            assertEquals("ust_tests_hello:tptest_sighandler", baseEventInfo.getName());
+            assertEquals(TraceLogLevel.TRACE_DEBUG_MODULE, baseEventInfo.getLogLevel());
+            assertEquals(TraceEventType.TRACEPOINT, baseEventInfo.getEventType());
+
+            baseEventInfo = events[1];
+            assertEquals("ust_tests_hello:tptest", baseEventInfo.getName());
+            assertEquals(TraceLogLevel.TRACE_INFO, baseEventInfo.getLogLevel());
+            assertEquals(TraceEventType.TRACEPOINT, baseEventInfo.getEventType());
+
+            //Verify second provider
+            assertEquals("/home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello", providers.get(1).getName());
+            assertEquals(4852, providers.get(1).getPid());
+
+            // Verify event info
+            events = providers.get(1).getEvents();
+            assertNotNull(events);
+            assertEquals(2, events.length);
+
+            baseEventInfo = events[0];
+            assertNotNull(baseEventInfo);
+            assertEquals("ust_tests_hello:tptest_sighandler", baseEventInfo.getName());
+            assertEquals(TraceLogLevel.TRACE_WARNING, baseEventInfo.getLogLevel());
+            assertEquals(TraceEventType.TRACEPOINT, baseEventInfo.getEventType());
+
+            baseEventInfo = events[1];
+            assertEquals("ust_tests_hello:tptest", baseEventInfo.getName());
+            assertEquals(TraceLogLevel.TRACE_DEBUG_FUNCTION, baseEventInfo.getLogLevel());
+            assertEquals(TraceEventType.TRACEPOINT, baseEventInfo.getEventType());
+
+        } catch (ExecutionException e) {
+            fail(e.toString());
+        }
+    }
+
+    @Test
+    public void testUstProvider2() {
+        try {
+            fShell.setScenario(SCEN_GET_UST_PROVIDER2);
+            List<IUstProviderInfo> providers = fService.getUstProvider();
+
+            assertNotNull(providers);
+            assertEquals(0, providers.size());
+
+        } catch (ExecutionException e) {
+            fail(e.toString());
+        }
+    }
+
+    @Test
+    public void testGetUstProvider3() {
+        try {
+            fShell.setScenario(SCEN_GET_UST_PROVIDER3);
+            // Set version
+            ((LTTngControlService)fService).setVersion("2.1.0");
+            List<IUstProviderInfo> providers = fService.getUstProvider();
+
+            // Check all providers
+            assertNotNull(providers);
+            assertEquals(2, providers.size());
+
+            //Verify first provider
+            assertEquals("/home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello", providers.get(0).getName());
+            assertEquals(9379, providers.get(0).getPid());
+
+            // Verify event info
+            IBaseEventInfo[] events = providers.get(0).getEvents();
+            assertNotNull(events);
+            assertEquals(2, events.length);
+
+            IBaseEventInfo baseEventInfo = events[0];
+            assertNotNull(baseEventInfo);
+            IFieldInfo[] fields = baseEventInfo.getFields();
+            assertNotNull(fields);
+            assertEquals(0, fields.length);
+
+            baseEventInfo = events[1];
+            fields = baseEventInfo.getFields();
+            assertNotNull(fields);
+            assertEquals(3, fields.length);
+            assertEquals("doublefield", fields[0].getName());
+            assertEquals("float", fields[0].getFieldType());
+
+            assertEquals("floatfield", fields[1].getName());
+            assertEquals("float", fields[1].getFieldType());
+
+            assertEquals("stringfield", fields[2].getName());
+            assertEquals("string", fields[2].getFieldType());
+
+            //Verify second provider
+            assertEquals("/home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello", providers.get(1).getName());
+            assertEquals(4852, providers.get(1).getPid());
+
+            // Verify event info
+            events = providers.get(1).getEvents();
+            assertNotNull(events);
+            assertEquals(2, events.length);
+
+            baseEventInfo = events[0];
+            assertNotNull(baseEventInfo);
+            fields = baseEventInfo.getFields();
+            assertNotNull(fields);
+            assertEquals(0, fields.length);
+
+            baseEventInfo = events[1];
+            fields = baseEventInfo.getFields();
+            assertNotNull(fields);
+            assertEquals(3, fields.length);
+
+            assertEquals("doublefield", fields[0].getName());
+            assertEquals("float", fields[0].getFieldType());
+
+            assertEquals("floatfield", fields[1].getName());
+            assertEquals("float", fields[1].getFieldType());
+
+            assertEquals("stringfield", fields[2].getName());
+            assertEquals("string", fields[2].getFieldType());
+
+            // Reset version
+            ((LTTngControlService)fService).setVersion("2.0.0");
+
+        } catch (ExecutionException e) {
+            fail(e.toString());
+        }
+    }
+
+
+    @Test
+    public void testGetKernelProviderNoUst1() {
+        try {
+            fShell.setScenario(SCEN_LIST_WITH_NO_UST1);
+            List<IUstProviderInfo> providerList = fService.getUstProvider(new NullProgressMonitor());
+
+            // Verify Provider info
+            assertNotNull(providerList);
+            assertEquals(0, providerList.size());
+
+        } catch (ExecutionException e) {
+            fail(e.toString());
+        }
+    }
+
+
+    @Test
+    public void testGetKernelProviderNoUst2() {
+        try {
+            // Set version
+            ((LTTngControlService)fService).setVersion("2.1.0");
+
+            fShell.setScenario(SCEN_LIST_WITH_NO_UST2);
+            List<IUstProviderInfo> providerList = fService.getUstProvider(new NullProgressMonitor());
+
+            // Verify Provider info
+            assertNotNull(providerList);
+            assertEquals(0, providerList.size());
+
+            // Reset version
+            ((LTTngControlService)fService).setVersion("2.0.0");
+
+        } catch (ExecutionException e) {
+            fail(e.toString());
+        }
+    }
+
+    @Test
+    public void testGetKernelProviderNoUst3() {
+        try {
+
+            // Set version
+            ((LTTngControlService)fService).setVersion("2.1.0");
+
+            fShell.setScenario(SCEN_LIST_WITH_NO_UST3);
+            List<IUstProviderInfo> providerList = fService.getUstProvider(new NullProgressMonitor());
+
+            // Verify provider info
+            assertNotNull(providerList);
+            assertEquals(0, providerList.size());
+
+            // Reset version
+            ((LTTngControlService)fService).setVersion("2.0.0");
+
+        } catch (ExecutionException e) {
+            fail(e.toString());
+        }
+    }
+
+    @Test
+    public void testGetKernelProviderNoUstVerbose() {
+        try {
+            enableVerbose();
+
+            // Set version
+            ((LTTngControlService)fService).setVersion("2.1.0");
+
+            fShell.setScenario(SCEN_LIST_WITH_NO_UST_VERBOSE);
+            List<IUstProviderInfo> providerList = fService.getUstProvider(new NullProgressMonitor());
+
+            // Verify provider info
+            assertNotNull(providerList);
+            assertEquals(0, providerList.size());
+
+            // Reset version
+            ((LTTngControlService)fService).setVersion("2.0.0");
+
+        } catch (ExecutionException e) {
+            fail(e.toString());
+        } finally {
+            disableVerbose();
+        }
+    }
+
+
+
+    @Test
+    public void testCreateSession() {
+        try {
+            fShell.setScenario(SCEN_CREATE_SESSION1);
+
+            ISessionInfo info = fService.createSession(new SessionInfo("mysession2"), new NullProgressMonitor());
+            assertNotNull(info);
+            assertEquals("mysession2", info.getName());
+            assertNotNull(info.getSessionPath());
+            assertTrue(info.getSessionPath().contains("mysession2"));
+            assertEquals(TraceSessionState.INACTIVE, info.getSessionState());
+        } catch (ExecutionException e) {
+            fail(e.toString());
+        }
+    }
+
+    @Test
+    public void testCreateSessionWithPrompt() {
+        try {
+            // First line has the shell prompt before the command output
+            // This can happen in a real application if the command line is not echoed by the shell.
+            fShell.setScenario(SCEN_CREATE_SESSION_WITH_PROMPT);
+
+            // First line has no shell prompt before the output
+            ISessionInfo info = fService.createSession(new SessionInfo("mysession2"), new NullProgressMonitor());
+            assertNotNull(info);
+            assertEquals("mysession2", info.getName());
+            assertNotNull(info.getSessionPath());
+            assertTrue(info.getSessionPath().contains("mysession2"));
+            assertEquals(TraceSessionState.INACTIVE, info.getSessionState());
+        } catch (ExecutionException e) {
+            fail(e.toString());
+        }
+    }
+
+    @Test
+    public void testCreateSessionVariants() {
+
+        fShell.setScenario(SCEN_CREATE_SESSION_VARIANTS);
+
+        try {
+            fService.createSession(new SessionInfo("alreadyExist"), new NullProgressMonitor());
+            fail("No exeption thrown");
+        } catch (ExecutionException e) {
+            // success
+        }
+
+        try {
+            fService.createSession(new SessionInfo("wrongName"), new NullProgressMonitor());
+            fail("No exeption thrown");
+        } catch (ExecutionException e) {
+            // success
+        }
+
+        try {
+            ISessionInfo sessionInfo = new SessionInfo("withPath");
+            sessionInfo.setSessionPath("/home/user/hallo");
+            fService.createSession(sessionInfo, new NullProgressMonitor());
+            fail("No exeption thrown");
+        } catch (ExecutionException e) {
+            // success
+        }
+
+        try {
+            ISessionInfo info = fService.createSession(new SessionInfo("session with spaces"), new NullProgressMonitor());
+            assertNotNull(info);
+            assertEquals("session with spaces", info.getName());
+            assertNotNull(info.getSessionPath());
+            assertTrue(info.getSessionPath().contains("session with spaces"));
+            assertEquals(TraceSessionState.INACTIVE, info.getSessionState());
+
+        } catch (ExecutionException e) {
+            fail(e.toString());
+        }
+
+        try {
+            ISessionInfo sessionInfo = new SessionInfo("pathWithSpaces");
+            sessionInfo.setSessionPath("/home/user/hallo user/here");
+            ISessionInfo info = fService.createSession(sessionInfo, new NullProgressMonitor());
+            assertNotNull(info);
+            assertEquals("pathWithSpaces", info.getName());
+            assertNotNull(info.getSessionPath());
+            assertTrue(info.getSessionPath().contains("/home/user/hallo user/here"));
+            assertEquals(TraceSessionState.INACTIVE, info.getSessionState());
+
+        } catch (ExecutionException e) {
+            fail(e.toString());
+        }
+    }
+
+    @Test
+    public void testDestroySession() {
+        try {
+            fShell.setScenario(SCEN_DESTROY_SESSION1);
+            fService.destroySession("mysession2", new NullProgressMonitor());
+        } catch (ExecutionException e) {
+            fail(e.toString());
+        }
+    }
+
+    @Test
+    public void testDestroySessionVerbose() {
+        try {
+            enableVerbose();
+            fShell.setScenario(SCEN_DESTROY_SESSION_VERBOSE);
+            fService.destroySession("mysession2", new NullProgressMonitor());
+        } catch (ExecutionException e) {
+            fail(e.toString());
+        } finally {
+            disableVerbose();
+        }
+    }
+
+    @Test
+    public void testCreateChannel() {
+        try {
+            ((LTTngControlService)fService).setVersion("2.2.0");
+            String sessionName = "mysession2";
+            List<String> list = new ArrayList<>();
+            String kernelChannel0 = "mychannel0";
+            String kernelChannel1 = "mychannel1";
+            list.add(kernelChannel0);
+            list.add(kernelChannel1);
+
+            fShell.setScenario(SCEN_CHANNEL_HANDLING);
+
+            // Create/enable/configure 2 kernel channels
+            ChannelInfo chanInfo = new ChannelInfo("");
+            chanInfo.setOverwriteMode(true);
+            chanInfo.setSubBufferSize(16384);
+            chanInfo.setReadTimer(100);
+            chanInfo.setSwitchTimer(200);
+            chanInfo.setNumberOfSubBuffers(2);
+            chanInfo.setMaxNumberTraceFiles(10);
+            chanInfo.setMaxSizeTraceFiles(0);
+            fService.enableChannels(sessionName, list, true, chanInfo, new NullProgressMonitor());
+
+            // Create/enable/configure 1 UST channel
+            list.clear();
+            list.add("ustChannel");
+
+            chanInfo = new ChannelInfo("");
+            chanInfo.setOverwriteMode(true);
+            chanInfo.setSubBufferSize(32768);
+            chanInfo.setReadTimer(200);
+            chanInfo.setSwitchTimer(100);
+            chanInfo.setNumberOfSubBuffers(1);
+            chanInfo.setMaxNumberTraceFiles(20);
+            chanInfo.setMaxSizeTraceFiles(0);
+            fService.enableChannels(sessionName, list, false, chanInfo, new NullProgressMonitor());
+            ((LTTngControlService)fService).setVersion("2.0.0");
+
+        } catch (ExecutionException e) {
+            fail(e.toString());
+        }
+    }
+
+    @Test
+    public void testCreateChannelUIDBuffer() {
+        try {
+            ((LTTngControlService)fService).setVersion("2.2.0");
+            String sessionName = "mysession2";
+            List<String> list = new ArrayList<>();
+            String USTChannel = "ustChannel";
+            list.add(USTChannel);
+            fShell.setScenario(SCEN_CHANNEL_HANDLING);
+
+            ChannelInfo chanInfo = new ChannelInfo("");
+            chanInfo.setOverwriteMode(true);
+            chanInfo.setSubBufferSize(32768);
+            chanInfo.setReadTimer(200);
+            chanInfo.setSwitchTimer(100);
+            chanInfo.setNumberOfSubBuffers(1);
+            chanInfo.setMaxNumberTraceFiles(20);
+            chanInfo.setMaxSizeTraceFiles(0);
+            chanInfo.setBufferType(BufferType.BUFFER_PER_UID);
+            fService.enableChannels(sessionName, list, false, chanInfo, new NullProgressMonitor());
+            ((LTTngControlService)fService).setVersion("2.0.0");
+
+        } catch (ExecutionException e) {
+            fail(e.toString());
+        }
+    }
+
+    @Test
+    public void testCreateChannelPIDBuffer() {
+        try {
+            ((LTTngControlService)fService).setVersion("2.2.0");
+            String sessionName = "mysession2";
+            List<String> list = new ArrayList<>();
+            String USTChannel = "ustChannel";
+            list.add(USTChannel);
+            fShell.setScenario(SCEN_CHANNEL_HANDLING);
+
+
+            ChannelInfo chanInfo = new ChannelInfo("");
+            chanInfo.setOverwriteMode(true);
+            chanInfo.setSubBufferSize(-1);
+            chanInfo.setReadTimer(-1);
+            chanInfo.setSwitchTimer(-1);
+            chanInfo.setNumberOfSubBuffers(-1);
+            chanInfo.setMaxNumberTraceFiles(-1);
+            chanInfo.setMaxSizeTraceFiles(-1);
+            chanInfo.setBufferType(BufferType.BUFFER_PER_PID);
+
+            fService.enableChannels(sessionName, list, false, chanInfo, new NullProgressMonitor());
+            ((LTTngControlService)fService).setVersion("2.0.0");
+
+        } catch (ExecutionException e) {
+            fail(e.toString());
+        }
+    }
+
+    @Test
+    public void testDisableChannel() {
+        try {
+
+            String sessionName = "mysession2";
+            List<String> list = new ArrayList<>();
+            String kernelChannel0 = "mychannel0";
+            String kernelChannel1 = "mychannel1";
+            list.add(kernelChannel0);
+            list.add(kernelChannel1);
+
+            fShell.setScenario(SCEN_CHANNEL_HANDLING);
+            fService.disableChannels(sessionName, list, true, new NullProgressMonitor());
+
+            list.clear();
+            list.add("ustChannel");
+            fService.disableChannels(sessionName, list, false, new NullProgressMonitor());
+
+        } catch (ExecutionException e) {
+            fail(e.toString());
+        }
+    }
+
+    @Test
+    public void testEnableChannel() {
+        try {
+
+            String sessionName = "mysession2";
+            List<String> list = new ArrayList<>();
+            String kernelChannel0 = "mychannel0";
+            String kernelChannel1 = "mychannel1";
+            list.add(kernelChannel0);
+            list.add(kernelChannel1);
+
+            fShell.setScenario(SCEN_CHANNEL_HANDLING);
+            fService.enableChannels(sessionName, list, true, null, new NullProgressMonitor());
+
+            // Create/enable/configure 1 UST channel
+            list.clear();
+            list.add("ustChannel");
+
+            fService.enableChannels(sessionName, list, false, null, new NullProgressMonitor());
+
+        } catch (ExecutionException e) {
+            fail(e.toString());
+        }
+    }
+
+    @Test
+    public void testEnableEvents() {
+        try {
+            // 1) session name, channel = null, 3 event names, kernel
+            String sessionName = "mysession2";
+            List<String> list = new ArrayList<>();
+            String eventName0 = "block_rq_remap";
+            String eventName1 = "block_bio_remap";
+            String eventName2 = "softirq_entry";
+            list.add(eventName0);
+            list.add(eventName1);
+            list.add(eventName2);
+            fShell.setScenario(SCEN_EVENT_HANDLING);
+            fService.enableEvents(sessionName, null, list, true, null, new NullProgressMonitor());
+
+            // 2) session name, channel=mychannel, event name= null, kernel
+            String channelName = "mychannel";
+            fService.enableEvents(sessionName, channelName, null, true, null, new NullProgressMonitor());
+
+            // 3) session name, channel=mychannel, 1 event name, ust, no filter
+            String ustEventName = "ust_tests_hello:tptest_sighandler";
+            list.clear();
+            list.add(ustEventName);
+            fService.enableEvents(sessionName, channelName, list, false, null, new NullProgressMonitor());
+
+            // 4) session name, channel = mychannel, no event name, ust, with filter
+            fService.enableEvents(sessionName, channelName, list, false, "intfield==10", new NullProgressMonitor());
+
+            // 5) session name, channel = mychannel, no event name, ust, no filter
+            list.clear();
+            fService.enableEvents(sessionName, channelName, list, false, null, new NullProgressMonitor());
+
+            // TODO add test with filters
+
+        } catch (ExecutionException e) {
+            fail(e.toString());
+        }
+    }
+
+    @Test
+    public void testEnableSyscalls() {
+        try {
+            // 1) session name, channel = null, 3 event names, kernel
+            String sessionName = "mysession2";
+            String channelName = "mychannel";
+
+            fShell.setScenario(SCEN_EVENT_HANDLING);
+
+            // 1) session name, channel = null
+            fService.enableSyscalls(sessionName, null, new NullProgressMonitor());
+
+            // 2) session name, channel = mychannel
+            fService.enableSyscalls(sessionName, channelName, new NullProgressMonitor());
+
+        } catch (ExecutionException e) {
+            fail(e.toString());
+        }
+    }
+
+    @Test
+    public void testDynamicProbe() {
+        try {
+            // 1) session name, channel = null, 3 event names, kernel
+            String sessionName = "mysession2";
+            String channelName = "mychannel";
+            String eventName0 = "myevent0";
+            String eventName1 = "myevent1";
+            String functionProbe = "0xc0101340";
+            String dynProbe = "init_post";
+
+            fShell.setScenario(SCEN_EVENT_HANDLING);
+
+            // 1) session name, channel = null, event name, function probe, probe
+            fService.enableProbe(sessionName, null, eventName0, true, functionProbe, new NullProgressMonitor());
+
+            // 2) session name, channel = mychannel
+            fService.enableProbe(sessionName, channelName, eventName1, false, dynProbe, new NullProgressMonitor());
+
+        } catch (ExecutionException e) {
+            fail(e.toString());
+        }
+    }
+
+    @Test
+    public void testEnableLogLevel() {
+        try {
+            // 1) session name, channel = null, 3 event names, kernel
+            String sessionName = "mysession2";
+            String channelName = "mychannel";
+            String eventName4 = "myevent4";
+            String eventName5 = "myevent5";
+
+            fShell.setScenario(SCEN_EVENT_HANDLING);
+
+            // 1) session name, channel = null, event name, loglevel-only, TRACE_DEBUG
+            fService.enableLogLevel(sessionName, null, eventName4, LogLevelType.LOGLEVEL_ONLY, TraceLogLevel.TRACE_DEBUG, null, new NullProgressMonitor());
+
+            // 2) session name, channel = mychannel, null, loglevel, TRACE_DEBUG_FUNCTION
+            fService.enableLogLevel(sessionName, channelName, eventName5, LogLevelType.LOGLEVEL, TraceLogLevel.TRACE_DEBUG_FUNCTION, null, new NullProgressMonitor());
+
+            // TODO add test with filters
+
+        } catch (ExecutionException e) {
+            fail(e.toString());
+        }
+    }
+
+    @Test
+    public void testAddContext() {
+        try {
+            // 1) session name, channel = null, 3 event names, kernel
+            String sessionName = "mysession2";
+            String channelName = "mychannel";
+            String eventName = "ust_tests_hello:tptest_sighandler";
+            List<String> contexts = new ArrayList<>();
+            contexts.add("prio");
+            contexts.add("pid");
+
+            fShell.setScenario(SCEN_CONTEXT_HANDLING);
+
+            List<String> availContexts = fService.getContextList(new NullProgressMonitor());
+            assertNotNull(availContexts);
+            assertEquals(12, availContexts.size());
+
+            // A very "hard-coded" way to verify but it works ...
+            Set<String> expectedContexts = new HashSet<>();
+            expectedContexts.add("pid");
+            expectedContexts.add("procname");
+            expectedContexts.add("prio");
+            expectedContexts.add("nice");
+            expectedContexts.add("vpid");
+            expectedContexts.add("tid");
+            expectedContexts.add("pthread_id");
+            expectedContexts.add("vtid");
+            expectedContexts.add("ppid");
+            expectedContexts.add("vppid");
+            expectedContexts.add("perf:cpu-cycles");
+            expectedContexts.add("perf:cycles");
+
+            assertTrue(expectedContexts.containsAll(availContexts));
+
+            // 1) session name, channel = null, event name, loglevel-only, TRACE_DEBUG
+            fService.addContexts(sessionName, channelName, eventName, false, contexts, new NullProgressMonitor());
+
+        } catch (ExecutionException e) {
+            fail(e.toString());
+        }
+    }
+
+    @Test
+    public void testAddContextFailure() {
+
+        // 1) session name, channel = null, 3 event names, kernel
+        String sessionName = "mysession2";
+        String channelName = "mychannel";
+        String eventName = "ust_tests_hello:tptest_sighandler";
+        List<String> contexts = new ArrayList<>();
+        contexts.add("prio");
+        contexts.add("pid");
+        fShell.setScenario(SCEN_CONTEXT_ERROR_HANDLING);
+        try {
+            fService.getContextList(new NullProgressMonitor());
+            fail("No exeption generated");
+        } catch (ExecutionException e) {
+            // success
+        }
+        try {
+            // 1) session name, channel = null, event name, loglevel-only, TRACE_DEBUG
+            fService.addContexts(sessionName, channelName, eventName, false, contexts, new NullProgressMonitor());
+            fail("No exeption generated");
+        } catch (ExecutionException e) {
+            // success
+        }
+    }
+
+    @Test
+    public void testCalibrate() {
+        try {
+            fShell.setScenario(SCEN_CALIBRATE_HANDLING);
+            fService.calibrate(true, new NullProgressMonitor());
+
+        } catch (ExecutionException e) {
+            fail(e.toString());
+        }
+    }
+
+    @Test
+    public void testCalibrateFailure() {
+        try {
+            fShell.setScenario(SCEN_CALIBRATE_HANDLING);
+            fService.calibrate(false, new NullProgressMonitor());
+            fail("No exeption generated");
+        } catch (ExecutionException e) {
+            // success
+        }
+    }
+
+    @Test
+    public void testCreateSession2_1() {
+
+        try {
+            fShell.setScenario(SCEN_CREATE_SESSION_2_1);
+
+            ISessionInfo sessionInfo = new SessionInfo("mysession");
+            sessionInfo.setNetworkUrl("net://172.0.0.1");
+            sessionInfo.setStreamedTrace(true);
+            ISessionInfo info = fService.createSession(sessionInfo, new NullProgressMonitor());
+            assertNotNull(info);
+            assertEquals("mysession", info.getName());
+            assertEquals("net://172.0.0.1", info.getSessionPath());
+            assertTrue(info.isStreamedTrace());
+            fService.destroySession("mysession", new NullProgressMonitor());
+
+            sessionInfo = new SessionInfo("mysession");
+            sessionInfo.setStreamedTrace(true);
+            sessionInfo.setNetworkUrl("file:///tmp");
+            info = fService.createSession(sessionInfo, new NullProgressMonitor());
+            assertNotNull(info);
+            assertEquals("mysession", info.getName());
+            assertEquals("file:///tmp", info.getSessionPath());
+            assertTrue(!info.isStreamedTrace());
+            fService.destroySession("mysession", new NullProgressMonitor());
+
+            sessionInfo = new SessionInfo("mysession");
+            sessionInfo.setStreamedTrace(true);
+            sessionInfo.setNetworkUrl("file:///tmp");
+            info = fService.createSession(sessionInfo, new NullProgressMonitor());
+            assertNotNull(info);
+            assertEquals("mysession", info.getName());
+            assertEquals("file:///tmp", info.getSessionPath());
+            assertTrue(!info.isStreamedTrace());
+            fService.destroySession("mysession", new NullProgressMonitor());
+
+            sessionInfo = new SessionInfo("mysession");
+            sessionInfo.setStreamedTrace(true);
+            sessionInfo.setControlUrl("tcp://172.0.0.1");
+            sessionInfo.setDataUrl("tcp://172.0.0.1:5343");
+            info = fService.createSession(sessionInfo, new NullProgressMonitor());
+            assertNotNull(info);
+            assertEquals("mysession", info.getName());
+            assertEquals("", info.getSessionPath()); // the complete network path is not available at this point
+            assertTrue(info.isStreamedTrace());
+            fService.destroySession("mysession", new NullProgressMonitor());
+
+            sessionInfo = new SessionInfo("mysession");
+            sessionInfo.setStreamedTrace(true);
+            sessionInfo.setNetworkUrl("net://172.0.0.1:1234:2345");
+            info = fService.createSession(sessionInfo, new NullProgressMonitor());
+            assertNotNull(info);
+            assertEquals("mysession", info.getName());
+            assertEquals("net://172.0.0.1:1234:2345", info.getSessionPath());
+            assertTrue(info.isStreamedTrace());
+            fService.destroySession("mysession", new NullProgressMonitor());
+
+            // verbose
+            enableVerbose();
+            sessionInfo = new SessionInfo("mysession");
+            sessionInfo.setStreamedTrace(true);
+            sessionInfo.setNetworkUrl("net://172.0.0.1");
+            info = fService.createSession(sessionInfo, new NullProgressMonitor());
+            assertNotNull(info);
+            assertEquals("mysession", info.getName());
+            assertEquals("net://172.0.0.1", info.getSessionPath());
+            assertTrue(info.isStreamedTrace());
+            disableVerbose();
+            fService.destroySession("mysession", new NullProgressMonitor());
+
+
+        } catch (ExecutionException e) {
+            fail(e.toString());
+        }
+    }
+
+    @Test
+    public void testCreateSessionVerbose2_1() {
+        try {
+            fShell.setScenario(SCEN_CREATE_SESSION_VERBOSE_2_1);
+
+            enableVerbose();
+            ISessionInfo sessionInfo = new SessionInfo("mysession");
+            sessionInfo.setStreamedTrace(true);
+            sessionInfo.setNetworkUrl("net://172.0.0.1");
+            ISessionInfo info = fService.createSession(sessionInfo, new NullProgressMonitor());
+            assertNotNull(info);
+            assertEquals("mysession", info.getName());
+            assertEquals("net://172.0.0.1", info.getSessionPath());
+            assertTrue(info.isStreamedTrace());
+            fService.destroySession("mysession", new NullProgressMonitor());
+        } catch (ExecutionException e) {
+            fail(e.toString());
+        } finally {
+            disableVerbose();
+        }
+    }
+
+    @Test
+    public void testCreateSnapshotSession() {
+        try {
+            fShell.setScenario(SCEN_CREATE_SNAPSHOT_SESSION);
+            ISessionInfo params = new SessionInfo("mysession");
+            params.setSnapshot(true);
+            ISessionInfo sessionInfo = fService.createSession(params, new NullProgressMonitor());
+            assertNotNull(sessionInfo);
+            assertEquals("mysession", sessionInfo.getName());
+            assertTrue(sessionInfo.isSnapshotSession());
+            assertEquals("", sessionInfo.getSessionPath());
+            assertTrue(!sessionInfo.isStreamedTrace());
+
+            assertEquals(TraceSessionState.INACTIVE, sessionInfo.getSessionState());
+
+            List<String> names = fService.getSessionNames(new NullProgressMonitor());
+            assertEquals(names.get(0), "mysession");
+
+            ISnapshotInfo snapshotInfo = fService.getSnapshotInfo("mysession", new NullProgressMonitor());
+            assertNotNull(snapshotInfo);
+            assertEquals("snapshot-1", snapshotInfo.getName());
+            assertEquals("/home/user/lttng-traces/mysession-20130913-141651", snapshotInfo.getSnapshotPath());
+            assertEquals(1, snapshotInfo.getId());
+            assertTrue(!snapshotInfo.isStreamedSnapshot());
+
+            // we need to set the snapshotInfo to so that the session path is set correctly
+            sessionInfo.setSnapshotInfo(snapshotInfo);
+            assertEquals("/home/user/lttng-traces/mysession-20130913-141651", sessionInfo.getSessionPath());
+
+            fService.recordSnapshot("mysession", new NullProgressMonitor());
+
+            fService.destroySession("mysession", new NullProgressMonitor());
+
+        } catch (ExecutionException e) {
+            fail(e.toString());
+        }
+    }
+
+    @Test
+    public void testCreateSnapshotSession2_5() {
+        try {
+            fShell.setScenario(SCEN_CREATE_SNAPSHOT_SESSION_2_5);
+            ISessionInfo params = new SessionInfo("mysession");
+            params.setSnapshot(true);
+            ISessionInfo sessionInfo = fService.createSession(params, new NullProgressMonitor());
+            assertNotNull(sessionInfo);
+            assertEquals("mysession", sessionInfo.getName());
+            assertTrue(sessionInfo.isSnapshotSession());
+            assertEquals("", sessionInfo.getSessionPath());
+            assertTrue(!sessionInfo.isStreamedTrace());
+
+            assertEquals(TraceSessionState.INACTIVE, sessionInfo.getSessionState());
+
+            List<String> names = fService.getSessionNames(new NullProgressMonitor());
+            assertEquals(names.get(0), "mysession");
+
+            ISnapshotInfo snapshotInfo = fService.getSnapshotInfo("mysession", new NullProgressMonitor());
+            assertNotNull(snapshotInfo);
+            assertEquals("snapshot-1", snapshotInfo.getName());
+            assertEquals("/home/user/lttng-traces/mysession-20130913-141651", snapshotInfo.getSnapshotPath());
+            assertEquals(1, snapshotInfo.getId());
+            assertTrue(!snapshotInfo.isStreamedSnapshot());
+
+            // we need to set the snapshotInfo to so that the session path is set correctly
+            sessionInfo.setSnapshotInfo(snapshotInfo);
+            assertEquals("/home/user/lttng-traces/mysession-20130913-141651", sessionInfo.getSessionPath());
+
+            fService.recordSnapshot("mysession", new NullProgressMonitor());
+
+            fService.destroySession("mysession", new NullProgressMonitor());
+
+        } catch (ExecutionException e) {
+            fail(e.toString());
+        }
+    }
+
+    public void testCreateStreamedSnapshotSession() {
+        try {
+            fShell.setScenario(SCEN_CREATE_STREAMED_SNAPSHOT_SESSION);
+
+            ISessionInfo params = new SessionInfo("mysession");
+            params.setNetworkUrl("net://172.0.0.1");
+            ISessionInfo sessionInfo = fService.createSession(params, new NullProgressMonitor());
+            assertNotNull(sessionInfo);
+            assertEquals("mysession", sessionInfo.getName());
+            assertTrue(sessionInfo.isSnapshotSession());
+
+            assertEquals(TraceSessionState.INACTIVE, sessionInfo.getSessionState());
+            assertTrue(sessionInfo.isStreamedTrace());
+
+            List<String> names = fService.getSessionNames(new NullProgressMonitor());
+            assertEquals(names.get(0), "mysession");
+
+            ISnapshotInfo snapshotInfo = sessionInfo.getSnapshotInfo();
+            assertNotNull(sessionInfo);
+            assertEquals("snapshot-2", snapshotInfo.getName());
+            assertEquals("net4://172.0.0.1:5342/", snapshotInfo.getSnapshotPath());
+            assertEquals(2, snapshotInfo.getId());
+            assertTrue(snapshotInfo.isStreamedSnapshot());
+
+            // we need to set the snapshotInfo to so that the session path is set correctly
+            sessionInfo.setSnapshotInfo(snapshotInfo);
+            assertEquals("net4://172.0.0.1:5342/", sessionInfo.getSessionPath());
+
+            fService.recordSnapshot("mysession", new NullProgressMonitor());
+
+            fService.destroySession("mysession", new NullProgressMonitor());
+
+        } catch (ExecutionException e) {
+            fail(e.toString());
+        }
+    }
+
+    @Test
+    public void testCreateSnapshotSessionErrors() {
+        try {
+            fShell.setScenario(SCEN_CREATE_SNAPSHOT_SESSION_ERRORS);
+
+            List<String> names = fService.getSessionNames(new NullProgressMonitor());
+            assertEquals(names.get(0), "mysession");
+        } catch (ExecutionException e) {
+            fail(e.toString());
+        }
+
+        try {
+            fService.getSnapshotInfo("blabla", new NullProgressMonitor());
+            fail("getSnapshoInfo() didn't fail");
+        } catch (ExecutionException e) {
+            // successful
+        }
+
+        try {
+            fService.recordSnapshot("blabla", new NullProgressMonitor());
+            fail("getSnapshoInfo() didn't fail");
+        } catch (ExecutionException e) {
+            // successful
+        }
+
+        try {
+            fService.recordSnapshot("mysession", new NullProgressMonitor());
+            fail("getSnapshoInfo() didn't fail");
+        } catch (ExecutionException e) {
+            // successful
+        }
+    }
+
+    @Test
+    public void testCreateLiveSession() throws ExecutionException {
+        fShell.setScenario(SCEN_CREATE_LIVE_SESSION);
+
+        ISessionInfo params = new SessionInfo("mysession");
+        params.setLive(true);
+        params.setStreamedTrace(true);
+        params.setNetworkUrl("net://127.0.0.1");
+        ISessionInfo sessionInfo = fService.createSession(params, new NullProgressMonitor());
+        assertNotNull(sessionInfo);
+        assertEquals("mysession", sessionInfo.getName());
+        assertEquals(TraceSessionState.INACTIVE, sessionInfo.getSessionState());
+        assertTrue(sessionInfo.isStreamedTrace());
+        assertTrue(sessionInfo.isLive());
+        assertEquals("net://127.0.0.1", sessionInfo.getSessionPath());
+        List<String> names = fService.getSessionNames(new NullProgressMonitor());
+        assertEquals(names.get(0), "mysession");
+        fService.destroySession("mysession", new NullProgressMonitor());
+    }
+
+    @Test
+    public void testCreateLiveSessionErrors() {
+        try {
+            fShell.setScenario(SCEN_CREATE_LIVE_SESSION_ERRORS);
+
+            ISessionInfo parameters = new SessionInfo("mysession");
+            parameters.setLive(true);
+            parameters.setSnapshot(true);
+            fService.createSession(parameters, new NullProgressMonitor());
+            fail("createSession() didn't fail");
+        } catch (ExecutionException e) {
+            // successful
+        }
+
+        try {
+            ISessionInfo parameters = new SessionInfo("mysession");
+            parameters.setNetworkUrl("blah");
+            parameters.setLive(true);
+            fService.createSession(parameters, new NullProgressMonitor());
+            fail("createSession() didn't fail");
+        } catch (ExecutionException e) {
+            // successful
+        }
+
+        try {
+            ISessionInfo parameters = new SessionInfo("mysession");
+            parameters.setControlUrl("net://127.0.0.1");
+            parameters.setLive(true);
+            fService.createSession(parameters, new NullProgressMonitor());
+            fail("createSession() didn't fail");
+        } catch (ExecutionException e) {
+            // successful
+        }
+    }
+
+    private static void enableVerbose() {
+        // verbose
+        ControlCommandLogger.init(ControlPreferences.getInstance().getLogfilePath(), false);
+        ControlPreferences.getInstance().getPreferenceStore().setDefault(ControlPreferences.TRACE_CONTROL_LOG_COMMANDS_PREF, true);
+        ControlPreferences.getInstance().getPreferenceStore().setDefault(ControlPreferences.TRACE_CONTROL_VERBOSE_LEVEL_PREF, ControlPreferences.TRACE_CONTROL_VERBOSE_LEVEL_V_V_VERBOSE);
+    }
+
+    private static void disableVerbose() {
+        ControlPreferences.getInstance().getPreferenceStore().setDefault(ControlPreferences.TRACE_CONTROL_LOG_COMMANDS_PREF, false);
+    }
+
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/stubs/org/eclipse/tracecompass/internal/lttng2/control/stubs/dialogs/AddContextDialogStub.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/stubs/org/eclipse/tracecompass/internal/lttng2/control/stubs/dialogs/AddContextDialogStub.java
new file mode 100644 (file)
index 0000000..c929186
--- /dev/null
@@ -0,0 +1,63 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs;
+
+import java.util.ArrayList;
+import java.util.HashSet;
+import java.util.Iterator;
+import java.util.List;
+import java.util.Set;
+
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.IAddContextDialog;
+
+/**
+ * Add Context dialog stub.
+ */
+@SuppressWarnings("javadoc")
+public class AddContextDialogStub implements IAddContextDialog {
+
+    private Set<String> fAvailableContexts = null;
+    private List<String> fContexts = null;
+
+    @Override
+    public int open() {
+        return 0;
+    }
+
+    @Override
+    public void setAvalibleContexts(List<String> contexts) {
+        fAvailableContexts = new HashSet<>();
+        fAvailableContexts.addAll(contexts);
+    }
+
+    @Override
+    public List<String> getContexts() {
+        List<String> ret = new ArrayList<>();
+        ret.addAll(fContexts);
+        return ret;
+    }
+
+    public void setContexts(List<String> contexts) throws IllegalArgumentException{
+        fContexts = new ArrayList<>();
+        fContexts.addAll(contexts);
+        // If availableContexts are null we cannot verify
+        if (fAvailableContexts != null) {
+            for (Iterator<String> iterator = fContexts.iterator(); iterator.hasNext();) {
+                String string = iterator.next();
+                if (!fAvailableContexts.contains(string)) {
+                    throw new IllegalArgumentException();
+                }
+            }
+        }
+    }
+}
+
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/stubs/org/eclipse/tracecompass/internal/lttng2/control/stubs/dialogs/CreateSessionDialogStub.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/stubs/org/eclipse/tracecompass/internal/lttng2/control/stubs/dialogs/CreateSessionDialogStub.java
new file mode 100644 (file)
index 0000000..0d4ca9d
--- /dev/null
@@ -0,0 +1,101 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
+ *   Marc-Andre Laperle - Support for creating a live session
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs;
+
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISessionInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.SessionInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.ICreateSessionDialog;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionGroup;
+
+/**
+ * Create session dialog stub implementation.
+ */
+@SuppressWarnings("javadoc")
+public class CreateSessionDialogStub implements ICreateSessionDialog {
+
+    public String fName = "mysession";
+    public String fPath = null;
+    private boolean fIsStreamedTrace = false;
+    private String fNetworkUrl = null;
+    private String fControlUrl = null;
+    private String fDataUrl = null;
+    private boolean fIsSnapshot;
+    private boolean fIsLive = false;
+    private long fLiveDelay = 0;
+
+    @Override
+    public void initialize(TraceSessionGroup group) {
+    }
+
+    @Override
+    public int open() {
+        return 0;
+    }
+
+    public void setSessionPath(String path) {
+        fPath = path;
+    }
+
+    public void setSessionName(String name) {
+        fName = name;
+    }
+
+    public void setStreamedTrace(boolean isStreamedTrace) {
+        fIsStreamedTrace = isStreamedTrace;
+    }
+
+    public void setNetworkUrl(String fNetworkUrl) {
+        this.fNetworkUrl = fNetworkUrl;
+    }
+
+    public void setControlUrl(String fControlUrl) {
+        this.fControlUrl = fControlUrl;
+    }
+
+    public void setDataUrl(String fDataUrl) {
+        this.fDataUrl = fDataUrl;
+    }
+
+    public void setSnapshot(boolean isSnapshot) {
+        fIsSnapshot = isSnapshot;
+    }
+
+    public void setLive(boolean isLive) {
+        fIsLive = isLive;
+    }
+
+    public void setLiveDelay(int liveDelay) {
+        fLiveDelay = liveDelay;
+    }
+
+    @Override
+    public ISessionInfo getParameters() {
+        ISessionInfo sessionInfo = new SessionInfo(fName);
+
+        if (fIsStreamedTrace) {
+            sessionInfo.setNetworkUrl(fNetworkUrl);
+            sessionInfo.setControlUrl(fControlUrl);
+            sessionInfo.setDataUrl(fDataUrl);
+            sessionInfo.setStreamedTrace(true);
+        } else if (fPath != null) {
+            sessionInfo.setSessionPath(fPath);
+        }
+
+        sessionInfo.setLive(fIsLive);
+        sessionInfo.setLiveDelay(fLiveDelay);
+        sessionInfo.setSnapshot(fIsSnapshot);
+
+        return sessionInfo;
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/stubs/org/eclipse/tracecompass/internal/lttng2/control/stubs/dialogs/DestroyConfirmDialogStub.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/stubs/org/eclipse/tracecompass/internal/lttng2/control/stubs/dialogs/DestroyConfirmDialogStub.java
new file mode 100644 (file)
index 0000000..6cfc86a
--- /dev/null
@@ -0,0 +1,26 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs;
+
+import org.eclipse.swt.widgets.Shell;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.IConfirmDialog;
+
+/**
+ * A confirmation dialog stub implementation.
+ */
+public class DestroyConfirmDialogStub implements IConfirmDialog {
+
+    @Override
+    public boolean openConfirm(Shell parent, String title, String message) {
+        return true;
+    }
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/stubs/org/eclipse/tracecompass/internal/lttng2/control/stubs/dialogs/EnableChannelDialogStub.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/stubs/org/eclipse/tracecompass/internal/lttng2/control/stubs/dialogs/EnableChannelDialogStub.java
new file mode 100644 (file)
index 0000000..570f0a7
--- /dev/null
@@ -0,0 +1,93 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs;
+
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IChannelInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.BufferType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.ChannelInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.IEnableChannelDialog;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent;
+
+/**
+ * Create channel dialog stub implementation.
+ */
+@SuppressWarnings("javadoc")
+public class EnableChannelDialogStub implements IEnableChannelDialog {
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+    private TraceDomainComponent fDomain;
+    private ChannelInfo fChannelInfo;
+    private boolean fIsKernel;
+
+    // ------------------------------------------------------------------------
+    // Constructor
+    // ------------------------------------------------------------------------
+    public EnableChannelDialogStub() {
+        fChannelInfo = new ChannelInfo("mychannel");
+        fChannelInfo.setNumberOfSubBuffers(4);
+        fChannelInfo.setOverwriteMode(true);
+        fChannelInfo.setReadTimer(200);
+        fChannelInfo.setSwitchTimer(100);
+        fChannelInfo.setSubBufferSize(16384);
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+    public void setIsKernel(boolean isKernel) {
+        fIsKernel = isKernel;
+    }
+
+    @Override
+    public IChannelInfo getChannelInfo() {
+        return fChannelInfo;
+    }
+
+    @Override
+    public void setDomainComponent(TraceDomainComponent domain) {
+        fDomain = domain;
+        if (fDomain != null) {
+            fIsKernel = fDomain.isKernel();
+        }
+    }
+
+    @Override
+    public int open() {
+        return 0;
+    }
+
+    @Override
+    public boolean isKernel() {
+        return fIsKernel;
+    }
+
+    @Override
+    public void setHasKernel(boolean hasKernel) {
+        // Do nothing
+    }
+
+    public void setChannelInfo(ChannelInfo info) {
+        fChannelInfo = info;
+    }
+
+    @Override
+    public void setTargetNodeComponent(TargetNodeComponent node) {
+        // Do nothing
+    }
+
+    public void setBufferType (BufferType bufferType) {
+        fChannelInfo.setBufferType(bufferType);
+    }
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/stubs/org/eclipse/tracecompass/internal/lttng2/control/stubs/dialogs/EnableEventsDialogStub.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/stubs/org/eclipse/tracecompass/internal/lttng2/control/stubs/dialogs/EnableEventsDialogStub.java
new file mode 100644 (file)
index 0000000..0e3e9e7
--- /dev/null
@@ -0,0 +1,234 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.LogLevelType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.IEnableEventsDialog;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceProviderGroup;
+
+/**
+ * Enable events dialog stub implementation.
+ */
+@SuppressWarnings("javadoc")
+public class EnableEventsDialogStub implements IEnableEventsDialog {
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+    private boolean fIsKernel;
+    private boolean fIsTracePoints;
+    private boolean fIsAllTracePoints;
+    private boolean fIsSysCalls;
+    private boolean fIsDynamicProbe;
+    private String fProbeEventName;
+    private String fDynamicProbe;
+    private boolean fIsFunctionProbe;
+    private String fFunctionEventName;
+    private String fFunctionProbe;
+    private boolean fIsWildcard;
+    private String fWildcard;
+    private boolean fIsLogLevel;
+    private String fLogLevelEventName;
+    private TraceLogLevel fLogLevel;
+    private LogLevelType fLogLevelType;
+    private String fFilter;
+    private List<String> fNames = new ArrayList<>();
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+    public void setIsKernel(boolean isKernel) {
+        fIsKernel = isKernel;
+    }
+
+    public void setIsTracePoints(boolean isTracePoints) {
+        fIsTracePoints = isTracePoints;
+    }
+
+    public void setIsAllTracePoints(boolean isAllTracePoints) {
+        fIsAllTracePoints = isAllTracePoints;
+    }
+
+    public void setIsSysCalls(boolean isSysCalls) {
+        this.fIsSysCalls = isSysCalls;
+    }
+
+    public void setIsDynamicProbe(boolean isDynamicProbe) {
+        fIsDynamicProbe = isDynamicProbe;
+    }
+
+    public void setProbeEventName(String probeEventName) {
+        fProbeEventName = probeEventName;
+    }
+
+    public void setDynamicProbe(String dynamicProbe) {
+        fDynamicProbe = dynamicProbe;
+    }
+
+    public void setIsFunctionProbe(boolean isFunctionProbe) {
+        fIsFunctionProbe = isFunctionProbe;
+    }
+
+    public void setFunctionEventName(String functionEventName) {
+        fFunctionEventName = functionEventName;
+    }
+
+    public void setFunctionProbe(String functionProbe) {
+        fFunctionProbe = functionProbe;
+    }
+
+    public void setIsWildcard(boolean isWildcard) {
+        fIsWildcard = isWildcard;
+    }
+
+    public void setWildcard(String wildcard) {
+        fWildcard = wildcard;
+    }
+
+    public void setIsLogLevel(boolean isLogLevel) {
+        fIsLogLevel = isLogLevel;
+    }
+
+    public void setLogLevelEventName(String logLevelEventName) {
+        fLogLevelEventName = logLevelEventName;
+    }
+
+    public void setLogLevel(TraceLogLevel logLevel) {
+        fLogLevel = logLevel;
+    }
+
+    public void setLogLevelType(LogLevelType logLevelType) {
+        fLogLevelType = logLevelType;
+    }
+
+    public void setNames(List<String> names) {
+        fNames = names;
+    }
+
+    public void setFilterExpression(String filter) {
+        fFilter = filter;
+    }
+
+    @Override
+    public boolean isTracepoints() {
+        return fIsTracePoints;
+    }
+
+    @Override
+    public boolean isAllTracePoints() {
+        return fIsAllTracePoints;
+    }
+
+    @Override
+    public boolean isSysCalls() {
+        return fIsSysCalls;
+    }
+
+    @Override
+    public boolean isAllSysCalls() {
+        return fIsSysCalls;
+    }
+
+    @Override
+    public List<String> getEventNames() {
+        return fNames;
+    }
+
+    @Override
+    public boolean isDynamicProbe() {
+        return fIsDynamicProbe;
+    }
+
+    @Override
+    public String getProbeEventName() {
+        return fProbeEventName;
+    }
+
+    @Override
+    public String getProbeName() {
+        return fDynamicProbe;
+    }
+
+    @Override
+    public boolean isDynamicFunctionProbe() {
+        return fIsFunctionProbe;
+    }
+
+    @Override
+    public String getFunctionEventName() {
+        return fFunctionEventName;
+    }
+
+    @Override
+    public String getFunction() {
+        return fFunctionProbe;
+    }
+
+    @Override
+    public boolean isWildcard() {
+        return fIsWildcard;
+    }
+
+    @Override
+    public String getWildcard() {
+        return fWildcard;
+    }
+
+    @Override
+    public boolean isLogLevel() {
+        return fIsLogLevel;
+    }
+
+    @Override
+    public LogLevelType getLogLevelType() {
+        return fLogLevelType;
+    }
+
+    @Override
+    public TraceLogLevel getLogLevel() {
+        return fLogLevel;
+    }
+
+    @Override
+    public String getLogLevelEventName() {
+        return fLogLevelEventName;
+    }
+
+    @Override
+    public boolean isKernel() {
+        return fIsKernel;
+    }
+
+    @Override
+    public void setTraceProviderGroup(TraceProviderGroup providerGroup) {
+    }
+
+    @Override
+    public void setTraceDomainComponent(TraceDomainComponent domain) {
+    }
+
+    @Override
+    public int open() {
+        return 0;
+    }
+
+    @Override
+    public String getFilterExpression() {
+        return fFilter;
+    }
+
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/stubs/org/eclipse/tracecompass/internal/lttng2/control/stubs/dialogs/GetEventInfoDialogStub.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/stubs/org/eclipse/tracecompass/internal/lttng2/control/stubs/dialogs/GetEventInfoDialogStub.java
new file mode 100644 (file)
index 0000000..c08978e
--- /dev/null
@@ -0,0 +1,68 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs;
+
+import java.util.Arrays;
+
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.IGetEventInfoDialog;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
+
+/**
+ * Get event information dialog stub implementation.
+ */
+public class GetEventInfoDialogStub implements IGetEventInfoDialog {
+
+    private TraceSessionComponent[] fSessions;
+    private String fFilterExpression;
+
+    @Override
+    public TraceSessionComponent getSession() {
+        return fSessions[0];
+    }
+
+    @Override
+    public TraceChannelComponent getChannel() {
+        return null;
+    }
+
+    @Override
+    public void setIsKernel(boolean isKernel) {
+    }
+
+    @Override
+    public void setSessions(TraceSessionComponent[] sessions) {
+        if (sessions != null) {
+            fSessions = Arrays.copyOf(sessions, sessions.length);
+            return;
+        }
+        fSessions = null;
+    }
+
+    @Override
+    public String getFilterExpression() {
+        return fFilterExpression;
+    }
+
+    @Override
+    public int open() {
+        return 0;
+    }
+
+    /**
+     * @param filter the filter to set
+     */
+    public void setFilterExpression(String filter) {
+        fFilterExpression = filter;
+    }
+}
+
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/stubs/org/eclipse/tracecompass/internal/lttng2/control/stubs/service/TestRemoteSystemProxy.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/stubs/org/eclipse/tracecompass/internal/lttng2/control/stubs/service/TestRemoteSystemProxy.java
new file mode 100644 (file)
index 0000000..4b7c501
--- /dev/null
@@ -0,0 +1,78 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2015 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Markus Schorn - Bug 448058: Use org.eclipse.remote in favor of RSE
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.stubs.service;
+
+import static org.eclipse.tracecompass.common.core.NonNullUtils.checkNotNull;
+
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.remote.core.IRemoteConnection;
+import org.eclipse.tracecompass.internal.lttng2.control.stubs.shells.LTTngToolsFileShell;
+import org.eclipse.tracecompass.tmf.remote.core.proxy.RemoteSystemProxy;
+import org.eclipse.tracecompass.tmf.remote.core.shell.ICommandShell;
+
+@SuppressWarnings("javadoc")
+public class TestRemoteSystemProxy extends RemoteSystemProxy {
+
+    public TestRemoteSystemProxy(IRemoteConnection host) {
+        super(checkNotNull(host));
+    }
+
+    private LTTngToolsFileShell fShell = null;
+    private String fTestFile = null;
+    private String fScenario = null;
+
+    @Override
+    public void connect(IProgressMonitor monitor) throws ExecutionException {
+    }
+
+    @Override
+    public void disconnect() {
+        fShell = null;
+    }
+
+    @Override
+    public void dispose() {
+    }
+
+    @Override
+    public ICommandShell createCommandShell() {
+        LTTngToolsFileShell shell = fShell;
+        if (shell == null) {
+            shell = new LTTngToolsFileShell();
+            if ((fTestFile != null) && (fScenario != null)) {
+                shell.loadScenarioFile(fTestFile);
+                shell.setScenario(fScenario);
+                fShell = shell;
+            }
+            fShell = shell;
+        }
+        return shell;
+    }
+
+    public void setTestFile(String testFile) {
+        fTestFile = testFile;
+    }
+
+    public void setScenario(String scenario) {
+        fScenario = scenario;
+        if (fShell != null) {
+            fShell.setScenario(fScenario);
+        }
+    }
+
+    @Override
+    public boolean isConnected() {
+        return true;
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/stubs/org/eclipse/tracecompass/internal/lttng2/control/stubs/shells/LTTngToolsFileShell.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/stubs/org/eclipse/tracecompass/internal/lttng2/control/stubs/shells/LTTngToolsFileShell.java
new file mode 100644 (file)
index 0000000..5d6bf94
--- /dev/null
@@ -0,0 +1,286 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2015 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Markus Schorn - Bug 448058: Use org.eclipse.remote in favor of RSE
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.stubs.shells;
+
+import static org.eclipse.tracecompass.common.core.NonNullUtils.checkNotNull;
+
+import java.io.BufferedReader;
+import java.io.DataInputStream;
+import java.io.FileInputStream;
+import java.io.IOException;
+import java.io.InputStreamReader;
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.HashMap;
+import java.util.Iterator;
+import java.util.List;
+import java.util.Map;
+import java.util.regex.Matcher;
+import java.util.regex.Pattern;
+
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.tracecompass.internal.tmf.remote.core.stubs.shells.TestCommandShell;
+import org.eclipse.tracecompass.tmf.remote.core.shell.ICommandInput;
+import org.eclipse.tracecompass.tmf.remote.core.shell.ICommandResult;
+
+@SuppressWarnings("javadoc")
+public class LTTngToolsFileShell extends TestCommandShell {
+
+    // ------------------------------------------------------------------------
+    // CONSTANTS
+    // ------------------------------------------------------------------------
+    private final static String SCENARIO_KEY = "<SCENARIO>";
+    private final static String SCENARIO_END_KEY = "</SCENARIO>";
+    private final static String INPUT_KEY = "<COMMAND_INPUT>";
+    private final static String INPUT_END_KEY = "</COMMAND_INPUT>";
+    private final static String RESULT_KEY = "<COMMAND_RESULT>";
+    private final static String OUTPUT_KEY = "<COMMAND_OUTPUT>";
+    private final static String OUTPUT_END_KEY = "</COMMAND_OUTPUT>";
+    private final static String ERROR_OUTPUT_KEY = "<COMMAND_ERROR_OUTPUT>";
+    private final static String ERROR_OUTPUT_END_KEY = "</COMMAND_ERROR_OUTPUT>";
+    private final static String COMMENT_KEY = "#.*";
+
+    private final static Pattern LTTNG_LIST_SESSION_PATTERN = Pattern.compile("lttng\\s+list\\s+(.+)");
+    private final static String LTTNG_LIST_PROVIDER_PATTERN = "lttng\\s+list\\s+(-u|-k)";
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+    private String fScenariofile;
+    private String fScenario;
+
+    private final Map<String, Map<String, ICommandResult>> fScenarioMap = new HashMap<>();
+    private final Map<String, Integer> fSessionNameMap = new HashMap<>();
+
+    /**
+     * Parse a scenario file with the format:
+     *
+     * <pre>
+     * &lt;SCENARIO&gt;
+     * ScenarioName
+     *
+     * &lt;COMMAND_INPUT&gt;
+     * Command
+     * &lt;/COMMAND_INPUT&gt;
+     *
+     * &lt;COMMAND_RESULT&gt;
+     * CommandResult
+     * &lt;/COMMAND_RESULT&gt;
+     *
+     * &lt;COMMAND_OUTPUT&gt;
+     * CommandOutput
+     * &lt;COMMAND_ERROR_OUTPUT&gt;
+     * CommandErrorOutput
+     * &lt;/COMMAND_ERROR_OUTPUT&gt;
+     * &lt;/COMMAND_OUTPUT&gt;
+     *
+     * &lt;/SCENARIO&gt;
+     *
+     * Where: ScenarioName - is the scenario name
+     *        Command - the command line string
+     *        CommandResult - the result integer of the command (0 for success, 1 for failure)
+     *        CommandOutput - the command output string (multi-line possible)
+     *        CommandErrorOutput - the command error output string (multi-line possible)
+     *
+     * Note: 1) There can be many scenarios per file
+     *       2) There can be many (Command-CommandResult-CommandOutput) triples per scenario
+     * 3) Lines starting with # will be ignored (comments)
+     *
+     * <pre>
+     * @param scenariofile - path to scenario file
+     */
+    public synchronized void loadScenarioFile(String scenariofile) {
+        fScenariofile = scenariofile;
+
+        // clean up map
+        Collection<Map<String, ICommandResult>> values = fScenarioMap.values();
+        for (Iterator<Map<String, ICommandResult>> iterator = values.iterator(); iterator.hasNext();) {
+            Map<String, ICommandResult> map = iterator.next();
+            map.clear();
+        }
+        fScenarioMap.clear();
+
+        // load from file
+
+        // Open the file
+        try (FileInputStream fstream = new FileInputStream(fScenariofile);
+                DataInputStream in = new DataInputStream(fstream);
+                BufferedReader br = new BufferedReader(new InputStreamReader(in));) {
+            String strLine;
+
+            // Read File Line by Line
+
+            // Temporary map for generating instance numbers for lttng list
+            // <session> commands.
+            // The numbers are per scenario.
+            Map<String, Integer> tmpSessionNameMap = new HashMap<>();
+            while ((strLine = br.readLine()) != null) {
+
+                // Ignore comments
+                if (isComment(strLine)) {
+                    continue;
+                }
+
+                if (SCENARIO_KEY.equals(strLine)) {
+                    // scenario start
+
+                    // Ignore comments
+                    strLine = br.readLine();
+                    while (isComment(strLine)) {
+                        strLine = br.readLine();
+                    }
+
+                    String scenario = strLine;
+                    Map<String, ICommandResult> commandMap = new HashMap<>();
+                    fScenarioMap.put(scenario, commandMap);
+                    List<String> output = null;
+                    List<String> errorOutput = null;
+                    String input = null;
+                    boolean inOutput = false;
+                    boolean inErrorOutput = false;
+                    int result = 0;
+                    tmpSessionNameMap.clear();
+                    while ((strLine = br.readLine()) != null) {
+                        // Ignore comments
+                        if (isComment(strLine)) {
+                            continue;
+                        }
+
+                        if (SCENARIO_END_KEY.equals(strLine)) {
+                            // Scenario is finished
+                            break;
+                        }
+                        if (INPUT_KEY.equals(strLine)) {
+                            strLine = br.readLine();
+                            // Ignore comments
+                            while (isComment(strLine)) {
+                                strLine = br.readLine();
+                            }
+                            // Read command
+                            input = strLine;
+
+                            // Handle instances of 'lttng list
+                            // <session"-command
+                            Matcher matcher = LTTNG_LIST_SESSION_PATTERN.matcher(strLine);
+                            if (matcher.matches() && !input.matches(LTTNG_LIST_PROVIDER_PATTERN)) {
+                                String sessionName = matcher.group(1).trim();
+                                Integer i = tmpSessionNameMap.get(sessionName);
+                                if (i != null) {
+                                    i++;
+                                } else {
+                                    i = 0;
+                                }
+                                tmpSessionNameMap.put(sessionName, i);
+                                input += String.valueOf(i);
+                            }
+                        } else if (INPUT_END_KEY.equals(strLine)) {
+                            // Initialize output array
+                            output = new ArrayList<>();
+                            errorOutput = new ArrayList<>();
+                        } else if (RESULT_KEY.equals(strLine)) {
+                            strLine = br.readLine();
+                            // Ignore comments
+                            while (isComment(strLine)) {
+                                strLine = br.readLine();
+                            }
+                            // Save result value
+                            result = Integer.parseInt(strLine);
+                        } else if (OUTPUT_END_KEY.equals(strLine)) {
+                            // Save output/result in command map
+                            if (output != null && errorOutput != null) {
+                                commandMap.put(input, createCommandResult(result,
+                                        checkNotNull(output.toArray(new String[output.size()])),
+                                        checkNotNull(errorOutput.toArray(new String[errorOutput.size()]))));
+                            }
+                            inOutput = false;
+                        } else if (OUTPUT_KEY.equals(strLine)) {
+                            // first line of output
+                            inOutput = true;
+                        } else if (ERROR_OUTPUT_KEY.equals(strLine)) {
+                            // first line of output
+                            inErrorOutput = true;
+                        } else if (ERROR_OUTPUT_END_KEY.equals(strLine)) {
+                            inErrorOutput = false;
+                        } else if (inOutput) {
+                            while (isComment(strLine)) {
+                                strLine = br.readLine();
+                            }
+                            // lines of output/error output
+                            if (errorOutput != null && inErrorOutput) {
+                                errorOutput.add(strLine);
+                            } else if (output != null) {
+                                output.add(strLine);
+                            }
+                        }
+                        // else {
+                        // if (RESULT_END_KEY.equals(strLine)) {
+                        // nothing to do
+                        // }
+                    }
+                }
+            }
+        } catch (IOException e) {
+            e.printStackTrace();
+        }
+    }
+
+    // Set the scenario to consider in executeCommand()
+    public synchronized void setScenario(String scenario) {
+        fScenario = scenario;
+        fSessionNameMap.clear();
+        if (!fScenarioMap.containsKey(fScenario)) {
+            throw new IllegalArgumentException();
+        }
+    }
+
+    @Override
+    public synchronized ICommandResult executeCommand(ICommandInput command, IProgressMonitor monitor) throws ExecutionException {
+        Map<String, ICommandResult> commands = fScenarioMap.get(fScenario);
+        String commandLine = command.toString();
+        String fullCommand = commandLine;
+
+        Matcher matcher = LTTNG_LIST_SESSION_PATTERN.matcher(commandLine);
+        if (matcher.matches() && !commandLine.matches(LTTNG_LIST_PROVIDER_PATTERN)) {
+            String sessionName = matcher.group(1).trim();
+            Integer i = fSessionNameMap.get(sessionName);
+            if (i != null) {
+                i++;
+            } else {
+                i = 0;
+            }
+            fSessionNameMap.put(sessionName, i);
+            fullCommand += String.valueOf(i);
+        }
+
+        if (commands.containsKey(fullCommand)) {
+            return checkNotNull(commands.get(fullCommand));
+        }
+
+        String[] output = new String[1];
+        output[0] = String.valueOf("Command not found");
+        ICommandResult result = createCommandResult(1, output, output);
+        return result;
+    }
+
+    // ------------------------------------------------------------------------
+    // Helper methods
+    // ------------------------------------------------------------------------
+
+    private static boolean isComment(String line) {
+        if (line == null) {
+            throw new RuntimeException("line is null");
+        }
+        return line.matches(COMMENT_KEY);
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/testfiles/CreateSessionTest.cfg b/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/testfiles/CreateSessionTest.cfg
new file mode 100644 (file)
index 0000000..870b87a
--- /dev/null
@@ -0,0 +1,228 @@
+####################################################################
+# 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:
+#    Bernd Hufmann - Initial API and implementation
+####################################################################
+####################################################################
+# Scenario: Initialize
+####################################################################
+<SCENARIO>
+Initialize
+<COMMAND_INPUT>
+lttng version
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+lttng version 2.0.0 - Annedd'ale
+Web site: http://lttng.org/
+
+lttng is free software and under the GPL license and part LGPL
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Currently no available tracing session
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list -k
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Kernel events
+-------------
+      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint)
+      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint)
+      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint)
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list -u
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+UST events:
+-------------
+
+PID: 9379 - Name: /home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello
+    ust_tests_hello:tptest_sighandler (loglevel: TRACE_WARNING (4)) (type: tracepoint)
+    ust_tests_hello:tptest (loglevel: TRACE_DEBUG_FUNCTION (12)) (type: tracepoint)
+
+PID: 4852 - Name: /home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello
+    ust_tests_hello:tptest_sighandler (loglevel: TRACE_WARNING (4)) (type: tracepoint)
+    ust_tests_hello:tptest (loglevel: TRACE_DEBUG_FUNCTION (12)) (type: tracepoint)
+
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test "lttng create <session> with LTTng 2.1 options
+####################################################################
+##################################################################
+<SCENARIO>
+CreateSessionFileProto
+<COMMAND_INPUT>
+lttng create mysession -U file:///tmp
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Session mysession created.
+Traces will be written in file:///tmp
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession: [inactive]
+    Trace path: file:///tmp
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng destroy mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Session mysession destroyed.
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+##################################################################
+<SCENARIO>
+CreateSessionControlData
+<COMMAND_INPUT>
+lttng create mysession -C tcp://172.0.0.1 -D tcp://172.0.0.1:5343
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Session mysession created.
+Control URL tcp://172.0.0.1 set for session mysession
+Data URL tcp://172.0.0.1:5343 set for session mysession
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession: [inactive]
+    Trace path: tcp://172.0.0.1:5342 [data: 5343]
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng destroy mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Session mysession destroyed.
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+##################################################################
+<SCENARIO>
+CreateSessionNetwork
+<COMMAND_INPUT>
+lttng create mysession -U net://172.0.0.1:1234:2345
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Session mysession created.
+Traces will be written in net://172.0.0.1:1234:2345
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession: [inactive]
+    Trace path: net://172.0.0.1:1234 [data: 2345]
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng destroy mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Session mysession2 destroyed.
+</COMMAND_OUTPUT>
+
+</SCENARIO>
+
+##################################################################
+<SCENARIO>
+CreateSessionNetwork2
+<COMMAND_INPUT>
+lttng create mysession -U net6://[ffff::eeee:dddd:cccc:0]
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Session mysession created.
+Traces will be written in net6://[ffff::eeee:dddd:cccc:0]
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession: [inactive]
+    Trace path:  net://[ffff::eeee:dddd:cccc:0]:5342/mysession-20130221-144451 [data: 5343]
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng destroy mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Session mysession2 destroyed.
+</COMMAND_OUTPUT>
+
+</SCENARIO>
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/testfiles/CreateSessionTest2.cfg b/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/testfiles/CreateSessionTest2.cfg
new file mode 100644 (file)
index 0000000..a8bd262
--- /dev/null
@@ -0,0 +1,158 @@
+####################################################################
+# Copyright (c) 2013 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:
+#    Bernd Hufmann - Initial API and implementation
+####################################################################
+####################################################################
+# Scenario: Initialize
+####################################################################
+<SCENARIO>
+Initialize
+<COMMAND_INPUT>
+lttng version
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+lttng version 2.3.0 - Dominus Vobiscum
+
+A very succulent line-up of beers brewed at Microbrasserie Charlevoix. Elaborated starting from special malts and fermented with a Belgian yeast. These beers are refermented in bottle and will make you discover the richness of wheat, amber and triple styles.
+
+Web site: http://lttng.org
+
+lttng is free software and under the GPL license and part LGPL
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Currently no available tracing session
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list -k
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Kernel events
+-------------
+      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint)
+      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint)
+      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint)
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list -u -f
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+UST events:
+-------------
+
+PID: 9379 - Name: /home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello
+    ust_tests_hello:tptest_sighandler (loglevel: TRACE_WARNING (4)) (type: tracepoint)
+    ust_tests_hello:tptest (loglevel: TRACE_DEBUG_FUNCTION (12)) (type: tracepoint)
+
+PID: 4852 - Name: /home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello
+    ust_tests_hello:tptest_sighandler (loglevel: TRACE_WARNING (4)) (type: tracepoint)
+    ust_tests_hello:tptest (loglevel: TRACE_DEBUG_FUNCTION (12)) (type: tracepoint)
+
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test "lttng create <session> --snapshot" LTTng 2.3
+####################################################################
+<SCENARIO>
+ScenCreateSession
+<COMMAND_INPUT>
+lttng create mysession --snapshot
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Session mysession created.
+Default snapshot output set to: /home/user/lttng-traces/mysession-20130913-141651
+Snapshot mode set. Every channel enabled for that session will be set in overwrite mode and mmap output.
+</COMMAND_OUTPUT>
+#------------------------------------------------------------------------------
+<COMMAND_INPUT>
+lttng list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession: [inactive snapshot]
+    Trace path:
+
+</COMMAND_OUTPUT>
+#------------------------------------------------------------------------------
+<COMMAND_INPUT>
+lttng snapshot list-output -s mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Snapshot output list for session mysession
+    [1] snapshot-1: /home/user/lttng-traces/mysession-20130913-141651
+</COMMAND_OUTPUT>
+#------------------------------------------------------------------------------
+<COMMAND_INPUT>
+lttng start mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing started for session mysession.
+</COMMAND_OUTPUT>
+#------------------------------------------------------------------------------
+<COMMAND_INPUT>
+lttng snapshot record -s mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+    Snapshot recorded successfully for session mysession
+</COMMAND_OUTPUT>
+#------------------------------------------------------------------------------
+<COMMAND_INPUT>
+lttng stop mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing stopped for session mysession.
+</COMMAND_OUTPUT>
+#------------------------------------------------------------------------------
+<COMMAND_INPUT>
+lttng destroy mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Session mysession destroyed.
+</COMMAND_OUTPUT>
+</SCENARIO>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/testfiles/CreateSessionTestMi.cfg b/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/testfiles/CreateSessionTestMi.cfg
new file mode 100644 (file)
index 0000000..330f25a
--- /dev/null
@@ -0,0 +1,528 @@
+####################################################################
+# Copyright (c) 2014 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:
+#    Jonathan Rajotte - Initial API and implementation
+####################################################################
+####################################################################
+# Scenario: Initialize
+####################################################################
+<SCENARIO>
+Initialize
+<COMMAND_INPUT>
+lttng --mi xml version
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>version</name>
+  <output>
+    <version>
+      <string>2.6.0</string>
+      <major>2</major>
+      <minor>6</minor>
+      <commit></commit>
+      <patchLevel>0</patchLevel>
+      <name>TestMI</name>
+      <description>Lorem ipsum</description>
+      <url>http://lttng.org</url>
+      <license>lttng is free software and under the GPL license and part LGPL</license>
+    </version>
+  </output>
+</command>
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng --mi xml list
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>list</name>
+  <output>
+    <sessions/>
+  </output>
+</command>
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng --mi xml list -k
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>list</name>
+  <output>
+    <domains>
+      <domain>
+        <type>KERNEL</type>
+        <buffer_type>PER_PID</buffer_type>
+        <events>
+          <event>
+            <name>sched_kthread_stop</name>
+            <type>TRACEPOINT</type>
+            <enabled>true</enabled>
+            <filter>false</filter>
+            <loglevel>TRACE_EMERG</loglevel>
+            <loglevel_type>ALL</loglevel_type>
+            <exclusion>false</exclusion>
+          </event>
+          <event>
+            <name>sched_kthread_stop_ret</name>
+            <type>TRACEPOINT</type>
+            <enabled>true</enabled>
+            <filter>false</filter>
+            <loglevel>TRACE_EMERG</loglevel>
+            <loglevel_type>ALL</loglevel_type>
+            <exclusion>false</exclusion>
+          </event>
+          <event>
+            <name>sched_wakeup_new</name>
+            <type>TRACEPOINT</type>
+            <enabled>true</enabled>
+            <filter>false</filter>
+            <loglevel>TRACE_EMERG</loglevel>
+            <loglevel_type>ALL</loglevel_type>
+            <exclusion>false</exclusion>
+          </event>
+        </events>
+      </domain>
+    </domains>
+  </output>
+</command>
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng --mi xml list -u -f
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>list</name>
+  <output>
+    <domains>
+      <domain>
+        <type>UST</type>
+        <buffer_type>PER_PID</buffer_type>
+        <pids>
+          <pid>
+            <id>9379</id>
+            <name>/home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello</name>
+            <events>
+              <event>
+                <name>ust_tests_hello:tptest_sighandler</name>
+                <type>TRACEPOINT</type>
+                <enabled>true</enabled>
+                <filter>false</filter>
+                <loglevel>TRACE_DEBUG_MODULE</loglevel>
+                <loglevel_type>ALL</loglevel_type>
+                <exclusion>false</exclusion>
+                <event_fields/>
+              </event>
+              <event>
+                <name>ust_tests_hello:tptest</name>
+                <type>TRACEPOINT</type>
+                <enabled>true</enabled>
+                <filter>false</filter>
+                <loglevel>TRACE_INFO</loglevel>
+                <loglevel_type>ALL</loglevel_type>
+                <exclusion>false</exclusion>
+                <event_fields>
+                  <event_field>
+                    <name>doublefield</name>
+                    <type>FLOAT</type>
+                    <nowrite>0</nowrite>
+                  </event_field>
+                  <event_field>
+                    <name>floatfield</name>
+                    <type>FLOAT</type>
+                    <nowrite>0</nowrite>
+                  </event_field>
+                  <event_field>
+                    <name>stringfield</name>
+                    <type>STRING</type>
+                    <nowrite>0</nowrite>
+                  </event_field>
+                </event_fields>
+              </event>
+            </events>
+          </pid>
+          <pid>
+            <id>4852</id>
+            <name>/home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello</name>
+            <events>
+              <event>
+                <name>ust_tests_hello:tptest_sighandler</name>
+                <type>TRACEPOINT</type>
+                <enabled>true</enabled>
+                <filter>false</filter>
+                <loglevel>TRACE_WARNING</loglevel>
+                <loglevel_type>ALL</loglevel_type>
+                <exclusion>false</exclusion>
+                <event_fields/>
+              </event>
+              <event>
+                <name>ust_tests_hello:tptest</name>
+                <type>TRACEPOINT</type>
+                <enabled>true</enabled>
+                <filter>false</filter>
+                <loglevel>TRACE_DEBUG_FUNCTION</loglevel>
+                <loglevel_type>ALL</loglevel_type>
+                <exclusion>false</exclusion>
+                <event_fields>
+                  <event_field>
+                    <name>doublefield</name>
+                    <type>FLOAT</type>
+                    <nowrite>0</nowrite>
+                  </event_field>
+                  <event_field>
+                    <name>floatfield</name>
+                    <type>FLOAT</type>
+                    <nowrite>0</nowrite>
+                  </event_field>
+                  <event_field>
+                    <name>stringfield</name>
+                    <type>STRING</type>
+                    <nowrite>0</nowrite>
+                  </event_field>
+                </event_fields>
+              </event>
+            </events>
+          </pid>
+        </pids>
+      </domain>
+    </domains>
+  </output>
+</command>
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test "lttng create <session> with LTTng 2.1 options
+####################################################################
+##################################################################
+<SCENARIO>
+CreateSessionFileProto
+<COMMAND_INPUT>
+lttng --mi xml create mysession -U file:///tmp
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>create</name>
+  <output>
+    <session>
+      <name>mysession</name>
+      <path>/tmp</path>
+      <enabled>false</enabled>
+      <snapshot_mode>0</snapshot_mode>
+      <live_timer_interval>0</live_timer_interval>
+    </session>
+  </output>
+  <success>true</success>
+</command>
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng --mi xml list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>list</name>
+  <output>
+    <sessions>
+      <session>
+        <name>mysession</name>
+        <path>/tmp</path>
+        <enabled>false</enabled>
+        <snapshot_mode>0</snapshot_mode>
+        <live_timer_interval>0</live_timer_interval>
+        <domains/>
+      </session>
+    </sessions>
+  </output>
+</command>
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng --mi xml destroy mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>destroy</name>
+  <output>
+    <sessions>
+      <session>
+        <name>mysession</name>
+        <path>/tmp</path>
+        <enabled>false</enabled>
+        <snapshot_mode>0</snapshot_mode>
+        <live_timer_interval>0</live_timer_interval>
+      </session>
+    </sessions>
+  </output>
+  <success>true</success>
+</command>
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+##################################################################
+<SCENARIO>
+CreateSessionControlData
+<COMMAND_INPUT>
+lttng --mi xml create mysession -C tcp://172.0.0.1 -D tcp://172.0.0.1:5343
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>create</name>
+  <output>
+    <session>
+      <name>mysession</name>
+      <path>tcp4://172.0.0.1:5342/ [data: 5343]</path>
+      <enabled>false</enabled>
+      <snapshot_mode>0</snapshot_mode>
+      <live_timer_interval>0</live_timer_interval>
+    </session>
+  </output>
+  <success>true</success>
+</command>
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng --mi xml list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>list</name>
+  <output>
+    <sessions>
+      <session>
+        <name>mysession</name>
+        <path>tcp4://172.0.0.1:5342/ [data: 5343]</path>
+        <enabled>false</enabled>
+        <snapshot_mode>0</snapshot_mode>
+        <live_timer_interval>0</live_timer_interval>
+        <domains/>
+      </session>
+    </sessions>
+  </output>
+</command>
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng --mi xml destroy mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>destroy</name>
+  <output>
+    <sessions>
+      <session>
+        <name>mysession</name>
+        <path>tcp4://172.0.0.1:5342/ [data: 5343]</path>
+        <enabled>false</enabled>
+        <snapshot_mode>0</snapshot_mode>
+        <live_timer_interval>0</live_timer_interval>
+      </session>
+    </sessions>
+  </output>
+  <success>true</success>
+</command>
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+##################################################################
+<SCENARIO>
+CreateSessionNetwork
+<COMMAND_INPUT>
+lttng --mi xml create mysession -U net://172.0.0.1:1234:2345
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>create</name>
+  <output>
+    <session>
+      <name>mysession</name>
+      <path>tcp4://172.0.0.1:1234/mysession-20140820-153527 [data: 2345]</path>
+      <enabled>false</enabled>
+      <snapshot_mode>0</snapshot_mode>
+      <live_timer_interval>0</live_timer_interval>
+    </session>
+  </output>
+  <success>true</success>
+</command>
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng --mi xml list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>list</name>
+  <output>
+    <sessions>
+      <session>
+        <name>mysession</name>
+        <path>tcp4://172.0.0.1:1234/mysession-20140820-153527 [data: 2345]</path>
+        <enabled>false</enabled>
+        <snapshot_mode>0</snapshot_mode>
+        <live_timer_interval>0</live_timer_interval>
+        <domains/>
+      </session>
+    </sessions>
+  </output>
+</command>
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng --mi xml destroy mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>destroy</name>
+  <output>
+    <sessions>
+      <session>
+        <name>mysession</name>
+        <path>tcp4://172.0.0.1:1234/mysession-20140820-153527 [data: 2345]</path>
+        <enabled>false</enabled>
+        <snapshot_mode>0</snapshot_mode>
+        <live_timer_interval>0</live_timer_interval>
+      </session>
+    </sessions>
+  </output>
+  <success>true</success>
+</command>
+</COMMAND_OUTPUT>
+
+</SCENARIO>
+
+##################################################################
+<SCENARIO>
+CreateSessionNetwork2
+<COMMAND_INPUT>
+lttng --mi xml create mysession -U net6://[ffff::eeee:dddd:cccc:0]
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>create</name>
+  <output>
+    <session>
+      <name>mysession</name>
+      <path>tcp6://[ffff::eeee:dddd:cccc:0]:5342/mysession-20140820-153801 [data: 5343]</path>
+      <enabled>false</enabled>
+      <snapshot_mode>0</snapshot_mode>
+      <live_timer_interval>0</live_timer_interval>
+    </session>
+  </output>
+  <success>true</success>
+</command>
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng --mi xml list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>list</name>
+  <output>
+    <sessions>
+      <session>
+        <name>mysession</name>
+        <path>tcp6://[ffff::eeee:dddd:cccc:0]:5342/mysession-20140820-153801 [data: 5343]</path>
+        <enabled>false</enabled>
+        <snapshot_mode>0</snapshot_mode>
+        <live_timer_interval>0</live_timer_interval>
+        <domains/>
+      </session>
+    </sessions>
+  </output>
+</command>
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng --mi xml destroy mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>destroy</name>
+  <output>
+    <sessions>
+      <session>
+        <name>mysession</name>
+        <path>tcp6://[ffff::eeee:dddd:cccc:0]:5342/mysession-20140820-153801 [data: 5343]</path>
+        <enabled>false</enabled>
+        <snapshot_mode>0</snapshot_mode>
+        <live_timer_interval>0</live_timer_interval>
+      </session>
+    </sessions>
+  </output>
+  <success>true</success>
+</command>
+</COMMAND_OUTPUT>
+
+</SCENARIO>
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/testfiles/CreateTreeTest.cfg b/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/testfiles/CreateTreeTest.cfg
new file mode 100644 (file)
index 0000000..056077c
--- /dev/null
@@ -0,0 +1,2676 @@
+####################################################################
+# Copyright (c) 2012, 2014 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:
+#    Bernd Hufmann - Initial API and implementation
+####################################################################
+####################################################################
+# Scenario: Initialize
+####################################################################
+<SCENARIO>
+Initialize
+<COMMAND_INPUT>
+lttng version
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+lttng version 2.0.0 - Annedd'ale
+Web site: http://lttng.org/
+
+lttng is free software and under the GPL license and part LGPL
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Currently no available tracing session
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list -k
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Kernel events
+-------------
+      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint)
+      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint)
+      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint)
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list -u
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+UST events:
+-------------
+
+PID: 9379 - Name: /home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello
+    ust_tests_hello:tptest_sighandler (loglevel: TRACE_WARNING (4)) (type: tracepoint)
+    ust_tests_hello:tptest (loglevel: TRACE_DEBUG_FUNCTION (12)) (type: tracepoint)
+
+PID: 4852 - Name: /home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello
+    ust_tests_hello:tptest_sighandler (loglevel: TRACE_WARNING (4)) (type: tracepoint)
+    ust_tests_hello:tptest (loglevel: TRACE_DEBUG_FUNCTION (12)) (type: tracepoint)
+
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Create and destroy session
+####################################################################
+<SCENARIO>
+SessionHandling
+<SCENARIO>
+<COMMAND_INPUT>
+lttng create mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Session mysession created.
+Traces will be written in /home/user/lttng-traces/mysession-20120314-132824
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession: [inactive]
+    Trace path: /home/user/lttng-traces/mysession-20120314-132824
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng destroy mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Session mysession destroyed.
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng start mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing started for session mysession.
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng stop mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing stopped for session mysession.
+</COMMAND_OUTPUT>
+
+</SCENARIO>
+
+####################################################################
+# Scenario: Create and destroy session
+####################################################################
+<SCENARIO>
+SessionHandlingWithPath
+<SCENARIO>
+<COMMAND_INPUT>
+lttng create mysession -o /home/user/temp
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Session mysession created.
+Traces will be written in /home/user/temp
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession: [inactive]
+    Trace path: /home/user/temp
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng destroy mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Session mysession destroyed.
+</COMMAND_OUTPUT>
+
+</SCENARIO>
+
+
+####################################################################
+# Scenario: Enable events from kernel provider events
+####################################################################
+<SCENARIO>
+Scenario1
+
+
+<COMMAND_INPUT>
+lttng enable-event sched_kthread_stop,sched_kthread_stop_ret -k -s mysession --tracepoint
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+kernel event sched_kthread_stop created in channel channel0
+kernel sched_kthread_stop_ret created in channel channel0
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession: [inactive]
+    Trace path: /home/user/lttng-traces/mysession-20120314-132824
+
+=== Domain: Kernel ===
+
+Channels:
+-------------
+- channel0: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 262144
+      number of subbufers: 4
+      switch timer interval: 0
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng disable-event sched_kthread_stop_ret,sched_kthread_stop -k -s mysession -c channel0
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+kernel event sched_kthread_stop_ret disabled in channel channel0
+kernel event sched_kthread_stop disabled in channel channel0
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng enable-event sched_kthread_stop -k -s mysession -c channel0 --tracepoint
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+kernel event sched_kthread_stop enabled in channel channel0
+</COMMAND_OUTPUT>
+
+</SCENARIO>
+
+####################################################################
+# Scenario: Enable events from UST provider events
+####################################################################
+<SCENARIO>
+Scenario2
+
+<COMMAND_INPUT>
+lttng enable-channel mychannel -u -s mysession --subbuf-size 16384 --num-subbuf 2 --switch-timer 200 --read-timer 100
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+UST channel mychannel enabled for session mysession
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession: [inactive]
+    Trace path: /home/user/temp
+
+=== Domain: UST global ===
+
+Channels:
+-------------
+- mychannel: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 16384
+      number of subbufers: 2
+      switch timer interval: 200
+      read timer interval: 100
+      output: mmap()
+
+    Events:
+      None
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng enable-event ust_tests_hello:tptest_sighandler,ust_tests_hello:tptest -u -s mysession --tracepoint
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+UST event ust_tests_hello:tptest_sighandler in channel channel0
+UST sched_ust_tests_hello:tptest created in channel channel0
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession: [inactive]
+    Trace path: /home/user/temp
+
+=== Domain: UST global ===
+
+Channels:
+-------------
+- mychannel: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 16384
+      number of subbufers: 2
+      switch timer interval: 200
+      read timer interval: 100
+      output: mmap()
+
+    Events:
+      ust_tests_hello:tptest_sighandler (type: tracepoint) [enabled]
+      ust_tests_hello:tptest (type: tracepoint) [enabled]
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng disable-event ust_tests_hello:tptest -u -s mysession -c mychannel
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+kernel event ust_tests_hello:tptest in channel mychannel
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng enable-event ust_tests_hello:tptest -u -s mysession -c mychannel --tracepoint
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+kernel event ust_tests_hello:tptest enabled in channel mychannel
+</COMMAND_OUTPUT>
+
+</SCENARIO>
+
+<SCENARIO>
+Scenario3
+
+<COMMAND_INPUT>
+lttng enable-channel mychannel -k -s mysession --overwrite --subbuf-size 16384 --num-subbuf 4 --switch-timer 100 --read-timer 200
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Kernel channel mychannel enabled for session mysession
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession: [inactive]
+    Trace path: /home/user/lttng-traces/mysession-20120314-132824
+
+=== Domain: Kernel ===
+
+Channels:
+-------------
+- mychannel: [enabled]
+
+    Attributes:
+      overwrite mode: 1
+      subbufers size: 16384
+      number of subbufers: 4
+      switch timer interval: 100
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      None
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng enable-channel mychannel2 -k -s mysession --subbuf-size 32768 --num-subbuf 2 --switch-timer 100 --read-timer 200
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Kernel channel mychannel2 enabled for session mysession
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession: [inactive]
+    Trace path: /home/user/lttng-traces/mysession-20120314-132824
+
+=== Domain: Kernel ===
+
+Channels:
+-------------
+- mychannel: [enabled]
+
+    Attributes:
+      overwrite mode: 1
+      subbufers size: 16384
+      number of subbufers: 4
+      switch timer interval: 100
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      None
+
+- mychannel2: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 32768
+      number of subbufers: 2
+      switch timer interval: 100
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      None
+
+</COMMAND_OUTPUT>
+
+
+<COMMAND_INPUT>
+lttng disable-channel mychannel,mychannel2 -k -s mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Kernel channel mychannel disabled for session mysession
+Kernel channel mychannel2 disabled for session mysession
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng enable-channel mychannel,mychannel2 -k -s mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Kernel channel mychannel enabled for session mysession
+Kernel channel mychannel2 enabled for session mysession
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng enable-event sched_kthread_stop,sched_kthread_stop_ret -k -s mysession --tracepoint
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+kernel event sched_kthread_stop created in channel channel0
+kernel sched_kthread_stop_ret created in channel channel0
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession: [inactive]
+    Trace path: /home/user/lttng-traces/mysession-20120314-132824
+
+=== Domain: Kernel ===
+
+Channels:
+-------------
+- mychannel: [enabled]
+
+    Attributes:
+      overwrite mode: 1
+      subbufers size: 16384
+      number of subbufers: 4
+      switch timer interval: 100
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      None
+
+- mychannel2: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 32768
+      number of subbufers: 2
+      switch timer interval: 100
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      None
+
+- channel0: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 262144
+      number of subbufers: 4
+      switch timer interval: 0
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng enable-event sched_wakeup_new -k -s mysession --tracepoint
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+kernel event sched_wakeup_new created in channel channel0
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession: [inactive]
+    Trace path: /home/user/lttng-traces/mysession-20120314-132824
+
+=== Domain: Kernel ===
+
+Channels:
+-------------
+- mychannel: [enabled]
+
+    Attributes:
+      overwrite mode: 1
+      subbufers size: 16384
+      number of subbufers: 4
+      switch timer interval: 100
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      None
+
+- mychannel2: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 32768
+      number of subbufers: 2
+      switch timer interval: 100
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      None
+
+- channel0: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 262144
+      number of subbufers: 4
+      switch timer interval: 0
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng enable-event -a -k -s mysession -c mychannel2 --tracepoint
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+All kernel event sched_kthread_stop created in channel channel0
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession: [inactive]
+    Trace path: /home/user/lttng-traces/mysession-20120314-132824
+
+=== Domain: Kernel ===
+
+Channels:
+-------------
+- mychannel: [enabled]
+
+    Attributes:
+      overwrite mode: 1
+      subbufers size: 16384
+      number of subbufers: 4
+      switch timer interval: 100
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      None
+
+- mychannel2: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 32768
+      number of subbufers: 2
+      switch timer interval: 100
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+
+- channel0: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 262144
+      number of subbufers: 4
+      switch timer interval: 0
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng enable-event -a -k -s mysession -c mychannel --syscall
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+All kernel system calls are enabled in channel mychannel
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession: [inactive]
+    Trace path: /home/user/lttng-traces/mysession-20120314-132824
+
+=== Domain: Kernel ===
+
+Channels:
+-------------
+- mychannel: [enabled]
+
+    Attributes:
+      overwrite mode: 1
+      subbufers size: 16384
+      number of subbufers: 4
+      switch timer interval: 100
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      syscalls (type: syscall) [enabled]
+
+- mychannel2: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 32768
+      number of subbufers: 2
+      switch timer interval: 100
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+
+- channel0: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 262144
+      number of subbufers: 4
+      switch timer interval: 0
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng enable-event -a -k -s mysession --syscall
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+All kernel system calls are enabled in channel channel0
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession: [inactive]
+    Trace path: /home/user/lttng-traces/mysession-20120314-132824
+
+=== Domain: Kernel ===
+
+Channels:
+-------------
+- mychannel: [enabled]
+
+    Attributes:
+      overwrite mode: 1
+      subbufers size: 16384
+      number of subbufers: 4
+      switch timer interval: 100
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      syscalls (type: syscall) [enabled]
+
+- mychannel2: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 32768
+      number of subbufers: 2
+      switch timer interval: 100
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+
+- channel0: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 262144
+      number of subbufers: 4
+      switch timer interval: 0
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      syscalls (type: syscall) [enabled]
+      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng enable-event -a -k -s mysession --syscall
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+All kernel system calls are enabled in channel channel0
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession: [inactive]
+    Trace path: /home/user/lttng-traces/mysession-20120314-132824
+
+=== Domain: Kernel ===
+
+Channels:
+-------------
+- mychannel: [enabled]
+
+    Attributes:
+      overwrite mode: 1
+      subbufers size: 16384
+      number of subbufers: 4
+      switch timer interval: 100
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      syscalls (type: syscall) [enabled]
+
+- mychannel2: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 32768
+      number of subbufers: 2
+      switch timer interval: 100
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+
+- channel0: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 262144
+      number of subbufers: 4
+      switch timer interval: 0
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      syscalls (type: syscall) [enabled]
+      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng enable-event myevent1 -k -s mysession --probe 0xc0101280
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+kernel event myevent1 created in channel channel0
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession: [inactive]
+    Trace path: /home/user/lttng-traces/mysession-20120314-132824
+
+=== Domain: Kernel ===
+
+Channels:
+-------------
+- mychannel: [enabled]
+
+    Attributes:
+      overwrite mode: 1
+      subbufers size: 16384
+      number of subbufers: 4
+      switch timer interval: 100
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      syscalls (type: syscall) [enabled]
+
+- mychannel2: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 32768
+      number of subbufers: 2
+      switch timer interval: 100
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+
+- channel0: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 262144
+      number of subbufers: 4
+      switch timer interval: 0
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      myevent1 (type: probe) [enabled]
+        addr: 0xc0101280
+      syscalls (type: syscall) [enabled]
+      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng enable-event myevent2 -k -s mysession -c channel0 --probe init_post
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+kernel event myevent2 created in channel channel0
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession: [inactive]
+    Trace path: /home/user/lttng-traces/mysession-20120314-132824
+
+=== Domain: Kernel ===
+
+Channels:
+-------------
+- mychannel: [enabled]
+
+    Attributes:
+      overwrite mode: 1
+      subbufers size: 16384
+      number of subbufers: 4
+      switch timer interval: 100
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      syscalls (type: syscall) [enabled]
+
+- mychannel2: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 32768
+      number of subbufers: 2
+      switch timer interval: 100
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+
+- channel0: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 262144
+      number of subbufers: 4
+      switch timer interval: 0
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      myevent2 (type: probe) [enabled]
+        offset: 0x0
+        symbol: init_post
+      myevent1 (type: probe) [enabled]
+        addr: 0xc0101280
+      syscalls (type: syscall) [enabled]
+      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng enable-event myevent3 -k -s mysession --probe init_post:0x1000
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+kernel event myevent2 created in channel channel0
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession: [inactive]
+    Trace path: /home/user/lttng-traces/mysession-20120314-132824
+
+=== Domain: Kernel ===
+
+Channels:
+-------------
+- mychannel: [enabled]
+
+    Attributes:
+      overwrite mode: 1
+      subbufers size: 16384
+      number of subbufers: 4
+      switch timer interval: 100
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      syscalls (type: syscall) [enabled]
+
+- mychannel2: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 32768
+      number of subbufers: 2
+      switch timer interval: 100
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+
+- channel0: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 262144
+      number of subbufers: 4
+      switch timer interval: 0
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      myevent3 (type: probe) [enabled]
+        offset: 0x1000
+        symbol: init_post
+      myevent2 (type: probe) [enabled]
+        offset: 0x0
+        symbol: init_post
+      myevent1 (type: probe) [enabled]
+        addr: 0xc0101280
+      syscalls (type: syscall) [enabled]
+      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng enable-event myevent4 -k -s mysession --function create_dev
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+kernel event myevent4 created in channel channel0
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession: [inactive]
+    Trace path: /home/user/lttng-traces/mysession-20120314-132824
+
+=== Domain: Kernel ===
+
+Channels:
+-------------
+- mychannel: [enabled]
+
+    Attributes:
+      overwrite mode: 1
+      subbufers size: 16384
+      number of subbufers: 4
+      switch timer interval: 100
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      syscalls (type: syscall) [enabled]
+
+- mychannel2: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 32768
+      number of subbufers: 2
+      switch timer interval: 100
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+
+- channel0: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 262144
+      number of subbufers: 4
+      switch timer interval: 0
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      myevent4 (type: function) [enabled]
+        offset: 0x0
+        symbol: create_dev
+      myevent3 (type: probe) [enabled]
+        offset: 0x1000
+        symbol: init_post
+      myevent2 (type: probe) [enabled]
+        offset: 0x0
+        symbol: init_post
+      myevent1 (type: probe) [enabled]
+        addr: 0xc0101280
+      syscalls (type: syscall) [enabled]
+      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng enable-event myevent5 -k -s mysession --function create_dev:0x2000
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+kernel event myevent5 created in channel channel0
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession: [inactive]
+    Trace path: /home/user/lttng-traces/mysession-20120314-132824
+
+=== Domain: Kernel ===
+
+Channels:
+-------------
+- mychannel: [enabled]
+
+    Attributes:
+      overwrite mode: 1
+      subbufers size: 16384
+      number of subbufers: 4
+      switch timer interval: 100
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      syscalls (type: syscall) [enabled]
+
+- mychannel2: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 32768
+      number of subbufers: 2
+      switch timer interval: 100
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+
+- channel0: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 262144
+      number of subbufers: 4
+      switch timer interval: 0
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      myevent5 (type: probe) [enabled]
+        offset: 0x2000
+        symbol: create_dev
+      myevent4 (type: function) [enabled]
+        offset: 0x0
+        symbol: create_dev
+      myevent3 (type: probe) [enabled]
+        offset: 0x1000
+        symbol: init_post
+      myevent2 (type: probe) [enabled]
+        offset: 0x0
+        symbol: init_post
+      myevent1 (type: probe) [enabled]
+        addr: 0xc0101280
+      syscalls (type: syscall) [enabled]
+      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng enable-event myevent -k -s mysession -c mychannel --function create_dev:0x2000
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+kernel event myevent created in channel mychannel
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession: [inactive]
+    Trace path: /home/user/lttng-traces/mysession-20120314-132824
+
+=== Domain: Kernel ===
+
+Channels:
+-------------
+- mychannel: [enabled]
+
+    Attributes:
+      overwrite mode: 1
+      subbufers size: 16384
+      number of subbufers: 4
+      switch timer interval: 100
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      myevent (type: probe) [enabled]
+        offset: 0x2000
+        symbol: create_dev
+      syscalls (type: syscall) [enabled]
+
+- mychannel2: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 32768
+      number of subbufers: 2
+      switch timer interval: 100
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+
+- channel0: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 262144
+      number of subbufers: 4
+      switch timer interval: 0
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      myevent5 (type: probe) [enabled]
+        offset: 0x2000
+        symbol: create_dev
+      myevent4 (type: function) [enabled]
+        offset: 0x0
+        symbol: create_dev
+      myevent3 (type: probe) [enabled]
+        offset: 0x1000
+        symbol: init_post
+      myevent2 (type: probe) [enabled]
+        offset: 0x0
+        symbol: init_post
+      myevent1 (type: probe) [enabled]
+        addr: 0xc0101280
+      syscalls (type: syscall) [enabled]
+      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Available tracing sessions:
+  1) mysession (/home/eedbhu/lttng-traces/mysession-20120321-115617) [inactive]
+
+Use lttng list <session_name> for more details
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list -k
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Kernel events
+-------------
+      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint)
+      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint)
+      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint)
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list -u
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+UST events:
+-------------
+
+PID: 9379 - Name: /home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello
+    ust_tests_hello:tptest_sighandler (loglevel: TRACE_WARNING (4)) (type: tracepoint)
+    ust_tests_hello:tptest (loglevel: TRACE_DEBUG_FUNCTION (12)) (type: tracepoint)
+
+PID: 4852 - Name: /home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello
+    ust_tests_hello:tptest_sighandler (loglevel: TRACE_WARNING (4)) (type: tracepoint)
+    ust_tests_hello:tptest (loglevel: TRACE_DEBUG_FUNCTION (12)) (type: tracepoint)
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession: [inactive]
+    Trace path: /home/user/lttng-traces/mysession-20120314-132824
+
+=== Domain: Kernel ===
+
+Channels:
+-------------
+- mychannel: [enabled]
+
+    Attributes:
+      overwrite mode: 1
+      subbufers size: 16384
+      number of subbufers: 4
+      switch timer interval: 100
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      myevent (type: probe) [enabled]
+        offset: 0x2000
+        symbol: create_dev
+      syscalls (type: syscall) [enabled]
+
+- mychannel2: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 32768
+      number of subbufers: 2
+      switch timer interval: 100
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+
+- channel0: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 262144
+      number of subbufers: 4
+      switch timer interval: 0
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      myevent5 (type: probe) [enabled]
+        offset: 0x2000
+        symbol: create_dev
+      myevent4 (type: function) [enabled]
+        offset: 0x0
+        symbol: create_dev
+      myevent3 (type: probe) [enabled]
+        offset: 0x1000
+        symbol: init_post
+      myevent2 (type: probe) [enabled]
+        offset: 0x0
+        symbol: init_post
+      myevent1 (type: probe) [enabled]
+        addr: 0xc0101280
+      syscalls (type: syscall) [enabled]
+      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng add-context -h
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+usage: lttng add-context -t TYPE
+
+If no channel and no event is given (-c/-e), the context
+will be added to all events and all channels.
+Otherwise the context will be added only to the channel (-c)
+and/or event (-e) indicated.
+Exactly one domain (-k/--kernel or -u/--userspace) must be specified.
+
+Options:
+  -h, --help               Show this help
+      --list-options       Simple listing of options
+  -s, --session NAME       Apply to session name
+  -c, --channel NAME       Apply to channel
+  -e, --event NAME         Apply to event
+  -k, --kernel             Apply to the kernel tracer
+  -u, --userspace          Apply to the user-space tracer
+  -t, --type TYPE          Context type. You can repeat that option on
+                           the command line to specify multiple contexts at once.
+                           (--kernel preempts --userspace)
+                           TYPE can be one of the strings below:
+                               pid, procname, prio, nice, vpid, tid, pthread_id,
+                               vtid, ppid, vppid, perf:cpu-cycles, perf:cycles,
+                               perf:stalled-cycles-frontend,
+                               perf:idle-cycles-frontend,
+                               perf:stalled-cycles-backend,
+                               perf:idle-cycles-backend, perf:instructions,
+                               perf:cache-references, perf:cache-misses,
+                               perf:branch-instructions, perf:branches,
+                               perf:branch-misses, perf:bus-cycles,
+                               perf:L1-dcache-loads, perf:L1-dcache-load-misses,
+                               perf:L1-dcache-stores,
+                               perf:L1-dcache-store-misses,
+                               perf:L1-dcache-prefetches,
+                               perf:L1-dcache-prefetch-misses,
+                               perf:L1-icache-loads, perf:L1-icache-load-misses,
+                               perf:L1-icache-stores,
+                               perf:L1-icache-store-misses,
+                               perf:L1-icache-prefetches,
+                               perf:L1-icache-prefetch-misses, perf:LLC-loads,
+                               perf:LLC-load-misses, perf:LLC-stores,
+                               perf:LLC-store-misses, perf:LLC-prefetches,
+                               perf:LLC-prefetch-misses, perf:dTLB-loads,
+                               perf:dTLB-load-misses, perf:dTLB-stores,
+                               perf:dTLB-store-misses, perf:dTLB-prefetches,
+                               perf:dTLB-prefetch-misses, perf:iTLB-loads,
+                               perf:iTLB-load-misses, perf:branch-loads,
+                               perf:branch-load-misses, perf:cpu-clock,
+                               perf:task-clock, perf:page-fault, perf:faults,
+                               perf:major-faults, perf:minor-faults,
+                               perf:context-switches, perf:cs,
+                               perf:cpu-migrations, perf:migrations,
+                               perf:alignment-faults, perf:emulation-faults
+Example:
+This command will add the context information 'prio' and two perf
+counters (hardware branch misses and cache misses), to all events
+in the trace data output:
+# lttng add-context -k -t prio -t perf:branch-misses -t perf:cache-misses
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng add-context -s mysession -k -t prio -t perf:branch-misses -t perf:cache-misses
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+kernel context perf:cache-misses added to all channels
+kernel context perf:branch-misses added to all channels
+kernel context prio added to all channels
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession: [inactive]
+    Trace path: /home/user/lttng-traces/mysession-20120314-132824
+
+=== Domain: Kernel ===
+
+Channels:
+-------------
+- mychannel: [enabled]
+
+    Attributes:
+      overwrite mode: 1
+      subbufers size: 16384
+      number of subbufers: 4
+      switch timer interval: 100
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      myevent (type: probe) [enabled]
+        offset: 0x2000
+        symbol: create_dev
+      syscalls (type: syscall) [enabled]
+
+- mychannel2: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 32768
+      number of subbufers: 2
+      switch timer interval: 100
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+
+- channel0: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 262144
+      number of subbufers: 4
+      switch timer interval: 0
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      myevent5 (type: probe) [enabled]
+        offset: 0x2000
+        symbol: create_dev
+      myevent4 (type: function) [enabled]
+        offset: 0x0
+        symbol: create_dev
+      myevent3 (type: probe) [enabled]
+        offset: 0x1000
+        symbol: init_post
+      myevent2 (type: probe) [enabled]
+        offset: 0x0
+        symbol: init_post
+      myevent1 (type: probe) [enabled]
+        addr: 0xc0101280
+      syscalls (type: syscall) [enabled]
+      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng add-context -h
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+usage: lttng add-context -t TYPE
+
+If no channel and no event is given (-c/-e), the context
+will be added to all events and all channels.
+Otherwise the context will be added only to the channel (-c)
+and/or event (-e) indicated.
+Exactly one domain (-k/--kernel or -u/--userspace) must be specified.
+
+Options:
+  -h, --help               Show this help
+      --list-options       Simple listing of options
+  -s, --session NAME       Apply to session name
+  -c, --channel NAME       Apply to channel
+  -e, --event NAME         Apply to event
+  -k, --kernel             Apply to the kernel tracer
+  -u, --userspace          Apply to the user-space tracer
+  -t, --type TYPE          Context type. You can repeat that option on
+                           the command line to specify multiple contexts at once.
+                           (--kernel preempts --userspace)
+                           TYPE can be one of the strings below:
+                               pid, procname, prio, nice, vpid, tid, pthread_id,
+                               vtid, ppid, vppid, perf:cpu-cycles, perf:cycles,
+                               perf:stalled-cycles-frontend,
+                               perf:idle-cycles-frontend,
+                               perf:stalled-cycles-backend,
+                               perf:idle-cycles-backend, perf:instructions,
+                               perf:cache-references, perf:cache-misses,
+                               perf:branch-instructions, perf:branches,
+                               perf:branch-misses, perf:bus-cycles,
+                               perf:L1-dcache-loads, perf:L1-dcache-load-misses,
+                               perf:L1-dcache-stores,
+                               perf:L1-dcache-store-misses,
+                               perf:L1-dcache-prefetches,
+                               perf:L1-dcache-prefetch-misses,
+                               perf:L1-icache-loads, perf:L1-icache-load-misses,
+                               perf:L1-icache-stores,
+                               perf:L1-icache-store-misses,
+                               perf:L1-icache-prefetches,
+                               perf:L1-icache-prefetch-misses, perf:LLC-loads,
+                               perf:LLC-load-misses, perf:LLC-stores,
+                               perf:LLC-store-misses, perf:LLC-prefetches,
+                               perf:LLC-prefetch-misses, perf:dTLB-loads,
+                               perf:dTLB-load-misses, perf:dTLB-stores,
+                               perf:dTLB-store-misses, perf:dTLB-prefetches,
+                               perf:dTLB-prefetch-misses, perf:iTLB-loads,
+                               perf:iTLB-load-misses, perf:branch-loads,
+                               perf:branch-load-misses, perf:cpu-clock,
+                               perf:task-clock, perf:page-fault, perf:faults,
+                               perf:major-faults, perf:minor-faults,
+                               perf:context-switches, perf:cs,
+                               perf:cpu-migrations, perf:migrations,
+                               perf:alignment-faults, perf:emulation-faults
+Example:
+This command will add the context information 'prio' and two perf
+counters (hardware branch misses and cache misses), to all events
+in the trace data output:
+# lttng add-context -k -t prio -t perf:branch-misses -t perf:cache-misses
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng add-context -s mysession -c mychannel -k -t prio -t perf:branch-misses -t perf:cache-misses
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+kernel context perf:cache-misses added to channel mychannel
+kernel context perf:branch-misses added to channel mychannel
+kernel context prio added to channel mychannel
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession: [inactive]
+    Trace path: /home/user/lttng-traces/mysession-20120314-132824
+
+=== Domain: Kernel ===
+
+Channels:
+-------------
+- mychannel: [enabled]
+
+    Attributes:
+      overwrite mode: 1
+      subbufers size: 16384
+      number of subbufers: 4
+      switch timer interval: 100
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      myevent (type: probe) [enabled]
+        offset: 0x2000
+        symbol: create_dev
+      syscalls (type: syscall) [enabled]
+
+- mychannel2: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 32768
+      number of subbufers: 2
+      switch timer interval: 100
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+
+- channel0: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 262144
+      number of subbufers: 4
+      switch timer interval: 0
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      myevent5 (type: probe) [enabled]
+        offset: 0x2000
+        symbol: create_dev
+      myevent4 (type: function) [enabled]
+        offset: 0x0
+        symbol: create_dev
+      myevent3 (type: probe) [enabled]
+        offset: 0x1000
+        symbol: init_post
+      myevent2 (type: probe) [enabled]
+        offset: 0x0
+        symbol: init_post
+      myevent1 (type: probe) [enabled]
+        addr: 0xc0101280
+      syscalls (type: syscall) [enabled]
+      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng add-context -h
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+usage: lttng add-context -t TYPE
+
+If no channel and no event is given (-c/-e), the context
+will be added to all events and all channels.
+Otherwise the context will be added only to the channel (-c)
+and/or event (-e) indicated.
+Exactly one domain (-k/--kernel or -u/--userspace) must be specified.
+
+Options:
+  -h, --help               Show this help
+      --list-options       Simple listing of options
+  -s, --session NAME       Apply to session name
+  -c, --channel NAME       Apply to channel
+  -e, --event NAME         Apply to event
+  -k, --kernel             Apply to the kernel tracer
+  -u, --userspace          Apply to the user-space tracer
+  -t, --type TYPE          Context type. You can repeat that option on
+                           the command line to specify multiple contexts at once.
+                           (--kernel preempts --userspace)
+                           TYPE can be one of the strings below:
+                               pid, procname, prio, nice, vpid, tid, pthread_id,
+                               vtid, ppid, vppid, perf:cpu-cycles, perf:cycles,
+                               perf:stalled-cycles-frontend,
+                               perf:idle-cycles-frontend,
+                               perf:stalled-cycles-backend,
+                               perf:idle-cycles-backend, perf:instructions,
+                               perf:cache-references, perf:cache-misses,
+                               perf:branch-instructions, perf:branches,
+                               perf:branch-misses, perf:bus-cycles,
+                               perf:L1-dcache-loads, perf:L1-dcache-load-misses,
+                               perf:L1-dcache-stores,
+                               perf:L1-dcache-store-misses,
+                               perf:L1-dcache-prefetches,
+                               perf:L1-dcache-prefetch-misses,
+                               perf:L1-icache-loads, perf:L1-icache-load-misses,
+                               perf:L1-icache-stores,
+                               perf:L1-icache-store-misses,
+                               perf:L1-icache-prefetches,
+                               perf:L1-icache-prefetch-misses, perf:LLC-loads,
+                               perf:LLC-load-misses, perf:LLC-stores,
+                               perf:LLC-store-misses, perf:LLC-prefetches,
+                               perf:LLC-prefetch-misses, perf:dTLB-loads,
+                               perf:dTLB-load-misses, perf:dTLB-stores,
+                               perf:dTLB-store-misses, perf:dTLB-prefetches,
+                               perf:dTLB-prefetch-misses, perf:iTLB-loads,
+                               perf:iTLB-load-misses, perf:branch-loads,
+                               perf:branch-load-misses, perf:cpu-clock,
+                               perf:task-clock, perf:page-fault, perf:faults,
+                               perf:major-faults, perf:minor-faults,
+                               perf:context-switches, perf:cs,
+                               perf:cpu-migrations, perf:migrations,
+                               perf:alignment-faults, perf:emulation-faults
+Example:
+This command will add the context information 'prio' and two perf
+counters (hardware branch misses and cache misses), to all events
+in the trace data output:
+# lttng add-context -k -t prio -t perf:branch-misses -t perf:cache-misses
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng add-context -s mysession -c channel0 -e sched_kthread_stop_ret -k -t prio -t perf:branch-misses -t perf:cache-misses
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+kernel context perf:cache-misses added to event sched_kthread_stop_ret channel mychannel
+kernel context perf:branch-misses added to event sched_kthread_stop_ret channel mychannel
+kernel context prio added to channel event sched_kthread_stop_ret mychannel
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession: [inactive]
+    Trace path: /home/user/lttng-traces/mysession-20120314-132824
+
+=== Domain: Kernel ===
+
+Channels:
+-------------
+- mychannel: [enabled]
+
+    Attributes:
+      overwrite mode: 1
+      subbufers size: 16384
+      number of subbufers: 4
+      switch timer interval: 100
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      myevent (type: probe) [enabled]
+        offset: 0x2000
+        symbol: create_dev
+      syscalls (type: syscall) [enabled]
+
+- mychannel2: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 32768
+      number of subbufers: 2
+      switch timer interval: 100
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+
+- channel0: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 262144
+      number of subbufers: 4
+      switch timer interval: 0
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      myevent5 (type: probe) [enabled]
+        offset: 0x2000
+        symbol: create_dev
+      myevent4 (type: function) [enabled]
+        offset: 0x0
+        symbol: create_dev
+      myevent3 (type: probe) [enabled]
+        offset: 0x1000
+        symbol: init_post
+      myevent2 (type: probe) [enabled]
+        offset: 0x0
+        symbol: init_post
+      myevent1 (type: probe) [enabled]
+        addr: 0xc0101280
+      syscalls (type: syscall) [enabled]
+      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng calibrate -k --function
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Kernel calibration done
+</COMMAND_OUTPUT>
+
+</SCENARIO>
+
+<SCENARIO>
+Scenario4
+
+<COMMAND_INPUT>
+lttng enable-channel mychannel -u -s mysession --overwrite --subbuf-size 16384 --num-subbuf 4 --switch-timer 100 --read-timer 200
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+UST channel mychannel enabled for session mysession
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession: [inactive]
+    Trace path: /home/user/lttng-traces/mysession-20120314-132824
+
+=== Domain: UST global ===
+
+Channels:
+-------------
+- mychannel: [enabled]
+
+    Attributes:
+      overwrite mode: 1
+      subbufers size: 16384
+      number of subbufers: 4
+      switch timer interval: 100
+      read timer interval: 200
+      output: mmap()
+
+    Events:
+      None
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng enable-channel mychannel2 -u -s mysession --subbuf-size 32768 --num-subbuf 2 --switch-timer 100 --read-timer 200
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+UST channel mychannel2 enabled for session mysession
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession: [inactive]
+    Trace path: /home/user/lttng-traces/mysession-20120314-132824
+
+=== Domain: UST global ===
+
+Channels:
+-------------
+- mychannel: [enabled]
+
+    Attributes:
+      overwrite mode: 1
+      subbufers size: 16384
+      number of subbufers: 4
+      switch timer interval: 100
+      read timer interval: 200
+      output: mmap()
+
+    Events:
+      None
+
+- mychannel2: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 32768
+      number of subbufers: 2
+      switch timer interval: 100
+      read timer interval: 200
+      output: mmap()
+
+    Events:
+      None
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng enable-event ust_tests_hello:tptest_sighandler -u -s mysession --tracepoint
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+UST event ust_tests_hello:tptest_sighandler created in channel channel0
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession: [inactive]
+    Trace path: /home/user/lttng-traces/mysession-20120314-132824
+
+=== Domain: UST global ===
+
+Channels:
+-------------
+- mychannel: [enabled]
+
+    Attributes:
+      overwrite mode: 1
+      subbufers size: 16384
+      number of subbufers: 4
+      switch timer interval: 100
+      read timer interval: 200
+      output: mmap()
+
+    Events:
+      None
+
+- mychannel2: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 32768
+      number of subbufers: 2
+      switch timer interval: 100
+      read timer interval: 200
+      output: mmap()
+
+    Events:
+      None
+
+- channel0: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 262144
+      number of subbufers: 4
+      switch timer interval: 0
+      read timer interval: 200
+      output: mmap()
+
+    Events:
+      ust_tests_hello:tptest_sighandler (type: tracepoint) [enabled]
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng enable-event ust_tests_hello:tptest -u -s mysession --tracepoint
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+UST event ust_tests_hello:tptest created in channel channel0
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession: [inactive]
+    Trace path: /home/user/lttng-traces/mysession-20120314-132824
+
+=== Domain: UST global ===
+
+Channels:
+-------------
+- mychannel: [enabled]
+
+    Attributes:
+      overwrite mode: 1
+      subbufers size: 16384
+      number of subbufers: 4
+      switch timer interval: 100
+      read timer interval: 200
+      output: mmap()
+
+    Events:
+      None
+
+- mychannel2: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 32768
+      number of subbufers: 2
+      switch timer interval: 100
+      read timer interval: 200
+      output: mmap()
+
+    Events:
+      None
+
+- channel0: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 262144
+      number of subbufers: 4
+      switch timer interval: 0
+      read timer interval: 200
+      output: mmap()
+
+    Events:
+      ust_tests_hello:tptest_sighandler (type: tracepoint) [enabled]
+      ust_tests_hello:tptest (type: tracepoint) [enabled]
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng enable-event -a -u -s mysession -c mychannel2 --tracepoint
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+All UST events created in channel channel0
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession: [inactive]
+    Trace path: /home/user/lttng-traces/mysession-20120314-132824
+
+=== Domain: UST global ===
+
+Channels:
+-------------
+- mychannel: [enabled]
+
+    Attributes:
+      overwrite mode: 1
+      subbufers size: 16384
+      number of subbufers: 4
+      switch timer interval: 100
+      read timer interval: 200
+      output: mmap()
+
+    Events:
+      None
+
+- mychannel2: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 32768
+      number of subbufers: 2
+      switch timer interval: 100
+      read timer interval: 200
+      output: mmap()
+
+    Events:
+      * (type: tracepoint) [enabled]
+
+- channel0: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 262144
+      number of subbufers: 4
+      switch timer interval: 0
+      read timer interval: 200
+      output: mmap()
+
+    Events:
+      ust_tests_hello:tptest_sighandler (type: tracepoint) [enabled]
+      ust_tests_hello:tptest (type: tracepoint) [enabled]
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng enable-event ust* -u -s mysession -c mychannel --tracepoint
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+UST event ust* created in channel mychannel
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession: [inactive]
+    Trace path: /home/user/lttng-traces/mysession-20120314-132824
+
+=== Domain: UST global ===
+
+Channels:
+-------------
+- mychannel: [enabled]
+
+    Attributes:
+      overwrite mode: 1
+      subbufers size: 16384
+      number of subbufers: 4
+      switch timer interval: 100
+      read timer interval: 200
+      output: mmap()
+
+    Events:
+      ust* (type: tracepoint) [enabled]
+
+- mychannel2: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 32768
+      number of subbufers: 2
+      switch timer interval: 100
+      read timer interval: 200
+      output: mmap()
+
+    Events:
+      * (type: tracepoint) [enabled]
+
+- channel0: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 262144
+      number of subbufers: 4
+      switch timer interval: 0
+      read timer interval: 200
+      output: mmap()
+
+    Events:
+      ust_tests_hello:tptest_sighandler (type: tracepoint) [enabled]
+      ust_tests_hello:tptest (type: tracepoint) [enabled]
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng enable-event ust* -u -s mysession --tracepoint
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+UST event ust* created in channel channel0
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession: [inactive]
+    Trace path: /home/user/lttng-traces/mysession-20120314-132824
+
+=== Domain: UST global ===
+
+Channels:
+-------------
+- mychannel: [enabled]
+
+    Attributes:
+      overwrite mode: 1
+      subbufers size: 16384
+      number of subbufers: 4
+      switch timer interval: 100
+      read timer interval: 200
+      output: mmap()
+
+    Events:
+      ust* (type: tracepoint) [enabled]
+
+- mychannel2: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 32768
+      number of subbufers: 2
+      switch timer interval: 100
+      read timer interval: 200
+      output: mmap()
+
+    Events:
+      * (type: tracepoint) [enabled]
+
+- channel0: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 262144
+      number of subbufers: 4
+      switch timer interval: 0
+      read timer interval: 200
+      output: mmap()
+
+    Events:
+      ust* (type: tracepoint) [enabled]
+      ust_tests_hello:tptest_sighandler (type: tracepoint) [enabled]
+      ust_tests_hello:tptest (type: tracepoint) [enabled]
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng enable-event "u*" -u -s mysession --tracepoint
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+UST event u* created in channel channel0
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession: [inactive]
+    Trace path: /home/user/lttng-traces/mysession-20120314-132824
+
+=== Domain: UST global ===
+
+Channels:
+-------------
+- mychannel: [enabled]
+
+    Attributes:
+      overwrite mode: 1
+      subbufers size: 16384
+      number of subbufers: 4
+      switch timer interval: 100
+      read timer interval: 200
+      output: mmap()
+
+    Events:
+      ust* (type: tracepoint) [enabled]
+
+- mychannel2: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 32768
+      number of subbufers: 2
+      switch timer interval: 100
+      read timer interval: 200
+      output: mmap()
+
+    Events:
+      * (type: tracepoint) [enabled]
+
+- channel0: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 262144
+      number of subbufers: 4
+      switch timer interval: 0
+      read timer interval: 200
+      output: mmap()
+
+    Events:
+      u* (type: tracepoint) [enabled]
+      ust* (type: tracepoint) [enabled]
+      ust_tests_hello:tptest_sighandler (type: tracepoint) [enabled]
+      ust_tests_hello:tptest (type: tracepoint) [enabled]
+
+</COMMAND_OUTPUT>
+
+
+<COMMAND_INPUT>
+lttng enable-event myevent1 -u -s mysession --loglevel TRACE_WARNING
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+UST event myevent1 created in channel channel0
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession: [inactive]
+    Trace path: /home/user/lttng-traces/mysession-20120314-132824
+
+=== Domain: UST global ===
+
+Channels:
+-------------
+- mychannel: [enabled]
+
+    Attributes:
+      overwrite mode: 1
+      subbufers size: 16384
+      number of subbufers: 4
+      switch timer interval: 100
+      read timer interval: 200
+      output: mmap()
+
+    Events:
+      ust* (type: tracepoint) [enabled]
+
+- mychannel2: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 32768
+      number of subbufers: 2
+      switch timer interval: 100
+      read timer interval: 200
+      output: mmap()
+
+    Events:
+      * (type: tracepoint) [enabled]
+
+- channel0: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 262144
+      number of subbufers: 4
+      switch timer interval: 0
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      myevent1 (loglevel <= TRACE_WARNING (4)) (type: tracepoint) [enabled]
+      u* (type: tracepoint) [enabled]
+      ust* (type: tracepoint) [enabled]
+      ust_tests_hello:tptest_sighandler (type: tracepoint) [enabled]
+      ust_tests_hello:tptest (type: tracepoint) [enabled]
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng enable-event myevent2 -u -s mysession --loglevel-only TRACE_DEBUG_FUNCTION
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+UST event myevent2 created in channel channel0
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession: [inactive]
+    Trace path: /home/user/lttng-traces/mysession-20120314-132824
+
+=== Domain: UST global ===
+
+Channels:
+-------------
+- mychannel: [enabled]
+
+    Attributes:
+      overwrite mode: 1
+      subbufers size: 16384
+      number of subbufers: 4
+      switch timer interval: 100
+      read timer interval: 200
+      output: mmap()
+
+    Events:
+      ust* (type: tracepoint) [enabled]
+
+- mychannel2: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 32768
+      number of subbufers: 2
+      switch timer interval: 100
+      read timer interval: 200
+      output: mmap()
+
+    Events:
+      * (type: tracepoint) [enabled]
+
+- channel0: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 262144
+      number of subbufers: 4
+      switch timer interval: 0
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      myevent2 (loglevel == TRACE_DEBUG_FUNCTION (12)) (type: tracepoint) [enabled]
+      myevent1 (loglevel <= TRACE_WARNING (4)) (type: loglevel) [enabled]
+      u* (type: tracepoint) [enabled]
+      ust* (type: tracepoint) [enabled]
+      ust_tests_hello:tptest_sighandler (type: tracepoint) [enabled]
+      ust_tests_hello:tptest (type: tracepoint) [enabled]
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng enable-event myevent0 -u -s mysession -c mychannel --loglevel-only TRACE_DEBUG_FUNCTION
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+UST event myevent0 created in channel mychannel
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession: [inactive]
+    Trace path: /home/user/lttng-traces/mysession-20120314-132824
+
+=== Domain: UST global ===
+
+Channels:
+-------------
+- mychannel: [enabled]
+
+    Attributes:
+      overwrite mode: 1
+      subbufers size: 16384
+      number of subbufers: 4
+      switch timer interval: 100
+      read timer interval: 200
+      output: mmap()
+
+    Events:
+      myevent0 (loglevel <= TRACE_DEBUG_FUNCTION (12)) (type: tracepoint) [enabled]
+      ust* (type: tracepoint) [enabled]
+
+- mychannel2: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 32768
+      number of subbufers: 2
+      switch timer interval: 100
+      read timer interval: 200
+      output: mmap()
+
+    Events:
+      * (type: tracepoint) [enabled]
+
+- channel0: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 262144
+      number of subbufers: 4
+      switch timer interval: 0
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      myevent2 (loglevel <= TRACE_DEBUG_FUNCTION (12)) (type: tracepoint) [enabled]
+      myevent1 (loglevel == TRACE_WARNING (4)) (type: loglevel) [enabled]
+      u* (type: tracepoint) [enabled]
+      ust* (type: tracepoint) [enabled]
+      ust_tests_hello:tptest_sighandler (type: tracepoint) [enabled]
+      ust_tests_hello:tptest (type: tracepoint) [enabled]
+
+</COMMAND_OUTPUT>
+
+
+</SCENARIO>
+
+
+
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/testfiles/CreateTreeTest2.cfg b/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/testfiles/CreateTreeTest2.cfg
new file mode 100644 (file)
index 0000000..b7b88bc
--- /dev/null
@@ -0,0 +1,323 @@
+####################################################################
+# Copyright (c) 2013 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:
+#    Bernd Hufmann - Initial API and implementation
+####################################################################
+####################################################################
+# Scenario: Initialize
+####################################################################
+<SCENARIO>
+Initialize
+<COMMAND_INPUT>
+lttng version
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+lttng version 2.2.0 - Cuda
+Web site: http://lttng.org/
+
+lttng is free software and under the GPL license and part LGPL
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Currently no available tracing session
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list -k
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Kernel events
+-------------
+      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint)
+      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint)
+      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint)
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list -u -f
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+UST events:
+-------------
+
+PID: 9379 - Name: /home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello
+    ust_tests_hello:tptest_sighandler (loglevel: TRACE_WARNING (4)) (type: tracepoint)
+    ust_tests_hello:tptest (loglevel: TRACE_DEBUG_FUNCTION (12)) (type: tracepoint)
+
+PID: 4852 - Name: /home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello
+    ust_tests_hello:tptest_sighandler (loglevel: TRACE_WARNING (4)) (type: tracepoint)
+    ust_tests_hello:tptest (loglevel: TRACE_DEBUG_FUNCTION (12)) (type: tracepoint)
+
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Session and channel with per-UID UST buffers
+####################################################################
+<SCENARIO>
+ScenPerUidTest
+<COMMAND_INPUT>
+lttng create mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Session mysession created.
+Traces will be written in /home/user/lttng-traces/mysession-20130812-113358
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession: [inactive]
+    Trace path: /home/user/lttng-traces/mysession-20130812-113358
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng destroy mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Session my destroyed.
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng enable-channel mychannel -u -s mysession --buffers-uid
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+UST channel mychannel enabled for session mysession
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession: [inactive]
+    Trace path: /home/user/lttng-traces/mysession-20130812-113358
+
+=== Domain: UST global ===
+
+Buffer type: per UID
+
+Channels:
+-------------
+- mychannel: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 8388608
+      number of subbufers: 4
+      switch timer interval: 0
+      read timer interval: 0
+      output: mmap()
+
+    Events:
+      None
+
+</COMMAND_OUTPUT>
+
+</SCENARIO>
+
+####################################################################
+# Scenario: Session and channel with per-PID UST buffers
+####################################################################
+<SCENARIO>
+ScenPerPidTest
+<COMMAND_INPUT>
+lttng create mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Session mysession created.
+Traces will be written in /home/user/lttng-traces/mysession-20130812-113358
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession: [inactive]
+    Trace path: /home/user/lttng-traces/mysession-20130812-113358
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng destroy mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Session mysession destroyed.
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng enable-channel mychannel -u -s mysession --buffers-pid
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+UST channel mychannel enabled for session mysession
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession: [inactive]
+    Trace path: /home/user/lttng-traces/mysession-20130812-113358
+
+=== Domain: UST global ===
+
+Buffer type: per PID
+
+Channels:
+-------------
+- mychannel: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 8388608
+      number of subbufers: 4
+      switch timer interval: 0
+      read timer interval: 0
+      output: mmap()
+
+    Events:
+      None
+
+</COMMAND_OUTPUT>
+
+</SCENARIO>
+
+####################################################################
+# Scenario: Session and channel with per-PID UST buffers with option -C -W
+####################################################################
+<SCENARIO>
+ScenBufSizeTest
+<COMMAND_INPUT>
+lttng create mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Session mysession created.
+Traces will be written in /home/user/lttng-traces/mysession-20130812-113358
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession: [inactive]
+    Trace path: /home/user/lttng-traces/mysession-20130812-113358
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng destroy mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Session mysession destroyed.
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng enable-channel mychannel -u -s mysession -C 1024 -W 10
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<COMMAND_ERROR_OUTPUT>
+Warning: Tracefile size rounded up from (1024) to subbuffer size (8388608)
+</COMMAND_ERROR_OUTPUT>
+UST channel mychannel enabled for session mysession
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession: [inactive]
+    Trace path: /home/user/lttng-traces/mysession-20130812-113358
+
+=== Domain: UST global ===
+
+Buffer type: per PID
+
+Channels:
+-------------
+- mychannel: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 8388608
+      number of subbufers: 4
+      switch timer interval: 0
+      read timer interval: 0
+      output: mmap()
+
+    Events:
+      None
+
+</COMMAND_OUTPUT>
+
+</SCENARIO>
+
+
+
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/testfiles/LTTngServiceMiTest.cfg b/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/testfiles/LTTngServiceMiTest.cfg
new file mode 100644 (file)
index 0000000..1406ca4
--- /dev/null
@@ -0,0 +1,2616 @@
+####################################################################
+# Copyright (c) 2014, 2015 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:
+#    Jonathan Rajotte - Initial API and implementation
+#    Bernd Hufmann - Added new test cases
+####################################################################
+####################################################################
+# Scenario: Test lttng not installed
+####################################################################
+<SCENARIO>
+LttngNotInstalled
+<COMMAND_INPUT>
+lttng --mi xml list
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+1
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<COMMAND_ERROR_OUTPUT>
+Command not found
+</COMMAND_ERROR_OUTPUT>
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test lttng version
+####################################################################
+<SCENARIO>
+LttngVersion
+<COMMAND_INPUT>
+lttng version
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+lttng version 2.1.0 - Basse Messe
+Web site: http://lttng.org/
+
+lttng is free software and under the GPL license and part LGPL
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test lttng version
+# output with prompt
+####################################################################
+<SCENARIO>
+LttngVersionWithPrompt
+<COMMAND_INPUT>
+lttng version
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Prompt> lttng version 2.0.0 - Annedd'ale
+Web site: http://lttng.org/
+
+lttng is free software and under the GPL license and part LGPL
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test lttng version (unsupported version)
+####################################################################
+<SCENARIO>
+LttngUnsupportedVersion
+<COMMAND_INPUT>
+lttng version
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+lttng version 200.0.0 - Annedd'ale
+Web site: http://lttng.org/
+
+lttng is free software and under the GPL license and part LGPL
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+
+####################################################################
+# Scenario: Test lttng version (noversion)
+####################################################################
+<SCENARIO>
+LttngNoVersion
+<COMMAND_INPUT>
+lttng version
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Web site: http://lttng.org/
+
+lttng is free software and under the GPL license and part LGPL
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test lttng version (compiled from source)
+####################################################################
+<SCENARIO>
+LttngVersionCompiled
+<COMMAND_INPUT>
+lttng --mi xml version
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>version</name>
+  <output>
+    <version>
+      <string>2.5.0-rc2</string>
+      <major>2</major>
+      <minor>5</minor>
+      <commit>v2.5.0-rc2-99-g234170a</commit>
+      <patchLevel>0</patchLevel>
+      <name>Fumisterie</name>
+      <description>The Fumisterie is a beer whose style is at the confluence of English and German ales. On the palate, it is full-bodied, malty and slightly caramelized. The organic hemp seeds incorporated during the brewing gives it a unique and original taste. The hop flavour comes through delicately in the after taste.</description>
+      <url>http://lttng.org</url>
+      <license>lttng is free software and under the GPL license and part LGPL</license>
+    </version>
+  </output>
+</command>
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test no sessions available
+####################################################################
+<SCENARIO>
+NoSessionAvailable
+<COMMAND_INPUT>
+lttng --mi xml list
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command><name>list</name><output><sessions/></output></command>
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test get sessions
+####################################################################
+<SCENARIO>
+GetSessionNames1
+<COMMAND_INPUT>
+lttng --mi xml list
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>list</name>
+  <output>
+    <sessions>
+      <session>
+        <name>mysession1</name>
+        <path>home/user/lttng-traces/mysession1-20120123-083928</path>
+        <enabled>false</enabled>
+        <snapshot_mode>0</snapshot_mode>
+        <live_timer_interval>0</live_timer_interval>
+      </session>
+      <session>
+        <name>mysession</name>
+        <path>home/user/lttng-traces/mysession-20120123-083318</path>
+        <enabled>false</enabled>
+        <snapshot_mode>0</snapshot_mode>
+        <live_timer_interval>0</live_timer_interval>
+      </session>
+    </sessions>
+  </output>
+</command>
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test get sessions with tracing group
+####################################################################
+<SCENARIO>
+GetSessionWithTracingGroup
+<COMMAND_INPUT>
+lttng -g group --mi xml list
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>list</name>
+  <output>
+    <sessions>
+      <session>
+        <name>mysession1</name>
+        <path>home/user/lttng-traces/mysession1-20120123-083928</path>
+        <enabled>false</enabled>
+        <snapshot_mode>0</snapshot_mode>
+        <live_timer_interval>0</live_timer_interval>
+      </session>
+      <session>
+        <name>mysession</name>
+        <path>home/user/lttng-traces/mysession-20120123-083318</path>
+        <enabled>false</enabled>
+        <snapshot_mode>0</snapshot_mode>
+        <live_timer_interval>0</live_timer_interval>
+      </session>
+    </sessions>
+  </output>
+</command>
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+
+####################################################################
+# Scenario: Test lttng list <name> where session doesn't exist
+####################################################################
+<SCENARIO>
+GetSessionNameNotExist
+<COMMAND_INPUT>
+lttng --mi xml list test
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+1
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command><name>list</name><output><sessions/></output></command>
+<COMMAND_ERROR_OUTPUT>
+Error: Session 'test' not found
+Error: Command error
+</COMMAND_ERROR_OUTPUT>
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test lttng -vvv list <name> where session doesn't exist
+####################################################################
+<SCENARIO>
+GetSessionNameNotExistVerbose
+<COMMAND_INPUT>
+lttng --mi xml -vvv list test
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+1
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command><name>list</name><output><sessions/></output></command>
+<COMMAND_ERROR_OUTPUT>
+Error: Session 'test' not found
+Error: Command error
+</COMMAND_ERROR_OUTPUT>
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test lttng list with garbage output
+####################################################################
+<SCENARIO>
+GetSessionGarbageOut
+<COMMAND_INPUT>
+lttng --mi xml list
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+asdfaereafsdcv 12333456434&*89**(())(^%$*
+@#$%^&*()@#$%^&*()0834523094578kj;djkfs
+a;sdf094v5u dsafj;sd9
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test lttng list <name> with sample outputs
+####################################################################
+<SCENARIO>
+GetSession1
+<COMMAND_INPUT>
+lttng --mi xml list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>list</name>
+  <output>
+    <sessions>
+      <session>
+        <name>mysession</name>
+        <path>/home/user/lttng-traces/mysession-20120129-084256</path>
+        <enabled>true</enabled>
+        <snapshot_mode>0</snapshot_mode>
+        <live_timer_interval>0</live_timer_interval>
+        <domains>
+          <domain>
+            <type>KERNEL</type>
+            <buffer_type>PER_PID</buffer_type>
+            <channels>
+              <channel>
+                <name>channel0</name>
+                <enabled>true</enabled>
+                <attributes>
+                  <overwrite_mode>DISCARD</overwrite_mode>
+                  <subbuffer_size>262144</subbuffer_size>
+                  <subbuffer_count>4</subbuffer_count>
+                  <switch_timer_interval>0</switch_timer_interval>
+                  <read_timer_interval>200</read_timer_interval>
+                  <output_type>SPLICE</output_type>
+                  <tracefile_size>0</tracefile_size>
+                  <tracefile_count>0</tracefile_count>
+                  <live_timer_interval>0</live_timer_interval>
+                </attributes>
+                <events>
+                  <event>
+                    <name>block_rq_remap</name>
+                    <type>TRACEPOINT</type>
+                    <enabled>true</enabled>
+                    <filter>false</filter>
+                    <loglevel>TRACE_EMERG</loglevel>
+                    <loglevel_type>ALL</loglevel_type>
+                    <exclusion>false</exclusion>
+                  </event>
+                  <event>
+                    <name>block_bio_remap</name>
+                    <type>TRACEPOINT</type>
+                    <enabled>false</enabled>
+                    <filter>false</filter>
+                    <loglevel>TRACE_EMERG</loglevel>
+                    <loglevel_type>ALL</loglevel_type>
+                    <exclusion>false</exclusion>
+                  </event>
+                </events>
+              </channel>
+              <channel>
+                <name>channel1</name>
+                <enabled>false</enabled>
+                <attributes>
+                  <overwrite_mode>OVERWRITE</overwrite_mode>
+                  <subbuffer_size>524288</subbuffer_size>
+                  <subbuffer_count>4</subbuffer_count>
+                  <switch_timer_interval>100</switch_timer_interval>
+                  <read_timer_interval>400</read_timer_interval>
+                  <output_type>SPLICE</output_type>
+                  <tracefile_size>0</tracefile_size>
+                  <tracefile_count>0</tracefile_count>
+                  <live_timer_interval>4294967295</live_timer_interval>
+                </attributes>
+                <events/>
+              </channel>
+            </channels>
+          </domain>
+          <domain>
+            <type>UST</type>
+            <buffer_type>PER_UID</buffer_type>
+            <channels>
+              <channel>
+                <name>mychannel1</name>
+                <enabled>false</enabled>
+                <attributes>
+                  <overwrite_mode>OVERWRITE</overwrite_mode>
+                  <subbuffer_size>8192</subbuffer_size>
+                  <subbuffer_count>8</subbuffer_count>
+                  <switch_timer_interval>200</switch_timer_interval>
+                  <read_timer_interval>100</read_timer_interval>
+                  <output_type>MMAP</output_type>
+                  <tracefile_size>0</tracefile_size>
+                  <tracefile_count>0</tracefile_count>
+                  <live_timer_interval>0</live_timer_interval>
+                </attributes>
+                <events/>
+              </channel>
+              <channel>
+                <name>channel0</name>
+                <enabled>true</enabled>
+                <attributes>
+                  <overwrite_mode>DISCARD</overwrite_mode>
+                  <subbuffer_size>4096</subbuffer_size>
+                  <subbuffer_count>4</subbuffer_count>
+                  <switch_timer_interval>0</switch_timer_interval>
+                  <read_timer_interval>200</read_timer_interval>
+                  <output_type>MMAP</output_type>
+                  <tracefile_size>0</tracefile_size>
+                  <tracefile_count>0</tracefile_count>
+                  <live_timer_interval>0</live_timer_interval>
+                </attributes>
+                <events>
+                  <event>
+                    <name>ust_tests_hello:tptest_sighandler</name>
+                    <type>TRACEPOINT</type>
+                    <enabled>false</enabled>
+                    <filter>false</filter>
+                    <loglevel>TRACE_DEBUG_LINE</loglevel>
+                    <loglevel_type>ALL</loglevel_type>
+                    <exclusion>false</exclusion>
+                  </event>
+                  <event>
+                    <name>*</name>
+                    <type>TRACEPOINT</type>
+                    <enabled>true</enabled>
+                    <filter>false</filter>
+                    <exclusion>false</exclusion>
+                  </event>
+                </events>
+              </channel>
+            </channels>
+          </domain>
+        </domains>
+      </session>
+    </sessions>
+  </output>
+</command>
+</COMMAND_OUTPUT>
+<COMMAND_INPUT>
+lttng --mi xml list mysession1
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>list</name>
+  <output>
+    <sessions>
+      <session>
+        <name>mysession1</name>
+        <path>/home/user/lttng-traces/mysession1-20120203-133225</path>
+        <enabled>false</enabled>
+        <snapshot_mode>0</snapshot_mode>
+        <live_timer_interval>0</live_timer_interval>
+        <domains/>
+      </session>
+    </sessions>
+  </output>
+</command>
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+
+####################################################################
+# Scenario: Test lttng list <name> (with live time interval)
+####################################################################
+<SCENARIO>
+GetSessionWithLiveInterval
+<COMMAND_INPUT>
+lttng --mi xml list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>list</name>
+  <output>
+    <sessions>
+      <session>
+        <name>mysession</name>
+        <path>/home/user/lttng-traces/mysession-20120129-084256</path>
+        <enabled>false</enabled>
+        <snapshot_mode>1</snapshot_mode>
+        <live_timer_interval>4294967295</live_timer_interval>
+        <domains>
+        </domains>
+      </session>
+    </sessions>
+  </output>
+</command>
+</COMMAND_OUTPUT>
+#------------------------------------------------------------------------------
+<COMMAND_INPUT>
+lttng --mi xml snapshot list-output -s mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>snapshot</name>
+  <output>
+    <snapshot_action>
+      <name>list-output</name>
+      <output>
+        <session>
+          <name>mysession</name>
+          <snapshots>
+            <snapshot>
+              <id>1</id>
+              <name>snapshot-1</name>
+              <ctrl_url>/home/user/lttng-traces/mysession-20120129-084256</ctrl_url>
+              <data_url/>
+              <max_size>0</max_size>
+            </snapshot>
+          </snapshots>
+        </session>
+      </output>
+    </snapshot_action>
+  </output>
+  <success>true</success>
+</command>
+</COMMAND_OUTPUT>
+#------------------------------------------------------------------------------
+<COMMAND_INPUT>
+lttng --mi xml list mysession1
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>list</name>
+  <output>
+    <sessions>
+      <session>
+        <name>mysession1</name>
+        <path>/home/user/lttng-traces/mysession1-20120129-084256</path>
+        <enabled>true</enabled>
+        <snapshot_mode>0</snapshot_mode>
+        <live_timer_interval>0</live_timer_interval>
+        <domains/>
+      </session>
+    </sessions>
+  </output>
+</command>
+</COMMAND_OUTPUT>
+#------------------------------------------------------------------------------
+<COMMAND_INPUT>
+lttng --mi xml list mysession2
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>list</name>
+  <output>
+    <sessions>
+      <session>
+        <name>mysession2</name>
+        <path>tcp4://172.0.0.1:5342/ [data: 5343]</path>
+        <enabled>false</enabled>
+        <snapshot_mode>0</snapshot_mode>
+        <live_timer_interval>1000000</live_timer_interval>
+        <domains/>
+      </session>
+    </sessions>
+  </output>
+</command>
+</COMMAND_OUTPUT>
+
+</SCENARIO>
+
+
+####################################################################
+# Scenario: Test "lttng list -k" with sample output
+####################################################################
+<SCENARIO>
+GetKernelProvider1
+<COMMAND_INPUT>
+lttng --mi xml list -k
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>list</name>
+  <output>
+    <domains>
+      <domain>
+        <type>KERNEL</type>
+        <buffer_type>PER_PID</buffer_type>
+        <events>
+          <event>
+            <name>sched_kthread_stop</name>
+            <type>TRACEPOINT</type>
+            <enabled>true</enabled>
+            <filter>false</filter>
+            <loglevel>TRACE_EMERG</loglevel>
+            <loglevel_type>ALL</loglevel_type>
+            <exclusion>false</exclusion>
+          </event>
+          <event>
+            <name>sched_kthread_stop_ret</name>
+            <type>TRACEPOINT</type>
+            <enabled>true</enabled>
+            <filter>false</filter>
+            <loglevel>TRACE_EMERG</loglevel>
+            <loglevel_type>ALL</loglevel_type>
+            <exclusion>false</exclusion>
+          </event>
+          <event>
+            <name>sched_wakeup_new</name>
+            <type>TRACEPOINT</type>
+            <enabled>true</enabled>
+            <filter>false</filter>
+            <loglevel>TRACE_EMERG</loglevel>
+            <loglevel_type>ALL</loglevel_type>
+            <exclusion>false</exclusion>
+          </event>
+       </events>
+      </domain>
+    </domains>
+  </output>
+</command>
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test "lttng list -k" with no kernel and no session daemon
+####################################################################
+<SCENARIO>
+ListWithNoKernel1
+<COMMAND_INPUT>
+lttng --mi xml list -k
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+1
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Spawning session daemon
+<COMMAND_ERROR_OUTPUT>
+Error: Unable to list kernel events
+</COMMAND_ERROR_OUTPUT>
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test "lttng list -k" with no kernel and with session daemon
+####################################################################
+<SCENARIO>
+ListWithNoKernel2
+<COMMAND_INPUT>
+lttng --mi xml list -k
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+1
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<COMMAND_ERROR_OUTPUT>
+Error: Unable to list kernel events
+</COMMAND_ERROR_OUTPUT>
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test "lttng list -u" with sample output
+####################################################################
+<SCENARIO>
+GetUstProvider1
+<COMMAND_INPUT>
+lttng --mi xml list -u -f
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>list</name>
+  <output>
+    <domains>
+      <domain>
+        <type>UST</type>
+        <buffer_type>PER_PID</buffer_type>
+        <pids>
+          <pid>
+            <id>9379</id>
+            <name>/home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello</name>
+            <events>
+              <event>
+                <name>ust_tests_hello:tptest_sighandler</name>
+                <type>TRACEPOINT</type>
+                <enabled>true</enabled>
+                <filter>false</filter>
+                <loglevel>TRACE_DEBUG_MODULE</loglevel>
+                <loglevel_type>ALL</loglevel_type>
+                <exclusion>false</exclusion>
+                <event_fields/>
+              </event>
+              <event>
+                <name>ust_tests_hello:tptest</name>
+                <type>TRACEPOINT</type>
+                <enabled>true</enabled>
+                <filter>false</filter>
+                <loglevel>TRACE_INFO</loglevel>
+                <loglevel_type>ALL</loglevel_type>
+                <exclusion>false</exclusion>
+                <event_fields>
+                  <event_field>
+                    <name>doublefield</name>
+                    <type>FLOAT</type>
+                    <nowrite>0</nowrite>
+                  </event_field>
+                  <event_field>
+                    <name>floatfield</name>
+                    <type>FLOAT</type>
+                    <nowrite>0</nowrite>
+                  </event_field>
+                  <event_field>
+                    <name>stringfield</name>
+                    <type>STRING</type>
+                    <nowrite>0</nowrite>
+                  </event_field>
+                </event_fields>
+              </event>
+            </events>
+          </pid>
+          <pid>
+            <id>4852</id>
+            <name>/home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello</name>
+            <events>
+              <event>
+                <name>ust_tests_hello:tptest_sighandler</name>
+                <type>TRACEPOINT</type>
+                <enabled>true</enabled>
+                <filter>false</filter>
+                <loglevel>TRACE_WARNING</loglevel>
+                <loglevel_type>ALL</loglevel_type>
+                <exclusion>false</exclusion>
+                <event_fields/>
+              </event>
+              <event>
+                <name>ust_tests_hello:tptest</name>
+                <type>TRACEPOINT</type>
+                <enabled>true</enabled>
+                <filter>false</filter>
+                <loglevel>TRACE_DEBUG_FUNCTION</loglevel>
+                <loglevel_type>ALL</loglevel_type>
+                <exclusion>false</exclusion>
+                <event_fields>
+                  <event_field>
+                    <name>doublefield</name>
+                    <type>FLOAT</type>
+                    <nowrite>0</nowrite>
+                  </event_field>
+                  <event_field>
+                    <name>floatfield</name>
+                    <type>FLOAT</type>
+                    <nowrite>0</nowrite>
+                  </event_field>
+                  <event_field>
+                    <name>stringfield</name>
+                    <type>STRING</type>
+                    <nowrite>0</nowrite>
+                  </event_field>
+                </event_fields>
+              </event>
+            </events>
+          </pid>
+        </pids>
+      </domain>
+    </domains>
+  </output>
+</command>
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test "lttng list -u" with no UST provider available
+####################################################################
+<SCENARIO>
+GetUstProvider2
+<COMMAND_INPUT>
+lttng --mi xml list -u -f
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>list</name>
+  <output>
+    <domains>
+      <domain>
+        <type>UST</type>
+        <buffer_type>PER_PID</buffer_type>
+        <pids/>
+      </domain>
+    </domains>
+  </output>
+</command>
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test "lttng list -u" with no UST available (LTTng 2.0.x)
+####################################################################
+<SCENARIO>
+ListWithNoUst1
+<COMMAND_INPUT>
+lttng --mi xml list -u -f
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+1
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command><name>list</name><output/></command>
+<COMMAND_ERROR_OUTPUT>
+Error: Unable to list UST event fields: LTTng-UST tracer is not supported. Please rebuild lttng-tools with lttng-ust support enabled.
+Error: Command error
+</COMMAND_ERROR_OUTPUT>
+</COMMAND_OUTPUT>
+</SCENARIO>
+####################################################################
+# Scenario: Test "lttng list -u" with no UST available and no session daemon
+####################################################################
+<SCENARIO>
+ListWithNoUst2
+<COMMAND_INPUT>
+lttng --mi xml list -u -f
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+1
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command><name>list</name><output/></command>
+<COMMAND_ERROR_OUTPUT>
+Error: Unable to list UST event fields: LTTng-UST tracer is not supported. Please rebuild lttng-tools with lttng-ust support enabled.
+Error: Command error
+</COMMAND_ERROR_OUTPUT>
+</COMMAND_OUTPUT>
+</SCENARIO>
+####################################################################
+# Scenario: Test "lttng list -" with no kernel and with session daemon
+####################################################################
+<SCENARIO>
+ListWithNoUst3
+<COMMAND_INPUT>
+lttng --mi xml list -u -f
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+1
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command><name>list</name><output/></command>
+<COMMAND_ERROR_OUTPUT>
+Error: Unable to list kernel events: Tracing the kernel requires a root lttng-sessiond daemon, as well as "tracing" group membership or root user ID for the lttng client.
+Error: Command Error
+</COMMAND_ERROR_OUTPUT>
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test "lttng list -u -f" with sample output (version 2.6.0)
+####################################################################
+<SCENARIO>
+GetUstProvider3
+<COMMAND_INPUT>
+lttng --mi xml list -u -f
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>list</name>
+  <output>
+    <domains>
+      <domain>
+        <type>UST</type>
+        <buffer_type>PER_PID</buffer_type>
+        <pids>
+          <pid>
+            <id>9379</id>
+            <name>/home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello</name>
+            <events>
+              <event>
+                <name>ust_tests_hello:tptest_sighandler</name>
+                <type>TRACEPOINT</type>
+                <enabled>true</enabled>
+                <filter>false</filter>
+                <loglevel>TRACE_DEBUG_MODULE</loglevel>
+                <loglevel_type>ALL</loglevel_type>
+                <exclusion>false</exclusion>
+                <event_fields/>
+              </event>
+              <event>
+                <name>ust_tests_hello:tptest</name>
+                <type>TRACEPOINT</type>
+                <enabled>true</enabled>
+                <filter>false</filter>
+                <loglevel>TRACE_INFO</loglevel>
+                <loglevel_type>ALL</loglevel_type>
+                <exclusion>false</exclusion>
+                <event_fields>
+                  <event_field>
+                    <name>doublefield</name>
+                    <type>FLOAT</type>
+                    <nowrite>0</nowrite>
+                  </event_field>
+                  <event_field>
+                    <name>floatfield</name>
+                    <type>FLOAT</type>
+                    <nowrite>0</nowrite>
+                  </event_field>
+                  <event_field>
+                    <name>stringfield</name>
+                    <type>STRING</type>
+                    <nowrite>0</nowrite>
+                  </event_field>
+                </event_fields>
+              </event>
+            </events>
+          </pid>
+          <pid>
+            <id>4852</id>
+            <name>/home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello</name>
+            <events>
+              <event>
+                <name>ust_tests_hello:tptest_sighandler</name>
+                <type>TRACEPOINT</type>
+                <enabled>true</enabled>
+                <filter>false</filter>
+                <loglevel>TRACE_WARNING</loglevel>
+                <loglevel_type>ALL</loglevel_type>
+                <exclusion>false</exclusion>
+                <event_fields/>
+              </event>
+              <event>
+                <name>ust_tests_hello:tptest</name>
+                <type>TRACEPOINT</type>
+                <enabled>true</enabled>
+                <filter>false</filter>
+                <loglevel>TRACE_DEBUG_FUNCTION</loglevel>
+                <loglevel_type>ALL</loglevel_type>
+                <exclusion>false</exclusion>
+                <event_fields>
+                  <event_field>
+                    <name>doublefield</name>
+                    <type>FLOAT</type>
+                    <nowrite>0</nowrite>
+                  </event_field>
+                  <event_field>
+                    <name>floatfield</name>
+                    <type>FLOAT</type>
+                    <nowrite>0</nowrite>
+                  </event_field>
+                  <event_field>
+                    <name>stringfield</name>
+                    <type>STRING</type>
+                    <nowrite>0</nowrite>
+                  </event_field>
+                </event_fields>
+              </event>
+            </events>
+          </pid>
+        </pids>
+      </domain>
+    </domains>
+  </output>
+</command>
+</COMMAND_OUTPUT>
+</SCENARIO>
+####################################################################
+# Scenario: Test "lttng create <session>
+####################################################################
+<SCENARIO>
+CreateSession1
+<COMMAND_INPUT>
+lttng --mi xml create mysession2
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>create</name>
+  <output>
+    <session>
+      <name>mysession2</name>
+      <path>/home/user/lttng-traces/mysession2-20120209-095418</path>
+      <enabled>false</enabled>
+      <snapshot_mode>0</snapshot_mode>
+      <live_timer_interval>0</live_timer_interval>
+    </session>
+  </output>
+  <success>true</success>
+</command>
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test "lttng create <session>
+####################################################################
+<SCENARIO>
+CreateSessionWithPrompt
+<COMMAND_INPUT>
+lttng --mi xml create mysession2
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Prompt> Session mysession2 created.
+Traces will be written in /home/user/lttng-traces/mysession2-20120209-095418
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test "lttng create <session> with different variants
+# and errors
+####################################################################
+<SCENARIO>
+CreateSessionVariants
+<COMMAND_INPUT>
+lttng --mi xml create alreadyExist
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+1
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>create</name>
+  <output/>
+  <success>false</success>
+</command>
+<COMMAND_ERROR_OUTPUT>
+Warning: Session mysession2 already exists
+Error: Session name already exists
+</COMMAND_ERROR_OUTPUT>
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng --mi xml create session with spaces
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>create</name>
+  <output>
+    <session>
+      <name>session with spaces</name>
+      <path>/home/user/lttng-traces/session with spaces-20120209-095418</path>
+      <enabled>false</enabled>
+      <snapshot_mode>0</snapshot_mode>
+      <live_timer_interval>0</live_timer_interval>
+    </session>
+  </output>
+  <success>true</success>
+</command>
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng --mi xml create wrongName
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>create</name>
+  <output>
+    <session>
+      <name>auto</name>
+      <path>/home/user/lttng-traces/auto-20120209-095418</path>
+      <enabled>false</enabled>
+      <snapshot_mode>0</snapshot_mode>
+      <live_timer_interval>0</live_timer_interval>
+    </session>
+  </output>
+  <success>true</success>
+</command>
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng --mi xml create wrongPath -o /home/user/hallo
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>create</name>
+  <output>
+    <session>
+      <name>wrongPath</name>
+      <path>/home/user/lttng-traces/wrongPath-20120209-095418</path>
+      <enabled>false</enabled>
+      <snapshot_mode>0</snapshot_mode>
+      <live_timer_interval>0</live_timer_interval>
+    </session>
+  </output>
+  <success>true</success>
+</command>
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng --mi xml create pathWithSpaces -o /home/user/hallo user/here
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>create</name>
+  <output>
+    <session>
+      <name>pathWithSpaces</name>
+      <path>/home/user/hallo user/here/pathWithSpaces-20120209-095418</path>
+      <enabled>false</enabled>
+      <snapshot_mode>0</snapshot_mode>
+      <live_timer_interval>0</live_timer_interval>
+    </session>
+  </output>
+  <success>true</success>
+</command>
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test "lttng destroy <session>
+####################################################################
+
+<SCENARIO>
+DestroySession1
+<COMMAND_INPUT>
+lttng --mi xml destroy mysession2
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>destroy</name>
+  <output>
+    <sessions>
+      <session>
+        <name>mysession2</name>
+        <path>/home/user/lttng-traces/mysession2-20140812-160632</path>
+        <enabled>false</enabled>
+        <snapshot_mode>0</snapshot_mode>
+        <live_timer_interval>0</live_timer_interval>
+      </session>
+    </sessions>
+  </output>
+  <success>true</success>
+</command>
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test "lttng enable-channel ..." with different inputs
+####################################################################
+
+<SCENARIO>
+ChannelHandling
+<COMMAND_INPUT>
+lttng --mi xml enable-channel mychannel0,mychannel1 -k -s mysession2 --overwrite --subbuf-size 16384 --num-subbuf 2 --switch-timer 200 --read-timer 100 -C 0 -W 10
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Kernel channel mychannel0 enabled for session mysession2
+Kernel channel mychannel1 enabled for session mysession2
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng --mi xml enable-channel mychannel0,mychannel1 -k -s mysession2 --overwrite --subbuf-size 16384 --num-subbuf 2 --switch-timer 200 --read-timer 100
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>enable-channel</name>
+  <output>
+    <channels>
+      <channel>
+        <name>mychannel0</name>
+        <enabled>false</enabled>
+        <attributes>
+          <overwrite_mode>OVERWRITE</overwrite_mode>
+          <subbuffer_size>16384</subbuffer_size>
+          <subbuffer_count>2</subbuffer_count>
+          <switch_timer_interval>200</switch_timer_interval>
+          <read_timer_interval>100</read_timer_interval>
+          <output_type>SPLICE</output_type>
+          <tracefile_size>0</tracefile_size>
+          <tracefile_count>0</tracefile_count>
+          <live_timer_interval>4294967295</live_timer_interval>
+        </attributes>
+        <success>true</success>
+      </channel>
+      <channel>
+        <name>mychannel1</name>
+        <enabled>false</enabled>
+        <attributes>
+          <overwrite_mode>OVERWRITE</overwrite_mode>
+          <subbuffer_size>16384</subbuffer_size>
+          <subbuffer_count>2</subbuffer_count>
+          <switch_timer_interval>200</switch_timer_interval>
+          <read_timer_interval>100</read_timer_interval>
+          <output_type>SPLICE</output_type>
+          <tracefile_size>0</tracefile_size>
+          <tracefile_count>0</tracefile_count>
+          <live_timer_interval>4294967295</live_timer_interval>
+        </attributes>
+        <success>true</success>
+      </channel>
+    </channels>
+  </output>
+  <success>true</success>
+</command>
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng --mi xml enable-channel ustChannel -u -s mysession2 --overwrite --subbuf-size 32768 --num-subbuf 1 --switch-timer 100 --read-timer 200 -C 0 -W 20
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+UST channel channel0 enabled for session mysession2
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng --mi xml enable-channel ustChannel -u -s mysession2 --overwrite --subbuf-size 32768 --num-subbuf 1 --switch-timer 100 --read-timer 200
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>enable-channel</name>
+  <output>
+    <channels>
+      <channel>
+        <name>ustChannel</name>
+        <enabled>false</enabled>
+        <attributes>
+          <overwrite_mode>OVERWRITE</overwrite_mode>
+          <subbuffer_size>32768</subbuffer_size>
+          <subbuffer_count>2</subbuffer_count>
+          <switch_timer_interval>100</switch_timer_interval>
+          <read_timer_interval>200</read_timer_interval>
+          <output_type>MMAP</output_type>
+          <tracefile_size>0</tracefile_size>
+          <tracefile_count>0</tracefile_count>
+          <live_timer_interval>4294967295</live_timer_interval>
+        </attributes>
+        <success>true</success>
+      </channel>
+    </channels>
+  </output>
+  <success>true</success>
+</command>
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng --mi xml enable-channel ustChannel -u -s mysession2 --overwrite --subbuf-size 32768 --num-subbuf 1 --switch-timer 100 --read-timer 200 --buffers-uid -C 0 -W 20
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+UST channel channel0 enabled for session mysession2
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng --mi xml enable-channel ustChannel -u -s mysession2 --overwrite --buffers-pid
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>enable-channel</name>
+  <output>
+    <channels>
+      <channel>
+        <name>ustChannel</name>
+        <enabled>false</enabled>
+        <attributes>
+          <overwrite_mode>OVERWRITE</overwrite_mode>
+          <subbuffer_size>4096</subbuffer_size>
+          <subbuffer_count>4</subbuffer_count>
+          <switch_timer_interval>0</switch_timer_interval>
+          <read_timer_interval>0</read_timer_interval>
+          <output_type>MMAP</output_type>
+          <tracefile_size>0</tracefile_size>
+          <tracefile_count>0</tracefile_count>
+          <live_timer_interval>4294967295</live_timer_interval>
+        </attributes>
+        <success>true</success>
+      </channel>
+    </channels>
+  </output>
+  <success>true</success>
+</command>
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng --mi xml enable-channel ustChannel -u -s mysession2 --overwrite --subbuf-size 32768 --num-subbuf 2 --switch-timer 100 --read-timer 200 --buffers-uid
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>enable-channel</name>
+  <output>
+    <channels>
+      <channel>
+        <name>ustChannel</name>
+        <enabled>false</enabled>
+        <attributes>
+          <overwrite_mode>OVERWRITE</overwrite_mode>
+          <subbuffer_size>32768</subbuffer_size>
+          <subbuffer_count>2</subbuffer_count>
+          <switch_timer_interval>100</switch_timer_interval>
+          <read_timer_interval>200</read_timer_interval>
+          <output_type>MMAP</output_type>
+          <tracefile_size>0</tracefile_size>
+          <tracefile_count>0</tracefile_count>
+          <live_timer_interval>4294967295</live_timer_interval>
+        </attributes>
+        <success>true</success>
+      </channel>
+    </channels>
+  </output>
+  <success>true</success>
+</command>
+</COMMAND_OUTPUT>
+
+
+<COMMAND_INPUT>
+lttng --mi xml enable-channel mychannel0,mychannel1 -k -s mysession2
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>enable-channel</name>
+  <output>
+    <channels>
+      <channel>
+        <name>mychannel0</name>
+        <enabled>false</enabled>
+        <attributes>
+          <overwrite_mode>DISCARD</overwrite_mode>
+          <subbuffer_size>262144</subbuffer_size>
+          <subbuffer_count>4</subbuffer_count>
+          <switch_timer_interval>0</switch_timer_interval>
+          <read_timer_interval>200000</read_timer_interval>
+          <output_type>SPLICE</output_type>
+          <tracefile_size>0</tracefile_size>
+          <tracefile_count>0</tracefile_count>
+          <live_timer_interval>4294967295</live_timer_interval>
+        </attributes>
+        <success>true</success>
+      </channel>
+      <channel>
+        <name>mychannel1</name>
+        <enabled>false</enabled>
+        <attributes>
+          <overwrite_mode>DISCARD</overwrite_mode>
+          <subbuffer_size>262144</subbuffer_size>
+          <subbuffer_count>4</subbuffer_count>
+          <switch_timer_interval>0</switch_timer_interval>
+          <read_timer_interval>200000</read_timer_interval>
+          <output_type>SPLICE</output_type>
+          <tracefile_size>0</tracefile_size>
+          <tracefile_count>0</tracefile_count>
+          <live_timer_interval>4294967295</live_timer_interval>
+        </attributes>
+        <success>true</success>
+      </channel>
+    </channels>
+  </output>
+  <success>true</success>
+</command>
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng --mi xml enable-channel ustChannel -u -s mysession2
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>enable-channel</name>
+  <output>
+    <channels>
+      <channel>
+        <name>ustChannel</name>
+        <enabled>false</enabled>
+        <attributes>
+          <overwrite_mode>DISCARD</overwrite_mode>
+          <subbuffer_size>131072</subbuffer_size>
+          <subbuffer_count>4</subbuffer_count>
+          <switch_timer_interval>0</switch_timer_interval>
+          <read_timer_interval>0</read_timer_interval>
+          <output_type>MMAP</output_type>
+          <tracefile_size>0</tracefile_size>
+          <tracefile_count>0</tracefile_count>
+          <live_timer_interval>4294967295</live_timer_interval>
+        </attributes>
+        <success>true</success>
+      </channel>
+    </channels>
+  </output>
+  <success>true</success>
+</command>
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng --mi xml disable-channel mychannel0,mychannel1 -k -s mysession2
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>disable-channel</name>
+  <output>
+    <channels>
+      <channel>
+        <name>mychannel0</name>
+        <enabled>false</enabled>
+        <success>true</success>
+      </channel>
+      <channel>
+        <name>mychannel1</name>
+        <enabled>false</enabled>
+        <success>true</success>
+      </channel>
+    </channels>
+  </output>
+  <success>true</success>
+</command>
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng --mi xml disable-channel ustChannel -u -s mysession2
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>disable-channel</name>
+  <output>
+    <channels>
+      <channel>
+        <name>ustChannel</name>
+        <enabled>false</enabled>
+        <success>true</success>
+      </channel>
+    </channels>
+  </output>
+  <success>true</success>
+</command>
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+
+####################################################################
+# Scenario: Test "lttng --mi xml enable-events ..." with different inputs
+####################################################################
+<SCENARIO>
+EventHandling
+
+# Tracepoint test cases
+
+<COMMAND_INPUT>
+lttng --mi xml enable-event block_rq_remap,block_bio_remap,softirq_entry -k -s mysession2 --tracepoint
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>enable-event</name>
+  <output>
+    <events>
+      <event>
+        <name>block_rq_remap</name>
+        <type>TRACEPOINT</type>
+        <enabled>true</enabled>
+        <filter>false</filter>
+        <loglevel>TRACE_EMERG</loglevel>
+        <loglevel_type>ALL</loglevel_type>
+        <exclusion>false</exclusion>
+        <success>true</success>
+      </event>
+      <event>
+        <name>block_bio_remap</name>
+        <type>TRACEPOINT</type>
+        <enabled>true</enabled>
+        <filter>false</filter>
+        <loglevel>TRACE_EMERG</loglevel>
+        <loglevel_type>ALL</loglevel_type>
+        <exclusion>false</exclusion>
+        <success>true</success>
+      </event>
+      <event>
+        <name>softirq_entry</name>
+        <type>TRACEPOINT</type>
+        <enabled>true</enabled>
+        <filter>false</filter>
+        <loglevel>TRACE_EMERG</loglevel>
+        <loglevel_type>ALL</loglevel_type>
+        <exclusion>false</exclusion>
+        <success>true</success>
+      </event>
+    </events>
+  </output>
+  <success>true</success>
+</command>
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng --mi xml enable-event -a -k -s mysession2 -c mychannel --tracepoint
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>enable-event</name>
+  <output>
+    <events>
+      <event>
+        <name>*</name>
+        <type>TRACEPOINT</type>
+        <enabled>true</enabled>
+        <filter>false</filter>
+        <loglevel>TRACE_EMERG</loglevel>
+        <loglevel_type>ALL</loglevel_type>
+        <exclusion>false</exclusion>
+        <success>true</success>
+      </event>
+    </events>
+  </output>
+  <success>true</success>
+</command>
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng --mi xml enable-event ust_tests_hello:tptest_sighandler -u -s mysession2 -c mychannel --tracepoint
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>enable-event</name>
+  <output>
+    <events>
+      <event>
+        <name>ust_tests_hello:tptest_sighandler</name>
+        <type>TRACEPOINT</type>
+        <enabled>true</enabled>
+        <filter>false</filter>
+        <exclusion>false</exclusion>
+        <success>true</success>
+      </event>
+    </events>
+  </output>
+  <success>true</success>
+</command>
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng --mi xml enable-event ust_tests_hello:tptest_sighandler -u -s mysession2 -c mychannel --tracepoint --filter intfield==10
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>enable-event</name>
+  <output>
+    <events>
+      <event>
+        <name>ust_tests_hello:tptest_sighandler</name>
+        <type>TRACEPOINT</type>
+        <enabled>true</enabled>
+        <filter>true</filter>
+        <exclusion>false</exclusion>
+        <success>true</success>
+      </event>
+    </events>
+  </output>
+  <success>true</success>
+</command>
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng --mi xml enable-event -a -u -s mysession2 -c mychannel --tracepoint
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>enable-event</name>
+  <output>
+    <events>
+      <event>
+        <name>*</name>
+        <type>TRACEPOINT</type>
+        <enabled>true</enabled>
+        <filter>false</filter>
+        <exclusion>false</exclusion>
+        <success>true</success>
+      </event>
+    </events>
+  </output>
+  <success>true</success>
+</command>
+</COMMAND_OUTPUT>
+
+# Syscall test cases
+
+<COMMAND_INPUT>
+lttng --mi xml enable-event -a -k -s mysession2 --syscall
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>enable-event</name>
+  <output>
+    <events>
+      <event>
+        <name>*</name>
+        <type>SYSCALL</type>
+        <enabled>true</enabled>
+        <filter>false</filter>
+        <success>true</success>
+      </event>
+    </events>
+  </output>
+  <success>true</success>
+</command>
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng --mi xml enable-event -a -k -s mysession2 -c mychannel --syscall
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>enable-event</name>
+  <output>
+    <events>
+      <event>
+        <name>*</name>
+        <type>SYSCALL</type>
+        <enabled>true</enabled>
+        <filter>false</filter>
+        <success>true</success>
+      </event>
+    </events>
+  </output>
+  <success>true</success>
+</command>
+</COMMAND_OUTPUT>
+
+# dynamic probe/function probe test cases
+
+<COMMAND_INPUT>
+lttng --mi xml enable-event myevent0 -k -s mysession2 --function 0xc0101340
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>enable-event</name>
+  <output>
+    <events>
+      <event>
+        <name>myevent0</name>
+        <type>FUNCTION</type>
+        <enabled>false</enabled>
+        <filter>false</filter>
+        <success>true</success>
+      </event>
+    </events>
+  </output>
+  <success>true</success>
+</command>
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng --mi xml enable-event myevent1 -k -s mysession2 -c mychannel --probe init_post
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>enable-event</name>
+  <output>
+    <events>
+      <event>
+        <name>myevent1</name>
+        <type>PROBE</type>
+        <enabled>false</enabled>
+        <filter>false</filter>
+        <offset>0</offset>
+        <symbol_name>init_post</symbol_name>
+        <success>true</success>
+      </event>
+    </events>
+  </output>
+  <success>true</success>
+</command>
+
+</COMMAND_OUTPUT>
+
+# log level test cases
+
+<COMMAND_INPUT>
+lttng --mi xml enable-event myevent4 -u -s mysession2 --loglevel-only TRACE_DEBUG
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>enable-event</name>
+  <output>
+    <events>
+      <event>
+        <name>myevent4</name>
+        <type>TRACEPOINT</type>
+        <enabled>true</enabled>
+        <filter>false</filter>
+        <loglevel>TRACE_DEBUG</loglevel>
+        <loglevel_type>SINGLE</loglevel_type>
+        <exclusion>false</exclusion>
+        <success>true</success>
+      </event>
+    </events>
+  </output>
+  <success>true</success>
+</command>
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng --mi xml enable-event myevent5 -u -s mysession2 -c mychannel --loglevel TRACE_DEBUG_FUNCTION
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>enable-event</name>
+  <output>
+    <events>
+      <event>
+        <name>myevent5</name>
+        <type>TRACEPOINT</type>
+        <enabled>true</enabled>
+        <filter>false</filter>
+        <loglevel>TRACE_DEBUG_FUNCTION</loglevel>
+        <loglevel_type>RANGE</loglevel_type>
+        <exclusion>false</exclusion>
+        <success>true</success>
+      </event>
+    </events>
+  </output>
+  <success>true</success>
+</command>
+</COMMAND_OUTPUT>
+
+</SCENARIO>
+
+####################################################################
+# Scenario: Test "lttng add-context -h" and lttng --mi xml add-context ..." with different inputs
+####################################################################
+
+<SCENARIO>
+ContextHandling
+
+<COMMAND_INPUT>
+lttng --mi xml add-context -h
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+usage: lttng add-context -t TYPE [-k|-u] [OPTIONS]
+
+If no channel is given (-c), the context is added to
+all channels.
+
+Otherwise the context is added only to the channel (-c).
+
+Exactly one domain (-k or -u) must be specified.
+
+Options:
+  -h, --help               Show this help
+      --list-options       Simple listing of options
+  -s, --session NAME       Apply to session name
+  -c, --channel NAME       Apply to channel
+  -k, --kernel             Apply to the kernel tracer
+  -u, --userspace          Apply to the user-space tracer
+
+Context:
+  -t, --type TYPE          Context type. You can repeat that option on
+                           the command line to specify multiple contexts at once.
+                           (--kernel preempts --userspace)
+                           TYPE can be one of the strings below:
+                               pid, procname, prio, nice, vpid, tid, pthread_id,
+                               vtid, ppid, vppid, perf:cpu:cpu-cycles, perf:cpu:cycles
+Note that the vpid, vppid and vtid context types represent the virtual process id,
+virtual parent process id and virtual thread id as seen from the current execution context
+as opposed to the pid, ppid and tid which are kernel internal data structures.
+
+Example:
+This command will add the context information 'prio' and two per-cpu
+perf counters (hardware branch misses and cache misses), to all channels
+in the trace data output:
+# lttng add-context -k -t prio -t perf:cpu:branch-misses -t perf:cpu:cache-misses
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng --mi xml add-context -s mysession2 -c mychannel -e ust_tests_hello:tptest_sighandler -u -t prio -t pid
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+UST context prio added to event ust_tests_hello:tptest_sighandle channel mychannel
+UST context pid added to event sched_kthread_stop_ret channel mychannel
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+<SCENARIO>
+ContextErrorHandling
+
+<COMMAND_INPUT>
+lttng --mi xml add-context -h
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+1
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+usage: lttng add-context -t TYPE
+
+If no channel and no event is given (-c/-e), the context
+will be added to all events and all channels.
+Otherwise the context will be added only to the channel (-c)
+and/or event (-e) indicated.
+Exactly one domain (-k/--kernel or -u/--userspace) must be specified.
+
+Options:
+  -h, --help               Show this help
+      --list-options       Simple listing of options
+  -s, --session NAME       Apply to session name
+  -c, --channel NAME       Apply to channel
+  -e, --event NAME         Apply to event
+  -k, --kernel             Apply to the kernel tracer
+  -u, --userspace          Apply to the user-space tracer
+  -t, --type TYPE          Context type. You can repeat that option on
+                           the command line to specify multiple contexts at once.
+                           (--kernel preempts --userspace)
+                           TYPE can be one of the strings below:
+                               pid, procname, prio, nice, vpid, tid, pthread_id,
+                               vtid, ppid, vppid, perf:cpu-cycles, perf:cycles
+Example:
+This command will add the context information 'prio' and two perf
+counters (hardware branch misses and cache misses), to all events
+in the trace data output:
+# lttng add-context -k -t prio -t perf:branch-misses -t perf:cache-misses
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng --mi xml add-context -s mysession2 -c mychannel -e ust_tests_hello:tptest_sighandler -u -t prio -t pid
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+1
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+UST context prio added to event ust_tests_hello:tptest_sighandle channel mychannel
+UST context pid added to event sched_kthread_stop_ret channel mychannel
+</COMMAND_OUTPUT>
+
+</SCENARIO>
+
+<SCENARIO>
+CalibrateHandling
+<COMMAND_INPUT>
+lttng --mi xml calibrate -k --function
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>calibrate</name>
+  <output>
+    <calibrate>
+      <type>FUNCTION</type>
+    </calibrate>
+  </output>
+  <success>true</success>
+</command>
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng --mi xml calibrate -u --function
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+1
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>calibrate</name>
+  <output>
+    <calibrate>
+      <type>FUNCTION</type>
+    </calibrate>
+  </output>
+  <success>true</success>
+</command>
+</COMMAND_OUTPUT>
+
+</SCENARIO>
+
+####################################################################
+# Scenario: Test "lttng create <session> with LTTng 2.1 options
+####################################################################
+<SCENARIO>
+CreateSessionLttng2.1
+
+<COMMAND_INPUT>
+lttng --mi xml create mysession -U net://172.0.0.1
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>create</name>
+  <output>
+    <session>
+      <name>mysession</name>
+      <path>tcp4://172.0.0.1:5342/mysession-20140813-095804 [data: 5343]</path>
+      <enabled>false</enabled>
+      <snapshot_mode>0</snapshot_mode>
+      <live_timer_interval>0</live_timer_interval>
+    </session>
+  </output>
+  <success>true</success>
+</command>
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng --mi xml create mysession -U file:///tmp
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>create</name>
+  <output>
+    <session>
+      <name>mysession</name>
+      <path>/tmp</path>
+      <enabled>false</enabled>
+      <snapshot_mode>0</snapshot_mode>
+      <live_timer_interval>0</live_timer_interval>
+    </session>
+  </output>
+  <success>true</success>
+</command>
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng --mi xml create mysession -C tcp://172.0.0.1 -D tcp://172.0.0.1:5343
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>create</name>
+  <output>
+    <session>
+      <name>mysession</name>
+      <path>tcp4://172.0.0.1:5342/ [data: 5343]</path>
+      <enabled>false</enabled>
+      <snapshot_mode>0</snapshot_mode>
+      <live_timer_interval>0</live_timer_interval>
+    </session>
+  </output>
+  <success>true</success>
+</command>
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng --mi xml create mysession -U 172.0.0.1:1234:2345
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>create</name>
+  <output>
+    <session>
+      <name>mysession</name>
+      <path>tcp4://172.0.0.1:1234/mysession-20140813-102225 [data: 2345]</path>
+      <enabled>false</enabled>
+      <snapshot_mode>0</snapshot_mode>
+      <live_timer_interval>0</live_timer_interval>
+    </session>
+  </output>
+  <success>true</success>
+</command>
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng --mi xml destroy mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>destroy</name>
+  <output>
+    <sessions>
+      <session>
+        <name>mysession</name>
+        <path>/home/user/lttng-traces/mysession-20140818-100114</path>
+        <enabled>false</enabled>
+        <snapshot_mode>0</snapshot_mode>
+        <live_timer_interval>0</live_timer_interval>
+      </session>
+    </sessions>
+  </output>
+  <success>true</success>
+</command>
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng --mi xml -vvv create mysession -U net://172.0.0.1
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+DEBUG3: URI string: net://172.0.0.1 [in uri_parse() at uri.c:253]
+DEBUG2: IP address resolved to 172.0.0.1 [in set_ip_address() at uri.c:132]
+DEBUG3: URI dtype: 1, proto: 1, host: 172.0.0.1, subdir: , ctrl: 0, data: 0 [in uri_parse() at uri.c:467]
+DEBUG1: LSM cmd type : 8 [in send_session_msg() at lttng-ctl.c:261]
+Session mysession created.
+Traces will be written in net://172.0.0.1
+DEBUG1: Init config session in /home/bernd [in config_init() at conf.c:294]
+</COMMAND_OUTPUT>
+
+</SCENARIO>
+
+####################################################################
+# Scenario: Test "lttng create <session> --snapshot (LTTng 2.3)
+####################################################################
+<SCENARIO>
+CreateSessionSnapshot
+<COMMAND_INPUT>
+lttng --mi xml create mysession --snapshot
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>create</name>
+  <output>
+    <session>
+      <name>mysession</name>
+      <path/>
+      <enabled>false</enabled>
+      <snapshot_mode>1</snapshot_mode>
+      <live_timer_interval>4294967295</live_timer_interval>
+    </session>
+  </output>
+  <success>true</success>
+</command>
+</COMMAND_OUTPUT>
+#------------------------------------------------------------------------------
+<COMMAND_INPUT>
+lttng --mi xml snapshot list-output -s mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>snapshot</name>
+  <output>
+    <snapshot_action>
+      <name>list-output</name>
+      <output>
+        <session>
+          <name>mysession</name>
+          <snapshots>
+            <snapshot>
+              <id>1</id>
+              <name>snapshot-1</name>
+              <ctrl_url>/home/user/lttng-traces/mysession-20130913-141651</ctrl_url>
+              <data_url/>
+              <max_size>0</max_size>
+            </snapshot>
+          </snapshots>
+        </session>
+      </output>
+    </snapshot_action>
+  </output>
+  <success>true</success>
+</command>
+</COMMAND_OUTPUT>
+#------------------------------------------------------------------------------
+<COMMAND_INPUT>
+lttng --mi xml list
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>list</name>
+  <output>
+    <sessions>
+      <session>
+        <name>mysession</name>
+        <path/>
+        <enabled>false</enabled>
+        <snapshot_mode>1</snapshot_mode>
+        <live_timer_interval>4294967295</live_timer_interval>
+      </session>
+    </sessions>
+  </output>
+</command>
+</COMMAND_OUTPUT>
+#------------------------------------------------------------------------------
+<COMMAND_INPUT>
+lttng --mi xml snapshot record -s mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+    Snapshot recorded successfully for session mysession
+</COMMAND_OUTPUT>
+#------------------------------------------------------------------------------
+<COMMAND_INPUT>
+lttng --mi xml destroy mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>destroy</name>
+  <output>
+    <sessions>
+      <session>
+        <name>mysession</name>
+        <path>/home/user/lttng-traces/mysession-20140818-100114</path>
+        <enabled>false</enabled>
+        <snapshot_mode>0</snapshot_mode>
+        <live_timer_interval>0</live_timer_interval>
+      </session>
+    </sessions>
+  </output>
+  <success>true</success>
+</command>
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test "lttng create <session> --snapshot -U <URL> (LTTng 2.3)
+####################################################################
+<SCENARIO>
+CreateSessionStreamedSnapshot
+<COMMAND_INPUT>
+lttng --mi xml create mysession --snapshot -U net://172.0.0.1
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Session mysession created.
+Default snapshot output set to: net://172.0.0.1
+Snapshot mode set. Every channel enabled for that session will be set in overwrite mode and mmap output.
+</COMMAND_OUTPUT>
+#------------------------------------------------------------------------------
+<COMMAND_INPUT>
+lttng --mi xml snapshot list-output -s mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Snapshot output list for session mysession
+    [2] snapshot-2: net4://172.0.0.1:5342/
+</COMMAND_OUTPUT>
+#------------------------------------------------------------------------------
+<COMMAND_INPUT>
+lttng --mi xml list
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+  1) mysession () [inactive snapshot]
+
+</COMMAND_OUTPUT>
+#------------------------------------------------------------------------------
+<COMMAND_INPUT>
+lttng --mi xml snapshot record -s mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+    Snapshot recorded successfully for session mysession
+</COMMAND_OUTPUT>
+#------------------------------------------------------------------------------
+<COMMAND_INPUT>
+lttng --mi xml destroy mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>destroy</name>
+  <output>
+    <sessions>
+      <session>
+        <name>mysession</name>
+        <path>/home/user/lttng-traces/mysession-20140818-100114</path>
+        <enabled>false</enabled>
+        <snapshot_mode>0</snapshot_mode>
+        <live_timer_interval>0</live_timer_interval>
+      </session>
+    </sessions>
+  </output>
+  <success>true</success>
+</command>
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test "lttng create <session> --snapshot (LTTng 2.3)
+####################################################################
+<SCENARIO>
+CreateSessionSnapshotErrors
+<COMMAND_INPUT>
+lttng --mi xml snapshot list-output -s blabla
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+1
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<COMMAND_ERROR_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>snapshot</name>
+  <output>
+    <snapshot_action>
+      <name>list-output</name>
+      <output/>
+    </snapshot_action>
+  </output>
+  <success>false</success>
+</command>
+</COMMAND_ERROR_OUTPUT>
+</COMMAND_OUTPUT>
+#------------------------------------------------------------------------------
+#next is not an error case but good to be tested
+<COMMAND_INPUT>
+lttng --mi xml list
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>list</name>
+  <output>
+    <sessions>
+      <session>
+        <name>mysession</name>
+        <path/>
+        <enabled>true</enabled>
+        <snapshot_mode>1</snapshot_mode>
+        <live_timer_interval>4294967295</live_timer_interval>
+      </session>
+    </sessions>
+  </output>
+</command>
+</COMMAND_OUTPUT>
+#------------------------------------------------------------------------------
+<COMMAND_INPUT>
+lttng --mi xml snapshot record -s blabla
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+1
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<COMMAND_ERROR_OUTPUT>
+    Error: Session name not found
+</COMMAND_ERROR_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>snapshot</name>
+  <output>
+    <snapshot_action>
+      <name>record</name>
+      <output/>
+    </snapshot_action>
+  </output>
+  <success>false</success>
+</command>
+</COMMAND_OUTPUT>
+#------------------------------------------------------------------------------
+<COMMAND_INPUT>
+lttng --mi xml snapshot record -s mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+1
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<COMMAND_ERROR_OUTPUT>
+    Error: Session needs to be started once
+</COMMAND_ERROR_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>snapshot</name>
+  <output>
+    <snapshot_action>
+      <name>record</name>
+      <output/>
+    </snapshot_action>
+  </output>
+  <success>false</success>
+</command>
+</COMMAND_OUTPUT>
+
+</SCENARIO>
+
+####################################################################
+# Scenario: Test "lttng create <session> --live [USEC] (LTTng 2.4)
+####################################################################
+<SCENARIO>
+CreateSessionLive
+<COMMAND_INPUT>
+lttng --mi xml create mysession --live -U net://127.0.0.1
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>create</name>
+  <output>
+    <session>
+      <name>mysession</name>
+      <path>tcp4://127.0.0.1:5342/ [data: 5343]</path>
+      <enabled>false</enabled>
+      <snapshot_mode>0</snapshot_mode>
+      <live_timer_interval>1000000</live_timer_interval>
+    </session>
+  </output>
+  <success>true</success>
+</command>
+</COMMAND_OUTPUT>
+#------------------------------------------------------------------------------
+<COMMAND_INPUT>
+lttng --mi xml list
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>list</name>
+  <output>
+    <sessions>
+      <session>
+        <name>mysession</name>
+        <path>tcp4://127.0.0.1:5342/ [data: 5343]</path>
+        <enabled>false</enabled>
+        <snapshot_mode>0</snapshot_mode>
+        <live_timer_interval>1000000</live_timer_interval>
+      </session>
+    </sessions>
+  </output>
+</command>
+</COMMAND_OUTPUT>
+#------------------------------------------------------------------------------
+<COMMAND_INPUT>
+lttng --mi xml destroy mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>destroy</name>
+  <output>
+    <sessions>
+      <session>
+        <name>mysession</name>
+        <path>/home/user/lttng-traces/mysession-20140818-100114</path>
+        <enabled>false</enabled>
+        <snapshot_mode>0</snapshot_mode>
+        <live_timer_interval>0</live_timer_interval>
+      </session>
+    </sessions>
+  </output>
+  <success>true</success>
+</command>
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test errors for  "lttng create <session> --live [USEC] (LTTng 2.4)
+####################################################################
+<SCENARIO>
+CreateSessionLiveErrors
+<COMMAND_INPUT>
+lttng --mi xml create mysession --live --snapshot
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+1
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<COMMAND_ERROR_OUTPUT>
+Error: Snapshot and live modes are mutually exclusive.
+Error: Command error
+</COMMAND_ERROR_OUTPUT>
+</COMMAND_OUTPUT>
+#------------------------------------------------------------------------------
+<COMMAND_INPUT>
+lttng --mi xml create mysession --live -U blah
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+1
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<COMMAND_ERROR_OUTPUT>
+Error: URI parse unknown protocol blah
+Error: Unable to parse the URL blah
+Error: Invalid parameter
+</COMMAND_ERROR_OUTPUT>
+</COMMAND_OUTPUT>
+#------------------------------------------------------------------------------
+<COMMAND_INPUT>
+lttng --mi xml create mysession --live -C net://127.0.0.1
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+1
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<COMMAND_ERROR_OUTPUT>
+Error: You need both control and data URL.
+Error: Command error
+</COMMAND_ERROR_OUTPUT>
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test "lttng list <session> (version 2.6.0, syscalls)
+####################################################################
+<SCENARIO>
+GetSessionWithSyscalls
+<COMMAND_INPUT>
+lttng --mi xml list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<?xml version="1.0" encoding="UTF-8"?>
+<command>
+  <name>list</name>
+  <output>
+    <sessions>
+      <session>
+        <name>mysession</name>
+        <path>/home/user/lttng-traces/mysession-20120129-084256</path>
+        <enabled>false</enabled><snapshot_mode>0</snapshot_mode>
+        <live_timer_interval>0</live_timer_interval>
+        <domains>
+          <domain>
+            <type>KERNEL</type>
+            <buffer_type>PER_PID</buffer_type>
+            <channels>
+              <channel>
+                <name>channel0</name>
+                <enabled>true</enabled>
+                <attributes>
+                  <overwrite_mode>DISCARD</overwrite_mode>
+                  <subbuffer_size>262144</subbuffer_size>
+                  <subbuffer_count>4</subbuffer_count>
+                  <switch_timer_interval>0</switch_timer_interval>
+                  <read_timer_interval>200</read_timer_interval>
+                  <output_type>SPLICE</output_type>
+                  <tracefile_size>0</tracefile_size>
+                  <tracefile_count>0</tracefile_count>
+                  <live_timer_interval>0</live_timer_interval>
+                </attributes><events>
+                <event>
+                  <name>read</name>
+                  <type>SYSCALL</type>
+                  <enabled>true</enabled>
+                  <filter>false</filter>
+                </event>
+                <event>
+                  <name>write</name>
+                  <type>SYSCALL</type>
+                  <enabled>true</enabled>
+                  <filter>false</filter>
+                </event>
+              </events>
+            </channel>
+          </channels>
+        </domain></domains>
+      </session>
+    </sessions>
+  </output>
+</command>
+</COMMAND_OUTPUT>
+</SCENARIO>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/testfiles/LTTngServiceTest.cfg b/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/testfiles/LTTngServiceTest.cfg
new file mode 100644 (file)
index 0000000..316d0de
--- /dev/null
@@ -0,0 +1,1578 @@
+####################################################################
+# Copyright (c) 2012, 2015 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:
+#    Bernd Hufmann - Initial API and implementation
+####################################################################
+####################################################################
+# Scenario: Test lttng not installed
+####################################################################
+<SCENARIO>
+LttngNotInstalled
+<COMMAND_INPUT>
+lttng list
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+1
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<COMMAND_ERROR_OUTPUT>
+Command not found
+</COMMAND_ERROR_OUTPUT>
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test lttng version
+####################################################################
+<SCENARIO>
+LttngVersion
+<COMMAND_INPUT>
+lttng version
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+lttng version 2.1.0 - Basse Messe
+Web site: http://lttng.org/
+
+lttng is free software and under the GPL license and part LGPL
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test lttng version
+# output with prompt
+####################################################################
+<SCENARIO>
+LttngVersionWithPrompt
+<COMMAND_INPUT>
+lttng version
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Prompt> lttng version 2.0.0 - Annedd'ale
+Web site: http://lttng.org/
+
+lttng is free software and under the GPL license and part LGPL
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test lttng version (unsupported version)
+####################################################################
+<SCENARIO>
+LttngUnsupportedVersion
+<COMMAND_INPUT>
+lttng version
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+lttng version 200.0.0 - Annedd'ale
+Web site: http://lttng.org/
+
+lttng is free software and under the GPL license and part LGPL
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+
+####################################################################
+# Scenario: Test lttng version (noversion)
+####################################################################
+<SCENARIO>
+LttngNoVersion
+<COMMAND_INPUT>
+lttng version
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Web site: http://lttng.org/
+
+lttng is free software and under the GPL license and part LGPL
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test lttng version (compiled from source)
+####################################################################
+<SCENARIO>
+LttngVersionCompiled
+<COMMAND_INPUT>
+lttng version
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+lttng version heads/stable-2.5-0-g3910e60 - Fumisterie
+
+The Fumisterie is a beer whose style is at the confluence of English and German ales. On the palate, it is full-bodied, malty and slightly caramelized. The organic hemp seeds incorporated during the brewing gives it a unique and original taste. The hop flavour comes through delicately in the after taste.
+
+Web site: http://lttng.org
+
+lttng is free software and under the GPL license and part LGPL
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test no sessions available
+####################################################################
+<SCENARIO>
+NoSessionAvailable
+<COMMAND_INPUT>
+lttng list
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Currently no available tracing session
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test get sessions
+####################################################################
+<SCENARIO>
+GetSessionNames1
+<COMMAND_INPUT>
+lttng list
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Available tracing sessions:
+  1) mysession1 (/home/user/lttng-traces/mysession1-20120123-083928) [inactive]
+  2) mysession (/home/user/lttng-traces/mysession-20120123-083318) [inactive]
+
+ Use lttng list <session_name> for more details
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test get sessions with tracing group
+####################################################################
+<SCENARIO>
+GetSessionWithTracingGroup
+<COMMAND_INPUT>
+lttng -g group list
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Available tracing sessions:
+  1) mysession1 (/home/user/lttng-traces/mysession1-20120123-083928) [inactive]
+  2) mysession (/home/user/lttng-traces/mysession-20120123-083318) [inactive]
+
+ Use lttng list <session_name> for more details
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test lttng list <name> where session doesn't exist
+####################################################################
+<SCENARIO>
+GetSessionNameNotExist
+<COMMAND_INPUT>
+lttng list test
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+1
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Session test not found
+<COMMAND_ERROR_OUTPUT>
+Error: Session name not found
+</COMMAND_ERROR_OUTPUT>
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test lttng -vvv list <name> where session doesn't exist
+####################################################################
+<SCENARIO>
+GetSessionNameNotExistVerbose
+<COMMAND_INPUT>
+lttng -vvv list test
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+1
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+DEBUG2: Session name: test [in cmd_list() at commands/list.c:618]
+DEBUG1: Session count 1 [in list_sessions() at commands/list.c:485]
+<COMMAND_ERROR_OUTPUT>
+Error: Session 'test' not found
+Error: Command error
+</COMMAND_ERROR_OUTPUT>
+DEBUG1: Clean exit [in clean_exit() at lttng.c:165]
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test lttng list with garbage output
+####################################################################
+<SCENARIO>
+GetSessionGarbageOut
+<COMMAND_INPUT>
+lttng list
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+asdfaereafsdcv 12333456434&*89**(())(^%$*
+@#$%^&*()@#$%^&*()0834523094578kj;djkfs
+a;sdf094v5u dsafj;sd9
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test lttng list <name> with sample outputs
+####################################################################
+<SCENARIO>
+GetSession1
+<COMMAND_INPUT>
+lttng list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession: [active]
+    Trace path: /home/user/lttng-traces/mysession-20120129-084256
+
+=== Domain: Kernel ===
+
+Channels:
+-------------
+- channel0: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 262144
+      number of subbufers: 4
+      switch timer interval: 0
+      read timer interval: 200
+      output: splice()
+
+    Events:
+      block_rq_remap (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      block_bio_remap (loglevel: TRACE_EMERG (0)) (type: tracepoint) [disabled]
+
+- channel1: [disabled]
+
+    Attributes:
+      overwrite mode: 1
+      subbufers size: 524288
+      number of subbufers: 4
+      switch timer interval: 100
+      read timer interval: 400
+      output: splice()
+
+    Events:
+      None
+
+=== Domain: UST global ===
+
+Channels:
+-------------
+- mychannel1: [disabled]
+
+    Attributes:
+     overwrite mode: 1
+     subbufers size: 8192
+      number of subbufers: 8
+      switch timer interval: 200
+      read timer interval: 100
+      output: mmap()
+
+    Events:
+      None
+
+- channel0: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 4096
+      number of subbufers: 4
+      switch timer interval: 0
+      read timer interval: 200
+      output: mmap()
+
+    Events:
+      ust_tests_hello:tptest_sighandler (loglevel: TRACE_DEBUG_LINE (13)) (type: tracepoint) [disabled]
+      * (type: tracepoint) [enabled]
+
+</COMMAND_OUTPUT>
+<COMMAND_INPUT>
+lttng list mysession1
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession1: [inactive]
+    Trace path: /home/user/lttng-traces/mysession1-20120203-133225
+
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test lttng list <name> (with live time interval)
+####################################################################
+<SCENARIO>
+GetSessionWithLiveInterval
+<COMMAND_INPUT>
+lttng list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession: [inactive snapshot]
+    Trace path: 
+    Live timer interval (usec): 4294967295
+
+</COMMAND_OUTPUT>
+#------------------------------------------------------------------------------
+<COMMAND_INPUT>
+lttng snapshot list-output -s mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Snapshot output list for session mysession
+    [1] snapshot-1: /home/user/lttng-traces/mysession-20120129-084256 (max-size: 0)
+</COMMAND_OUTPUT>
+#------------------------------------------------------------------------------
+<COMMAND_INPUT>
+lttng list mysession1
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession1: [active]
+    Trace path: /home/user/lttng-traces/mysession1-20120129-084256
+    Live timer interval (usec): 0
+
+</COMMAND_OUTPUT>
+#------------------------------------------------------------------------------
+<COMMAND_INPUT>
+lttng list mysession2
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession2: [inactive]
+    Trace path: tcp4://172.0.0.1:5342/ [data: 5343]
+    Live timer interval (usec): 1000000
+
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test "lttng list -k" with sample output
+####################################################################
+<SCENARIO>
+GetKernelProvider1
+<COMMAND_INPUT>
+lttng list -k
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Kernel events
+-------------
+      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint)
+      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint)
+      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint)
+
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test "lttng list -k" with no kernel and no session daemon
+####################################################################
+<SCENARIO>
+ListWithNoKernel1
+<COMMAND_INPUT>
+lttng list -k
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+1
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Spawning session daemon
+<COMMAND_ERROR_OUTPUT>
+Error: Unable to list kernel events
+</COMMAND_ERROR_OUTPUT>
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test "lttng list -k" with no kernel and with session daemon
+####################################################################
+<SCENARIO>
+ListWithNoKernel2
+<COMMAND_INPUT>
+lttng list -k
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+1
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<COMMAND_ERROR_OUTPUT>
+Error: Unable to list kernel events
+</COMMAND_ERROR_OUTPUT>
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test "lttng list -k" with no kernel, with session daemon and verbose
+####################################################################
+<SCENARIO>
+ListWithNoKernelVerbose
+<COMMAND_INPUT>
+lttng -vvv list -k
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+1
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+DEBUG2: Session name: (null) [in cmd_list() at commands/list.c:618]
+DEBUG1: Getting kernel tracing events [in list_kernel_events() at commands/list.c:309]
+<COMMAND_ERROR_OUTPUT>
+Error: Unable to list kernel events
+</COMMAND_ERROR_OUTPUT>
+DEBUG1: Clean exit [in clean_exit() at lttng.c:165]
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test "lttng list -u" with sample output
+####################################################################
+<SCENARIO>
+GetUstProvider1
+<COMMAND_INPUT>
+lttng list -u
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+UST events:
+-------------
+
+PID: 9379 - Name: /home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello
+    ust_tests_hello:tptest_sighandler (loglevel: TRACE_DEBUG_MODULE (10)) (type: tracepoint)
+    ust_tests_hello:tptest (loglevel: TRACE_INFO (6)) (type: tracepoint)
+
+PID: 4852 - Name: /home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello
+    ust_tests_hello:tptest_sighandler (loglevel: TRACE_WARNING (4)) (type: tracepoint)
+    ust_tests_hello:tptest (loglevel: TRACE_DEBUG_FUNCTION (12)) (type: tracepoint)
+
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test "lttng list -u" with no UST provider available
+####################################################################
+<SCENARIO>
+GetUstProvider2
+<COMMAND_INPUT>
+lttng list -u
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+UST events:
+-------------
+None
+
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test "lttng list -u" with no UST available (LTTng 2.0.x)
+####################################################################
+<SCENARIO>
+ListWithNoUst1
+<COMMAND_INPUT>
+lttng list -u
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+1
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+UST events:
+-------------
+None
+Segmentation Fault
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test "lttng list -u" with no UST available and no session daemon
+####################################################################
+<SCENARIO>
+ListWithNoUst2
+<COMMAND_INPUT>
+lttng list -u -f
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+1
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Spawning a session daemon
+<COMMAND_ERROR_OUTPUT>
+Error: Unable to list UST events: Listing UST events failed
+Error: Command Error
+</COMMAND_ERROR_OUTPUT>
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test "lttng list -u" with no ust and with session daemon
+####################################################################
+<SCENARIO>
+ListWithNoUst3
+<COMMAND_INPUT>
+lttng list -u -f
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+1
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<COMMAND_ERROR_OUTPUT>
+Error: Unable to list UST events: Listing UST events failed
+Error: Command Error
+</COMMAND_ERROR_OUTPUT>
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test "lttng list -u" with no kernel, with session daemon and verbose
+####################################################################
+<SCENARIO>
+ListWithNoUstVerbose
+<COMMAND_INPUT>
+lttng -vvv list -u -f
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+1
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+DEBUG2: Session name: (null) [in cmd_list() at commands/list.c:618]
+DEBUG1: Getting kernel tracing events [in list_kernel_events() at commands/list.c:309]
+Spawning a session daemon
+<COMMAND_ERROR_OUTPUT>
+Error: Unable to list UST events: Listing UST events failed
+Error: Command Error
+</COMMAND_ERROR_OUTPUT>
+DEBUG1: Clean exit [in clean_exit() at lttng.c:165]
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+
+####################################################################
+# Scenario: Test "lttng list -u -f" with sample output (version 2.1.0)
+####################################################################
+<SCENARIO>
+GetUstProvider3
+<COMMAND_INPUT>
+lttng list -u -f
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+UST events:
+-------------
+
+PID: 9379 - Name: /home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello
+    ust_tests_hello:tptest_sighandler (loglevel: TRACE_DEBUG_MODULE (10)) (type: tracepoint)
+    ust_tests_hello:tptest (loglevel: TRACE_INFO (6)) (type: tracepoint)
+        field: doublefield (float)
+        field: floatfield (float)
+        field: stringfield (string)
+
+PID: 4852 - Name: /home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello
+    ust_tests_hello:tptest_sighandler (loglevel: TRACE_WARNING (4)) (type: tracepoint)
+    ust_tests_hello:tptest (loglevel: TRACE_DEBUG_FUNCTION (12)) (type: tracepoint)
+        field: doublefield (float)
+        field: floatfield (float)
+        field: stringfield (string)
+
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+
+####################################################################
+# Scenario: Test "lttng create <session>
+####################################################################
+<SCENARIO>
+CreateSession1
+<COMMAND_INPUT>
+lttng create mysession2
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Session mysession2 created.
+Traces will be written in /home/user/lttng-traces/mysession2-20120209-095418
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test "lttng create <session>
+####################################################################
+<SCENARIO>
+CreateSessionWithPrompt
+<COMMAND_INPUT>
+lttng create mysession2
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Prompt> Session mysession2 created.
+Traces will be written in /home/user/lttng-traces/mysession2-20120209-095418
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test "lttng create <session> with different variants
+# and errors
+####################################################################
+<SCENARIO>
+CreateSessionVariants
+<COMMAND_INPUT>
+lttng create alreadyExist
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+1
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<COMMAND_ERROR_OUTPUT>
+Error: Session name already exist
+</COMMAND_ERROR_OUTPUT>
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng create session with spaces
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Session session with spaces created.
+Traces will be written in /home/user/lttng-traces/session with spaces-20120209-095418
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng create wrongName
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Session auto created.
+Traces will be written in /home/user/lttng-traces/auto-20120209-095418
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng create wrongPath -o /home/user/hallo
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Session wrongPath created.
+Traces will be written in /home/user/lttng-traces/wrongPath-20120209-095418
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng create pathWithSpaces -o /home/user/hallo user/here
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Session pathWithSpaces created.
+Traces will be written in /home/user/hallo user/here/pathWithSpaces-20120209-095418
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test "lttng destroy <session>
+####################################################################
+
+<SCENARIO>
+DestroySession1
+<COMMAND_INPUT>
+lttng destroy mysession2
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Session mysession2 destroyed.
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test "lttng -vvv destroy <session>"
+####################################################################
+
+<SCENARIO>
+DestroySessionVerbose
+<COMMAND_INPUT>
+lttng -vvv destroy mysession2
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+DEBUG2: Config file path found: /home/eedbhu [in get_session_name() at utils.c:98]
+DEBUG1: Session name found: mysession2 [in get_session_name() at utils.c:99]
+Session mysession2 destroyed at /home/eedbhu
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+
+####################################################################
+# Scenario: Test "lttng enable-channel ..." with different inputs
+####################################################################
+
+<SCENARIO>
+ChannelHandling
+<COMMAND_INPUT>
+lttng enable-channel mychannel0,mychannel1 -k -s mysession2 --overwrite --subbuf-size 16384 --num-subbuf 2 --switch-timer 200 --read-timer 100 -C 0 -W 10
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Kernel channel mychannel0 enabled for session mysession2
+Kernel channel mychannel1 enabled for session mysession2
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng enable-channel mychannel0,mychannel1 -k -s mysession2 --overwrite --subbuf-size 16384 --num-subbuf 2 --switch-timer 200 --read-timer 100
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Kernel channel mychannel0 enabled for session mysession2
+Kernel channel mychannel1 enabled for session mysession2
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng enable-channel ustChannel -u -s mysession2 --overwrite --subbuf-size 32768 --num-subbuf 1 --switch-timer 100 --read-timer 200 -C 0 -W 20
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+UST channel channel0 enabled for session mysession2
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng enable-channel ustChannel -u -s mysession2 --overwrite --subbuf-size 32768 --num-subbuf 1 --switch-timer 100 --read-timer 200
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+UST channel channel0 enabled for session mysession2
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng enable-channel ustChannel -u -s mysession2 --overwrite --subbuf-size 32768 --num-subbuf 1 --switch-timer 100 --read-timer 200 --buffers-uid -C 0 -W 20
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+UST channel channel0 enabled for session mysession2
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng enable-channel ustChannel -u -s mysession2 --overwrite --buffers-pid
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+UST channel ustChannel enabled for session mysession2
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng enable-channel ustChannel -u -s mysession2 --overwrite --subbuf-size 32768 --num-subbuf 1 --switch-timer 100 --read-timer 200 --buffers-uid
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+UST channel channel0 enabled for session mysession2
+</COMMAND_OUTPUT>
+
+
+<COMMAND_INPUT>
+lttng enable-channel mychannel0,mychannel1 -k -s mysession2
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Kernel channel mychannel0 enabled for session mysession2
+Kernel channel mychannel1 enabled for session mysession2
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng enable-channel ustChannel -u -s mysession2
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+UST channel mychannel0 enabled for session mysession2
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng disable-channel mychannel0,mychannel1 -k -s mysession2
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Kernel channel mychannel0 disabled for session mysession2
+Kernel channel mychannel1 disabled for session mysession2
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng disable-channel ustChannel -u -s mysession2
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+UST channel mychannel0 enabled for session mysession2
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+
+####################################################################
+# Scenario: Test "lttng enable-events ..." with different inputs
+####################################################################
+<SCENARIO>
+EventHandling
+
+# Tracepoint test cases
+
+<COMMAND_INPUT>
+lttng enable-event block_rq_remap,block_bio_remap,softirq_entry -k -s mysession2 --tracepoint
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+kernel event block_rq_remap created in channel channel0
+kernel event block_bio_remap created in channel channel0
+kernel event softirq_entry created in channel channel0
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng enable-event -a -k -s mysession2 -c mychannel --tracepoint
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+All kernel tracepoints are enabled in channel channel0
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng enable-event ust_tests_hello:tptest_sighandler -u -s mysession2 -c mychannel --tracepoint
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+UST event ust_tests_hello:tptest_sighandler created in channel mychannel
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng enable-event ust_tests_hello:tptest_sighandler -u -s mysession2 -c mychannel --tracepoint --filter intfield==10
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+UST event ust_tests_hello:tptest_sighandler created in channel mychannel
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng enable-event -a -u -s mysession2 -c mychannel --tracepoint
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+All UST tracepoints are enabled in channel mychannel
+</COMMAND_OUTPUT>
+
+# Syscall test cases
+
+<COMMAND_INPUT>
+lttng enable-event -a -k -s mysession2 --syscall
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+All kernel system calls are enabled in channel channel0
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng enable-event -a -k -s mysession2 -c mychannel --syscall
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+All kernel system calls are enabled in channel mychannel
+</COMMAND_OUTPUT>
+
+# dynamic probe/function probe test cases
+
+<COMMAND_INPUT>
+lttng enable-event myevent0 -k -s mysession2 --function 0xc0101340
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+kernel event myevent0 created in channel mychannel
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng enable-event myevent1 -k -s mysession2 -c mychannel --probe init_post
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+kernel event myevent1 created in channel mychannel
+</COMMAND_OUTPUT>
+
+# log level test cases
+
+<COMMAND_INPUT>
+lttng enable-event myevent4 -u -s mysession2 --loglevel-only TRACE_DEBUG
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+UST event myevent4 created in channel channel0
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng enable-event myevent5 -u -s mysession2 -c mychannel --loglevel TRACE_DEBUG_FUNCTION
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+UST event myevent5 created in channel mychannel
+</COMMAND_OUTPUT>
+
+</SCENARIO>
+
+####################################################################
+# Scenario: Test "lttng add-context -h" and lttng add-context ..." with different inputs
+####################################################################
+
+<SCENARIO>
+ContextHandling
+
+<COMMAND_INPUT>
+lttng add-context -h
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+usage: lttng add-context -t TYPE
+
+If no channel and no event is given (-c/-e), the context
+will be added to all events and all channels.
+Otherwise the context will be added only to the channel (-c)
+and/or event (-e) indicated.
+Exactly one domain (-k/--kernel or -u/--userspace) must be specified.
+
+Options:
+  -h, --help               Show this help
+      --list-options       Simple listing of options
+  -s, --session NAME       Apply to session name
+  -c, --channel NAME       Apply to channel
+  -e, --event NAME         Apply to event
+  -k, --kernel             Apply to the kernel tracer
+  -u, --userspace          Apply to the user-space tracer
+  -t, --type TYPE          Context type. You can repeat that option on
+                           the command line to specify multiple contexts at once.
+                           (--kernel preempts --userspace)
+                           TYPE can be one of the strings below:
+                               pid, procname, prio, nice, vpid, tid, pthread_id,
+                               vtid, ppid, vppid, perf:cpu-cycles, perf:cycles
+Example:
+This command will add the context information 'prio' and two perf
+counters (hardware branch misses and cache misses), to all events
+in the trace data output:
+# lttng add-context -k -t prio -t perf:branch-misses -t perf:cache-misses
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng add-context -s mysession2 -c mychannel -e ust_tests_hello:tptest_sighandler -u -t prio -t pid
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+UST context prio added to event ust_tests_hello:tptest_sighandle channel mychannel
+UST context pid added to event sched_kthread_stop_ret channel mychannel
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+<SCENARIO>
+ContextErrorHandling
+
+<COMMAND_INPUT>
+lttng add-context -h
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+1
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+usage: lttng add-context -t TYPE
+
+If no channel and no event is given (-c/-e), the context
+will be added to all events and all channels.
+Otherwise the context will be added only to the channel (-c)
+and/or event (-e) indicated.
+Exactly one domain (-k/--kernel or -u/--userspace) must be specified.
+
+Options:
+  -h, --help               Show this help
+      --list-options       Simple listing of options
+  -s, --session NAME       Apply to session name
+  -c, --channel NAME       Apply to channel
+  -e, --event NAME         Apply to event
+  -k, --kernel             Apply to the kernel tracer
+  -u, --userspace          Apply to the user-space tracer
+  -t, --type TYPE          Context type. You can repeat that option on
+                           the command line to specify multiple contexts at once.
+                           (--kernel preempts --userspace)
+                           TYPE can be one of the strings below:
+                               pid, procname, prio, nice, vpid, tid, pthread_id,
+                               vtid, ppid, vppid, perf:cpu-cycles, perf:cycles
+Example:
+This command will add the context information 'prio' and two perf
+counters (hardware branch misses and cache misses), to all events
+in the trace data output:
+# lttng add-context -k -t prio -t perf:branch-misses -t perf:cache-misses
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng add-context -s mysession2 -c mychannel -e ust_tests_hello:tptest_sighandler -u -t prio -t pid
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+1
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+UST context prio added to event ust_tests_hello:tptest_sighandle channel mychannel
+UST context pid added to event sched_kthread_stop_ret channel mychannel
+</COMMAND_OUTPUT>
+
+</SCENARIO>
+
+<SCENARIO>
+CalibrateHandling
+<COMMAND_INPUT>
+lttng calibrate -k --function
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Kernel calibration done
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng calibrate -u --function
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+1
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Kernel calibration done
+</COMMAND_OUTPUT>
+
+</SCENARIO>
+
+####################################################################
+# Scenario: Test "lttng create <session> with LTTng 2.1 options
+####################################################################
+<SCENARIO>
+CreateSessionLttng2.1
+
+<COMMAND_INPUT>
+lttng create mysession -U net://172.0.0.1
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Session mysession created.
+Traces will be written in net://172.0.0.1
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng create mysession -U file:///tmp
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Session mysession created.
+Traces will be written in file:///tmp
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng create mysession -C tcp://172.0.0.1 -D tcp://172.0.0.1:5343
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Session mysession created.
+Control URL tcp://172.0.0.1 set for session mysession
+Data URL tcp://172.0.0.1:5343 set for session mysession
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng create mysession -U net://172.0.0.1:1234:2345
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Session mysession created.
+Traces will be written in net://172.0.0.1:1234:2345
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng destroy mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Session mysession destroyed.
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng -vvv create mysession -U net://172.0.0.1
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+DEBUG3: URI string: net://172.0.0.1 [in uri_parse() at uri.c:253]
+DEBUG2: IP address resolved to 172.0.0.1 [in set_ip_address() at uri.c:132]
+DEBUG3: URI dtype: 1, proto: 1, host: 172.0.0.1, subdir: , ctrl: 0, data: 0 [in uri_parse() at uri.c:467]
+DEBUG1: LSM cmd type : 8 [in send_session_msg() at lttng-ctl.c:261]
+Session mysession created.
+Traces will be written in net://172.0.0.1
+DEBUG1: Init config session in /home/bernd [in config_init() at conf.c:294]
+</COMMAND_OUTPUT>
+
+</SCENARIO>
+
+####################################################################
+# Scenario: Test "lttng -vvv create <session> with LTTng 2.1 options"
+####################################################################
+<SCENARIO>
+CreateSessionLttngVerbose2.1
+<COMMAND_INPUT>
+lttng -vvv create mysession -U net://172.0.0.1
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+DEBUG3: URI string: net://172.0.0.1 [in uri_parse() at uri.c:253]
+DEBUG2: IP address resolved to 172.0.0.1 [in set_ip_address() at uri.c:132]
+DEBUG3: URI dtype: 1, proto: 1, host: 172.0.0.1, subdir: , ctrl: 0, data: 0 [in uri_parse() at uri.c:467]
+DEBUG1: LSM cmd type : 8 [in send_session_msg() at lttng-ctl.c:261]
+Session mysession created.
+Traces will be written in net://172.0.0.1
+DEBUG1: Init config session in /home/bernd [in config_init() at conf.c:294]
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng -vvv destroy mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Session mysession destroyed.
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test "lttng create <session> --snapshot (LTTng 2.3)
+####################################################################
+<SCENARIO>
+CreateSessionSnapshot
+<COMMAND_INPUT>
+lttng create mysession --snapshot
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Session mysession created.
+Default snapshot output set to: /home/user/lttng-traces/mysession-20130913-141651
+Snapshot mode set. Every channel enabled for that session will be set in overwrite mode and mmap output.
+</COMMAND_OUTPUT>
+#------------------------------------------------------------------------------
+<COMMAND_INPUT>
+lttng snapshot list-output -s mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Snapshot output list for session mysession
+    [1] snapshot-1: /home/user/lttng-traces/mysession-20130913-141651
+</COMMAND_OUTPUT>
+#------------------------------------------------------------------------------
+<COMMAND_INPUT>
+lttng list
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+  1) mysession () [inactive snapshot]
+
+</COMMAND_OUTPUT>
+#------------------------------------------------------------------------------
+<COMMAND_INPUT>
+lttng snapshot record -s mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+    Snapshot recorded successfully for session mysession
+</COMMAND_OUTPUT>
+#------------------------------------------------------------------------------
+<COMMAND_INPUT>
+lttng destroy mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Session mysession destroyed.
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test "lttng create <session> --snapshot -U <URL> (LTTng 2.3)
+####################################################################
+<SCENARIO>
+CreateSessionStreamedSnapshot
+<COMMAND_INPUT>
+lttng create mysession --snapshot -U net://172.0.0.1
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Session mysession created.
+Default snapshot output set to: net://172.0.0.1
+Snapshot mode set. Every channel enabled for that session will be set in overwrite mode and mmap output.
+</COMMAND_OUTPUT>
+#------------------------------------------------------------------------------
+<COMMAND_INPUT>
+lttng snapshot list-output -s mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Snapshot output list for session mysession
+    [2] snapshot-2: net4://172.0.0.1:5342/
+</COMMAND_OUTPUT>
+#------------------------------------------------------------------------------
+<COMMAND_INPUT>
+lttng list
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+  1) mysession () [inactive snapshot]
+
+</COMMAND_OUTPUT>
+#------------------------------------------------------------------------------
+<COMMAND_INPUT>
+lttng snapshot record -s mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+    Snapshot recorded successfully for session mysession
+</COMMAND_OUTPUT>
+#------------------------------------------------------------------------------
+<COMMAND_INPUT>
+lttng destroy mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Session mysession destroyed.
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test "lttng create <session> --snapshot (LTTng 2.3)
+####################################################################
+<SCENARIO>
+CreateSessionSnapshotErrors
+<COMMAND_INPUT>
+lttng snapshot list-output -s blabla
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+1
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<COMMAND_ERROR_OUTPUT>
+Error: Session name not found
+</COMMAND_ERROR_OUTPUT>
+</COMMAND_OUTPUT>
+#------------------------------------------------------------------------------
+#next is not an error case but good to be tested
+<COMMAND_INPUT>
+lttng list
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+  1) mysession () [active snapshot]
+
+</COMMAND_OUTPUT>
+#------------------------------------------------------------------------------
+<COMMAND_INPUT>
+lttng snapshot record -s blabla
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+1
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<COMMAND_ERROR_OUTPUT>
+    Error: Session name not found
+</COMMAND_ERROR_OUTPUT>
+</COMMAND_OUTPUT>
+#------------------------------------------------------------------------------
+<COMMAND_INPUT>
+lttng snapshot record -s mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+1
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<COMMAND_ERROR_OUTPUT>
+    Error: Session needs to be started once
+</COMMAND_ERROR_OUTPUT>
+</COMMAND_OUTPUT>
+
+</SCENARIO>
+
+####################################################################
+# Scenario: Test "lttng create <session> --live [USEC] (LTTng 2.4)
+####################################################################
+<SCENARIO>
+CreateSessionLive
+<COMMAND_INPUT>
+lttng create mysession --live -U net://127.0.0.1
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Session mysession created.
+Traces will be written in net://127.0.0.1
+Live timer set to 1000000 usec
+</COMMAND_OUTPUT>
+#------------------------------------------------------------------------------
+<COMMAND_INPUT>
+lttng list
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Available tracing sessions:
+  1) mysession (net4://127.0.0.1:5342/ [data: 5343]) [inactive]
+
+Use lttng list <session_name> for more details
+</COMMAND_OUTPUT>
+#------------------------------------------------------------------------------
+<COMMAND_INPUT>
+lttng destroy mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Session mysession destroyed.
+</COMMAND_OUTPUT>
+</SCENARIO>
+
+####################################################################
+# Scenario: Test errors for  "lttng create <session> --live [USEC] (LTTng 2.4)
+####################################################################
+<SCENARIO>
+CreateSessionLiveErrors
+<COMMAND_INPUT>
+lttng create mysession --live --snapshot
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+1
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<COMMAND_ERROR_OUTPUT>
+Error: Snapshot and live modes are mutually exclusive.
+Error: Command error
+</COMMAND_ERROR_OUTPUT>
+</COMMAND_OUTPUT>
+#------------------------------------------------------------------------------
+<COMMAND_INPUT>
+lttng create mysession --live -U blah
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+1
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<COMMAND_ERROR_OUTPUT>
+Error: URI parse unknown protocol blah
+Error: Unable to parse the URL blah
+Error: Invalid parameter
+</COMMAND_ERROR_OUTPUT>
+</COMMAND_OUTPUT>
+#------------------------------------------------------------------------------
+<COMMAND_INPUT>
+lttng create mysession --live -C net://127.0.0.1
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+1
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<COMMAND_ERROR_OUTPUT>
+Error: You need both control and data URL.
+Error: Command error
+</COMMAND_ERROR_OUTPUT>
+</COMMAND_OUTPUT>
+</SCENARIO>
+####################################################################
+# Scenario: Test "lttng create <session> --snapshot (LTTng 2.5)
+####################################################################
+<SCENARIO>
+CreateSessionSnapshot2.5
+<COMMAND_INPUT>
+lttng create mysession --snapshot
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Session mysession created.
+Default snapshot output set to: /home/user/lttng-traces/mysession-20130913-141651
+Snapshot mode set. Every channel enabled for that session will be set in overwrite mode and mmap output.
+</COMMAND_OUTPUT>
+#------------------------------------------------------------------------------
+<COMMAND_INPUT>
+lttng snapshot list-output -s mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Snapshot output list for session mysession
+    [1] snapshot-1: /home/user/lttng-traces/mysession-20130913-141651 (max-size: 0)
+</COMMAND_OUTPUT>
+#------------------------------------------------------------------------------
+<COMMAND_INPUT>
+lttng list
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+  1) mysession () [inactive snapshot]
+
+</COMMAND_OUTPUT>
+#------------------------------------------------------------------------------
+<COMMAND_INPUT>
+lttng snapshot record -s mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+    Snapshot recorded successfully for session mysession
+</COMMAND_OUTPUT>
+#------------------------------------------------------------------------------
+<COMMAND_INPUT>
+lttng destroy mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Session mysession destroyed.
+</COMMAND_OUTPUT>
+</SCENARIO>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/testfiles/ListInfoTest.cfg b/lttng/org.eclipse.tracecompass.lttng2.control.ui.tests/testfiles/ListInfoTest.cfg
new file mode 100644 (file)
index 0000000..95d3b52
--- /dev/null
@@ -0,0 +1,244 @@
+####################################################################
+# Copyright (c) 2012, 2015 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:
+#    Bernd Hufmann - Initial API and implementation
+####################################################################
+####################################################################
+# Scenario: Test lttng list <name> with sample outputs
+####################################################################
+<SCENARIO>
+ListInfoTest
+
+<COMMAND_INPUT>
+lttng version
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+lttng version 2.5.0 - 20120129-084256
+Web site: http://lttng.org/
+
+lttng is free software and under the GPL license and part LGPL
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Available tracing sessions:
+  1) mysession1 (/home/user/lttng-traces/mysession1-20120123-083928) [inactive]
+  2) mysession (/home/user/lttng-traces/mysession-20120123-083318) [inactive]
+
+ Use lttng list <session_name> for more details
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list mysession
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession: [active]
+    Trace path: /home/user/lttng-traces/mysession-20120129-084256
+
+=== Domain: Kernel ===
+
+Channels:
+-------------
+- channel0: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 262144
+      number of subbufers: 4
+      switch timer interval: 0
+      read timer interval: 200
+      trace file count: 2
+      trace file size (bytes): 262144
+      output: splice()
+
+    Events:
+      block_rq_remap (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
+      block_bio_remap (loglevel: TRACE_EMERG (0)) (type: tracepoint) [disabled]
+      myevent2 (type: probe) [enabled]
+        addr: 0xc0101340
+      myevent0 (type: probe) [enabled]
+        offset: 0x0
+        symbol: init_post
+      syscalls (type: syscall) [enabled]
+
+- channel1: [disabled]
+
+    Attributes:
+      overwrite mode: 1
+      subbufers size: 524288
+      number of subbufers: 4
+      switch timer interval: 100
+      read timer interval: 400
+      output: splice()
+
+    Events:
+      None
+
+=== Domain: UST global ===
+
+Channels:
+-------------
+- mychannel1: [disabled]
+
+    Attributes:
+     overwrite mode: 1
+     subbufers size: 8192
+      number of subbufers: 8
+      switch timer interval: 200
+      read timer interval: 100
+      trace file count: 2
+      trace file size (bytes): 8192
+      output: mmap()
+
+    Events:
+      None
+
+- channel0: [enabled]
+
+    Attributes:
+      overwrite mode: 0
+      subbufers size: 4096
+      number of subbufers: 4
+      switch timer interval: 0
+      read timer interval: 200
+      output: mmap()
+
+    Events:
+      ust_tests_hello:tptest_sighandler (loglevel == TRACE_DEBUG_LINE (13)) (type: tracepoint) [disabled] [with filter]
+      ust_tests_hello:tptest_sighandler1 (loglevel <= TRACE_INFO (7)) (type: tracepoint) [disabled] [with filter]
+      ust_tests_hello:tptest_sighandler2 (loglevel: TRACE_DEBUG_SYSTEM (8)) (type: tracepoint) [disabled] [with filter]
+      * (type: tracepoint) [enabled]
+
+</COMMAND_OUTPUT>
+<COMMAND_INPUT>
+lttng list mysession1
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Tracing session mysession1: [inactive]
+    Trace path: /home/user/lttng-traces/mysession1-20120203-133225
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list -k
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Kernel events
+-------------
+      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint)
+      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint)
+      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint)
+
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list -u -f
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+UST events:
+-------------
+
+PID: 9379 - Name: /home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello
+    ust_tests_hello:tptest_sighandler (loglevel: TRACE_DEBUG_MODULE (10)) (type: tracepoint)
+    ust_tests_hello:tptest (loglevel: TRACE_INFO (6)) (type: tracepoint)
+        field: doublefield (float)
+        field: floatfield (float)
+        field: stringfield (string)
+
+PID: 4852 - Name: /home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello
+    ust_tests_hello:tptest_sighandler (loglevel: TRACE_WARNING (4)) (type: tracepoint)
+    ust_tests_hello:tptest (loglevel: TRACE_DEBUG_FUNCTION (12)) (type: tracepoint)
+        field: doublefield (float)
+        field: floatfield (float)
+        field: stringfield (string)
+
+</COMMAND_OUTPUT>
+
+</SCENARIO>
+
+
+####################################################################
+# Scenario: Test "lttng list -k" with no kernel and no session daemon
+####################################################################
+<SCENARIO>
+ListInfoTestNoKernel
+
+<COMMAND_INPUT>
+lttng version
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+lttng version 2.0.0 - Annedd'ale
+Web site: http://lttng.org/
+
+lttng is free software and under the GPL license and part LGPL
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+Currently no available tracing session
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list -k
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+1
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+<COMMAND_ERROR_OUTPUT>
+Error: Unable to list kernel events
+</COMMAND_ERROR_OUTPUT>
+</COMMAND_OUTPUT>
+
+<COMMAND_INPUT>
+lttng list -u
+</COMMAND_INPUT>
+<COMMAND_RESULT>
+0
+</COMMAND_RESULT>
+<COMMAND_OUTPUT>
+UST events:
+-------------
+
+PID: 9379 - Name: /home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello
+    ust_tests_hello:tptest_sighandler (loglevel: TRACE_DEBUG_MODULE (10)) (type: tracepoint)
+    ust_tests_hello:tptest (loglevel: TRACE_INFO (6)) (type: tracepoint)
+
+</COMMAND_OUTPUT>
+
+</SCENARIO>
+
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/.classpath b/lttng/org.eclipse.tracecompass.lttng2.control.ui/.classpath
new file mode 100644 (file)
index 0000000..098194c
--- /dev/null
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+       <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7"/>
+       <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
+       <classpathentry kind="src" path="src"/>
+       <classpathentry kind="output" path="bin"/>
+</classpath>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/.project b/lttng/org.eclipse.tracecompass.lttng2.control.ui/.project
new file mode 100644 (file)
index 0000000..9988dea
--- /dev/null
@@ -0,0 +1,34 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+       <name>org.eclipse.tracecompass.lttng2.control.ui</name>
+       <comment></comment>
+       <projects>
+       </projects>
+       <buildSpec>
+               <buildCommand>
+                       <name>org.eclipse.jdt.core.javabuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+               <buildCommand>
+                       <name>org.eclipse.pde.ManifestBuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+               <buildCommand>
+                       <name>org.eclipse.pde.SchemaBuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+               <buildCommand>
+                       <name>org.eclipse.pde.api.tools.apiAnalysisBuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+       </buildSpec>
+       <natures>
+               <nature>org.eclipse.pde.PluginNature</nature>
+               <nature>org.eclipse.jdt.core.javanature</nature>
+               <nature>org.eclipse.pde.api.tools.apiAnalysisNature</nature>
+       </natures>
+</projectDescription>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/.settings/org.eclipse.core.resources.prefs b/lttng/org.eclipse.tracecompass.lttng2.control.ui/.settings/org.eclipse.core.resources.prefs
new file mode 100644 (file)
index 0000000..99f26c0
--- /dev/null
@@ -0,0 +1,2 @@
+eclipse.preferences.version=1
+encoding/<project>=UTF-8
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/.settings/org.eclipse.core.runtime.prefs b/lttng/org.eclipse.tracecompass.lttng2.control.ui/.settings/org.eclipse.core.runtime.prefs
new file mode 100644 (file)
index 0000000..5a0ad22
--- /dev/null
@@ -0,0 +1,2 @@
+eclipse.preferences.version=1
+line.separator=\n
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/.settings/org.eclipse.jdt.core.prefs b/lttng/org.eclipse.tracecompass.lttng2.control.ui/.settings/org.eclipse.jdt.core.prefs
new file mode 100644 (file)
index 0000000..a2b5e6b
--- /dev/null
@@ -0,0 +1,405 @@
+eclipse.preferences.version=1
+org.eclipse.jdt.core.codeComplete.argumentPrefixes=
+org.eclipse.jdt.core.codeComplete.argumentSuffixes=
+org.eclipse.jdt.core.codeComplete.fieldPrefixes=f
+org.eclipse.jdt.core.codeComplete.fieldSuffixes=
+org.eclipse.jdt.core.codeComplete.localPrefixes=
+org.eclipse.jdt.core.codeComplete.localSuffixes=
+org.eclipse.jdt.core.codeComplete.staticFieldPrefixes=
+org.eclipse.jdt.core.codeComplete.staticFieldSuffixes=
+org.eclipse.jdt.core.codeComplete.staticFinalFieldPrefixes=
+org.eclipse.jdt.core.codeComplete.staticFinalFieldSuffixes=
+org.eclipse.jdt.core.compiler.annotation.inheritNullAnnotations=enabled
+org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore
+org.eclipse.jdt.core.compiler.annotation.nonnull=org.eclipse.jdt.annotation.NonNull
+org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=org.eclipse.jdt.annotation.NonNullByDefault
+org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nullable
+org.eclipse.jdt.core.compiler.annotation.nullanalysis=enabled
+org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
+org.eclipse.jdt.core.compiler.codegen.methodParameters=do not generate
+org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
+org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
+org.eclipse.jdt.core.compiler.compliance=1.7
+org.eclipse.jdt.core.compiler.debug.lineNumber=generate
+org.eclipse.jdt.core.compiler.debug.localVariable=generate
+org.eclipse.jdt.core.compiler.debug.sourceFile=generate
+org.eclipse.jdt.core.compiler.doc.comment.support=enabled
+org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=error
+org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
+org.eclipse.jdt.core.compiler.problem.autoboxing=ignore
+org.eclipse.jdt.core.compiler.problem.comparingIdentical=error
+org.eclipse.jdt.core.compiler.problem.deadCode=error
+org.eclipse.jdt.core.compiler.problem.deprecation=error
+org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled
+org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=enabled
+org.eclipse.jdt.core.compiler.problem.discouragedReference=warning
+org.eclipse.jdt.core.compiler.problem.emptyStatement=error
+org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
+org.eclipse.jdt.core.compiler.problem.explicitlyClosedAutoCloseable=error
+org.eclipse.jdt.core.compiler.problem.fallthroughCase=error
+org.eclipse.jdt.core.compiler.problem.fatalOptionalError=disabled
+org.eclipse.jdt.core.compiler.problem.fieldHiding=error
+org.eclipse.jdt.core.compiler.problem.finalParameterBound=error
+org.eclipse.jdt.core.compiler.problem.finallyBlockNotCompletingNormally=error
+org.eclipse.jdt.core.compiler.problem.forbiddenReference=error
+org.eclipse.jdt.core.compiler.problem.hiddenCatchBlock=error
+org.eclipse.jdt.core.compiler.problem.includeNullInfoFromAsserts=disabled
+org.eclipse.jdt.core.compiler.problem.incompatibleNonInheritedInterfaceMethod=error
+org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch=error
+org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=error
+org.eclipse.jdt.core.compiler.problem.invalidJavadoc=warning
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTags=enabled
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsDeprecatedRef=enabled
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsNotVisibleRef=enabled
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsVisibility=protected
+org.eclipse.jdt.core.compiler.problem.localVariableHiding=error
+org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=error
+org.eclipse.jdt.core.compiler.problem.missingDefaultCase=error
+org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=error
+org.eclipse.jdt.core.compiler.problem.missingEnumCaseDespiteDefault=enabled
+org.eclipse.jdt.core.compiler.problem.missingHashCodeMethod=error
+org.eclipse.jdt.core.compiler.problem.missingJavadocComments=warning
+org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsOverriding=disabled
+org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsVisibility=protected
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagDescription=all_standard_tags
+org.eclipse.jdt.core.compiler.problem.missingJavadocTags=warning
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagsMethodTypeParameters=disabled
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagsOverriding=disabled
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagsVisibility=protected
+org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotation=error
+org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotationForInterfaceMethodImplementation=enabled
+org.eclipse.jdt.core.compiler.problem.missingSerialVersion=error
+org.eclipse.jdt.core.compiler.problem.missingSynchronizedOnInheritedMethod=error
+org.eclipse.jdt.core.compiler.problem.noEffectAssignment=error
+org.eclipse.jdt.core.compiler.problem.noImplicitStringConversion=error
+org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=warning
+org.eclipse.jdt.core.compiler.problem.nonnullParameterAnnotationDropped=warning
+org.eclipse.jdt.core.compiler.problem.nullAnnotationInferenceConflict=warning
+org.eclipse.jdt.core.compiler.problem.nullReference=error
+org.eclipse.jdt.core.compiler.problem.nullSpecViolation=error
+org.eclipse.jdt.core.compiler.problem.nullUncheckedConversion=warning
+org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=error
+org.eclipse.jdt.core.compiler.problem.parameterAssignment=error
+org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=error
+org.eclipse.jdt.core.compiler.problem.potentialNullReference=error
+org.eclipse.jdt.core.compiler.problem.potentiallyUnclosedCloseable=warning
+org.eclipse.jdt.core.compiler.problem.rawTypeReference=warning
+org.eclipse.jdt.core.compiler.problem.redundantNullAnnotation=warning
+org.eclipse.jdt.core.compiler.problem.redundantNullCheck=error
+org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=error
+org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=error
+org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore
+org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=error
+org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled
+org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=error
+org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=disabled
+org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled
+org.eclipse.jdt.core.compiler.problem.syntacticNullAnalysisForFields=enabled
+org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=ignore
+org.eclipse.jdt.core.compiler.problem.typeParameterHiding=error
+org.eclipse.jdt.core.compiler.problem.unavoidableGenericTypeProblems=disabled
+org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=warning
+org.eclipse.jdt.core.compiler.problem.unclosedCloseable=error
+org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=ignore
+org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=error
+org.eclipse.jdt.core.compiler.problem.unnecessaryElse=error
+org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=error
+org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=warning
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionExemptExceptionAndThrowable=disabled
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionIncludeDocCommentReference=disabled
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverriding=disabled
+org.eclipse.jdt.core.compiler.problem.unusedExceptionParameter=ignore
+org.eclipse.jdt.core.compiler.problem.unusedImport=error
+org.eclipse.jdt.core.compiler.problem.unusedLabel=error
+org.eclipse.jdt.core.compiler.problem.unusedLocal=error
+org.eclipse.jdt.core.compiler.problem.unusedObjectAllocation=ignore
+org.eclipse.jdt.core.compiler.problem.unusedParameter=error
+org.eclipse.jdt.core.compiler.problem.unusedParameterIncludeDocCommentReference=enabled
+org.eclipse.jdt.core.compiler.problem.unusedParameterWhenImplementingAbstract=disabled
+org.eclipse.jdt.core.compiler.problem.unusedParameterWhenOverridingConcrete=disabled
+org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=error
+org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=error
+org.eclipse.jdt.core.compiler.problem.unusedWarningToken=error
+org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=error
+org.eclipse.jdt.core.compiler.source=1.7
+org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=16
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_call=16
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation=16
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression=16
+org.eclipse.jdt.core.formatter.alignment_for_assignment=0
+org.eclipse.jdt.core.formatter.alignment_for_binary_expression=16
+org.eclipse.jdt.core.formatter.alignment_for_compact_if=16
+org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=80
+org.eclipse.jdt.core.formatter.alignment_for_enum_constants=0
+org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=16
+org.eclipse.jdt.core.formatter.alignment_for_method_declaration=0
+org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16
+org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=80
+org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation=0
+org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_constructor_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_method_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_union_type_in_multicatch=16
+org.eclipse.jdt.core.formatter.blank_lines_after_imports=1
+org.eclipse.jdt.core.formatter.blank_lines_after_package=1
+org.eclipse.jdt.core.formatter.blank_lines_before_field=0
+org.eclipse.jdt.core.formatter.blank_lines_before_first_class_body_declaration=0
+org.eclipse.jdt.core.formatter.blank_lines_before_imports=1
+org.eclipse.jdt.core.formatter.blank_lines_before_member_type=1
+org.eclipse.jdt.core.formatter.blank_lines_before_method=1
+org.eclipse.jdt.core.formatter.blank_lines_before_new_chunk=1
+org.eclipse.jdt.core.formatter.blank_lines_before_package=0
+org.eclipse.jdt.core.formatter.blank_lines_between_import_groups=1
+org.eclipse.jdt.core.formatter.blank_lines_between_type_declarations=1
+org.eclipse.jdt.core.formatter.brace_position_for_annotation_type_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_array_initializer=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_block=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_block_in_case=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_constructor_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_enum_constant=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_enum_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_method_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_switch=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_type_declaration=end_of_line
+org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_block_comment=false
+org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_javadoc_comment=false
+org.eclipse.jdt.core.formatter.comment.format_block_comments=true
+org.eclipse.jdt.core.formatter.comment.format_header=false
+org.eclipse.jdt.core.formatter.comment.format_html=true
+org.eclipse.jdt.core.formatter.comment.format_javadoc_comments=true
+org.eclipse.jdt.core.formatter.comment.format_line_comments=true
+org.eclipse.jdt.core.formatter.comment.format_source_code=true
+org.eclipse.jdt.core.formatter.comment.indent_parameter_description=true
+org.eclipse.jdt.core.formatter.comment.indent_root_tags=true
+org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags=insert
+org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter=insert
+org.eclipse.jdt.core.formatter.comment.line_length=80
+org.eclipse.jdt.core.formatter.comment.new_lines_at_block_boundaries=true
+org.eclipse.jdt.core.formatter.comment.new_lines_at_javadoc_boundaries=true
+org.eclipse.jdt.core.formatter.comment.preserve_white_space_between_code_and_line_comments=false
+org.eclipse.jdt.core.formatter.compact_else_if=true
+org.eclipse.jdt.core.formatter.continuation_indentation=2
+org.eclipse.jdt.core.formatter.continuation_indentation_for_array_initializer=2
+org.eclipse.jdt.core.formatter.disabling_tag=@formatter\:off
+org.eclipse.jdt.core.formatter.enabling_tag=@formatter\:on
+org.eclipse.jdt.core.formatter.format_guardian_clause_on_one_line=false
+org.eclipse.jdt.core.formatter.format_line_comment_starting_on_first_column=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_annotation_declaration_header=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_constant_header=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_declaration_header=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_type_header=true
+org.eclipse.jdt.core.formatter.indent_breaks_compare_to_cases=true
+org.eclipse.jdt.core.formatter.indent_empty_lines=false
+org.eclipse.jdt.core.formatter.indent_statements_compare_to_block=true
+org.eclipse.jdt.core.formatter.indent_statements_compare_to_body=true
+org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_cases=true
+org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_switch=false
+org.eclipse.jdt.core.formatter.indentation.size=4
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_field=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_local_variable=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_method=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_package=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_parameter=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_type=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_label=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_opening_brace_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_at_end_of_file_if_missing=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_finally_in_try_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_while_in_do_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_annotation_declaration=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_anonymous_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_block=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter=insert
+org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_binary_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_paren_in_cast=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_assert=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_case=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_labeled_statement=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_allocation_expression=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_annotation=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_throws=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_constant_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_declarations=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_explicitconstructorcall_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_increments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_inits=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_throws=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_invocation_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_field_declarations=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_local_declarations=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_parameterized_type_reference=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_superinterfaces=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_ellipsis=insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_brace_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_cast=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_catch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_for=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_if=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_parenthesized_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_switch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_synchronized=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_try=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_while=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_try_resources=insert
+org.eclipse.jdt.core.formatter.insert_space_after_unary_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter=insert
+org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_binary_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_brace_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_cast=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_catch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_for=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_if=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_parenthesized_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_switch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_synchronized=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_try=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_while=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_assert=insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_case=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_default=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_labeled_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_throws=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_constant_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_declarations=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_explicitconstructorcall_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_increments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_inits=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_throws=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_invocation_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_field_declarations=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_local_declarations=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_superinterfaces=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_ellipsis=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_annotation_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_anonymous_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_block=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_constructor_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_constant=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_method_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_switch=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation_type_member_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_catch=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_if=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_parenthesized_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_switch=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_synchronized=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_try=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_while=insert
+org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_return=insert
+org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_throw=insert
+org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_semicolon=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_try_resources=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_unary_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_brackets_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_annotation_type_member_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.join_lines_in_comments=true
+org.eclipse.jdt.core.formatter.join_wrapped_lines=false
+org.eclipse.jdt.core.formatter.keep_else_statement_on_same_line=false
+org.eclipse.jdt.core.formatter.keep_empty_array_initializer_on_one_line=false
+org.eclipse.jdt.core.formatter.keep_imple_if_on_one_line=false
+org.eclipse.jdt.core.formatter.keep_then_statement_on_same_line=false
+org.eclipse.jdt.core.formatter.lineSplit=250
+org.eclipse.jdt.core.formatter.never_indent_block_comments_on_first_column=false
+org.eclipse.jdt.core.formatter.never_indent_line_comments_on_first_column=false
+org.eclipse.jdt.core.formatter.number_of_blank_lines_at_beginning_of_method_body=0
+org.eclipse.jdt.core.formatter.number_of_empty_lines_to_preserve=1
+org.eclipse.jdt.core.formatter.put_empty_statement_on_new_line=true
+org.eclipse.jdt.core.formatter.tabulation.char=space
+org.eclipse.jdt.core.formatter.tabulation.size=4
+org.eclipse.jdt.core.formatter.use_on_off_tags=false
+org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false
+org.eclipse.jdt.core.formatter.wrap_before_binary_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_or_operator_multicatch=true
+org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/.settings/org.eclipse.jdt.ui.prefs b/lttng/org.eclipse.tracecompass.lttng2.control.ui/.settings/org.eclipse.jdt.ui.prefs
new file mode 100644 (file)
index 0000000..232a3fd
--- /dev/null
@@ -0,0 +1,60 @@
+eclipse.preferences.version=1
+editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true
+formatter_profile=_tmf-style
+formatter_settings_version=12
+org.eclipse.jdt.ui.exception.name=e
+org.eclipse.jdt.ui.gettersetter.use.is=true
+org.eclipse.jdt.ui.keywordthis=false
+org.eclipse.jdt.ui.overrideannotation=true
+sp_cleanup.add_default_serial_version_id=true
+sp_cleanup.add_generated_serial_version_id=false
+sp_cleanup.add_missing_annotations=false
+sp_cleanup.add_missing_deprecated_annotations=true
+sp_cleanup.add_missing_methods=false
+sp_cleanup.add_missing_nls_tags=false
+sp_cleanup.add_missing_override_annotations=true
+sp_cleanup.add_missing_override_annotations_interface_methods=true
+sp_cleanup.add_serial_version_id=false
+sp_cleanup.always_use_blocks=true
+sp_cleanup.always_use_parentheses_in_expressions=false
+sp_cleanup.always_use_this_for_non_static_field_access=false
+sp_cleanup.always_use_this_for_non_static_method_access=false
+sp_cleanup.convert_to_enhanced_for_loop=false
+sp_cleanup.correct_indentation=false
+sp_cleanup.format_source_code=false
+sp_cleanup.format_source_code_changes_only=false
+sp_cleanup.make_local_variable_final=false
+sp_cleanup.make_parameters_final=false
+sp_cleanup.make_private_fields_final=true
+sp_cleanup.make_type_abstract_if_missing_method=false
+sp_cleanup.make_variable_declarations_final=false
+sp_cleanup.never_use_blocks=false
+sp_cleanup.never_use_parentheses_in_expressions=true
+sp_cleanup.on_save_use_additional_actions=true
+sp_cleanup.organize_imports=false
+sp_cleanup.qualify_static_field_accesses_with_declaring_class=false
+sp_cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=true
+sp_cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=true
+sp_cleanup.qualify_static_member_accesses_with_declaring_class=false
+sp_cleanup.qualify_static_method_accesses_with_declaring_class=false
+sp_cleanup.remove_private_constructors=true
+sp_cleanup.remove_trailing_whitespaces=true
+sp_cleanup.remove_trailing_whitespaces_all=true
+sp_cleanup.remove_trailing_whitespaces_ignore_empty=false
+sp_cleanup.remove_unnecessary_casts=false
+sp_cleanup.remove_unnecessary_nls_tags=false
+sp_cleanup.remove_unused_imports=false
+sp_cleanup.remove_unused_local_variables=false
+sp_cleanup.remove_unused_private_fields=true
+sp_cleanup.remove_unused_private_members=false
+sp_cleanup.remove_unused_private_methods=true
+sp_cleanup.remove_unused_private_types=true
+sp_cleanup.sort_members=false
+sp_cleanup.sort_members_all=false
+sp_cleanup.use_blocks=true
+sp_cleanup.use_blocks_only_for_return_and_throw=false
+sp_cleanup.use_parentheses_in_expressions=false
+sp_cleanup.use_this_for_non_static_field_access=false
+sp_cleanup.use_this_for_non_static_field_access_only_if_necessary=true
+sp_cleanup.use_this_for_non_static_method_access=false
+sp_cleanup.use_this_for_non_static_method_access_only_if_necessary=true
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/.settings/org.eclipse.pde.api.tools.prefs b/lttng/org.eclipse.tracecompass.lttng2.control.ui/.settings/org.eclipse.pde.api.tools.prefs
new file mode 100644 (file)
index 0000000..acc3abd
--- /dev/null
@@ -0,0 +1,97 @@
+ANNOTATION_ELEMENT_TYPE_ADDED_METHOD_WITHOUT_DEFAULT_VALUE=Error
+ANNOTATION_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+ANNOTATION_ELEMENT_TYPE_REMOVED_FIELD=Error
+ANNOTATION_ELEMENT_TYPE_REMOVED_METHOD=Error
+ANNOTATION_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_API_TYPE=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_API_TYPE=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_TYPE=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_TYPE=Error
+API_USE_SCAN_FIELD_SEVERITY=Error
+API_USE_SCAN_METHOD_SEVERITY=Error
+API_USE_SCAN_TYPE_SEVERITY=Error
+CLASS_ELEMENT_TYPE_ADDED_METHOD=Error
+CLASS_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
+CLASS_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+CLASS_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
+CLASS_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+CLASS_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
+CLASS_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
+CLASS_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+CLASS_ELEMENT_TYPE_REMOVED_CONSTRUCTOR=Error
+CLASS_ELEMENT_TYPE_REMOVED_FIELD=Error
+CLASS_ELEMENT_TYPE_REMOVED_METHOD=Error
+CLASS_ELEMENT_TYPE_REMOVED_SUPERCLASS=Error
+CLASS_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+CLASS_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+CONSTRUCTOR_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+CONSTRUCTOR_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+CONSTRUCTOR_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
+CONSTRUCTOR_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+ENUM_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
+ENUM_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+ENUM_ELEMENT_TYPE_REMOVED_ENUM_CONSTANT=Error
+ENUM_ELEMENT_TYPE_REMOVED_FIELD=Error
+ENUM_ELEMENT_TYPE_REMOVED_METHOD=Error
+ENUM_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+FIELD_ELEMENT_TYPE_ADDED_VALUE=Error
+FIELD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+FIELD_ELEMENT_TYPE_CHANGED_FINAL_TO_NON_FINAL_STATIC_CONSTANT=Error
+FIELD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
+FIELD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
+FIELD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
+FIELD_ELEMENT_TYPE_CHANGED_TYPE=Error
+FIELD_ELEMENT_TYPE_CHANGED_VALUE=Error
+FIELD_ELEMENT_TYPE_REMOVED_TYPE_ARGUMENT=Error
+FIELD_ELEMENT_TYPE_REMOVED_VALUE=Error
+ILLEGAL_EXTEND=Warning
+ILLEGAL_IMPLEMENT=Warning
+ILLEGAL_INSTANTIATE=Warning
+ILLEGAL_OVERRIDE=Warning
+ILLEGAL_REFERENCE=Warning
+INTERFACE_ELEMENT_TYPE_ADDED_FIELD=Error
+INTERFACE_ELEMENT_TYPE_ADDED_METHOD=Error
+INTERFACE_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
+INTERFACE_ELEMENT_TYPE_ADDED_SUPER_INTERFACE_WITH_METHODS=Error
+INTERFACE_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+INTERFACE_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
+INTERFACE_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_FIELD=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_METHOD=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+INVALID_JAVADOC_TAG=Warning
+INVALID_REFERENCE_IN_SYSTEM_LIBRARIES=Warning
+LEAK_EXTEND=Warning
+LEAK_FIELD_DECL=Warning
+LEAK_IMPLEMENT=Warning
+LEAK_METHOD_PARAM=Warning
+LEAK_METHOD_RETURN_TYPE=Warning
+METHOD_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
+METHOD_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+METHOD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+METHOD_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
+METHOD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
+METHOD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
+METHOD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
+METHOD_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
+METHOD_ELEMENT_TYPE_REMOVED_ANNOTATION_DEFAULT_VALUE=Error
+METHOD_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+MISSING_EE_DESCRIPTIONS=Ignore
+TYPE_PARAMETER_ELEMENT_TYPE_ADDED_CLASS_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_ADDED_INTERFACE_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_CLASS_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_INTERFACE_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_CLASS_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_INTERFACE_BOUND=Error
+UNUSED_PROBLEM_FILTERS=Warning
+automatically_removed_unused_problem_filters=false
+eclipse.preferences.version=1
+incompatible_api_component_version=Error
+incompatible_api_component_version_include_major_without_breaking_change=Disabled
+incompatible_api_component_version_include_minor_without_api_change=Disabled
+invalid_since_tag_version=Error
+malformed_since_tag=Error
+missing_since_tag=Error
+report_api_breakage_when_major_version_incremented=Disabled
+report_resolution_errors_api_component=Warning
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/.settings/org.eclipse.pde.prefs b/lttng/org.eclipse.tracecompass.lttng2.control.ui/.settings/org.eclipse.pde.prefs
new file mode 100644 (file)
index 0000000..d92b94f
--- /dev/null
@@ -0,0 +1,32 @@
+compilers.f.unresolved-features=1
+compilers.f.unresolved-plugins=1
+compilers.incompatible-environment=1
+compilers.p.build=1
+compilers.p.build.bin.includes=1
+compilers.p.build.encodings=2
+compilers.p.build.java.compiler=2
+compilers.p.build.java.compliance=1
+compilers.p.build.missing.output=2
+compilers.p.build.output.library=1
+compilers.p.build.source.library=1
+compilers.p.build.src.includes=1
+compilers.p.deprecated=1
+compilers.p.discouraged-class=1
+compilers.p.internal=1
+compilers.p.missing-packages=1
+compilers.p.missing-version-export-package=2
+compilers.p.missing-version-import-package=2
+compilers.p.missing-version-require-bundle=2
+compilers.p.no-required-att=0
+compilers.p.not-externalized-att=1
+compilers.p.unknown-attribute=1
+compilers.p.unknown-class=1
+compilers.p.unknown-element=1
+compilers.p.unknown-identifier=1
+compilers.p.unknown-resource=1
+compilers.p.unresolved-ex-points=0
+compilers.p.unresolved-import=0
+compilers.s.create-docs=false
+compilers.s.doc-folder=doc
+compilers.s.open-tags=1
+eclipse.preferences.version=1
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/META-INF/MANIFEST.MF b/lttng/org.eclipse.tracecompass.lttng2.control.ui/META-INF/MANIFEST.MF
new file mode 100644 (file)
index 0000000..cbbf7aa
--- /dev/null
@@ -0,0 +1,37 @@
+Manifest-Version: 1.0
+Bundle-ManifestVersion: 2
+Bundle-Name: %Bundle-Name
+Bundle-Vendor: %Bundle-Vendor
+Bundle-Version: 1.0.0.qualifier
+Bundle-Localization: plugin
+Bundle-SymbolicName: org.eclipse.tracecompass.lttng2.control.ui;singleton:=true
+Bundle-Activator: org.eclipse.tracecompass.internal.lttng2.control.ui.Activator
+Bundle-ActivationPolicy: lazy
+Bundle-RequiredExecutionEnvironment: JavaSE-1.7
+Require-Bundle: org.eclipse.ui,
+ org.eclipse.ui.ide,
+ org.eclipse.core.expressions,
+ org.eclipse.core.resources,
+ org.eclipse.core.runtime,
+ org.eclipse.tracecompass.common.core,
+ org.eclipse.tracecompass.lttng2.control.core,
+ org.eclipse.tracecompass.tmf.core,
+ org.eclipse.tracecompass.tmf.ui,
+ org.eclipse.tracecompass.tmf.ctf.core,
+ org.eclipse.remote.core;bundle-version="2.0.0",
+ org.eclipse.remote.ui;bundle-version="2.0.0",
+ org.eclipse.tracecompass.tmf.remote.core,
+ org.eclipse.core.filesystem
+Export-Package: org.eclipse.tracecompass.internal.lttng2.control.ui;x-friends:="org.eclipse.tracecompass.lttng2.control.ui.tests",
+ org.eclipse.tracecompass.internal.lttng2.control.ui.relayd;x-internal:=true,
+ org.eclipse.tracecompass.internal.lttng2.control.ui.views;x-friends:="org.eclipse.tracecompass.lttng2.kernel.ui,org.eclipse.tracecompass.lttng2.control.ui.tests,org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests",
+ org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;x-friends:="org.eclipse.tracecompass.lttng2.control.ui.tests",
+ org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;x-internal:=true,
+ org.eclipse.tracecompass.internal.lttng2.control.ui.views.logging;x-friends:="org.eclipse.tracecompass.lttng2.control.ui.tests",
+ org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages;x-internal:=true,
+ org.eclipse.tracecompass.internal.lttng2.control.ui.views.model;x-friends:="org.eclipse.tracecompass.lttng2.control.ui.tests",
+ org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl;x-friends:="org.eclipse.tracecompass.lttng2.control.ui.tests",
+ org.eclipse.tracecompass.internal.lttng2.control.ui.views.preferences;x-friends:="org.eclipse.tracecompass.lttng2.control.ui.tests",
+ org.eclipse.tracecompass.internal.lttng2.control.ui.views.property;x-friends:="org.eclipse.tracecompass.lttng2.control.ui.tests",
+ org.eclipse.tracecompass.internal.lttng2.control.ui.views.service;x-friends:="org.eclipse.tracecompass.lttng2.control.ui.tests"
+Import-Package: com.google.common.collect
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/about.html b/lttng/org.eclipse.tracecompass.lttng2.control.ui/about.html
new file mode 100644 (file)
index 0000000..c258ef5
--- /dev/null
@@ -0,0 +1,28 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"/>
+<title>About</title>
+</head>
+<body lang="EN-US">
+<h2>About This Content</h2>
+<p>June 5, 2006</p>    
+<h3>License</h3>
+
+<p>The Eclipse Foundation makes available all content in this plug-in (&quot;Content&quot;).  Unless otherwise 
+indicated below, the Content is provided to you under the terms and conditions of the
+Eclipse Public License Version 1.0 (&quot;EPL&quot;).  A copy of the EPL is available 
+at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>.
+For purposes of the EPL, &quot;Program&quot; will mean the Content.</p>
+
+<p>If you did not receive this Content directly from the Eclipse Foundation, the Content is 
+being redistributed by another party (&quot;Redistributor&quot;) and different terms and conditions may
+apply to your use of any object code in the Content.  Check the Redistributor's license that was 
+provided with the Content.  If no such license exists, contact the Redistributor.  Unless otherwise
+indicated below, the terms and conditions of the EPL still apply to any source code in the Content
+and such source code may be obtained at <a href="http://www.eclipse.org/">http://www.eclipse.org</a>.</p>
+
+</body>
+</html>
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/build.properties b/lttng/org.eclipse.tracecompass.lttng2.control.ui/build.properties
new file mode 100644 (file)
index 0000000..13e8d04
--- /dev/null
@@ -0,0 +1,23 @@
+###############################################################################
+# Copyright (c) 2013, 2014 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:
+#     Ericsson - Initial API and implementation
+###############################################################################
+
+source.. = src/
+output.. = bin/
+bin.includes = META-INF/,\
+               .,\
+               plugin.xml,\
+               icons/,\
+               about.html,\
+               plugin.properties
+src.includes = about.html
+additional.bundles = org.eclipse.jdt.annotation
+jars.extra.classpath = platform:/plugin/org.eclipse.jdt.annotation
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/add-context.gif b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/add-context.gif
new file mode 100644 (file)
index 0000000..030eade
Binary files /dev/null and b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/add-context.gif differ
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/add_button.gif b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/add_button.gif
new file mode 100644 (file)
index 0000000..252d7eb
Binary files /dev/null and b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/add_button.gif differ
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/calibrate.gif b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/calibrate.gif
new file mode 100644 (file)
index 0000000..c984fba
Binary files /dev/null and b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/calibrate.gif differ
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/connect.gif b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/connect.gif
new file mode 100644 (file)
index 0000000..866ad33
Binary files /dev/null and b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/connect.gif differ
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/delete_trace.gif b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/delete_trace.gif
new file mode 100644 (file)
index 0000000..b6922ac
Binary files /dev/null and b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/delete_trace.gif differ
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/disable.gif b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/disable.gif
new file mode 100644 (file)
index 0000000..f6b9f8a
Binary files /dev/null and b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/disable.gif differ
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/disable_event.gif b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/disable_event.gif
new file mode 100644 (file)
index 0000000..2966a28
Binary files /dev/null and b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/disable_event.gif differ
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/disconnect.gif b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/disconnect.gif
new file mode 100644 (file)
index 0000000..ec8a8b0
Binary files /dev/null and b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/disconnect.gif differ
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/edit.gif b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/edit.gif
new file mode 100644 (file)
index 0000000..feb8e94
Binary files /dev/null and b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/edit.gif differ
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/enable.gif b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/enable.gif
new file mode 100644 (file)
index 0000000..9cacb96
Binary files /dev/null and b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/enable.gif differ
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/enable_event.gif b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/enable_event.gif
new file mode 100644 (file)
index 0000000..06d0079
Binary files /dev/null and b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/enable_event.gif differ
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/import_trace.gif b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/import_trace.gif
new file mode 100644 (file)
index 0000000..d38085a
Binary files /dev/null and b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/import_trace.gif differ
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/pause_trace.gif b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/pause_trace.gif
new file mode 100644 (file)
index 0000000..161e3f5
Binary files /dev/null and b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/pause_trace.gif differ
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/refresh.gif b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/refresh.gif
new file mode 100644 (file)
index 0000000..3ca04d0
Binary files /dev/null and b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/refresh.gif differ
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/snapshot.gif b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/snapshot.gif
new file mode 100644 (file)
index 0000000..176830a
Binary files /dev/null and b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/snapshot.gif differ
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/start_trace.gif b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/start_trace.gif
new file mode 100644 (file)
index 0000000..d6b3bdc
Binary files /dev/null and b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/start_trace.gif differ
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/stop_trace.gif b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/stop_trace.gif
new file mode 100644 (file)
index 0000000..dc47edf
Binary files /dev/null and b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/stop_trace.gif differ
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/target_add.gif b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/target_add.gif
new file mode 100644 (file)
index 0000000..114b964
Binary files /dev/null and b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/target_add.gif differ
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/target_delete.gif b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/target_delete.gif
new file mode 100644 (file)
index 0000000..b853d62
Binary files /dev/null and b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/target_delete.gif differ
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/eview16/control_view.gif b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/eview16/control_view.gif
new file mode 100644 (file)
index 0000000..0dc862c
Binary files /dev/null and b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/eview16/control_view.gif differ
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/channel.gif b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/channel.gif
new file mode 100644 (file)
index 0000000..e8efe69
Binary files /dev/null and b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/channel.gif differ
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/channel_disabled.gif b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/channel_disabled.gif
new file mode 100644 (file)
index 0000000..413c1b9
Binary files /dev/null and b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/channel_disabled.gif differ
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/domain.gif b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/domain.gif
new file mode 100644 (file)
index 0000000..c4a8af4
Binary files /dev/null and b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/domain.gif differ
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/event_disabled.gif b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/event_disabled.gif
new file mode 100644 (file)
index 0000000..2966a28
Binary files /dev/null and b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/event_disabled.gif differ
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/event_enabled.gif b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/event_enabled.gif
new file mode 100644 (file)
index 0000000..11d3d8d
Binary files /dev/null and b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/event_enabled.gif differ
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/garland16.png b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/garland16.png
new file mode 100644 (file)
index 0000000..74f9751
Binary files /dev/null and b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/garland16.png differ
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/providers.gif b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/providers.gif
new file mode 100644 (file)
index 0000000..885b8a6
Binary files /dev/null and b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/providers.gif differ
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/session_active.gif b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/session_active.gif
new file mode 100644 (file)
index 0000000..57a42bc
Binary files /dev/null and b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/session_active.gif differ
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/session_destroyed.gif b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/session_destroyed.gif
new file mode 100644 (file)
index 0000000..b0adbc3
Binary files /dev/null and b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/session_destroyed.gif differ
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/session_inactive.gif b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/session_inactive.gif
new file mode 100644 (file)
index 0000000..b6774cb
Binary files /dev/null and b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/session_inactive.gif differ
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/sessions.gif b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/sessions.gif
new file mode 100644 (file)
index 0000000..c695884
Binary files /dev/null and b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/sessions.gif differ
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/systemlttng2-live.gif b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/systemlttng2-live.gif
new file mode 100755 (executable)
index 0000000..57c522d
Binary files /dev/null and b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/systemlttng2-live.gif differ
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/systemlttng2.gif b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/systemlttng2.gif
new file mode 100755 (executable)
index 0000000..fd7b311
Binary files /dev/null and b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/systemlttng2.gif differ
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/target_connected.gif b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/target_connected.gif
new file mode 100644 (file)
index 0000000..def312a
Binary files /dev/null and b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/target_connected.gif differ
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/target_disconnected.gif b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/target_disconnected.gif
new file mode 100644 (file)
index 0000000..2104ab4
Binary files /dev/null and b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/target_disconnected.gif differ
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/targets.gif b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/targets.gif
new file mode 100644 (file)
index 0000000..c1e4ee3
Binary files /dev/null and b/lttng/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/targets.gif differ
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/plugin.properties b/lttng/org.eclipse.tracecompass.lttng2.control.ui/plugin.properties
new file mode 100644 (file)
index 0000000..44c24c6
--- /dev/null
@@ -0,0 +1,142 @@
+###############################################################################
+# Copyright (c) 2013, 2015 Ericsson and others.
+#
+# 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:
+#     Ericsson - Initial API and implementation
+###############################################################################
+
+Bundle-Vendor = Eclipse Trace Compass
+Bundle-Name = Trace Compass LTTng Control UI Plug-in
+
+views.category.name = LTTng
+control.view.name = Control
+events.view.name = Events
+timeframe.view.name = Time Frame
+controlflow.view.name = Control Flow
+resources.view.name = Resources
+statistics.view.name = Statistics
+histogram.view.name = Histogram
+latency.view.name = Latency View
+
+project.new.category.name = LTTng
+project.new.wizard.name = LTTng Project
+project.new.wizard.description = Create a new LTTng project
+
+project.propertyPage.tracelibPath = LTTng Trace Library Path
+action.set.label = LTTng Action Set
+action.set.description = LTTng Action Set
+
+tracetype.category.lttng= LTTng
+tracetype.type.kernel = Kernel Trace
+
+#Commands and Menus
+commands.trace.category.name = LTTng Trace Commands
+commands.trace.category.description = LTTng Trace Commands
+commands.trace.import = Import Trace
+commands.trace.import.description = Import an LTTng Trace
+commands.trace.open = Open Trace
+commands.trace.open.description = Open an LTTng Trace
+commands.trace.rename = Rename Trace
+commands.trace.rename.description = Rename an LTTng Trace
+commands.trace.delete = Delete Trace
+commands.trace.delete.description = Delete an LTTng Trace
+commands.trace.selectparser = Select Parser
+
+commands.experiment.category.name = LTTng Experiment Commands
+commands.experiment.category.description = LTTng Experiment Commands
+commands.experiment.new = New Experiment
+commands.experiment.new.description = Create a new LTTng Experiment
+commands.experiment.selecttraces = Select Traces
+commands.experiment.selecttraces.description = Select LTTng Traces
+commands.experiment.open = Open Experiment
+commands.experiment.open.description = Open an LTTng Experiment
+commands.experiment.rename = Rename Experiment
+commands.experiment.rename.description = Rename an LTTng Experiment
+commands.experiment.delete = Delete Experiment
+commands.experiment.delete.description = Delete an LTTng Experiment
+
+# LTTng 2.0 trace control commands
+commands.control.category=LTTng Trace Control Commands
+commands.control.category.description=LTTng Trace Control Commands
+
+commands.control.new=New Connection...
+commands.control.new.description=New Connection to Target Node
+
+commands.control.connect=Connect
+commands.control.connect.description=Connect to Target Node
+
+commands.control.disconnect=Disconnect
+commands.control.disconnect.description=Disconnect to Target Node
+
+commands.control.refresh=Refresh
+commands.control.refresh.description=Refresh Node Configuration
+
+commands.control.delete=Delete
+commands.control.delete.description=Delete Target Node
+
+commands.control.create.session=Create Session...
+commands.control.create.session.description=Create a Trace Session
+
+commands.control.execute.command.script=Execute Command Script...
+commands.control.execute.command.script.description=Execute Command Script
+
+commands.control.destroy.session=Destroy Session...
+commands.control.destroy.session.description=Destroy a Trace Session
+
+commands.control.enable.channelOnSession=Enable Channel...
+commands.control.enable.channelOnSession.description=Enable a Trace Channel
+
+commands.control.enable.channelOnDomain=Enable Channel...
+commands.control.enable.channelOnDomain.description=Enable a Trace Channel
+
+commands.control.enable.channel=Enable Channel
+commands.control.enable.channel.description=Enable a Trace Channel
+
+commands.control.disable.channel=Disable Channel
+commands.control.disable.channel.description=Disable a Trace Channel
+
+commands.control.start=Start
+commands.control.start.description=Start Trace Session
+
+commands.control.stop=Stop
+commands.control.stop.description=Stop Trace Session
+
+commands.control.assign.event=Enable Event...
+commands.control.assign.event.description=Assign Event to Session and Channel and Enable Event 
+
+commands.control.enable.event=Enable Event
+commands.control.enable.event.description=Enable Event
+
+commands.control.enable.eventOnChannel=Enable Event...
+commands.control.enable.eventOnChannel.description=Enable Event
+
+commands.control.enable.eventOnDomain=Enable Event (default channel)...
+commands.control.enable.eventOnDomain.description=Enable Event on Default Channel
+
+commands.control.enable.eventOnSession=Enable Event (default channel)...
+commands.control.enable.eventOnSession.description=Enable Event on Default Channel
+
+commands.control.disable.event=Disable Event
+commands.control.disable.event.description=Disable Event
+
+commands.control.add.context=Add Context...
+commands.control.add.context.description=Add Context to Channel(s) and/or Event(s)
+
+commands.control.import=Import...
+commands.control.import.description=Import Traces to LTTng Project
+
+commands.control.calibrate=Calibrate
+commands.control.calibrate.description=Quantify LTTng overhead
+
+commands.control.snapshot=Record Snapshot
+commands.control.snapshot.description=Record a snapshot
+
+preference.page.control.name=LTTng Tracer Control Preferences
+
+commandParameter.remoteServicesId.name = Remote Services ID
+commandParameter.connectionName.name = Connection Name
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/plugin.xml b/lttng/org.eclipse.tracecompass.lttng2.control.ui/plugin.xml
new file mode 100644 (file)
index 0000000..2da1f5e
--- /dev/null
@@ -0,0 +1,1273 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<?eclipse version="3.4"?>
+<plugin>
+   <extension
+         id="org.eclipse.linuxtools.lttng2.ui.views"
+         point="org.eclipse.ui.views">
+      <category
+            id="org.eclipse.linuxtools.lttng2.ui.views.category"
+            name="%views.category.name">
+      </category>
+      <view
+            allowMultiple="false"
+            category="org.eclipse.linuxtools.lttng2.ui.views.category"
+            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView"
+            icon="icons/eview16/control_view.gif"
+            id="org.eclipse.linuxtools.internal.lttng2.ui.views.control"
+            name="%control.view.name"
+            restorable="true">
+      </view>
+   </extension>
+   
+      <extension
+         point="org.eclipse.ui.commands">
+      <category
+            description="%commands.control.category.description"
+            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
+            name="%commands.control.category">
+      </category>
+      <command
+            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
+            description="%commands.control.new.description"
+            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.newConnection"
+            name="%commands.control.new">
+         <commandParameter
+               id="org.eclipse.linuxtools.lttng2.control.ui.remoteServicesIdParameter"
+               name="%commandParameter.remoteServicesId.name"
+               optional="true">
+         </commandParameter>
+         <commandParameter
+               id="org.eclipse.linuxtools.lttng2.control.ui.connectionNameParameter"
+               name="%commandParameter.connectionName.name"
+               optional="true">
+         </commandParameter>
+      </command>
+      <command
+            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
+            description="%commands.control.connect.description"
+            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.connect"
+            name="%commands.control.connect">
+      </command>
+      <command
+            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
+            description="%commands.control.disconnect.description"
+            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.disconnect"
+            name="%commands.control.disconnect">
+      </command>
+      <command
+            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
+            description="%commands.control.refresh.description"
+            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.refresh"
+            name="%commands.control.refresh">
+      </command>
+      <command
+            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
+            description="%commands.control.delete.description"
+            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.delete"
+            name="%commands.control.delete">
+      </command>
+      <command
+            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
+            description="%commands.control.create.session.description"
+            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.createSession"
+            name="%commands.control.create.session">
+      </command>
+      <command
+            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
+            description="%commands.control.execute.command.script.description"
+            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.executeScript"
+            name="%commands.control.execute.command.script">
+      </command>
+      <command
+            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
+            description="%commands.control.destroy.session.description"
+            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.destroySession"
+            name="%commands.control.destroy.session">
+      </command>
+      <command
+            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
+            description="%commands.control.import.description"
+            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.import"
+            name="%commands.control.import">
+      </command>
+      <command
+            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
+            description="%commands.control.enable.channelOnSession.description"
+            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.enableChannelOnSession"
+            name="%commands.control.enable.channelOnSession">
+      </command>
+      <command
+            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
+            description="%commands.control.enable.channelOnDomain.description"
+            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.enableChannelOnDomain"
+            name="%commands.control.enable.channelOnDomain">
+      </command>
+      <command
+            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
+            description="%commands.control.enable.channel.description"
+            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.enableChannel"
+            name="%commands.control.enable.channel">
+      </command>
+      <command
+            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
+            description="%commands.control.disable.channel.description"
+            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.disableChannel"
+            name="%commands.control.disable.channel">
+      </command>
+      <command
+            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
+            description="%commands.control.start.description"
+            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.start"
+            name="%commands.control.start">
+      </command>
+      <command
+            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
+            description="%commands.control.stop.description"
+            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.stop"
+            name="%commands.control.stop">
+      </command>
+      <command
+            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
+            description="%commands.control.assign.event.description"
+            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.assign.event"
+            name="%commands.control.assign.event">
+      </command>
+      <command
+            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
+            description="%commands.control.enable.event.description"
+            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.enableEvent"
+            name="%commands.control.enable.event">
+      </command>
+      <command
+            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
+            description="%commands.control.disable.event.description"
+            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.disableEvent"
+            name="%commands.control.disable.event">
+      </command>
+      <command
+            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
+            description="%commands.control.enable.eventOnChannel.description"
+            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.enableEventOnChannel"
+            name="%commands.control.enable.eventOnChannel">
+      </command>
+      <command
+            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
+            description="%commands.control.enable.eventOnDomain.description"
+            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.enableEventOnDomain"
+            name="%commands.control.enable.eventOnDomain">
+      </command>
+      <command
+            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
+            description="%commands.control.enable.eventOnSession.description"
+            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.enableEventOnSession"
+            name="%commands.control.enable.eventOnSession">
+      </command>
+
+      <command
+            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
+            description="%commands.control.add.context.description"
+            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.addContextOnDomain"
+            name="%commands.control.add.context">
+      </command>
+
+      <command
+            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
+            description="%commands.control.add.context.description"
+            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.addContextOnChannel"
+            name="%commands.control.add.context">
+      </command>
+
+      <command
+            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
+            description="%commands.control.add.context.description"
+            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.addContextOnEvent"
+            name="%commands.control.add.context">
+      </command>
+
+      <command
+            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
+            description="%commands.control.import.description"
+            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.import"
+            name="%commands.control.import">
+      </command>
+
+      <command
+            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
+            description="%commands.control.calibrate.description"
+            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.calibrate"
+            name="%commands.control.calibrate">
+      </command>
+
+      <command
+            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
+            description="%commands.control.snapshot.description"
+            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.snapshot"
+            name="%commands.control.snapshot">
+      </command>
+
+   </extension>
+   <extension
+         point="org.eclipse.ui.menus">
+      <menuContribution
+            allPopups="false"
+            locationURI="toolbar:org.eclipse.linuxtools.internal.lttng2.ui.views.control">
+         <command
+               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.newConnection"
+               icon="icons/elcl16/target_add.gif"
+               label="%commands.control.new"
+               style="push">
+         </command>
+         <command
+               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.connect"
+               icon="icons/elcl16/connect.gif"
+               label="%commands.control.connect"
+               style="push">
+         </command>
+         <command
+               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.disconnect"
+               icon="icons/elcl16/disconnect.gif"
+               label="%commands.control.disconnect"
+               style="push">
+         </command>
+         <command
+               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.refresh"
+               icon="icons/elcl16/refresh.gif"
+               label="%commands.control.refresh"
+               style="push">
+         </command>
+         <command
+               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.delete"
+               icon="icons/elcl16/target_delete.gif"
+               label="%commands.control.delete"
+               style="push">
+         </command>
+         <separator
+               name="org.eclipse.linuxtools.internal.lttng2.ui.views.control.toolbar.separator1"
+               visible="true">
+         </separator>
+         <command
+               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.start"
+               icon="icons/elcl16/start_trace.gif"
+               label="%commands.control.start"
+               style="push">
+         </command>
+         <command
+               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.stop"
+               icon="icons/elcl16/pause_trace.gif"
+               label="%commands.control.stop"
+               style="push">
+         </command>
+         <command
+               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.destroySession"
+               icon="icons/elcl16/delete_trace.gif"
+               label="%commands.control.destroy.session"
+               style="push">
+         </command>
+         <separator
+               name="org.eclipse.linuxtools.internal.lttng2.ui.views.control.toolbar.separator2"
+               visible="true">
+         </separator>
+         <command
+               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.snapshot"
+               icon="icons/elcl16/snapshot.gif"
+               label="%commands.control.snapshot"
+               style="push">
+         </command>
+         <separator
+               name="org.eclipse.linuxtools.internal.lttng2.ui.views.control.toolbar.separator3"
+               visible="true">
+         </separator>
+         <command
+               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.import"
+               icon="icons/elcl16/import_trace.gif"
+               label="%commands.control.import"
+               style="push">
+         </command>
+         
+      </menuContribution>
+      <menuContribution
+            allPopups="false"
+            locationURI="popup:org.eclipse.linuxtools.internal.lttng2.ui.views.control">
+         <command
+               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.connect"
+               icon="icons/elcl16/connect.gif"
+               label="%commands.control.connect"
+               style="push">
+            <visibleWhen
+                  checkEnabled="false">
+               <with
+                     variable="activeMenuSelection">
+                  <iterate
+                        operator="or">
+                     <instanceof
+                           value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent">
+                     </instanceof>
+                  </iterate>
+               </with>
+            </visibleWhen>
+         </command>
+         <command
+               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.disconnect"
+               icon="icons/elcl16/disconnect.gif"
+               label="%commands.control.disconnect"
+               style="push">
+            <visibleWhen
+                  checkEnabled="false">
+               <with
+                     variable="activeMenuSelection">
+                  <iterate
+                        operator="or">
+                     <instanceof
+                           value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent">
+                     </instanceof>
+                  </iterate>
+               </with>
+            </visibleWhen>
+         </command>
+         <command
+               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.refresh"
+               icon="icons/elcl16/refresh.gif"
+               label="%commands.control.refresh"
+               style="push">
+            <visibleWhen
+                  checkEnabled="false">
+               <with
+                     variable="activeMenuSelection">
+                  <iterate
+                        operator="or">
+                     <instanceof
+                           value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceControlComponent">
+                     </instanceof>
+                  </iterate>
+               </with>
+            </visibleWhen>
+         </command>
+         <command
+               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.delete"
+               icon="icons/elcl16/target_delete.gif"
+               label="%commands.control.delete"
+               style="push">
+            <visibleWhen
+                  checkEnabled="false">
+               <with
+                     variable="activeMenuSelection">
+                  <iterate
+                        operator="or">
+                     <instanceof
+                           value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent">
+                     </instanceof>
+                  </iterate>
+               </with>
+            </visibleWhen>
+         </command>
+         <command
+               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.createSession"
+               icon="icons/elcl16/add_button.gif"
+               label="%commands.control.create.session"
+               style="push">
+            <visibleWhen
+                  checkEnabled="false">
+               <with
+                     variable="activeMenuSelection">
+                  <iterate
+                        operator="or">
+                     <instanceof
+                           value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionGroup">
+                     </instanceof>
+                  </iterate>
+               </with>
+            </visibleWhen>
+         </command>
+         <command
+               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.executeScript"
+               icon="icons/elcl16/add_button.gif"
+               label="%commands.control.execute.command.script"
+               style="push">
+            <visibleWhen
+                  checkEnabled="false">
+               <with
+                     variable="activeMenuSelection">
+                  <iterate
+                        operator="or">
+                     <instanceof
+                           value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionGroup">
+                     </instanceof>
+                  </iterate>
+               </with>
+            </visibleWhen>
+         </command>
+         <command
+               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.start"
+               icon="icons/elcl16/start_trace.gif"
+               label="%commands.control.start"
+               style="push">
+            <visibleWhen
+                  checkEnabled="false">
+               <with
+                     variable="activeMenuSelection">
+                  <iterate
+                        operator="or">
+                     <instanceof
+                           value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent">
+                     </instanceof>
+                  </iterate>
+               </with>
+            </visibleWhen>
+         </command>
+         <command
+               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.stop"
+               icon="icons/elcl16/pause_trace.gif"
+               label="%commands.control.stop"
+               style="push">
+            <visibleWhen
+                  checkEnabled="false">
+               <with
+                     variable="activeMenuSelection">
+                  <iterate
+                        operator="or">
+                     <instanceof
+                           value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent">
+                     </instanceof>
+                  </iterate>
+               </with>
+            </visibleWhen>
+         </command>
+         <command
+               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.destroySession"
+               icon="icons/elcl16/delete_trace.gif"
+               label="%commands.control.destroy.session"
+               style="push">
+            <visibleWhen
+                  checkEnabled="false">
+               <with
+                     variable="activeMenuSelection">
+                  <iterate
+                        operator="or">
+                     <instanceof
+                           value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent">
+                     </instanceof>
+                  </iterate>
+               </with>
+            </visibleWhen>
+         </command>
+         <separator
+               name="org.eclipse.linuxtools.internal.lttng2.ui.views.control.popup.separator1"
+               visible="true">
+         </separator>
+         <command
+               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.import"
+               icon="icons/elcl16/import_trace.gif"
+               label="%commands.control.import"
+               style="push">
+            <visibleWhen
+                  checkEnabled="false">
+               <with
+                     variable="activeMenuSelection">
+                  <and>
+                    <iterate
+                         operator="or">
+                         <instanceof
+                               value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent">
+                         </instanceof>
+                      </iterate>
+                      <count
+                           value="1">
+                      </count>
+                  </and>   
+               </with>
+            </visibleWhen>
+         </command>
+         <separator
+               name="org.eclipse.linuxtools.internal.lttng2.ui.views.control.popup.separator2"
+               visible="true">
+         </separator>
+         <command
+               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.enableChannelOnSession"
+               icon="icons/elcl16/add_button.gif"
+               label="%commands.control.enable.channelOnSession"
+               style="push">
+            <visibleWhen
+                  checkEnabled="false">
+               <with
+                     variable="activeMenuSelection">
+                  <and>
+                     <iterate
+                           operator="or">
+                        <instanceof
+                              value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent">
+                        </instanceof>
+                     </iterate>
+                     <not>
+                        <iterate
+                              operator="or">
+                           <instanceof
+                                 value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent">
+                           </instanceof>
+                        </iterate>
+                     </not>
+                     <count
+                           value="1">
+                     </count>
+                  </and>
+               </with>
+            </visibleWhen>
+         </command>
+         <command
+               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.enableEventOnSession"
+               icon="icons/obj16/event_enabled.gif"
+               label="%commands.control.enable.eventOnDomain"
+               style="push">
+            <visibleWhen
+                  checkEnabled="false">
+               <with
+                     variable="activeMenuSelection">
+                  <and>
+                     <iterate
+                           operator="or">
+                        <instanceof
+                              value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent">
+                        </instanceof>
+                     </iterate>
+                     <count
+                           value="1">
+                     </count>
+                  </and>
+               </with>
+            </visibleWhen>
+         </command>
+         <command
+               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.enableChannelOnDomain"
+               icon="icons/elcl16/add_button.gif"
+               label="%commands.control.enable.channelOnDomain"
+               style="push">
+            <visibleWhen
+                  checkEnabled="false">
+               <with
+                     variable="activeMenuSelection">
+                  <and>
+                     <iterate
+                           operator="or">
+                        <instanceof
+                              value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent">
+                        </instanceof>
+                     </iterate>
+                        <not>
+                           <iterate
+                                 operator="or">
+                              <instanceof
+                                    value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent">
+                              </instanceof>
+                           </iterate>
+                        </not>
+                        <count
+                              value="1">
+                        </count>
+                  </and>
+               </with>
+               </visibleWhen>
+         </command>
+         <command
+               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.enableEventOnDomain"
+               icon="icons/elcl16/enable_event.gif"
+               label="%commands.control.enable.eventOnDomain"
+               style="push">
+            <visibleWhen
+                  checkEnabled="false">
+               <with
+                     variable="activeMenuSelection">
+                  <and>
+                     <iterate
+                           operator="or">
+                        <instanceof
+                              value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent">
+                        </instanceof>
+                     </iterate>
+                     <count
+                           value="1">
+                     </count>
+                  </and>
+               </with>
+            </visibleWhen>
+         </command>
+         <command
+               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.enableChannel"
+               icon="icons/elcl16/enable.gif"
+               label="%commands.control.enable.channel"
+               style="push">
+            <visibleWhen
+                  checkEnabled="false">
+               <with
+                     variable="activeMenuSelection">
+                  <iterate
+                        operator="or">
+                     <instanceof
+                           value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent">
+                     </instanceof>
+                  </iterate>
+               </with>
+            </visibleWhen>
+         </command>
+         <command
+               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.disableChannel"
+               icon="icons/elcl16/disable.gif"
+               label="%commands.control.disable.channel"
+               style="push">
+            <visibleWhen
+                  checkEnabled="false">
+               <with
+                     variable="activeMenuSelection">
+                  <iterate
+                        operator="or">
+                     <instanceof
+                           value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent">
+                     </instanceof>
+                  </iterate>
+               </with>
+            </visibleWhen>
+         </command>
+
+         <command
+               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.assign.event"
+               icon="icons/elcl16/enable_event.gif"
+               label="%commands.control.assign.event"
+               style="push">
+            <visibleWhen
+                  checkEnabled="false">
+               <with
+                     variable="activeMenuSelection">
+                  <iterate
+                        operator="or">
+                     <instanceof
+                           value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.BaseEventComponent">
+                     </instanceof>
+                  </iterate>
+               </with>
+            </visibleWhen>
+         </command>
+
+         <command
+               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.enableEvent"
+               icon="icons/elcl16/enable_event.gif"
+               label="%commands.control.enable.event"
+               style="push">
+            <visibleWhen
+                  checkEnabled="false">
+               <with
+                     variable="activeMenuSelection">
+                  <iterate
+                        operator="or">
+                     <instanceof
+                           value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceEventComponent">
+                     </instanceof>
+                  </iterate>
+               </with>
+            </visibleWhen>
+         </command>
+
+         <command
+               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.disableEvent"
+               icon="icons/elcl16/disable_event.gif"
+               label="%commands.control.disable.event"
+               style="push">
+            <visibleWhen
+                  checkEnabled="false">
+               <with
+                     variable="activeMenuSelection">
+                  <iterate
+                        operator="or">
+                     <instanceof
+                           value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceEventComponent">
+                     </instanceof>
+                  </iterate>
+               </with>
+            </visibleWhen>
+         </command>
+         <command
+               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.enableEventOnChannel"
+               icon="icons/elcl16/enable_event.gif"
+               label="%commands.control.enable.eventOnChannel"
+               style="push">
+            <visibleWhen
+                  checkEnabled="false">
+               <with
+                     variable="activeMenuSelection">
+                  <and>
+                     <iterate
+                           operator="or">
+                        <instanceof
+                              value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent">
+                        </instanceof>
+                     </iterate>
+                     <count
+                           value="1">
+                     </count>
+                  </and>
+               </with>
+            </visibleWhen>
+         </command>
+         <command
+               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.addContextOnDomain"
+               icon="icons/elcl16/add-context.gif"
+               label="%commands.control.add.context"
+               style="push">
+            <visibleWhen
+                  checkEnabled="false">
+               <with
+                     variable="activeMenuSelection">
+                  <and>
+                     <iterate
+                           operator="or">
+                        <instanceof
+                              value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent">
+                        </instanceof>
+                     </iterate>
+                     <count
+                           value="1">
+                     </count>
+                  </and>
+               </with>
+            </visibleWhen>
+         </command>
+         <command
+               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.addContextOnChannel"
+               icon="icons/elcl16/add-context.gif"
+               label="%commands.control.add.context"
+               style="push">
+            <visibleWhen
+                  checkEnabled="false">
+               <with
+                     variable="activeMenuSelection">
+                  <and>
+                     <iterate
+                           operator="or">
+                        <instanceof
+                              value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent">
+                        </instanceof>
+                     </iterate>
+                     <count
+                           value="1">
+                     </count>
+                  </and>
+               </with>
+            </visibleWhen>
+         </command>
+         <command
+               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.addContextOnEvent"
+               icon="icons/elcl16/add-context.gif"
+               label="%commands.control.add.context"
+               style="push">
+            <visibleWhen
+                  checkEnabled="false">
+               <with
+                     variable="activeMenuSelection">
+                  <and>
+                     <count
+                           value="1">
+                     </count>
+                     <iterate
+                           ifEmpty="false"
+                           operator="and">
+                        <and>
+                           <or>
+                              <instanceof
+                                    value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceEventComponent">
+                              </instanceof>
+                           </or>
+                           <test
+                                 forcePluginActivation="true"
+                                 property="org.eclipse.linuxtools.internal.lttng2.ui.views.control.model.isAddContextOnEventSupported">
+                           </test>
+                        </and>
+                     </iterate>
+                  </and>
+               </with>
+            </visibleWhen>
+         </command>
+         <command
+               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.calibrate"
+               icon="icons/elcl16/calibrate.gif"
+               label="%commands.control.calibrate"
+               style="push">
+            <visibleWhen
+                  checkEnabled="false">
+               <with
+                     variable="activeMenuSelection">
+                  <and>
+                     <iterate
+                           operator="or">
+                        <instanceof
+                              value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent">
+                        </instanceof>
+                     </iterate>
+                     <count
+                           value="1">
+                     </count>
+                  </and>
+               </with>
+            </visibleWhen>
+         </command>
+
+         <command
+               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.snapshot"
+               icon="icons/elcl16/snapshot.gif"
+               label="%commands.control.snapshot"
+               style="push">
+            <visibleWhen
+                  checkEnabled="false">
+               <with
+                     variable="activeMenuSelection">
+                  <and>
+                     <iterate
+                           operator="or">
+                        <instanceof
+                              value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent">
+                        </instanceof>
+                     </iterate>
+                     <count
+                           value="1">
+                     </count>
+                  </and>
+               </with>
+            </visibleWhen>
+         </command>
+
+      </menuContribution>
+      
+   </extension>
+   <extension
+         point="org.eclipse.ui.handlers">
+      <handler
+            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.NewConnectionHandler"
+            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.newConnection">
+         <activeWhen>
+            <with
+                  variable="activePart">
+               <instanceof
+                     value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView">
+               </instanceof>
+            </with>
+         </activeWhen>
+      </handler>
+      <handler
+            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.ConnectHandler"
+            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.connect">
+         <activeWhen>
+            <with
+                  variable="selection">
+               <iterate
+                     operator="or">
+                  <instanceof
+                        value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent">
+                  </instanceof>
+               </iterate>
+            </with>
+         </activeWhen>
+      </handler>
+      <handler
+            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.DisconnectHandler"
+            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.disconnect">
+         <activeWhen>
+            <with
+                  variable="selection">
+               <iterate
+                     operator="or">
+                  <instanceof
+                        value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent">
+                  </instanceof>
+               </iterate>
+            </with>
+         </activeWhen>
+      </handler>
+      <handler
+            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.RefreshHandler"
+            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.refresh">
+         <activeWhen>
+            <with
+                  variable="selection">
+               <iterate
+                     operator="or">
+                  <instanceof
+                        value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceControlComponent">
+                  </instanceof>
+               </iterate>
+            </with>
+         </activeWhen>
+      </handler>
+      <handler
+            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.DeleteHandler"
+            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.delete">
+         <activeWhen>
+            <with
+                  variable="selection">
+               <iterate
+                     operator="or">
+                  <instanceof
+                        value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent">
+                  </instanceof>
+               </iterate>
+            </with>
+         </activeWhen>
+      </handler>
+      <handler
+            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.CreateSessionHandler"
+            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.createSession">
+         <activeWhen>
+            <with
+                  variable="selection">
+               <iterate
+                     operator="or">
+                  <instanceof
+                        value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionGroup">
+                  </instanceof>
+               </iterate>
+            </with>
+         </activeWhen>
+      </handler>
+      <handler
+            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.ExecuteCommandScriptHandler"
+            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.executeScript">
+         <activeWhen>
+            <with
+                  variable="selection">
+               <iterate
+                     operator="or">
+                  <instanceof
+                        value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionGroup">
+                  </instanceof>
+               </iterate>
+            </with>
+         </activeWhen>
+      </handler>
+      <handler
+            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.DestroySessionHandler"
+            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.destroySession">
+         <activeWhen>
+            <with
+                  variable="selection">
+               <iterate
+                     operator="or">
+                  <instanceof
+                        value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent">
+                  </instanceof>
+               </iterate>
+            </with>
+         </activeWhen>
+      </handler>
+      <handler
+            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.ImportHandler"
+            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.import">
+         <activeWhen>
+            <with
+                  variable="selection">
+               <and>   
+                  <iterate
+                        operator="or">
+                     <instanceof
+                           value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent">
+                     </instanceof>
+                  </iterate>
+                  <count
+                        value="1">
+                  </count>
+               </and>
+            </with>
+         </activeWhen>
+      </handler>
+      <handler
+            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.EnableChannelOnSessionHandler"
+            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.enableChannelOnSession">
+         <activeWhen>
+            <with
+                  variable="selection">
+               <iterate
+                     operator="or">
+                  <instanceof
+                        value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent">
+                  </instanceof>
+               </iterate>
+            </with>
+         </activeWhen>
+      </handler>
+      <handler
+            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.EnableChannelOnDomainHandler"
+            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.enableChannelOnDomain">
+         <activeWhen>
+            <with
+                  variable="selection">
+               <iterate
+                     operator="or">
+                  <instanceof
+                        value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent">
+                  </instanceof>
+               </iterate>
+            </with>
+         </activeWhen>
+      </handler>
+      <handler
+            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.EnableChannelHandler"
+            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.enableChannel">
+         <activeWhen>
+            <with
+                  variable="selection">
+               <iterate
+                     operator="or">
+                  <instanceof
+                        value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent">
+                  </instanceof>
+               </iterate>
+            </with>
+         </activeWhen>
+      </handler>
+      <handler
+            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.DisableChannelHandler"
+            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.disableChannel">
+         <activeWhen>
+            <with
+                  variable="selection">
+               <iterate
+                     operator="or">
+                  <instanceof
+                        value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent">
+                  </instanceof>
+               </iterate>
+            </with>
+         </activeWhen>
+      </handler>
+      
+      <handler
+            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.StartHandler"
+            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.start">
+         <activeWhen>
+            <with
+                  variable="selection">
+               <iterate
+                     operator="or">
+                  <instanceof
+                        value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent">
+                  </instanceof>
+               </iterate>
+            </with>
+         </activeWhen>
+      </handler>
+
+      <handler
+            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.StopHandler"
+            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.stop">
+         <activeWhen>
+            <with
+                  variable="selection">
+               <iterate
+                     operator="or">
+                  <instanceof
+                        value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent">
+                  </instanceof>
+               </iterate>
+            </with>
+         </activeWhen>
+      </handler>
+
+      <handler
+            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.SnaphshotHandler"
+            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.snapshot">
+         <activeWhen>
+            <with
+                  variable="selection">
+               <iterate
+                     operator="or">
+                  <instanceof
+                        value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent">
+                  </instanceof>
+               </iterate>
+            </with>
+         </activeWhen>
+      </handler>
+
+
+      <handler
+            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.AssignEventHandler"
+            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.assign.event">
+         <activeWhen>
+            <with
+                  variable="selection">
+               <iterate
+                     operator="or">
+                  <instanceof
+                        value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.BaseEventComponent">
+                  </instanceof>
+               </iterate>
+            </with>
+         </activeWhen>
+      </handler>
+
+      <handler
+            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.EnableEventHandler"
+            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.enableEvent">
+         <activeWhen>
+            <with
+                  variable="selection">
+               <iterate
+                     operator="or">
+                  <instanceof
+                        value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceEventComponent">
+                  </instanceof>
+               </iterate>
+            </with>
+         </activeWhen>
+      </handler>
+
+      <handler
+            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.DisableEventHandler"
+            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.disableEvent">
+         <activeWhen>
+            <with
+                  variable="selection">
+               <iterate
+                     operator="or">
+                  <instanceof
+                        value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceEventComponent">
+                  </instanceof>
+               </iterate>
+            </with>
+         </activeWhen>
+      </handler>
+
+      <handler
+            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.EnableEventOnChannelHandler"
+            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.enableEventOnChannel">
+         <activeWhen>
+            <with
+                  variable="selection">
+               <iterate
+                     operator="or">
+                  <instanceof
+                        value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent">
+                  </instanceof>
+               </iterate>
+            </with>
+         </activeWhen>
+      </handler>
+
+      <handler
+            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.EnableEventOnDomainHandler"
+            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.enableEventOnDomain">
+         <activeWhen>
+            <with
+                  variable="selection">
+               <iterate
+                     operator="or">
+                  <instanceof
+                        value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent">
+                  </instanceof>
+               </iterate>
+            </with>
+         </activeWhen>
+      </handler>
+      <handler
+            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.EnableEventOnSessionHandler"
+            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.enableEventOnSession">
+         <activeWhen>
+            <with
+                  variable="selection">
+               <iterate
+                     operator="or">
+                  <instanceof
+                        value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent">
+                  </instanceof>
+               </iterate>
+            </with>
+         </activeWhen>
+      </handler>
+      
+      <handler
+            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.AddContextOnDomainHandler"
+            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.addContextOnDomain">
+         <activeWhen>
+            <with
+                  variable="selection">
+               <iterate
+                     operator="or">
+                  <instanceof
+                        value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent">
+                  </instanceof>
+               </iterate>
+            </with>
+         </activeWhen>
+      </handler>
+
+      <handler
+            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.CalibrateHandler"
+            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.calibrate">
+         <activeWhen>
+            <with
+                  variable="selection">
+               <iterate
+                     operator="or">
+                  <instanceof
+                        value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent">
+                  </instanceof>
+               </iterate>
+            </with>
+         </activeWhen>
+      </handler>
+
+      <handler
+            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.AddContextOnChannelHandler"
+            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.addContextOnChannel">
+         <activeWhen>
+            <with
+                  variable="selection">
+               <iterate
+                     operator="or">
+                  <instanceof
+                        value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent">
+                  </instanceof>
+               </iterate>
+            </with>
+         </activeWhen>
+      </handler>
+
+      <handler
+            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.AddContextOnEventHandler"
+            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.addContextOnEvent">
+         <activeWhen>
+            <with
+                  variable="selection">
+               <iterate
+                     operator="or">
+                  <instanceof
+                        value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceEventComponent">
+                  </instanceof>
+               </iterate>
+            </with>
+         </activeWhen>
+      </handler>
+      
+   </extension>
+   <extension
+         point="org.eclipse.ui.preferencePages">
+      <page
+            category="org.eclipse.linuxtools.tmf.ui.TmfTracingPreferences"
+            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.preferences.ControlPreferencePage"
+            id="org.eclipse.linuxtools.internal.lttng2.ui.views.control.preferences"
+            name="%preference.page.control.name">
+      </page>
+   </extension>
+   <extension
+         point="org.eclipse.core.runtime.preferences">
+      <initializer
+            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.preferences.ControlPreferenceInitializer">
+      </initializer>
+   </extension>
+   <extension
+         point="org.eclipse.core.expressions.propertyTesters">
+      <propertyTester
+            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceControlPropertyTester"
+            id="org.eclipse.linuxtools.internal.lttng2.ui.views.control.model.propertyTester"
+            namespace="org.eclipse.linuxtools.internal.lttng2.ui.views.control.model"
+            properties="isAddContextOnEventSupported"
+            type="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceControlComponent">
+      </propertyTester>
+   </extension>
+   
+   
+</plugin>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/pom.xml b/lttng/org.eclipse.tracecompass.lttng2.control.ui/pom.xml
new file mode 100644 (file)
index 0000000..ec3dff7
--- /dev/null
@@ -0,0 +1,36 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+   Copyright (C) 2011, Red Hat, Inc.
+
+   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
+-->
+<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>
+    <artifactId>org.eclipse.tracecompass.lttng-parent</artifactId>
+    <groupId>org.eclipse.tracecompass</groupId>
+    <version>1.0.0-SNAPSHOT</version>
+  </parent>
+
+  <artifactId>org.eclipse.tracecompass.lttng2.control.ui</artifactId>
+  <version>1.0.0-SNAPSHOT</version>
+  <packaging>eclipse-plugin</packaging>
+
+  <name>Trace Compass LTTng Control UI Plug-in</name>
+
+ <build>
+    <plugins>
+      <plugin>
+        <groupId>org.eclipse.tycho</groupId>
+        <artifactId>tycho-source-plugin</artifactId>
+      </plugin>
+    </plugins>
+  </build>
+
+ <groupId>org.eclipse.tracecompass</groupId>
+</project>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/Activator.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/Activator.java
new file mode 100644 (file)
index 0000000..24f54ac
--- /dev/null
@@ -0,0 +1,210 @@
+/*******************************************************************************
+ * Copyright (c) 2012, 2015 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:
+ *   Francois Chouinard - Initial API and implementation
+ *   Bernd Hufmann - Add Utility to get a OSGI service
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.ui;
+
+import java.net.URL;
+
+import org.eclipse.core.runtime.IStatus;
+import org.eclipse.core.runtime.Status;
+import org.eclipse.jface.resource.ImageDescriptor;
+import org.eclipse.jface.resource.ImageRegistry;
+import org.eclipse.swt.graphics.Image;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.relayd.LttngRelaydConnectionManager;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.preferences.ControlPreferences;
+import org.eclipse.ui.plugin.AbstractUIPlugin;
+import org.osgi.framework.BundleContext;
+
+/**
+ * The activator class controls the plug-in life cycle
+ */
+public class Activator extends AbstractUIPlugin {
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+
+    /**
+     *  The plug-in ID
+     */
+    public static final String PLUGIN_ID = "org.eclipse.tracecompass.lttng2.control.ui"; //$NON-NLS-1$
+
+    /**
+     *  The shared instance
+     */
+    private static Activator plugin;
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+
+    /**
+     * The constructor
+     */
+    public Activator() {
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    /**
+     * Returns the shared instance
+     *
+     * @return the shared instance
+     */
+    public static Activator getDefault() {
+        return plugin;
+    }
+
+    // ------------------------------------------------------------------------
+    // AbstractUIPlugin
+    // ------------------------------------------------------------------------
+
+    @Override
+    public void start(BundleContext context) throws Exception {
+        super.start(context);
+        plugin = this;
+        ControlPreferences.getInstance().init(getPreferenceStore());
+        // This registers the connection manager with the signal manager
+        LttngRelaydConnectionManager.getInstance();
+    }
+
+    @Override
+    public void stop(BundleContext context) throws Exception {
+        ControlPreferences.getInstance().dispose();
+        LttngRelaydConnectionManager.getInstance().dispose();
+        plugin = null;
+        super.stop(context);
+    }
+
+    @Override
+    protected void initializeImageRegistry(ImageRegistry reg) {
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    /**
+     * Gets an image object using given path within plug-in.
+     *
+     * @param path path to image file
+     *
+     * @return image object
+     */
+    public Image getImageFromPath(String path) {
+        return getImageDescripterFromPath(path).createImage();
+    }
+
+    /**
+     * Gets an image descriptor using given path within plug-in.
+     *
+     * @param path path to image file
+     *
+     * @return image descriptor object
+     */
+    public ImageDescriptor getImageDescripterFromPath(String path) {
+        return AbstractUIPlugin.imageDescriptorFromPlugin(PLUGIN_ID, path);
+    }
+
+    /**
+     * Gets a image object from the image registry based on the given path.
+     * If the image is not in the registry it will be registered.
+     *
+     * @param path to the image file
+     * @return image object
+     */
+    public Image getImageFromImageRegistry(String path) {
+        Image icon = getImageRegistry().get(path);
+        if (icon == null) {
+            icon = getImageDescripterFromPath(path).createImage();
+            plugin.getImageRegistry().put(path, icon);
+        }
+        return icon;
+    }
+
+    /**
+     * Loads the image in the plug-ins image registry (if necessary) and returns the image
+     * @param url - URL relative to the Bundle
+     * @return  the image
+     */
+    public Image loadIcon(String url) {
+        String key = plugin.getBundle().getSymbolicName() + "/" + url; //$NON-NLS-1$
+        Image icon = plugin.getImageRegistry().get(key);
+        if (icon == null) {
+            URL imageURL = plugin.getBundle().getResource(url);
+            ImageDescriptor descriptor = ImageDescriptor.createFromURL(imageURL);
+            icon = descriptor.createImage();
+            plugin.getImageRegistry().put(key, icon);
+        }
+        return icon;
+    }
+
+    /**
+     * Logs a message with severity INFO in the runtime log of the plug-in.
+     *
+     * @param message A message to log
+     */
+    public void logInfo(String message) {
+        getLog().log(new Status(IStatus.INFO, PLUGIN_ID, message));
+    }
+
+    /**
+     * Logs a message and exception with severity INFO in the runtime log of the plug-in.
+     *
+     * @param message A message to log
+     * @param exception A exception to log
+     */
+    public void logInfo(String message, Throwable exception) {
+        getLog().log(new Status(IStatus.INFO, PLUGIN_ID, message, exception));
+    }
+
+    /**
+     * Logs a message and exception with severity WARNING in the runtime log of the plug-in.
+     *
+     * @param message A message to log
+     */
+    public void logWarning(String message) {
+        getLog().log(new Status(IStatus.WARNING, PLUGIN_ID, message));
+    }
+
+    /**
+     * Logs a message and exception with severity WARNING in the runtime log of the plug-in.
+     *
+     * @param message A message to log
+     * @param exception A exception to log
+     */
+    public void logWarning(String message, Throwable exception) {
+        getLog().log(new Status(IStatus.WARNING, PLUGIN_ID, message, exception));
+    }
+
+    /**
+     * Logs a message and exception with severity ERROR in the runtime log of the plug-in.
+     *
+     * @param message A message to log
+     */
+    public void logError(String message) {
+        getLog().log(new Status(IStatus.ERROR, PLUGIN_ID, message));
+    }
+
+    /**
+     * Logs a message and exception with severity ERROR in the runtime log of the plug-in.
+     *
+     * @param message A message to log
+     * @param exception A exception to log
+     */
+    public void logError(String message, Throwable exception) {
+        getLog().log(new Status(IStatus.ERROR, PLUGIN_ID, message, exception));
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/relayd/LttngRelaydConnectionInfo.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/relayd/LttngRelaydConnectionInfo.java
new file mode 100644 (file)
index 0000000..1f435a8
--- /dev/null
@@ -0,0 +1,110 @@
+/**********************************************************************
+ * Copyright (c) 2014 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:
+ *   Marc-Andre Laperle - Initial implementation
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.ui.relayd;
+
+/**
+ * A class that holds information about the relayd connection.
+ *
+ * @author Marc-Andre Laperle
+ */
+public final class LttngRelaydConnectionInfo {
+
+    private final String fHost;
+    private final int fPort;
+    private final String fSessionName;
+
+    /**
+     * Constructs a connection information.
+     *
+     * @param host
+     *            the host string
+     * @param port
+     *            the port number
+     * @param sessionName
+     *            the session name
+     */
+    public LttngRelaydConnectionInfo(String host, int port, String sessionName) {
+        fHost = host;
+        fPort = port;
+        fSessionName = sessionName;
+    }
+
+    /**
+     * Get the host string.
+     *
+     * @return the host string
+     */
+    public String getHost() {
+        return fHost;
+    }
+
+    /**
+     * Get the port number.
+     *
+     * @return the port number
+     */
+    public int getPort() {
+        return fPort;
+    }
+
+    /**
+     * Get the session name.
+     *
+     * @return the session name
+     */
+    public String getSessionName() {
+        return fSessionName;
+    }
+
+    @Override
+    public int hashCode() {
+        final int prime = 31;
+        int result = 1;
+        result = prime * result + ((fHost == null) ? 0 : fHost.hashCode());
+        result = prime * result + fPort;
+        result = prime * result + ((fSessionName == null) ? 0 : fSessionName.hashCode());
+        return result;
+    }
+
+    @Override
+    public boolean equals(final Object obj) {
+        if (this == obj) {
+            return true;
+        }
+        if (obj == null) {
+            return false;
+        }
+        if (getClass() != obj.getClass()) {
+            return false;
+        }
+        LttngRelaydConnectionInfo other = (LttngRelaydConnectionInfo) obj;
+        if (fHost == null) {
+            if (other.fHost != null) {
+                return false;
+            }
+        } else if (!fHost.equals(other.fHost)) {
+            return false;
+        }
+        if (fPort != other.fPort) {
+            return false;
+        }
+        if (fSessionName == null) {
+            if (other.fSessionName != null) {
+                return false;
+            }
+        } else if (!fSessionName.equals(other.fSessionName)) {
+            return false;
+        }
+        return true;
+    }
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/relayd/LttngRelaydConnectionManager.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/relayd/LttngRelaydConnectionManager.java
new file mode 100644 (file)
index 0000000..178e865
--- /dev/null
@@ -0,0 +1,148 @@
+/**********************************************************************
+ * Copyright (c) 2014 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:
+ *   Marc-Andre Laperle - Initial implementation
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.ui.relayd;
+
+import java.util.HashMap;
+import java.util.Map;
+
+import org.eclipse.core.resources.IResource;
+import org.eclipse.core.runtime.CoreException;
+import org.eclipse.core.runtime.IStatus;
+import org.eclipse.core.runtime.Status;
+import org.eclipse.jface.dialogs.ErrorDialog;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
+import org.eclipse.tracecompass.tmf.core.signal.TmfSignalHandler;
+import org.eclipse.tracecompass.tmf.core.signal.TmfSignalManager;
+import org.eclipse.tracecompass.tmf.core.signal.TmfTraceClosedSignal;
+import org.eclipse.tracecompass.tmf.core.signal.TmfTraceOpenedSignal;
+import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace;
+import org.eclipse.tracecompass.tmf.ctf.core.CtfConstants;
+import org.eclipse.tracecompass.tmf.ctf.core.trace.CtfTmfTrace;
+import org.eclipse.ui.PlatformUI;
+
+/**
+ * Manages relayd connections. When a trace is opened, it creates a connection
+ * if the trace was started with live support. When a trace is closed, is closes
+ * the connection.
+ *
+ * @author Marc-Andre Laperle
+ */
+public final class LttngRelaydConnectionManager {
+    private static LttngRelaydConnectionManager fConnectionManager;
+    private Map<LttngRelaydConnectionInfo, LttngRelaydConsumer> fConnections = new HashMap<>();
+
+    /**
+     * Get an instance of the trace manager.
+     *
+     * @return The trace manager
+     */
+    public static synchronized LttngRelaydConnectionManager getInstance() {
+        if (fConnectionManager == null) {
+            fConnectionManager = new LttngRelaydConnectionManager();
+            TmfSignalManager.register(fConnectionManager);
+        }
+        return fConnectionManager;
+    }
+
+    /**
+     * Get the cosumer for the given relayd connection information.
+     *
+     * @param connectionInfo
+     *            the connection information
+     *
+     * @return the consumer
+     */
+    public LttngRelaydConsumer getConsumer(final LttngRelaydConnectionInfo connectionInfo) {
+        if (!fConnections.containsKey(connectionInfo)) {
+            LttngRelaydConsumer lttngRelaydConsumer = new LttngRelaydConsumer(connectionInfo);
+            fConnections.put(connectionInfo, lttngRelaydConsumer);
+            return lttngRelaydConsumer;
+        }
+
+        return fConnections.get(connectionInfo);
+    }
+
+    private static LttngRelaydConnectionInfo getEntry(final ITmfTrace trace) throws CoreException {
+        if (trace instanceof CtfTmfTrace) {
+            CtfTmfTrace ctfTmfTrace = (CtfTmfTrace) trace;
+            if (!ctfTmfTrace.isComplete()) {
+                IResource resource = ctfTmfTrace.getResource();
+                String host = resource.getPersistentProperty(CtfConstants.LIVE_HOST);
+                String port = resource.getPersistentProperty(CtfConstants.LIVE_PORT);
+                String sessionName = resource.getPersistentProperty(CtfConstants.LIVE_SESSION_NAME);
+                if (host != null && port != null && sessionName != null && !sessionName.isEmpty()) {
+                    LttngRelaydConnectionInfo entry = new LttngRelaydConnectionInfo(host, Integer.parseInt(port), sessionName);
+                    return entry;
+                }
+            }
+        }
+
+        return null;
+    }
+
+    /**
+     * Listen to trace opened so that we can start the relayd job if necessary.
+     *
+     * @param signal
+     *            the signal to be processed
+     */
+    @TmfSignalHandler
+    public void traceOpened(final TmfTraceOpenedSignal signal) {
+
+        try {
+            LttngRelaydConnectionInfo entry = getEntry(signal.getTrace());
+            if (entry != null) {
+                LttngRelaydConsumer consumer = getConsumer(entry);
+                consumer.connect();
+                consumer.run((CtfTmfTrace) signal.getTrace());
+            }
+        } catch (CoreException e) {
+            Activator.getDefault().logError(Messages.LttngRelaydConnectionManager_ConnectionError, e);
+            ErrorDialog.openError(PlatformUI.getWorkbench().getActiveWorkbenchWindow().getShell(), null, Messages.LttngRelaydConnectionManager_ConnectionError, new Status(IStatus.WARNING,
+                    Activator.PLUGIN_ID, e.getLocalizedMessage(), e));
+        }
+    }
+
+    /**
+     * Listen to trace closed so that we can stop the relayd job.
+     *
+     * @param signal
+     *            the signal to be processed
+     */
+    @TmfSignalHandler
+    public void traceClosed(final TmfTraceClosedSignal signal) {
+        LttngRelaydConnectionInfo entry;
+        try {
+            entry = getEntry(signal.getTrace());
+            if (entry != null) {
+                LttngRelaydConsumer comsumer = getConsumer(entry);
+                if (comsumer != null) {
+                    comsumer.dispose();
+                }
+                fConnections.remove(entry);
+            }
+        } catch (CoreException e) {
+            // Something went wrong with the resource. That's OK, the trace is
+            // getting closed anyway.
+        }
+    }
+
+    /**
+     * Dispose of all the manager's resources (i.e. its connections).
+     */
+    public void dispose() {
+        for (LttngRelaydConsumer consumer : fConnections.values()) {
+            consumer.dispose();
+        }
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/relayd/LttngRelaydConsumer.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/relayd/LttngRelaydConsumer.java
new file mode 100644 (file)
index 0000000..2cc064b
--- /dev/null
@@ -0,0 +1,264 @@
+/**********************************************************************
+ * Copyright (c) 2014, 2015 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:
+ *   Matthew Khouzam - Initial implementation
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.ui.relayd;
+
+import java.io.IOException;
+import java.io.UnsupportedEncodingException;
+import java.net.Socket;
+import java.util.List;
+import java.util.regex.Matcher;
+import java.util.regex.Pattern;
+
+import org.eclipse.core.runtime.CoreException;
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.core.runtime.IStatus;
+import org.eclipse.core.runtime.Status;
+import org.eclipse.core.runtime.jobs.Job;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.ILttngRelaydConnector;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.LttngRelaydConnectorFactory;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.AttachReturnCode;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.AttachSessionResponse;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.CreateSessionResponse;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.CreateSessionReturnCode;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.IndexResponse;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.NextIndexReturnCode;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.SessionResponse;
+import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.StreamResponse;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
+import org.eclipse.tracecompass.tmf.core.signal.TmfTraceRangeUpdatedSignal;
+import org.eclipse.tracecompass.tmf.core.timestamp.TmfNanoTimestamp;
+import org.eclipse.tracecompass.tmf.core.timestamp.TmfTimeRange;
+import org.eclipse.tracecompass.tmf.ctf.core.trace.CtfTmfTrace;
+
+/**
+ * Consumer of the relay d.
+ *
+ * @author Matthew Khouzam
+ */
+public final class LttngRelaydConsumer {
+
+    private static final Pattern PROTOCOL_HOST_PATTERN = Pattern.compile("(\\S+://)*(\\d+\\.\\d+\\.\\d+\\.\\d+)"); //$NON-NLS-1$
+    private static final int SIGNAL_THROTTLE_NANOSEC = 10_000_000;
+    private static final String ENCODING_UTF_8 = "UTF-8"; //$NON-NLS-1$
+
+    private Job fConsumerJob;
+    private CtfTmfTrace fCtfTmfTrace;
+    private long fTimestampEnd;
+    private AttachSessionResponse fSession;
+    private Socket fConnection;
+    private ILttngRelaydConnector fRelayd;
+    private String fTracePath;
+    private long fLastSignal = 0;
+    private final LttngRelaydConnectionInfo fConnectionInfo;
+
+    /**
+     * Start a lttng consumer.
+     *
+     * @param address
+     *            the ip address in string format
+     * @param port
+     *            the port, an integer
+     * @param sessionName
+     *            the session name
+     * @param project
+     *            the default project
+     */
+    LttngRelaydConsumer(final LttngRelaydConnectionInfo connectionInfo) {
+        fConnectionInfo = connectionInfo;
+        fTimestampEnd = 0;
+    }
+
+    /**
+     * Connects to the relayd at the given address and port then attaches to the
+     * given session name.
+     *
+     * @throws CoreException
+     *             If something goes wrong during the connection
+     *             <ul>
+     *             <li>
+     *             Connection could not be established (Socket could not be
+     *             opened, etc)</li>
+     *             <li>
+     *             Connection timeout</li>
+     *             <li>
+     *             The session was not found</li>
+     *             <li>
+     *             Could not create viewer session</li>
+     *             <li>
+     *             Invalid trace (no metadata, no streams)</li>
+     *             </ul>
+     */
+    public void connect() throws CoreException {
+        if (fConnection != null) {
+            return;
+        }
+
+        try {
+            Matcher matcher = PROTOCOL_HOST_PATTERN.matcher(fConnectionInfo.getHost());
+            String host = null;
+            if (matcher.matches()) {
+                host = matcher.group(2);
+            }
+
+            if (host == null || host.isEmpty()) {
+                throw new CoreException(new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.LttngRelaydConsumer_ErrorConnecting));
+            }
+
+            fConnection = new Socket(host, fConnectionInfo.getPort());
+            fRelayd = LttngRelaydConnectorFactory.getNewConnector(fConnection);
+            List<SessionResponse> sessions = fRelayd.getSessions();
+            SessionResponse selectedSession = null;
+            for (SessionResponse session : sessions) {
+                String asessionName = nullTerminatedByteArrayToString(session.getSessionName().getBytes());
+
+                if (asessionName.equals(fConnectionInfo.getSessionName())) {
+                    selectedSession = session;
+                    break;
+                }
+            }
+
+            if (selectedSession == null) {
+                throw new CoreException(new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.LttngRelaydConsumer_SessionNotFound));
+            }
+
+            CreateSessionResponse createSession = fRelayd.createSession();
+            if (createSession.getStatus() != CreateSessionReturnCode.LTTNG_VIEWER_CREATE_SESSION_OK) {
+                throw new CoreException(new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.LttngRelaydConsumer_CreateViewerSessionError + createSession.getStatus().toString()));
+            }
+
+            AttachSessionResponse attachedSession = fRelayd.attachToSession(selectedSession);
+            if (attachedSession.getStatus() != AttachReturnCode.VIEWER_ATTACH_OK) {
+                throw new CoreException(new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.LttngRelaydConsumer_AttachSessionError + attachedSession.getStatus().toString()));
+            }
+
+            String metadata = fRelayd.getMetadata(attachedSession);
+            if (metadata == null) {
+                throw new CoreException(new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.LttngRelaydConsumer_NoMetadata));
+            }
+
+            List<StreamResponse> attachedStreams = attachedSession.getStreamList();
+            if (attachedStreams.isEmpty()) {
+                throw new CoreException(new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.LttngRelaydConsumer_NoStreams));
+            }
+
+            fTracePath = nullTerminatedByteArrayToString(attachedStreams.get(0).getPathName().getBytes());
+
+            fSession = attachedSession;
+        } catch (IOException e) {
+            throw new CoreException(new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.LttngRelaydConsumer_ErrorConnecting + (e.getMessage() != null ? e.getMessage() : ""))); //$NON-NLS-1$
+        }
+    }
+
+    /**
+     * Run the consumer operation for a give trace.
+     *
+     * @param trace
+     *            the trace
+     */
+    public void run(final CtfTmfTrace trace) {
+        if (fSession == null) {
+            return;
+        }
+
+        fCtfTmfTrace = trace;
+        fConsumerJob = new Job("RelayD consumer") { //$NON-NLS-1$
+
+            @Override
+            protected IStatus run(final IProgressMonitor monitor) {
+                try {
+                    while (!monitor.isCanceled()) {
+                        List<StreamResponse> attachedStreams = fSession.getStreamList();
+                        for (StreamResponse stream : attachedStreams) {
+                            if (stream.getMetadataFlag() != 1) {
+                                IndexResponse indexReply = fRelayd.getNextIndex(stream);
+                                if (indexReply.getStatus() == NextIndexReturnCode.VIEWER_INDEX_OK) {
+                                    long nanoTimeStamp = fCtfTmfTrace.timestampCyclesToNanos(indexReply.getTimestampEnd());
+                                    if (nanoTimeStamp > fTimestampEnd) {
+                                        TmfNanoTimestamp endTime = new TmfNanoTimestamp(nanoTimeStamp);
+                                        TmfTimeRange range = new TmfTimeRange(fCtfTmfTrace.getStartTime(), endTime);
+
+                                        long currentTime = System.nanoTime();
+                                        if (currentTime - fLastSignal > SIGNAL_THROTTLE_NANOSEC) {
+                                            TmfTraceRangeUpdatedSignal signal = new TmfTraceRangeUpdatedSignal(LttngRelaydConsumer.this, fCtfTmfTrace, range);
+                                            fCtfTmfTrace.broadcastAsync(signal);
+                                            fLastSignal = currentTime;
+                                        }
+                                        fTimestampEnd = nanoTimeStamp;
+                                    }
+                                } else if (indexReply.getStatus() == NextIndexReturnCode.VIEWER_INDEX_HUP) {
+                                    // The trace is now complete because the trace session was destroyed
+                                    fCtfTmfTrace.setComplete(true);
+                                    TmfTraceRangeUpdatedSignal signal = new TmfTraceRangeUpdatedSignal(LttngRelaydConsumer.this, fCtfTmfTrace, new TmfTimeRange(fCtfTmfTrace.getStartTime(), new TmfNanoTimestamp(fTimestampEnd)));
+                                    fCtfTmfTrace.broadcastAsync(signal);
+                                    return Status.OK_STATUS;
+                                }
+                            }
+                        }
+                    }
+                } catch (IOException e) {
+                    Activator.getDefault().logError("Error during live trace reading", e); //$NON-NLS-1$
+                    return new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.LttngRelaydConsumer_ErrorLiveReading + (e.getMessage() != null ? e.getMessage() : "")); //$NON-NLS-1$
+                }
+
+                return Status.OK_STATUS;
+            }
+        };
+        fConsumerJob.setSystem(true);
+        fConsumerJob.schedule();
+    }
+
+    /**
+     * Dispose the consumer and it's resources (sockets, etc).
+     */
+    public void dispose() {
+        try {
+            if (fConsumerJob != null) {
+                fConsumerJob.cancel();
+                fConsumerJob.join();
+            }
+            if (fConnection != null) {
+                fConnection.close();
+            }
+            if (fRelayd != null) {
+                fRelayd.close();
+            }
+        } catch (IOException e) {
+            // Ignore
+        } catch (InterruptedException e) {
+            // Ignore
+        }
+    }
+
+    /**
+     * Once the consumer is connected to the relayd session, it knows the trace
+     * path. This can be useful to know exactly where the trace is so that it
+     * can be imported into the workspace and it can be opened.
+     *
+     * @return the trace path
+     */
+    public String getTracePath() {
+        return fTracePath;
+    }
+
+    private static String nullTerminatedByteArrayToString(final byte[] byteArray) throws UnsupportedEncodingException {
+        // Find length of null terminated string
+        int length = 0;
+        while (length < byteArray.length && byteArray[length] != 0) {
+            length++;
+        }
+
+        String asessionName = new String(byteArray, 0, length, ENCODING_UTF_8);
+        return asessionName;
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/relayd/Messages.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/relayd/Messages.java
new file mode 100644 (file)
index 0000000..9632cd5
--- /dev/null
@@ -0,0 +1,71 @@
+/**********************************************************************
+ * Copyright (c) 2014 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:
+ *   Marc-Andre Laperle - Initial implementation
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.ui.relayd;
+
+import org.eclipse.osgi.util.NLS;
+
+/**
+ * Messages for the relayd connection.
+ *
+ * @author Marc-Andre Laperle
+ */
+public final class Messages extends NLS {
+    private static final String BUNDLE_NAME = "org.eclipse.tracecompass.internal.lttng2.control.ui.relayd.messages"; //$NON-NLS-1$
+
+    /**
+     * Error occurred establishing the connection.
+     */
+    public static String LttngRelaydConnectionManager_ConnectionError;
+
+    /**
+     * Error occurred attaching to the session.
+     */
+    public static String LttngRelaydConsumer_AttachSessionError;
+
+    /**
+     * Error occurred creating the viewer session.
+     */
+    public static String LttngRelaydConsumer_CreateViewerSessionError;
+
+    /**
+     * Error occurred connecting to the relayd.
+     */
+    public static String LttngRelaydConsumer_ErrorConnecting;
+
+    /**
+     * Error (generic) during live reading.
+     */
+    public static String LttngRelaydConsumer_ErrorLiveReading;
+
+    /**
+     * No metadata for this trace session.
+     */
+    public static String LttngRelaydConsumer_NoMetadata;
+
+    /**
+     * No streams for this trace session.
+     */
+    public static String LttngRelaydConsumer_NoStreams;
+
+    /**
+     * The session was not found by the relayd.
+     */
+    public static String LttngRelaydConsumer_SessionNotFound;
+    static {
+        // initialize resource bundle
+        NLS.initializeMessages(BUNDLE_NAME, Messages.class);
+    }
+
+    private Messages() {
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/relayd/messages.properties b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/relayd/messages.properties
new file mode 100644 (file)
index 0000000..e76b1d2
--- /dev/null
@@ -0,0 +1,20 @@
+###############################################################################
+# Copyright (c) 2014 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:
+#   Marc-Andre Laperle - initial API and implementation
+###############################################################################
+
+LttngRelaydConnectionManager_ConnectionError=The connection to the relayd could not be established. The trace cannot be opened in Live mode.
+LttngRelaydConsumer_AttachSessionError=Error, could not attach to session, error code: 
+LttngRelaydConsumer_CreateViewerSessionError=Error, could not create viewer session, error code: 
+LttngRelaydConsumer_ErrorConnecting=Error connecting to live trace session.
+LttngRelaydConsumer_ErrorLiveReading=Error during live trace reading.
+LttngRelaydConsumer_NoMetadata=Error, trace has no metadata.
+LttngRelaydConsumer_NoStreams=Error, has no streams.
+LttngRelaydConsumer_SessionNotFound=Error, live session not found
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/ControlView.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/ControlView.java
new file mode 100644 (file)
index 0000000..a25d4cf
--- /dev/null
@@ -0,0 +1,247 @@
+/*******************************************************************************
+ * Copyright (c) 2009, 2015 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:
+ *   Francois Chouinard - Initial API and implementation
+ *   Bernd Hufmann - Filled with content
+ *   Markus Schorn - Bug 448058: Use org.eclipse.remote in favor of RSE
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.core.runtime.IStatus;
+import org.eclipse.core.runtime.Status;
+import org.eclipse.jface.action.MenuManager;
+import org.eclipse.jface.viewers.ColumnViewerToolTipSupport;
+import org.eclipse.jface.viewers.ISelection;
+import org.eclipse.jface.viewers.StructuredSelection;
+import org.eclipse.jface.viewers.TreeViewer;
+import org.eclipse.remote.core.IRemoteConnection;
+import org.eclipse.swt.SWT;
+import org.eclipse.swt.widgets.Composite;
+import org.eclipse.swt.widgets.Menu;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponentChangedListener;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceControlContentProvider;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceControlLabelProvider;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceControlRoot;
+import org.eclipse.tracecompass.tmf.remote.core.proxy.TmfRemoteConnectionFactory;
+import org.eclipse.ui.IMemento;
+import org.eclipse.ui.IViewSite;
+import org.eclipse.ui.PartInitException;
+import org.eclipse.ui.part.ViewPart;
+import org.eclipse.ui.progress.UIJob;
+
+/**
+ * <p>
+ * View implementation for Trace Control.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class ControlView extends ViewPart implements ITraceControlComponentChangedListener {
+
+    // ------------------------------------------------------------------------
+    // Constants
+    // ------------------------------------------------------------------------
+
+    /**
+     * View ID.
+     */
+    public static final String ID = "org.eclipse.linuxtools.internal.lttng2.ui.views.control"; //$NON-NLS-1$
+
+    private static final String KEY_REMOTE_CONNECTION_NAME = "rc_name_"; //$NON-NLS-1$
+    private static final String KEY_REMOTE_PROVIDER = "rc_id_"; //$NON-NLS-1$
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+
+    /**
+     * The tree viewer.
+     */
+    private TreeViewer fTreeViewer = null;
+
+    /**
+     * The trace control root node. This provides access to the whole model.
+     */
+    private ITraceControlComponent fRoot = null;
+
+    private List<IRemoteConnection> fInitialConnections;
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    /**
+     * Returns the trace control tree node (model)
+     *
+     * @return the trace control tree node (model).
+     */
+    public ITraceControlComponent getTraceControlRoot() {
+        return fRoot;
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    public void createPartControl(Composite parent) {
+        // Create tree viewer
+        fTreeViewer = new TreeViewer(parent, SWT.MULTI | SWT.H_SCROLL | SWT.V_SCROLL);
+        ColumnViewerToolTipSupport.enableFor(fTreeViewer);
+
+        fTreeViewer.setContentProvider(new TraceControlContentProvider());
+        fTreeViewer.setLabelProvider(new TraceControlLabelProvider());
+
+        // Create model root
+        fRoot = new TraceControlRoot();
+        fRoot.addComponentListener(this);
+        if (fInitialConnections != null) {
+            for (IRemoteConnection rc : fInitialConnections) {
+                TargetNodeComponent node = new TargetNodeComponent(rc.getName(), fRoot, rc);
+                fRoot.addChild(node);
+            }
+            fInitialConnections = null;
+        }
+        fTreeViewer.setInput(fRoot);
+
+        // Create context menu for the tree viewer
+        createContextMenu();
+
+        getSite().setSelectionProvider(fTreeViewer);
+    }
+
+    @Override
+    public void saveState(IMemento memento) {
+        int i = 0;
+        for (ITraceControlComponent cmp : fRoot.getChildren()) {
+            if (cmp instanceof TargetNodeComponent) {
+                IRemoteConnection rc = ((TargetNodeComponent) cmp).getRemoteSystemProxy().getRemoteConnection();
+                memento.putString(KEY_REMOTE_PROVIDER + i, rc.getConnectionType().getId());
+                memento.putString(KEY_REMOTE_CONNECTION_NAME + i, rc.getName());
+                i++;
+            }
+        }
+        super.saveState(memento);
+    }
+
+
+    @Override
+    public void init(IViewSite site, IMemento memento) throws PartInitException {
+        super.init(site, memento);
+        if (memento != null) {
+            fInitialConnections = new ArrayList<>();
+            for(int i = 0; ; i++) {
+                String id = memento.getString(KEY_REMOTE_PROVIDER + i);
+                String name = memento.getString(KEY_REMOTE_CONNECTION_NAME + i);
+                if ((id == null) || (name == null)) {
+                    break;
+                }
+                IRemoteConnection conn = TmfRemoteConnectionFactory.getRemoteConnection(id, name);
+                if (conn != null) {
+                    fInitialConnections.add(conn);
+                }
+            }
+        }
+    }
+
+    @Override
+    public void setFocus() {
+        fTreeViewer.getControl().setFocus();
+    }
+
+    @Override
+    public void componentAdded(ITraceControlComponent parent, ITraceControlComponent component) {
+        componentChanged(parent);
+    }
+
+    @Override
+    public void componentRemoved(ITraceControlComponent parent, ITraceControlComponent component) {
+        componentChanged(parent);
+    }
+
+    @Override
+    public void componentChanged(final ITraceControlComponent component) {
+        if (fTreeViewer.getTree().isDisposed()) {
+            return;
+        }
+
+        UIJob myJob = new UIJob("Refresh") { //$NON-NLS-1$
+            @Override
+            public IStatus runInUIThread(IProgressMonitor monitor) {
+                if (fTreeViewer.getTree().isDisposed()) {
+                    return Status.OK_STATUS;
+                }
+
+                fTreeViewer.refresh(component);
+
+                // Change selection needed
+                final ISelection sel = fTreeViewer.getSelection();
+                fTreeViewer.setSelection(null);
+                fTreeViewer.setSelection(sel);
+
+                // Show component that was changed
+                fTreeViewer.reveal(component);
+
+                return Status.OK_STATUS;
+            }
+        };
+        myJob.setUser(false);
+        myJob.setSystem(true);
+        myJob.schedule();
+    }
+
+    /**
+     * Sets the selected component in the tree
+     * @param component - component to select
+     */
+    public void setSelection(ITraceControlComponent component) {
+        ITraceControlComponent[] components = new ITraceControlComponent[1];
+        components[0] = component;
+        setSelection(components);
+    }
+
+    /**
+     * Sets the selected components in the tree
+     * @param components - array of components to select
+     */
+    public void setSelection(ITraceControlComponent[] components) {
+        final StructuredSelection selection = new StructuredSelection(components);
+        UIJob myJob = new UIJob("Select") { //$NON-NLS-1$
+            @Override
+            public IStatus runInUIThread(IProgressMonitor monitor) {
+                fTreeViewer.setSelection(selection);
+                return Status.OK_STATUS;
+            }
+        };
+        myJob.setUser(false);
+        myJob.schedule();
+    }
+
+    // ------------------------------------------------------------------------
+    // Helper methods
+    // ------------------------------------------------------------------------
+    /**
+     * Creates the context sensitive menu.
+     */
+    private void createContextMenu() {
+        // First we create a menu Manager
+        final MenuManager menuManager = new MenuManager();
+        final Menu menu = menuManager.createContextMenu(fTreeViewer.getTree());
+        // Set the MenuManager
+        fTreeViewer.getTree().setMenu(menu);
+        getSite().registerContextMenu(menuManager, fTreeViewer);
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/AddContextDialog.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/AddContextDialog.java
new file mode 100644 (file)
index 0000000..7e2fa71
--- /dev/null
@@ -0,0 +1,420 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
+
+import java.util.ArrayList;
+import java.util.Iterator;
+import java.util.List;
+
+import org.eclipse.jface.dialogs.Dialog;
+import org.eclipse.jface.dialogs.IDialogConstants;
+import org.eclipse.jface.viewers.CheckStateChangedEvent;
+import org.eclipse.jface.viewers.CheckboxTreeViewer;
+import org.eclipse.jface.viewers.ColumnLabelProvider;
+import org.eclipse.jface.viewers.ICheckStateListener;
+import org.eclipse.jface.viewers.ITreeContentProvider;
+import org.eclipse.jface.viewers.Viewer;
+import org.eclipse.swt.SWT;
+import org.eclipse.swt.graphics.Point;
+import org.eclipse.swt.layout.GridData;
+import org.eclipse.swt.layout.GridLayout;
+import org.eclipse.swt.widgets.Composite;
+import org.eclipse.swt.widgets.Control;
+import org.eclipse.swt.widgets.Group;
+import org.eclipse.swt.widgets.Shell;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
+
+/**
+ * <p>
+ * Dialog box for collecting information about contexts to be added to channels/events.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class AddContextDialog extends Dialog implements IAddContextDialog  {
+
+    // ------------------------------------------------------------------------
+    // Constants
+    // ------------------------------------------------------------------------
+
+    /**
+     * The icon file for this dialog box.
+     */
+    public static final String ADD_CONTEXT_ICON_FILE = "icons/elcl16/add-context.gif"; //$NON-NLS-1$
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+
+    /**
+     * A tree viewer for displaying and selection of available contexts.
+     */
+    private CheckboxTreeViewer fContextsViewer;
+
+    /**
+     * A Tree model for the checkbox tree viewer.
+     */
+    private final ContextModel fContextModel = new ContextModel();
+
+    /**
+     * The contexts to add.
+     */
+    private final List<String> fSelectedContexts = new ArrayList<>();
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+
+    /**
+     * Constructor
+     * @param shell - a shell for the display of the dialog
+     */
+    public AddContextDialog(Shell shell) {
+        super(shell);
+        setShellStyle(SWT.RESIZE | getShellStyle());
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    @Override
+    public void setAvalibleContexts(List<String> contexts) {
+        fContextModel.setAvalibleContexts(contexts);
+    }
+
+    @Override
+    public List<String> getContexts() {
+        List<String> ret = new ArrayList<>();
+        ret.addAll(fSelectedContexts);
+        return ret;
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    protected void configureShell(Shell newShell) {
+        super.configureShell(newShell);
+        newShell.setText(Messages.TraceControl_AddContextDialogTitle);
+        newShell.setImage(Activator.getDefault().loadIcon(ADD_CONTEXT_ICON_FILE));
+    }
+
+    @Override
+    protected Control createDialogArea(Composite parent) {
+
+        // Main dialog panel
+        Composite dialogComposite = new Composite(parent, SWT.NONE);
+        GridLayout layout = new GridLayout(1, true);
+        dialogComposite.setLayout(layout);
+        dialogComposite.setLayoutData(new GridData(GridData.FILL_BOTH));
+
+        // Contexts list
+        Group contextGroup = new Group(dialogComposite, SWT.SHADOW_NONE);
+        contextGroup.setText(Messages.TraceControl_AddContextAvailableContextsLabel);
+        layout = new GridLayout(1, true);
+        contextGroup.setLayout(layout);
+        contextGroup.setLayoutData(new GridData(GridData.FILL_BOTH));
+
+        fContextsViewer = new CheckboxTreeViewer(contextGroup, SWT.MULTI | SWT.H_SCROLL | SWT.V_SCROLL);
+        fContextsViewer.getTree().setToolTipText(Messages.TraceControl_AddContextAvailableContextsTooltip);
+
+        fContextsViewer.setContentProvider(new ContextsContentProvider());
+        fContextsViewer.setLabelProvider(new ContextsLabelProvider());
+        fContextsViewer.addCheckStateListener(new ContextCheckListener());
+        fContextsViewer.setInput(fContextModel);
+        fContextsViewer.getTree().setLayoutData(new GridData(GridData.FILL_BOTH));
+
+        getShell().setMinimumSize(new Point(500, 450));
+
+        return dialogComposite;
+    }
+
+    @Override
+    protected void createButtonsForButtonBar(Composite parent) {
+        createButton(parent, IDialogConstants.CANCEL_ID, "&Cancel", true); //$NON-NLS-1$
+        createButton(parent, IDialogConstants.OK_ID, "&Ok", true); //$NON-NLS-1$
+    }
+
+    @Override
+    protected void okPressed() {
+        fSelectedContexts.clear();
+
+        Object[] checkedElements = fContextsViewer.getCheckedElements();
+        for (int i = 0; i < checkedElements.length; i++) {
+            IContextModelComponent component = (IContextModelComponent)checkedElements[i];
+            if (!Messages.TraceControl_AddContextAllLabel.equals(component.getName())) {
+                fSelectedContexts.add(component.getName());
+            }
+        }
+
+        // validation successful -> call super.okPressed()
+        super.okPressed();
+    }
+
+    // ------------------------------------------------------------------------
+    // Helper classes and methods
+    // ------------------------------------------------------------------------
+    /**
+     * Content provider for the contexts tree
+     */
+    public static final class ContextsContentProvider implements ITreeContentProvider {
+
+        @Override
+        public void dispose() {
+        }
+
+        @Override
+        public void inputChanged(Viewer viewer, Object oldInput, Object newInput) {
+        }
+
+        @Override
+        public Object[] getElements(Object inputElement) {
+            return getChildren(inputElement);
+        }
+
+        @Override
+        public Object[] getChildren(Object parentElement) {
+            if (parentElement instanceof IContextModelComponent) {
+                return ((IContextModelComponent)parentElement).getChildren();
+            }
+            return null;
+        }
+
+        @Override
+        public Object getParent(Object element) {
+            if (element instanceof IContextModelComponent) {
+                return ((IContextModelComponent)element).getParent();
+            }
+            return null;
+        }
+
+        @Override
+        public boolean hasChildren(Object element) {
+            if (element instanceof IContextModelComponent) {
+                return ((IContextModelComponent)element).hasChildren();
+            }
+            return false;
+        }
+    }
+
+    /**
+     * Label provider for the contexts tree
+     */
+    public static final class ContextsLabelProvider extends ColumnLabelProvider {
+        @Override
+        public String getText(Object element) {
+
+            if ((element != null) && (element instanceof IContextModelComponent)) {
+                return ((IContextModelComponent)element).getName();
+            }
+
+            return "";//$NON-NLS-1$
+        }
+    }
+
+    /**
+     * Check state listener for the contexts tree.
+     */
+    public final class ContextCheckListener implements ICheckStateListener {
+        @Override
+        public void checkStateChanged(CheckStateChangedEvent event) {
+          if (event.getChecked()) {
+              if (event.getElement() instanceof AllContexts) {
+                  fContextsViewer.setSubtreeChecked(event.getElement(), true);
+              }
+          } else {
+              if (event.getElement() instanceof AllContexts) {
+                  fContextsViewer.setSubtreeChecked(event.getElement(), false);
+              } else {
+                  IContextModelComponent component = (IContextModelComponent) event.getElement();
+                  fContextsViewer.setChecked(component.getParent(), false);
+              }
+          }
+        }
+    }
+
+    /**
+     * Model for the context tree viewer (root component)
+     */
+    public static class ContextModel implements IContextModelComponent {
+
+        private final AllContexts fAllContexts;
+
+        /**
+         * Constructor
+         */
+        public ContextModel() {
+            fAllContexts = new AllContexts(this);
+        }
+
+        /**
+         * Sets the available contexts
+         *
+         * @param contexts
+         *            The contexts to set
+         */
+        public void setAvalibleContexts(List<String> contexts) {
+            fAllContexts.setAvalibleContexts(contexts);
+        }
+
+        @Override
+        public String getName() {
+            return "root"; //$NON-NLS-1$
+        }
+
+        @Override
+        public Object getParent() {
+            return null;
+        }
+
+        @Override
+        public Object[] getChildren() {
+            Object[] ret = new Object[1];
+            ret[0] = fAllContexts;
+            return ret;
+        }
+
+        @Override
+        public boolean hasChildren() {
+            return true;
+        }
+    }
+
+    /**
+     * Model element (to select/deselect) all contexts) for the context tree viewer
+     */
+    public static class AllContexts implements IContextModelComponent {
+        /**
+         * The available list of contexts.
+         */
+        private List<Context> fAvailableContexts;
+
+        private final IContextModelComponent fParent;
+
+        /**
+         * Constructor
+         *
+         * @param parent
+         *            The parent component
+         */
+        public AllContexts(IContextModelComponent parent) {
+            fParent = parent;
+        }
+
+        /**
+         * Sets the available contexts
+         *
+         * @param contexts
+         *            The contexts to set
+         */
+        public void setAvalibleContexts(List<String> contexts) {
+            fAvailableContexts = new ArrayList<>();
+            if (contexts != null) {
+                for (Iterator<String> iterator = contexts.iterator(); iterator.hasNext();) {
+                    String name = iterator.next();
+                    fAvailableContexts.add(new Context(this, name));
+                }
+            }
+        }
+
+        @Override
+        public String getName() {
+            return Messages.TraceControl_AddContextAllLabel;
+        }
+
+        @Override
+        public Object[] getChildren() {
+            return fAvailableContexts.toArray();
+        }
+
+        @Override
+        public Object getParent() {
+            return fParent;
+        }
+
+        @Override
+        public boolean hasChildren() {
+            return true;
+        }
+    }
+
+    /**
+     * Model element (the context) for the context tree viewer
+     */
+    public static class Context implements IContextModelComponent {
+
+        private final String fContextName;
+        private final IContextModelComponent fParent;
+
+        /**
+         * Constructor
+         *
+         * @param parent
+         *            The parent component
+         * @param name
+         *            The name of this context
+         */
+        public Context(IContextModelComponent parent, String name) {
+            fParent = parent;
+            fContextName = name;
+        }
+
+        @Override
+        public String getName() {
+            return fContextName;
+        }
+
+        @Override
+        public Object getParent() {
+            return fParent;
+        }
+
+        @Override
+        public Object[] getChildren() {
+            return null;
+        }
+
+        @Override
+        public boolean hasChildren() {
+            return false;
+        }
+    }
+
+    /**
+     * Interface for the tree model used for the context tree viewer.
+     */
+    public interface IContextModelComponent {
+
+        /**
+         * @return The name of this component
+         */
+        String getName();
+
+        /**
+         * @return The parent component
+         */
+        Object getParent();
+
+        /**
+         * @return The array of children of this component
+         */
+        Object[] getChildren();
+
+        /**
+         * @return If this component has children or not
+         */
+        boolean hasChildren();
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/ConfirmDialog.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/ConfirmDialog.java
new file mode 100644 (file)
index 0000000..e665de5
--- /dev/null
@@ -0,0 +1,36 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
+
+
+import org.eclipse.jface.dialogs.MessageDialog;
+import org.eclipse.swt.widgets.Shell;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
+
+/**
+ * <p>
+ * Confirmation dialog implementation.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+
+public class ConfirmDialog implements IConfirmDialog {
+
+    @Override
+    public boolean openConfirm(Shell parent, String title, String message) {
+        return MessageDialog.openConfirm(parent,
+                Messages.TraceControl_DestroyConfirmationTitle,
+                Messages.TraceControl_DestroyConfirmationMessage);
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/CreateSessionDialog.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/CreateSessionDialog.java
new file mode 100644 (file)
index 0000000..39b0c8a
--- /dev/null
@@ -0,0 +1,1027 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2015 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
+ *   Marc-Andre Laperle - Support for creating a live session
+ *   Markus Schorn - Bug 448058: Use org.eclipse.remote in favor of RSE
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
+
+import org.eclipse.core.filesystem.IFileInfo;
+import org.eclipse.core.filesystem.IFileStore;
+import org.eclipse.jface.dialogs.IDialogConstants;
+import org.eclipse.jface.dialogs.TitleAreaDialog;
+import org.eclipse.remote.core.IRemoteFileService;
+import org.eclipse.swt.SWT;
+import org.eclipse.swt.custom.CCombo;
+import org.eclipse.swt.events.FocusEvent;
+import org.eclipse.swt.events.FocusListener;
+import org.eclipse.swt.events.ModifyEvent;
+import org.eclipse.swt.events.ModifyListener;
+import org.eclipse.swt.events.SelectionAdapter;
+import org.eclipse.swt.events.SelectionEvent;
+import org.eclipse.swt.events.VerifyEvent;
+import org.eclipse.swt.events.VerifyListener;
+import org.eclipse.swt.layout.GridData;
+import org.eclipse.swt.layout.GridLayout;
+import org.eclipse.swt.widgets.Button;
+import org.eclipse.swt.widgets.Composite;
+import org.eclipse.swt.widgets.Control;
+import org.eclipse.swt.widgets.Group;
+import org.eclipse.swt.widgets.Label;
+import org.eclipse.swt.widgets.Shell;
+import org.eclipse.swt.widgets.Text;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISessionInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.SessionInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionGroup;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.service.LTTngControlServiceConstants;
+import org.eclipse.tracecompass.tmf.remote.core.proxy.RemoteSystemProxy;
+
+/**
+ * <p>
+ * Dialog box for collecting session creation information.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class CreateSessionDialog extends TitleAreaDialog implements ICreateSessionDialog {
+
+    // ------------------------------------------------------------------------
+    // Constants
+    // ------------------------------------------------------------------------
+    /**
+     * The icon file for this dialog box.
+     */
+    public static final String CREATE_SESSION_ICON_FILE = "icons/elcl16/add_button.gif"; //$NON-NLS-1$
+
+    /**
+     *  To indicate that the default value will be used for this field
+     */
+    private static final String DEFAULT_TEXT = "<" + Messages.EnableChannelDialog_DefaultMessage + ">"; //$NON-NLS-1$ //$NON-NLS-2$
+
+    /**
+     * Supported network protocols for streaming
+     */
+    private enum StreamingProtocol {
+        /** Default network protocol for IPv4 (TCP)*/
+        net,
+        /** Default network protocol for IPv6 (TCP)*/
+        net6,
+        /** File */
+        file,
+   }
+
+    /**
+     * Supported network protocols for Live tracing
+     */
+    private enum LiveProtocol {
+        /** Default network protocol for IPv4 (TCP)*/
+        net,
+        /** Default network protocol for IPv6 (TCP)*/
+        net6
+   }
+
+    private enum StreamingProtocol2 {
+        /** Default network protocol for IPv4 (TCP)*/
+        net,
+        /** Default network protocol for IPv6 (TCP)*/
+        net6,
+        /** TCP network protocol for IPv4*/
+        tcp,
+        /** TCP network protocol for IPv6*/
+        tcp6 }
+
+    /**
+     * Index of last supported streaming protocol for common URL configuration.
+     */
+    private static final int COMMON_URL_LAST_INDEX = 1;
+    /**
+     *  Index of default streaming protocol.
+     */
+    private static final int DEFAULT_URL_INDEX = 0;
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+    /**
+     * The dialog composite.
+     */
+    private Composite fDialogComposite = null;
+    /**
+     * The text widget for the session name
+     */
+    private Text fSessionNameText = null;
+    /**
+     * The label widget for the session path.
+     */
+    private Label fSessionPathLabel = null;
+    /**
+     * The text widget for the session path.
+     */
+    private Text fSessionPathText = null;
+    /**
+     * The button widget to select a normal session
+     */
+    private Button fNormalModeButton = null;
+    /**
+     * The button widget to select a snapshot session
+     */
+    private Button fSnapshotButton = null;
+    /**
+     * The group that contains the mutually exclusive mode buttons
+     */
+    private Group fModeButtonGroup = null;
+    /**
+     * The button widget to select a live session
+     */
+    private Button fLiveButton = null;
+
+    /**
+     * The text widget to set a live delay
+     */
+    private Text fLiveDelayText = null;
+    /**
+     * The Group for advanced configuration.
+     */
+    private Group fAdvancedGroup = null;
+    /**
+     * The button to show advanced options.
+     */
+    private Button fAdvancedButton = null;
+    /**
+     * The composite with streaming configuration parameter.
+     */
+    private Composite fStreamingComposite = null;
+    /**
+     * The text widget for the trace path.
+     */
+    private Text fTracePathText = null;
+    /**
+     * The button to link data protocol/Address with control protocol.
+     */
+    private Button fLinkDataWithControlButton = null;
+    /**
+     * The Combo box for channel protocol selection.
+     */
+     private CCombo fControlProtocolCombo = null;
+    /**
+     * A selection listener that copies the protocol from control to data when being linked.
+     */
+    private ControlProtocolSelectionListener fCopyProtocolSelectionListener;
+    /**
+     * A selection listener updates the control port text depending on the control protocol selected.
+     */
+    private ProtocolComboSelectionListener fControlProtocolSelectionListener;
+    /**
+     * A selection listener updates the data port text depending on the data protocol selected.
+     */
+    private ProtocolComboSelectionListener fDataProtocolSelectionListener;
+    /**
+     * The text box for the host/IP address of the control channel.
+     */
+    private Text fControlHostAddressText = null;
+    /**
+     * A key listener that copies the host address from control to data when being linked.
+     */
+    private CopyModifyListener fControlUrlKeyListener;
+    /**
+     * A modify listener that updates the enablement of the dialog.
+     */
+    private UpdateEnablementModifyListener fUpdateEnablementModifyListener;
+    /**
+     * The text box for the control port.
+     */
+    private Text fControlPortText = null;
+    /**
+     * The Combo box for data protocol selection.
+     */
+     private CCombo fDataProtocolCombo = null;
+    /**
+     * The text box for the host/IP address of the data channel.
+     */
+    private Text fDataHostAddressText = null;
+    /**
+     * The text box for the data port.
+     */
+    private Text fDataPortText = null;
+    /**
+     * The parent where the new node should be added.
+     */
+    private TraceSessionGroup fParent = null;
+    /**
+     * The session name string.
+     */
+    private String fSessionName = ""; //$NON-NLS-1$;
+    /**
+     * The  session path string.
+     */
+    private String fSessionPath = null;
+    /**
+     * Flag whether the session is snapshot or not
+     */
+    private boolean fIsSnapshot = false;
+    /**
+     * Flag whether the session is live or not
+     */
+    private boolean fIsLive = false;
+    /**
+     * The text box for the live address (relayd).
+     */
+    private Text fLiveHostAddressText = null;
+    /**
+     * The text box for the live port (relayd).
+     */
+    private Text fLivePortText = null;
+    /**
+     * The live delay
+     */
+    private Long fLiveDelay = 0L;
+    /**
+     * The live url.
+     */
+    private String fLiveUrl = null;
+    /**
+     * The live port.
+     */
+    private Integer fLivePort = 0;
+    /**
+     * Flag whether default location (path) shall be used or not
+     */
+    private boolean fIsDefaultPath = true;
+    /**
+     * Flag whether the advanced options are enabled or not
+     */
+    private boolean fIsAdvancedEnabled = false;
+    /**
+     * The network URL in case control and data is configured together.
+     * If set, fControlUrl and fDataUrl will be null.
+     */
+    private String fNetworkUrl = null;
+    /**
+     * The control URL in case control and data is configured separately.
+     * If set, fDataUrl will be set too and fNetworkUrl will be null.
+     */
+    private String fControlUrl = null;
+    /**
+     * The data URL in case control and data is configured separately.
+     * If set, fControlUrl will be set too and fNetworkUrl will be null.
+     */
+    private String fDataUrl = null;
+    /**
+     * The trace path string.
+     */
+    private String fTracePath = null;
+    /**
+     * The Group for advanced configuration of Live mode.
+     */
+    private Group fLiveGroup = null;
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+    /**
+     * Constructor
+     * @param shell - a shell for the display of the dialog
+     */
+    public CreateSessionDialog(Shell shell) {
+        super(shell);
+        setShellStyle(SWT.RESIZE | getShellStyle());
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    @Override
+    public void initialize(TraceSessionGroup group) {
+       fParent = group;
+       fStreamingComposite = null;
+       fLiveGroup = null;
+       fLiveButton = null;
+       fIsLive = false;
+       fSnapshotButton = null;
+       fSessionName = ""; //$NON-NLS-1$
+       fSessionPath = null;
+       fIsSnapshot = false;
+       fIsDefaultPath = true;
+       fIsAdvancedEnabled = false;
+       fNetworkUrl = null;
+       fControlUrl = null;
+       fDataUrl = null;
+    }
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    protected void configureShell(Shell newShell) {
+        super.configureShell(newShell);
+        newShell.setText(Messages.TraceControl_CreateSessionDialogTitle);
+        newShell.setImage(Activator.getDefault().loadIcon(CREATE_SESSION_ICON_FILE));
+    }
+
+    @Override
+    protected Control createDialogArea(Composite parent) {
+        Composite dialogAreaa = (Composite) super.createDialogArea(parent);
+        setTitle(Messages.TraceControl_CreateSessionDialogTitle);
+        setMessage(Messages.TraceControl_CreateSessionDialogMessage);
+
+        // Main dialog panel
+        fDialogComposite = new Composite(dialogAreaa, SWT.NONE);
+        GridLayout layout = new GridLayout(1, true);
+        fDialogComposite.setLayout(layout);
+        fDialogComposite.setLayoutData(new GridData(GridData.FILL_BOTH));
+
+        Group sessionGroup = new Group(fDialogComposite, SWT.SHADOW_NONE);
+        sessionGroup.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
+        sessionGroup.setLayout(new GridLayout(4, true));
+
+        fUpdateEnablementModifyListener = new UpdateEnablementModifyListener();
+
+        Label sessionNameLabel = new Label(sessionGroup, SWT.RIGHT);
+        sessionNameLabel.setText(Messages.TraceControl_CreateSessionNameLabel);
+        fSessionNameText = new Text(sessionGroup, SWT.NONE);
+        fSessionNameText.setToolTipText(Messages.TraceControl_CreateSessionNameTooltip);
+        fSessionNameText.addModifyListener(fUpdateEnablementModifyListener);
+        GridData data = new GridData(GridData.FILL_HORIZONTAL);
+        data.horizontalSpan = 3;
+        fSessionNameText.setLayoutData(data);
+
+        fSessionPathLabel = new Label(sessionGroup, SWT.RIGHT);
+        fSessionPathLabel.setText(Messages.TraceControl_CreateSessionPathLabel);
+        fSessionPathText = new Text(sessionGroup, SWT.NONE);
+        fSessionPathText.setToolTipText(Messages.TraceControl_CreateSessionPathTooltip);
+        data = new GridData(GridData.FILL_HORIZONTAL);
+        data.horizontalSpan = 3;
+        fSessionPathText.setLayoutData(data);
+        fSessionPathText.addModifyListener(fUpdateEnablementModifyListener);
+
+        if (fParent.isSnapshotSupported() || fParent.isLiveSupported()) {
+            fModeButtonGroup = new Group(sessionGroup, SWT.NONE);
+            data = new GridData(GridData.FILL_HORIZONTAL);
+            data.horizontalSpan = 4;
+            fModeButtonGroup.setLayoutData(data);
+            fModeButtonGroup.setLayout(new GridLayout(3, true));
+
+            SelectionAdapter modeChangedListener = new SelectionAdapter() {
+                @Override
+                public void widgetSelected(SelectionEvent e) {
+                    if (fLiveButton != null) {
+                        if (fLiveButton.getSelection()) {
+                            createAdvancedLiveGroup();
+                            updateSessionPathEnablement();
+                            updateProtocolComboItems();
+                        } else {
+                            disposeLiveGroup();
+                            updateSessionPathEnablement();
+                            updateProtocolComboItems();
+                        }
+                    }
+                    updateEnablement();
+                }
+            };
+
+            fNormalModeButton = new Button(fModeButtonGroup, SWT.RADIO);
+            fNormalModeButton.setText(Messages.TraceControl_CreateSessionNormalLabel);
+            fNormalModeButton.setToolTipText(Messages.TraceControl_CreateSessionNormalTooltip);
+            fNormalModeButton.setSelection(true);
+            fNormalModeButton.addSelectionListener(modeChangedListener);
+
+            if (fParent.isSnapshotSupported()) {
+                fSnapshotButton = new Button(fModeButtonGroup, SWT.RADIO);
+                fSnapshotButton.setText(Messages.TraceControl_CreateSessionSnapshotLabel);
+                fSnapshotButton.setToolTipText(Messages.TraceControl_CreateSessionSnapshotTooltip);
+                fSnapshotButton.addSelectionListener(modeChangedListener);
+            }
+
+            if (fParent.isLiveSupported()) {
+                fLiveButton = new Button(fModeButtonGroup, SWT.RADIO);
+                fLiveButton.setText(Messages.TraceControl_CreateSessionLiveLabel);
+                fLiveButton.setToolTipText(Messages.TraceControl_CreateSessionLiveTooltip);
+                fLiveButton.addSelectionListener(modeChangedListener);
+            }
+        }
+
+        if (fParent.isNetworkStreamingSupported() || fParent.isLiveSupported()) {
+            createAdvancedOptionsComposite();
+        }
+
+        return fDialogComposite;
+    }
+
+    private void createAdvancedOptionsComposite() {
+
+        fAdvancedGroup = new Group(fDialogComposite, SWT.SHADOW_NONE);
+        fAdvancedGroup.setLayoutData(new GridData(GridData.FILL_BOTH));
+        fAdvancedGroup.setLayout(new GridLayout(1, true));
+
+        fAdvancedButton = new Button(fAdvancedGroup, SWT.PUSH);
+        fAdvancedButton.setText(Messages.TraceControl_CreateSessionConfigureStreamingButtonText + " >>>"); //$NON-NLS-1$
+        fAdvancedButton.setToolTipText(Messages.TraceControl_CreateSessionConfigureStreamingButtonTooltip);
+        fAdvancedButton.addSelectionListener(new SelectionAdapter() {
+            @Override
+            public void widgetSelected(SelectionEvent e) {
+                if (fIsAdvancedEnabled) {
+                    fIsAdvancedEnabled = false;
+                    fAdvancedButton.setText(">>> " + Messages.TraceControl_CreateSessionConfigureStreamingButtonText); //$NON-NLS-1$
+                    fAdvancedButton.setToolTipText(Messages.TraceControl_CreateSessionConfigureStreamingButtonTooltip);
+
+                    if (fParent.isNetworkStreamingSupported()) {
+                        updateSessionPathEnablement();
+                        disposeConfigureStreamingComposite();
+                    }
+
+                    if (fParent.isLiveSupported()) {
+                        disposeLiveGroup();
+                    }
+                } else {
+                    fIsAdvancedEnabled = true;
+                    fAdvancedButton.setText("<<< " + Messages.TraceControl_CreateSessionNoStreamingButtonText); //$NON-NLS-1$
+                    fAdvancedButton.setToolTipText(Messages.TraceControl_CreateSessionNoStreamingButtonTooltip);
+
+                    if (fParent.isNetworkStreamingSupported()) {
+                        updateSessionPathEnablement();
+                        createConfigureStreamingComposite();
+                    }
+                    if (fLiveButton != null && fLiveButton.getSelection()) {
+                        createAdvancedLiveGroup();
+                    }
+                }
+
+                updateEnablement();
+                getShell().pack();
+            }
+        });
+    }
+
+    private void updateSessionPathEnablement() {
+        if (fIsAdvancedEnabled || fIsLive) {
+            fSessionPathText.setEnabled(false);
+            fSessionPathText.setText(""); //$NON-NLS-1$
+            fSessionPathLabel.setText(""); //$NON-NLS-1$
+        } else {
+            fSessionPathText.setEnabled(true);
+            fSessionPathLabel.setText(Messages.TraceControl_CreateSessionPathLabel);
+        }
+    }
+
+    private void updateProtocolComboItems() {
+        if (fControlProtocolCombo == null || fControlProtocolCombo.isDisposed()) {
+            return;
+        }
+
+        int currentSelection = fControlProtocolCombo.getSelectionIndex() <= COMMON_URL_LAST_INDEX ?
+                fControlProtocolCombo.getSelectionIndex() : DEFAULT_URL_INDEX;
+
+        fControlProtocolCombo.removeAll();
+        Enum<? extends Enum<?>>[] values;
+        if (fIsLive) {
+            values = LiveProtocol.values();
+        } else if (fLinkDataWithControlButton.getSelection()) {
+            values = StreamingProtocol.values();
+        } else {
+            values = StreamingProtocol2.values();
+        }
+
+        String[] controlItems = new String[values.length];
+        for (int i = 0; i < controlItems.length; i++) {
+            controlItems[i] = values[i].name();
+        }
+        fControlProtocolCombo.setItems(controlItems);
+        fDataProtocolCombo.setItems(controlItems);
+
+        // Set selection
+        if (currentSelection != -1) {
+            fControlProtocolCombo.select(currentSelection);
+            fDataProtocolCombo.select(currentSelection);
+        }
+    }
+
+    private void createConfigureStreamingComposite() {
+        if (fStreamingComposite == null) {
+            fStreamingComposite = new Group(fAdvancedGroup, SWT.SHADOW_NONE);
+            GridLayout layout = new GridLayout(1, true);
+            fStreamingComposite.setLayout(layout);
+            fStreamingComposite.setLayoutData(new GridData(GridData.FILL_BOTH));
+
+            layout = new GridLayout(7, true);
+            fStreamingComposite.setLayout(layout);
+            fStreamingComposite.setLayoutData(new GridData(GridData.FILL_BOTH));
+
+            Label tracePathLabel = new Label(fStreamingComposite, SWT.RIGHT);
+            tracePathLabel.setText(Messages.TraceControl_CreateSessionTracePathText);
+            fTracePathText = new Text(fStreamingComposite, SWT.NONE);
+            fTracePathText.setToolTipText(Messages.TraceControl_CreateSessionTracePathTooltip);
+
+            // layout widgets
+            GridData data = new GridData(GridData.FILL_HORIZONTAL);
+            data.horizontalSpan = 6;
+            fTracePathText.setLayoutData(data);
+            fTracePathText.addModifyListener(fUpdateEnablementModifyListener);
+
+            fLinkDataWithControlButton = new Button(fStreamingComposite, SWT.CHECK);
+            fLinkDataWithControlButton.setText(Messages.TraceControl_CreateSessionLinkButtonText);
+            fLinkDataWithControlButton.setToolTipText(Messages.TraceControl_CreateSessionLinkButtonTooltip);
+            data = new GridData(GridData.FILL_HORIZONTAL);
+            data.horizontalSpan = 7;
+            fLinkDataWithControlButton.setLayoutData(data);
+            fLinkDataWithControlButton.setSelection(true);
+
+            Label label = new Label(fStreamingComposite, SWT.NONE);
+            data = new GridData(GridData.FILL_HORIZONTAL);
+            data.horizontalSpan = 1;
+            label.setLayoutData(data);
+
+            label = new Label(fStreamingComposite, SWT.NONE);
+            label.setText(Messages.TraceControl_CreateSessionProtocolLabelText);
+            data = new GridData(GridData.FILL_HORIZONTAL);
+            data.horizontalSpan = 1;
+            label.setLayoutData(data);
+
+            label = new Label(fStreamingComposite, SWT.NONE);
+            label.setText(Messages.TraceControl_CreateSessionAddressLabelText);
+            data = new GridData(GridData.FILL_HORIZONTAL);
+            data.horizontalSpan = 4;
+            label.setLayoutData(data);
+
+            label = new Label(fStreamingComposite, SWT.NONE);
+            label.setText(Messages.TraceControl_CreateSessionPortLabelText);
+            data = new GridData(GridData.FILL_HORIZONTAL);
+            data.horizontalSpan = 1;
+            label.setLayoutData(data);
+
+            label = new Label(fStreamingComposite, SWT.RIGHT);
+            label.setText(Messages.TraceControl_CreateSessionControlUrlLabel);
+            data = new GridData(GridData.FILL_HORIZONTAL);
+            data.horizontalSpan = 1;
+            label.setLayoutData(data);
+
+            fControlProtocolCombo = new CCombo(fStreamingComposite, SWT.READ_ONLY);
+            fControlProtocolCombo.setToolTipText(Messages.TraceControl_CreateSessionCommonProtocolTooltip);
+            data = new GridData(GridData.FILL_HORIZONTAL);
+            data.horizontalSpan = 1;
+            fControlProtocolCombo.setLayoutData(data);
+            fControlProtocolCombo.addModifyListener(fUpdateEnablementModifyListener);
+
+            fControlHostAddressText = new Text(fStreamingComposite, SWT.NONE);
+            fControlHostAddressText.setToolTipText(Messages.TraceControl_CreateSessionControlAddressTooltip);
+            data = new GridData(GridData.FILL_HORIZONTAL);
+            data.horizontalSpan = 4;
+            fControlHostAddressText.setLayoutData(data);
+            fControlHostAddressText.addModifyListener(fUpdateEnablementModifyListener);
+
+            fControlPortText = new Text(fStreamingComposite, SWT.NONE);
+            fControlPortText.setToolTipText(Messages.TraceControl_CreateSessionControlPortTooltip);
+            data = new GridData(GridData.FILL_HORIZONTAL);
+            data.horizontalSpan = 1;
+            fControlPortText.setLayoutData(data);
+            fControlPortText.addModifyListener(fUpdateEnablementModifyListener);
+
+            label = new Label(fStreamingComposite, SWT.RIGHT);
+            label.setText(Messages.TraceControl_CreateSessionDataUrlLabel);
+            data = new GridData(GridData.FILL_HORIZONTAL);
+            data.horizontalSpan = 1;
+            label.setLayoutData(data);
+
+            fDataProtocolCombo = new CCombo(fStreamingComposite, SWT.READ_ONLY);
+            fDataProtocolCombo.setEnabled(false);
+            fDataProtocolCombo.setToolTipText(Messages.TraceControl_CreateSessionProtocolTooltip);
+            data = new GridData(GridData.FILL_HORIZONTAL);
+            data.horizontalSpan = 1;
+            fDataProtocolCombo.setLayoutData(data);
+            fDataProtocolCombo.addModifyListener(fUpdateEnablementModifyListener);
+
+            updateProtocolComboItems();
+
+            fDataHostAddressText = new Text(fStreamingComposite, SWT.NONE);
+            fDataHostAddressText.setEnabled(false);
+            fDataHostAddressText.setToolTipText(Messages.TraceControl_CreateSessionDataAddressTooltip);
+            data = new GridData(GridData.FILL_HORIZONTAL);
+            data.horizontalSpan = 4;
+            fDataHostAddressText.setLayoutData(data);
+            fDataHostAddressText.addModifyListener(fUpdateEnablementModifyListener);
+
+            fDataPortText = new Text(fStreamingComposite, SWT.NONE);
+            fDataPortText.setEnabled(true);
+            fDataPortText.setToolTipText(Messages.TraceControl_CreateSessionDataPortTooltip);
+            data = new GridData(GridData.FILL_HORIZONTAL);
+            data.horizontalSpan = 1;
+            fDataPortText.setLayoutData(data);
+            fDataPortText.addModifyListener(fUpdateEnablementModifyListener);
+
+            fCopyProtocolSelectionListener = new ControlProtocolSelectionListener();
+            fControlProtocolSelectionListener = new ProtocolComboSelectionListener(fControlProtocolCombo, fControlPortText);
+            fDataProtocolSelectionListener = new ProtocolComboSelectionListener(fDataProtocolCombo, fDataPortText);
+
+            fControlProtocolCombo.addSelectionListener(fCopyProtocolSelectionListener);
+
+            fControlUrlKeyListener = new CopyModifyListener(fControlHostAddressText, fDataHostAddressText);
+            fControlHostAddressText.addModifyListener(fControlUrlKeyListener);
+
+            fControlProtocolCombo.select(DEFAULT_URL_INDEX);
+            fDataProtocolCombo.select(DEFAULT_URL_INDEX);
+
+            fLinkDataWithControlButton.addSelectionListener(new SelectionAdapter() {
+                @Override
+                public void widgetSelected(SelectionEvent e) {
+                    if (fLinkDataWithControlButton.getSelection()) {
+                        // Set enablement control data channel inputs
+                        fDataProtocolCombo.setEnabled(false);
+                        fDataHostAddressText.setEnabled(false);
+                        fControlPortText.setEnabled(true);
+                        fDataPortText.setEnabled(true);
+
+                        // Update listeners
+                        fControlProtocolCombo.removeSelectionListener(fControlProtocolSelectionListener);
+                        fDataProtocolCombo.removeSelectionListener(fDataProtocolSelectionListener);
+                        fControlProtocolCombo.addSelectionListener(fCopyProtocolSelectionListener);
+                        fControlHostAddressText.addModifyListener(fControlUrlKeyListener);
+
+                        updateProtocolComboItems();
+
+                        fDataHostAddressText.setText(fControlHostAddressText.getText());
+
+                        // Update tool tips
+                        fControlProtocolCombo.setToolTipText(Messages.TraceControl_CreateSessionCommonProtocolTooltip);
+                    } else {
+                        // Enable data channel inputs
+                        fDataProtocolCombo.setEnabled(true);
+                        fDataHostAddressText.setEnabled(true);
+
+                        // Update listeners
+                        fControlProtocolCombo.removeSelectionListener(fCopyProtocolSelectionListener);
+                        fControlProtocolCombo.addSelectionListener(fControlProtocolSelectionListener);
+                        fDataProtocolCombo.addSelectionListener(fDataProtocolSelectionListener);
+                        fControlHostAddressText.removeModifyListener(fControlUrlKeyListener);
+
+                        updateProtocolComboItems();
+
+                        // Update tool tips
+                        fDataProtocolCombo.setToolTipText(Messages.TraceControl_CreateSessionProtocolTooltip);
+                        fControlProtocolCombo.setToolTipText(Messages.TraceControl_CreateSessionProtocolTooltip);
+
+                        // Update control/data port enablement and input
+                        if (fControlProtocolCombo.getItem(fControlProtocolCombo.getSelectionIndex()).equals(StreamingProtocol.net.name()) ||
+                                fControlProtocolCombo.getItem(fControlProtocolCombo.getSelectionIndex()).equals(StreamingProtocol.net6.name())) {
+                            fControlPortText.setText(""); //$NON-NLS-1$
+                            fControlPortText.setEnabled(false);
+                        } else {
+                            fControlPortText.setEnabled(true);
+                        }
+
+                        if (fDataProtocolCombo.getItem(fDataProtocolCombo.getSelectionIndex()).equals(StreamingProtocol.net.name()) ||
+                                fDataProtocolCombo.getItem(fDataProtocolCombo.getSelectionIndex()).equals(StreamingProtocol.net6.name())) {
+                            fDataPortText.setText(""); //$NON-NLS-1$
+                            fDataPortText.setEnabled(false);
+                        } else {
+                            fDataPortText.setEnabled(true);
+                        }
+                    }
+                }
+            });
+        }
+    }
+
+    private void createAdvancedLiveGroup() {
+        if (fLiveGroup == null && fIsAdvancedEnabled) {
+            GridLayout layout = new GridLayout(7, true);
+            fLiveGroup = new Group(fAdvancedGroup, SWT.NONE);
+            fLiveGroup.setLayout(layout);
+            GridData layoutData = new GridData(GridData.FILL_BOTH);
+            fLiveGroup.setLayoutData(layoutData);
+
+            Label label = new Label(fLiveGroup, SWT.NONE);
+            label.setText(Messages.TraceControl_CreateSessionLiveConnectionLabel);
+            layoutData = new GridData(GridData.FILL_HORIZONTAL);
+            layoutData.horizontalSpan = 2;
+            label.setLayoutData(layoutData);
+
+            fLiveHostAddressText = new Text(fLiveGroup, SWT.NONE);
+            fLiveHostAddressText.setText(SessionInfo.DEFAULT_LIVE_NETWORK_URL);
+            fLiveHostAddressText.setEnabled(false);
+            fLiveHostAddressText.setToolTipText(Messages.TraceControl_CreateSessionLiveConnectionUrlTooltip);
+            layoutData = new GridData(GridData.FILL_HORIZONTAL);
+            layoutData.horizontalSpan = 4;
+            fLiveHostAddressText.setLayoutData(layoutData);
+
+            fLivePortText = new Text(fLiveGroup, SWT.NONE);
+            fLivePortText.setText(Integer.toString(SessionInfo.DEFAULT_LIVE_PORT));
+            fLivePortText.setToolTipText(Messages.TraceControl_CreateSessionLiveConnectionPortTooltip);
+            layoutData = new GridData(GridData.FILL_HORIZONTAL);
+            fLivePortText.setLayoutData(layoutData);
+
+            Label liveDelayLabel = new Label(fLiveGroup, SWT.NONE);
+            layoutData = new GridData(GridData.FILL_HORIZONTAL);
+            liveDelayLabel.setText(Messages.TraceControl_CreateSessionLiveDelayLabel);
+            liveDelayLabel.setLayoutData(layoutData);
+            fLiveDelayText = new Text(fLiveGroup, SWT.NONE);
+            fLiveDelayText.setText(DEFAULT_TEXT);
+            fLiveDelayText.setForeground(getShell().getDisplay().getSystemColor(SWT.COLOR_GRAY));
+            fLiveDelayText.setToolTipText(Messages.TraceControl_CreateSessionLiveDelayTooltip);
+            fLiveDelayText.addVerifyListener(new VerifyListener() {
+                @Override
+                public void verifyText(VerifyEvent e) {
+                    // only numbers and default are allowed.
+                    e.doit = e.text.matches("[0-9]*") || e.text.matches(DEFAULT_TEXT); //$NON-NLS-1$
+                    updateEnablement();
+                }
+            });
+            fLiveDelayText.addModifyListener(new ModifyListener() {
+                @Override
+                public void modifyText(ModifyEvent event) {
+                    updateEnablement();
+                }
+            });
+
+            fLiveDelayText.addFocusListener(new FocusListener() {
+
+                @Override
+                public void focusLost(FocusEvent e) {
+                    Text focusLostWidget = (Text) e.widget;
+                    if (focusLostWidget.getText().isEmpty()) {
+                        focusLostWidget.setText(DEFAULT_TEXT);
+                        focusLostWidget.setForeground(getShell().getDisplay().getSystemColor(SWT.COLOR_GRAY));
+                    }
+                }
+
+                @Override
+                public void focusGained(FocusEvent e) {
+                    Text focusGainedWidget = (Text) e.widget;
+                    if (focusGainedWidget.getText().equals(DEFAULT_TEXT)) {
+                        focusGainedWidget.setText(""); //$NON-NLS-1$
+                        focusGainedWidget.setForeground(getShell().getDisplay().getSystemColor(SWT.COLOR_BLACK));
+                    }
+                }
+            });
+
+            layoutData = new GridData(GridData.FILL_HORIZONTAL);
+            layoutData.grabExcessHorizontalSpace = true;
+            layoutData.horizontalSpan = 6;
+            fLiveDelayText.setLayoutData(layoutData);
+            getShell().pack();
+        }
+    }
+
+    private void disposeLiveGroup() {
+        if (fLiveGroup != null) {
+            fLiveGroup.dispose();
+            fLiveGroup = null;
+            getShell().pack();
+        }
+    }
+
+    private void disposeConfigureStreamingComposite() {
+        if (fStreamingComposite != null) {
+            fStreamingComposite.dispose();
+            fStreamingComposite = null;
+        }
+    }
+
+    @Override
+    protected void createButtonsForButtonBar(Composite parent) {
+        createButton(parent, IDialogConstants.CANCEL_ID, "&Cancel", true); //$NON-NLS-1$
+        createButton(parent, IDialogConstants.OK_ID, "&Ok", true); //$NON-NLS-1$
+    }
+
+    private void updateEnablement() {
+        validate();
+        getButton(IDialogConstants.OK_ID).setEnabled(getErrorMessage() == null);
+    }
+
+    private void validate() {
+        // Validate input data
+        fSessionName = fSessionNameText.getText();
+        fSessionPath = fSessionPathText.getText();
+        setErrorMessage(null);
+
+        if (fParent.isLiveSupported() && fLiveButton != null) {
+            fIsLive = fLiveButton.getSelection();
+            fLiveDelay = Long.valueOf(LTTngControlServiceConstants.UNUSED_VALUE);
+            fLiveUrl = SessionInfo.DEFAULT_LIVE_NETWORK_URL;
+            fLivePort = SessionInfo.DEFAULT_LIVE_PORT;
+        }
+
+        if (!"".equals(fSessionPath)) { //$NON-NLS-1$
+            // validate sessionPath
+            if (!fIsAdvancedEnabled && !fIsLive) {
+                TargetNodeComponent node = (TargetNodeComponent)fParent.getParent();
+                RemoteSystemProxy proxy = node.getRemoteSystemProxy();
+                IRemoteFileService fsss = proxy.getRemoteConnection().getService(IRemoteFileService.class);
+                if (fsss != null) {
+                    IFileStore remoteFolder = fsss.getResource(fSessionPath);
+                    if (remoteFolder == null) {
+                        setErrorMessage(Messages.TraceControl_InvalidSessionPathError + " (" + fSessionPath + ") \n"); //$NON-NLS-1$ //$NON-NLS-2$
+                        return;
+                    }
+                    IFileInfo fileInfo = remoteFolder.fetchInfo();
+                    if (fileInfo.exists()) {
+                        setErrorMessage(Messages.TraceControl_SessionPathAlreadyExistsError + " (" + fSessionPath + ") \n"); //$NON-NLS-1$ //$NON-NLS-2$
+                        return;
+                    }
+                }
+            }
+            fIsDefaultPath = false;
+        }
+
+        if (fParent.isSnapshotSupported()) {
+            fIsSnapshot = fSnapshotButton.getSelection();
+        }
+
+        fNetworkUrl = null;
+        fControlUrl = null;
+        fDataUrl = null;
+
+        if (fIsAdvancedEnabled && fStreamingComposite != null) {
+            // Validate input data
+
+            if (fIsLive && fLiveGroup != null) {
+                String liveDelayText = fLiveDelayText.getText();
+                try {
+                    fLiveDelay = liveDelayText.equals(DEFAULT_TEXT) ? LTTngControlServiceConstants.UNUSED_VALUE : Long.valueOf(liveDelayText);
+                    fLivePort = Integer.valueOf(fLivePortText.getText());
+                    fLiveUrl = fLiveHostAddressText.getText();
+                } catch (NumberFormatException e) {
+                    setErrorMessage(Messages.TraceControl_InvalidLiveDelayError);
+                    return;
+                }
+            }
+
+            fTracePath = fTracePathText.getText();
+
+            if (fControlProtocolCombo.getSelectionIndex() < 0) {
+                setErrorMessage("Control Protocol Text is empty\n");  //$NON-NLS-1$
+                return;
+            }
+
+            if ("".equals(fControlHostAddressText.getText())) { //$NON-NLS-1$
+                setErrorMessage("Control Address Text is empty\n");  //$NON-NLS-1$
+                return;
+            }
+
+            if (!fLinkDataWithControlButton.getSelection()) {
+                if (fDataProtocolCombo.getSelectionIndex() < 0) {
+                    setErrorMessage("Data Protocol Text is empty\n");  //$NON-NLS-1$
+                    return;
+                }
+
+                if ("".equals(fDataHostAddressText.getText())) { //$NON-NLS-1$
+                    setErrorMessage("Data Address Text is empty\n");  //$NON-NLS-1$
+                    return;
+                }
+
+                fControlUrl = getUrlString(fControlProtocolCombo.getItem(fControlProtocolCombo.getSelectionIndex()),
+                        fControlHostAddressText.getText(),
+                        fControlPortText.getText(),
+                        null,
+                        fTracePath);
+
+                fDataUrl = getUrlString(fDataProtocolCombo.getItem(fDataProtocolCombo.getSelectionIndex()),
+                        fDataHostAddressText.getText(),
+                        null,
+                        fDataPortText.getText(),
+                        fTracePath);
+            } else {
+                fNetworkUrl = getUrlString(fControlProtocolCombo.getItem(fControlProtocolCombo.getSelectionIndex()),
+                        fControlHostAddressText.getText(),
+                        fControlPortText.getText(),
+                        fDataPortText.getText(),
+                        fTracePath);
+            }
+        }
+
+        if (fIsLive && fNetworkUrl == null && fControlUrl == null && fDataUrl == null) {
+            fNetworkUrl = SessionInfo.DEFAULT_LIVE_NETWORK_URL;
+        }
+
+        // Check for invalid names
+        if (!"".equals(fSessionName) && !fSessionName.matches("^[a-zA-Z0-9\\-\\_]{1,}$")) { //$NON-NLS-1$ //$NON-NLS-2$
+            setErrorMessage(Messages.TraceControl_InvalidSessionNameError + " (" + fSessionName + ") \n");  //$NON-NLS-1$ //$NON-NLS-2$
+            return;
+        }
+
+        // Check if node with name already exists in parent
+        if(fParent.containsChild(fSessionName)) {
+            setErrorMessage(Messages.TraceControl_SessionAlreadyExistsError + " (" + fSessionName + ")");  //$NON-NLS-1$ //$NON-NLS-2$
+            return;
+        }
+    }
+
+    private static String getUrlString(String proto, String host, String ctrlPort, String dataPort, String sessionPath) {
+        //proto://[HOST|IP][:PORT1[:PORT2]][/TRACE_PATH]
+        StringBuilder stringBuilder = new StringBuilder();
+        stringBuilder.append(proto);
+        stringBuilder.append("://"); //$NON-NLS-1$
+        stringBuilder.append(host);
+
+        if ((ctrlPort != null) && (!"".equals(ctrlPort))) { //$NON-NLS-1$
+            stringBuilder.append(":"); //$NON-NLS-1$
+            stringBuilder.append(ctrlPort);
+        }
+
+        if ((dataPort != null) && (!"".equals(dataPort))) { //$NON-NLS-1$
+            stringBuilder.append(":"); //$NON-NLS-1$
+            stringBuilder.append(dataPort);
+        }
+
+        if ((sessionPath != null) && (!"".equals(sessionPath))) { //$NON-NLS-1$
+            stringBuilder.append("/"); //$NON-NLS-1$
+            stringBuilder.append(sessionPath);
+        }
+        return stringBuilder.toString();
+    }
+
+    private static class CopyModifyListener implements ModifyListener {
+        private Text fSource;
+        private Text fDestination;
+
+        public CopyModifyListener(Text source, Text destination) {
+            fSource = source;
+            fDestination = destination;
+        }
+
+        @Override
+        public void modifyText(ModifyEvent e) {
+            fDestination.setText(fSource.getText());
+        }
+    }
+
+    private class ControlProtocolSelectionListener extends SelectionAdapter {
+
+        @Override
+        public void widgetSelected(SelectionEvent e) {
+            fDataProtocolCombo.select(fControlProtocolCombo.getSelectionIndex());
+            if (fControlProtocolCombo.getItem(fControlProtocolCombo.getSelectionIndex()).equals(StreamingProtocol.file.name())) {
+                fControlPortText.setText(""); //$NON-NLS-1$
+                fDataPortText.setText(""); //$NON-NLS-1$
+                fControlPortText.setEnabled(false);
+                fDataPortText.setEnabled(false);
+            } else {
+                fControlPortText.setEnabled(true);
+                fDataPortText.setEnabled(true);
+            }
+        }
+    }
+
+    private class ProtocolComboSelectionListener extends SelectionAdapter {
+
+        private CCombo fCombo;
+        private Text fPortText;
+
+        public ProtocolComboSelectionListener(CCombo combo, Text portText) {
+            fCombo = combo;
+            fPortText = portText;
+        }
+
+        @Override
+        public void widgetSelected(SelectionEvent e) {
+            if (fCombo.getItem(fCombo.getSelectionIndex()).equals(StreamingProtocol.net.name()) ||
+                    fCombo.getItem(fCombo.getSelectionIndex()).equals(StreamingProtocol.net6.name())) {
+                fPortText.setText(""); //$NON-NLS-1$
+                fPortText.setEnabled(false);
+            } else {
+                fPortText.setEnabled(true);
+            }
+        }
+    }
+
+    @Override
+    public ISessionInfo getParameters() {
+        ISessionInfo sessionInfo = new SessionInfo(fSessionName);
+
+        boolean isStreaming = (fIsAdvancedEnabled && fStreamingComposite != null) || fIsLive;
+        if (isStreaming) {
+            sessionInfo.setNetworkUrl(fNetworkUrl);
+            sessionInfo.setControlUrl(fControlUrl);
+            sessionInfo.setDataUrl(fDataUrl);
+            sessionInfo.setStreamedTrace(true);
+        } else if (!fIsDefaultPath) {
+            sessionInfo.setSessionPath(fSessionPath);
+        }
+
+        sessionInfo.setLive(fIsLive);
+        sessionInfo.setLiveUrl(fLiveUrl);
+        sessionInfo.setLivePort(fLivePort);
+        sessionInfo.setLiveDelay(fLiveDelay);
+        sessionInfo.setSnapshot(fIsSnapshot);
+
+        return sessionInfo;
+    }
+
+    private final class UpdateEnablementModifyListener implements ModifyListener {
+        @Override
+        public void modifyText(ModifyEvent e) {
+            updateEnablement();
+        }
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/EnableChannelDialog.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/EnableChannelDialog.java
new file mode 100644 (file)
index 0000000..5a41940
--- /dev/null
@@ -0,0 +1,595 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Simon Delisle - Updated for support of LTTng Tools 2.2
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
+
+import org.eclipse.jface.dialogs.Dialog;
+import org.eclipse.jface.dialogs.IDialogConstants;
+import org.eclipse.jface.dialogs.MessageDialog;
+import org.eclipse.swt.SWT;
+import org.eclipse.swt.events.FocusEvent;
+import org.eclipse.swt.events.FocusListener;
+import org.eclipse.swt.events.SelectionAdapter;
+import org.eclipse.swt.events.SelectionEvent;
+import org.eclipse.swt.events.VerifyEvent;
+import org.eclipse.swt.events.VerifyListener;
+import org.eclipse.swt.layout.GridData;
+import org.eclipse.swt.layout.GridLayout;
+import org.eclipse.swt.widgets.Button;
+import org.eclipse.swt.widgets.Composite;
+import org.eclipse.swt.widgets.Control;
+import org.eclipse.swt.widgets.Group;
+import org.eclipse.swt.widgets.Label;
+import org.eclipse.swt.widgets.Shell;
+import org.eclipse.swt.widgets.Text;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IChannelInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.BufferType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.ChannelInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.service.LTTngControlServiceConstants;
+
+/**
+ * <p>
+ * Dialog box for collecting channel information when enabling a channel (which will be created).
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class EnableChannelDialog extends Dialog implements IEnableChannelDialog {
+
+    // ------------------------------------------------------------------------
+    // Constants
+    // ------------------------------------------------------------------------
+    /**
+     * The icon file for this dialog box.
+     */
+    public static final String ENABLE_CHANNEL_ICON_FILE = "icons/elcl16/add_button.gif"; //$NON-NLS-1$
+
+    /**
+     *  To indicate that the default value will be used for this field
+     */
+    private static final String DEFAULT_TEXT = "<" + Messages.EnableChannelDialog_DefaultMessage + ">"; //$NON-NLS-1$ //$NON-NLS-2$
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+    /**
+     * The text widget for the channel name
+     */
+    private Text fChannelNameText = null;
+    /**
+     * The discard mode of the channel.
+     */
+    private Button fDiscardModeButton = null;
+    /**
+     * The overwrite mode of the channel.
+     */
+    private Button fOverwriteModeButton = null;
+    /**
+     * The sub-buffer size of the channel.
+     */
+    private Text fSubBufferSizeText = null;
+    /**
+     * The number of sub-buffers of the channel.
+     */
+    private Text fNumberOfSubBuffersText = null;
+    /**
+     * The switch timer interval of the channel.
+     */
+    private Text fSwitchTimerText = null;
+    /**
+     * The read timer interval of the channel.
+     */
+    private Text fReadTimerText = null;
+    /**
+     * Radio button for selecting kernel domain.
+     */
+    private Button fKernelButton = null;
+    /**
+     * Radio button for selecting UST domain.
+     */
+    private Button fUstButton = null;
+    /**
+     * The parent domain component where the channel node should be added.
+     * Null in case of creation on session level.
+     */
+    private TraceDomainComponent fDomain = null;
+    /**
+     * The target node component
+     */
+    private TargetNodeComponent fTargetNodeComponent = null;
+    /**
+     * Common verify listener for numeric text input.
+     */
+    private VerifyListener fVerifyListener = null;
+    /**
+     * Common focus listener
+     */
+    private FocusListener fFocusListener = null;
+    /**
+     * Output channel information.
+     */
+    private IChannelInfo fChannelInfo = null;
+    /**
+     * Output domain information. True in case of Kernel domain. False for UST.
+     */
+    private boolean fIsKernel;
+    /**
+     *  Flag which indicates whether Kernel domain is available or not
+     */
+    private boolean fHasKernel;
+    /**
+     * Maximum size of trace files of the channel.
+     */
+    private Text fMaxSizeTraceText = null;
+    /**
+     * Maximum number of trace files of the channel.
+     */
+    private Text fMaxNumberTraceText = null;
+    /**
+     * CheckBox for selecting shared buffers (kernel onlyu).
+     */
+    private Button fSharedBuffersButton = null;
+    /**
+     * CheckBox for selecting per UID buffers.
+     */
+    private Button fPIDBuffersButton = null;
+    /**
+     * CheckBox for selecting per UID buffers.
+     */
+    private Button fUIDBuffersButton = null;
+    /**
+     * CheckBox to configure metadata channel
+     */
+    private Button fMetadataChannelButton = null;
+    /**
+     * Previous channel name
+     */
+    private String fPreviousChannelName = null;
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+
+    /**
+     * Constructor
+     * @param shell - a shell for the display of the dialog
+     */
+    public EnableChannelDialog(Shell shell) {
+       super(shell);
+       fIsKernel = true;
+
+        // Common verify listener
+        fVerifyListener = new VerifyListener() {
+            @Override
+            public void verifyText(VerifyEvent e) {
+                // only numbers and default are allowed.
+                e.doit = e.text.matches("[0-9]*") || e.text.matches(DEFAULT_TEXT); //$NON-NLS-1$
+            }
+        };
+
+        // Common focus listener
+        fFocusListener = new FocusListener() {
+
+            @Override
+            public void focusLost(FocusEvent e) {
+                Text focusLostWidget = (Text) e.widget;
+                if (focusLostWidget.getText().isEmpty()) {
+                    focusLostWidget.setText(DEFAULT_TEXT);
+                    focusLostWidget.setForeground(getShell().getDisplay().getSystemColor(SWT.COLOR_GRAY));
+                }
+            }
+
+            @Override
+            public void focusGained(FocusEvent e) {
+                Text focusGainedWidget = (Text) e.widget;
+                if (focusGainedWidget.getText().equals(DEFAULT_TEXT)) {
+                    focusGainedWidget.setText(""); //$NON-NLS-1$
+                    focusGainedWidget.setForeground(getShell().getDisplay().getSystemColor(SWT.COLOR_BLACK));
+                }
+            }
+        };
+
+        setShellStyle(SWT.RESIZE | getShellStyle());
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    @Override
+    public IChannelInfo getChannelInfo() {
+        return fChannelInfo;
+    }
+
+    @Override
+    public void setDomainComponent(TraceDomainComponent domain) {
+        fDomain = domain;
+        if (fDomain != null) {
+            fIsKernel = fDomain.isKernel();
+        } else {
+            fIsKernel = true;
+        }
+    }
+
+    @Override
+    public boolean isKernel() {
+        return fIsKernel;
+    }
+
+    @Override
+    public void setHasKernel(boolean hasKernel) {
+        if (fDomain != null) {
+            fIsKernel = fDomain.isKernel();
+        } else {
+            fIsKernel = hasKernel;
+        }
+
+        fHasKernel = hasKernel;
+    }
+
+    @Override
+    public void setTargetNodeComponent(TargetNodeComponent node) {
+        fTargetNodeComponent = node;
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    protected void configureShell(Shell newShell) {
+        super.configureShell(newShell);
+        newShell.setText(Messages.TraceControl_EnableChannelDialogTitle);
+        newShell.setImage(Activator.getDefault().loadIcon(ENABLE_CHANNEL_ICON_FILE));
+    }
+
+    @Override
+    protected Control createDialogArea(Composite parent) {
+
+        int numColumn = 2;
+        if (fTargetNodeComponent.isBufferTypeConfigSupported()) {
+            numColumn = 3;
+        }
+
+        // Main dialog panel
+        Composite dialogComposite = new Composite(parent, SWT.NONE);
+        GridLayout layout = new GridLayout(1, true);
+        dialogComposite.setLayout(layout);
+
+        Composite commonModeGroup = new Composite(dialogComposite, SWT.NONE);
+        layout = new GridLayout(3, true);
+        commonModeGroup.setLayout(layout);
+
+        Label channelNameLabel = new Label(commonModeGroup, SWT.RIGHT);
+        channelNameLabel.setText(Messages.TraceControl_EnableChannelNameLabel);
+        fChannelNameText = new Text(commonModeGroup, SWT.NONE);
+        fChannelNameText.setToolTipText(Messages.TraceControl_EnableChannelNameTooltip);
+
+        Label subBufferSizeLabel = new Label(commonModeGroup, SWT.RIGHT);
+        subBufferSizeLabel.setText(Messages.TraceControl_SubBufferSizePropertyName);
+        fSubBufferSizeText = new Text(commonModeGroup, SWT.NONE);
+        fSubBufferSizeText.setToolTipText(Messages.TraceControl_EnableChannelSubBufferSizeTooltip);
+        fSubBufferSizeText.addVerifyListener(fVerifyListener);
+        fSubBufferSizeText.addFocusListener(fFocusListener);
+        fSubBufferSizeText.setForeground(getShell().getDisplay().getSystemColor(SWT.COLOR_GRAY));
+
+        Label numSubBufferLabel = new Label(commonModeGroup, SWT.RIGHT);
+        numSubBufferLabel.setText(Messages.TraceControl_NbSubBuffersPropertyName);
+        fNumberOfSubBuffersText = new Text(commonModeGroup, SWT.NONE);
+        fNumberOfSubBuffersText.setToolTipText(Messages.TraceControl_EnableChannelNbSubBuffersTooltip);
+        fNumberOfSubBuffersText.addVerifyListener(fVerifyListener);
+        fNumberOfSubBuffersText.addFocusListener(fFocusListener);
+
+        Label switchTimerLabel = new Label(commonModeGroup, SWT.RIGHT);
+        switchTimerLabel.setText(Messages.TraceControl_SwitchTimerPropertyName);
+        fSwitchTimerText = new Text(commonModeGroup, SWT.NONE);
+        fSwitchTimerText.setToolTipText(Messages.TraceControl_EnableChannelSwitchTimerTooltip);
+        fSwitchTimerText.addVerifyListener(fVerifyListener);
+        fSwitchTimerText.addFocusListener(fFocusListener);
+
+        Label readTimerLabel = new Label(commonModeGroup, SWT.RIGHT);
+        readTimerLabel.setText(Messages.TraceControl_ReadTimerPropertyName);
+        fReadTimerText = new Text(commonModeGroup, SWT.NONE);
+        fReadTimerText.setToolTipText(Messages.TraceControl_EnableChannelReadTimerTooltip);
+        fReadTimerText.addVerifyListener(fVerifyListener);
+        fReadTimerText.addFocusListener(fFocusListener);
+
+        if (fTargetNodeComponent.isTraceFileRotationSupported()) {
+            Label maxSizeTraceFilesLabel = new Label(commonModeGroup, SWT.RIGHT);
+            maxSizeTraceFilesLabel.setText(Messages.TraceControl_MaxSizeTraceFilesPropertyName);
+            fMaxSizeTraceText = new Text(commonModeGroup, SWT.NONE);
+            fMaxSizeTraceText.setToolTipText(Messages.TraceControl_EnbleChannelMaxSizeTraceFilesTooltip);
+            fMaxSizeTraceText.addVerifyListener(fVerifyListener);
+            fMaxSizeTraceText.addFocusListener(fFocusListener);
+
+            Label maxNumTraceFilesLabel = new Label(commonModeGroup, SWT.RIGHT);
+            maxNumTraceFilesLabel.setText(Messages.TraceControl_MaxNumTraceFilesPropertyName);
+            fMaxNumberTraceText = new Text(commonModeGroup, SWT.NONE);
+            fMaxNumberTraceText.setToolTipText(Messages.TraceControl_EnbleChannelMaxNumTraceFilesTooltip);
+            fMaxNumberTraceText.addVerifyListener(fVerifyListener);
+            fMaxNumberTraceText.addFocusListener(fFocusListener);
+        }
+
+        if (fTargetNodeComponent.isPeriodicalMetadataFlushSupported()) {
+            fMetadataChannelButton = new Button(commonModeGroup, SWT.CHECK);
+            fMetadataChannelButton.setText(Messages.TraceControl_ConfigureMetadataChannelName);
+            fMetadataChannelButton.setSelection(false);
+
+            fMetadataChannelButton.addSelectionListener(new SelectionAdapter() {
+                @Override
+                public void widgetSelected(SelectionEvent e) {
+                    if (fMetadataChannelButton.getSelection()) {
+                        fPreviousChannelName = fChannelNameText.getText();
+                        fChannelNameText.setText("metadata"); //$NON-NLS-1$
+                        fChannelNameText.setEnabled(false);
+                    } else {
+                        fChannelNameText.setText(fPreviousChannelName);
+                        fChannelNameText.setEnabled(true);
+                    }
+                }
+            });
+        }
+        Group discardModeGroup = new Group(dialogComposite, SWT.SHADOW_NONE);
+        discardModeGroup.setText(Messages.TraceControl_EnableChannelDiscardModeGroupName);
+        layout = new GridLayout(numColumn, true);
+        discardModeGroup.setLayout(layout);
+
+        fDiscardModeButton = new  Button(discardModeGroup, SWT.RADIO);
+        fDiscardModeButton.setText(Messages.TraceControl_EnableChannelDiscardModeLabel);
+        fDiscardModeButton.setToolTipText(Messages.TraceControl_EnableChannelDiscardModeTooltip);
+        fDiscardModeButton.setSelection(true);
+
+        fOverwriteModeButton = new Button(discardModeGroup, SWT.RADIO);
+        fOverwriteModeButton.setText(Messages.TraceControl_EnableChannelOverwriteModeLabel);
+        fOverwriteModeButton.setToolTipText(Messages.TraceControl_EnableChannelOverwriteModeTooltip);
+        fOverwriteModeButton.setSelection(false);
+
+        Group domainGroup = new Group(dialogComposite, SWT.SHADOW_NONE);
+        domainGroup.setText(Messages.TraceControl_DomainDisplayName);
+        layout = new GridLayout(numColumn, true);
+        domainGroup.setLayout(layout);
+
+        fKernelButton = new Button(domainGroup, SWT.RADIO);
+        fKernelButton.setText(Messages.TraceControl_KernelDomainDisplayName);
+        fKernelButton.setSelection(fIsKernel);
+        fUstButton = new Button(domainGroup, SWT.RADIO);
+        fUstButton.setText(Messages.TraceControl_UstDisplayName);
+        fUstButton.setSelection(!fIsKernel);
+
+        if (fTargetNodeComponent.isBufferTypeConfigSupported()) {
+            Group bufferTypeGroup = new Group(dialogComposite, SWT.SHADOW_NONE);
+            bufferTypeGroup.setText(Messages.TraceControl_BufferTypeDisplayName);
+            layout = new GridLayout(numColumn, true);
+            bufferTypeGroup.setLayout(layout);
+
+            GridData data = new GridData(GridData.FILL, GridData.BEGINNING, false, false);
+            data.horizontalSpan = 3;
+            bufferTypeGroup.setLayoutData(data);
+
+            fSharedBuffersButton = new Button(bufferTypeGroup, SWT.RADIO);
+            fSharedBuffersButton.setText(Messages.TraceControl_SharedBuffersDisplayName);
+            fSharedBuffersButton.setSelection(fIsKernel);
+            fSharedBuffersButton.setEnabled(false);
+
+            fPIDBuffersButton = new Button(bufferTypeGroup, SWT.RADIO);
+            fPIDBuffersButton.setText(Messages.TraceControl_PerPidBuffersDisplayName);
+            fPIDBuffersButton.setToolTipText(Messages.TraceControl_PerPidBuffersTooltip);
+            fPIDBuffersButton.setSelection(false);
+
+            fUIDBuffersButton = new Button(bufferTypeGroup, SWT.RADIO);
+            fUIDBuffersButton.setText(Messages.TraceControl_PerUidBuffersDisplayName);
+            fUIDBuffersButton.setToolTipText(Messages.TraceControl_PerPidBuffersTooltip);
+            fUIDBuffersButton.setSelection(false);
+
+            fUIDBuffersButton.setEnabled(!fIsKernel);
+            fPIDBuffersButton.setEnabled(!fIsKernel);
+
+            // Update buffers type buttons depending on UST or Kernel
+            fUstButton.addSelectionListener(new SelectionAdapter() {
+                @Override
+                public void widgetSelected(SelectionEvent e) {
+                    if (fUstButton.getSelection()) {
+                        fSharedBuffersButton.setSelection(false);
+                        fPIDBuffersButton.setSelection(false);
+                        fUIDBuffersButton.setSelection(false);
+                        fPIDBuffersButton.setEnabled(true);
+                        fUIDBuffersButton.setEnabled(true);
+                    } else {
+                        fSharedBuffersButton.setSelection(true);
+                        fPIDBuffersButton.setSelection(false);
+                        fUIDBuffersButton.setSelection(false);
+                        fPIDBuffersButton.setEnabled(false);
+                        fUIDBuffersButton.setEnabled(false);
+                    }
+                }
+            });
+        }
+
+        if ((fDomain != null) || (!fHasKernel)) {
+            fKernelButton.setEnabled(false);
+            fUstButton.setEnabled(false);
+
+            if (fTargetNodeComponent.isBufferTypeConfigSupported()) {
+                fSharedBuffersButton.setEnabled(false);
+                fUIDBuffersButton.setEnabled(!fHasKernel);
+                fPIDBuffersButton.setEnabled(!fHasKernel);
+                setBufferTypeButtonSelection();
+            }
+        }
+
+        // layout widgets
+        GridData data = new GridData(GridData.FILL, GridData.BEGINNING, false, false);
+        data.horizontalSpan = 3;
+        discardModeGroup.setLayoutData(data);
+        data = new GridData(SWT.BEGINNING, SWT.BEGINNING, true, true);
+        fDiscardModeButton.setLayoutData(data);
+        data = new GridData(SWT.BEGINNING, SWT.BEGINNING, true, true);
+        fOverwriteModeButton.setLayoutData(data);
+
+        data = new GridData(GridData.FILL, GridData.BEGINNING, false, false);
+        data.horizontalSpan = 3;
+        domainGroup.setLayoutData(data);
+
+        data = new GridData(SWT.BEGINNING, SWT.BEGINNING, true, true);
+        fKernelButton.setLayoutData(data);
+        data = new GridData(SWT.BEGINNING, SWT.BEGINNING, true, true);
+        fUstButton.setLayoutData(data);
+        if (fTargetNodeComponent.isBufferTypeConfigSupported()) {
+            data = new GridData(SWT.BEGINNING, SWT.BEGINNING, true, true);
+            fSharedBuffersButton.setLayoutData(data);
+            data = new GridData(SWT.BEGINNING, SWT.BEGINNING, true, true);
+            fPIDBuffersButton.setLayoutData(data);
+            data = new GridData(SWT.BEGINNING, SWT.BEGINNING, true, true);
+            fUIDBuffersButton.setLayoutData(data);
+        }
+
+        if (fTargetNodeComponent.isPeriodicalMetadataFlushSupported()) {
+            data = new GridData(SWT.BEGINNING, SWT.BEGINNING, true, true);
+            data.horizontalSpan = numColumn;
+            fMetadataChannelButton.setLayoutData(data);
+        }
+
+        data = new GridData(GridData.FILL_HORIZONTAL);
+        data.horizontalSpan = 2;
+
+        fChannelNameText.setLayoutData(data);
+        fSubBufferSizeText.setLayoutData(data);
+        fNumberOfSubBuffersText.setLayoutData(data);
+        fSwitchTimerText.setLayoutData(data);
+        fReadTimerText.setLayoutData(data);
+        if (fTargetNodeComponent.isTraceFileRotationSupported()) {
+            fMaxNumberTraceText.setLayoutData(data);
+            fMaxSizeTraceText.setLayoutData(data);
+        }
+
+        setDefaults();
+
+        return dialogComposite;
+    }
+
+    @Override
+    protected void createButtonsForButtonBar(Composite parent) {
+        createButton(parent, IDialogConstants.DETAILS_ID, "&Default", true); //$NON-NLS-1$
+        createButton(parent, IDialogConstants.CANCEL_ID, "&Cancel", true); //$NON-NLS-1$
+        createButton(parent, IDialogConstants.OK_ID, "&Ok", true); //$NON-NLS-1$
+    }
+
+    @Override
+    protected void okPressed() {
+        // Set channel information
+        ChannelInfo channelInfo = new ChannelInfo(fChannelNameText.getText());
+        channelInfo.setSubBufferSize(fSubBufferSizeText.getText().equals(DEFAULT_TEXT) ? LTTngControlServiceConstants.UNUSED_VALUE : Long.parseLong(fSubBufferSizeText.getText()));
+        channelInfo.setNumberOfSubBuffers(fNumberOfSubBuffersText.getText().equals(DEFAULT_TEXT) ? LTTngControlServiceConstants.UNUSED_VALUE : Integer.parseInt(fNumberOfSubBuffersText.getText()));
+        channelInfo.setSwitchTimer(fSwitchTimerText.getText().equals(DEFAULT_TEXT) ? LTTngControlServiceConstants.UNUSED_VALUE : Long.parseLong(fSwitchTimerText.getText()));
+        channelInfo.setReadTimer(fReadTimerText.getText().equals(DEFAULT_TEXT) ? LTTngControlServiceConstants.UNUSED_VALUE : Long.parseLong(fReadTimerText.getText()));
+        channelInfo.setOverwriteMode(fOverwriteModeButton.getSelection());
+        if (fTargetNodeComponent.isTraceFileRotationSupported()) {
+            channelInfo.setMaxSizeTraceFiles(fMaxSizeTraceText.getText().equals(DEFAULT_TEXT) ? LTTngControlServiceConstants.UNUSED_VALUE : Integer.parseInt(fMaxSizeTraceText.getText()));
+            channelInfo.setMaxNumberTraceFiles(fMaxNumberTraceText.getText().equals(DEFAULT_TEXT) ? LTTngControlServiceConstants.UNUSED_VALUE : Integer.parseInt(fMaxNumberTraceText.getText()));
+        }
+        if (fTargetNodeComponent.isBufferTypeConfigSupported()) {
+            if (fSharedBuffersButton.getSelection()) {
+                channelInfo.setBufferType(BufferType.BUFFER_SHARED);
+            } else if (fPIDBuffersButton.getSelection()) {
+                channelInfo.setBufferType(BufferType.BUFFER_PER_PID);
+            } else if (fUIDBuffersButton.getSelection()) {
+                channelInfo.setBufferType(BufferType.BUFFER_PER_UID);
+            } else {
+                channelInfo.setBufferType(BufferType.BUFFER_TYPE_UNKNOWN);
+            }
+        }
+
+        fIsKernel = fKernelButton.getSelection();
+
+        // Check for invalid names
+        if (!channelInfo.getName().matches("^[a-zA-Z0-9\\-\\_]{1,}$")) { //$NON-NLS-1$
+            MessageDialog.openError(getShell(),
+                  Messages.TraceControl_EnableChannelDialogTitle,
+                  Messages.TraceControl_InvalidChannelNameError + " (" + channelInfo.getName() + ") \n");  //$NON-NLS-1$ //$NON-NLS-2$
+            return;
+        }
+
+        // Check for duplicate names
+        if (fDomain != null && fDomain.containsChild(channelInfo.getName())) {
+            MessageDialog.openError(getShell(),
+                    Messages.TraceControl_EnableChannelDialogTitle,
+                    Messages.TraceControl_ChannelAlreadyExistsError + " (" + channelInfo.getName() + ") \n");  //$NON-NLS-1$ //$NON-NLS-2$
+            return;
+        }
+
+        fChannelInfo = channelInfo;
+
+        // validation successful -> call super.okPressed()
+        super.okPressed();
+    }
+
+    @Override
+    protected void buttonPressed(int buttonId) {
+        if (buttonId == IDialogConstants.DETAILS_ID) {
+            setDefaults();
+            return;
+        }
+        super.buttonPressed(buttonId);
+    }
+
+    // ------------------------------------------------------------------------
+    // Helper methods
+    // ------------------------------------------------------------------------
+
+    /**
+     * Sets default value depending on Kernel or UST
+     */
+    private void setDefaults() {
+        fSwitchTimerText.setText(DEFAULT_TEXT);
+        fSwitchTimerText.setForeground(getShell().getDisplay().getSystemColor(SWT.COLOR_GRAY));
+        fReadTimerText.setText(DEFAULT_TEXT);
+        fReadTimerText.setForeground(getShell().getDisplay().getSystemColor(SWT.COLOR_GRAY));
+        fOverwriteModeButton.setSelection(IChannelInfo.DEFAULT_OVERWRITE_MODE);
+        if (fTargetNodeComponent.isTraceFileRotationSupported()) {
+            fMaxSizeTraceText.setText(DEFAULT_TEXT);
+            fMaxSizeTraceText.setForeground(getShell().getDisplay().getSystemColor(SWT.COLOR_GRAY));
+            fMaxNumberTraceText.setText(DEFAULT_TEXT);
+            fMaxNumberTraceText.setForeground(getShell().getDisplay().getSystemColor(SWT.COLOR_GRAY));
+        }
+        fSubBufferSizeText.setText(DEFAULT_TEXT);
+        fSubBufferSizeText.setForeground(getShell().getDisplay().getSystemColor(SWT.COLOR_GRAY));
+        fNumberOfSubBuffersText.setText(DEFAULT_TEXT);
+        fNumberOfSubBuffersText.setForeground(getShell().getDisplay().getSystemColor(SWT.COLOR_GRAY));
+        if (fTargetNodeComponent.isBufferTypeConfigSupported()) {
+            setBufferTypeButtonSelection();
+        }
+    }
+
+    private void setBufferTypeButtonSelection() {
+        if ((fDomain != null) && fDomain.getBufferType() != null) {
+            switch (fDomain.getBufferType()) {
+            case BUFFER_PER_PID:
+                fPIDBuffersButton.setSelection(true);
+                break;
+            case BUFFER_PER_UID:
+                fUIDBuffersButton.setSelection(true);
+                break;
+            case BUFFER_SHARED:
+                fSharedBuffersButton.setSelection(true);
+                break;
+                //$CASES-OMITTED$
+            default:
+                break;
+            }
+        }
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/EnableEventsDialog.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/EnableEventsDialog.java
new file mode 100644 (file)
index 0000000..e7f89b7
--- /dev/null
@@ -0,0 +1,436 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
+
+import java.util.List;
+
+import org.eclipse.jface.dialogs.Dialog;
+import org.eclipse.jface.dialogs.IDialogConstants;
+import org.eclipse.swt.SWT;
+import org.eclipse.swt.events.SelectionAdapter;
+import org.eclipse.swt.events.SelectionEvent;
+import org.eclipse.swt.graphics.Point;
+import org.eclipse.swt.layout.GridData;
+import org.eclipse.swt.layout.GridLayout;
+import org.eclipse.swt.widgets.Button;
+import org.eclipse.swt.widgets.Composite;
+import org.eclipse.swt.widgets.Control;
+import org.eclipse.swt.widgets.Group;
+import org.eclipse.swt.widgets.Shell;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.LogLevelType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceProviderGroup;
+
+/**
+ * <p>
+ * Dialog box for collecting information events to be enabled.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class EnableEventsDialog extends Dialog implements IEnableEventsDialog  {
+
+    // ------------------------------------------------------------------------
+    // Constants
+    // ------------------------------------------------------------------------
+
+    /**
+     * The icon file for this dialog box.
+     */
+    public static final String ENABLE_EVENT_ICON_FILE = "icons/elcl16/enable_event.gif"; //$NON-NLS-1$
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+    /**
+     * The dialog composite.
+     */
+    private Composite fDialogComposite;
+    /**
+     * The composite with widgets for collecting information about kernel events.
+     */
+    private EnableKernelEventComposite fKernelComposite;
+    /**
+     * The composite with widgets for collecting information about UST events.
+     */
+    private EnableUstEventsComposite fUstComposite;
+    /**
+     * Radio button for selecting kernel domain.
+     */
+    private Button fKernelButton;
+    /**
+     * Radio button for selecting UST domain.
+     */
+    private Button fUstButton;
+    /**
+     * The referenced trace provider group containing the kernel provider and UST
+     * provider component which contains a list of available tracepoints.
+     */
+    private TraceProviderGroup fProviderGroup;
+    /**
+     * The parent domain component where the channel node should be added.
+     * Null in case the domain is not known (i.e. on session level).
+     */
+    private TraceDomainComponent fDomain;
+    /**
+     * Output domain information. True in case of Kernel domain. False for UST.
+     */
+    private boolean fIsKernel;
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+    /**
+     * Constructor
+     * @param shell - a shell for the display of the dialog
+     */
+    public EnableEventsDialog(Shell shell) {
+        super(shell);
+        setShellStyle(SWT.RESIZE | getShellStyle());
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    @Override
+    public boolean isTracepoints() {
+        if (fIsKernel) {
+            return fKernelComposite.isTracepoints();
+        }
+        return fUstComposite.isTracepoints();
+    }
+
+    @Override
+    public boolean isAllTracePoints() {
+        if (fIsKernel) {
+            return fKernelComposite.isAllTracePoints();
+        }
+        return fUstComposite.isAllTracePoints();
+    }
+
+    @Override
+    public boolean isSysCalls() {
+        if (fIsKernel) {
+            return fKernelComposite.isSysCalls();
+        }
+        return false;
+    }
+
+    @Override
+    public boolean isAllSysCalls() {
+        if (fIsKernel) {
+            return fKernelComposite.isSysCalls();
+        }
+        return false;
+    }
+
+    @Override
+    public List<String> getEventNames() {
+        if (fIsKernel) {
+            return fKernelComposite.getEventNames();
+        }
+        return fUstComposite.getEventNames();
+    }
+
+    @Override
+    public boolean isDynamicProbe() {
+        if (fIsKernel) {
+            return fKernelComposite.isDynamicProbe();
+        }
+        return false;
+    }
+
+    @Override
+    public String getProbeName() {
+        if (fIsKernel) {
+            return fKernelComposite.getProbeName();
+        }
+        return null;
+    }
+
+    @Override
+    public String getProbeEventName() {
+        if (fIsKernel) {
+            return fKernelComposite.getProbeEventName();
+        }
+        return null;
+    }
+
+    @Override
+    public boolean isDynamicFunctionProbe() {
+        if (fIsKernel) {
+            return fKernelComposite.isDynamicFunctionProbe();
+        }
+        return false;
+    }
+
+    @Override
+    public String getFunctionEventName() {
+        if (fIsKernel) {
+            return fKernelComposite.getFunctionEventName();
+        }
+        return null;
+    }
+
+    @Override
+    public String getFunction() {
+        if (fIsKernel) {
+            return fKernelComposite.getFunction();
+        }
+        return null;
+    }
+
+    @Override
+    public boolean isWildcard() {
+        if (!fIsKernel) {
+            return fUstComposite.isWildcard();
+        }
+        return false;
+    }
+
+    @Override
+    public String getWildcard() {
+        if (!fIsKernel) {
+            return fUstComposite.getWildcard();
+        }
+        return null;
+    }
+
+    @Override
+    public boolean isLogLevel() {
+        if (!fIsKernel) {
+            return fUstComposite.isLogLevel();
+        }
+        return false;
+    }
+
+    @Override
+    public LogLevelType getLogLevelType() {
+        if (!fIsKernel) {
+            return fUstComposite.getLogLevelType();
+        }
+        return null;
+    }
+
+    @Override
+    public TraceLogLevel getLogLevel() {
+        if (!fIsKernel) {
+            return fUstComposite.getLogLevel();
+        }
+        return null;
+    }
+
+    @Override
+    public String getLogLevelEventName() {
+        if (!fIsKernel) {
+            return fUstComposite.getLogLevelEventName();
+        }
+        return null;
+    }
+
+    @Override
+    public boolean isKernel() {
+        return fIsKernel;
+    }
+
+    @Override
+    public void setTraceProviderGroup(TraceProviderGroup providerGroup) {
+        fProviderGroup = providerGroup;
+    }
+
+    @Override
+    public void setTraceDomainComponent(TraceDomainComponent domain) {
+        fDomain = domain;
+        if (fDomain != null) {
+            fIsKernel = fDomain.isKernel();
+        } else {
+            fIsKernel = fProviderGroup != null ? fProviderGroup.hasKernelProvider() : true;
+        }
+    }
+
+    @Override
+    public String getFilterExpression() {
+        if (!fIsKernel) {
+            return fUstComposite.getFilterExpression();
+        }
+        return null;
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    protected void configureShell(Shell newShell) {
+        super.configureShell(newShell);
+        newShell.setText(Messages.TraceControl_EnableEventsDialogTitle);
+        newShell.setImage(Activator.getDefault().loadIcon(ENABLE_EVENT_ICON_FILE));
+    }
+
+    @Override
+    protected Control createDialogArea(Composite parent) {
+
+        // Main dialog panel
+        fDialogComposite = new Composite(parent, SWT.NONE);
+        GridLayout layout = new GridLayout(1, true);
+        fDialogComposite.setLayout(layout);
+        fDialogComposite.setLayoutData(new GridData(GridData.FILL_BOTH));
+
+        // ------------------------------------------------------------------------
+        // Domain Group
+        // ------------------------------------------------------------------------
+        Group domainGroup = new Group(fDialogComposite, SWT.SHADOW_NONE);
+        domainGroup.setText(Messages.TraceControl_DomainDisplayName);
+        layout = new GridLayout(2, true);
+        domainGroup.setLayout(layout);
+
+        fKernelButton = new Button(domainGroup, SWT.RADIO);
+        fKernelButton.setText(Messages.TraceControl_KernelDomainDisplayName);
+        fKernelButton.setSelection(fIsKernel);
+        fUstButton = new Button(domainGroup, SWT.RADIO);
+        fUstButton.setText(Messages.TraceControl_UstDisplayName);
+        fUstButton.setSelection(!fIsKernel);
+
+        if ((fDomain != null) || ((fProviderGroup != null) && (!fProviderGroup.hasKernelProvider()))) {
+            fKernelButton.setEnabled(false);
+            fUstButton.setEnabled(false);
+        }
+
+        // layout widgets
+        GridData data = new GridData(GridData.FILL_HORIZONTAL);
+        domainGroup.setLayoutData(data);
+
+        data = new GridData(SWT.BEGINNING, SWT.BEGINNING, true, true);
+        fKernelButton.setLayoutData(data);
+        data = new GridData(SWT.BEGINNING, SWT.BEGINNING, true, true);
+        fUstButton.setLayoutData(data);
+
+        // ------------------------------------------------------------------------
+        // Kernel or UST event data group
+        // ------------------------------------------------------------------------
+        fUstComposite = null;
+        fKernelComposite = null;
+        if (fIsKernel) {
+            createKernelComposite();
+            fUstComposite = null;
+        } else {
+            createUstComposite();
+        }
+
+        fKernelButton.addSelectionListener(new SelectionAdapter() {
+            @Override
+            public void widgetSelected(SelectionEvent e) {
+                if (fKernelButton.getSelection()) {
+                    disposeUstComposite();
+                    createKernelComposite();
+                    fDialogComposite.layout();
+                }
+            }
+        });
+
+        fUstButton.addSelectionListener(new SelectionAdapter() {
+            @Override
+            public void widgetSelected(SelectionEvent e) {
+                if (fUstButton.getSelection()) {
+                    disposeKernelComposite();
+                    createUstComposite();
+                    fDialogComposite.layout();
+                }
+            }
+        });
+
+        getShell().setMinimumSize(new Point(500, 650));
+
+        return fDialogComposite;
+    }
+
+    @Override
+    protected void createButtonsForButtonBar(Composite parent) {
+        createButton(parent, IDialogConstants.CANCEL_ID, "&Cancel", true); //$NON-NLS-1$
+        createButton(parent, IDialogConstants.OK_ID, "&Ok", true); //$NON-NLS-1$
+    }
+
+    @Override
+    protected void okPressed() {
+        fIsKernel = fKernelButton.getSelection();
+
+        // Validate kernel composite in case of kernel domain
+        if (fKernelComposite != null && !fKernelComposite.isValid()) {
+            return;
+        }
+
+     // Validate UST composite in case of UST domain
+        if (fUstComposite != null && !fUstComposite.isValid()) {
+            return;
+        }
+
+        // validation successful -> call super.okPressed()
+        super.okPressed();
+    }
+
+    // ------------------------------------------------------------------------
+    // Helper methods
+    // ------------------------------------------------------------------------
+
+    /**
+     * Creates the kernel composite (if not existing)
+     */
+    private void createKernelComposite() {
+        if (fKernelComposite == null) {
+            fKernelComposite = new EnableKernelEventComposite(fDialogComposite, SWT.NONE, fProviderGroup);
+            GridLayout layout = new GridLayout(1, true);
+            fKernelComposite.setLayout(layout);
+            fKernelComposite.setLayoutData(new GridData(GridData.FILL_BOTH));
+
+            fKernelComposite.createContent();
+        }
+    }
+
+    /**
+     * Disposes the kernel composite (if existing)
+     */
+    private void disposeKernelComposite() {
+        if (fKernelComposite != null) {
+            fKernelComposite.dispose();
+            fKernelComposite = null;
+        }
+    }
+
+    /**
+     * Creates the UST composite (if not existing)
+     */
+    private void createUstComposite() {
+        if (fUstComposite == null) {
+            fUstComposite = new EnableUstEventsComposite(fDialogComposite, SWT.NONE, fProviderGroup);
+            GridLayout layout = new GridLayout(1, true);
+            fUstComposite.setLayout(layout);
+            fUstComposite.setLayoutData(new GridData(GridData.FILL_BOTH));
+
+            fUstComposite.createContent();
+        }
+    }
+
+    /**
+     * Disposes the UST composite (if existing)
+     */
+    private void disposeUstComposite() {
+        if (fUstComposite != null) {
+            fUstComposite.dispose();
+            fUstComposite = null;
+        }
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/EnableKernelEventComposite.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/EnableKernelEventComposite.java
new file mode 100644 (file)
index 0000000..483bbee
--- /dev/null
@@ -0,0 +1,605 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Marc-Andre Laperle - Add filtering textbox
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import org.eclipse.jface.dialogs.MessageDialog;
+import org.eclipse.jface.viewers.CheckStateChangedEvent;
+import org.eclipse.jface.viewers.CheckboxTreeViewer;
+import org.eclipse.jface.viewers.ICheckStateListener;
+import org.eclipse.jface.viewers.TreeViewer;
+import org.eclipse.swt.SWT;
+import org.eclipse.swt.events.SelectionAdapter;
+import org.eclipse.swt.events.SelectionEvent;
+import org.eclipse.swt.graphics.Image;
+import org.eclipse.swt.layout.GridData;
+import org.eclipse.swt.layout.GridLayout;
+import org.eclipse.swt.widgets.Button;
+import org.eclipse.swt.widgets.Composite;
+import org.eclipse.swt.widgets.Group;
+import org.eclipse.swt.widgets.Label;
+import org.eclipse.swt.widgets.Text;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.BaseEventComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.KernelProviderComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceControlContentProvider;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceControlLabelProvider;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceProviderGroup;
+import org.eclipse.ui.dialogs.FilteredTree;
+import org.eclipse.ui.dialogs.PatternFilter;
+
+/**
+ * <p>
+ * A composite for collecting information about kernel events to be enabled.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class EnableKernelEventComposite extends Composite implements IEnableKernelEvents {
+
+    // ------------------------------------------------------------------------
+    // Constants
+    // ------------------------------------------------------------------------
+    private enum KernelGroupEnum { TRACEPOINTS, SYSCALLS, PROBE, FUNCTION }
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+
+    /**
+     * A button to enable/disable the tracepoints group
+     */
+    private Button fTracepointsActivateButton;
+    /**
+     * A tree viewer for displaying and selection of available tracepoints.
+     */
+    private CheckboxTreeViewer fTracepointsViewer;
+    /**
+     * A button to enable/disable the syscalls group
+     */
+    private Button fSysCallsActivateButton;
+    /**
+     * A button to enable or disable the dynamic probe group.
+     */
+    private Button fProbeActivateButton;
+    /**
+     * The text field for the event name for the dynamic probe.
+     */
+    private Text fProbeEventNameText;
+    /**
+     * The text field for the dynamic probe.
+     */
+    private Text fProbeText;
+    /**
+     * A button to enable or disable the dynamic function probe group.
+     */
+    private Button fFunctionActivateButton;
+    /**
+     * The text field for the event name for the dynamic probe.
+     */
+    private Text fFunctionEventNameText;
+    /**
+     * The text field for the dynamic function entry/return probe.
+     */
+    private Text fFunctionText;
+    /**
+     * The referenced trace provider group containing the kernel provider
+     * component which contains a list of available tracepoints.
+     */
+    private final TraceProviderGroup fProviderGroup;
+    /**
+     * The flag indicating that tracepoints are selected.
+     */
+    private boolean fIsTracepoints;
+    /**
+     * The flag indicating that all tracepoints are selected.
+     */
+    private boolean fIsAllTracepoints;
+    /**
+     * The flag indicating that syscalls are selected.
+     */
+    private boolean fIsSysCalls;
+    /**
+     * The list of tracepoints to be enabled.
+     */
+    private List<String> fSelectedEvents;
+    /**
+     * The flag indicating that dynamic probe is selected.
+     */
+    private boolean fIsDynamicProbe;
+    /**
+     *  The event name of the dynamic probe.
+     */
+    private String fProbeEventName;
+    /**
+     * The dynamic probe.
+     */
+    private String fProbeString;
+    /**
+     * The flag indicating that the dynamic function probe is selected.
+     */
+    private boolean fIsDynamicFunctionProbe;
+    /**
+     * The event name of the dynamic function entry/return probe.
+     */
+    private String fFunctionEventName;
+    /**
+     * The dynamic function entry/return probe.
+     */
+    private String fFunctionString;
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+
+    /**
+     * Constructor
+     *
+     * @param parent
+     *            The parent composite
+     * @param style
+     *            The index of the style for this event composite
+     * @param providerGroup
+     *            The trace provider group
+     */
+    public EnableKernelEventComposite(Composite parent, int style, TraceProviderGroup providerGroup) {
+        super(parent, style);
+        fProviderGroup = providerGroup;
+    }
+
+    // ------------------------------------------------------------------------
+    // Acessors
+    // ------------------------------------------------------------------------
+
+    @Override
+    public boolean isTracepoints() {
+        return fIsTracepoints;
+    }
+
+    @Override
+    public boolean isAllTracePoints() {
+        return fIsAllTracepoints;
+    }
+
+    @Override
+    public boolean isSysCalls() {
+        return fIsSysCalls;
+    }
+
+    @Override
+    public boolean isAllSysCalls() {
+        return fIsSysCalls;
+    }
+
+    @Override
+    public List<String> getEventNames() {
+        return new ArrayList<>(fSelectedEvents);
+    }
+
+    @Override
+    public boolean isDynamicProbe() {
+        return fIsDynamicProbe;
+    }
+
+    @Override
+    public String getProbeName() {
+        return fProbeString;
+    }
+
+    @Override
+    public String getProbeEventName() {
+        return fProbeEventName;
+    }
+
+    @Override
+    public boolean isDynamicFunctionProbe() {
+        return fIsDynamicFunctionProbe;
+    }
+
+    @Override
+    public String getFunctionEventName() {
+        return fFunctionEventName;
+    }
+
+    @Override
+    public String getFunction() {
+        return fFunctionString;
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    /**
+     * Creates the composite content
+     */
+    public void createContent() {
+
+        // Tracepoints Group
+        createTracepointsGroup();
+
+        // Syscalls Group
+        createSysCallsGroup();
+
+        // Dynamic Probe Group
+        createDynamicProbeGroup();
+
+        // Dynamic Function Probe Group
+        createDynamicFunctionPropeGroup();
+
+        // Set default enablements
+        setKernelEnablements(KernelGroupEnum.TRACEPOINTS);
+    }
+
+    /**
+     * Validates the kernel composite input data.
+     * @return true if configured data is valid and can be retrieved.
+     */
+    public boolean isValid() {
+        fIsTracepoints = fTracepointsActivateButton.getSelection();
+        fIsSysCalls = fSysCallsActivateButton.getSelection();
+        fIsDynamicProbe = fProbeActivateButton.getSelection();
+        fIsDynamicFunctionProbe = fFunctionActivateButton.getSelection();
+
+        // initialize tracepoint fields
+        fIsAllTracepoints = false;
+        fSelectedEvents = new ArrayList<>();
+
+        if (fIsTracepoints) {
+            Object[] checkedElements = fTracepointsViewer.getCheckedElements();
+            for (int i = 0; i < checkedElements.length; i++) {
+                ITraceControlComponent component = (ITraceControlComponent)checkedElements[i];
+                if (component instanceof BaseEventComponent) {
+                    fSelectedEvents.add(component.getName());
+                }
+            }
+            // verify if all events are selected
+            int nbEvents = 0;
+            List<ITraceControlComponent> comps = fProviderGroup.getChildren(KernelProviderComponent.class);
+            for (ITraceControlComponent comp : comps) {
+                nbEvents += comp.getChildren().length;
+            }
+            fIsAllTracepoints = (nbEvents == fSelectedEvents.size());
+        }
+
+        if (fIsDynamicProbe) {
+            String temp = fProbeEventNameText.getText();
+            if (temp.isEmpty() ||
+                fProbeText.getText().matches("\\s*") || //$NON-NLS-1$
+                (!temp.matches("^[\\s]{0,}$") && !temp.matches("^[a-zA-Z0-9\\-\\_]{1,}$"))) { //$NON-NLS-1$ //$NON-NLS-2$
+                MessageDialog.openError(getShell(),
+                        Messages.TraceControl_EnableEventsDialogTitle,
+                        Messages.TraceControl_InvalidProbeNameError + " (" + temp + ") \n");  //$NON-NLS-1$ //$NON-NLS-2$
+
+                return false;
+            }
+
+            fProbeEventName = temp;
+            // fProbeString will be validated by lttng-tools
+            fProbeString = fProbeText.getText();
+        }
+
+        // initialize function string
+        fFunctionEventName = null;
+        fFunctionString = null;
+        if (fIsDynamicFunctionProbe) {
+            String functionTemp = fFunctionEventNameText.getText();
+            if (functionTemp.isEmpty() ||
+                functionTemp.matches("\\s*") || //$NON-NLS-1$
+                (!functionTemp.matches("^[\\s]{0,}$") && !functionTemp.matches("^[a-zA-Z0-9\\-\\_]{1,}$"))) { //$NON-NLS-1$ //$NON-NLS-2$
+                MessageDialog.openError(getShell(),
+                        Messages.TraceControl_EnableEventsDialogTitle,
+                        Messages.TraceControl_InvalidProbeNameError + " (" + functionTemp + ") \n");  //$NON-NLS-1$ //$NON-NLS-2$
+
+                return false;
+            }
+
+            fFunctionEventName = functionTemp;
+            // fFunctionString will be validated by lttng-tools
+            fFunctionString = fFunctionText.getText();
+        }
+
+        return true;
+    }
+
+    /**
+     * Creates tracepoints group.
+     */
+    private void createTracepointsGroup() {
+
+        GridLayout layout;
+        GridData data;
+        Group tpMainGroup = new Group(this, SWT.SHADOW_NONE);
+        tpMainGroup.setText(Messages.TraceControl_EnableEventsTracepointGroupName);
+        layout = new GridLayout(2, false);
+        tpMainGroup.setLayout(layout);
+        data = new GridData(GridData.FILL_BOTH);
+        tpMainGroup.setLayoutData(data);
+
+        Composite buttonComposite = new Composite(tpMainGroup, SWT.NONE);
+        layout = new GridLayout(1, true);
+        buttonComposite.setLayout(layout);
+        data = new GridData(SWT.BEGINNING, SWT.CENTER, false, true);
+        buttonComposite.setLayoutData(data);
+
+        fTracepointsActivateButton = new Button(buttonComposite, SWT.RADIO);
+        fTracepointsActivateButton.setText(Messages.TraceControl_EnableGroupSelectionName);
+        data = new GridData(GridData.FILL_HORIZONTAL);
+        fTracepointsActivateButton.setLayoutData(data);
+        fTracepointsActivateButton.addSelectionListener(new SelectionAdapter() {
+            @Override
+            public void widgetSelected(SelectionEvent e) {
+                setKernelEnablements(KernelGroupEnum.TRACEPOINTS);
+            }
+        });
+
+        Group tracepointsGroup = new Group(tpMainGroup, SWT.SHADOW_NONE);
+        layout = new GridLayout(1, true);
+        tracepointsGroup.setLayout(layout);
+        data = new GridData(GridData.FILL_BOTH);
+        tracepointsGroup.setLayoutData(data);
+
+        new FilteredTree(tracepointsGroup, SWT.MULTI | SWT.H_SCROLL | SWT.V_SCROLL | SWT.BORDER, new PatternFilter(), true) {
+            @Override
+            protected TreeViewer doCreateTreeViewer(Composite aparent, int style) {
+                fTracepointsViewer = new CheckboxTreeViewer(aparent, SWT.MULTI | SWT.H_SCROLL | SWT.V_SCROLL);
+                fTracepointsViewer.getTree().setToolTipText(Messages.TraceControl_EnableEventsTracepointTreeTooltip);
+
+                fTracepointsViewer.setContentProvider(new KernelContentProvider());
+                fTracepointsViewer.setLabelProvider(new KernelLabelProvider());
+                fTracepointsViewer.addCheckStateListener(new KernelCheckListener());
+                fTracepointsViewer.setInput(fProviderGroup);
+
+                fTracepointsViewer.getTree().setLayoutData(new GridData(GridData.FILL_BOTH));
+                return fTracepointsViewer;
+            }
+        };
+    }
+
+    /**
+     * Creates syscalls group.
+     */
+    private void createSysCallsGroup() {
+        GridLayout layout;
+        GridData data;
+        Group sysCallsMainGroup = new Group(this, SWT.SHADOW_NONE);
+        sysCallsMainGroup.setText(Messages.TraceControl_EnableEventsSyscallName);
+        sysCallsMainGroup.setToolTipText(Messages.TraceControl_EnableEventsSyscallTooltip);
+        layout = new GridLayout(2, false);
+        sysCallsMainGroup.setLayout(layout);
+        data = new GridData(GridData.FILL_HORIZONTAL);
+        sysCallsMainGroup.setLayoutData(data);
+
+        Composite buttonComposite = new Composite(sysCallsMainGroup, SWT.NONE);
+        layout = new GridLayout(1, false);
+        buttonComposite.setLayout(layout);
+        data = new GridData(SWT.BEGINNING, SWT.CENTER, false, true);
+        buttonComposite.setLayoutData(data);
+
+        fSysCallsActivateButton = new Button(buttonComposite, SWT.RADIO);
+        fSysCallsActivateButton.setText(Messages.TraceControl_EnableGroupSelectionName);
+        fSysCallsActivateButton.setToolTipText(Messages.TraceControl_EnableEventsSyscallTooltip);
+        fSysCallsActivateButton.setSelection(false);
+        data = new GridData(GridData.FILL_HORIZONTAL);
+        fSysCallsActivateButton.setLayoutData(data);
+        fSysCallsActivateButton.addSelectionListener(new SelectionAdapter() {
+            @Override
+            public void widgetSelected(SelectionEvent e) {
+                setKernelEnablements(KernelGroupEnum.SYSCALLS);
+            }
+        });
+    }
+
+    /**
+     * Creates dynamic probe group.
+     */
+    private void createDynamicProbeGroup() {
+        GridLayout layout;
+        GridData data;
+        Group probeMainGroup = new Group(this, SWT.SHADOW_NONE);
+        probeMainGroup.setText(Messages.TraceControl_EnableEventsProbeGroupName);
+        layout = new GridLayout(2, false);
+        probeMainGroup.setLayout(layout);
+        data = new GridData(GridData.FILL_HORIZONTAL);
+        probeMainGroup.setLayoutData(data);
+
+        Composite buttonComposite = new Composite(probeMainGroup, SWT.NONE);
+        layout = new GridLayout(1, false);
+        buttonComposite.setLayout(layout);
+        data = new GridData(SWT.BEGINNING, SWT.CENTER, false, true);
+        buttonComposite.setLayoutData(data);
+
+        fProbeActivateButton = new Button(buttonComposite, SWT.RADIO);
+        fProbeActivateButton.setText(Messages.TraceControl_EnableGroupSelectionName);
+        fProbeActivateButton.setSelection(false);
+        data = new GridData(GridData.FILL_HORIZONTAL);
+        fProbeActivateButton.setLayoutData(data);
+        fProbeActivateButton.addSelectionListener(new SelectionAdapter() {
+            @Override
+            public void widgetSelected(SelectionEvent e) {
+                setKernelEnablements(KernelGroupEnum.PROBE);
+            }
+        });
+
+        Group probeGroup = new Group(probeMainGroup, SWT.SHADOW_NONE);
+        layout = new GridLayout(4, true);
+        probeGroup.setLayout(layout);
+        probeGroup.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
+
+        Label probeNameLabel = new Label(probeGroup, SWT.LEFT);
+        probeNameLabel.setText(Messages.TraceControl_EnableEventsEventNameLabel);
+        data = new GridData(GridData.FILL_BOTH);
+        data.horizontalSpan = 1;
+        probeNameLabel.setLayoutData(data);
+
+        fProbeEventNameText = new Text(probeGroup, SWT.LEFT);
+        fProbeEventNameText.setToolTipText(Messages.TraceControl_EnableEventsProbeEventNameTooltip);
+
+        data = new GridData(GridData.FILL_BOTH);
+        data.horizontalSpan = 3;
+        fProbeEventNameText.setLayoutData(data);
+
+        Label probeLabel = new Label(probeGroup, SWT.LEFT);
+        probeLabel.setText(Messages.TraceControl_EnableEventsProbeNameLabel);
+        data = new GridData(GridData.FILL_BOTH);
+        data.horizontalSpan = 1;
+        probeLabel.setLayoutData(data);
+
+        fProbeText = new Text(probeGroup, SWT.LEFT);
+        fProbeText.setToolTipText(Messages.TraceControl_EnableEventsProbeNameTooltip);
+        data = new GridData(GridData.FILL_BOTH);
+        data.horizontalSpan = 3;
+        fProbeText.setLayoutData(data);
+    }
+
+    /**
+     * Creates dynamic function entry/return probe group.
+     */
+    private void createDynamicFunctionPropeGroup() {
+        GridLayout layout;
+        GridData data;
+        Group functionMainGroup = new Group(this, SWT.SHADOW_NONE);
+        functionMainGroup.setText(Messages.TraceControl_EnableEventsFucntionGroupName);
+        layout = new GridLayout(2, false);
+        functionMainGroup.setLayout(layout);
+        data = new GridData(GridData.FILL_HORIZONTAL);
+        functionMainGroup.setLayoutData(data);
+
+        Composite buttonComposite = new Composite(functionMainGroup, SWT.NONE);
+        layout = new GridLayout(1, false);
+        buttonComposite.setLayout(layout);
+        data = new GridData(SWT.BEGINNING, SWT.CENTER, false, true);
+        buttonComposite.setLayoutData(data);
+
+        fFunctionActivateButton = new Button(buttonComposite, SWT.RADIO);
+        fFunctionActivateButton.setText(Messages.TraceControl_EnableGroupSelectionName);
+        fFunctionActivateButton.setSelection(false);
+        data = new GridData(GridData.FILL_HORIZONTAL);
+        fFunctionActivateButton.setLayoutData(data);
+        fFunctionActivateButton.addSelectionListener(new SelectionAdapter() {
+            @Override
+            public void widgetSelected(SelectionEvent e) {
+                setKernelEnablements(KernelGroupEnum.FUNCTION);
+            }
+        });
+
+        Group functionGroup = new Group(functionMainGroup, SWT.SHADOW_NONE);
+        layout = new GridLayout(4, true);
+        functionGroup.setLayout(layout);
+        functionGroup.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
+
+        Label functionNameLabel = new Label(functionGroup, SWT.LEFT);
+        functionNameLabel.setText(Messages.TraceControl_EnableEventsEventNameLabel);
+        data = new GridData(GridData.FILL_BOTH);
+        data.horizontalSpan = 1;
+        functionNameLabel.setLayoutData(data);
+
+        fFunctionEventNameText = new Text(functionGroup, SWT.LEFT);
+        fFunctionEventNameText.setToolTipText(Messages.TraceControl_EnableEventsFunctionEventNameTooltip);
+        data = new GridData(GridData.FILL_BOTH);
+        data.horizontalSpan = 3;
+        fFunctionEventNameText.setLayoutData(data);
+
+        Label functionLabel = new Label(functionGroup, SWT.LEFT);
+        functionLabel.setText(Messages.TraceControl_EnableEventsFunctionNameLabel);
+        data = new GridData(GridData.FILL_BOTH);
+        data.horizontalSpan = 1;
+        functionLabel.setLayoutData(data);
+
+        fFunctionText = new Text(functionGroup, SWT.LEFT);
+        fFunctionText.setToolTipText(Messages.TraceControl_EnableEventsProbeNameTooltip);
+        data = new GridData(GridData.FILL_BOTH);
+        data.horizontalSpan = 3;
+        fFunctionText.setLayoutData(data);
+    }
+
+    /**
+     * Enable/selects widgets depending on the group specified.
+     * @param group - group to enable.
+     */
+    private void setKernelEnablements(KernelGroupEnum group) {
+        fTracepointsActivateButton.setSelection(group == KernelGroupEnum.TRACEPOINTS);
+        fTracepointsViewer.getTree().setEnabled(group == KernelGroupEnum.TRACEPOINTS);
+
+        fSysCallsActivateButton.setSelection(group == KernelGroupEnum.SYSCALLS);
+
+        fProbeActivateButton.setSelection(group == KernelGroupEnum.PROBE);
+        fProbeEventNameText.setEnabled(group == KernelGroupEnum.PROBE);
+        fProbeText.setEnabled(group == KernelGroupEnum.PROBE);
+
+        fFunctionActivateButton.setSelection(group == KernelGroupEnum.FUNCTION);
+        fFunctionEventNameText.setEnabled(group == KernelGroupEnum.FUNCTION);
+        fFunctionText.setEnabled(group == KernelGroupEnum.FUNCTION);
+    }
+
+    // ------------------------------------------------------------------------
+    // Local classes
+    // ------------------------------------------------------------------------
+    /**
+     * Content provider for the tracepoints tree.
+     */
+    public static final class KernelContentProvider extends TraceControlContentProvider {
+        @Override
+        public Object[] getChildren(Object parentElement) {
+            if (parentElement instanceof TraceProviderGroup) {
+                List<ITraceControlComponent> children = ((ITraceControlComponent)parentElement).getChildren(KernelProviderComponent.class);
+                return children.toArray(new ITraceControlComponent[children.size()]);
+            }
+            if (parentElement instanceof ITraceControlComponent) {
+                return ((ITraceControlComponent)parentElement).getChildren();
+            }
+            return new Object[0];
+        }
+    }
+
+    /**
+     * Content label for the tracepoints tree.
+     */
+    public static final class KernelLabelProvider extends TraceControlLabelProvider {
+        @Override
+        public Image getImage(Object element) {
+            return null;
+        }
+        @Override
+        public String getText(Object element) {
+            if ((element != null) && (element instanceof KernelProviderComponent)) {
+                return Messages.TraceControl_EnableEventsTracepointTreeAllLabel;
+            }
+            return super.getText(element);
+        }
+    }
+
+    /**
+     * Check state listener for the tracepoints tree.
+     */
+    public final class KernelCheckListener implements ICheckStateListener {
+        @Override
+        public void checkStateChanged(CheckStateChangedEvent event) {
+          if (event.getChecked()) {
+              if (event.getElement() instanceof KernelProviderComponent) {
+                  fTracepointsViewer.setSubtreeChecked(event.getElement(), true);
+              }
+          } else {
+              if (event.getElement() instanceof KernelProviderComponent) {
+                  fTracepointsViewer.setSubtreeChecked(event.getElement(), false);
+              } else {
+                  ITraceControlComponent component = (ITraceControlComponent) event.getElement();
+                  fTracepointsViewer.setChecked(component.getParent(), false);
+              }
+          }
+        }
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/EnableUstEventsComposite.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/EnableUstEventsComposite.java
new file mode 100644 (file)
index 0000000..637aca8
--- /dev/null
@@ -0,0 +1,649 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2015 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
+ *   Marc-Andre Laperle - Add filtering textbox
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
+
+import java.util.ArrayList;
+import java.util.HashSet;
+import java.util.List;
+import java.util.Set;
+
+import org.eclipse.jface.dialogs.MessageDialog;
+import org.eclipse.jface.viewers.CheckStateChangedEvent;
+import org.eclipse.jface.viewers.CheckboxTreeViewer;
+import org.eclipse.jface.viewers.ICheckStateListener;
+import org.eclipse.jface.viewers.TreeViewer;
+import org.eclipse.swt.SWT;
+import org.eclipse.swt.custom.CCombo;
+import org.eclipse.swt.events.SelectionAdapter;
+import org.eclipse.swt.events.SelectionEvent;
+import org.eclipse.swt.graphics.Image;
+import org.eclipse.swt.layout.GridData;
+import org.eclipse.swt.layout.GridLayout;
+import org.eclipse.swt.widgets.Button;
+import org.eclipse.swt.widgets.Composite;
+import org.eclipse.swt.widgets.Group;
+import org.eclipse.swt.widgets.Label;
+import org.eclipse.swt.widgets.Text;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.LogLevelType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.BaseEventComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceControlContentProvider;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceControlLabelProvider;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceProviderGroup;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.UstProviderComponent;
+import org.eclipse.ui.dialogs.FilteredTree;
+import org.eclipse.ui.dialogs.PatternFilter;
+
+/**
+ * <p>
+ * A composite for collecting information about UST events to be enabled.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class EnableUstEventsComposite extends Composite implements IEnableUstEvents  {
+
+    // ------------------------------------------------------------------------
+    // Constants
+    // ------------------------------------------------------------------------
+
+    private enum GroupEnum { TRACEPOINTS, WILDCARD, LOGLEVEL }
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+
+    /**
+     * A button to enable/disable the tracepoints group
+     */
+    private Button fTracepointsActivateButton;
+    /**
+     * A tree viewer for diplaying and selection of available tracepoints.
+     */
+    private CheckboxTreeViewer fTracepointsViewer;
+    /**
+     * A button to enable/disable the wildcard group
+     */
+    private Button fWildcardActivateButton;
+    /**
+     * A Text field for the event's wildcard.
+     */
+    private Text fWildcardText;
+    /**
+     * A button to enable/disable the log level group
+     */
+    private Button fLogLevelActivateButton;
+    /**
+     * A Text field for the event name for the log level enablement.
+     */
+    private Text fLogLevelEventNameText;
+    /**
+     * A Combo box for selecting the log level.
+     */
+    private CCombo fLogLevelCombo;
+    /**
+     * A button for selecting the log level (range 0 to level).
+     */
+    private Button fLogLevelButton;
+    /**
+     * A button for selecting the specified log level only.
+     */
+    private Button fLogLevelOnlyButton;
+    /**
+     * The filter text
+     */
+    private Text fFilterText;
+
+    /**
+     * The referenced trace provider group containing the UST providers
+     * component which contains a list of available tracepoints.
+     */
+    private final TraceProviderGroup fProviderGroup;
+    /**
+     * The flag indicating that tracepoints are selected.
+     */
+    private boolean fIsTracepoints;
+    /**
+     * The flag indicating that all tracepoints (across providers) are selected.
+     */
+    private boolean fIsAllTracepoints;
+    /**
+     * The list of tracepoints to be enabled.
+     */
+    private List<String> fSelectedEvents;
+    /**
+     * The flag indicating that all wildcard are selected..
+     */
+    private boolean fIsWildcard;
+    /**
+     * The wildcard if wildcard is selected.
+     */
+    private String fWildcard;
+    /**
+     *The flag indicating that all log level are selected.
+     */
+    private boolean fIsLogLevel;
+    /**
+     * The event name for the log level enablement.
+     */
+    private String fLogLevelEventName;
+    /**
+     * The type of the log level (loglevel or loglevel-only)
+     */
+    private LogLevelType fLogLevelType;
+    /**
+     * The actual selected log level.
+     */
+    private TraceLogLevel fLogLevel;
+    /**
+     * The filter expression
+     */
+    private String fFilterExpression;
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+    /**
+     * Constructor
+     * @param parent - a parent composite
+     * @param style - a composite style
+     * @param providerGroup - the trace provider group
+     */
+    public EnableUstEventsComposite(Composite parent, int style, TraceProviderGroup providerGroup) {
+        super(parent, style);
+        fProviderGroup = providerGroup;
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    @Override
+    public boolean isTracepoints() {
+        return fIsTracepoints;
+    }
+
+    @Override
+    public boolean isAllTracePoints() {
+        return fIsAllTracepoints;
+    }
+
+    @Override
+    public List<String> getEventNames() {
+        return new ArrayList<>(fSelectedEvents);
+    }
+
+    @Override
+    public boolean isWildcard() {
+        return fIsWildcard;
+    }
+
+    @Override
+    public String getWildcard() {
+        return fWildcard;
+    }
+
+    @Override
+    public boolean isLogLevel() {
+        return fIsLogLevel;
+    }
+
+    @Override
+    public LogLevelType getLogLevelType() {
+        return fLogLevelType;
+    }
+
+    @Override
+    public TraceLogLevel getLogLevel() {
+        return fLogLevel;
+    }
+
+    @Override
+    public String getLogLevelEventName() {
+        return fLogLevelEventName;
+    }
+
+    @Override
+    public String getFilterExpression() {
+        return fFilterExpression;
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    /**
+     * Create the contents of this event composite
+     */
+    public void createContent() {
+
+        // Tracepoints Group
+        createTracepointsGroup();
+
+        // Wildcard Group
+        createWildCardGroup();
+
+        // Log Level Group
+        createLogLevelGroup();
+
+        // Filter Group
+        createFilterGroup();
+
+        // Set default enablements
+        setEnablements(GroupEnum.TRACEPOINTS);
+    }
+
+    /**
+     * Validates the UST composite input data.
+     *
+     * @return true if configured data is valid and can be retrieved.
+     */
+    public boolean isValid() {
+
+        fIsTracepoints = fTracepointsActivateButton.getSelection();
+        fIsWildcard = fWildcardActivateButton.getSelection();
+        fIsLogLevel = fLogLevelActivateButton.getSelection();
+
+        // initialize tracepoint fields
+        fIsAllTracepoints = false;
+        fSelectedEvents = new ArrayList<>();
+        if (fIsTracepoints) {
+            Set<String> set = new HashSet<>();
+            Object[] checkedElements = fTracepointsViewer.getCheckedElements();
+            int totalNbEvents = 0;
+            for (int i = 0; i < checkedElements.length; i++) {
+                ITraceControlComponent component = (ITraceControlComponent) checkedElements[i];
+                if (component instanceof BaseEventComponent) {
+                    totalNbEvents++;
+                    if (!set.contains(component.getName())) {
+                        set.add(component.getName());
+                        fSelectedEvents.add(component.getName());
+                    }
+                }
+
+            }
+
+            // verify if all events are selected
+            int nbUstEvents = 0;
+            List<ITraceControlComponent> comps = fProviderGroup.getChildren(UstProviderComponent.class);
+            for (ITraceControlComponent comp : comps) {
+                nbUstEvents += comp.getChildren().length;
+            }
+            fIsAllTracepoints = (nbUstEvents == totalNbEvents);
+        }
+
+        // initialize log level event name string
+        fLogLevelType = LogLevelType.LOGLEVEL_NONE;
+        fLogLevelEventName = null;
+
+        if (fIsLogLevel) {
+            if (fLogLevelButton.getSelection()) {
+                fLogLevelType = LogLevelType.LOGLEVEL;
+            } else if (fLogLevelOnlyButton.getSelection()) {
+                fLogLevelType = LogLevelType.LOGLEVEL_ONLY;
+            }
+
+            String temp = fLogLevelEventNameText.getText();
+            if (temp.isEmpty() ||
+                temp.matches("\\s*") || //$NON-NLS-1$
+                (!temp.matches("^[\\s]{0,}$") && !temp.matches("^[a-zA-Z0-9\\-\\_]{1,}$"))) { //$NON-NLS-1$ //$NON-NLS-2$
+                MessageDialog.openError(getShell(),
+                        Messages.TraceControl_EnableEventsDialogTitle,
+                        Messages.TraceControl_InvalidLogLevelEventNameError + " (" + temp + ") \n");  //$NON-NLS-1$ //$NON-NLS-2$
+
+                return false;
+            }
+
+            fLogLevelEventName = temp;
+
+            TraceLogLevel[] levels = TraceLogLevel.values();
+            int id = fLogLevelCombo.getSelectionIndex();
+
+            if (id < 0) {
+                MessageDialog.openError(getShell(),
+                        Messages.TraceControl_EnableEventsDialogTitle,
+                        Messages.TraceControl_InvalidLogLevel + " (" + temp + ") \n");  //$NON-NLS-1$ //$NON-NLS-2$
+
+                return false;
+            }
+            fLogLevel = levels[id];
+        }
+
+        // initialize wildcard with null
+        fWildcard = null;
+        if (fIsWildcard) {
+            String tempWildcard = fWildcardText.getText();
+            if (tempWildcard.isEmpty() ||
+                tempWildcard.matches("\\s*") || //$NON-NLS-1$
+                (!tempWildcard.matches("^[\\s]{0,}$") && !tempWildcard.matches("^[a-zA-Z0-9\\-\\_\\*\\\\\\']{1,}$"))) { //$NON-NLS-1$ //$NON-NLS-2$
+                MessageDialog.openError(getShell(),
+                        Messages.TraceControl_EnableEventsDialogTitle,
+                        Messages.TraceControl_InvalidWildcardError + " (" + tempWildcard + ") \n");  //$NON-NLS-1$ //$NON-NLS-2$
+
+                return false;
+            }
+
+            fWildcard = tempWildcard;
+        }
+
+        // initialize filter with null
+        fFilterExpression = null;
+        if (fProviderGroup.isEventFilteringSupported()) {
+            String tempFilter = fFilterText.getText();
+
+            if(!tempFilter.isEmpty() && !tempFilter.matches("\\s*")) { //$NON-NLS-1$
+                fFilterExpression = tempFilter;
+            }
+        }
+
+        // validation successful -> call super.okPressed()
+        return true;
+    }
+
+    // ------------------------------------------------------------------------
+    // Helper methods
+    // ------------------------------------------------------------------------
+
+    /**
+     * Creates tracepoints group.
+     */
+    private void createTracepointsGroup() {
+        Group tpMainGroup = new Group(this, SWT.SHADOW_NONE);
+        tpMainGroup.setText(Messages.TraceControl_EnableEventsTracepointGroupName);
+        GridLayout layout = new GridLayout(2, false);
+        tpMainGroup.setLayout(layout);
+        GridData data = new GridData(GridData.FILL_BOTH);
+        tpMainGroup.setLayoutData(data);
+
+        Composite buttonComposite = new Composite(tpMainGroup, SWT.NONE);
+        layout = new GridLayout(1, true);
+        buttonComposite.setLayout(layout);
+        data = new GridData(SWT.BEGINNING, SWT.CENTER, false, true);
+        buttonComposite.setLayoutData(data);
+
+        fTracepointsActivateButton = new Button(buttonComposite, SWT.RADIO);
+        fTracepointsActivateButton.setText(Messages.TraceControl_EnableGroupSelectionName);
+        data = new GridData(GridData.FILL_HORIZONTAL);
+        fTracepointsActivateButton.setLayoutData(data);
+        fTracepointsActivateButton.addSelectionListener(new SelectionAdapter() {
+            @Override
+            public void widgetSelected(SelectionEvent e) {
+                setEnablements(GroupEnum.TRACEPOINTS);
+            }
+        });
+
+        Group tpGroup = new Group(tpMainGroup, SWT.SHADOW_NONE);
+        layout = new GridLayout(1, true);
+        tpGroup.setLayout(layout);
+        data = new GridData(GridData.FILL_BOTH);
+        tpGroup.setLayoutData(data);
+        new FilteredTree(tpGroup, SWT.MULTI | SWT.H_SCROLL | SWT.V_SCROLL | SWT.BORDER, new PatternFilter(), true) {
+            @Override
+            protected TreeViewer doCreateTreeViewer(Composite aparent, int style) {
+                fTracepointsViewer = new CheckboxTreeViewer(aparent, SWT.MULTI | SWT.H_SCROLL | SWT.V_SCROLL);
+                fTracepointsViewer.getTree().setToolTipText(Messages.TraceControl_EnableEventsTracepointTreeTooltip);
+                fTracepointsViewer.setContentProvider(new UstContentProvider());
+
+                fTracepointsViewer.setLabelProvider(new UstLabelProvider());
+                fTracepointsViewer.addCheckStateListener(new UstCheckStateListener());
+
+                fTracepointsViewer.setInput(fProviderGroup.getParent());
+                fTracepointsViewer.getTree().setLayoutData(new GridData(GridData.FILL_BOTH));
+                return fTracepointsViewer;
+            }
+        };
+    }
+
+    /**
+     * Creates wildcard group.
+     */
+    private void createWildCardGroup() {
+        Group wildcardMainGroup = new Group(this, SWT.SHADOW_NONE);
+        wildcardMainGroup.setText(Messages.TraceControl_EnableEventsWildcardGroupName);
+        GridLayout layout = new GridLayout(2, false);
+        wildcardMainGroup.setLayout(layout);
+        GridData data = new GridData(GridData.FILL_HORIZONTAL);
+        wildcardMainGroup.setLayoutData(data);
+
+        Composite buttonComposite = new Composite(wildcardMainGroup, SWT.NONE);
+        layout = new GridLayout(1, false);
+        buttonComposite.setLayout(layout);
+        data = new GridData(SWT.BEGINNING, SWT.CENTER, false, true);
+        buttonComposite.setLayoutData(data);
+
+        fWildcardActivateButton = new Button(buttonComposite, SWT.RADIO);
+        fWildcardActivateButton.setText(Messages.TraceControl_EnableGroupSelectionName);
+        fWildcardActivateButton.setSelection(false);
+        data = new GridData(GridData.FILL_HORIZONTAL);
+        fWildcardActivateButton.setLayoutData(data);
+        fWildcardActivateButton.addSelectionListener(new SelectionAdapter() {
+            @Override
+            public void widgetSelected(SelectionEvent e) {
+                setEnablements(GroupEnum.WILDCARD);
+            }
+        });
+
+        Group wildcardGroup = new Group(wildcardMainGroup, SWT.SHADOW_NONE);
+        layout = new GridLayout(3, true);
+        wildcardGroup.setLayout(layout);
+        data = new GridData(GridData.FILL_HORIZONTAL);
+        wildcardGroup.setLayoutData(data);
+
+        Label wildcardLabel = new Label(wildcardGroup, SWT.LEFT);
+        wildcardLabel.setText(Messages.TraceControl_EnableEventsWildcardLabel);
+        data = new GridData(GridData.FILL_HORIZONTAL);
+        data.horizontalSpan = 1;
+        wildcardLabel.setLayoutData(data);
+
+        fWildcardText = new Text(wildcardGroup, SWT.LEFT);
+        fWildcardText.setToolTipText(Messages.TraceControl_EnableEventsWildcardTooltip);
+        data = new GridData(GridData.FILL_HORIZONTAL);
+        data.horizontalSpan = 2;
+        fWildcardText.setLayoutData(data);
+    }
+
+    /**
+     * Creates log level group.
+     */
+    private void createLogLevelGroup() {
+        Group logLevelMainGroup = new Group(this, SWT.SHADOW_NONE);
+        logLevelMainGroup.setText(Messages.TraceControl_EnableEventsLogLevelGroupName);
+        GridLayout layout = new GridLayout(2, false);
+        logLevelMainGroup.setLayout(layout);
+        GridData data = new GridData(GridData.FILL_HORIZONTAL);
+        logLevelMainGroup.setLayoutData(data);
+
+        Composite buttonComposite = new Composite(logLevelMainGroup, SWT.NONE);
+        layout = new GridLayout(1, false);
+        buttonComposite.setLayout(layout);
+        data = new GridData(SWT.BEGINNING, SWT.CENTER, false, true);
+        buttonComposite.setLayoutData(data);
+
+        fLogLevelActivateButton = new Button(buttonComposite, SWT.RADIO);
+        fLogLevelActivateButton.setText(Messages.TraceControl_EnableGroupSelectionName);
+        fLogLevelActivateButton.setSelection(false);
+        data = new GridData(GridData.FILL_HORIZONTAL);
+        fLogLevelActivateButton.setLayoutData(data);
+        fLogLevelActivateButton.addSelectionListener(new SelectionAdapter() {
+            @Override
+            public void widgetSelected(SelectionEvent e) {
+                setEnablements(GroupEnum.LOGLEVEL);
+            }
+        });
+
+        Group logLevelGroup = new Group(logLevelMainGroup, SWT.SHADOW_NONE);
+        layout = new GridLayout(3, true);
+        logLevelGroup.setLayout(layout);
+        logLevelGroup.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
+
+        Label logLevelEventNameLabel = new Label(logLevelGroup, SWT.LEFT);
+        logLevelEventNameLabel.setText(Messages.TraceControl_EnableEventsEventNameLabel);
+
+        data = new GridData(GridData.FILL_BOTH);
+        data.horizontalSpan = 1;
+        logLevelEventNameLabel.setLayoutData(data);
+
+        fLogLevelEventNameText = new Text(logLevelGroup, SWT.LEFT);
+        fLogLevelEventNameText.setToolTipText(Messages.TraceControl_EnableEventsLoglevelEventNameTooltip);
+        data = new GridData(GridData.FILL_BOTH);
+        data.horizontalSpan = 2;
+        fLogLevelEventNameText.setLayoutData(data);
+
+        TraceLogLevel[] levels = TraceLogLevel.values();
+
+        String[] levelNames = new String[levels.length - 1];
+        int k = 0;
+        for (int i = 0; i < levels.length; i++) {
+            if (levels[i] != TraceLogLevel.LEVEL_UNKNOWN) {
+                levelNames[k++] = levels[i].getInName();
+            }
+        }
+
+        fLogLevelCombo = new CCombo(logLevelGroup, SWT.READ_ONLY);
+        fLogLevelCombo.setItems(levelNames);
+        fLogLevelCombo.setToolTipText(Messages.TraceControl_EnableEventsLogLevelTooltip);
+        data = new GridData(GridData.FILL_HORIZONTAL);
+        data.horizontalSpan = 4;
+        fLogLevelCombo.setLayoutData(data);
+
+        fLogLevelButton = new Button(logLevelGroup, SWT.RADIO);
+        fLogLevelButton.setText(Messages.TraceControl_EnableEventsLogLevelTypeName);
+        fLogLevelButton.setToolTipText(Messages.TraceControl_EnableEventsLogLevelTypeTooltip);
+        data = new GridData(GridData.FILL_BOTH);
+        fLogLevelButton.setLayoutData(data);
+        fLogLevelButton.setSelection(true);
+
+        fLogLevelOnlyButton = new Button(logLevelGroup, SWT.RADIO);
+        fLogLevelOnlyButton.setText(Messages.TraceControl_EnableEventsLogLevelOnlyTypeName);
+        fLogLevelOnlyButton.setToolTipText(Messages.TraceControl_EnableEventsLogLevelOnlyTypeTooltip);
+        data = new GridData(GridData.FILL_BOTH);
+        fLogLevelButton.setLayoutData(data);
+    }
+
+    void createFilterGroup() {
+        if (fProviderGroup.isEventFilteringSupported()) {
+            Group filterMainGroup = new Group(this, SWT.SHADOW_NONE);
+            filterMainGroup.setText(Messages.TraceControl_EnableEventsFilterGroupName);
+            GridLayout layout = new GridLayout(3, false);
+            filterMainGroup.setLayout(layout);
+            GridData data = new GridData(GridData.FILL_HORIZONTAL);
+            filterMainGroup.setLayoutData(data);
+
+            fFilterText = new Text(filterMainGroup, SWT.LEFT);
+            fFilterText.setToolTipText(Messages.TraceControl_EnableEventsFilterTooltip);
+            data = new GridData(GridData.FILL_HORIZONTAL);
+            fFilterText.setLayoutData(data);
+        }
+    }
+
+    /**
+     * Enable/selects widgets depending on the group specified.
+     * @param group - group to enable.
+     */
+    private void setEnablements(GroupEnum group) {
+
+        // Enable/disable trace point items
+        fTracepointsActivateButton.setSelection(group == GroupEnum.TRACEPOINTS);
+        fTracepointsViewer.getTree().setEnabled(group == GroupEnum.TRACEPOINTS);
+
+        // Enable/disable wildcard items
+        fWildcardActivateButton.setSelection(group == GroupEnum.WILDCARD);
+        fWildcardText.setEnabled(group == GroupEnum.WILDCARD);
+
+        // Enable/disable log level items
+        fLogLevelActivateButton.setSelection(group == GroupEnum.LOGLEVEL);
+        fLogLevelEventNameText.setEnabled(group == GroupEnum.LOGLEVEL);
+        fLogLevelCombo.setEnabled(group == GroupEnum.LOGLEVEL);
+        fLogLevelButton.setEnabled(group == GroupEnum.LOGLEVEL);
+        fLogLevelOnlyButton.setEnabled(group == GroupEnum.LOGLEVEL);
+    }
+
+    // ------------------------------------------------------------------------
+    // Local classes
+    // ------------------------------------------------------------------------
+    /**
+     * Content provider for the tracepoints tree.
+     */
+    public static final class UstContentProvider extends TraceControlContentProvider {
+        @Override
+        public Object[] getChildren(Object parentElement) {
+            if (parentElement instanceof TargetNodeComponent) {
+                List<ITraceControlComponent> children = ((ITraceControlComponent)parentElement).getChildren(TraceProviderGroup.class);
+                return children.toArray(new ITraceControlComponent[children.size()]);
+            }
+            if (parentElement instanceof TraceProviderGroup) {
+                List<ITraceControlComponent> children = ((ITraceControlComponent)parentElement).getChildren(UstProviderComponent.class);
+                return children.toArray(new ITraceControlComponent[children.size()]);
+            }
+            if (parentElement instanceof ITraceControlComponent) {
+                return ((ITraceControlComponent)parentElement).getChildren();
+            }
+            return new Object[0];
+        }
+    }
+
+    /**
+     * Content label for the tracepoints tree.
+     */
+    public static final class UstLabelProvider extends TraceControlLabelProvider {
+        @Override
+        public Image getImage(Object element) {
+            return null;
+        }
+        @Override
+        public String getText(Object element) {
+            if ((element != null) && (element instanceof TraceProviderGroup)) {
+                return Messages.TraceControl_EnableEventsTracepointTreeAllLabel;
+            }
+
+            if ((element != null) && (element instanceof UstProviderComponent)) {
+                return Messages.TraceControl_EnableEventsTracepointTreeAllLabel + " - " + ((UstProviderComponent)element).getName(); //$NON-NLS-1$
+            }
+            return super.getText(element);
+        }
+    }
+
+    /**
+     * Check state listener for the tracepoints tree.
+     */
+    public final class UstCheckStateListener implements ICheckStateListener {
+        @Override
+        public void checkStateChanged(CheckStateChangedEvent event) {
+            if (event.getChecked()) {
+                if (event.getElement() instanceof TraceProviderGroup) {
+                    fTracepointsViewer.setSubtreeChecked(event.getElement(), true);
+                }
+                if (event.getElement() instanceof UstProviderComponent) {
+                    fTracepointsViewer.setSubtreeChecked(event.getElement(), true);
+                }
+            } else {
+                if (event.getElement() instanceof TraceProviderGroup) {
+                    fTracepointsViewer.setSubtreeChecked(event.getElement(), true);
+                }
+                if (event.getElement() instanceof UstProviderComponent) {
+                    ITraceControlComponent component = (ITraceControlComponent) event.getElement();
+                    fTracepointsViewer.setSubtreeChecked(event.getElement(), false);
+                    fTracepointsViewer.setChecked(component.getParent(), false);
+                } else {
+                    ITraceControlComponent component = (ITraceControlComponent) event.getElement();
+                    fTracepointsViewer.setChecked(component.getParent(), false);
+                    fTracepointsViewer.setChecked(component.getParent().getParent(), false);
+                }
+            }
+        }
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/GetEventInfoDialog.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/GetEventInfoDialog.java
new file mode 100644 (file)
index 0000000..88c156a
--- /dev/null
@@ -0,0 +1,281 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
+
+import java.util.Arrays;
+
+import org.eclipse.jface.dialogs.Dialog;
+import org.eclipse.jface.dialogs.IDialogConstants;
+import org.eclipse.jface.dialogs.MessageDialog;
+import org.eclipse.swt.SWT;
+import org.eclipse.swt.custom.CCombo;
+import org.eclipse.swt.events.SelectionEvent;
+import org.eclipse.swt.events.SelectionListener;
+import org.eclipse.swt.graphics.Point;
+import org.eclipse.swt.layout.GridData;
+import org.eclipse.swt.layout.GridLayout;
+import org.eclipse.swt.widgets.Composite;
+import org.eclipse.swt.widgets.Control;
+import org.eclipse.swt.widgets.Group;
+import org.eclipse.swt.widgets.Shell;
+import org.eclipse.swt.widgets.Text;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
+
+/**
+ * <p>
+ * Dialog box for collecting information about the events to enable.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class GetEventInfoDialog extends Dialog implements IGetEventInfoDialog {
+
+    // ------------------------------------------------------------------------
+    // Constants
+    // ------------------------------------------------------------------------
+    /**
+     * The icon file for this dialog box.
+     */
+    public static final String TARGET_NEW_CONNECTION_ICON_FILE = "icons/elcl16/enable_event.gif"; //$NON-NLS-1$
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+    /**
+     * The session combo box.
+     */
+    private CCombo fSessionsCombo = null;
+    /**
+     * The channel combo box.
+     */
+    private CCombo fChannelsCombo = null;
+    /**
+     * The filter text
+     */
+    private Text fFilterText;
+    /**
+     * The list of available sessions.
+     */
+    private TraceSessionComponent[] fSessions;
+    /**
+     * True for kernel, false for UST.
+     */
+    private boolean fIsKernel;
+    /**
+     * Index in session array (selected session).
+     */
+    private int fSessionIndex = 0;
+    /**
+     * The Channel where the events should be enabled.
+     */
+    private TraceChannelComponent fChannel;
+    /**
+     * List of available channels of the selected session.
+     */
+    private TraceChannelComponent[] fChannels;
+    /**
+     * The filter expression
+     */
+    private String fFilterExpression;
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+    /**
+     * Constructor of dialog box.
+     * @param shell - the shell for the dialog box
+     */
+    public GetEventInfoDialog(Shell shell) {
+        super(shell);
+        setShellStyle(SWT.RESIZE | getShellStyle());
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    @Override
+    public TraceSessionComponent getSession() {
+        return fSessions[fSessionIndex];
+    }
+
+    @Override
+    public TraceChannelComponent getChannel() {
+        return fChannel;
+    }
+
+    @Override
+    public void setIsKernel(boolean isKernel) {
+        fIsKernel = isKernel;
+    }
+
+    @Override
+    public void setSessions(TraceSessionComponent[] sessions) {
+        fSessions = Arrays.copyOf(sessions, sessions.length);
+    }
+
+    @Override
+    public String getFilterExpression() {
+       return fFilterExpression;
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    protected void configureShell(Shell newShell) {
+        super.configureShell(newShell);
+        newShell.setText(Messages.TraceControl_EnableEventsDialogTitle);
+        newShell.setImage(Activator.getDefault().loadIcon(TARGET_NEW_CONNECTION_ICON_FILE));
+    }
+
+    @Override
+    protected Control createDialogArea(Composite parent) {
+
+        // Main dialog panel
+        Composite dialogComposite = new Composite(parent, SWT.NONE);
+        GridLayout layout = new GridLayout(1, true);
+        dialogComposite.setLayout(layout);
+        dialogComposite.setLayoutData(new GridData(GridData.FILL_BOTH));
+
+        Group sessionsGroup = new Group(dialogComposite, SWT.SHADOW_NONE);
+        sessionsGroup.setText(Messages.TraceControl_EnableEventsSessionGroupName);
+        layout = new GridLayout(1, true);
+        sessionsGroup.setLayout(layout);
+        GridData data = new GridData(GridData.FILL_HORIZONTAL);
+        sessionsGroup.setLayoutData(data);
+
+        fSessionsCombo = new CCombo(sessionsGroup, SWT.READ_ONLY);
+        fSessionsCombo.setToolTipText(Messages.TraceControl_EnableEventsSessionsTooltip);
+        fSessionsCombo.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
+
+        String items[] = new String[fSessions.length];
+        for (int i = 0; i < items.length; i++) {
+            items[i] = String.valueOf(fSessions[i].getName());
+        }
+
+        fSessionsCombo.setItems(items);
+        fSessionsCombo.setEnabled(fSessions.length > 0);
+
+        Group channelsGroup = new Group(dialogComposite, SWT.SHADOW_NONE);
+        channelsGroup.setText(Messages.TraceControl_EnableEventsChannelGroupName);
+        layout = new GridLayout(1, true);
+        channelsGroup.setLayout(layout);
+        data = new GridData(GridData.FILL_HORIZONTAL);
+        channelsGroup.setLayoutData(data);
+
+        fChannelsCombo = new CCombo(channelsGroup, SWT.READ_ONLY);
+        fChannelsCombo.setToolTipText(Messages.TraceControl_EnableEventsChannelsTooltip);
+        fChannelsCombo.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
+        fChannelsCombo.setEnabled(false);
+
+        fSessionsCombo.addSelectionListener(new SelectionListener() {
+            @Override
+            public void widgetSelected(SelectionEvent e) {
+                fSessionIndex = fSessionsCombo.getSelectionIndex();
+
+                if (fSessionIndex >= 0) {
+                    TraceDomainComponent domain = null;
+                    TraceDomainComponent[] domains = fSessions[fSessionIndex].getDomains();
+                    for (int i = 0; i < domains.length; i++) {
+
+                        if (domains[i].isKernel() == fIsKernel) {
+                            domain = domains[i];
+                            break;
+                        }
+                    }
+
+                    if (domain != null) {
+                        fChannels = domain.getChannels();
+                        String selectionItems[] = new String[fChannels.length];
+                        for (int i = 0; i < selectionItems.length; i++) {
+                            selectionItems[i] = String.valueOf(fChannels[i].getName());
+                        }
+                        fChannelsCombo.setItems(selectionItems);
+                        fChannelsCombo.setEnabled(fChannels.length > 0);
+                    } else {
+                        fChannelsCombo.setItems(new String[0]);
+                        fChannelsCombo.setEnabled(false);
+                        fChannels = null;
+                   }
+                   fChannelsCombo.getParent().getParent().layout();
+                }
+            }
+
+            @Override
+            public void widgetDefaultSelected(SelectionEvent e) {
+            }
+        });
+
+        // take first session to test whether events filtering is supported or not
+        if (fSessions[0].isEventFilteringSupported() && !fIsKernel) {
+            Group filterMainGroup = new Group(dialogComposite, SWT.SHADOW_NONE);
+            filterMainGroup.setText(Messages.TraceControl_EnableEventsFilterGroupName);
+            layout = new GridLayout(2, false);
+            filterMainGroup.setLayout(layout);
+            data = new GridData(GridData.FILL_HORIZONTAL);
+            filterMainGroup.setLayoutData(data);
+
+            fFilterText = new Text(filterMainGroup, SWT.LEFT);
+            fFilterText.setToolTipText(Messages.TraceControl_EnableEventsFilterTooltip);
+            data = new GridData(GridData.FILL_HORIZONTAL);
+            fFilterText.setLayoutData(data);
+        }
+
+        getShell().setMinimumSize(new Point(300, 200));
+
+        return dialogComposite;
+    }
+
+    @Override
+    protected void createButtonsForButtonBar(Composite parent) {
+        createButton(parent, IDialogConstants.CANCEL_ID, "&Cancel", true); //$NON-NLS-1$
+        createButton(parent, IDialogConstants.OK_ID, "&Ok", true); //$NON-NLS-1$
+    }
+
+    @Override
+    protected void okPressed() {
+
+        if (fSessionsCombo.getSelectionIndex() < 0) {
+            MessageDialog.openError(getShell(),
+                  Messages.TraceControl_EnableEventsDialogTitle,
+                  Messages.TraceControl_EnableEventsNoSessionError);
+            return;
+        }
+
+        fSessionIndex = fSessionsCombo.getSelectionIndex();
+
+        // if no channel is available or no channel is selected use default channel indicated by fChannel=null
+        fChannel = null;
+        if ((fChannels != null) && (fChannelsCombo.getSelectionIndex() >= 0)) {
+            fChannel = fChannels[fChannelsCombo.getSelectionIndex()];
+        }
+
+        // initialize filter with null
+        fFilterExpression = null;
+        if (fSessions[0].isEventFilteringSupported() && !fIsKernel) {
+            String tempFilter = fFilterText.getText();
+
+            if(!tempFilter.isEmpty() && !tempFilter.matches("\\s*")) { //$NON-NLS-1$
+                fFilterExpression = tempFilter;
+            }
+        }
+
+        super.okPressed();
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IAddContextDialog.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IAddContextDialog.java
new file mode 100644 (file)
index 0000000..97b007f
--- /dev/null
@@ -0,0 +1,47 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
+
+import java.util.List;
+
+/**
+ * <p>
+ * Interface for providing information about contexts to be added to channels/events.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public interface IAddContextDialog {
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    /**
+     * Sets the available contexts to choose from.
+     * @param contexts - a list of available contexts.
+     */
+    void setAvalibleContexts(List<String> contexts);
+
+    /**
+     * @return array of contexts to be added
+     */
+    List<String> getContexts();
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+    /**
+     * @return returns the open return value
+     */
+    int open();
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IConfirmDialog.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IConfirmDialog.java
new file mode 100644 (file)
index 0000000..2ecd326
--- /dev/null
@@ -0,0 +1,38 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
+
+import org.eclipse.swt.widgets.Shell;
+
+/**
+ * <p>
+ * Interface for a confirmation dialog.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public interface IConfirmDialog {
+
+    /**
+     * Open a confirmation dialog
+     *
+     * @param parent
+     *            The parent shell
+     * @param title
+     *            The title of the dialog window
+     * @param message
+     *            The message in the dialog window
+     * @return If the user clicked OK (true) or Cancel (false)
+     */
+    boolean openConfirm(Shell parent, String title, String message);
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/ICreateSessionDialog.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/ICreateSessionDialog.java
new file mode 100644 (file)
index 0000000..833c868
--- /dev/null
@@ -0,0 +1,52 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
+
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISessionInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionGroup;
+
+/**
+ * <p>
+ * Interface for create session dialog.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public interface ICreateSessionDialog {
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    /**
+     * Get the parameters necessary for the creation of a LTTng session
+     *
+     * @return the parameters
+     */
+    ISessionInfo getParameters();
+
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+    /**
+     * Initializes the dialog box.
+     * @param group - the session group
+     */
+    void initialize(TraceSessionGroup group);
+
+    /**
+     * @return the open return value
+     */
+    int open();
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IEnableChannelDialog.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IEnableChannelDialog.java
new file mode 100644 (file)
index 0000000..d23174d
--- /dev/null
@@ -0,0 +1,65 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
+
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IChannelInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent;
+
+/**
+ * <p>
+ * Interface for the enable channel dialog when domain is known.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public interface IEnableChannelDialog {
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+    /**
+     * @return the configuration info for the new channel.
+     */
+    IChannelInfo getChannelInfo();
+
+    /**
+     * Sets the domain component
+     * @param domain - the trace domain component
+     */
+    void setDomainComponent(TraceDomainComponent domain);
+
+    /**
+     * Set the targent node component
+     * @param node - the node component
+     */
+    void setTargetNodeComponent(TargetNodeComponent node);
+
+    /**
+     * @return true for Kernel domain. False for UST.
+     */
+    boolean isKernel();
+
+    /**
+     * Sets the whether dialog is for Kernel or UST
+     * @param isKernel true for kernel domain else UST
+     */
+    void setHasKernel(boolean isKernel);
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+    /**
+     * @return the open return value
+     */
+    int open();
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IEnableEventsDialog.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IEnableEventsDialog.java
new file mode 100644 (file)
index 0000000..f34837e
--- /dev/null
@@ -0,0 +1,53 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
+
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceProviderGroup;
+
+/**
+ * <p>
+ * Interface for providing information about Kernel or UST events to be enabled.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public interface IEnableEventsDialog extends IEnableKernelEvents, IEnableUstEvents {
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+    /**
+     * @return the session the events shall be enabled.
+     */
+    boolean isKernel();
+
+    /**
+     * Sets the trace provider group.
+     * @param providerGroup -  a trace provider group
+     */
+    void setTraceProviderGroup(TraceProviderGroup providerGroup);
+
+    /**
+     * Sets the trace domain component.
+     * @param domain - a domain of the events (null if not known)
+     */
+    void setTraceDomainComponent(TraceDomainComponent domain);
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+    /**
+     * @return returns the open return value
+     */
+    int open();
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IEnableKernelEvents.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IEnableKernelEvents.java
new file mode 100644 (file)
index 0000000..86adb6e
--- /dev/null
@@ -0,0 +1,84 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
+
+import java.util.List;
+
+/**
+ * <p>
+ * Interface for providing information about kernel events to be enabled.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public interface IEnableKernelEvents {
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    /**
+     * @return a flag whether the tracepoints shall be configured.
+     */
+    boolean isTracepoints();
+
+    /**
+     * @return a flag indicating whether all tracepoints shall be enabled or not.
+     */
+    boolean isAllTracePoints();
+
+    /**
+     * @return a flag whether the syscalls shall be configured.
+     */
+    boolean isSysCalls();
+
+    /**
+     * @return a flag indicating whether syscalls shall be enabled or not.
+     */
+    boolean isAllSysCalls();
+
+    /**
+     * @return a list of event names to be enabled.
+     */
+    List<String> getEventNames();
+
+    /**
+     * @return a flag whether the dynamic probe shall be configured.
+     */
+    boolean isDynamicProbe();
+
+    /**
+     * @return event name of the dynamic probe (or null if no dynamic probe).
+     */
+    String getProbeEventName();
+
+    /**
+     * @return the dynamic probe (or null if no dynamic probe).
+     */
+    String getProbeName();
+
+    /**
+     * @return a flag whether the dynamic function entry/return probe shall be configured.
+     */
+    boolean isDynamicFunctionProbe();
+
+    /**
+     * @return event name of the dynamic function entry/exit probe (or null if no dynamic probe).
+     */
+    String getFunctionEventName();
+
+    /**
+     * @return the dynamic function entry/exit probe (or null if no dynamic probe).
+     */
+    String getFunction();
+
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IEnableUstEvents.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IEnableUstEvents.java
new file mode 100644 (file)
index 0000000..2b06bcc
--- /dev/null
@@ -0,0 +1,83 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
+
+import java.util.List;
+
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.LogLevelType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
+
+/**
+ * <p>
+ * Interface for providing information about UST events to be enabled.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public interface IEnableUstEvents {
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    /**
+     * @return a flag whether the tracepoints shall be configured.
+     */
+    boolean isTracepoints();
+
+    /**
+     * @return a flag indicating whether all tracepoints shall be enabled or not.
+     */
+    boolean isAllTracePoints();
+
+    /**
+     * @return a list of event names to be enabled.
+     */
+    List<String> getEventNames();
+
+    /**
+     * @return a flag whether events using wildcards should be enabled
+     */
+    boolean isWildcard();
+
+    /**
+     * @return a wildcard
+     */
+    String getWildcard();
+
+    /**
+     * @return a flag whether events using log levels should be enabled
+     */
+    boolean isLogLevel();
+
+    /**
+     * @return a log level type (loglevel or loglevel-only)
+     */
+    LogLevelType getLogLevelType();
+
+    /**
+     * @return a log level
+     */
+    TraceLogLevel getLogLevel();
+
+    /**
+     * @return a event name for the log level enable action
+     */
+    String getLogLevelEventName();
+
+    /**
+     * @return a filter expression
+     */
+    String getFilterExpression();
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IGetEventInfoDialog.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IGetEventInfoDialog.java
new file mode 100644 (file)
index 0000000..77c3c22
--- /dev/null
@@ -0,0 +1,65 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
+
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
+
+/**
+ * <p>
+ * Interface for a dialog box for collecting information about the events to enable.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public interface IGetEventInfoDialog {
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+    /**
+     * @return the session the events shall be enabled.
+     */
+    TraceSessionComponent getSession();
+
+    /**
+     * @return the channel the events shall be enabled. Null for default channel.
+     */
+    TraceChannelComponent getChannel();
+
+    /**
+     * Sets flag about domain.
+     * @param isKernel - true for kernel, false for UST
+     */
+    void setIsKernel(boolean isKernel);
+
+    /**
+     * Sets available session.
+     * @param sessions - a array of available sessions.
+     */
+    void setSessions(TraceSessionComponent[] sessions);
+
+    /**
+     * Returns the filter expression.
+     * @return the filter expression or null for no filtering
+     */
+    String getFilterExpression();
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+    /**
+     * @return returns the open return value
+     */
+    int open();
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IImportConfirmationDialog.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IImportConfirmationDialog.java
new file mode 100644 (file)
index 0000000..1ed0847
--- /dev/null
@@ -0,0 +1,49 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
+
+/**
+ * <p>
+ * Interface for dialog box for updating file import information.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public interface IImportConfirmationDialog {
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+    /**
+     * @param name old trace name.
+     */
+    void setTraceName(String name);
+
+    /**
+     * @return the new trace name if not overwrite.
+     */
+    String getNewTraceName();
+
+    /**
+     *
+     * @return true to overwrite existing trace.
+     */
+    boolean isOverwrite();
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+    /**
+     * @return the open return value
+     */
+    int open();
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IImportDialog.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IImportDialog.java
new file mode 100644 (file)
index 0000000..8b92a40
--- /dev/null
@@ -0,0 +1,63 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
+
+import java.util.List;
+
+import org.eclipse.core.resources.IProject;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
+
+/**
+ * <p>
+ * Interface for import traces dialog.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public interface IImportDialog {
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+    /**
+     * @return a list of trace paths to import.
+     */
+    List<ImportFileInfo> getTracePathes();
+
+    /**
+     * @return the project to import the traces to
+     */
+    IProject getProject();
+
+    /**
+     * Sets the session containing the traces to import
+     * @param session The trace session
+     */
+    void setSession(TraceSessionComponent session);
+
+    /**
+     * Sets the default project name to use
+     *
+     * @param defaultProject
+     *            the name of the default project to use
+     */
+    void setDefaultProject(String defaultProject);
+
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+    /**
+     * @return the open return value
+     */
+    int open();
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/INewConnectionDialog.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/INewConnectionDialog.java
new file mode 100644 (file)
index 0000000..5c3678d
--- /dev/null
@@ -0,0 +1,43 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Markus Schorn - Bug 448058: Use org.eclipse.remote in favor of RSE
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
+
+import org.eclipse.remote.core.IRemoteConnection;
+
+/**
+ * <p>
+ * Interface for connection information dialog.
+ * </p>
+ *
+ *  @author Bernd Hufmann
+ */
+public interface INewConnectionDialog {
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    /**
+     * Returns the selected connection.
+     * @return the selected connection, or <code>null</code>.
+     */
+    IRemoteConnection getConnection();
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+    /**
+     * @return returns the open return value
+     */
+    int open();
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/ISelectCommandScriptDialog.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/ISelectCommandScriptDialog.java
new file mode 100644 (file)
index 0000000..808845e
--- /dev/null
@@ -0,0 +1,32 @@
+/**********************************************************************
+ * Copyright (c) 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
+
+import java.util.List;
+
+/**
+ * Interface for dialog for selecting a command script.
+ *
+ * @author Bernd Hufmann
+ *
+ */
+public interface ISelectCommandScriptDialog {
+    /**
+     * @return a list of command
+     */
+    List<String> getCommands();
+
+    /**
+     * @return the open return value
+     */
+    int open();
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/ImportConfirmationDialog.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/ImportConfirmationDialog.java
new file mode 100644 (file)
index 0000000..d3125ce
--- /dev/null
@@ -0,0 +1,200 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
+
+import org.eclipse.jface.dialogs.Dialog;
+import org.eclipse.jface.dialogs.IDialogConstants;
+import org.eclipse.jface.dialogs.MessageDialog;
+import org.eclipse.swt.SWT;
+import org.eclipse.swt.events.SelectionAdapter;
+import org.eclipse.swt.events.SelectionEvent;
+import org.eclipse.swt.graphics.Point;
+import org.eclipse.swt.layout.GridData;
+import org.eclipse.swt.layout.GridLayout;
+import org.eclipse.swt.widgets.Button;
+import org.eclipse.swt.widgets.Composite;
+import org.eclipse.swt.widgets.Control;
+import org.eclipse.swt.widgets.Label;
+import org.eclipse.swt.widgets.Shell;
+import org.eclipse.swt.widgets.Text;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
+
+/**
+ * <p>
+ * Dialog box for collecting session creation information.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class ImportConfirmationDialog extends Dialog implements IImportConfirmationDialog {
+
+    // ------------------------------------------------------------------------
+    // Constants
+    // ------------------------------------------------------------------------
+    /**
+     * The icon file for this dialog box.
+     */
+    public static final String IMPORT_ICON_FILE = "icons/elcl16/import_trace.gif"; //$NON-NLS-1$
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+    /**
+     * The radio button for selecting the overwrite action
+     */
+    private Button fOverwriteButton = null;
+    /**
+     * The radio button for selecting the renaming action
+     */
+    private Button fRenameButton = null;
+    /**
+     * The text widget for the session name
+     */
+    private Text fNewTraceNameText = null;
+    /**
+     * The trace name which already exists in the project
+     */
+    private String fTraceName = null;
+    /**
+     * The session name string.
+     */
+    private String fNewTraceName = null;
+    /**
+     * Flag whether default location (path) shall be used or not
+     */
+    private boolean fIsOverride = true;
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+    /**
+     * Constructor
+     * @param shell - a shell for the display of the dialog
+     */
+    public ImportConfirmationDialog(Shell shell) {
+        super(shell);
+        setShellStyle(SWT.RESIZE | getShellStyle());
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    @Override
+    public void setTraceName(String name) {
+        fTraceName = name;
+    }
+
+    @Override
+    public String getNewTraceName() {
+        return fNewTraceName;
+    }
+
+    @Override
+    public boolean isOverwrite() {
+        return fIsOverride;
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    protected void configureShell(Shell newShell) {
+        super.configureShell(newShell);
+        newShell.setText(Messages.TraceControl_ImportDialogConfirmationTitle);
+        newShell.setImage(Activator.getDefault().loadIcon(IMPORT_ICON_FILE));
+    }
+
+    @Override
+    protected Control createDialogArea(Composite parent) {
+
+        // Main dialog panel
+       Composite dialogComposite = new Composite(parent, SWT.NONE);
+        GridLayout layout = new GridLayout(1, true);
+        dialogComposite.setLayout(layout);
+        dialogComposite.setLayoutData(new GridData(GridData.FILL_BOTH));
+
+        Label sessionNameLabel = new Label(dialogComposite, SWT.RIGHT);
+        sessionNameLabel.setText(Messages.TraceControl_ImportDialogTraceAlreadyExistError + ": " + fTraceName); //$NON-NLS-1$
+
+        fOverwriteButton = new Button(dialogComposite, SWT.RADIO);
+        fOverwriteButton.setText(Messages.TraceControl_ImportDialogConfirmationOverwriteLabel);
+
+        fOverwriteButton.addSelectionListener(new SelectionAdapter() {
+            @Override
+            public void widgetSelected(SelectionEvent e) {
+                fNewTraceNameText.setEnabled(false);
+                fNewTraceNameText.setText(fTraceName);
+            }
+        });
+
+        fRenameButton = new Button(dialogComposite, SWT.RADIO);
+        fRenameButton.setText(Messages.TraceControl_ImportDialogConfirmationRenameLabel);
+
+        fRenameButton.addSelectionListener(new SelectionAdapter() {
+            @Override
+            public void widgetSelected(SelectionEvent e) {
+                fNewTraceNameText.setEnabled(true);
+            }
+        });
+
+        fNewTraceNameText = new Text(dialogComposite, SWT.NONE);
+        fNewTraceNameText.setToolTipText(Messages.TraceControl_ImportDialogConfirmationNewNameLabel);
+        fNewTraceNameText.setText(fTraceName);
+
+        // Default
+        fOverwriteButton.setSelection(true);
+        fNewTraceNameText.setEnabled(false);
+
+
+        // layout widgets
+        GridData data = new GridData(GridData.FILL_HORIZONTAL);
+
+        fNewTraceNameText.setLayoutData(data);
+
+        getShell().setMinimumSize(new Point(300, 150));
+
+        return dialogComposite;
+    }
+
+    @Override
+    protected void createButtonsForButtonBar(Composite parent) {
+        createButton(parent, IDialogConstants.CANCEL_ID, "&Cancel", true); //$NON-NLS-1$
+        createButton(parent, IDialogConstants.OK_ID, "&Ok", true); //$NON-NLS-1$
+    }
+
+    @Override
+    protected void okPressed() {
+
+        fIsOverride = fOverwriteButton.getSelection();
+
+        if (fIsOverride) {
+            // new name is old name
+            fNewTraceName = fTraceName;
+        } else {
+            fNewTraceName = fNewTraceNameText.getText();
+        }
+
+        // Check for invalid names
+        if (!fNewTraceName.matches("^[a-zA-Z0-9\\-\\_]{1,}$")) { //$NON-NLS-1$
+            MessageDialog.openError(getShell(),
+                    Messages.TraceControl_ImportDialogConfirmationTitle,
+                    Messages.TraceControl_InvalidTraceNameError + " (" + fNewTraceName + ") \n");  //$NON-NLS-1$ //$NON-NLS-2$
+            return;
+        }
+
+        // validation successful -> call super.okPressed()
+        super.okPressed();
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/ImportDialog.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/ImportDialog.java
new file mode 100644 (file)
index 0000000..9562d06
--- /dev/null
@@ -0,0 +1,509 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2015 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Bernd Hufmann - Added handling of streamed traces
+ *   Marc-Andre Laperle - Use common method to get opened tmf projects
+ *   Markus Schorn - Bug 448058: Use org.eclipse.remote in favor of RSE
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import org.eclipse.core.filesystem.EFS;
+import org.eclipse.core.filesystem.IFileInfo;
+import org.eclipse.core.filesystem.IFileStore;
+import org.eclipse.core.resources.IFolder;
+import org.eclipse.core.resources.IProject;
+import org.eclipse.core.runtime.CoreException;
+import org.eclipse.core.runtime.IPath;
+import org.eclipse.core.runtime.NullProgressMonitor;
+import org.eclipse.core.runtime.Path;
+import org.eclipse.jface.dialogs.Dialog;
+import org.eclipse.jface.dialogs.IDialogConstants;
+import org.eclipse.jface.dialogs.MessageDialog;
+import org.eclipse.jface.viewers.CheckStateChangedEvent;
+import org.eclipse.jface.viewers.CheckboxTreeViewer;
+import org.eclipse.jface.viewers.ICheckStateListener;
+import org.eclipse.jface.viewers.ITreeContentProvider;
+import org.eclipse.jface.viewers.LabelProvider;
+import org.eclipse.jface.viewers.Viewer;
+import org.eclipse.jface.window.Window;
+import org.eclipse.remote.core.IRemoteFileService;
+import org.eclipse.swt.SWT;
+import org.eclipse.swt.custom.CCombo;
+import org.eclipse.swt.events.SelectionAdapter;
+import org.eclipse.swt.events.SelectionEvent;
+import org.eclipse.swt.graphics.Image;
+import org.eclipse.swt.graphics.Point;
+import org.eclipse.swt.layout.GridData;
+import org.eclipse.swt.layout.GridLayout;
+import org.eclipse.swt.widgets.Button;
+import org.eclipse.swt.widgets.Composite;
+import org.eclipse.swt.widgets.Control;
+import org.eclipse.swt.widgets.Group;
+import org.eclipse.swt.widgets.Shell;
+import org.eclipse.swt.widgets.Text;
+import org.eclipse.swt.widgets.Tree;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
+import org.eclipse.tracecompass.tmf.remote.core.proxy.RemoteSystemProxy;
+import org.eclipse.tracecompass.tmf.ui.project.model.TmfTracesFolder;
+import org.eclipse.tracecompass.tmf.ui.project.model.TraceUtils;
+import org.eclipse.ui.ISharedImages;
+import org.eclipse.ui.PlatformUI;
+
+/**
+ * <p>
+ * Dialog box for collecting trace import information.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class ImportDialog extends Dialog implements IImportDialog {
+
+    // ------------------------------------------------------------------------
+    // Constants
+    // ------------------------------------------------------------------------
+    /** The icon file for this dialog box. */
+    public static final String IMPORT_ICON_FILE = "icons/elcl16/import_trace.gif"; //$NON-NLS-1$
+
+    /** Parent directory for UST traces */
+    public static final String UST_PARENT_DIRECTORY = "ust"; //$NON-NLS-1$
+
+    /** Name of metadata file of trace */
+    public static final String METADATA_FILE_NAME = "metadata"; //$NON-NLS-1$
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+    /**
+     * The dialog composite.
+     */
+    private Composite fDialogComposite = null;
+    /**
+     * The checkbox tree viewer for selecting available traces
+     */
+    private CheckboxTreeViewer fFolderViewer;
+    /**
+     * The combo box for selecting a project.
+     */
+    private CCombo fCombo;
+    /**
+     * The overwrite button
+     */
+    private Button fOverwriteButton;
+    /**
+     * List of available LTTng 2.0 projects
+     */
+    private List<IProject> fProjects;
+    /**
+     * The parent where the new node should be added.
+     */
+    private TraceSessionComponent fSession = null;
+    /**
+     * The name of the default project name
+     */
+    private String fDefaultProjectName = null;
+    /**
+     * List of traces to import
+     */
+    private final List<ImportFileInfo> fTraces = new ArrayList<>();
+    /**
+     * Selection index in project combo box.
+     */
+    private int fProjectIndex;
+    /**
+     * Flag to indicate that something went wrong when creating the dialog box.
+     */
+    private boolean fIsError = false;
+    /**
+     * Children of the remote folder (can be null)
+     */
+    private Object[] fFolderChildren = null;
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+    /**
+     * Constructor
+     *
+     * @param shell
+     *            - a shell for the display of the dialog
+     */
+    public ImportDialog(Shell shell) {
+        super(shell);
+        setShellStyle(SWT.RESIZE | getShellStyle());
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    @Override
+    public List<ImportFileInfo> getTracePathes() {
+        List<ImportFileInfo> retList = new ArrayList<>();
+        retList.addAll(fTraces);
+        return retList;
+    }
+
+    @Override
+    public IProject getProject() {
+        return fProjects.get(fProjectIndex);
+    }
+
+    @Override
+    public void setSession(TraceSessionComponent session) {
+        fSession = session;
+    }
+
+    @Override
+    public void setDefaultProject(String defaultProject) {
+        fDefaultProjectName = defaultProject;
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    protected void configureShell(Shell newShell) {
+        super.configureShell(newShell);
+        newShell.setText(Messages.TraceControl_ImportDialogTitle);
+        newShell.setImage(Activator.getDefault().loadIcon(IMPORT_ICON_FILE));
+    }
+
+    @Override
+    protected Control createDialogArea(Composite parent) {
+
+        // Main dialog panel
+        fDialogComposite = new Composite(parent, SWT.NONE);
+        GridLayout layout = new GridLayout(1, true);
+        fDialogComposite.setLayout(layout);
+        fDialogComposite.setLayoutData(new GridData(GridData.FILL_BOTH));
+
+        try {
+            createRemoteComposite();
+        } catch (CoreException e) {
+            createErrorComposite(parent, e.fillInStackTrace());
+            return fDialogComposite;
+        }
+        return fDialogComposite;
+    }
+
+    @Override
+    protected void createButtonsForButtonBar(Composite parent) {
+        Button selectAllButton = createButton(parent, IDialogConstants.SELECT_ALL_ID, Messages.TraceControl_ImportDialog_SelectAll, true);
+        selectAllButton.addSelectionListener(new SelectionAdapter() {
+            @Override
+            public void widgetSelected(SelectionEvent e) {
+                setFolderChildrenChecked(true);
+            }
+        });
+
+        Button deselectAllButton = createButton(parent, IDialogConstants.DESELECT_ALL_ID, Messages.TraceControl_ImportDialog_DeselectAll, true);
+        deselectAllButton.addSelectionListener(new SelectionAdapter() {
+            @Override
+            public void widgetSelected(SelectionEvent e) {
+                setFolderChildrenChecked(false);
+            }
+        });
+        createButton(parent, IDialogConstants.CANCEL_ID, IDialogConstants.CANCEL_LABEL, true);
+        createButton(parent, IDialogConstants.OK_ID, IDialogConstants.OK_LABEL, true);
+        updateOKButtonEnablement();
+    }
+
+    @Override
+    protected void okPressed() {
+        if (!fIsError) {
+
+            // Validate input data
+            fTraces.clear();
+
+            fProjectIndex = fCombo.getSelectionIndex();
+
+            if (fProjectIndex < 0) {
+                MessageDialog.openError(getShell(),
+                        Messages.TraceControl_ImportDialogTitle,
+                        Messages.TraceControl_ImportDialogNoProjectSelectedError);
+                return;
+            }
+
+            IProject project = fProjects.get(fProjectIndex);
+            IFolder traceFolder = project.getFolder(TmfTracesFolder.TRACES_FOLDER_NAME);
+
+            if (!traceFolder.exists()) {
+                // Invalid LTTng 2.0 project
+                MessageDialog.openError(getShell(),
+                        Messages.TraceControl_ImportDialogTitle,
+                        Messages.TraceControl_ImportDialogInvalidTracingProject + " (" + TmfTracesFolder.TRACES_FOLDER_NAME + ")"); //$NON-NLS-1$//$NON-NLS-2$
+                return;
+            }
+
+            boolean overwriteAll = fOverwriteButton.getSelection();
+
+            Object[] checked = fFolderViewer.getCheckedElements();
+            for (int i = 0; i < checked.length; i++) {
+                IFileStore file = (IFileStore) checked[i];
+                if (!file.fetchInfo().isDirectory() && file.getName().equals(METADATA_FILE_NAME)) {
+                    IFileStore trace = file.getParent();
+                    IFileStore parent = trace.getParent();
+
+                    String path = fSession.isSnapshotSession() ? fSession.getSnapshotInfo().getSnapshotPath() : fSession.getSessionPath();
+                    path = getUnifiedPath(path);
+                    IPath sessionParentPath = new Path(path).removeLastSegments(1);
+                    IPath traceParentPath = new Path(parent.toURI().getPath());
+
+                    IPath relativeTracePath = traceParentPath.makeRelativeTo(sessionParentPath);
+
+                    IFolder destinationFolder = traceFolder.getFolder(new Path(relativeTracePath.toOSString()));
+
+                    ImportFileInfo info = new ImportFileInfo(trace, trace.getName(), destinationFolder, overwriteAll);
+                    IFolder folder = destinationFolder.getFolder(trace.getName());
+
+                    // Verify if trace directory already exists (and not
+                    // overwrite)
+                    if (folder.exists() && !overwriteAll) {
+
+                        // Ask user for overwrite or new name
+                        IImportConfirmationDialog conf = TraceControlDialogFactory.getInstance().getImportConfirmationDialog();
+                        conf.setTraceName(trace.getName());
+
+                        // Don't add trace to list if dialog was cancelled.
+                        if (conf.open() == Window.OK) {
+                            info.setOverwrite(conf.isOverwrite());
+                            if (!conf.isOverwrite()) {
+                                info.setLocalTraceName(conf.getNewTraceName());
+                            }
+                            fTraces.add(info);
+                        }
+                    } else {
+                        fTraces.add(info);
+                    }
+                }
+            }
+
+            if (fTraces.isEmpty()) {
+                MessageDialog.openError(getShell(),
+                        Messages.TraceControl_ImportDialogTitle,
+                        Messages.TraceControl_ImportDialogNoTraceSelectedError);
+                return;
+            }
+        }
+
+        // validation successful -> call super.okPressed()
+        super.okPressed();
+    }
+
+    // ------------------------------------------------------------------------
+    // Helper methods and classes
+    // ------------------------------------------------------------------------
+
+    private final class FolderCheckStateListener implements ICheckStateListener {
+        @Override
+        public void checkStateChanged(CheckStateChangedEvent event) {
+            Object elem = event.getElement();
+            if (elem instanceof IFileStore) {
+                IFileStore element = (IFileStore) elem;
+                IFileInfo info = element.fetchInfo();
+                if (!info.isDirectory()) {
+                    // A trick to keep selection of a file in sync with the
+                    // directory
+                    boolean p = fFolderViewer.getChecked((element.getParent()));
+                    fFolderViewer.setChecked(element, p);
+                } else {
+                    fFolderViewer.setSubtreeChecked(event.getElement(), event.getChecked());
+                    if (!event.getChecked()) {
+                        fFolderViewer.setChecked(element.getParent(), false);
+                    }
+                }
+                updateOKButtonEnablement();
+            }
+        }
+    }
+
+    /**
+     * Helper class for the contents of a folder in a tracing project
+     *
+     * @author Bernd Hufmann
+     */
+    public static class FolderContentProvider implements ITreeContentProvider {
+        @Override
+        public Object[] getChildren(Object o) {
+            try {
+                IFileStore store = (IFileStore) o;
+                if (store.fetchInfo().isDirectory()) {
+                    return store.childStores(EFS.NONE, new NullProgressMonitor());
+                }
+            } catch (CoreException e) {
+                Activator.getDefault().logError(e.getMessage(), e);
+            }
+            return new Object[0];
+        }
+
+        @Override
+        public Object getParent(Object element) {
+            return ((IFileStore) element).getParent();
+        }
+
+        @Override
+        public void dispose() {
+        }
+
+        @Override
+        public void inputChanged(Viewer viewer, Object oldInput, Object newInput) {
+        }
+
+        @Override
+        public Object[] getElements(Object inputElement) {
+            return getChildren(inputElement);
+        }
+
+        @Override
+        public boolean hasChildren(Object element) {
+            return ((IFileStore) element).fetchInfo().isDirectory();
+        }
+    }
+
+    /**
+     * Creates a dialog composite with an error message which can be used when
+     * an exception occurred during creation time of the dialog box.
+     *
+     * @param parent
+     *            - a parent composite
+     * @param e
+     *            - a error causing exception
+     */
+    private void createErrorComposite(Composite parent, Throwable e) {
+        fIsError = true;
+        fDialogComposite.dispose();
+
+        fDialogComposite = new Composite(parent, SWT.NONE);
+        GridLayout layout = new GridLayout(1, true);
+        fDialogComposite.setLayout(layout);
+        fDialogComposite.setLayoutData(new GridData(GridData.FILL_BOTH));
+
+        Text errorText = new Text(fDialogComposite, SWT.MULTI);
+        StringBuffer error = new StringBuffer();
+        error.append(Messages.TraceControl_ImportDialogCreationError);
+        error.append(System.getProperty("line.separator")); //$NON-NLS-1$
+        error.append(System.getProperty("line.separator")); //$NON-NLS-1$
+        error.append(e.toString());
+        errorText.setText(error.toString());
+        errorText.setLayoutData(new GridData(GridData.FILL_BOTH));
+    }
+
+    private void createRemoteComposite() throws CoreException {
+        Group contextGroup = new Group(fDialogComposite, SWT.SHADOW_NONE);
+        contextGroup.setText(Messages.TraceControl_ImportDialogTracesGroupName);
+        GridLayout layout = new GridLayout(1, true);
+        contextGroup.setLayout(layout);
+        contextGroup.setLayoutData(new GridData(GridData.FILL_BOTH));
+
+        RemoteSystemProxy proxy = fSession.getTargetNode().getRemoteSystemProxy();
+
+        IRemoteFileService fsss = proxy.getRemoteConnection().getService(IRemoteFileService.class);
+
+        if (fsss == null) {
+            return;
+        }
+
+        final String path = fSession.isSnapshotSession() ? fSession.getSnapshotInfo().getSnapshotPath() : fSession.getSessionPath();
+        final IFileStore remoteFolder = fsss.getResource(path);
+
+        fFolderViewer = new CheckboxTreeViewer(contextGroup, SWT.BORDER | SWT.V_SCROLL | SWT.H_SCROLL);
+        GridData data = new GridData(GridData.FILL_BOTH);
+        Tree tree = fFolderViewer.getTree();
+        tree.setLayoutData(data);
+        tree.setFont(fDialogComposite.getFont());
+        tree.setToolTipText(Messages.TraceControl_ImportDialogTracesTooltip);
+
+        fFolderViewer.setContentProvider(new FolderContentProvider());
+        fFolderViewer.setLabelProvider(new LabelProvider() {
+            @Override
+            public String getText(Object element) {
+                return ((IFileStore) element).getName();
+            }
+
+            @Override
+            public Image getImage(Object element) {
+                if (((IFileStore) element).fetchInfo().isDirectory()) {
+                    return PlatformUI.getWorkbench().getSharedImages().getImage(ISharedImages.IMG_OBJ_FOLDER);
+                }
+                return PlatformUI.getWorkbench().getSharedImages().getImage(ISharedImages.IMG_OBJ_FILE);
+            }
+        });
+
+        fFolderViewer.addCheckStateListener(new FolderCheckStateListener());
+        fFolderViewer.setInput(remoteFolder);
+
+        fFolderChildren = remoteFolder.childStores(EFS.NONE, new NullProgressMonitor());
+        // children can be null if there the path doesn't exist. This happens
+        // when a trace
+        // session hadn't been started and no output was created.
+        setFolderChildrenChecked(true);
+
+        Group projectGroup = new Group(fDialogComposite, SWT.SHADOW_NONE);
+        projectGroup.setText(Messages.TraceControl_ImportDialogProjectsGroupName);
+        layout = new GridLayout(1, true);
+        projectGroup.setLayout(layout);
+        projectGroup.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
+
+        fProjects = new ArrayList<>();
+        List<String> projectNames = new ArrayList<>();
+
+        for (IProject project : TraceUtils.getOpenedTmfProjects()) {
+            fProjects.add(project);
+            projectNames.add(project.getName());
+        }
+
+        fCombo = new CCombo(projectGroup, SWT.READ_ONLY);
+        fCombo.setToolTipText(Messages.TraceControl_ImportDialogProjectsTooltip);
+        fCombo.setLayoutData(new GridData(GridData.FILL, GridData.CENTER, true, false, 1, 1));
+        fCombo.setItems(projectNames.toArray(new String[projectNames.size()]));
+
+        if (fDefaultProjectName != null) {
+            int select = projectNames.indexOf(fDefaultProjectName);
+            fCombo.select(select);
+        }
+
+        Group overrideGroup = new Group(fDialogComposite, SWT.SHADOW_NONE);
+        layout = new GridLayout(1, true);
+        overrideGroup.setLayout(layout);
+        overrideGroup.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
+
+        fOverwriteButton = new Button(overrideGroup, SWT.CHECK);
+        fOverwriteButton.setText(Messages.TraceControl_ImportDialogOverwriteButtonText);
+        getShell().setMinimumSize(new Point(500, 400));
+    }
+
+    private void setFolderChildrenChecked(boolean isChecked) {
+        if (fFolderChildren != null) {
+            for (Object child : fFolderChildren) {
+                fFolderViewer.setSubtreeChecked(child, isChecked);
+            }
+        }
+        updateOKButtonEnablement();
+    }
+
+    private void updateOKButtonEnablement() {
+        Object[] checked = fFolderViewer.getCheckedElements();
+        Button okButton = getButton(IDialogConstants.OK_ID);
+        if (okButton != null) {
+            okButton.setEnabled(checked.length > 0);
+        }
+    }
+
+    private static String getUnifiedPath(String path) {
+        // Use Path class to remove unnecessary slashes
+        return new Path(path).removeTrailingSeparator().toString();
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/ImportFileInfo.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/ImportFileInfo.java
new file mode 100644 (file)
index 0000000..5e586d1
--- /dev/null
@@ -0,0 +1,128 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Markus Schorn - Bug 448058: Use org.eclipse.remote in favor of RSE
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
+
+import org.eclipse.core.filesystem.IFileStore;
+import org.eclipse.core.resources.IFolder;
+
+/**
+ * <p>
+ * Helper class for storing information about a remote file to import.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class ImportFileInfo {
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+    /**
+     * Remote file reference
+     */
+    private IFileStore fRemoteFile;
+    /**
+     * Local Trace Name
+     */
+    private String fLocalTraceName;
+    /**
+     * Global overwrite flag
+     */
+    private boolean fIsOverwrite;
+    /**
+     * Destination folder to import the trace to (full workspace path)
+     */
+    private IFolder fDestinationFolder;
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+    /**
+     * Standard constructor
+     *
+     * @param file
+     *            A remote file reference
+     * @param traceName
+     *            A trace name
+     * @param destinationFolder
+     *            The destination folder (full workspace path)
+     * @param isOverwrite
+     *            global overwrite flag
+     */
+    public ImportFileInfo(IFileStore file, String traceName, IFolder destinationFolder, boolean isOverwrite) {
+        fRemoteFile = file;
+        fLocalTraceName = traceName;
+        fDestinationFolder = destinationFolder;
+        fIsOverwrite = isOverwrite;
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+    /**
+     * @return name of traces after importing
+     */
+    public String getLocalTraceName() {
+        return fLocalTraceName;
+    }
+
+    /**
+     * Sets the local trace name
+     *
+     * @param importTraceName
+     *            - local name of trace to set (name after importing)
+     */
+    public void setLocalTraceName(String importTraceName) {
+        this.fLocalTraceName = importTraceName;
+    }
+    /**
+     * @return true if local trace should be overwritten if a trace with the same name already exists.
+     */
+    public boolean isOverwrite() {
+        return fIsOverwrite;
+    }
+    /**
+     * Sets the overwrite flag.
+     * @param isOverwrite If the Overwrite checkbox is checked or not
+     */
+    public void setOverwrite(boolean isOverwrite) {
+        this.fIsOverwrite = isOverwrite;
+    }
+
+    /**
+     * @return the remote file implementation.
+     */
+    public IFileStore getImportFile() {
+        return fRemoteFile;
+    }
+
+    /**
+     * Sets the remote file implementation
+     *
+     * @param remoteFile
+     *            The remote file implementation.
+     */
+    public void setRemoteFile(IFileStore remoteFile) {
+        fRemoteFile = remoteFile;
+    }
+
+    /**
+     * Returns the destination folder to import the trace to (full workspace path).
+     *
+     * @return destination folder
+     */
+    public IFolder getDestinationFolder() {
+        return fDestinationFolder;
+    }
+}
+
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/NewConnectionDialog.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/NewConnectionDialog.java
new file mode 100644 (file)
index 0000000..1f30749
--- /dev/null
@@ -0,0 +1,399 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2015 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Markus Schorn - Bug 448058: Use org.eclipse.remote in favor of RSE
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
+
+import static java.text.MessageFormat.format;
+
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.Comparator;
+import java.util.List;
+
+import org.eclipse.jface.dialogs.Dialog;
+import org.eclipse.jface.dialogs.IDialogConstants;
+import org.eclipse.jface.viewers.DoubleClickEvent;
+import org.eclipse.jface.viewers.IDoubleClickListener;
+import org.eclipse.jface.viewers.ISelectionChangedListener;
+import org.eclipse.jface.viewers.IStructuredSelection;
+import org.eclipse.jface.viewers.ITreeContentProvider;
+import org.eclipse.jface.viewers.LabelProvider;
+import org.eclipse.jface.viewers.SelectionChangedEvent;
+import org.eclipse.jface.viewers.StructuredSelection;
+import org.eclipse.jface.viewers.TreeViewer;
+import org.eclipse.jface.viewers.Viewer;
+import org.eclipse.remote.core.IRemoteConnection;
+import org.eclipse.remote.core.IRemoteConnectionHostService;
+import org.eclipse.remote.core.IRemoteConnectionType;
+import org.eclipse.remote.core.IRemoteConnectionWorkingCopy;
+import org.eclipse.remote.core.IRemoteServicesManager;
+import org.eclipse.remote.core.exception.RemoteConnectionException;
+import org.eclipse.remote.ui.IRemoteUIConnectionService;
+import org.eclipse.remote.ui.IRemoteUIConnectionWizard;
+import org.eclipse.swt.SWT;
+import org.eclipse.swt.events.SelectionAdapter;
+import org.eclipse.swt.events.SelectionEvent;
+import org.eclipse.swt.graphics.Image;
+import org.eclipse.swt.layout.GridData;
+import org.eclipse.swt.layout.GridLayout;
+import org.eclipse.swt.widgets.Button;
+import org.eclipse.swt.widgets.Composite;
+import org.eclipse.swt.widgets.Control;
+import org.eclipse.swt.widgets.Label;
+import org.eclipse.swt.widgets.Shell;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
+import org.eclipse.tracecompass.tmf.remote.core.proxy.TmfRemoteConnectionFactory;
+
+/**
+ * <p>
+ * Dialog box for connection information.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class NewConnectionDialog extends Dialog implements INewConnectionDialog {
+
+    private static final int BUTTONS_NUMBER_OF_COLUMNS = 3;
+    private static final int LABEL_WIDTH_CHARS = 4;
+    private static final int CONNECTIONTREE_HEIGHT_CHARS = 10;
+    private static final int CONNECTIONTREE_WIDTH_CHARS = 40;
+    // ------------------------------------------------------------------------
+    // Constants
+    // ------------------------------------------------------------------------
+    private static final String TARGET_NEW_CONNECTION_ICON_FILE = "icons/elcl16/target_add.gif"; //$NON-NLS-1$
+    private static final String PROVIDERS_ICON_FILE = "icons/obj16/providers.gif"; //$NON-NLS-1$
+    private static final String CONNECTION_ICON_FILE = "icons/obj16/target_connected.gif"; //$NON-NLS-1$
+
+    private final class ConnectionTreeLabelProvider extends LabelProvider {
+        @Override
+        public String getText(Object element) {
+            if (element instanceof IRemoteConnection) {
+                IRemoteConnection rc = (IRemoteConnection) element;
+                return getConnectionLabel(rc);
+            } else if (element instanceof IRemoteConnectionType) {
+                IRemoteConnectionType rs = (IRemoteConnectionType) element;
+                return rs.getName();
+            }
+            return Messages.TraceControl_UnknownNode;
+        }
+
+        @Override
+        public Image getImage(Object element) {
+            if (element instanceof IRemoteConnection) {
+                return Activator.getDefault().loadIcon(CONNECTION_ICON_FILE);
+            }
+            return Activator.getDefault().loadIcon(PROVIDERS_ICON_FILE);
+        }
+    }
+
+    private static final class ConnectionContentProvider implements ITreeContentProvider {
+        private static final Object[] NO_CHILDREN = {};
+
+        @Override
+        public void inputChanged(Viewer viewer, Object oldInput, Object newInput) {
+        }
+
+        @Override
+        public void dispose() {
+        }
+
+        @Override
+        public Object[] getElements(Object inputElement) {
+            List<Object> children = new ArrayList<>();
+            IRemoteServicesManager manager = TmfRemoteConnectionFactory.getService(IRemoteServicesManager.class);
+            if (manager != null) {
+                children.addAll(manager.getAllConnectionTypes());
+            }
+            return children.toArray();
+        }
+
+        @Override
+        public Object[] getChildren(Object parentElement) {
+            if (parentElement instanceof IRemoteConnectionType) {
+                return getConnections((IRemoteConnectionType) parentElement);
+            }
+            return NO_CHILDREN;
+        }
+
+        private static IRemoteConnection[] getConnections(IRemoteConnectionType parentElement) {
+            List<IRemoteConnection> connectionList = parentElement.getConnections();
+            IRemoteConnection[] result = connectionList.toArray(new IRemoteConnection[connectionList.size()]);
+            Arrays.sort(result, new Comparator<IRemoteConnection>() {
+                @Override
+                public int compare(IRemoteConnection o1, IRemoteConnection o2) {
+                    return getConnectionLabel(o1).compareTo(getConnectionLabel(o2));
+                }
+            });
+            return result;
+        }
+
+        @Override
+        public Object getParent(Object element) {
+            if (element instanceof IRemoteConnection) {
+                return ((IRemoteConnection) element).getConnectionType();
+            }
+            return null;
+        }
+
+        @Override
+        public boolean hasChildren(Object element) {
+            return getChildren(element).length > 0;
+        }
+
+    }
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+    /**
+     * The host combo box.
+     */
+    private TreeViewer fConnectionTree = null;
+    /**
+     * The push button for creating a new connection.
+     */
+    private Button fNewButton = null;
+    /**
+     * The push button for editing a connection.
+     */
+    private Button fEditButton = null;
+
+    private IRemoteConnection fConnection;
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+    /**
+     * Constructor
+     *
+     * @param shell
+     *            The shell
+     */
+    public NewConnectionDialog(Shell shell) {
+        super(shell);
+        setShellStyle(SWT.RESIZE | getShellStyle());
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    protected void configureShell(Shell newShell) {
+        super.configureShell(newShell);
+        newShell.setText(Messages.TraceControl_NewDialogTitle);
+        newShell.setImage(Activator.getDefault().loadIcon(TARGET_NEW_CONNECTION_ICON_FILE));
+    }
+
+    @Override
+    protected Control createContents(Composite parent) {
+        Control result = super.createContents(parent);
+        fConnectionTree.setAutoExpandLevel(2);
+        fConnectionTree.setInput(this);
+
+        IRemoteServicesManager manager = TmfRemoteConnectionFactory.getService(IRemoteServicesManager.class);
+        if (manager == null) {
+            return result;
+        }
+        List<IRemoteConnectionType> providers = manager.getAllConnectionTypes();
+        if (!providers.isEmpty()) {
+            IRemoteConnectionType provider = providers.get(0);
+            IRemoteConnection[] connections = ConnectionContentProvider.getConnections(provider);
+            if (connections.length > 0) {
+                fConnectionTree.setSelection(new StructuredSelection(connections[0]));
+            } else {
+                fConnectionTree.setSelection(new StructuredSelection(provider));
+            }
+        } else {
+            onSelectionChanged();
+        }
+        return result;
+    }
+
+    @Override
+    protected Control createDialogArea(Composite parent) {
+        // Main dialog panel
+        GridData gd;
+        Composite dialogComposite = new Composite(parent, SWT.NONE);
+        GridLayout layout = new GridLayout(1, true);
+        dialogComposite.setLayout(layout);
+        dialogComposite.setLayoutData(new GridData(GridData.FILL_BOTH));
+
+        Label label = new Label(dialogComposite, SWT.NONE);
+        label.setText(Messages.TraceControl_NewNodeExistingConnectionGroupName);
+        gd = new GridData();
+        label.setLayoutData(gd );
+        gd.widthHint = label.computeSize(-1, -1).x + convertWidthInCharsToPixels(LABEL_WIDTH_CHARS);
+        // Existing connections group
+        fConnectionTree = new TreeViewer(dialogComposite);
+        gd = new GridData(SWT.FILL, SWT.FILL, true, true);
+        fConnectionTree.getTree().setLayoutData(gd);
+        gd.widthHint = convertWidthInCharsToPixels(CONNECTIONTREE_WIDTH_CHARS);
+        gd.heightHint = convertHeightInCharsToPixels(CONNECTIONTREE_HEIGHT_CHARS);
+        fConnectionTree.setLabelProvider(new ConnectionTreeLabelProvider());
+        fConnectionTree.setContentProvider(new ConnectionContentProvider());
+        fConnectionTree.addSelectionChangedListener(new ISelectionChangedListener() {
+            @Override
+            public void selectionChanged(SelectionChangedEvent event) {
+                onSelectionChanged();
+            }
+        });
+        fConnectionTree.addDoubleClickListener(new IDoubleClickListener() {
+            @Override
+            public void doubleClick(DoubleClickEvent event) {
+                okPressed();
+            }
+        });
+
+        Composite buttons = new Composite(dialogComposite, SWT.NONE);
+        layout = new GridLayout(BUTTONS_NUMBER_OF_COLUMNS, true);
+        layout.marginHeight = 0;
+        layout.marginWidth = 0;
+        buttons.setLayout(layout);
+        buttons.setLayoutData(new GridData(SWT.END, SWT.CENTER, false, false));
+
+        new Label(buttons, SWT.NONE);
+
+        fEditButton = new Button(buttons, SWT.PUSH);
+        fEditButton.setText(Messages.TraceControl_NewNodeEditButtonName);
+        setButtonLayoutData(fEditButton);
+        fEditButton.addSelectionListener(new SelectionAdapter() {
+            @Override
+            public void widgetSelected(SelectionEvent e) {
+                onEditConnection();
+            }
+        });
+
+        fNewButton = new Button(buttons, SWT.PUSH);
+        fNewButton.setText(Messages.TraceControl_NewNodeCreateButtonText);
+        setButtonLayoutData(fNewButton);
+        fNewButton.addSelectionListener(new SelectionAdapter() {
+            @Override
+            public void widgetSelected(SelectionEvent e) {
+                onNewConnection();
+            }
+        });
+
+        return dialogComposite;
+    }
+
+    private void onSelectionChanged() {
+        setConnection();
+        getButton(OK).setEnabled(fConnection != null);
+        fEditButton.setEnabled(canEdit(fConnection));
+        fNewButton.setEnabled(getServiceForCreation() != null);
+    }
+
+    private IRemoteConnectionType getServiceForCreation() {
+        Object o = ((IStructuredSelection) fConnectionTree.getSelection()).getFirstElement();
+        IRemoteConnectionType result = null;
+        if (o instanceof IRemoteConnectionType) {
+            result = (IRemoteConnectionType) o;
+        } else if (o instanceof IRemoteConnection) {
+            result = ((IRemoteConnection) o).getConnectionType();
+        } else {
+            return null;
+        }
+
+        if (!result.canAdd()) {
+            return null;
+        }
+
+        return result;
+    }
+
+    private static boolean canEdit(IRemoteConnection conn) {
+        if (conn == null) {
+            return false;
+        }
+        return conn.getConnectionType().canEdit();
+    }
+
+    private void onNewConnection() {
+        IRemoteConnectionType rs = getServiceForCreation();
+        if (rs != null) {
+            IRemoteUIConnectionService uiService = rs.getService(IRemoteUIConnectionService.class);
+            if (uiService != null) {
+                IRemoteUIConnectionWizard wiz = uiService.getConnectionWizard(getShell());
+                if (wiz != null) {
+                    IRemoteConnectionWorkingCopy wc = wiz.open();
+                    if (wc != null) {
+                        IRemoteConnection conn = null;
+                        try {
+                            conn = wc.save();
+                        } catch (RemoteConnectionException e) {
+                            Activator.getDefault().logWarning("Connection configuration could not be saved for " + fConnection.getName() , e); //$NON-NLS-1$
+                        }
+                        if (conn != null) {
+                            fConnectionTree.refresh();
+                            fConnectionTree.setSelection(new StructuredSelection(conn), true);
+                        }
+                    }
+                }
+            }
+        }
+    }
+
+    private void onEditConnection() {
+        setConnection();
+        if (fConnection != null) {
+            IRemoteUIConnectionService ui = fConnection.getConnectionType().getService(IRemoteUIConnectionService.class);
+            if (ui != null) {
+                    IRemoteUIConnectionWizard wiz = ui.getConnectionWizard(getShell());
+                    wiz.setConnection(fConnection.getWorkingCopy());
+                    IRemoteConnectionWorkingCopy result = wiz.open();
+                    if (result != null) {
+                        try {
+                            result.save();
+                        } catch (RemoteConnectionException e) {
+                            Activator.getDefault().logWarning("Connection configuration could not be saved for " + fConnection.getName() , e); //$NON-NLS-1$
+                        }
+                        fConnectionTree.refresh();
+                    }
+            }
+        }
+    }
+
+    @Override
+    protected void createButtonsForButtonBar(Composite parent) {
+        createButton(parent, IDialogConstants.CANCEL_ID, "&Cancel", true); //$NON-NLS-1$
+        createButton(parent, IDialogConstants.OK_ID, "&Ok", true); //$NON-NLS-1$
+    }
+
+    @Override
+    protected void okPressed() {
+        setConnection();
+        if (fConnection != null) {
+            super.okPressed();
+        }
+    }
+
+    private void setConnection() {
+        Object o = ((IStructuredSelection) fConnectionTree.getSelection()).getFirstElement();
+        fConnection = o instanceof IRemoteConnection ? (IRemoteConnection) o : null;
+    }
+
+    @Override
+    public IRemoteConnection getConnection() {
+        return fConnection;
+    }
+
+    private static String getConnectionLabel(IRemoteConnection rc) {
+        StringBuffer label = new StringBuffer();
+        label.append(rc.getName());
+        if (rc.hasService(IRemoteConnectionHostService.class)) {
+            label.append(format(" [{0}]", rc.getService(IRemoteConnectionHostService.class).getHostname())); //$NON-NLS-1$
+        }
+        return label.toString();
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/OpenCommandScriptDialog.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/OpenCommandScriptDialog.java
new file mode 100644 (file)
index 0000000..bd648f5
--- /dev/null
@@ -0,0 +1,269 @@
+/**********************************************************************
+ * Copyright (c) 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
+
+import java.io.IOException;
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.List;
+
+import org.eclipse.core.runtime.IStatus;
+import org.eclipse.core.runtime.Status;
+import org.eclipse.jdt.annotation.NonNull;
+import org.eclipse.jface.dialogs.Dialog;
+import org.eclipse.jface.dialogs.ErrorDialog;
+import org.eclipse.jface.dialogs.IDialogConstants;
+import org.eclipse.jface.dialogs.IDialogSettings;
+import org.eclipse.swt.SWT;
+import org.eclipse.swt.graphics.Point;
+import org.eclipse.swt.graphics.Rectangle;
+import org.eclipse.swt.layout.GridData;
+import org.eclipse.swt.layout.GridLayout;
+import org.eclipse.swt.widgets.Button;
+import org.eclipse.swt.widgets.Combo;
+import org.eclipse.swt.widgets.Composite;
+import org.eclipse.swt.widgets.Control;
+import org.eclipse.swt.widgets.Event;
+import org.eclipse.swt.widgets.FileDialog;
+import org.eclipse.swt.widgets.Group;
+import org.eclipse.swt.widgets.Label;
+import org.eclipse.swt.widgets.Listener;
+import org.eclipse.swt.widgets.Shell;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
+import org.eclipse.tracecompass.tmf.core.io.BufferedRandomAccessFile;
+
+import com.google.common.collect.ImmutableList;
+
+/**
+ * <p>
+ * Dialog box for selecting a command script. It parses the script and
+ * provides a list of shell commands to be executed.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class OpenCommandScriptDialog extends Dialog implements ISelectCommandScriptDialog {
+
+    // ------------------------------------------------------------------------
+    // Constants
+    // ------------------------------------------------------------------------
+    /**
+     * The icon file for this dialog box.
+     */
+    public static final String CREATE_SESSION_ICON_FILE = "icons/elcl16/add_button.gif"; //$NON-NLS-1$
+
+    // Dialog settings constants
+    private static final String DIALOG_SETTINGS_SECTION = "OpenCommandScriptDialog"; //$NON-NLS-1$
+    private static final String FILE_NAME_ID = "STORE_FILE_NAME_ID"; //$NON-NLS-1$
+    private static final int COMBO_HISTORY_LENGTH = 5;
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+
+    // Dialog attributes
+    private Control fControl = null;
+    private Composite fDialogComposite = null;
+    private Button fBrowseButton;
+    private Label fFileNameLabel = null;
+    private Combo fFileNameCombo = null;
+
+    // Output list of commands
+    private List<String> fCommands = null;
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+    /**
+     * Constructor
+     * @param shell - a shell for the display of the dialog
+     */
+    public OpenCommandScriptDialog(Shell shell) {
+        super(shell);
+        setShellStyle(SWT.RESIZE | getShellStyle());
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    @Override
+    @NonNull public List<String> getCommands() {
+        if (fCommands != null) {
+            return fCommands;
+        }
+        return new ArrayList<>();
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    protected Control createContents(Composite parent) {
+        fControl = super.createContents(parent);
+
+        /* set the shell minimum size */
+        Point clientArea = fControl.computeSize(SWT.DEFAULT, SWT.DEFAULT);
+        Rectangle trim = getShell().computeTrim(0, 0, clientArea.x, clientArea.y);
+        getShell().setMinimumSize(trim.width, trim.height);
+
+        return fControl;
+    }
+
+    @Override
+    protected void configureShell(Shell newShell) {
+        super.configureShell(newShell);
+        newShell.setText(Messages.TraceControl_ExecuteScriptDialogTitle);
+        newShell.setImage(Activator.getDefault().loadIcon(CREATE_SESSION_ICON_FILE));
+    }
+
+    @Override
+    protected Control createDialogArea(Composite parent) {
+
+        // Main dialog panel
+        fDialogComposite = new Composite(parent, SWT.NONE);
+        GridLayout layout = new GridLayout(1, true);
+        fDialogComposite.setLayout(layout);
+        fDialogComposite.setLayoutData(new GridData(GridData.FILL_BOTH));
+
+        Group sessionGroup = new Group(fDialogComposite, SWT.SHADOW_NONE);
+        sessionGroup.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
+        sessionGroup.setLayout(new GridLayout(6, true));
+
+        fFileNameLabel = new Label(sessionGroup, SWT.RIGHT);
+        fFileNameLabel.setText(Messages.TraceControl_ExecuteScriptSelectLabel);
+        fFileNameCombo = new Combo(sessionGroup, SWT.BORDER);
+
+        fBrowseButton = new Button(sessionGroup, SWT.PUSH);
+        fBrowseButton.setText(Messages.TraceControl_ExecuteScriptBrowseText);
+        fBrowseButton.addListener(SWT.Selection, new Listener() {
+            @Override
+            public void handleEvent(Event event) {
+                handleFilePathBrowseButtonPressed(SWT.OPEN);
+            }
+        });
+
+        // layout widgets
+        GridData data = new GridData(GridData.FILL_HORIZONTAL);
+        data.horizontalSpan = 1;
+        data.grabExcessHorizontalSpace = false;
+        fFileNameLabel.setLayoutData(data);
+
+        data = new GridData(GridData.FILL_HORIZONTAL);
+        data.horizontalSpan = 4;
+        fFileNameCombo.setLayoutData(data);
+
+        data = new GridData(GridData.FILL_HORIZONTAL);
+        data.horizontalSpan = 1;
+
+        // Initialize a empty list
+        fCommands = new ArrayList<>();
+
+        restoreWidgetValues();
+
+        return fDialogComposite;
+    }
+
+    private void restoreWidgetValues() {
+        IDialogSettings workbenchSettings = Activator.getDefault().getDialogSettings();
+        IDialogSettings settings = workbenchSettings.getSection(DIALOG_SETTINGS_SECTION);
+        if (settings == null) {
+            settings = workbenchSettings.addNewSection(DIALOG_SETTINGS_SECTION);
+        }
+        String[] fileNames = settings.getArray(FILE_NAME_ID);
+        if ((fileNames != null) && (fileNames.length != 0)) {
+            for (int i = 0; i < fileNames.length; i++) {
+                fFileNameCombo.add(fileNames[i]);
+            }
+        }
+    }
+
+    private void saveWidgetValues() {
+        IDialogSettings workbenchSettings = Activator.getDefault().getDialogSettings();
+        IDialogSettings settings = workbenchSettings.getSection(DIALOG_SETTINGS_SECTION);
+        if (settings != null) {
+            // update file names history
+            String[] fileNames = settings.getArray(FILE_NAME_ID);
+            if (fileNames == null) {
+                fileNames = new String[0];
+            }
+
+            fileNames = addToHistory(fileNames, fFileNameCombo.getText().trim());
+            settings.put(FILE_NAME_ID, fileNames);
+        }
+    }
+
+    /**
+     * Adds an entry to a history, while taking care of duplicate history items
+     * and excessively long histories.  The assumption is made that all histories
+     * should be of length <code>COMBO_HISTORY_LENGTH</code>.
+     *
+     * @param history the current history
+     * @param newEntry the entry to add to the history
+     */
+    private static String[] addToHistory(String[] history, String newEntry) {
+        List<String> list = new ArrayList<>(Arrays.asList(history));
+        list.remove(newEntry);
+        list.add(0, newEntry);
+
+        // since only one new item was added, we can be over the limit
+        // by at most one item
+        if (list.size() > COMBO_HISTORY_LENGTH) {
+            list.remove(COMBO_HISTORY_LENGTH);
+        }
+        String[] r = new String[list.size()];
+        list.toArray(r);
+        return r;
+    }
+
+    private void handleFilePathBrowseButtonPressed(int fileDialogStyle) {
+        FileDialog dialog = new FileDialog(getShell(), fileDialogStyle | SWT.SHEET);
+        dialog.setFilterExtensions(new String[] { "*.*", "*.*" }); //$NON-NLS-1$ //$NON-NLS-2$
+        dialog.setText(Messages.TraceControl_ExecuteScriptDialogTitle);
+        String selectedFileName = dialog.open();
+        if (selectedFileName != null) {
+            fFileNameCombo.setText(selectedFileName);
+        }
+    }
+
+    @Override
+    protected void createButtonsForButtonBar(Composite parent) {
+        createButton(parent, IDialogConstants.CANCEL_ID, IDialogConstants.CANCEL_LABEL, true);
+        createButton(parent, IDialogConstants.OK_ID, IDialogConstants.OK_LABEL, true);
+    }
+
+    @Override
+    protected void okPressed() {
+        // Validate input data
+        String sessionPath = fFileNameCombo.getText();
+
+        if (!"".equals(sessionPath)) { //$NON-NLS-1$
+
+            ImmutableList.Builder<String> builder = new ImmutableList.Builder<>();
+            try (BufferedRandomAccessFile rafile = new BufferedRandomAccessFile(sessionPath, "r")) { //$NON-NLS-1$
+                String line = rafile.getNextLine();
+                while (line != null) {
+                    builder.add(line);
+                    line = rafile.getNextLine();
+                }
+            } catch (IOException e) {
+                ErrorDialog.openError(getShell(), null, null, new Status(IStatus.ERROR, Activator.PLUGIN_ID, IStatus.ERROR, e.getLocalizedMessage(), e));
+                return;
+            }
+            saveWidgetValues();
+            fCommands = builder.build();
+            super.okPressed();
+        }
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/TraceControlDialogFactory.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/TraceControlDialogFactory.java
new file mode 100644 (file)
index 0000000..78ec998
--- /dev/null
@@ -0,0 +1,282 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
+
+import org.eclipse.ui.PlatformUI;
+
+/**
+ * <p>
+ * Factory for generating dialog boxes. It allows to overwrite the dialog implementation.
+ * Useful also for testing purposes.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ *
+ */
+public final class TraceControlDialogFactory {
+
+    // ------------------------------------------------------------------------
+    // Members
+    // ------------------------------------------------------------------------
+
+    /**
+     * The factory instance.
+     */
+    private static TraceControlDialogFactory fInstance;
+
+    /**
+     * The new connection dialog reference.
+     */
+    private INewConnectionDialog fNewConnectionDialog;
+
+    /**
+     * The enable channel dialog
+     */
+    private IEnableChannelDialog fEnableChannelDialog;
+
+    /**
+     * The create session dialog.
+     */
+    private ICreateSessionDialog fCreateSessionDialog;
+
+    /**
+     * The command script selection dialog.
+     */
+    private ISelectCommandScriptDialog fCommandScriptDialog;
+
+    /**
+     * The enable events dialog.
+     */
+    private IEnableEventsDialog fEnableEventsDialog;
+
+    /**
+     * The get event info dialog.
+     */
+    private IGetEventInfoDialog fGetEventInfoDialog;
+
+    /**
+     * The confirmation dialog implementation.
+     */
+    private IConfirmDialog fConfirmDialog;
+
+    /**
+     * The add context dialog implementation.
+     */
+    private IAddContextDialog fAddContextDialog;
+
+    /**
+     * The import dialog implementation.
+     */
+    private IImportDialog fImportDialog;
+
+    /**
+     * The import confirmation dialog.
+     */
+    private IImportConfirmationDialog fImportConfirmationDialog;
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+
+    /**
+     * Constructor for R4EUIDialogFactory.
+     */
+    private TraceControlDialogFactory() {
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    /**
+     * @return TraceControlDialogFactory instance
+     */
+    public static synchronized TraceControlDialogFactory getInstance() {
+        if (fInstance == null) {
+            fInstance = new TraceControlDialogFactory();
+        }
+        return fInstance;
+    }
+
+    /**
+     * @return new connection dialog
+     */
+    public INewConnectionDialog getNewConnectionDialog() {
+        if (fNewConnectionDialog == null) {
+            fNewConnectionDialog = new NewConnectionDialog(PlatformUI.getWorkbench().getActiveWorkbenchWindow().getShell());
+        }
+        return fNewConnectionDialog;
+    }
+
+    /**
+     * Sets a new connection dialog implementation.
+     * @param newConnectionDialog - new connection dialog implementation
+     */
+    public void setNewConnectionDialog(INewConnectionDialog newConnectionDialog) {
+        fNewConnectionDialog = newConnectionDialog;
+    }
+
+    /**
+     * @return enable channel dialog
+     */
+    public IEnableChannelDialog getEnableChannelDialog() {
+        if (fEnableChannelDialog == null) {
+            fEnableChannelDialog = new EnableChannelDialog(PlatformUI.getWorkbench().getActiveWorkbenchWindow().getShell());
+        }
+        return fEnableChannelDialog;
+    }
+
+    /**
+     * Sets a enable channel dialog implementation.
+     * @param createEnableDialog - a create channel dialog implementation
+     */
+    public void setEnableChannelDialog(IEnableChannelDialog createEnableDialog) {
+        fEnableChannelDialog = createEnableDialog;
+    }
+
+    /**
+     * @return create session dialog implementation
+     */
+    public ICreateSessionDialog getCreateSessionDialog() {
+        if (fCreateSessionDialog == null) {
+            fCreateSessionDialog = new CreateSessionDialog(PlatformUI.getWorkbench().getActiveWorkbenchWindow().getShell());
+        }
+        return fCreateSessionDialog;
+    }
+
+    /**
+     * @return command script selection dialog implementation
+     */
+    public ISelectCommandScriptDialog getCommandScriptDialog() {
+        if (fCommandScriptDialog == null) {
+            fCommandScriptDialog = new OpenCommandScriptDialog(PlatformUI.getWorkbench().getActiveWorkbenchWindow().getShell());
+        }
+        return fCommandScriptDialog;
+    }
+
+    /**
+     * Sets a create session dialog implementation.
+     * @param createSessionDialog - a create session implementation.
+     */
+    public void setCreateSessionDialog(ICreateSessionDialog createSessionDialog) {
+        fCreateSessionDialog = createSessionDialog;
+    }
+
+    /**
+     * @return enable events dialog implementation.
+     */
+    public IEnableEventsDialog getEnableEventsDialog() {
+        if (fEnableEventsDialog == null) {
+            fEnableEventsDialog = new EnableEventsDialog(PlatformUI.getWorkbench().getActiveWorkbenchWindow().getShell());
+        }
+        return fEnableEventsDialog;
+    }
+
+    /**
+     * Sets a enable events dialog implementation.
+     * @param enableEventsDialog - a enable events dialog implementation.
+     */
+    public void setEnableEventsDialog(IEnableEventsDialog enableEventsDialog) {
+        fEnableEventsDialog = enableEventsDialog;
+    }
+
+    /**
+     * @return get events info dialog implementation.
+     */
+    public IGetEventInfoDialog getGetEventInfoDialog() {
+        if (fGetEventInfoDialog == null) {
+            fGetEventInfoDialog = new GetEventInfoDialog(PlatformUI.getWorkbench().getActiveWorkbenchWindow().getShell());
+        }
+        return fGetEventInfoDialog;
+    }
+
+    /**
+     * Sets a get events info dialog implementation.
+     * @param getEventInfoDialog - a get events info dialog implementation
+     */
+    public void setGetEventInfoDialog(IGetEventInfoDialog getEventInfoDialog) {
+        fGetEventInfoDialog = getEventInfoDialog;
+    }
+
+    /**
+     * @return the confirmation dialog implementation
+     */
+    public IConfirmDialog getConfirmDialog() {
+        if (fConfirmDialog == null) {
+            fConfirmDialog = new ConfirmDialog();
+        }
+        return fConfirmDialog;
+    }
+
+    /**
+     * Sets the confirmation dialog implementation
+     * @param confirmDialog - a confirmation dialog implementation
+     */
+    public void setConfirmDialog(IConfirmDialog confirmDialog) {
+        fConfirmDialog = confirmDialog;
+    }
+
+    /**
+     * @return the add context dialog implementation
+     */
+    public IAddContextDialog getAddContextDialog() {
+        if (fAddContextDialog == null) {
+            fAddContextDialog = new AddContextDialog(PlatformUI.getWorkbench().getActiveWorkbenchWindow().getShell());
+        }
+        return fAddContextDialog;
+    }
+
+    /**
+     * Sets the add context dialog information
+     * @param addContextDialog - a add context dialog implementation
+     */
+    public void setAddContextDialog(IAddContextDialog addContextDialog) {
+        fAddContextDialog = addContextDialog;
+    }
+
+    /**
+     * @return the import dialog implementation
+     */
+    public IImportDialog getImportDialog() {
+        if (fImportDialog == null) {
+            fImportDialog = new ImportDialog(PlatformUI.getWorkbench().getActiveWorkbenchWindow().getShell());
+        }
+        return fImportDialog;
+    }
+
+    /**
+     * Sets the import dialog implementation.
+     * @param importDialog - a import dialog implementation
+     */
+    public void setImportDialog(IImportDialog importDialog) {
+        fImportDialog = importDialog;
+    }
+
+    /**
+     * @return the import confirmation dialog implementation.
+     */
+    public IImportConfirmationDialog getImportConfirmationDialog() {
+        if (fImportConfirmationDialog == null) {
+            fImportConfirmationDialog = new ImportConfirmationDialog(PlatformUI.getWorkbench().getActiveWorkbenchWindow().getShell());
+        }
+        return fImportConfirmationDialog;
+    }
+
+    /**
+     * Sets the import confirmation dialog implementation.
+     * @param confirmDialog - a import confirmation dialog implementation.
+     */
+    public void setImportConfirmationDialog(IImportConfirmationDialog confirmDialog) {
+        fImportConfirmationDialog = confirmDialog;
+    }
+}
+
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/AddContextOnChannelHandler.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/AddContextOnChannelHandler.java
new file mode 100644 (file)
index 0000000..a68ce68
--- /dev/null
@@ -0,0 +1,90 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
+
+import java.util.Iterator;
+import java.util.List;
+
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.jface.viewers.ISelection;
+import org.eclipse.jface.viewers.StructuredSelection;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
+import org.eclipse.ui.IWorkbenchPage;
+
+/**
+ * <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
+    // ------------------------------------------------------------------------
+
+    @Override
+    public void addContexts(CommandParameter param, List<String> contextNames, IProgressMonitor monitor) throws ExecutionException {
+        if (param instanceof ChannelCommandParameter) {
+            TraceChannelComponent channel = ((ChannelCommandParameter)param).getChannel();
+            channel.addContexts(contextNames, monitor);
+        }
+    }
+
+    @Override
+    public boolean isEnabled() {
+        // Get workbench page for the Control View
+        IWorkbenchPage page = getWorkbenchPage();
+        if (page == null) {
+            return false;
+        }
+
+        TraceChannelComponent channel = null;
+        TraceSessionComponent session = null;
+        ISelection selection = page.getSelection(ControlView.ID);
+        if (selection instanceof StructuredSelection) {
+            StructuredSelection structered = ((StructuredSelection) selection);
+            for (Iterator<?> iterator = structered.iterator(); iterator.hasNext();) {
+                Object element = iterator.next();
+                if (element instanceof TraceChannelComponent) {
+                    // Add only if corresponding TraceSessionComponents is inactive and not destroyed
+                    TraceChannelComponent tmpChannel = (TraceChannelComponent) element;
+                    session = tmpChannel.getSession();
+                    if(session.getSessionState() == TraceSessionState.INACTIVE && !session.isDestroyed()) {
+                        channel = tmpChannel;
+                    }
+                }
+            }
+        }
+
+        boolean isEnabled = (channel != null);
+        fLock.lock();
+        try {
+            fParam = null;
+            if(isEnabled) {
+                fParam = new ChannelCommandParameter(session, channel);
+            }
+        } finally {
+            fLock.unlock();
+        }
+        return isEnabled;
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/AddContextOnDomainHandler.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/AddContextOnDomainHandler.java
new file mode 100644 (file)
index 0000000..d7051e0
--- /dev/null
@@ -0,0 +1,98 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
+
+import java.util.Iterator;
+import java.util.List;
+
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.jface.viewers.ISelection;
+import org.eclipse.jface.viewers.StructuredSelection;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
+import org.eclipse.ui.IWorkbenchPage;
+
+/**
+ * <p>
+ * Command handler implementation to add contexts to all channels and all events.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class AddContextOnDomainHandler extends BaseAddContextHandler {
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    public void addContexts(CommandParameter param, List<String> contextNames, IProgressMonitor monitor) throws ExecutionException {
+        if (param instanceof DomainCommandParameter) {
+            TraceDomainComponent domain = ((DomainCommandParameter)param).getDomain();
+            domain.addContexts(contextNames, monitor);
+        }
+    }
+
+    @Override
+    public boolean isEnabled() {
+
+        // Get workbench page for the Control View
+        IWorkbenchPage page = getWorkbenchPage();
+        if (page == null) {
+            return false;
+        }
+
+        TraceDomainComponent domain = null;
+        TraceSessionComponent session = null;
+
+        // Check if one domain is selected
+        ISelection selection = page.getSelection(ControlView.ID);
+        if (selection instanceof StructuredSelection) {
+            StructuredSelection structered = ((StructuredSelection) selection);
+            for (Iterator<?> iterator = structered.iterator(); iterator.hasNext();) {
+                Object element = iterator.next();
+                if (element instanceof TraceDomainComponent) {
+                    TraceDomainComponent tmpDomain = (TraceDomainComponent) element;
+                    session = (TraceSessionComponent) tmpDomain.getParent();
+
+                    // Add only TraceDomainComponent whose TraceSessionComponent parent is inactive and not destroyed
+                    if ((session.getSessionState() == TraceSessionState.INACTIVE) && (!session.isDestroyed())) {
+                        domain = tmpDomain;
+                    }
+                }
+            }
+        }
+
+        boolean isEnabled = domain != null;
+
+        fLock.lock();
+        try {
+            fParam = null;
+            if (isEnabled) {
+                fParam = new DomainCommandParameter(session, domain);
+            }
+        } finally {
+            fLock.unlock();
+        }
+
+        return isEnabled;
+    }
+
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/AddContextOnEventHandler.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/AddContextOnEventHandler.java
new file mode 100644 (file)
index 0000000..253d52e
--- /dev/null
@@ -0,0 +1,90 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
+
+import java.util.Iterator;
+import java.util.List;
+
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.jface.viewers.ISelection;
+import org.eclipse.jface.viewers.StructuredSelection;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceEventComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
+import org.eclipse.ui.IWorkbenchPage;
+
+/**
+ * <p>
+ * Command handler implementation to add contexts to a given event.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class AddContextOnEventHandler extends BaseAddContextHandler {
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    public void addContexts(CommandParameter param, List<String> contextNames, IProgressMonitor monitor) throws ExecutionException {
+        if (param instanceof EventCommandParameter) {
+            TraceEventComponent event = ((EventCommandParameter)param).getEvent();
+            event.addContexts(contextNames, monitor);
+        }
+    }
+
+    @Override
+    public boolean isEnabled() {
+        // Get workbench page for the Control View
+        IWorkbenchPage page = getWorkbenchPage();
+        if (page == null) {
+            return false;
+        }
+
+        TraceEventComponent event = null;
+        TraceSessionComponent session = null;
+        ISelection selection = page.getSelection(ControlView.ID);
+        if (selection instanceof StructuredSelection) {
+            StructuredSelection structered = ((StructuredSelection) selection);
+            for (Iterator<?> iterator = structered.iterator(); iterator.hasNext();) {
+                Object element = iterator.next();
+                if (element instanceof TraceEventComponent) {
+                    // Add only if corresponding TraceSessionComponents is inactive and not destroyed
+                    TraceEventComponent tmpEvent = (TraceEventComponent) element;
+                    session = tmpEvent.getSession();
+                    if(session.getSessionState() == TraceSessionState.INACTIVE && !session.isDestroyed()) {
+                        event = tmpEvent;
+                    }
+                }
+            }
+        }
+
+        boolean isEnabled = (event != null);
+        fLock.lock();
+        try {
+            fParam = null;
+            if(isEnabled) {
+                fParam = new EventCommandParameter(session, event);
+            }
+        } finally {
+            fLock.unlock();
+        }
+        return isEnabled;
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/AssignEventHandler.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/AssignEventHandler.java
new file mode 100644 (file)
index 0000000..36032f4
--- /dev/null
@@ -0,0 +1,253 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
+
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.Iterator;
+import java.util.List;
+
+import org.eclipse.core.commands.ExecutionEvent;
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.core.runtime.IStatus;
+import org.eclipse.core.runtime.Status;
+import org.eclipse.core.runtime.jobs.Job;
+import org.eclipse.jface.viewers.ISelection;
+import org.eclipse.jface.viewers.StructuredSelection;
+import org.eclipse.jface.window.Window;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.IGetEventInfoDialog;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.TraceControlDialogFactory;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.BaseEventComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.KernelProviderComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.UstProviderComponent;
+import org.eclipse.ui.IWorkbenchPage;
+
+/**
+ * <p>
+ * Command handler implementation to assign events to a session and channel and enable/configure them.
+ * This is done on the trace provider level.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class AssignEventHandler extends BaseControlViewHandler {
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+
+    /**
+     * The command execution parameter.
+     */
+    private Parameter fParam;
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    public Object execute(ExecutionEvent event) throws ExecutionException {
+
+        fLock.lock();
+        try {
+            // Make a copy for thread safety
+            final Parameter param = new Parameter(fParam);
+
+            // Open dialog box to retrieve the session and channel where the events should be enabled in.
+            final IGetEventInfoDialog dialog = TraceControlDialogFactory.getInstance().getGetEventInfoDialog();
+            dialog.setIsKernel(param.isKernel());
+            dialog.setSessions(param.getSessions());
+
+            if (dialog.open() != Window.OK) {
+                return null;
+            }
+
+            Job job = new Job(Messages.TraceControl_EnableEventsJob) {
+                @Override
+                protected IStatus run(IProgressMonitor monitor) {
+
+                    Exception error = null;
+
+                    try {
+                        List<String> eventNames = new ArrayList<>();
+                        List<BaseEventComponent> events = param.getEvents();
+                        // Create list of event names
+                        for (Iterator<BaseEventComponent> iterator = events.iterator(); iterator.hasNext();) {
+                            BaseEventComponent baseEvent = iterator.next();
+                            eventNames.add(baseEvent.getName());
+                        }
+
+                        TraceChannelComponent channel = dialog.getChannel();
+                        if (channel == null) {
+                            // enable events on default channel (which will be created by lttng-tools)
+                            dialog.getSession().enableEvents(eventNames, param.isKernel(), dialog.getFilterExpression(), monitor);
+                        } else {
+                            channel.enableEvents(eventNames, dialog.getFilterExpression(), monitor);
+                        }
+
+                    } catch (ExecutionException e) {
+                        error = e;
+                    }
+
+                    // refresh in all cases
+                    refresh(new CommandParameter(dialog.getSession()));
+
+                    if (error != null) {
+                        return new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.TraceControl_EnableEventsFailure, error);
+                    }
+                    return Status.OK_STATUS;
+                }
+            };
+            job.setUser(true);
+            job.schedule();
+        } finally {
+            fLock.unlock();
+        }
+
+        return null;
+    }
+
+    @Override
+    public boolean isEnabled() {
+        ArrayList<BaseEventComponent> events = new ArrayList<>();
+        TraceSessionComponent[] sessions = null;
+        Boolean isKernel = null;
+
+        // Get workbench page for the Control View
+        IWorkbenchPage page = getWorkbenchPage();
+        if (page == null) {
+            return false;
+        }
+
+        // Check if one or more session are selected
+        ISelection selection = page.getSelection(ControlView.ID);
+        if (selection instanceof StructuredSelection) {
+
+            StructuredSelection structered = ((StructuredSelection) selection);
+            for (Iterator<?> iterator = structered.iterator(); iterator.hasNext();) {
+                Object element = iterator.next();
+                if (element instanceof BaseEventComponent) {
+                    BaseEventComponent event = (BaseEventComponent) element;
+                    ITraceControlComponent provider = event.getParent();
+
+                    // check for kernel or UST provider
+                    boolean temp = false;
+                    if (provider instanceof KernelProviderComponent) {
+                        temp = true;
+                    } else if (provider instanceof UstProviderComponent) {
+                        temp = false;
+                    } else {
+                        return false;
+                    }
+                    if (isKernel == null) {
+                        isKernel = Boolean.valueOf(temp);
+                    } else {
+                        // don't mix events from Kernel and UST provider
+                        if (isKernel.booleanValue() != temp) {
+                            return false;
+                        }
+                    }
+
+                    // Add BaseEventComponents
+                    events.add(event);
+
+                    if (sessions == null) {
+                        TargetNodeComponent  root = (TargetNodeComponent)event.getParent().getParent().getParent();
+                        sessions = root.getSessions();
+                    }
+                }
+            }
+        }
+
+        boolean isEnabled = ((!events.isEmpty()) && (sessions != null) && (sessions.length > 0));
+
+        // To avoid compiler warnings check for null even if isKernel is always not null when used below
+        if (isKernel == null) {
+            return false;
+        }
+
+        fLock.lock();
+        try {
+            fParam = null;
+            if(isEnabled) {
+                fParam = new Parameter(sessions, events, isKernel);
+            }
+        } finally {
+            fLock.unlock();
+        }
+        return isEnabled;
+    }
+
+    /**
+     *  Class containing parameter for the command execution.
+     */
+    private static final class Parameter {
+
+        /**
+         * The list of event components the command is to be executed on.
+         */
+        private final List<BaseEventComponent> fEvents;
+
+        /**
+         * The list of available sessions.
+         */
+        private final TraceSessionComponent[] fSessions;
+
+        /**
+         * Flag for indicating Kernel or UST.
+         */
+        private final boolean fIsKernel;
+
+        /**
+         * Constructor
+         *
+         * @param sessions - a array of trace sessions
+         * @param events - a lists of events to enable
+         * @param isKernel - domain (true for kernel or UST)
+         */
+        public Parameter(TraceSessionComponent[] sessions, List<BaseEventComponent> events, boolean isKernel) {
+            fSessions = Arrays.copyOf(sessions, sessions.length);
+            fEvents = new ArrayList<>();
+            fEvents.addAll(events);
+            fIsKernel = isKernel;
+        }
+
+        /**
+         * Copy constructor
+         * @param other - a parameter to copy
+         */
+        public Parameter(Parameter other) {
+            this(other.fSessions, other.fEvents, other.fIsKernel);
+        }
+
+        public TraceSessionComponent[] getSessions() {
+            return fSessions;
+        }
+
+        public List<BaseEventComponent> getEvents() {
+            return fEvents;
+        }
+
+        public boolean isKernel() {
+            return fIsKernel;
+        }
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/BaseAddContextHandler.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/BaseAddContextHandler.java
new file mode 100644 (file)
index 0000000..35d1052
--- /dev/null
@@ -0,0 +1,132 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
+
+import java.util.List;
+
+import org.eclipse.core.commands.ExecutionEvent;
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.core.runtime.IStatus;
+import org.eclipse.core.runtime.Status;
+import org.eclipse.core.runtime.jobs.Job;
+import org.eclipse.jface.window.Window;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.IAddContextDialog;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.TraceControlDialogFactory;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
+import org.eclipse.ui.IWorkbenchWindow;
+import org.eclipse.ui.PlatformUI;
+import org.eclipse.ui.progress.UIJob;
+
+/**
+ * <p>
+ * Base command handler implementation to add contexts.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public abstract class BaseAddContextHandler extends BaseControlViewHandler {
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+
+    /**
+     * The command execution parameter.
+     */
+    protected CommandParameter fParam = null;
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    /**
+     * Adds contexts to channel(s) and/or event(s)
+     *
+     * @param param
+     *            - a parameter instance with data for the command execution
+     * @param contextNames
+     *            - list contexts to add
+     * @param monitor
+     *            - a progress monitor
+     * @throws ExecutionException
+     *             If something goes wrong
+     */
+    public abstract void addContexts(CommandParameter param, List<String> contextNames, IProgressMonitor monitor) throws ExecutionException;
+
+    @Override
+    public Object execute(ExecutionEvent event) throws ExecutionException {
+
+        final IWorkbenchWindow window = PlatformUI.getWorkbench().getActiveWorkbenchWindow();
+
+        if (window == null) {
+            return false;
+        }
+        fLock.lock();
+        try {
+            // Make a copy for thread safety
+            final CommandParameter param = fParam.clone();
+
+            UIJob getJob = new UIJob(Messages.TraceControl_GetContextJob) {
+                @Override
+                public IStatus runInUIThread(IProgressMonitor monitor) {
+
+                    try {
+                        final List<String> availableContexts = param.getSession().getContextList(monitor);
+                        final IAddContextDialog dialog = TraceControlDialogFactory.getInstance().getAddContextDialog();
+                        dialog.setAvalibleContexts(availableContexts);
+
+                        if ((dialog.open() != Window.OK) || (dialog.getContexts().isEmpty())) {
+                            return Status.OK_STATUS;
+                        }
+
+                        Job addJob = new Job(Messages.TraceControl_AddContextJob) {
+                            @Override
+                            protected IStatus run(IProgressMonitor monitor2) {
+                                Exception error = null;
+
+                                try {
+                                    List<String> contextNames = dialog.getContexts();
+                                    addContexts(param, contextNames, monitor2);
+
+                                } catch (ExecutionException e) {
+                                    error = e;
+                                }
+
+                                // get session configuration in all cases
+                                refresh(param);
+
+                                if (error != null) {
+                                    return new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.TraceControl_AddContextFailure, error);
+                                }
+                                return Status.OK_STATUS;
+                            }
+                        };
+                        addJob.setUser(true);
+                        addJob.schedule();
+                    } catch (ExecutionException e) {
+                        return new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.TraceControl_GetContextFailure, e);
+                    }
+
+                    return Status.OK_STATUS;
+                }
+            };
+            getJob.setUser(false);
+            getJob.schedule();
+
+        } finally {
+            fLock.unlock();
+        }
+        return null;
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/BaseControlViewHandler.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/BaseControlViewHandler.java
new file mode 100644 (file)
index 0000000..8e50191
--- /dev/null
@@ -0,0 +1,94 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
+
+import java.util.concurrent.locks.ReentrantLock;
+
+import org.eclipse.core.commands.AbstractHandler;
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.core.runtime.IStatus;
+import org.eclipse.core.runtime.Status;
+import org.eclipse.core.runtime.jobs.Job;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
+import org.eclipse.ui.IWorkbenchPage;
+import org.eclipse.ui.IWorkbenchPart;
+import org.eclipse.ui.IWorkbenchWindow;
+import org.eclipse.ui.PlatformUI;
+
+/**
+ * <p>
+ * Abstract Command handler implementation for all control view handlers.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public abstract class BaseControlViewHandler extends AbstractHandler {
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+    /**
+     * The synchronization lock.
+     */
+    protected final ReentrantLock fLock = new ReentrantLock();
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+    /**
+     * @return returns the workbench page for the Control View
+     */
+    protected IWorkbenchPage getWorkbenchPage() {
+        // Check if we are closing down
+        IWorkbenchWindow window = PlatformUI.getWorkbench().getActiveWorkbenchWindow();
+        if (window == null) {
+            return null;
+        }
+
+        // Check if we are in the Project View
+        IWorkbenchPage page = window.getActivePage();
+        if (page == null) {
+            return null;
+        }
+
+        IWorkbenchPart part = page.getActivePart();
+        if (!(part instanceof ControlView)) {
+            return null;
+        }
+        return page;
+    }
+
+    /**
+     * Refreshes the session information based on given session (in CommandParameter)
+     * @param param - command parameter containing the session to refresh
+     */
+    protected void refresh(final CommandParameter param) {
+        Job job = new Job(Messages.TraceControl_RetrieveNodeConfigurationJob) {
+
+            @Override
+            protected IStatus run(IProgressMonitor monitor) {
+                try {
+                    param.getSession().getConfigurationFromNode(monitor);
+                } catch (ExecutionException e) {
+                    return new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.TraceControl_ListSessionFailure, e);
+                }
+                return Status.OK_STATUS;
+            }
+        };
+        job.setUser(true);
+        job.schedule();
+    }
+
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/BaseEnableChannelHandler.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/BaseEnableChannelHandler.java
new file mode 100644 (file)
index 0000000..413739a
--- /dev/null
@@ -0,0 +1,124 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import org.eclipse.core.commands.ExecutionEvent;
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.core.runtime.IStatus;
+import org.eclipse.core.runtime.Status;
+import org.eclipse.core.runtime.jobs.Job;
+import org.eclipse.jface.window.Window;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IChannelInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.IEnableChannelDialog;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.TraceControlDialogFactory;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent;
+
+/**
+ * <p>
+ * Base implementation of a command handler to enable a trace channel.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+abstract class BaseEnableChannelHandler extends BaseControlViewHandler {
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+    protected CommandParameter fParam;
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    /**
+     * Enables channels with given names which are part of this domain. If a
+     * given channel doesn't exists it creates a new channel with the given
+     * parameters (or default values if given parameter is null).
+     *
+     * @param param
+     *            - a parameter instance with data for the command execution
+     * @param channelNames
+     *            - a list of channel names to enable on this domain
+     * @param info
+     *            - channel information to set for the channel (use null for
+     *            default)
+     * @param isKernel
+     *            - a flag for indicating kernel or UST.
+     * @param monitor
+     *            - a progress monitor
+     * @throws ExecutionException
+     *             If something goes wrong when enabling the channel
+     */
+    public abstract void enableChannel(CommandParameter param,
+            List<String> channelNames, IChannelInfo info, boolean isKernel,
+            IProgressMonitor monitor) throws ExecutionException;
+
+    /**
+     * @param param - a parameter instance with data for the command execution
+     * @return returns the relevant domain (null if domain is not known)
+     */
+    public abstract TraceDomainComponent getDomain(CommandParameter param);
+
+    @Override
+    public Object execute(ExecutionEvent event) throws ExecutionException {
+        fLock.lock();
+        try {
+            final CommandParameter param = fParam.clone();
+
+            final IEnableChannelDialog dialog =  TraceControlDialogFactory.getInstance().getEnableChannelDialog();
+            dialog.setTargetNodeComponent(param.getSession().getTargetNode());
+            dialog.setDomainComponent(getDomain(param));
+            dialog.setHasKernel(param.getSession().hasKernelProvider());
+
+            if (dialog.open() != Window.OK) {
+                return null;
+            }
+
+            Job job = new Job(Messages.TraceControl_CreateChannelStateJob) {
+                @Override
+                protected IStatus run(IProgressMonitor monitor) {
+                    Exception error = null;
+
+                    List<String> channelNames = new ArrayList<>();
+                    channelNames.add(dialog.getChannelInfo().getName());
+
+                    try {
+                        enableChannel(param, channelNames, dialog.getChannelInfo(), dialog.isKernel(), monitor);
+                    } catch (ExecutionException e) {
+                        error = e;
+                    }
+
+                    // refresh in all cases
+                    refresh(param);
+
+                    if (error != null) {
+                        return new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.TraceControl_CreateChannelStateFailure, error);
+                    }
+                    return Status.OK_STATUS;
+                }
+            };
+            job.setUser(true);
+            job.schedule();
+        } finally {
+            fLock.unlock();
+        }
+        return null;
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/BaseEnableEventHandler.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/BaseEnableEventHandler.java
new file mode 100644 (file)
index 0000000..45a3349
--- /dev/null
@@ -0,0 +1,227 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
+
+import java.util.List;
+
+import org.eclipse.core.commands.ExecutionEvent;
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.core.runtime.IStatus;
+import org.eclipse.core.runtime.Status;
+import org.eclipse.core.runtime.jobs.Job;
+import org.eclipse.jface.window.Window;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.LogLevelType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.IEnableEventsDialog;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.TraceControlDialogFactory;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceProviderGroup;
+import org.eclipse.ui.IWorkbenchWindow;
+import org.eclipse.ui.PlatformUI;
+
+/**
+ * <p>
+ * Base command handler implementation to enable events.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public abstract class BaseEnableEventHandler extends BaseControlViewHandler {
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+    /**
+     * The command execution parameter.
+     */
+    protected CommandParameter fParam = null;
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    /**
+     * Enables a list of events for given parameters.
+     *
+     * @param param
+     *            - a parameter instance with data for the command execution
+     * @param eventNames
+     *            - list of event names
+     * @param isKernel
+     *            - true if kernel domain else false
+     * @param filterExpression
+     *            - a filter expression
+     * @param monitor
+     *            - a progress monitor
+     * @throws ExecutionException
+     *             If the command fails for some reason
+     */
+    public abstract void enableEvents(CommandParameter param, List<String> eventNames, boolean isKernel, String filterExpression, IProgressMonitor monitor) throws ExecutionException;
+
+    /**
+     * Enables all syscall events.
+     *
+     * @param param
+     *            - a parameter instance with data for the command execution
+     * @param monitor
+     *            - a progress monitor
+     * @throws ExecutionException
+     *             If the command fails for some reason
+     */
+    public abstract void enableSyscalls(CommandParameter param, IProgressMonitor monitor) throws ExecutionException;
+
+    /**
+     * Enables a dynamic probe.
+     *
+     * @param param
+     *            - a parameter instance with data for the command execution
+     * @param eventName
+     *            - a event name
+     * @param isFunction
+     *            - true for dynamic function entry/return probe else false
+     * @param probe
+     *            - a dynamic probe information
+     * @param monitor
+     *            - a progress monitor
+     * @throws ExecutionException
+     *             If the command fails for some reason
+     */
+    public abstract void enableProbe(CommandParameter param, String eventName, boolean isFunction, String probe, IProgressMonitor monitor) throws ExecutionException;
+
+    /**
+     * Enables events using log level
+     *
+     * @param param
+     *            - a parameter instance with data for the command execution
+     * @param eventName
+     *            - a event name
+     * @param logLevelType
+     *            - a log level type
+     * @param level
+     *            - a log level
+     * @param filterExpression
+     *            - a filter expression
+     * @param monitor
+     *            - a progress monitor
+     * @throws ExecutionException
+     *             If the command fails for some reason
+     */
+    public abstract void enableLogLevel(CommandParameter param, String eventName, LogLevelType logLevelType, TraceLogLevel level, String filterExpression, IProgressMonitor monitor) throws ExecutionException;
+
+    /**
+     * @param param
+     *            - a parameter instance with data for the command execution
+     * @return returns the relevant domain (null if domain is not known)
+     */
+    public abstract TraceDomainComponent getDomain(CommandParameter param);
+
+    @Override
+    public Object execute(ExecutionEvent event) throws ExecutionException {
+
+        final IWorkbenchWindow window = PlatformUI.getWorkbench().getActiveWorkbenchWindow();
+
+        if (window == null) {
+            return false;
+        }
+        fLock.lock();
+        try {
+            // Make a copy for thread safety
+            final CommandParameter param = fParam.clone();
+
+            TargetNodeComponent node = param.getSession().getTargetNode();
+            List<ITraceControlComponent> providers = node.getChildren(TraceProviderGroup.class);
+
+            final IEnableEventsDialog dialog = TraceControlDialogFactory.getInstance().getEnableEventsDialog();
+            dialog.setTraceProviderGroup((TraceProviderGroup)providers.get(0));
+            dialog.setTraceDomainComponent(getDomain(param));
+
+            if (dialog.open() != Window.OK) {
+                return null;
+            }
+
+            Job job = new Job(Messages.TraceControl_ChangeEventStateJob) {
+                @Override
+                protected IStatus run(IProgressMonitor monitor) {
+                    Exception error = null;
+
+                    try {
+                        String filter = dialog.getFilterExpression();
+
+                        // Enable tracepoint events
+                        if (dialog.isTracepoints()) {
+                            if (dialog.isAllTracePoints()) {
+                                enableEvents(param, null, dialog.isKernel(), filter, monitor);
+                            } else {
+                                List<String> eventNames = dialog.getEventNames();
+                                if (!eventNames.isEmpty()) {
+                                    enableEvents(param, eventNames, dialog.isKernel(), filter, monitor);
+                                }
+                            }
+                        }
+
+                        // Enable syscall events
+                        if (dialog.isAllSysCalls()) {
+                            enableSyscalls(param, monitor);
+                        }
+
+                        // Enable dynamic probe
+                        if (dialog.isDynamicProbe() && (dialog.getProbeEventName() != null) && (dialog.getProbeName() != null)) {
+                            enableProbe(param, dialog.getProbeEventName(), false, dialog.getProbeName(), monitor);
+                        }
+
+                        // Enable dynamic function probe
+                        if (dialog.isDynamicFunctionProbe() && (dialog.getFunctionEventName() != null) && (dialog.getFunction() != null)) {
+                            enableProbe(param, dialog.getFunctionEventName(), true, dialog.getFunction(), monitor);
+                        }
+
+                        // Enable event using a wildcard
+                        if (dialog.isWildcard()) {
+                            List<String> eventNames = dialog.getEventNames();
+                            eventNames.add(dialog.getWildcard());
+
+                            if (!eventNames.isEmpty()) {
+                                enableEvents(param, eventNames, dialog.isKernel(), filter, monitor);
+                            }
+                        }
+
+                        // Enable events using log level
+                        if (dialog.isLogLevel()) {
+                            enableLogLevel(param, dialog.getLogLevelEventName(), dialog.getLogLevelType(), dialog.getLogLevel(), filter, monitor);
+                        }
+
+                    } catch (ExecutionException e) {
+                        error = e;
+                    }
+
+                    // refresh in all cases
+                    refresh(param);
+
+                    if (error != null) {
+                        return new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.TraceControl_ChangeEventStateFailure, error);
+                    }
+                    return Status.OK_STATUS;
+                }
+            };
+            job.setUser(true);
+            job.schedule();
+        } finally {
+            fLock.unlock();
+        }
+        return null;
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/BaseNodeHandler.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/BaseNodeHandler.java
new file mode 100644 (file)
index 0000000..90bf62e
--- /dev/null
@@ -0,0 +1,70 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
+
+import org.eclipse.jface.viewers.ISelection;
+import org.eclipse.jface.viewers.StructuredSelection;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent;
+import org.eclipse.ui.IWorkbenchPage;
+
+/**
+ * <p>
+ * Command handler implementation to delete a target host.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public abstract class BaseNodeHandler extends BaseControlViewHandler {
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+    /**
+     * The target node component the command is to be executed on.
+     */
+    protected TargetNodeComponent fTargetNode = null;
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    public boolean isEnabled() {
+
+        // Get workbench page for the Control View
+        IWorkbenchPage page = getWorkbenchPage();
+        if (page == null) {
+            return false;
+        }
+
+        TargetNodeComponent node = null;
+        // Check if the node component is selected
+        ISelection selection = page.getSelection(ControlView.ID);
+        if (selection instanceof StructuredSelection) {
+            Object element = ((StructuredSelection) selection).getFirstElement();
+            node = (element instanceof TargetNodeComponent) ? (TargetNodeComponent) element : null;
+        }
+        boolean isEnabled = node != null;
+        fLock.lock();
+        try {
+            if (isEnabled) {
+                fTargetNode = node;
+            }
+        } finally {
+            fLock.unlock();
+        }
+        return isEnabled;
+    }
+
+
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/CalibrateHandler.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/CalibrateHandler.java
new file mode 100644 (file)
index 0000000..b55a3b9
--- /dev/null
@@ -0,0 +1,132 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
+
+import java.util.Iterator;
+
+import org.eclipse.core.commands.ExecutionEvent;
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.core.runtime.IStatus;
+import org.eclipse.core.runtime.Status;
+import org.eclipse.core.runtime.jobs.Job;
+import org.eclipse.jface.viewers.ISelection;
+import org.eclipse.jface.viewers.StructuredSelection;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
+import org.eclipse.ui.IWorkbenchPage;
+import org.eclipse.ui.IWorkbenchWindow;
+import org.eclipse.ui.PlatformUI;
+
+/**
+ * <p>
+ * Command handler implementation to execute command calibrate to quantify LTTng overhead.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class CalibrateHandler extends BaseControlViewHandler {
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+    /**
+     * The command execution parameter.
+     */
+    protected DomainCommandParameter fParam = null;
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    public Object execute(ExecutionEvent event) throws ExecutionException {
+
+        final IWorkbenchWindow window = PlatformUI.getWorkbench().getActiveWorkbenchWindow();
+
+        if (window == null) {
+            return false;
+        }
+        fLock.lock();
+        try {
+            // Make a copy for thread safety
+            final DomainCommandParameter param = fParam.clone();
+
+            Job addJob = new Job(Messages.TraceControl_AddCalibrateJob) {
+                @Override
+                protected IStatus run(IProgressMonitor monitor) {
+                    try {
+                        param.getDomain().calibrate(monitor);
+                    } catch (ExecutionException e) {
+                        return new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.TraceControl_AddCalibrateFailure, e);
+                    }
+
+                    return Status.OK_STATUS;
+                }
+            };
+            addJob.setUser(true);
+            addJob.schedule();
+
+        } finally {
+            fLock.unlock();
+        }
+        return Status.OK_STATUS;
+    }
+
+    @Override
+    public boolean isEnabled() {
+
+        // Get workbench page for the Control View
+        IWorkbenchPage page = getWorkbenchPage();
+        if (page == null) {
+            return false;
+        }
+
+        TraceDomainComponent domain = null;
+        TraceSessionComponent session = null;
+
+        // Check if one domain is selected
+        ISelection selection = page.getSelection(ControlView.ID);
+        if (selection instanceof StructuredSelection) {
+            StructuredSelection structered = ((StructuredSelection) selection);
+            for (Iterator<?> iterator = structered.iterator(); iterator.hasNext();) {
+                Object element = iterator.next();
+                if (element instanceof TraceDomainComponent) {
+                    TraceDomainComponent tmpDomain = (TraceDomainComponent) element;
+                    session = (TraceSessionComponent) tmpDomain.getParent();
+
+                    // Add only TraceDomainComponent whose TraceSessionComponent parent is not destroyed
+                    if ((!session.isDestroyed())) {
+                        domain = tmpDomain;
+                    }
+                }
+            }
+        }
+
+        boolean isEnabled = domain != null;
+
+        fLock.lock();
+        try {
+            fParam = null;
+            if (isEnabled) {
+                fParam = new DomainCommandParameter(session, domain);
+            }
+        } finally {
+            fLock.unlock();
+        }
+
+        return isEnabled;
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/ChangeChannelStateHandler.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/ChangeChannelStateHandler.java
new file mode 100644 (file)
index 0000000..98789be
--- /dev/null
@@ -0,0 +1,303 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
+
+import java.util.ArrayList;
+import java.util.Iterator;
+import java.util.List;
+
+import org.eclipse.core.commands.ExecutionEvent;
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.core.runtime.IStatus;
+import org.eclipse.core.runtime.Status;
+import org.eclipse.core.runtime.jobs.Job;
+import org.eclipse.jface.viewers.ISelection;
+import org.eclipse.jface.viewers.StructuredSelection;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEnablement;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
+import org.eclipse.ui.IWorkbenchPage;
+import org.eclipse.ui.IWorkbenchWindow;
+import org.eclipse.ui.PlatformUI;
+
+/**
+ * <p>
+ * Abstract command handler implementation to enable or disabling a trace channel.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public abstract class ChangeChannelStateHandler extends BaseControlViewHandler {
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+    /**
+     * The command execution parameter.
+     */
+    protected Parameter fParam;
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+    /**
+     * @return the new state to set
+     */
+    protected abstract TraceEnablement getNewState();
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+    /**
+     * Changes the state of the given channels.
+     * @param domain - the domain of the channels.
+     * @param channelNames - a list of channel names
+     * @param monitor - a progress monitor
+     * @throws ExecutionException If the command fails
+     */
+    protected abstract void changeState(TraceDomainComponent domain, List<String> channelNames, IProgressMonitor monitor) throws ExecutionException;
+
+    @Override
+    public Object execute(ExecutionEvent event) throws ExecutionException {
+
+        fLock.lock();
+        try {
+            IWorkbenchWindow window = PlatformUI.getWorkbench().getActiveWorkbenchWindow();
+
+            if (window == null) {
+                return false;
+            }
+
+            final Parameter param = new Parameter(fParam);
+
+            Job job = new Job(Messages.TraceControl_ChangeChannelStateJob) {
+                @Override
+                protected IStatus run(IProgressMonitor monitor) {
+                    Exception error = null;
+
+                    TraceSessionComponent session = null;
+
+                    try {
+                        TraceDomainComponent kernelDomain = param.getKernelDomain();
+                        List<TraceChannelComponent> kernelChannels = param.getKernelChannels();
+
+                        if (kernelDomain != null) {
+                            session = (TraceSessionComponent)kernelDomain.getParent();
+                            List<String> channelNames = new ArrayList<>();
+                            for (Iterator<TraceChannelComponent> iterator = kernelChannels.iterator(); iterator.hasNext();) {
+                                // Enable all selected channels which are disabled
+                                TraceChannelComponent channel = iterator.next();
+                                channelNames.add(channel.getName());
+                            }
+
+                            changeState(kernelDomain, channelNames, monitor);
+
+                            for (Iterator<TraceChannelComponent> iterator = kernelChannels.iterator(); iterator.hasNext();) {
+                                // Enable all selected channels which are disabled
+                                TraceChannelComponent channel = iterator.next();
+                                channel.setState(getNewState());
+                            }
+                        }
+
+                        TraceDomainComponent ustDomain = param.getUstDomain();
+                        List<TraceChannelComponent> ustChannels = param.getUstChannels();
+                        if (ustDomain != null) {
+                            if (session == null) {
+                                session = (TraceSessionComponent)ustDomain.getParent();
+                            }
+
+                            List<String> channelNames = new ArrayList<>();
+                            for (Iterator<TraceChannelComponent> iterator = ustChannels.iterator(); iterator.hasNext();) {
+                                // Enable all selected channels which are disabled
+                                TraceChannelComponent channel = iterator.next();
+                                channelNames.add(channel.getName());
+                            }
+
+                            changeState(ustDomain, channelNames, monitor);
+
+                            for (Iterator<TraceChannelComponent> iterator = ustChannels.iterator(); iterator.hasNext();) {
+                                // Enable all selected channels which are disabled
+                                TraceChannelComponent channel = iterator.next();
+                                channel.setState(getNewState());
+                            }
+                        }
+                    } catch (ExecutionException e) {
+                        error = e;
+                    }
+
+                    // In all cases notify listeners
+                    if (session != null) {
+                        session.fireComponentChanged(session);
+                    }
+
+                    if (error != null) {
+                        return new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.TraceControl_ChangeChannelStateFailure, error);
+                    }
+
+                    return Status.OK_STATUS;
+                }
+            };
+            job.setUser(true);
+            job.schedule();
+        } finally {
+            fLock.unlock();
+        }
+
+        return null;
+    }
+
+    @Override
+    public boolean isEnabled() {
+
+        // Get workbench page for the Control View
+        IWorkbenchPage page = getWorkbenchPage();
+        if (page == null) {
+            return false;
+        }
+
+        TraceDomainComponent kernelDomain = null;
+        TraceDomainComponent ustDomain = null;
+        List<TraceChannelComponent> kernelChannels = new ArrayList<>();
+        List<TraceChannelComponent> ustChannels = new ArrayList<>();
+
+        // Check if one or more session are selected
+        ISelection selection = page.getSelection(ControlView.ID);
+        if (selection instanceof StructuredSelection) {
+            StructuredSelection structered = ((StructuredSelection) selection);
+            String sessionName = null;
+            for (Iterator<?> iterator = structered.iterator(); iterator.hasNext();) {
+                Object element = iterator.next();
+
+                if (element instanceof TraceChannelComponent) {
+
+                    // Add only TraceChannelComponents that are disabled
+                    TraceChannelComponent channel = (TraceChannelComponent) element;
+                    if (sessionName == null) {
+                        sessionName = String.valueOf(channel.getSessionName());
+                    }
+
+                    // Enable command only for channels of same session
+                    if (!sessionName.equals(channel.getSessionName())) {
+                        kernelChannels.clear();
+                        ustChannels.clear();
+                        break;
+                    }
+
+                    if ((channel.getState() != getNewState())) {
+                        if (channel.isKernel()) {
+                            kernelChannels.add(channel);
+                            if (kernelDomain == null) {
+                                kernelDomain = (TraceDomainComponent) channel.getParent();
+                            }
+                        } else {
+                            ustChannels.add(channel);
+                            if (ustDomain == null) {
+                                ustDomain = (TraceDomainComponent) channel.getParent();
+                            }
+                        }
+                    }
+                }
+            }
+        }
+
+        boolean isEnabled = (!kernelChannels.isEmpty() || !ustChannels.isEmpty());
+        fLock.lock();
+        try {
+            if (isEnabled) {
+                fParam = new Parameter(kernelDomain, ustDomain, kernelChannels, ustChannels);
+            }
+        } finally {
+            fLock.unlock();
+        }
+
+        return isEnabled;
+    }
+
+    /**
+     *  Class containing parameter for the command execution.
+     */
+    protected static class Parameter {
+        /**
+         * Kernel domain component reference.
+         */
+        protected final TraceDomainComponent fKernelDomain;
+        /**
+         * UST domain component reference.
+         */
+        protected final TraceDomainComponent fUstDomain;
+        /**
+         * The list of kernel channel components the command is to be executed on.
+         */
+        protected final List<TraceChannelComponent> fKernelChannels;
+        /**
+         * The list of UST channel components the command is to be executed on.
+         */
+        protected final List<TraceChannelComponent> fUstChannels;
+
+        /**
+         * Constructor
+         * @param kernelDomain - a kernel domain component
+         * @param ustDomain - a UST domain component
+         * @param kernelChannels - list of available kernel channels
+         * @param ustChannels - list of available UST channels
+         */
+        public Parameter(TraceDomainComponent kernelDomain, TraceDomainComponent ustDomain, List<TraceChannelComponent> kernelChannels, List<TraceChannelComponent> ustChannels) {
+            fKernelDomain = kernelDomain;
+            fUstDomain = ustDomain;
+            fKernelChannels = new ArrayList<>();
+            fKernelChannels.addAll(kernelChannels);
+            fUstChannels = new ArrayList<>();
+            fUstChannels.addAll(ustChannels);
+        }
+
+        /**
+         * Copy constructor
+         * @param other a parameter to copy
+         */
+        public Parameter(Parameter other) {
+            this(other.fKernelDomain, other.fUstDomain, other.fKernelChannels, other.fUstChannels);
+        }
+
+        /**
+         * @return the kernel domain component.
+         */
+        public TraceDomainComponent getKernelDomain() {
+            return fKernelDomain;
+        }
+
+        /**
+         * @return the UST domain component.
+         */
+        public TraceDomainComponent getUstDomain() {
+            return fUstDomain;
+        }
+
+        /**
+         * @return the list of kernel channel components.
+         */
+        public List<TraceChannelComponent> getKernelChannels() {
+            return fKernelChannels;
+        }
+
+        /**
+         * @return the list of UST channel components.
+         */
+        public List<TraceChannelComponent> getUstChannels() {
+            return fUstChannels;
+        }
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/ChangeEventStateHandler.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/ChangeEventStateHandler.java
new file mode 100644 (file)
index 0000000..4037640
--- /dev/null
@@ -0,0 +1,261 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
+
+import java.util.ArrayList;
+import java.util.Iterator;
+import java.util.List;
+
+import org.eclipse.core.commands.ExecutionEvent;
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.core.runtime.IStatus;
+import org.eclipse.core.runtime.Status;
+import org.eclipse.core.runtime.jobs.Job;
+import org.eclipse.jface.viewers.ISelection;
+import org.eclipse.jface.viewers.StructuredSelection;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEnablement;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceEventComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
+import org.eclipse.ui.IWorkbenchPage;
+import org.eclipse.ui.IWorkbenchWindow;
+import org.eclipse.ui.PlatformUI;
+
+/**
+ * <p>
+ * Base Command handler implementation to enable or disabling a trace channel.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public abstract class ChangeEventStateHandler extends BaseControlViewHandler {
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+    /**
+     * The command execution parameter.
+     */
+    protected Parameter fParam;
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+    /**
+     * @return the new state to set
+     */
+    protected abstract TraceEnablement getNewState();
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+    /**
+     * Change the state
+     * @param channel - channel of events to be enabled
+     * @param eventNames - list event names
+     * @param monitor - a progress monitor
+     * @throws ExecutionException If the command fails
+     */
+    protected abstract void changeState(TraceChannelComponent channel, List<String> eventNames, IProgressMonitor monitor) throws ExecutionException;
+
+    @Override
+    public Object execute(ExecutionEvent event) throws ExecutionException {
+
+        IWorkbenchWindow window = PlatformUI.getWorkbench().getActiveWorkbenchWindow();
+
+        if (window == null) {
+            return false;
+        }
+
+        fLock.lock();
+        try {
+
+            final Parameter param = new Parameter(fParam);
+
+            Job job = new Job(Messages.TraceControl_ChangeChannelStateJob) {
+                @Override
+                protected IStatus run(IProgressMonitor monitor) {
+                    Exception error = null;
+
+                    TraceSessionComponent session = null;
+
+                    try {
+                        boolean isAll = false;
+                        if (param.getChannel() != null) {
+                            session = param.getChannel().getSession();
+                            List<String> eventNames = new ArrayList<>();
+                            List<TraceEventComponent> events = param.getEvents();
+
+                            for (Iterator<TraceEventComponent> iterator = events.iterator(); iterator.hasNext();) {
+                                // Enable/disable all selected channels which are disabled
+                                TraceEventComponent traceEvent = iterator.next();
+
+                                // Workaround for wildcard handling in lttng-tools
+                                if ("*".equals(traceEvent.getName())) { //$NON-NLS-1$
+                                    isAll = true;
+                                } else {
+                                    eventNames.add(traceEvent.getName());
+                                }
+                            }
+                            if (isAll) {
+                                changeState(param.getChannel(), null, monitor);
+                            }
+
+                            if (!eventNames.isEmpty()) {
+                                changeState(param.getChannel(), eventNames, monitor);
+                            }
+
+                            for (Iterator<TraceEventComponent> iterator = events.iterator(); iterator.hasNext();) {
+                                // Enable all selected channels which are disabled
+                                TraceEventComponent ev = iterator.next();
+                                ev.setState(getNewState());
+                            }
+                        }
+                    } catch (ExecutionException e) {
+                        error = e;
+                    }
+
+                    if (session != null) {
+                        // In all cases notify listeners
+                        session.fireComponentChanged(session);
+                    }
+
+                    if (error != null) {
+                        return new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.TraceControl_ChangeEventStateFailure, error);
+                    }
+
+                    return Status.OK_STATUS;
+                }
+            };
+            job.setUser(true);
+            job.schedule();
+        } finally {
+            fLock.unlock();
+        }
+        return null;
+    }
+
+    @Override
+    public boolean isEnabled() {
+        // Get workbench page for the Control View
+        IWorkbenchPage page = getWorkbenchPage();
+        if (page == null) {
+            return false;
+        }
+
+        // Check if one or more session are selected
+        ISelection selection = page.getSelection(ControlView.ID);
+
+        TraceChannelComponent channel = null;
+        List<TraceEventComponent> events = new ArrayList<>();
+
+        if (selection instanceof StructuredSelection) {
+            StructuredSelection structered = ((StructuredSelection) selection);
+            String sessionName = null;
+            String channelName = null;
+
+            for (Iterator<?> iterator = structered.iterator(); iterator.hasNext();) {
+                Object element = iterator.next();
+
+                if (element instanceof TraceEventComponent) {
+
+                    TraceEventComponent event = (TraceEventComponent) element;
+                    if (sessionName == null) {
+                        sessionName = String.valueOf(event.getSessionName());
+                    }
+
+                    if (channel == null) {
+                        channel = (TraceChannelComponent)event.getParent();
+                    }
+
+                    if (channelName == null) {
+                        channelName = event.getChannelName();
+                    }
+
+                    // Enable command only for events of same session, same channel and domain
+                    if ((!sessionName.equals(event.getSessionName())) ||
+                        (!channelName.equals(event.getChannelName())) ||
+                        (channel.isKernel() != event.isKernel())) {
+                        events.clear();
+                        break;
+                    }
+
+                    if ((event.getState() != getNewState())) {
+                        events.add(event);
+                    }
+                }
+            }
+        }
+        boolean isEnabled = !events.isEmpty();
+
+        fLock.lock();
+        try {
+            fParam = null;
+            if (isEnabled) {
+                fParam = new Parameter(channel, events);
+            }
+        } finally {
+            fLock.unlock();
+        }
+        return isEnabled;
+    }
+
+    /**
+     *  Class containing parameter for the command execution.
+     */
+    protected static class Parameter {
+        /**
+         * Channel component reference.
+         */
+        private final TraceChannelComponent fChannel;
+        /**
+         * The list of kernel channel components the command is to be executed on.
+         */
+        private final List<TraceEventComponent> fEvents = new ArrayList<>();
+
+        /**
+         * Constructor
+         * @param channel - a channel component
+         * @param events - a list of event components
+         */
+        public Parameter(TraceChannelComponent channel, List<TraceEventComponent> events) {
+            fChannel = channel;
+            fEvents.addAll(events);
+        }
+
+        /**
+         * Copy constructor
+         * @param other - a parameter to copy
+         */
+        public Parameter(Parameter other) {
+            this(other.fChannel, other.fEvents);
+        }
+
+        /**
+         * @return the trace channel component.
+         */
+        public TraceChannelComponent getChannel() {
+            return fChannel;
+        }
+
+        /**
+         * @return a list of trace event components.
+         */
+        public List<TraceEventComponent> getEvents() {
+            return fEvents;
+        }
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/ChangeSessionStateHandler.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/ChangeSessionStateHandler.java
new file mode 100644 (file)
index 0000000..52ae259
--- /dev/null
@@ -0,0 +1,157 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
+
+import java.util.ArrayList;
+import java.util.Iterator;
+import java.util.List;
+
+import org.eclipse.core.commands.ExecutionEvent;
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.core.runtime.IStatus;
+import org.eclipse.core.runtime.Status;
+import org.eclipse.core.runtime.jobs.Job;
+import org.eclipse.jface.viewers.ISelection;
+import org.eclipse.jface.viewers.StructuredSelection;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
+import org.eclipse.ui.IWorkbenchPage;
+import org.eclipse.ui.IWorkbenchWindow;
+import org.eclipse.ui.PlatformUI;
+
+/**
+ * <p>
+ * Abstract command handler implementation to start or stop one or more trace sessions.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public abstract class ChangeSessionStateHandler extends BaseControlViewHandler {
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+    /**
+     * The list of session components the command is to be executed on.
+     */
+    protected List<TraceSessionComponent> fSessions = new ArrayList<>();
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    /**
+     * @return new required state.
+     */
+    public abstract TraceSessionState getNewState();
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    /**
+     * Performs the state change on given session.
+     *
+     * @param session
+     *            - a session which state is to be changed
+     * @param monitor
+     *            - a progress monitor
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    public abstract void changeState(TraceSessionComponent session, IProgressMonitor monitor) throws ExecutionException;
+
+    @Override
+    public Object execute(ExecutionEvent event) throws ExecutionException {
+
+        IWorkbenchWindow window = PlatformUI.getWorkbench().getActiveWorkbenchWindow();
+
+        if (window == null) {
+            return false;
+        }
+
+        fLock.lock();
+        try {
+
+            final List<TraceSessionComponent> sessions = new ArrayList<>();
+            sessions.addAll(fSessions);
+
+            Job job = new Job(Messages.TraceControl_ChangeSessionStateJob) {
+                @Override
+                protected IStatus run(IProgressMonitor monitor) {
+                    try {
+                        for (Iterator<TraceSessionComponent> iterator = sessions.iterator(); iterator.hasNext();) {
+
+                            // Start all selected sessions
+                            TraceSessionComponent session = iterator.next();
+                            changeState(session, monitor);
+
+                            // Set Session state
+                            session.setSessionState(getNewState());
+                            session.fireComponentChanged(session);
+                        }
+                    } catch (ExecutionException e) {
+                        return new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.TraceControl_ChangeSessionStateFailure, e);
+                    }
+                    return Status.OK_STATUS;
+                }
+            };
+            job.setUser(true);
+            job.schedule();
+        } finally {
+            fLock.unlock();
+        }
+        return null;
+    }
+
+    @Override
+    public boolean isEnabled() {
+        // Get workbench page for the Control View
+        IWorkbenchPage page = getWorkbenchPage();
+        if (page == null) {
+            return false;
+        }
+
+        List<TraceSessionComponent> sessions = new ArrayList<>(0);
+
+        // Check if one or more session are selected
+        ISelection selection = page.getSelection(ControlView.ID);
+        if (selection instanceof StructuredSelection) {
+            StructuredSelection structered = ((StructuredSelection) selection);
+            for (Iterator<?> iterator = structered.iterator(); iterator.hasNext();) {
+                Object element = iterator.next();
+                if (element instanceof TraceSessionComponent) {
+                    // Add only TraceSessionComponents that are inactive and not destroyed
+                    TraceSessionComponent session = (TraceSessionComponent) element;
+                    if ((session.getSessionState() != getNewState()) && (!session.isDestroyed())) {
+                        sessions.add(session);
+                    }
+                }
+            }
+        }
+        boolean isEnabled = !sessions.isEmpty();
+        fLock.lock();
+        try {
+            fSessions = null;
+            if (isEnabled) {
+                fSessions = sessions;
+            }
+        } finally {
+            fLock.unlock();
+        }
+        return isEnabled;
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/ChannelCommandParameter.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/ChannelCommandParameter.java
new file mode 100644 (file)
index 0000000..655dde3
--- /dev/null
@@ -0,0 +1,66 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
+
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
+
+/**
+ * Class containing parameter for the command execution.
+ *
+ * @author Bernd Hufmann
+ */
+public class ChannelCommandParameter extends CommandParameter {
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+
+    private TraceChannelComponent fChannel;
+
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+
+    /**
+     * Constructor
+     * @param session - a trace session component.
+     * @param channel - a trace channel component
+     */
+    public ChannelCommandParameter(TraceSessionComponent session, TraceChannelComponent channel) {
+        super(session);
+        fChannel = channel;
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    /**
+     * @return the trace channel component
+     */
+    public TraceChannelComponent getChannel() {
+        return fChannel;
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    public ChannelCommandParameter clone() {
+        ChannelCommandParameter clone = (ChannelCommandParameter) super.clone();
+        clone.fChannel = fChannel;
+        return clone;
+    }
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/CommandParameter.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/CommandParameter.java
new file mode 100644 (file)
index 0000000..69c15b9
--- /dev/null
@@ -0,0 +1,69 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
+
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
+
+/**
+ * Class containing parameter for the command execution.
+ *
+ * @author Bernd Hufmann
+ */
+public class CommandParameter implements Cloneable {
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+
+    /**
+     * The trace session component.
+     */
+    private TraceSessionComponent fSession;
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+
+    /**
+     * Constructor
+     * @param session a trace session component.
+     */
+    public CommandParameter(TraceSessionComponent session) {
+        fSession = session;
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    /**
+     * @return the session component.
+     */
+    public TraceSessionComponent getSession() {
+        return fSession;
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    public CommandParameter clone() {
+        CommandParameter clone = null;
+        try {
+            clone = (CommandParameter) super.clone();
+            clone.fSession = fSession;
+        } catch (CloneNotSupportedException e) {
+        }
+        return clone;
+    }
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/ConnectHandler.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/ConnectHandler.java
new file mode 100644 (file)
index 0000000..22fcc66
--- /dev/null
@@ -0,0 +1,53 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
+
+import org.eclipse.core.commands.ExecutionEvent;
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TargetNodeState;
+
+/**
+ * <p>
+ * Command handler implementation to connect to a target host.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class ConnectHandler extends BaseNodeHandler {
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    public Object execute(ExecutionEvent event) throws ExecutionException {
+        fLock.lock();
+        try {
+            fTargetNode.connect();
+        } finally {
+            fLock.unlock();
+        }
+        return null;
+    }
+
+    @Override
+    public boolean isEnabled() {
+        boolean isEnabled = false;
+        fLock.lock();
+        try {
+           isEnabled = (super.isEnabled() && (fTargetNode.getTargetNodeState() == TargetNodeState.DISCONNECTED));
+        } finally {
+            fLock.unlock();
+        }
+        return isEnabled;
+     }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/CreateSessionHandler.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/CreateSessionHandler.java
new file mode 100644 (file)
index 0000000..e76e31b
--- /dev/null
@@ -0,0 +1,118 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
+
+import org.eclipse.core.commands.ExecutionEvent;
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.core.runtime.IStatus;
+import org.eclipse.core.runtime.Status;
+import org.eclipse.core.runtime.jobs.Job;
+import org.eclipse.jface.viewers.ISelection;
+import org.eclipse.jface.viewers.StructuredSelection;
+import org.eclipse.jface.window.Window;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.ICreateSessionDialog;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.TraceControlDialogFactory;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionGroup;
+import org.eclipse.ui.IWorkbenchPage;
+
+/**
+ * <p>
+ * Command handler implementation to create a trace session.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class CreateSessionHandler extends BaseControlViewHandler {
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+
+    /**
+     * The trace session group the command is to be executed on.
+     */
+    private TraceSessionGroup fSessionGroup = null;
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    public Object execute(ExecutionEvent event) throws ExecutionException {
+
+        fLock.lock();
+        try {
+            final TraceSessionGroup sessionGroup = fSessionGroup;
+
+            // Open dialog box for the node name and address
+            final ICreateSessionDialog dialog = TraceControlDialogFactory.getInstance().getCreateSessionDialog();
+            dialog.initialize(sessionGroup);
+
+            if (dialog.open() != Window.OK) {
+                return null;
+            }
+
+            Job job = new Job(Messages.TraceControl_CreateSessionJob) {
+                @Override
+                protected IStatus run(IProgressMonitor monitor) {
+                    try {
+                        sessionGroup.createSession(dialog.getParameters(), monitor);
+                    } catch (ExecutionException e) {
+                        return new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.TraceControl_CreateSessionFailure, e);
+                    }
+                    return Status.OK_STATUS;
+                }
+            };
+            job.setUser(true);
+            job.schedule();
+        } finally {
+            fLock.unlock();
+        }
+        return null;
+    }
+
+    @Override
+    public boolean isEnabled() {
+
+        // Get workbench page for the Control View
+        IWorkbenchPage page = getWorkbenchPage();
+        if (page == null) {
+            return false;
+        }
+
+        TraceSessionGroup sessionGroup = null;
+
+        // Check if the session group project is selected
+        ISelection selection = page.getSelection(ControlView.ID);
+        if (selection instanceof StructuredSelection) {
+            Object element = ((StructuredSelection) selection).getFirstElement();
+            sessionGroup = (element instanceof TraceSessionGroup) ? (TraceSessionGroup) element : null;
+        }
+
+        boolean isEnabled = sessionGroup != null;
+        fLock.lock();
+        try {
+            fSessionGroup = null;
+            if(isEnabled) {
+                fSessionGroup = sessionGroup;
+            }
+        } finally {
+            fLock.unlock();
+        }
+        return isEnabled;
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/DeleteHandler.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/DeleteHandler.java
new file mode 100644 (file)
index 0000000..3687c50
--- /dev/null
@@ -0,0 +1,56 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
+
+import org.eclipse.core.commands.ExecutionEvent;
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TargetNodeState;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
+
+/**
+ * <p>
+ * Command handler implementation to delete a target host.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class DeleteHandler extends BaseNodeHandler {
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    public Object execute(ExecutionEvent event) throws ExecutionException {
+        fLock.lock();
+        try {
+            ITraceControlComponent root = fTargetNode.getParent();
+            fTargetNode.removeAllChildren();
+            root.removeChild(fTargetNode);
+        } finally {
+            fLock.unlock();
+        }
+        return null;
+    }
+
+    @Override
+    public boolean isEnabled() {
+        boolean isEnabled = false;
+        fLock.lock();
+        try {
+           isEnabled = (super.isEnabled() && (fTargetNode.getTargetNodeState() == TargetNodeState.DISCONNECTED));
+        } finally {
+            fLock.unlock();
+        }
+        return isEnabled;
+     }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/DestroySessionHandler.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/DestroySessionHandler.java
new file mode 100644 (file)
index 0000000..b9c040a
--- /dev/null
@@ -0,0 +1,129 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
+
+import java.util.ArrayList;
+import java.util.Iterator;
+import java.util.List;
+
+import org.eclipse.core.commands.ExecutionEvent;
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.core.runtime.IStatus;
+import org.eclipse.core.runtime.Status;
+import org.eclipse.core.runtime.jobs.Job;
+import org.eclipse.jface.viewers.ISelection;
+import org.eclipse.jface.viewers.StructuredSelection;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.IConfirmDialog;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.TraceControlDialogFactory;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionGroup;
+import org.eclipse.ui.IWorkbenchPage;
+import org.eclipse.ui.IWorkbenchWindow;
+import org.eclipse.ui.PlatformUI;
+
+/**
+ * <p>
+ * Command handler implementation to destroy one or more trace sessions.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class DestroySessionHandler extends BaseControlViewHandler {
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+    /**
+     * The list of session components the command is to be executed on.
+     */
+    private final List<TraceSessionComponent> fSessions = new ArrayList<>();
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    public Object execute(ExecutionEvent event) throws ExecutionException {
+
+        IWorkbenchWindow window = PlatformUI.getWorkbench().getActiveWorkbenchWindow();
+
+        if (window == null) {
+            return false;
+        }
+        // Get user confirmation
+        IConfirmDialog dialog = TraceControlDialogFactory.getInstance().getConfirmDialog();
+        if (!dialog.openConfirm(window.getShell(),
+                Messages.TraceControl_DestroyConfirmationTitle,
+                Messages.TraceControl_DestroyConfirmationMessage)) {
+
+            return null;
+        }
+
+        Job job = new Job(Messages.TraceControl_DestroySessionJob) {
+            @Override
+            protected IStatus run(IProgressMonitor monitor) {
+                try {
+                    // Make a copy of the list of sessions to avoid ConcurrentModificationException when iterating
+                    // over fSessions, since fSessions is modified in another thread triggered by the tree viewer refresh
+                    // after removing a session.
+                    TraceSessionComponent[] sessions = fSessions.toArray(new TraceSessionComponent[fSessions.size()]);
+
+                    for (int i = 0; i < sessions.length; i++) {
+                        // Destroy all selected sessions
+                        TraceSessionComponent session = sessions[i];
+                        TraceSessionGroup sessionGroup = (TraceSessionGroup)session.getParent();
+                        sessionGroup.destroySession(session, monitor);
+                    }
+                } catch (ExecutionException e) {
+                    return new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.TraceControl_DestroySessionFailure, e);
+                }
+                return Status.OK_STATUS;
+            }
+        };
+        job.setUser(true);
+        job.schedule();
+
+        return null;
+    }
+
+    @Override
+    public boolean isEnabled() {
+        // Get workbench page for the Control View
+        IWorkbenchPage page = getWorkbenchPage();
+        if (page == null) {
+            return false;
+        }
+        fSessions.clear();
+
+        // Check if one or more session are selected
+        ISelection selection = page.getSelection(ControlView.ID);
+        if (selection instanceof StructuredSelection) {
+            StructuredSelection structered = ((StructuredSelection) selection);
+            for (Iterator<?> iterator = structered.iterator(); iterator.hasNext();) {
+                Object element = iterator.next();
+                if (element instanceof TraceSessionComponent) {
+                    // Add only TraceSessionComponents that are inactive and not destroyed
+                    TraceSessionComponent session = (TraceSessionComponent) element;
+                    if ((session.getSessionState() == TraceSessionState.INACTIVE) && (!session.isDestroyed())) {
+                        fSessions.add((TraceSessionComponent)element);
+                    }
+                }
+            }
+        }
+        return !fSessions.isEmpty();
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/DisableChannelHandler.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/DisableChannelHandler.java
new file mode 100644 (file)
index 0000000..c7a821b
--- /dev/null
@@ -0,0 +1,47 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
+
+import java.util.List;
+
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEnablement;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent;
+
+/**
+ * <p>
+ * Command handler implementation to disable one or more trace channels per session and domain.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class DisableChannelHandler extends ChangeChannelStateHandler {
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    @Override
+    protected TraceEnablement getNewState() {
+        return TraceEnablement.DISABLED;
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    protected void changeState(TraceDomainComponent domain, List<String> channelNames, IProgressMonitor monitor) throws ExecutionException {
+        domain.disableChannels(channelNames, monitor);
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/DisableEventHandler.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/DisableEventHandler.java
new file mode 100644 (file)
index 0000000..8071eba
--- /dev/null
@@ -0,0 +1,47 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
+
+import java.util.List;
+
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEnablement;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent;
+
+/**
+ * <p>
+ * Command handler implementation to disable one or more events session, domain and channel.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class DisableEventHandler extends ChangeEventStateHandler {
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    @Override
+    protected TraceEnablement getNewState() {
+        return TraceEnablement.DISABLED;
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    protected void changeState(TraceChannelComponent channel, List<String> eventNames, IProgressMonitor monitor) throws ExecutionException{
+        channel.disableEvent(eventNames, monitor);
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/DisconnectHandler.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/DisconnectHandler.java
new file mode 100644 (file)
index 0000000..b3d6d66
--- /dev/null
@@ -0,0 +1,53 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
+
+import org.eclipse.core.commands.ExecutionEvent;
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TargetNodeState;
+
+/**
+ * <p>
+ * Command handler implementation to disconnect from a target host.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class DisconnectHandler extends BaseNodeHandler {
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    public Object execute(ExecutionEvent event) throws ExecutionException {
+        fLock.lock();
+        try {
+            fTargetNode.disconnect();
+        } finally {
+            fLock.unlock();
+        }
+        return null;
+    }
+
+    @Override
+    public boolean isEnabled() {
+        boolean isEnabled = false;
+        fLock.lock();
+        try {
+           isEnabled = super.isEnabled() && (fTargetNode.getTargetNodeState() == TargetNodeState.CONNECTED);
+        } finally {
+            fLock.unlock();
+        }
+        return isEnabled;
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/DomainCommandParameter.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/DomainCommandParameter.java
new file mode 100644 (file)
index 0000000..270006b
--- /dev/null
@@ -0,0 +1,66 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
+
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
+
+/**
+ * Class containing parameter for the command execution.
+ *
+ *  @author Bernd Hufmann
+ */
+public class DomainCommandParameter extends CommandParameter {
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+
+    private TraceDomainComponent fDomain;
+
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+
+    /**
+     * Constructor
+     * @param session - a trace session component.
+     * @param domain - a trace domain component
+     */
+    public DomainCommandParameter(TraceSessionComponent session, TraceDomainComponent domain) {
+        super(session);
+        fDomain = domain;
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    /**
+     * @return the trace domain component
+     */
+    public TraceDomainComponent getDomain() {
+        return fDomain;
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    public DomainCommandParameter clone() {
+        DomainCommandParameter clone = (DomainCommandParameter) super.clone();
+        clone.fDomain = fDomain;
+        return clone;
+    }
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/EnableChannelHandler.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/EnableChannelHandler.java
new file mode 100644 (file)
index 0000000..97d050d
--- /dev/null
@@ -0,0 +1,47 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
+
+import java.util.List;
+
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEnablement;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent;
+
+/**
+ * <p>
+ * Command handler implementation to enable one or more trace channels per session and domain.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class EnableChannelHandler extends ChangeChannelStateHandler {
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    @Override
+    protected TraceEnablement getNewState() {
+        return TraceEnablement.ENABLED;
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    protected void changeState(TraceDomainComponent domain, List<String> channelNames, IProgressMonitor monitor) throws ExecutionException {
+        domain.enableChannels(channelNames, null, monitor);
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/EnableChannelOnDomainHandler.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/EnableChannelOnDomainHandler.java
new file mode 100644 (file)
index 0000000..4d65480
--- /dev/null
@@ -0,0 +1,105 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
+
+import java.util.Iterator;
+import java.util.List;
+
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.jface.viewers.ISelection;
+import org.eclipse.jface.viewers.StructuredSelection;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IChannelInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
+import org.eclipse.ui.IWorkbenchPage;
+
+/**
+ * <p>
+ * Command handler implementation to enable a trace channel for known domain.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class EnableChannelOnDomainHandler extends BaseEnableChannelHandler {
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    public void enableChannel(CommandParameter param, List<String> channelNames, IChannelInfo info, boolean isKernel, IProgressMonitor monitor) throws ExecutionException {
+        if (param instanceof DomainCommandParameter) {
+            ((DomainCommandParameter)param).getDomain().enableChannels(channelNames, info, monitor);
+        }
+    }
+
+    @Override
+    public TraceDomainComponent getDomain(CommandParameter param) {
+        if (param instanceof DomainCommandParameter) {
+            return ((DomainCommandParameter)param).getDomain();
+        }
+        return null;
+    }
+
+    @Override
+    public boolean isEnabled() {
+
+        // Get workbench page for the Control View
+        IWorkbenchPage page = getWorkbenchPage();
+        if (page == null) {
+            return false;
+        }
+
+        TraceDomainComponent domain = null;
+        TraceSessionComponent session = null;
+
+        // Check if one domain is selected
+        ISelection selection = page.getSelection(ControlView.ID);
+        if (selection instanceof StructuredSelection) {
+            StructuredSelection structered = ((StructuredSelection) selection);
+            for (Iterator<?> iterator = structered.iterator(); iterator.hasNext();) {
+                Object element = iterator.next();
+                if (element instanceof TraceDomainComponent) {
+                    TraceDomainComponent tmpDomain = (TraceDomainComponent) element;
+                    session = (TraceSessionComponent) tmpDomain.getParent();
+
+                    // Add only TraceDomainComponent whose TraceSessionComponent parent is inactive and not destroyed
+                    if ((session.getSessionState() == TraceSessionState.INACTIVE) && (!session.isDestroyed())) {
+                        domain = tmpDomain;
+                    }
+                }
+            }
+        }
+
+        boolean isEnabled = domain != null;
+
+        fLock.lock();
+        try {
+            fParam = null;
+            if (isEnabled) {
+                fParam = new DomainCommandParameter(session, domain);
+            }
+        } finally {
+            fLock.unlock();
+        }
+
+        return isEnabled;
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/EnableChannelOnSessionHandler.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/EnableChannelOnSessionHandler.java
new file mode 100644 (file)
index 0000000..8620945
--- /dev/null
@@ -0,0 +1,94 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
+
+import java.util.Iterator;
+import java.util.List;
+
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.jface.viewers.ISelection;
+import org.eclipse.jface.viewers.StructuredSelection;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IChannelInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
+import org.eclipse.ui.IWorkbenchPage;
+
+/**
+ * <p>
+ * Command handler implementation to enable a trace channel for unknown domain
+ * (on session level).
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class EnableChannelOnSessionHandler extends BaseEnableChannelHandler {
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+
+    @Override
+    public void enableChannel(CommandParameter param, List<String> channelNames, IChannelInfo info, boolean isKernel, IProgressMonitor monitor) throws ExecutionException {
+        param.getSession().enableChannels(channelNames, info, isKernel, monitor);
+    }
+
+    @Override
+    public TraceDomainComponent getDomain(CommandParameter param) {
+        return null;
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    public boolean isEnabled() {
+        // Get workbench page for the Control View
+        IWorkbenchPage page = getWorkbenchPage();
+        if (page == null) {
+            return false;
+        }
+
+        TraceSessionComponent session = null;
+        // Check if one session is selected
+        ISelection selection = page.getSelection(ControlView.ID);
+        if (selection instanceof StructuredSelection) {
+            StructuredSelection structered = ((StructuredSelection) selection);
+            for (Iterator<?> iterator = structered.iterator(); iterator.hasNext();) {
+                Object element = iterator.next();
+                if (element instanceof TraceSessionComponent) {
+                    // Add only TraceSessionComponents that are inactive and not destroyed
+                    TraceSessionComponent tmpSession = (TraceSessionComponent) element;
+                    if ((tmpSession.getSessionState() == TraceSessionState.INACTIVE) && (!tmpSession.isDestroyed())) {
+                        session = tmpSession;
+                    }
+                }
+            }
+        }
+        boolean isEnabled = session != null;
+
+        fLock.lock();
+        try {
+            fParam = null;
+            if (isEnabled) {
+                fParam = new CommandParameter(session);
+            }
+        } finally {
+            fLock.unlock();
+        }
+
+        return isEnabled;
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/EnableEventHandler.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/EnableEventHandler.java
new file mode 100644 (file)
index 0000000..6d2cda0
--- /dev/null
@@ -0,0 +1,47 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
+
+import java.util.List;
+
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEnablement;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent;
+
+/**
+ * <p>
+ * Command handler implementation to enable one or more events session, domain and channel.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class EnableEventHandler extends ChangeEventStateHandler {
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    @Override
+    protected TraceEnablement getNewState() {
+        return TraceEnablement.ENABLED;
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    protected void changeState(TraceChannelComponent channel, List<String> eventNames, IProgressMonitor monitor) throws ExecutionException{
+        channel.enableEvents(eventNames, monitor);
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/EnableEventOnChannelHandler.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/EnableEventOnChannelHandler.java
new file mode 100644 (file)
index 0000000..9da2dc0
--- /dev/null
@@ -0,0 +1,122 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
+
+import java.util.Iterator;
+import java.util.List;
+
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.jface.viewers.ISelection;
+import org.eclipse.jface.viewers.StructuredSelection;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.LogLevelType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
+import org.eclipse.ui.IWorkbenchPage;
+
+/**
+ * <p>
+ * Command handler implementation to enable events for a known channel.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class EnableEventOnChannelHandler extends BaseEnableEventHandler {
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    public void enableEvents(CommandParameter param, List<String> eventNames, boolean isKernel, String filterExression, IProgressMonitor monitor) throws ExecutionException {
+        if (param instanceof ChannelCommandParameter) {
+            ((ChannelCommandParameter)param).getChannel().enableEvents(eventNames, filterExression, monitor);
+        }
+    }
+
+    @Override
+    public void enableSyscalls(CommandParameter param, IProgressMonitor monitor) throws ExecutionException {
+        if (param instanceof ChannelCommandParameter) {
+            ((ChannelCommandParameter)param).getChannel().enableSyscalls(monitor);
+        }
+    }
+
+    @Override
+    public void enableProbe(CommandParameter param, String eventName, boolean isFunction, String probe, IProgressMonitor monitor) throws ExecutionException {
+        if (param instanceof ChannelCommandParameter) {
+            ((ChannelCommandParameter)param).getChannel().enableProbe(eventName, isFunction, probe, monitor);
+        }
+    }
+
+    @Override
+    public void enableLogLevel(CommandParameter param, String eventName, LogLevelType logLevelType, TraceLogLevel level, String filterExression, IProgressMonitor monitor) throws ExecutionException {
+        if (param instanceof ChannelCommandParameter) {
+            ((ChannelCommandParameter)param).getChannel().enableLogLevel(eventName, logLevelType, level, filterExression, monitor);
+        }
+    }
+
+    @Override
+    public TraceDomainComponent getDomain(CommandParameter param) {
+        if (param instanceof ChannelCommandParameter) {
+            return (TraceDomainComponent) ((ChannelCommandParameter)param).getChannel().getParent();
+        }
+        return null;
+    }
+
+    @Override
+    public boolean isEnabled() {
+        // Get workbench page for the Control View
+        IWorkbenchPage page = getWorkbenchPage();
+        if (page == null) {
+            return false;
+        }
+
+        TraceChannelComponent channel = null;
+        TraceSessionComponent session = null;
+        ISelection selection = page.getSelection(ControlView.ID);
+        if (selection instanceof StructuredSelection) {
+            StructuredSelection structered = ((StructuredSelection) selection);
+            for (Iterator<?> iterator = structered.iterator(); iterator.hasNext();) {
+                Object element = iterator.next();
+                if (element instanceof TraceChannelComponent) {
+                    // Add only if corresponding TraceSessionComponents is inactive and not destroyed
+                    TraceChannelComponent tmpChannel = (TraceChannelComponent) element;
+                    session = tmpChannel.getSession();
+                    if(!session.isDestroyed()) {
+                        channel = tmpChannel;
+                    }
+                }
+            }
+        }
+
+        boolean isEnabled = (channel != null);
+        fLock.lock();
+        try {
+            fParam = null;
+            if(isEnabled) {
+                fParam = new ChannelCommandParameter(session, channel);
+            }
+        } finally {
+            fLock.unlock();
+        }
+        return isEnabled;
+    }
+}
+
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/EnableEventOnDomainHandler.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/EnableEventOnDomainHandler.java
new file mode 100644 (file)
index 0000000..b766ebb
--- /dev/null
@@ -0,0 +1,118 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
+
+import java.util.Iterator;
+import java.util.List;
+
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.jface.viewers.ISelection;
+import org.eclipse.jface.viewers.StructuredSelection;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.LogLevelType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
+import org.eclipse.ui.IWorkbenchPage;
+
+/**
+ * <p>
+ * Command handler implementation to enable events for a known domain and default channel 'channel0'
+ * (which will be created if doesn't exist).
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class EnableEventOnDomainHandler extends BaseEnableEventHandler {
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    public void enableEvents(CommandParameter param, List<String> eventNames, boolean isKernel, String filterExression, IProgressMonitor monitor) throws ExecutionException {
+        if (param instanceof DomainCommandParameter) {
+            ((DomainCommandParameter)param).getDomain().enableEvents(eventNames, monitor);
+        }
+    }
+
+    @Override
+    public void enableSyscalls(CommandParameter param, IProgressMonitor monitor) throws ExecutionException {
+        if (param instanceof DomainCommandParameter) {
+            ((DomainCommandParameter)param).getDomain().enableSyscalls(monitor);
+        }
+    }
+
+    @Override
+    public void enableProbe(CommandParameter param, String eventName, boolean isFunction, String probe, IProgressMonitor monitor) throws ExecutionException {
+        if (param instanceof DomainCommandParameter) {
+            ((DomainCommandParameter)param).getDomain().enableProbe(eventName, isFunction, probe, monitor);
+        }
+    }
+
+    @Override
+    public void enableLogLevel(CommandParameter param, String eventName, LogLevelType logLevelType, TraceLogLevel level, String filterExression, IProgressMonitor monitor) throws ExecutionException {
+        if (param instanceof DomainCommandParameter) {
+            ((DomainCommandParameter)param).getDomain().enableLogLevel(eventName, logLevelType, level, filterExression, monitor);
+        }
+    }
+
+    @Override
+    public TraceDomainComponent getDomain(CommandParameter param) {
+        if (param instanceof DomainCommandParameter) {
+            return ((DomainCommandParameter)param).getDomain();
+        }
+        return null;
+    }
+
+    @Override
+    public boolean isEnabled() {
+        // Get workbench page for the Control View
+        IWorkbenchPage page = getWorkbenchPage();
+        if (page == null) {
+            return false;
+        }
+
+        TraceDomainComponent domain = null;
+        TraceSessionComponent session = null;
+        ISelection selection = page.getSelection(ControlView.ID);
+        if (selection instanceof StructuredSelection) {
+            StructuredSelection structered = ((StructuredSelection) selection);
+            for (Iterator<?> iterator = structered.iterator(); iterator.hasNext();) {
+                Object element = iterator.next();
+                if (element instanceof TraceDomainComponent) {
+                    // Add only if corresponding TraceSessionComponents is inactive and not destroyed
+                    TraceDomainComponent tmpDomain = (TraceDomainComponent) element;
+                    session = tmpDomain.getSession();
+                    if(session.getSessionState() == TraceSessionState.INACTIVE && !session.isDestroyed()) {
+                        domain = tmpDomain;
+                    }
+                }
+            }
+        }
+
+        boolean isEnabled = (domain != null);
+        fLock.lock();
+        try {
+            fParam = null;
+            if(isEnabled) {
+                fParam = new DomainCommandParameter(session, domain);
+            }
+        } finally {
+            fLock.unlock();
+        }
+        return isEnabled;
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/EnableEventOnSessionHandler.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/EnableEventOnSessionHandler.java
new file mode 100644 (file)
index 0000000..c28578c
--- /dev/null
@@ -0,0 +1,109 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
+
+import java.util.Iterator;
+import java.util.List;
+
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.jface.viewers.ISelection;
+import org.eclipse.jface.viewers.StructuredSelection;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.LogLevelType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
+import org.eclipse.ui.IWorkbenchPage;
+
+/**
+ * <p>
+ * Command handler implementation to enable events for a known session and default channel 'channel0'
+ * (which will be created if doesn't exist).
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class EnableEventOnSessionHandler extends BaseEnableEventHandler {
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+
+    //-------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    public void enableEvents(CommandParameter param, List<String> eventNames, boolean isKernel, String filterExpression, IProgressMonitor monitor) throws ExecutionException {
+        param.getSession().enableEvents(eventNames, isKernel, filterExpression, monitor);
+    }
+
+    @Override
+    public void enableSyscalls(CommandParameter param, IProgressMonitor monitor) throws ExecutionException {
+        param.getSession().enableSyscalls(monitor);
+    }
+
+    @Override
+    public void enableProbe(CommandParameter param, String eventName, boolean isFunction, String probe, IProgressMonitor monitor) throws ExecutionException {
+        param.getSession().enableProbe(eventName, isFunction, probe, monitor);
+    }
+
+    @Override
+    public void enableLogLevel(CommandParameter param, String eventName, LogLevelType logLevelType, TraceLogLevel level, String filterExpression, IProgressMonitor monitor) throws ExecutionException {
+        param.getSession().enableLogLevel(eventName, logLevelType, level, filterExpression, monitor);
+    }
+
+    @Override
+    public TraceDomainComponent getDomain(CommandParameter param) {
+        return null;
+    }
+
+    @Override
+    public boolean isEnabled() {
+        // Get workbench page for the Control View
+        IWorkbenchPage page = getWorkbenchPage();
+        if (page == null) {
+            return false;
+        }
+
+        TraceSessionComponent session = null;
+        // Check if one session is selected
+        ISelection selection = page.getSelection(ControlView.ID);
+        if (selection instanceof StructuredSelection) {
+            StructuredSelection structered = ((StructuredSelection) selection);
+            for (Iterator<?> iterator = structered.iterator(); iterator.hasNext();) {
+                Object element = iterator.next();
+                if (element instanceof TraceSessionComponent) {
+                    // Add only if corresponding TraceSessionComponents is inactive and not destroyed
+                    TraceSessionComponent tmpSession = (TraceSessionComponent) element;
+                    if(tmpSession.getSessionState() == TraceSessionState.INACTIVE && !tmpSession.isDestroyed()) {
+                        session = tmpSession;
+                    }
+                }
+            }
+        }
+        boolean isEnabled = (session != null);
+        fLock.lock();
+        try {
+            fParam = null;
+            if(isEnabled) {
+                fParam = new CommandParameter(session);
+            }
+        } finally {
+            fLock.unlock();
+        }
+        return isEnabled;
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/EventCommandParameter.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/EventCommandParameter.java
new file mode 100644 (file)
index 0000000..df00f23
--- /dev/null
@@ -0,0 +1,65 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
+
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceEventComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
+
+/**
+ * Class containing parameter for a command execution.
+ *
+ * @author Bernd Hufmann
+ */
+public class EventCommandParameter extends CommandParameter {
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+
+    private TraceEventComponent fEvent;
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+
+    /**
+     * Constructor
+     * @param session - a trace session component.
+     * @param event - a trace event component
+     */
+    public EventCommandParameter(TraceSessionComponent session, TraceEventComponent event) {
+        super(session);
+        fEvent = event;
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    /**
+     * @return the trace event component
+     */
+    public TraceEventComponent getEvent() {
+        return fEvent;
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    public EventCommandParameter clone() {
+        EventCommandParameter clone = (EventCommandParameter) super.clone();
+        clone.fEvent = fEvent;
+        return clone;
+    }
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/ExecuteCommandScriptHandler.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/ExecuteCommandScriptHandler.java
new file mode 100644 (file)
index 0000000..03de199
--- /dev/null
@@ -0,0 +1,116 @@
+/**********************************************************************
+ * Copyright (c) 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
+
+import org.eclipse.core.commands.ExecutionEvent;
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.core.runtime.IStatus;
+import org.eclipse.core.runtime.Status;
+import org.eclipse.core.runtime.jobs.Job;
+import org.eclipse.jface.viewers.ISelection;
+import org.eclipse.jface.viewers.StructuredSelection;
+import org.eclipse.jface.window.Window;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.ISelectCommandScriptDialog;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.TraceControlDialogFactory;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionGroup;
+import org.eclipse.ui.IWorkbenchPage;
+
+/**
+ * <p>
+ * Command handler implementation to execute commands of a command script.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class ExecuteCommandScriptHandler extends BaseControlViewHandler {
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+
+    /**
+     * The trace session group the command is to be executed on.
+     */
+    private TraceSessionGroup fSessionGroup = null;
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    public Object execute(ExecutionEvent event) throws ExecutionException {
+
+        fLock.lock();
+        try {
+            final TraceSessionGroup sessionGroup = fSessionGroup;
+
+            // Open dialog box for the node name and address
+            final ISelectCommandScriptDialog dialog = TraceControlDialogFactory.getInstance().getCommandScriptDialog();
+
+            if (dialog.open() != Window.OK) {
+                return null;
+            }
+
+            Job job = new Job(Messages.TraceControl_ExecuteScriptJob) {
+                @Override
+                protected IStatus run(IProgressMonitor monitor) {
+                    try {
+                        sessionGroup.executeCommands(monitor, dialog.getCommands());
+                    } catch (ExecutionException e) {
+                        return new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.TraceControl_CreateSessionFailure, e);
+                    }
+                    return Status.OK_STATUS;
+                }
+            };
+            job.setUser(true);
+            job.schedule();
+        } finally {
+            fLock.unlock();
+        }
+        return null;
+    }
+
+    @Override
+    public boolean isEnabled() {
+
+        // Get workbench page for the Control View
+        IWorkbenchPage page = getWorkbenchPage();
+        if (page == null) {
+            return false;
+        }
+
+        TraceSessionGroup sessionGroup = null;
+
+        // Check if the session group project is selected
+        ISelection selection = page.getSelection(ControlView.ID);
+        if (selection instanceof StructuredSelection) {
+            Object element = ((StructuredSelection) selection).getFirstElement();
+            sessionGroup = (element instanceof TraceSessionGroup) ? (TraceSessionGroup) element : null;
+        }
+
+        boolean isEnabled = sessionGroup != null;
+        fLock.lock();
+        try {
+            fSessionGroup = null;
+            if(isEnabled) {
+                fSessionGroup = sessionGroup;
+            }
+        } finally {
+            fLock.unlock();
+        }
+        return isEnabled;
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/ImportHandler.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/ImportHandler.java
new file mode 100644 (file)
index 0000000..2673c43
--- /dev/null
@@ -0,0 +1,410 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Bernd Hufmann - Updated for support of streamed traces
+ *   Patrick Tasse - Add support for source location
+ *   Markus Schorn - Bug 448058: Use org.eclipse.remote in favor of RSE
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
+
+import java.io.FileOutputStream;
+import java.io.IOException;
+import java.io.InputStream;
+import java.io.OutputStream;
+import java.net.URI;
+import java.util.Iterator;
+import java.util.List;
+
+import org.eclipse.core.commands.ExecutionEvent;
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.core.filesystem.EFS;
+import org.eclipse.core.filesystem.IFileInfo;
+import org.eclipse.core.filesystem.IFileStore;
+import org.eclipse.core.resources.IFolder;
+import org.eclipse.core.resources.IProject;
+import org.eclipse.core.resources.IResource;
+import org.eclipse.core.resources.ResourcesPlugin;
+import org.eclipse.core.runtime.CoreException;
+import org.eclipse.core.runtime.IPath;
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.core.runtime.IStatus;
+import org.eclipse.core.runtime.MultiStatus;
+import org.eclipse.core.runtime.NullProgressMonitor;
+import org.eclipse.core.runtime.Path;
+import org.eclipse.core.runtime.Status;
+import org.eclipse.core.runtime.SubMonitor;
+import org.eclipse.core.runtime.URIUtil;
+import org.eclipse.core.runtime.jobs.Job;
+import org.eclipse.jface.dialogs.MessageDialogWithToggle;
+import org.eclipse.jface.preference.IPreferenceStore;
+import org.eclipse.jface.viewers.ISelection;
+import org.eclipse.jface.viewers.StructuredSelection;
+import org.eclipse.jface.window.Window;
+import org.eclipse.jface.wizard.WizardDialog;
+import org.eclipse.swt.widgets.Display;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.relayd.LttngRelaydConnectionInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.relayd.LttngRelaydConnectionManager;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.relayd.LttngRelaydConsumer;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.IImportDialog;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.ImportFileInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.TraceControlDialogFactory;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
+import org.eclipse.tracecompass.internal.tmf.ui.project.wizards.importtrace.ImportTraceWizard;
+import org.eclipse.tracecompass.tmf.core.TmfCommonConstants;
+import org.eclipse.tracecompass.tmf.core.project.model.TmfTraceImportException;
+import org.eclipse.tracecompass.tmf.core.project.model.TraceTypeHelper;
+import org.eclipse.tracecompass.tmf.ctf.core.CtfConstants;
+import org.eclipse.tracecompass.tmf.ui.project.model.TmfOpenTraceHelper;
+import org.eclipse.tracecompass.tmf.ui.project.model.TmfProjectElement;
+import org.eclipse.tracecompass.tmf.ui.project.model.TmfProjectRegistry;
+import org.eclipse.tracecompass.tmf.ui.project.model.TmfTraceElement;
+import org.eclipse.tracecompass.tmf.ui.project.model.TmfTraceFolder;
+import org.eclipse.tracecompass.tmf.ui.project.model.TmfTraceTypeUIUtils;
+import org.eclipse.tracecompass.tmf.ui.project.model.TmfTracesFolder;
+import org.eclipse.tracecompass.tmf.ui.project.model.TraceUtils;
+import org.eclipse.ui.IWorkbenchPage;
+import org.eclipse.ui.IWorkbenchWindow;
+import org.eclipse.ui.PlatformUI;
+
+/**
+ * <p>
+ * Command handler implementation to import traces from a (remote) session to a
+ * tracing project.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class ImportHandler extends BaseControlViewHandler {
+
+    private static final int BUFFER_IN_KB = 16;
+
+    private static final int BYTES_PER_KB = 1024;
+
+    // ------------------------------------------------------------------------
+    // Constants
+    // ------------------------------------------------------------------------
+    /** Name of default project to import traces to */
+    public static final String DEFAULT_REMOTE_PROJECT_NAME = "Remote"; //$NON-NLS-1$
+
+    /** The preference key to remeber whether or not the user wants the notification shown next time **/
+    private static final String NOTIFY_IMPORT_STREAMED_PREF_KEY = "NOTIFY_IMPORT_STREAMED"; //$NON-NLS-1$
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+
+    /**
+     * The command parameter
+     */
+    protected CommandParameter fParam;
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    public Object execute(ExecutionEvent event) throws ExecutionException {
+
+        IWorkbenchWindow window = PlatformUI.getWorkbench().getActiveWorkbenchWindow();
+
+        if (window == null) {
+            return false;
+        }
+
+        fLock.lock();
+        try {
+            final CommandParameter param = fParam.clone();
+
+            // create default project
+            IProject project = TmfProjectRegistry.createProject(DEFAULT_REMOTE_PROJECT_NAME, null, null);
+
+            if (param.getSession().isLiveTrace()) {
+                importLiveTrace(new LttngRelaydConnectionInfo(param.getSession().getLiveUrl(), param.getSession().getLivePort(), param.getSession().getName()), project);
+                return null;
+            } else if (param.getSession().isStreamedTrace()) {
+
+                IPreferenceStore store = Activator.getDefault().getPreferenceStore();
+                String notify = store.getString(NOTIFY_IMPORT_STREAMED_PREF_KEY);
+                if (!MessageDialogWithToggle.ALWAYS.equals(notify)) {
+                    MessageDialogWithToggle.openInformation(window.getShell(), null, Messages.TraceControl_ImportDialogStreamedTraceNotification, Messages.TraceControl_ImportDialogStreamedTraceNotificationToggle, false, store, NOTIFY_IMPORT_STREAMED_PREF_KEY);
+                }
+
+                // Streamed trace
+                TmfProjectElement projectElement = TmfProjectRegistry.getProject(project, true);
+                TmfTraceFolder traceFolder = projectElement.getTracesFolder();
+
+                ImportTraceWizard wizard = new ImportTraceWizard();
+                wizard.init(PlatformUI.getWorkbench(), new StructuredSelection(traceFolder));
+                WizardDialog dialog = new WizardDialog(window.getShell(), wizard);
+                dialog.open();
+                return null;
+            }
+
+            // Remote trace
+            final IImportDialog dialog = TraceControlDialogFactory.getInstance().getImportDialog();
+            dialog.setSession(param.getSession());
+            dialog.setDefaultProject(DEFAULT_REMOTE_PROJECT_NAME);
+
+            if (dialog.open() != Window.OK) {
+                return null;
+            }
+
+            Job job = new Job(Messages.TraceControl_ImportJob) {
+                @Override
+                protected IStatus run(IProgressMonitor monitor) {
+
+                    MultiStatus status = new MultiStatus(Activator.PLUGIN_ID, IStatus.OK, Messages.TraceControl_ImportFailure, null);
+                    List<ImportFileInfo> traces = dialog.getTracePathes();
+                    IProject selectedProject = dialog.getProject();
+                    for (Iterator<ImportFileInfo> iterator = traces.iterator(); iterator.hasNext();) {
+                        try {
+
+                            if (monitor.isCanceled()) {
+                                status.add(Status.CANCEL_STATUS);
+                                break;
+                            }
+
+                            ImportFileInfo remoteFile = iterator.next();
+
+                            downloadTrace(remoteFile, selectedProject, monitor);
+
+                            // Set trace type
+                            IFolder traceFolder = remoteFile.getDestinationFolder();
+
+                            IResource file = traceFolder.findMember(remoteFile.getLocalTraceName());
+
+                            if (file != null) {
+                                TraceTypeHelper helper = null;
+
+                                try {
+                                    helper = TmfTraceTypeUIUtils.selectTraceType(file.getLocation().toOSString(), null, null);
+                                } catch (TmfTraceImportException e) {
+                                    // the trace did not match any trace type
+                                }
+
+                                if (helper != null) {
+                                    status.add(TmfTraceTypeUIUtils.setTraceType(file, helper));
+                                }
+
+                                URI uri = remoteFile.getImportFile().toURI();
+                                String sourceLocation = URIUtil.toUnencodedString(uri);
+                                file.setPersistentProperty(TmfCommonConstants.SOURCE_LOCATION, sourceLocation);
+                            }
+                        } catch (ExecutionException e) {
+                            status.add(new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.TraceControl_ImportFailure, e));
+                        } catch (CoreException e) {
+                            status.add(new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.TraceControl_ImportFailure, e));
+                        }
+                    }
+                    return status;
+                }
+            };
+            job.setUser(true);
+            job.schedule();
+        } finally {
+            fLock.unlock();
+        }
+        return null;
+    }
+
+    @Override
+    public boolean isEnabled() {
+        // Get workbench page for the Control View
+        IWorkbenchPage page = getWorkbenchPage();
+        if (page == null) {
+            return false;
+        }
+
+        // Check if one or more session are selected
+        ISelection selection = page.getSelection(ControlView.ID);
+        TraceSessionComponent session = null;
+        if (selection instanceof StructuredSelection) {
+            StructuredSelection structered = ((StructuredSelection) selection);
+            for (Iterator<?> iterator = structered.iterator(); iterator.hasNext();) {
+                Object element = iterator.next();
+                if (element instanceof TraceSessionComponent) {
+                    // Add only TraceSessionComponents that are inactive and not
+                    // destroyed
+                    TraceSessionComponent tmpSession = (TraceSessionComponent) element;
+                    if ((tmpSession.isSnapshotSession() || tmpSession.isLiveTrace() || (tmpSession.getSessionState() == TraceSessionState.INACTIVE)) && (!tmpSession.isDestroyed())) {
+                        session = tmpSession;
+                    }
+                }
+            }
+        }
+        boolean isEnabled = session != null;
+
+        fLock.lock();
+        try {
+            fParam = null;
+            if (isEnabled) {
+                fParam = new CommandParameter(session);
+            }
+        } finally {
+            fLock.unlock();
+        }
+        return isEnabled;
+    }
+
+    // ------------------------------------------------------------------------
+    // Helper methods
+    // ------------------------------------------------------------------------
+
+    /**
+     * Downloads a trace from the remote host to the given project.
+     *
+     * @param trace
+     *            - trace information of trace to import
+     * @param project
+     *            - project to import to
+     * @param monitor
+     *            - a progress monitor
+     * @throws ExecutionException
+     */
+    private static void downloadTrace(ImportFileInfo trace, IProject project, IProgressMonitor monitor)
+            throws ExecutionException {
+        try {
+            IFileStore importRoot = trace.getImportFile();
+
+            IFolder traceFolder = project.getFolder(TmfTracesFolder.TRACES_FOLDER_NAME);
+            if (!traceFolder.exists()) {
+                throw new ExecutionException(Messages.TraceControl_ImportDialogInvalidTracingProject + " (" + TmfTracesFolder.TRACES_FOLDER_NAME + ")"); //$NON-NLS-1$//$NON-NLS-2$
+            }
+
+            IFolder destinationFolder = trace.getDestinationFolder();
+            TraceUtils.createFolder(destinationFolder, monitor);
+
+            String traceName = trace.getLocalTraceName();
+            IFolder folder = destinationFolder.getFolder(traceName);
+            if (folder.exists()) {
+                if (!trace.isOverwrite()) {
+                    throw new ExecutionException(Messages.TraceControl_ImportDialogTraceAlreadyExistError + ": " + traceName); //$NON-NLS-1$
+                }
+            } else {
+                folder.create(true, true, null);
+            }
+
+            IFileStore[] sources = importRoot.childStores(EFS.NONE, new NullProgressMonitor());
+            SubMonitor subMonitor = SubMonitor.convert(monitor, sources.length);
+            subMonitor.beginTask(Messages.TraceControl_DownloadTask, sources.length);
+
+            for (IFileStore source : sources) {
+                if (subMonitor.isCanceled()) {
+                    monitor.setCanceled(true);
+                    return;
+                }
+                SubMonitor childMonitor = subMonitor.newChild(1);
+                IFileInfo info = source.fetchInfo();
+                if (!info.isDirectory()) {
+                    IPath destination = folder.getLocation().addTrailingSeparator().append(source.getName());
+                    subMonitor.setTaskName(Messages.TraceControl_DownloadTask + ' ' + traceName + '/' + source.getName());
+                    try (InputStream in = source.openInputStream(EFS.NONE, new NullProgressMonitor())) {
+                        copy(in, destination, childMonitor, info.getLength());
+                    }
+                }
+            }
+        } catch (IOException e) {
+            throw new ExecutionException(e.toString(), e);
+        } catch (CoreException e) {
+            throw new ExecutionException(e.toString(), e);
+        }
+    }
+
+    private static void copy(InputStream in, IPath destination, SubMonitor monitor, long length) throws IOException {
+        try (OutputStream out = new FileOutputStream(destination.toFile())) {
+            monitor.setWorkRemaining((int) (length / BYTES_PER_KB));
+            byte[] buf = new byte[BYTES_PER_KB * BUFFER_IN_KB];
+            int counter = 0;
+            for (;;) {
+                int n = in.read(buf);
+                if (n <= 0) {
+                    return;
+                }
+                out.write(buf, 0, n);
+                counter = (counter % BYTES_PER_KB) + n;
+                monitor.worked(counter / BYTES_PER_KB);
+            }
+        }
+    }
+
+    private static void importLiveTrace(final LttngRelaydConnectionInfo connectionInfo, final IProject project) {
+        Job job = new Job(Messages.TraceControl_ImportJob) {
+
+            @Override
+            protected IStatus run(final IProgressMonitor monitor) {
+                try {
+                    // We initiate the connection first so that we can retrieve the trace path
+                    LttngRelaydConsumer lttngRelaydConsumer = LttngRelaydConnectionManager.getInstance().getConsumer(connectionInfo);
+                    try {
+                        lttngRelaydConsumer.connect();
+                    } catch (CoreException e) {
+                        return new Status(IStatus.ERROR, Activator.PLUGIN_ID, org.eclipse.tracecompass.internal.lttng2.control.ui.relayd.Messages.LttngRelaydConnectionManager_ConnectionError, e);
+                    }
+                    initializeTraceResource(connectionInfo, lttngRelaydConsumer.getTracePath(), project);
+                    return Status.OK_STATUS;
+                } catch (CoreException | TmfTraceImportException e) {
+                    return new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.ImportHandler_LiveTraceInitError, e);
+                }
+            }
+
+        };
+        job.setSystem(true);
+        job.schedule();
+    }
+
+
+    private static void initializeTraceResource(final LttngRelaydConnectionInfo connectionInfo, final String tracePath, final IProject project) throws CoreException, TmfTraceImportException {
+        IFolder folder = project.getFolder(TmfTracesFolder.TRACES_FOLDER_NAME);
+        IFolder traceFolder = folder.getFolder(connectionInfo.getSessionName());
+        Path location = new Path(tracePath);
+        IStatus result = ResourcesPlugin.getWorkspace().validateLinkLocation(folder, location);
+        if (result.isOK()) {
+            traceFolder.createLink(location, IResource.REPLACE, new NullProgressMonitor());
+        } else {
+            throw new CoreException(new Status(IStatus.ERROR, Activator.PLUGIN_ID, result.getMessage()));
+        }
+
+        TraceTypeHelper selectedTraceType = TmfTraceTypeUIUtils.selectTraceType(location.toOSString(), null, null);
+        // No trace type was determined.
+        TmfTraceTypeUIUtils.setTraceType(traceFolder, selectedTraceType);
+
+        final TmfProjectElement projectElement = TmfProjectRegistry.getProject(project, true);
+        final TmfTraceFolder tracesFolder = projectElement.getTracesFolder();
+        final List<TmfTraceElement> traces = tracesFolder.getTraces();
+        TmfTraceElement found = null;
+        for (TmfTraceElement candidate : traces) {
+            if (candidate.getName().equals(connectionInfo.getSessionName())) {
+                found = candidate;
+            }
+        }
+
+        if (found == null) {
+            throw new CoreException(new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.ImportHandler_LiveTraceElementError));
+        }
+
+        // Properties used to be able to reopen a trace in live mode
+        traceFolder.setPersistentProperty(CtfConstants.LIVE_HOST, connectionInfo.getHost());
+        traceFolder.setPersistentProperty(CtfConstants.LIVE_PORT, Integer.toString(connectionInfo.getPort()));
+        traceFolder.setPersistentProperty(CtfConstants.LIVE_SESSION_NAME, connectionInfo.getSessionName());
+
+        final TmfTraceElement finalTrace = found;
+        Display.getDefault().syncExec(new Runnable() {
+
+            @Override
+            public void run() {
+                TmfOpenTraceHelper.openTraceFromElement(finalTrace);
+            }
+        });
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/NewConnectionHandler.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/NewConnectionHandler.java
new file mode 100644 (file)
index 0000000..79dfdef
--- /dev/null
@@ -0,0 +1,149 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2015 Ericsson and others
+ *
+ * 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:
+ *   Bernd Hufmann               - Initial API and implementation
+ *   Anna Dushistova(Montavista) - [382684] Allow reusing already defined connections that have Files and Shells subsystems
+ *   Markus Schorn - Bug 448058: Use org.eclipse.remote in favor of RSE
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
+
+import static org.eclipse.tracecompass.common.core.NonNullUtils.checkNotNull;
+
+import java.util.Map;
+
+import org.eclipse.core.commands.ExecutionEvent;
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.jface.window.Window;
+import org.eclipse.remote.core.IRemoteConnection;
+import org.eclipse.remote.core.IRemoteConnectionType;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.INewConnectionDialog;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.TraceControlDialogFactory;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent;
+import org.eclipse.tracecompass.tmf.remote.core.proxy.TmfRemoteConnectionFactory;
+import org.eclipse.ui.IWorkbenchPage;
+import org.eclipse.ui.IWorkbenchPart;
+import org.eclipse.ui.IWorkbenchWindow;
+import org.eclipse.ui.PlatformUI;
+
+/**
+ * <p>
+ * Command handler for creation of a new connection for trace control.
+ * <br> By supplying arguments for the parameters with id {@link #PARAMETER_REMOTE_SERVICES_ID} and
+ * {@link #PARAMETER_CONNECTION_NAME}, the caller can specify the remote connection that will
+ * be added to the trace control. In case one of the optional arguments is not supplied, the handler
+ * opens a dialog for selecting a remote connection.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class NewConnectionHandler extends BaseControlViewHandler {
+
+    /**
+     * Id of the parameter for the remote services id.
+     * @see NewConnectionHandler
+     * @see IRemoteConnectionType#getId()
+     */
+    public static final String PARAMETER_REMOTE_SERVICES_ID = "org.eclipse.linuxtools.lttng2.control.ui.remoteServicesIdParameter"; //$NON-NLS-1$
+    /**
+     * Id of the parameter for the name of the remote connection.
+     * @see NewConnectionHandler
+     * @see IRemoteConnection#getName()
+     */
+    public static final String PARAMETER_CONNECTION_NAME = "org.eclipse.linuxtools.lttng2.control.ui.connectionNameParameter"; //$NON-NLS-1$
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+
+    /**
+     * The parent trace control component the new node will be added to.
+     */
+    private ITraceControlComponent fRoot = null;
+
+    @Override
+    public Object execute(ExecutionEvent event) throws ExecutionException {
+        assert (fRoot != null);
+
+        IWorkbenchWindow window = PlatformUI.getWorkbench().getActiveWorkbenchWindow();
+        if (window == null) {
+            return false;
+        }
+
+        IRemoteConnection connection = getConnection(event.getParameters());
+        if (connection != null) {
+            fLock.lock();
+            try {
+                // successful creation of host
+                TargetNodeComponent node = null;
+                if (!fRoot.containsChild(connection.getName())) {
+                    node = new TargetNodeComponent(connection.getName(), fRoot, connection);
+                    fRoot.addChild(node);
+                } else {
+                    node = (TargetNodeComponent)fRoot.getChild(connection.getName());
+                }
+
+                node.connect();
+            } finally {
+                fLock.unlock();
+            }
+        }
+        return null;
+    }
+
+    private static IRemoteConnection getConnection(Map<?,?> parameters) {
+        // First check whether arguments have been supplied
+        Object remoteServicesId = parameters.get(PARAMETER_REMOTE_SERVICES_ID);
+        Object connectionName = parameters.get(PARAMETER_CONNECTION_NAME);
+        if ((remoteServicesId != null) && (connectionName != null)) {
+            return TmfRemoteConnectionFactory.getRemoteConnection(
+                    checkNotNull(remoteServicesId.toString()),
+                    checkNotNull(connectionName.toString()));
+        }
+
+        // Without the arguments, open dialog box for the node name and address
+        final INewConnectionDialog dialog = TraceControlDialogFactory.getInstance().getNewConnectionDialog();
+        if (dialog.open() == Window.OK) {
+            return dialog.getConnection();
+        }
+
+        return null;
+    }
+
+    @Override
+    public boolean isEnabled() {
+
+        // Get workbench page for the Control View
+        IWorkbenchPage page = getWorkbenchPage();
+        if (page == null) {
+            return false;
+        }
+
+        ITraceControlComponent root = null;
+
+        // no need to verify part because it has been already done in getWorkbenchPage()
+        IWorkbenchPart part = page.getActivePart();
+        root = ((ControlView) part).getTraceControlRoot();
+
+        boolean isEnabled = root != null;
+
+        fLock.lock();
+        try {
+            fRoot = null;
+            if (isEnabled) {
+                fRoot = root;
+            }
+        } finally {
+            fLock.unlock();
+        }
+
+        return isEnabled;
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/RefreshHandler.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/RefreshHandler.java
new file mode 100644 (file)
index 0000000..228acf4
--- /dev/null
@@ -0,0 +1,105 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
+
+import java.util.Iterator;
+
+import org.eclipse.core.commands.ExecutionEvent;
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.jface.viewers.ISelection;
+import org.eclipse.jface.viewers.StructuredSelection;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TargetNodeState;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceControlComponent;
+import org.eclipse.ui.IWorkbenchPage;
+
+/**
+ * <p>
+ * Command handler implementation to refresh node configuration.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class RefreshHandler extends BaseControlViewHandler {
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+
+    /**
+     * The node component reference.
+     */
+    private TargetNodeComponent fNode;
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    public Object execute(ExecutionEvent event) throws ExecutionException {
+        fLock.lock();
+        try {
+            fNode.refresh();
+        } finally {
+            fLock.unlock();
+        }
+        return null;
+    }
+
+    @Override
+    public boolean isEnabled() {
+
+        // Get workbench page for the Control View
+        IWorkbenchPage page = getWorkbenchPage();
+        if (page == null) {
+            return false;
+        }
+
+        TargetNodeComponent node = null;
+        // Check if one or more session are selected
+        ISelection selection = page.getSelection(ControlView.ID);
+        if (selection instanceof StructuredSelection) {
+
+            StructuredSelection structered = ((StructuredSelection) selection);
+            for (Iterator<?> iterator = structered.iterator(); iterator.hasNext();) {
+                Object element = iterator.next();
+                if (element instanceof TraceControlComponent) {
+                    TraceControlComponent component = (TraceControlComponent) element;
+                    boolean isConnected = component.getTargetNodeState() == TargetNodeState.CONNECTED;
+                    if (isConnected) {
+                        while ((component != null) && component.getClass() != TargetNodeComponent.class) {
+                            component = (TraceControlComponent) component.getParent();
+                        }
+                        if (component != null) {
+                            node = (TargetNodeComponent) component;
+                        }
+                    }
+                }
+            }
+        }
+
+        boolean isEnabled = node != null;
+
+        fLock.lock();
+        try {
+            fNode = null;
+            if (isEnabled) {
+                fNode = node;
+            }
+        } finally {
+            fLock.unlock();
+        }
+
+        return isEnabled;
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/SnaphshotHandler.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/SnaphshotHandler.java
new file mode 100644 (file)
index 0000000..753b29e
--- /dev/null
@@ -0,0 +1,130 @@
+/**********************************************************************
+ * Copyright (c) 2013, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
+
+import java.util.ArrayList;
+import java.util.Iterator;
+import java.util.List;
+
+import org.eclipse.core.commands.ExecutionEvent;
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.core.runtime.IStatus;
+import org.eclipse.core.runtime.MultiStatus;
+import org.eclipse.core.runtime.Status;
+import org.eclipse.core.runtime.jobs.Job;
+import org.eclipse.jface.viewers.ISelection;
+import org.eclipse.jface.viewers.StructuredSelection;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
+import org.eclipse.ui.IWorkbenchPage;
+
+/**
+ * <p>
+ * Command handler implementation to record a snapshot.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class SnaphshotHandler extends BaseControlViewHandler {
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+    /**
+     * The list of session components the command is to be executed on.
+     */
+    protected List<TraceSessionComponent> fSessions = new ArrayList<>();
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    public Object execute(ExecutionEvent event) throws ExecutionException {
+        fLock.lock();
+        try {
+            // Make a copy for thread safety
+            final List<TraceSessionComponent> sessions = new ArrayList<>();
+            sessions.addAll(fSessions);
+
+            Job job = new Job(Messages.TraceControl_RecordSnapshotJob) {
+                @Override
+                protected IStatus run(IProgressMonitor monitor) {
+                    MultiStatus status = new MultiStatus(Activator.PLUGIN_ID, IStatus.OK, null, null);
+                    for (Iterator<TraceSessionComponent> iterator = sessions.iterator(); iterator.hasNext();) {
+                        try {
+                            // record snapshot for all selected sessions sequentially
+                            TraceSessionComponent session = iterator.next();
+                            session.recordSnapshot(monitor);
+                            if (monitor.isCanceled()) {
+                                status.add(Status.CANCEL_STATUS);
+                                break;
+                            }
+                        } catch (ExecutionException e) {
+                            status.add(new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.TraceControl_RecordSnapshotFailure, e));
+                        }
+                    }
+                    return status;
+                }
+            };
+            job.setUser(true);
+            job.schedule();
+        } finally {
+            fLock.unlock();
+        }
+        return null;
+    }
+
+    @Override
+    public boolean isEnabled() {
+        // Get workbench page for the Control View
+        IWorkbenchPage page = getWorkbenchPage();
+        if (page == null) {
+            return false;
+        }
+
+        List<TraceSessionComponent> sessions = new ArrayList<>(0);
+
+        // Check if one session is selected
+        ISelection selection = page.getSelection(ControlView.ID);
+        if (selection instanceof StructuredSelection) {
+            StructuredSelection structered = ((StructuredSelection) selection);
+            for (Iterator<?> iterator = structered.iterator(); iterator.hasNext();) {
+                Object element = iterator.next();
+                if (element instanceof TraceSessionComponent) {
+                    // Add only if corresponding TraceSessionComponent is an active snapshot session and not destroyed
+                    TraceSessionComponent session = (TraceSessionComponent) element;
+                    if(session.isSnapshotSession() &&
+                            session.getSessionState() == TraceSessionState.ACTIVE &&
+                            !session.isDestroyed()) {
+                        sessions.add(session);
+                    }
+                }
+            }
+        }
+        boolean isEnabled = !sessions.isEmpty();
+        fLock.lock();
+        try {
+            fSessions = null;
+            if (isEnabled) {
+                fSessions = sessions;
+            }
+        } finally {
+            fLock.unlock();
+        }
+        return isEnabled;
+    }
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/StartHandler.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/StartHandler.java
new file mode 100644 (file)
index 0000000..f818d0d
--- /dev/null
@@ -0,0 +1,45 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
+
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
+
+/**
+ * <p>
+ * Command handler implementation to start one or more trace sessions.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class StartHandler extends ChangeSessionStateHandler {
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    @Override
+    public TraceSessionState getNewState() {
+        return TraceSessionState.ACTIVE;
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    public void changeState(TraceSessionComponent session, IProgressMonitor monitor) throws ExecutionException {
+        session.startSession(monitor);
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/StopHandler.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/StopHandler.java
new file mode 100644 (file)
index 0000000..7b15839
--- /dev/null
@@ -0,0 +1,45 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
+
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
+
+/**
+ * <p>
+ * Command handler implementation to stop one or more trace sessions.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class StopHandler extends ChangeSessionStateHandler {
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    @Override
+    public TraceSessionState getNewState() {
+        return TraceSessionState.INACTIVE;
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    public void changeState(TraceSessionComponent session, IProgressMonitor monitor) throws ExecutionException {
+        session.stopSession(monitor);
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/XmlMiValidationErrorHandler.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/XmlMiValidationErrorHandler.java
new file mode 100644 (file)
index 0000000..524368b
--- /dev/null
@@ -0,0 +1,49 @@
+/**********************************************************************
+ * Copyright (c) 2014 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:
+ *   Jonathan Rajotte - Initial implementation
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
+
+import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.service.LTTngControlServiceMI;
+import org.xml.sax.ErrorHandler;
+import org.xml.sax.SAXException;
+import org.xml.sax.SAXParseException;
+
+/**
+ * <p>
+ * Error handler for xml xsd validation while using machine interface mode
+ * in {@link LTTngControlServiceMI}.
+ * </p>
+ *
+ * @author Jonathan Rajotte
+ */
+public class XmlMiValidationErrorHandler implements ErrorHandler {
+
+    @Override
+    public void error(SAXParseException e) throws SAXException {
+        Activator.getDefault().logError(Messages.TraceControl_XmlValidationError, e);
+        throw new SAXException(Messages.TraceControl_XmlValidationError, e);
+    }
+
+    @Override
+    public void fatalError(SAXParseException e) throws SAXException {
+        Activator.getDefault().logError(Messages.TraceControl_XmlValidationError, e);
+        throw new SAXException(Messages.TraceControl_XmlValidationError, e);
+    }
+
+    @Override
+    public void warning(SAXParseException e) throws SAXException {
+        Activator.getDefault().logWarning(Messages.TraceControl_XmlValidationWarning, e);
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/logging/ControlCommandLogger.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/logging/ControlCommandLogger.java
new file mode 100644 (file)
index 0000000..fef7567
--- /dev/null
@@ -0,0 +1,117 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.logging;
+
+import java.io.BufferedWriter;
+import java.io.FileWriter;
+import java.io.IOException;
+
+import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
+
+/**
+ * <p>
+ * Class to log control commands.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public final class ControlCommandLogger {
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+    /**
+     * The bufferd writer reference
+     */
+    private static BufferedWriter fTraceLog = null;
+
+    // ------------------------------------------------------------------------
+    // Constructor
+    // ------------------------------------------------------------------------
+    private ControlCommandLogger() {
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+    /**
+     * Initializes the logger class and opens the log file with the given parameter.
+     * @param filename - file name of logger output
+     * @param append - true to open log file in append mode else false (overwrite)
+     */
+    public static void init(String filename, boolean append) {
+        if (fTraceLog != null) {
+            close();
+        }
+        fTraceLog = openLogFile(filename, append);
+    }
+
+    /**
+     * Closes the log file if open.
+     */
+    public static void close() {
+        if (fTraceLog == null) {
+            return;
+        }
+
+        try {
+            fTraceLog.close();
+            fTraceLog = null;
+        } catch (IOException e) {
+            Activator.getDefault().logWarning("Can't close log file of the trace control", e); //$NON-NLS-1$
+        }
+    }
+
+    /**
+     * Logs a message to the log file.
+     * @param msg - message (e.g. command or command result) to log
+     */
+    @SuppressWarnings("nls")
+    public static void log(String msg) {
+        long currentTime = System.currentTimeMillis();
+        StringBuilder message = new StringBuilder("[");
+        message.append(currentTime / 1000);
+        message.append(".");
+        message.append(String.format("%1$03d", currentTime % 1000));
+        message.append("] ");
+        message.append(msg);
+        if (fTraceLog != null) {
+            try {
+                fTraceLog.write(message.toString());
+                fTraceLog.newLine();
+                fTraceLog.flush();
+            } catch (IOException e) {
+                Activator.getDefault().logError("Can't log message in log file of the tracer control", e); //$NON-NLS-1$
+            }
+        }
+    }
+
+    // ------------------------------------------------------------------------
+    // Helper methods
+    // ------------------------------------------------------------------------
+    /**
+     * Opens the trace log file with given name in the workspace root directory
+     * @param filename - file name of logger output
+     * @param append - true to open log file in append mode else false (overwrite)
+     * @return the buffer writer class or null if not successful
+     */
+    private static BufferedWriter openLogFile(String filename, boolean append) {
+        BufferedWriter outfile = null;
+        try {
+            outfile = new BufferedWriter(new FileWriter(filename, append));
+        } catch (IOException e) {
+            Activator.getDefault().logError("Can't open log file for logging of tracer control commands: " + filename, e); //$NON-NLS-1$
+        }
+        return outfile;
+    }
+}
+
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/messages/Messages.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/messages/Messages.java
new file mode 100644 (file)
index 0000000..5944aba
--- /dev/null
@@ -0,0 +1,346 @@
+/*******************************************************************************
+ * Copyright (c) 2012, 2015 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
+ *   Jonathan Rajotte - Updated for basic support of LTTng 2.6 machine interface
+ *   Markus Schorn - Bug 448058: Use org.eclipse.remote in favor of RSE
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages;
+
+import org.eclipse.osgi.util.NLS;
+
+/**
+ * Messages file for the trace control package.
+ *
+ * @author Bernd Hufmann
+ */
+@SuppressWarnings("javadoc")
+public final class Messages extends NLS {
+
+    private static final String BUNDLE_NAME = "org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.messages"; //$NON-NLS-1$
+
+    public static String EnableChannelDialog_DefaultMessage;
+
+    public static String ImportHandler_LiveTraceElementError;
+
+    public static String ImportHandler_LiveTraceInitError;
+
+    // Failures
+    public static String TraceControl_ConnectionFailure;
+    public static String TraceControl_DisconnectionFailure;
+
+    public static String TraceControl_CommandError;
+    public static String TraceControl_UnexpectedCommandOutputFormat;
+    public static String TraceControl_UnexpectedNameError;
+    public static String TraceControl_UnexpectedPathError;
+    public static String TraceControl_UnexpectedNumberOfElementError;
+    public static String TraceControl_UnexpectedValueError;
+
+    public static String TraceControl_UnsupportedVersionError;
+    public static String TraceControl_GettingVersionError;
+
+    // Xml parsing related failures
+    public static String TraceControl_InvalidSchemaError;
+    public static String TraceControl_XmlDocumentBuilderError;
+    public static String TraceControl_XmlParsingError;
+    public static String TraceControl_XmlValidationError;
+    public static String TraceControl_XmlValidationWarning;
+
+    // Xml machine interface failures
+    public static String TraceControl_MiInvalidNumberOfElementError;
+    public static String TraceControl_MiInvalidProviderError;
+    public static String TraceControl_MiMissingRequiredError;
+    public static String TraceControl_MiInvalidElementError;
+    public static String TraceControl_MiIllegalValueError;
+
+    // Commands
+    public static String TraceControl_ErrorTitle;
+    public static String TraceControl_RetrieveNodeConfigurationJob;
+    public static String TraceControl_RetrieveNodeConfigurationFailure;
+    public static String TraceControl_ListSessionFailure;
+    public static String TraceControl_EclipseCommandFailure;
+    public static String TraceControl_NewNodeCreateButtonText;
+
+    public static String TraceControl_NewNodeCreationFailure;
+    public static String TraceControl_CreateSessionJob;
+    public static String TraceControl_CreateSessionFailure;
+
+    public static String TraceControl_DestroySessionJob;
+    public static String TraceControl_DestroySessionFailure;
+    public static String TraceControl_DestroyConfirmationTitle;
+    public static String TraceControl_DestroyConfirmationMessage;
+
+    public static String TraceControl_ImportJob;
+    public static String TraceControl_DownloadTask;
+    public static String TraceControl_ImportFailure;
+
+    public static String TraceControl_ChangeSessionStateJob;
+    public static String TraceControl_ChangeSessionStateFailure;
+
+    public static String TraceControl_CreateChannelStateJob;
+    public static String TraceControl_CreateChannelStateFailure;
+
+    public static String TraceControl_ChangeChannelStateJob;
+    public static String TraceControl_ChangeChannelStateFailure;
+    public static String TraceControl_ChangeEventStateJob;
+    public static String TraceControl_ChangeEventStateFailure;
+
+    public static String TraceControl_EnableEventsJob;
+    public static String TraceControl_EnableEventsFailure;
+    public static String TraceControl_DisableEventsJob;
+
+    public static String TraceControl_GetContextJob;
+    public static String TraceControl_GetContextFailure;
+
+    public static String TraceControl_AddContextJob;
+    public static String TraceControl_AddContextFailure;
+
+    public static String TraceControl_AddCalibrateJob;
+    public static String TraceControl_AddCalibrateFailure;
+
+    public static String TraceControl_RecordSnapshotJob;
+    public static String TraceControl_RecordSnapshotFailure;
+
+    // Dialogs
+    public static String TraceControl_NewDialogTitle;
+    public static String TraceControl_NewNodeExistingConnectionGroupName;
+    public static String TraceControl_NewNodeEditButtonName;
+    public static String TraceControl_NewNodeComboToolTip;
+    public static String TraceControl_NewNodeConnectionNameLabel;
+    public static String TraceControl_NewNodeConnectionNameTooltip;
+    public static String TraceControl_NewNodeHostNameLabel;
+    public static String TraceControl_NewNodeHostNameTooltip;
+    public static String TraceControl_NewNodePortLabel;
+    public static String TraceControl_NewNodePortTooltip;
+    public static String TraceControl_AlreadyExistsError;
+
+    public static String TraceControl_CreateSessionDialogTitle;
+    public static String TraceControl_CreateSessionDialogMessage;
+    public static String TraceControl_CreateSessionNameLabel;
+    public static String TraceControl_CreateSessionNameTooltip;
+    public static String TraceControl_CreateSessionPathLabel;
+    public static String TraceControl_CreateSessionPathTooltip;
+    public static String TraceControl_CreateSessionNormalLabel;
+    public static String TraceControl_CreateSessionNormalTooltip;
+    public static String TraceControl_CreateSessionSnapshotLabel;
+    public static String TraceControl_CreateSessionSnapshotTooltip;
+    public static String TraceControl_CreateSessionLiveLabel;
+    public static String TraceControl_CreateSessionLiveTooltip;
+
+    public static String TraceControl_CreateSessionConfigureStreamingButtonText;
+    public static String TraceControl_CreateSessionConfigureStreamingButtonTooltip;
+    public static String TraceControl_CreateSessionNoStreamingButtonText;
+    public static String TraceControl_CreateSessionNoStreamingButtonTooltip;
+    public static String TraceControl_CreateSessionTracePathText;
+    public static String TraceControl_CreateSessionTracePathTooltip;
+    public static String TraceControl_CreateSessionLinkButtonText;
+    public static String TraceControl_CreateSessionLinkButtonTooltip;
+    public static String TraceControl_CreateSessionProtocolLabelText;
+    public static String TraceControl_CreateSessionAddressLabelText;
+    public static String TraceControl_CreateSessionPortLabelText;
+    public static String TraceControl_CreateSessionControlUrlLabel;
+    public static String TraceControl_CreateSessionDataUrlLabel;
+    public static String TraceControl_CreateSessionCommonProtocolTooltip;
+    public static String TraceControl_CreateSessionControlAddressTooltip;
+    public static String TraceControl_CreateSessionControlPortTooltip;
+    public static String TraceControl_CreateSessionProtocolTooltip;
+    public static String TraceControl_CreateSessionDataAddressTooltip;
+    public static String TraceControl_CreateSessionDataPortTooltip;
+    public static String TraceControl_CreateSessionNoConsumertText;
+    public static String TraceControl_CreateSessionNoConsumertTooltip;
+    public static String TraceControl_CreateSessionDisableConsumertText;
+    public static String TraceControl_CreateSessionDisableConsumertTooltip;
+    public static String TraceControl_CreateSessionLiveConnectionLabel;
+    public static String TraceControl_CreateSessionLiveConnectionUrlTooltip;
+    public static String TraceControl_CreateSessionLiveConnectionPortTooltip;
+    public static String TraceControl_CreateSessionLiveDelayLabel;
+    public static String TraceControl_CreateSessionLiveDelayTooltip;
+
+    public static String TraceControl_InvalidSessionNameError;
+    public static String TraceControl_SessionAlreadyExistsError;
+    public static String TraceControl_SessionPathAlreadyExistsError;
+    public static String TraceControl_InvalidSessionPathError;
+    public static String TraceControl_InvalidLiveDelayError;
+    public static String TraceControl_FileSubSystemError;
+
+    public static String TraceControl_EnableChannelDialogTitle;
+    public static String TraceControl_EnableChannelNameLabel;
+    public static String TraceControl_EnableChannelNameTooltip;
+    public static String TraceControl_EnableChannelSubBufferSizeTooltip;
+    public static String TraceControl_EnableChannelNbSubBuffersTooltip;
+    public static String TraceControl_EnableChannelSwitchTimerTooltip;
+    public static String TraceControl_EnableChannelReadTimerTooltip;
+    public static String TraceControl_EnableChannelOutputTypeTooltip;
+    public static String TraceControl_EnableChannelDiscardModeGroupName;
+    public static String TraceControl_EnableChannelDiscardModeLabel;
+    public static String TraceControl_EnableChannelDiscardModeTooltip;
+    public static String TraceControl_EnableChannelOverwriteModeLabel;
+    public static String TraceControl_EnableChannelOverwriteModeTooltip;
+    public static String TraceControl_EnbleChannelMaxSizeTraceFilesTooltip;
+    public static String TraceControl_EnbleChannelMaxNumTraceFilesTooltip;
+
+    public static String TraceControl_InvalidChannelNameError;
+    public static String TraceControl_ChannelAlreadyExistsError;
+
+    public static String TraceControl_EnableEventsDialogTitle;
+    public static String TraceControl_EnableEventsSessionGroupName;
+    public static String TraceControl_EnableEventsChannelGroupName;
+    public static String TraceControl_EnableEventsSessionsTooltip;
+    public static String TraceControl_EnableEventsChannelsTooltip;
+    public static String TraceControl_EnableEventsNoSessionError;
+    public static String TraceControl_EnableEventsNoChannelError;
+
+    public static String TraceControl_EnableGroupSelectionName;
+    public static String TraceControl_EnableEventsTracepointGroupName;
+    public static String TraceControl_EnableEventsTracepointTreeTooltip;
+    public static String TraceControl_EnableEventsTracepointTreeAllLabel;
+    public static String TraceControl_EnableEventsSyscallName;
+    public static String TraceControl_EnableEventsSyscallTooltip;
+    public static String TraceControl_EnableEventsProbeGroupName;
+    public static String TraceControl_EnableEventsEventNameLabel;
+    public static String TraceControl_EnableEventsProbeEventNameTooltip;
+    public static String TraceControl_EnableEventsProbeNameLabel;
+    public static String TraceControl_EnableEventsProbeNameTooltip;
+    public static String TraceControl_EnableEventsFucntionGroupName;
+    public static String TraceControl_EnableEventsFunctionEventNameTooltip;
+    public static String TraceControl_EnableEventsFunctionNameLabel;
+
+    public static String TraceControl_EnableEventsWildcardGroupName;
+    public static String TraceControl_EnableEventsWildcardLabel;
+    public static String TraceControl_EnableEventsWildcardTooltip;
+    public static String TraceControl_EnableEventsLogLevelGroupName;
+    public static String TraceControl_EnableEventsLogLevelTypeName;
+    public static String TraceControl_EnableEventsLogLevelTypeTooltip;
+    public static String TraceControl_EnableEventsLogLevelOnlyTypeName;
+    public static String TraceControl_EnableEventsLogLevelOnlyTypeTooltip;
+    public static String TraceControl_EnableEventsLogLevelTooltip;
+    public static String TraceControl_EnableEventsLoglevelEventNameTooltip;
+    public static String TraceControl_EnableEventsFilterGroupName;
+    public static String TraceControl_EnableEventsFilterTooltip;
+
+    public static String TraceControl_InvalidProbeNameError;
+    public static String TraceControl_InvalidWildcardError;
+    public static String TraceControl_InvalidLogLevelEventNameError;
+    public static String TraceControl_InvalidLogLevel;
+
+    public static String TraceControl_AddContextDialogTitle;
+    public static String TraceControl_AddContextAvailableContextsLabel;
+    public static String TraceControl_AddContextAvailableContextsTooltip;
+    public static String TraceControl_AddContextAllLabel;
+
+    public static String TraceControl_ImportDialogStreamedTraceNotification;
+    public static String TraceControl_ImportDialogStreamedTraceNotificationToggle;
+    public static String TraceControl_ImportDialogTitle;
+    public static String TraceControl_ImportDialogTracesGroupName;
+    public static String TraceControl_ImportDialogTracesTooltip;
+    public static String TraceControl_ImportDialogProjectsGroupName;
+    public static String TraceControl_ImportDialogProjectsTooltip;
+    public static String TraceControl_ImportDialogOverwriteButtonText;
+    public static String TraceControl_ImportDialogCreationError;
+    public static String TraceControl_ImportDialogNoProjectSelectedError;
+    public static String TraceControl_ImportDialogInvalidTracingProject;
+    public static String TraceControl_ImportDialogNoTraceSelectedError;
+    public static String TraceControl_ImportDialog_SelectAll;
+    public static String TraceControl_ImportDialog_DeselectAll;
+
+    public static String TraceControl_ImportDialogConfirmationTitle;
+    public static String TraceControl_ImportDialogConfirmationOverwriteLabel;
+    public static String TraceControl_ImportDialogConfirmationRenameLabel;
+    public static String TraceControl_ImportDialogConfirmationNewNameLabel;
+    public static String TraceControl_InvalidTraceNameError;
+    public static String TraceControl_ImportDialogTraceAlreadyExistError;
+
+    // Tree structure strings
+    public static String TraceControl_KernelDomainDisplayName;
+    public static String TraceControl_UstDisplayName;
+    public static String TraceControl_UstGlobalDomainDisplayName;
+    public static String TraceControl_UnknownDomainDisplayName;
+    public static String TraceControl_JULDomainDisplayName;
+    public static String TraceControl_AllSessionsDisplayName;
+    public static String TraceControl_SessionDisplayName;
+    public static String TraceControl_DomainDisplayName;
+    public static String TraceControl_BufferTypeDisplayName;
+    public static String TraceControl_ChannelDisplayName;
+    public static String TraceControl_EventDisplayName;
+    public static String TraceControl_ProviderDisplayName;
+    public static String TraceControl_KernelProviderDisplayName;
+    public static String TraceControl_SharedBuffersDisplayName;
+    public static String TraceControl_PerPidBuffersDisplayName;
+    public static String TraceControl_PerPidBuffersTooltip;
+    public static String TraceControl_PerUidBuffersDisplayName;
+    public static String TraceControl_PerUidBuffersTooltip;
+
+    // Property names
+    public static String TraceControl_SessionNamePropertyName;
+    public static String TraceControl_EventNamePropertyName;
+    public static String TraceControl_EventTypePropertyName;
+    public static String TraceControl_LogLevelPropertyName;
+    public static String TraceControl_FieldsPropertyName;
+    public static String TraceControl_FilterPropertyName;
+    public static String TraceControl_StatePropertyName;
+    public static String TraceControl_VersionPropertyName;
+    public static String TraceControl_DomainNamePropertyName;
+    public static String TraceControl_BufferTypePropertyName;
+    public static String TraceControl_ChannelNamePropertyName;
+    public static String TraceControl_OpenConnectionTo;
+
+    public static String TraceControl_OverwriteModePropertyName;
+    public static String TraceControl_SubBufferSizePropertyName;
+    public static String TraceControl_NbSubBuffersPropertyName;
+    public static String TraceControl_SwitchTimerPropertyName;
+    public static String TraceControl_ReadTimerPropertyName;
+    public static String TraceControl_OutputTypePropertyName;
+    public static String TraceControl_TraceFileCountPropertyName;
+    public static String TraceControl_TraceFileSizePropertyName;
+    public static String TraceControl_HostNamePropertyName;
+    public static String TraceControl_HostAddressPropertyName;
+    public static String TraceControl_SessionPathPropertyName;
+    public static String TraceControl_SnapshotPathPropertyName;
+    public static String TraceControl_SnapshotNamePropertyName;
+    public static String TraceControl_SnapshotIdPropertyName;
+    public static String TraceControl_ProviderNamePropertyName;
+    public static String TraceControl_ProcessIdPropertyName;
+    public static String TraceControl_ProbeAddressPropertyName;
+    public static String TraceControl_ProbeOffsetPropertyName;
+    public static String TraceControl_ProbeSymbolPropertyName;
+    public static String TraceControl_MaxSizeTraceFilesPropertyName;
+    public static String TraceControl_MaxNumTraceFilesPropertyName;
+    public static String TraceControl_ConfigureMetadataChannelName;
+
+    // Preferences
+    public static String TraceControl_TracingGroupPreference;
+    public static String TraceControl_LoggingPreference;
+    public static String TraceControl_LogfilePath;
+    public static String TraceControl_AppendLogfilePreference;
+
+    public static String TraceControl_VerboseLevelsPreference;
+    public static String TraceControl_VerboseLevelNonePreference;
+    public static String TraceControl_VerboseLevelVerbosePreference;
+    public static String TraceControl_VerboseLevelVeryVerbosePreference;
+    public static String TraceControl_VerboseLevelVeryVeryVerbosePreference;
+
+    public static String TraceControl_ExecuteScriptJob;
+    public static String TraceControl_ExecuteScriptError;
+
+    public static String TraceControl_ExecuteScriptDialogTitle;
+    public static String TraceControl_ExecuteScriptBrowseText;
+    public static String TraceControl_ExecuteScriptSelectLabel;
+
+    public static String TraceControl_UnknownNode;
+
+    static {
+        // initialize resource bundle
+        NLS.initializeMessages(BUNDLE_NAME, Messages.class);
+    }
+
+    private Messages() {
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/messages/messages.properties b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/messages/messages.properties
new file mode 100644 (file)
index 0000000..7ac5155
--- /dev/null
@@ -0,0 +1,321 @@
+###############################################################################
+# Copyright (c) 2012, 2015 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:
+# Bernd Hufmann - initial API and implementation
+# Jonathan Rajotte - updated for basic support of LTTng 2.6 machine interface
+###############################################################################
+
+EnableChannelDialog_DefaultMessage=Default
+ImportHandler_LiveTraceElementError=Could not find trace element
+ImportHandler_LiveTraceInitError=Error initializing live trace.
+TraceControl_ConnectionFailure=Connecting to host failed 
+TraceControl_DisconnectionFailure=Disconnection from host failed
+TraceControl_CommandError=Command failed! Command: 
+
+TraceControl_UnexpectedCommandOutputFormat=Unexpected command output
+TraceControl_UnexpectedNameError=Unexpected session name returned
+TraceControl_UnexpectedPathError=Unexpected session path returned
+TraceControl_UnexpectedNumberOfElementError=Unexpected number of elements {0} returned
+TraceControl_UnexpectedValueError=Unexpected value. Returned {0} Expected: {1}
+
+TraceControl_UnsupportedVersionError=Unsupported LTTng Tracer Control version
+TraceControl_GettingVersionError=Could not get version of LTTng Tracer Control
+
+# Xml parsing related failures
+TraceControl_InvalidSchemaError=Could not open/validate xsd Schema
+TraceControl_XmlDocumentBuilderError=Unable to create the xml document builder
+TraceControl_XmlParsingError=Unable to parse the xml document
+TraceControl_XmlValidationError=Could not validate the xml response
+TraceControl_XmlValidationWarning=Xml validation warning
+
+# Xml machine interface failures
+TraceControl_MiInvalidNumberOfElementError=Invalid number of element
+TraceControl_MiInvalidProviderError=Invalid provider data
+TraceControl_MiMissingRequiredError=Missing required data
+TraceControl_MiIllegalValueError=Invalid value
+
+# Commands
+TraceControl_MiInvalidElementError=Invalid xml data
+
+TraceControl_ErrorTitle=Error
+TraceControl_ListSessionFailure=List sessions failed
+TraceControl_RetrieveNodeConfigurationJob=Retrieving Target Node Configuration...
+TraceControl_RetrieveNodeConfigurationFailure=Error retrieving node configuration
+TraceControl_EclipseCommandFailure=Command failed
+TraceControl_NewNodeCreateButtonText=Create...
+TraceControl_NewNodeCreationFailure=Creation of new connection failed
+TraceControl_CreateSessionJob=Creating Session...
+TraceControl_CreateSessionFailure=Command to create session failed
+
+TraceControl_DestroySessionJob=Destroying Session...
+TraceControl_DestroySessionFailure=Command to destroy session failed
+TraceControl_DestroyConfirmationTitle=Destroy Confirmation
+TraceControl_DestroyConfirmationMessage=Do you want to delete all selected sessions?
+
+TraceControl_ImportJob=Importing Traces...
+TraceControl_DownloadTask=Downloading
+TraceControl_ImportFailure=Command to import traces failed
+
+TraceControl_ChangeSessionStateJob=Changing Session State...
+TraceControl_ChangeSessionStateFailure=Command to change session state failed...
+
+TraceControl_CreateChannelStateJob=Enabling (creating) channel... 
+TraceControl_CreateChannelStateFailure=Command to enable channel failed
+
+TraceControl_ChangeChannelStateJob=Changing State of Channels...
+TraceControl_ChangeChannelStateFailure=Command to change state of channels failed
+TraceControl_ChangeEventStateJob=Changing State of Events...
+TraceControl_ChangeEventStateFailure=Command to change state of events failed
+
+TraceControl_EnableEventsJob=Enabling Events...
+TraceControl_EnableEventsFailure=Command to enable events failed
+TraceControl_DisableEventsJob=Disabling Events...
+
+TraceControl_GetContextJob=Getting Available Contexts...
+TraceControl_GetContextFailure=Command to get available contexts failed
+
+TraceControl_AddContextJob=Adding Contexts...
+TraceControl_AddContextFailure=Command to add contexts failed
+
+TraceControl_AddCalibrateJob=Calibrating...
+TraceControl_AddCalibrateFailure=Command to calibrate failed
+
+TraceControl_RecordSnapshotJob=Record snapshot...
+TraceControl_RecordSnapshotFailure=Command to snapshot record failed
+
+# Dialogs
+TraceControl_NewDialogTitle=New Connection
+TraceControl_NewNodeExistingConnectionGroupName=Select an existing connection, or use a provider to create a new one:
+TraceControl_NewNodeEditButtonName=Edit...
+TraceControl_NewNodeComboToolTip=List of existing connections (connection name - host name)
+TraceControl_NewNodeConnectionNameLabel=Connection Name
+TraceControl_NewNodeConnectionNameTooltip=Alias to be displayed for node to connect to. 
+TraceControl_NewNodeHostNameLabel=Host Name
+TraceControl_NewNodeHostNameTooltip=IP Address or DNS name of node to connect to.
+TraceControl_NewNodePortLabel=Port Number
+TraceControl_NewNodePortTooltip=IP Port Number to be used for the connection. Leave empty for default port.
+TraceControl_AlreadyExistsError=Node name already exists in Control View
+
+TraceControl_CreateSessionDialogTitle=Create Session
+TraceControl_CreateSessionDialogMessage=Configure the new tracing session
+TraceControl_CreateSessionNameLabel=Session Name
+TraceControl_CreateSessionNameTooltip=The name of the session to be created.
+TraceControl_CreateSessionPathLabel=Session Path
+TraceControl_CreateSessionPathTooltip=The session path (keep empty for default location)
+TraceControl_CreateSessionNormalLabel=Normal Mode
+TraceControl_CreateSessionNormalTooltip=Configure session in normal mode
+TraceControl_CreateSessionSnapshotLabel=Snapshot Mode
+TraceControl_CreateSessionSnapshotTooltip=Configure session in snapshot mode
+TraceControl_CreateSessionLiveLabel=Live Mode
+TraceControl_CreateSessionLiveTooltip=Configure session in live mode
+
+
+TraceControl_CreateSessionConfigureStreamingButtonText=Advanced
+TraceControl_CreateSessionConfigureStreamingButtonTooltip=Configure advanced options
+TraceControl_CreateSessionNoStreamingButtonText=Basic
+TraceControl_CreateSessionNoStreamingButtonTooltip=Use basic options
+TraceControl_CreateSessionTracePathText=Trace Path
+TraceControl_CreateSessionTracePathTooltip=The trace path (keep empty for default location)
+TraceControl_CreateSessionLinkButtonText=Use same protocol and address for data and control
+TraceControl_CreateSessionLinkButtonTooltip=Use the same protocol and address for the data and control connection
+TraceControl_CreateSessionProtocolLabelText=Protocol
+TraceControl_CreateSessionAddressLabelText=Address
+TraceControl_CreateSessionPortLabelText=Port
+TraceControl_CreateSessionControlUrlLabel=Control URL
+TraceControl_CreateSessionDataUrlLabel=Data URL
+TraceControl_CreateSessionCommonProtocolTooltip=file - Local file system full path\n\
+net or net6 - Default network transport layer which is TCP for both control and data channel.
+TraceControl_CreateSessionControlAddressTooltip=IP Address or DNS name used for control channel.\n\
+NOTE: IPv6 address MUST be enclosed in brackets '[]' (rfc2732)
+TraceControl_CreateSessionControlPortTooltip=The control port (default: 5342).
+TraceControl_CreateSessionProtocolTooltip=file - Local file system full path\n\
+net or net6 - Default network transport layer which is TCP\n\
+tcp or tcp6 - TCP network transport
+TraceControl_CreateSessionDataAddressTooltip=IP Address or DNS name used for data channel.\n\
+NOTE: IPv6 address MUST be enclosed in brackets '[]' (rfc2732)
+TraceControl_CreateSessionDataPortTooltip=The data port (default: 5343).
+TraceControl_CreateSessionNoConsumertText=No Consumer
+TraceControl_CreateSessionNoConsumertTooltip=Don't activate a consumer for this session.
+TraceControl_CreateSessionDisableConsumertText=Disable Consumer
+TraceControl_CreateSessionDisableConsumertTooltip=Disable consumer for this session.
+TraceControl_CreateSessionLiveConnectionLabel=Live Connection
+TraceControl_CreateSessionLiveDelayLabel=Live Delay
+TraceControl_CreateSessionLiveDelayTooltip=The delay in micro seconds before the data is flushed and streamed
+TraceControl_CreateSessionLiveConnectionUrlTooltip=The URL for the live connection (Relayd)
+TraceControl_CreateSessionLiveConnectionPortTooltip=The port for the live connection (Relayd)
+
+TraceControl_InvalidSessionNameError=The session name is invalid
+TraceControl_SessionAlreadyExistsError=The session name already exists
+TraceControl_SessionPathAlreadyExistsError=Session path already exists
+TraceControl_InvalidSessionPathError=The session path is invalid
+TraceControl_InvalidLiveDelayError=Live Delay must be a valid positive number
+TraceControl_FileSubSystemError=File subsystem error in session creation dialog.
+
+TraceControl_EnableChannelDialogTitle=Enable Channel
+TraceControl_EnableChannelNameLabel=Channel Name
+TraceControl_EnableChannelNameTooltip=The name of the channel to be enabled.
+TraceControl_EnableChannelSubBufferSizeTooltip=The sub-buffers size of the channel. Needs to be a power of 2 for kernel and ust tracers (Only for versions prior to 2.2.0).
+TraceControl_EnableChannelNbSubBuffersTooltip=The number of sub-buffers of the channel. Needs to be a power of 2 for kernel and ust tracers (Only for versions prior to 2.2.0).
+TraceControl_EnableChannelSwitchTimerTooltip=The Switch subbuffer timer interval in usec (default: 0). Needs to be a power of 2 for kernel and ust tracers (Only for versions prior to 2.2.0).
+TraceControl_EnableChannelReadTimerTooltip=The Read timer interval in usec.
+TraceControl_EnableChannelOutputTypeTooltip=The output type of the channel.
+TraceControl_EnableChannelDiscardModeGroupName=Discard Mode
+TraceControl_EnableChannelDiscardModeLabel=Discard
+TraceControl_EnableChannelDiscardModeTooltip=Discard event when subbuffers are full
+TraceControl_EnableChannelOverwriteModeLabel=Overwrite
+TraceControl_EnableChannelOverwriteModeTooltip=Flight recorder mode : overwrites events when subbuffers are full
+TraceControl_EnbleChannelMaxSizeTraceFilesTooltip=Maximum size of each tracefile within a stream (in bytes). 0 means unlimited
+TraceControl_EnbleChannelMaxNumTraceFilesTooltip=Used in conjunction with the maximum size of trace files option, this will limit the number of files created to the specified count. 0 means unlimited
+
+TraceControl_InvalidChannelNameError=The channel name is invalid or empty
+TraceControl_ChannelAlreadyExistsError=Channel already exists
+
+TraceControl_EnableEventsDialogTitle=Enable Events
+TraceControl_EnableEventsSessionGroupName=Session List
+TraceControl_EnableEventsChannelGroupName=Channel List
+TraceControl_EnableEventsSessionsTooltip=List of available sessions.
+TraceControl_EnableEventsChannelsTooltip=List of available channels of selected session.\nIf no channel is available default channel will be created.
+TraceControl_EnableEventsNoSessionError=No session from session list is selected.
+TraceControl_EnableEventsNoChannelError=No channel from channel list is selected.
+
+TraceControl_EnableGroupSelectionName=Select
+TraceControl_EnableEventsTracepointGroupName=Tracepoint Events
+TraceControl_EnableEventsTracepointTreeTooltip=List of available kernel tracepoint events
+TraceControl_EnableEventsTracepointTreeAllLabel=All
+TraceControl_EnableEventsSyscallName=All Syscalls
+TraceControl_EnableEventsSyscallTooltip=Enable all Syscalls
+TraceControl_EnableEventsProbeGroupName=Dynamic Probe
+TraceControl_EnableEventsEventNameLabel=Event Name
+TraceControl_EnableEventsProbeEventNameTooltip=The name of the event for enabling a dynamic probe
+TraceControl_EnableEventsProbeNameLabel=Probe
+TraceControl_EnableEventsProbeNameTooltip=[addr | symbol | symbol+offset]\nAddr and offset can be octal (0NNN...),\ndecimal (NNN...) or hexadecimal (0xNNN...)
+TraceControl_EnableEventsFucntionGroupName=Dynamic Function Entry/Return Probe
+TraceControl_EnableEventsFunctionEventNameTooltip=The name of the event for enabling a dynamic function entry/return probe
+TraceControl_EnableEventsFunctionNameLabel=Function
+
+TraceControl_EnableEventsWildcardGroupName=Wildcard
+TraceControl_EnableEventsWildcardLabel=Wildcard
+TraceControl_EnableEventsWildcardTooltip=The wild card string of event names
+TraceControl_EnableEventsLogLevelGroupName=Log Level
+TraceControl_EnableEventsLogLevelTypeName=loglevel
+TraceControl_EnableEventsLogLevelTypeTooltip=The tracepoint log level range from 0 to loglevel
+TraceControl_EnableEventsLogLevelOnlyTypeName=loglevel-only
+TraceControl_EnableEventsLogLevelOnlyTypeTooltip=The tracepoint log level (only this loglevel)
+TraceControl_EnableEventsLogLevelTooltip=The available log levels
+TraceControl_EnableEventsLoglevelEventNameTooltip=Event name for enabling log levels
+TraceControl_EnableEventsFilterGroupName=Filter Expression
+TraceControl_EnableEventsFilterTooltip=Filter expression on event field.
+
+TraceControl_InvalidProbeNameError=The probe name is invalid or empty 
+TraceControl_InvalidWildcardError=The wild card name is invalid or empty
+TraceControl_InvalidLogLevelEventNameError=The event name for log level is invalid or empty
+TraceControl_InvalidLogLevel=No log level selected
+
+TraceControl_AddContextDialogTitle=Add Contexts
+TraceControl_AddContextAvailableContextsLabel=Contexts
+TraceControl_AddContextAvailableContextsTooltip=Available Contexts
+TraceControl_AddContextAllLabel=All Contexts
+
+TraceControl_ImportDialogStreamedTraceNotification=You are importing a trace generated by a streamed session. By default the traces will be outputed to ~/lttng-traces/hostname/sessionname but the location can vary.
+TraceControl_ImportDialogStreamedTraceNotificationToggle=Do not warn me again
+TraceControl_ImportDialogTitle=Import Traces
+TraceControl_ImportDialogTracesGroupName=Available Traces
+TraceControl_ImportDialogTracesTooltip=The available traces of current session to import
+TraceControl_ImportDialogProjectsGroupName=Available Projects
+TraceControl_ImportDialogProjectsTooltip=The available projects to select from
+TraceControl_ImportDialogOverwriteButtonText=Overwrite existing trace without warning
+TraceControl_ImportDialogCreationError=Dialog box cannot be created
+TraceControl_ImportDialogNoProjectSelectedError=No tracing project selected or available
+TraceControl_ImportDialogInvalidTracingProject=Invalid tracing project. Missing directory
+TraceControl_ImportDialogNoTraceSelectedError=No trace selected or available
+
+TraceControl_ImportDialogConfirmationTitle=Import Confirmation Dialog
+TraceControl_ImportDialogConfirmationOverwriteLabel=Overwrite
+TraceControl_ImportDialogConfirmationRenameLabel=Rename
+TraceControl_ImportDialogConfirmationNewNameLabel=New Trace Name
+TraceControl_InvalidTraceNameError=Invalid trace name
+TraceControl_ImportDialogTraceAlreadyExistError=Trace already exists in project
+TraceControl_ImportDialog_SelectAll=Select All
+TraceControl_ImportDialog_DeselectAll=Deselect All
+
+
+# Tree structure strings
+TraceControl_KernelDomainDisplayName=Kernel
+TraceControl_JULDomainDisplayName=JUL
+TraceControl_UstGlobalDomainDisplayName=UST global
+TraceControl_UstDisplayName=UST
+TraceControl_UnknownDomainDisplayName=Unknown domain
+TraceControl_AllSessionsDisplayName=Sessions
+TraceControl_SessionDisplayName=Session
+TraceControl_DomainDisplayName=Domain
+TraceControl_BufferTypeDisplayName = Buffer Type
+TraceControl_ChannelDisplayName=Channel
+TraceControl_EventDisplayName=Event
+TraceControl_ProviderDisplayName=Provider
+TraceControl_KernelProviderDisplayName=Kernel
+TraceControl_SharedBuffersDisplayName=Global shared buffers
+TraceControl_PerPidBuffersDisplayName=Per PID buffers
+TraceControl_PerPidBuffersTooltip=Configure per PID buffers (UST only)
+TraceControl_PerUidBuffersDisplayName=Per UID buffers
+TraceControl_PerUidBuffersTooltip=Configure per UID buffers (UST only)
+
+# Property names
+TraceControl_SessionNamePropertyName=Session Name
+TraceControl_EventNamePropertyName=Event Name
+TraceControl_EventTypePropertyName=Event Type
+TraceControl_LogLevelPropertyName=Log Level
+TraceControl_FieldsPropertyName=Fields
+TraceControl_FilterPropertyName=Filter
+TraceControl_StatePropertyName=State
+TraceControl_VersionPropertyName=Version
+TraceControl_DomainNamePropertyName=Domain Name
+TraceControl_BufferTypePropertyName=Buffer type
+TraceControl_ChannelNamePropertyName=Channel Name
+TraceControl_OpenConnectionTo=Opening connection to ''{0}''
+TraceControl_OverwriteModePropertyName=Overwrite Mode
+TraceControl_SubBufferSizePropertyName=Sub Buffer Size
+TraceControl_NbSubBuffersPropertyName=Number of Sub Buffers
+TraceControl_SwitchTimerPropertyName=Switch Timer Interval
+TraceControl_ReadTimerPropertyName=Read Timer Interval
+TraceControl_OutputTypePropertyName=Output Type
+TraceControl_TraceFileCountPropertyName=Trace File Count
+TraceControl_TraceFileSizePropertyName=Trace File Size
+TraceControl_HostNamePropertyName=Connection Name
+TraceControl_HostAddressPropertyName=Host Name
+TraceControl_SessionPathPropertyName=Session Path
+TraceControl_SnapshotPathPropertyName=Snapshot Path
+TraceControl_SnapshotNamePropertyName=Snapshot Name
+TraceControl_SnapshotIdPropertyName=Snapshot ID
+TraceControl_ProviderNamePropertyName=Provider Name
+TraceControl_ProcessIdPropertyName=Process ID
+TraceControl_ProbeAddressPropertyName=Address
+TraceControl_ProbeOffsetPropertyName=Offset
+TraceControl_ProbeSymbolPropertyName=Symbol
+TraceControl_MaxSizeTraceFilesPropertyName=Maximum size of trace files
+TraceControl_MaxNumTraceFilesPropertyName=Maximum number of trace files
+TraceControl_ConfigureMetadataChannelName=Configure metadata channel
+
+# Preferences
+TraceControl_TracingGroupPreference=&Tracing Group
+TraceControl_LoggingPreference=&Logging
+TraceControl_LogfilePath=Log file
+TraceControl_AppendLogfilePreference=&Append
+TraceControl_VerboseLevelsPreference=&Verbose Level
+TraceControl_VerboseLevelNonePreference=None
+TraceControl_VerboseLevelVerbosePreference=Level 1
+TraceControl_VerboseLevelVeryVerbosePreference=Level 2
+TraceControl_VerboseLevelVeryVeryVerbosePreference=Level 3
+
+TraceControl_ExecuteScriptJob=Executing command script
+TraceControl_ExecuteScriptError=Error executing command script
+
+TraceControl_ExecuteScriptDialogTitle=Select command script
+TraceControl_ExecuteScriptBrowseText=Browse...
+TraceControl_ExecuteScriptSelectLabel=Select Script
+TraceControl_UnknownNode=<unknown>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/ITraceControlComponent.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/ITraceControlComponent.java
new file mode 100644 (file)
index 0000000..3c8fc75
--- /dev/null
@@ -0,0 +1,192 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.model;
+
+import java.util.List;
+
+import org.eclipse.core.runtime.IAdaptable;
+import org.eclipse.swt.graphics.Image;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TargetNodeState;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.service.ILttngControlService;
+
+/**
+ * <p>
+ * Interface for trace control components that can be displayed in the
+ * trace control tree viewer.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public interface ITraceControlComponent extends IAdaptable {
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    /**
+     * @return the name of the component
+     */
+    String getName();
+    /**
+     * Sets the name of the component to the given value.
+     * @param name - name to set
+     */
+    void setName(String name);
+
+    /**
+     * @return the image representing the component.
+     */
+    Image getImage();
+    /**
+     * Sets the image path of the component.
+     * @param path - path to the image location
+     */
+    void setImage(String path);
+    /**
+     * Sets the image the component.
+     * @param image - image to the image location
+     */
+    void setImage(Image image);
+
+    /**
+     * @return tool tip with information about the component.
+     */
+    String getToolTip();
+    /**
+     * Sets the tool tip with information about the component.
+     * @param toolTip - the tool tip to set.
+     */
+    void setToolTip(String toolTip);
+
+    /**
+     * @return the node's connection state
+     */
+    TargetNodeState getTargetNodeState();
+    /**
+     * Sets the node's connection state.
+     * @param state - the state to set
+     */
+    void setTargetNodeState(TargetNodeState state);
+
+    /**
+     * @return returns the parent component.
+     */
+    ITraceControlComponent getParent();
+    /**
+     * Sets the parent component.
+     * @param parent - the parent to set.
+     */
+    void setParent(ITraceControlComponent parent);
+
+    /**
+     * @return the children components
+     */
+    ITraceControlComponent[] getChildren();
+    /**
+     * Sets the children components.
+     * @param children - the children to set.
+     */
+    void setChildren(List<ITraceControlComponent> children);
+    /**
+     * Returns the child component with given name.
+     * @param name - name of child to find.
+     * @return child component or null.
+     */
+    ITraceControlComponent getChild(String name);
+    /**
+     * Gets children for given class type.
+     * @param clazz - a class type to get
+     * @return list of trace control components matching given class type.
+     */
+    List<ITraceControlComponent> getChildren(Class<? extends ITraceControlComponent> clazz);
+
+    /**
+     * @return the LTTng control service implementation.
+     */
+    ILttngControlService getControlService();
+
+    /**
+     * Sets the LTTng control service implementation.
+     * @param service - the service to set.
+     */
+    void setControlService(ILttngControlService service);
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+    /**
+     * Dispose any resource.
+     */
+    void dispose();
+
+    /**
+     * Adds a child component.
+     * @param component - child to add.
+     */
+    void addChild(ITraceControlComponent component);
+
+    /**
+     * Removes the given child component.
+     * @param component - the child to remove.
+     */
+    void removeChild(ITraceControlComponent component);
+
+    /**
+     * Removes all children.
+     */
+    void removeAllChildren();
+
+    /**
+     * Checks if child with given name exists.
+     * @param name - child name to search for.
+     * @return - true if exists else false.
+     */
+    boolean containsChild(String name);
+
+    /**
+     * Checks for children.
+     * @return true if one or more children exist else false
+     */
+    boolean hasChildren();
+
+    /**
+     * Adds a component listener for notification of component changes.
+     * @param listener - listener interface implementation to add.
+     */
+    void addComponentListener(ITraceControlComponentChangedListener listener);
+
+    /**
+     * Removes a component listener for notification of component changes.
+     * @param listener - listener interface implementation to remove.
+     */
+    void removeComponentListener(ITraceControlComponentChangedListener listener);
+
+    /**
+     * Notifies listeners about the addition of a child.
+     * @param parent - the parent where the child was added.
+     * @param component - the child that was added.
+     */
+    void fireComponentAdded(ITraceControlComponent parent, ITraceControlComponent component);
+
+    /**
+     * Notifies listeners about the removal of a child.
+     * @param parent - the parent where the child was removed.
+     * @param component - the child that was removed.
+     */
+    void fireComponentRemoved(ITraceControlComponent parent, ITraceControlComponent component);
+
+    /**
+     * Notifies listeners about the change of a component.
+     * @param component - the component that was changed.
+     */
+    void fireComponentChanged(ITraceControlComponent component);
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/ITraceControlComponentChangedListener.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/ITraceControlComponentChangedListener.java
new file mode 100644 (file)
index 0000000..385c300
--- /dev/null
@@ -0,0 +1,42 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.model;
+
+/**
+ * <p>
+ * Listener interface a class can implement to be notified about changes
+ * of components
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public interface ITraceControlComponentChangedListener {
+    /**
+     * Interface for notifications about the addition of a component.
+     * @param parent - the parent where the child was added.
+     * @param component - the child that was added.
+     */
+    void componentAdded(ITraceControlComponent parent, ITraceControlComponent component);
+
+    /**
+     * Interface for notifications about the removal of a child.
+     * @param parent - the parent where the child was removed.
+     * @param component - the child that was removed.
+     */
+    void componentRemoved(ITraceControlComponent parent, ITraceControlComponent component);
+    /**
+     * NInterface for notifications about the change of a component.
+     * @param component - the component that was changed.
+     */
+    void componentChanged(ITraceControlComponent component);
+}
+
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/BaseEventComponent.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/BaseEventComponent.java
new file mode 100644 (file)
index 0000000..71253d2
--- /dev/null
@@ -0,0 +1,165 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl;
+
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IBaseEventInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IFieldInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEventType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.EventInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.property.BaseEventPropertySource;
+import org.eclipse.ui.views.properties.IPropertySource;
+
+/**
+ * <p>
+ * Implementation of the base trace event component.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class BaseEventComponent extends TraceControlComponent {
+    // ------------------------------------------------------------------------
+    // Constants
+    // ------------------------------------------------------------------------
+    /**
+     * Path to icon file for this component.
+     */
+    public static final String TRACE_EVENT_ICON_FILE_ENABLED = "icons/obj16/event_enabled.gif"; //$NON-NLS-1$
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+    /**
+     * The Event information implementation.
+     */
+    private IBaseEventInfo fEventInfo;
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+
+    /**
+     * Constructor
+     * @param name - the name of the component.
+     * @param parent - the parent of this component.
+     */
+    public BaseEventComponent(String name, ITraceControlComponent parent) {
+        super(name, parent);
+        setImage(TRACE_EVENT_ICON_FILE_ENABLED);
+        fEventInfo = new EventInfo(name);
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+    /**
+     * Sets the event information.
+     * @param eventInfo - the event info to set.
+     */
+    public void setEventInfo(IBaseEventInfo eventInfo) {
+        fEventInfo = eventInfo;
+    }
+
+    /**
+     * @return the event type.
+     */
+    public TraceEventType getEventType() {
+        return fEventInfo.getEventType();
+    }
+
+    /**
+     * Sets the event type to the given value.
+     * @param type - type to set.
+     */
+    public void setEventType(TraceEventType type) {
+        fEventInfo.setEventType(type);
+    }
+
+    /**
+     * Sets the event type to the value specified by the give name.
+     * @param typeName - the type name.
+     */
+    public void setEventType(String typeName) {
+        fEventInfo.setEventType(typeName);
+    }
+
+    /**
+     * @return the trace event log level
+     */
+    public TraceLogLevel getLogLevel() {
+        return fEventInfo.getLogLevel();
+    }
+
+    /**
+     * Sets the trace event log level to the given level
+     * @param level - event log level to set
+     */
+    public void setLogLevel(TraceLogLevel level) {
+        fEventInfo.setLogLevel(level);
+    }
+
+    /**
+     * Sets the trace event log level to the level specified by the given name.
+     * @param levelName - event log level name
+     */
+    public void setLogLevel(String levelName) {
+        fEventInfo.setLogLevel(levelName);
+    }
+
+    /**
+     * @return a String containing pairs if field name and data type
+     */
+    public String getFieldString() {
+        IFieldInfo[] fields = fEventInfo.getFields();
+        if ((fields != null) && (fields.length > 0)) {
+            StringBuffer buffer = new StringBuffer();
+            for (int i = 0; i < fields.length; i++) {
+                buffer.append(fields[i].getName());
+                buffer.append("="); //$NON-NLS-1$
+                buffer.append(fields[i].getFieldType());
+                if (i != fields.length-1) {
+                    buffer.append(";"); //$NON-NLS-1$
+                }
+            }
+            return buffer.toString();
+        }
+        return null;
+    }
+
+    @Override
+    public Object getAdapter(Class adapter) {
+        if (adapter == IPropertySource.class) {
+            return new BaseEventPropertySource(this);
+        }
+        return null;
+    }
+
+    /**
+     * @return target node component.
+     */
+    public TargetNodeComponent getTargetNode() {
+        return (TargetNodeComponent) getParent().getParent();
+    }
+
+    /**
+     * @return if provider kernel or UST
+     */
+    public boolean isKernel() {
+        return getParent() instanceof KernelProviderComponent;
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/KernelProviderComponent.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/KernelProviderComponent.java
new file mode 100644 (file)
index 0000000..76370b5
--- /dev/null
@@ -0,0 +1,82 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl;
+
+import java.util.Iterator;
+import java.util.List;
+
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IBaseEventInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.property.KernelProviderPropertySource;
+import org.eclipse.ui.views.properties.IPropertySource;
+
+/**
+ * <p>
+ * Implementation of the Kernel provider component.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class KernelProviderComponent extends TraceControlComponent {
+
+    // ------------------------------------------------------------------------
+    // Constants
+    // ------------------------------------------------------------------------
+
+    /**
+     * Path to icon file for this component.
+     */
+    public static final String KERNEL_PROVIDER_ICON_FILE = "icons/obj16/targets.gif"; //$NON-NLS-1$
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+
+    /**
+     * Constructor
+     * @param name - the name of the component.
+     * @param parent - the parent of this component.
+     */
+    public KernelProviderComponent(String name, ITraceControlComponent parent) {
+        super(name, parent);
+        setToolTip(Messages.TraceControl_ProviderDisplayName);
+        setImage(KERNEL_PROVIDER_ICON_FILE);
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    /**
+     * Sets the events information for this component.
+     * @param eventInfos - events information to set.
+     */
+    public void setEventInfo(List<IBaseEventInfo> eventInfos) {
+        for (Iterator<IBaseEventInfo> iterator = eventInfos.iterator(); iterator.hasNext();) {
+            IBaseEventInfo baseEventInfo = iterator.next();
+            BaseEventComponent component = new BaseEventComponent(baseEventInfo.getName(), this);
+            component.setEventInfo(baseEventInfo);
+            addChild(component);
+        }
+    }
+
+    @Override
+    public Object getAdapter(Class adapter) {
+        if (adapter == IPropertySource.class) {
+            return new KernelProviderPropertySource(this);
+        }
+        return null;
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/NullControlService.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/NullControlService.java
new file mode 100644 (file)
index 0000000..bbb1af3
--- /dev/null
@@ -0,0 +1,145 @@
+/*******************************************************************************
+ * Copyright (c) 2014, 2015 Wind River Systems, Inc. and others
+ *
+ * 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:
+ *   Markus Schorn - Initial API and implementation
+ *   Bernd Hufmann - Update for null safety
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl;
+
+import static org.eclipse.tracecompass.common.core.NonNullUtils.checkNotNull;
+
+import java.util.Collections;
+import java.util.List;
+
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IBaseEventInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IChannelInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISessionInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISnapshotInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IUstProviderInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.LogLevelType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.service.ILttngControlService;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.service.LttngVersion;
+
+class NullControlService implements ILttngControlService {
+
+    @Override
+    public LttngVersion getVersion() {
+        return LttngVersion.NULL_VERSION;
+    }
+
+    @Override
+    public String getVersionString() {
+        return checkNotNull(LttngVersion.NULL_VERSION.toString());
+    }
+
+    @Override
+    public boolean isVersionSupported(String version) {
+        return false;
+    }
+
+    @Override
+    public List<String> getSessionNames(IProgressMonitor monitor) throws ExecutionException {
+        return checkNotNull(Collections.EMPTY_LIST);
+    }
+
+    @Override
+    public ISessionInfo getSession(String sessionName, IProgressMonitor monitor) throws ExecutionException {
+        return null;
+    }
+
+    @Override
+    public ISnapshotInfo getSnapshotInfo(String sessionName, IProgressMonitor monitor) throws ExecutionException {
+        return null;
+    }
+
+    @Override
+    public List<IBaseEventInfo> getKernelProvider(IProgressMonitor monitor) throws ExecutionException {
+        return checkNotNull(Collections.EMPTY_LIST);
+    }
+
+    @Override
+    public List<IUstProviderInfo> getUstProvider() throws ExecutionException {
+        return checkNotNull(Collections.EMPTY_LIST);
+    }
+
+    @Override
+    public List<IUstProviderInfo> getUstProvider(IProgressMonitor monitor) throws ExecutionException {
+        return checkNotNull(Collections.EMPTY_LIST);
+    }
+
+    @Override
+    public ISessionInfo createSession(ISessionInfo sessionInfo, IProgressMonitor monitor) throws ExecutionException {
+        return null;
+    }
+
+    @Override
+    public void destroySession(String sessionName, IProgressMonitor monitor) throws ExecutionException {
+    }
+
+    @Override
+    public void startSession(String sessionName, IProgressMonitor monitor) throws ExecutionException {
+    }
+
+    @Override
+    public void stopSession(String sessionName, IProgressMonitor monitor) throws ExecutionException {
+    }
+
+    @Override
+    public void enableChannels(String sessionName, List<String> channelNames, boolean isKernel, IChannelInfo info, IProgressMonitor monitor) throws ExecutionException {
+    }
+
+    @Override
+    public void disableChannels(String sessionName, List<String> channelNames, boolean isKernel, IProgressMonitor monitor) throws ExecutionException {
+    }
+
+    @Override
+    public void enableEvents(String sessionName, String channelName, List<String> eventNames, boolean isKernel, String filterExpression, IProgressMonitor monitor) throws ExecutionException {
+    }
+
+    @Override
+    public void enableSyscalls(String sessionName, String channelName, IProgressMonitor monitor) throws ExecutionException {
+    }
+
+    @Override
+    public void enableProbe(String sessionName, String channelName, String eventName, boolean isFunction, String probe, IProgressMonitor monitor) throws ExecutionException {
+    }
+
+    @Override
+    public void enableLogLevel(String sessionName, String channelName, String eventName, LogLevelType logLevelType, TraceLogLevel level, String filterExpression, IProgressMonitor monitor) throws ExecutionException {
+    }
+
+    @Override
+    public void disableEvent(String sessionName, String channelName, List<String> eventNames, boolean isKernel, IProgressMonitor monitor) throws ExecutionException {
+    }
+
+    @Override
+    public List<String> getContextList(IProgressMonitor monitor) throws ExecutionException {
+        return checkNotNull(Collections.EMPTY_LIST);
+    }
+
+    @Override
+    public void addContexts(String sessionName, String channelName, String eventName, boolean isKernel, List<String> contexts, IProgressMonitor monitor) throws ExecutionException {
+    }
+
+    @Override
+    public void calibrate(boolean isKernel, IProgressMonitor monitor) throws ExecutionException {
+    }
+
+    @Override
+    public void recordSnapshot(String sessionName, IProgressMonitor monitor) throws ExecutionException {
+    }
+
+    @Override
+    public void runCommands(IProgressMonitor monitor, List<String> commands) throws ExecutionException {
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TargetNodeComponent.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TargetNodeComponent.java
new file mode 100644 (file)
index 0000000..8991cde
--- /dev/null
@@ -0,0 +1,486 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2015 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
+ *   Markus Schorn - Bug 448058: Use org.eclipse.remote in favor of RSE
+ *   Bernd Hufmann - Update to org.eclipse.remote API 2.0
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl;
+
+import static java.text.MessageFormat.format;
+import static org.eclipse.tracecompass.common.core.NonNullUtils.checkNotNull;
+
+import java.util.List;
+
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.core.runtime.IStatus;
+import org.eclipse.core.runtime.Status;
+import org.eclipse.core.runtime.jobs.IJobChangeEvent;
+import org.eclipse.core.runtime.jobs.Job;
+import org.eclipse.core.runtime.jobs.JobChangeAdapter;
+import org.eclipse.jdt.annotation.NonNull;
+import org.eclipse.jface.dialogs.ErrorDialog;
+import org.eclipse.remote.core.IRemoteConnection;
+import org.eclipse.remote.core.IRemoteConnectionChangeListener;
+import org.eclipse.remote.core.RemoteConnectionChangeEvent;
+import org.eclipse.swt.graphics.Image;
+import org.eclipse.swt.widgets.Display;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TargetNodeState;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.property.TargetNodePropertySource;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.service.ILttngControlService;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.service.LTTngControlServiceFactory;
+import org.eclipse.tracecompass.tmf.remote.core.proxy.RemoteSystemProxy;
+import org.eclipse.tracecompass.tmf.remote.core.shell.ICommandShell;
+import org.eclipse.ui.PlatformUI;
+import org.eclipse.ui.views.properties.IPropertySource;
+
+/**
+ * <p>
+ * Implementation of the trace node component.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class TargetNodeComponent extends TraceControlComponent implements IRemoteConnectionChangeListener {
+
+    // ------------------------------------------------------------------------
+    // Constants
+    // ------------------------------------------------------------------------
+
+    /**
+     * Path to icon file for this component (state connected).
+     */
+    public static final String TARGET_NODE_CONNECTED_ICON_FILE = "icons/obj16/target_connected.gif"; //$NON-NLS-1$
+    /**
+     * Path to icon file for this component (state disconnected).
+     */
+    public static final String TARGET_NODE_DISCONNECTED_ICON_FILE = "icons/obj16/target_disconnected.gif"; //$NON-NLS-1$
+
+    private static final ILttngControlService NULL_CONTROL_SERVICE = new NullControlService();
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+
+    /**
+     * The node connection state.
+     */
+    private TargetNodeState fState = TargetNodeState.DISCONNECTED;
+    /**
+     * The image to be displayed in state disconnected.
+     */
+    private Image fDisconnectedImage = null;
+    /**
+     * The remote proxy implementation.
+     */
+    private @NonNull RemoteSystemProxy fRemoteProxy;
+    /**
+     * The control service for LTTng specific commands.
+     */
+    private ILttngControlService fService = null;
+    /**
+     * The command shell for issuing commands.
+     */
+    private ICommandShell fShell = null;
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+
+    /**
+     * Constructor
+     *
+     * @param name
+     *            the name of the component
+     * @param parent
+     *            the parent of the component
+     * @param proxy
+     *            the remote proxy implementation
+     */
+    public TargetNodeComponent(String name, ITraceControlComponent parent, @NonNull RemoteSystemProxy proxy) {
+        super(name, parent);
+        setImage(TARGET_NODE_CONNECTED_ICON_FILE);
+        fDisconnectedImage = Activator.getDefault().loadIcon(TARGET_NODE_DISCONNECTED_ICON_FILE);
+        fRemoteProxy = proxy;
+        fRemoteProxy.getRemoteConnection().addConnectionChangeListener(this);
+        setToolTip(fRemoteProxy.getRemoteConnection().getName());
+    }
+
+    /**
+     * Constructor (using default proxy)
+     *
+     * @param name
+     *            the name of the component
+     * @param parent
+     *            the parent of the component
+     * @param host
+     *            the host connection implementation
+     */
+    public TargetNodeComponent(String name, ITraceControlComponent parent, @NonNull IRemoteConnection host) {
+        this(name, parent, new RemoteSystemProxy(host));
+    }
+
+    @Override
+    public void dispose() {
+        fRemoteProxy.getRemoteConnection().removeConnectionChangeListener(this);
+        fRemoteProxy.dispose();
+        disposeControlService();
+    }
+
+    private void disposeControlService() {
+        fService = null;
+        final ICommandShell shell = fShell;
+        if (shell != null) {
+            shell.dispose();
+            fShell = null;
+        }
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    @Override
+    public Image getImage() {
+        if (fState == TargetNodeState.CONNECTED) {
+            return super.getImage();
+        }
+        return fDisconnectedImage;
+    }
+
+    @Override
+    public TargetNodeState getTargetNodeState() {
+        return fState;
+    }
+
+    @Override
+    public void setTargetNodeState(TargetNodeState state) {
+        fState = state;
+        fireComponentChanged(TargetNodeComponent.this);
+    }
+
+    @Override
+    public ILttngControlService getControlService() {
+        return fService == null ? NULL_CONTROL_SERVICE : fService;
+    }
+
+    @Override
+    public void setControlService(ILttngControlService service) {
+        fService = service;
+    }
+
+    @Override
+    public Object getAdapter(Class adapter) {
+        if (adapter == IPropertySource.class) {
+            return new TargetNodePropertySource(this);
+        }
+        return null;
+    }
+
+    /**
+     * @return remote system proxy implementation
+     */
+    public @NonNull RemoteSystemProxy getRemoteSystemProxy() {
+        return fRemoteProxy;
+    }
+
+    /**
+     * @return all available sessions.
+     */
+    public TraceSessionComponent[] getSessions() {
+        List<ITraceControlComponent> compenents = getChildren(TraceSessionGroup.class);
+        if (compenents.size() > 0) {
+            TraceSessionGroup group = (TraceSessionGroup)compenents.get(0);
+            List<ITraceControlComponent> sessions = group.getChildren(TraceSessionComponent.class);
+            return sessions.toArray(new TraceSessionComponent[sessions.size()]);
+        }
+        return new TraceSessionComponent[0];
+    }
+
+    /**
+     * @return node version
+     */
+    public String getNodeVersion() {
+        // Control service is null during connection to node
+        if (getControlService() != NULL_CONTROL_SERVICE) {
+            return getControlService().getVersionString();
+        }
+        return ""; //$NON-NLS-1$
+    }
+
+    /**
+     * Returns if node supports filtering of events
+     * @return <code>true</code> if node supports filtering else <code>false</code>
+     */
+    public boolean isEventFilteringSupported() {
+        return getControlService().isVersionSupported("2.1.0"); //$NON-NLS-1$
+    }
+
+    /**
+     * Returns if node supports networks streaming or not
+     * @return <code>true</code> if node supports filtering else <code>false</code>
+     *
+     */
+    public boolean isNetworkStreamingSupported() {
+        return getControlService().isVersionSupported("2.1.0"); //$NON-NLS-1$
+    }
+
+    /**
+     * Returns if node supports configuring buffer type  or not
+     * @return <code>true</code> if node supports buffer type configuration else <code>false</code>
+     */
+    public boolean isBufferTypeConfigSupported() {
+        return getControlService().isVersionSupported("2.2.0"); //$NON-NLS-1$
+    }
+
+    /**
+     * Returns if node supports trace file rotation or not
+     * @return <code>true</code> if node supports trace file rotation else <code>false</code>
+     */
+    public boolean isTraceFileRotationSupported() {
+        return getControlService().isVersionSupported("2.2.0"); //$NON-NLS-1$
+    }
+
+    /**
+     * Returns if node supports periodical flush for metadata or not
+     * @return <code>true</code> if node supports periodical flush for metadata else <code>false</code>
+     */
+    public boolean isPeriodicalMetadataFlushSupported() {
+        return getControlService().isVersionSupported("2.2.0"); //$NON-NLS-1$
+    }
+    /**
+     * Returns if node supports snapshots or not
+     * @return <code>true</code> if it supports snapshots else <code>false</code>
+     *
+     */
+    public boolean isSnapshotSupported() {
+        return getControlService().isVersionSupported("2.3.0"); //$NON-NLS-1$
+    }
+    /**
+     * Returns if node supports live or not
+     * @return <code>true</code> if it supports live else <code>false</code>
+     *
+     */
+    public boolean isLiveSupported() {
+        return getControlService().isVersionSupported("2.4.0"); //$NON-NLS-1$;
+    }
+    /**
+     * Returns if node supports adding contexts on event
+     * @return <code>true</code> if it supports adding contexts on events else <code>false</code>
+     *
+     */
+    public boolean isContextOnEventSupported() {
+        return !getControlService().isVersionSupported("2.2.0"); //$NON-NLS-1$
+    }
+
+    /**
+     * Checks if given version is supported by this ILTTngControlService implementation.
+     *
+     * @param version The version to check
+     * @return <code>true</code> if version is supported else <code>false</code>
+     */
+    public boolean isVersionSupported(String version) {
+        return getControlService().isVersionSupported(version);
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    public void connectionChanged(RemoteConnectionChangeEvent e) {
+        if (fState == TargetNodeState.CONNECTING) {
+            return;
+        }
+
+        switch (e.getType()) {
+        case RemoteConnectionChangeEvent.CONNECTION_CLOSED:
+        case RemoteConnectionChangeEvent.CONNECTION_ABORTED:
+            handleDisconnected();
+            break;
+        case RemoteConnectionChangeEvent.CONNECTION_OPENED:
+            handleConnected();
+            break;
+        default:
+            break;
+        }
+    }
+
+    /**
+     * Method to connect this node component to the remote target node.
+     */
+    public void connect() {
+        if (fState == TargetNodeState.DISCONNECTED) {
+            try {
+                setTargetNodeState(TargetNodeState.CONNECTING);
+                Job job = new Job(format(Messages.TraceControl_OpenConnectionTo, getName())) {
+                    @Override
+                    protected IStatus run(IProgressMonitor monitor) {
+                        try {
+                            fRemoteProxy.connect(checkNotNull(monitor));
+                            return Status.OK_STATUS;
+                        } catch (Exception e) {
+                            return new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.TraceControl_ConnectionFailure, e);
+                        }
+                    }
+                };
+                job.addJobChangeListener(new JobChangeAdapter() {
+                    @Override
+                    public void done(IJobChangeEvent event) {
+                        IStatus status = event.getResult();
+                        if (status.isOK()) {
+                            handleConnected();
+                        } else {
+                            handleDisconnected();
+                            if (status.getSeverity() != IStatus.CANCEL) {
+                                Activator.getDefault().getLog().log(status);
+                            }
+                        }
+                    }
+                });
+                job.schedule();
+            } catch (Exception e) {
+                setTargetNodeState(TargetNodeState.DISCONNECTED);
+                Activator.getDefault().logError(Messages.TraceControl_ConnectionFailure + " (" + getName() + "). \n", e); //$NON-NLS-1$ //$NON-NLS-2$
+            }
+        }
+    }
+
+    /**
+     * Method to disconnect this node component to the remote target node.
+     */
+    public void disconnect() {
+        if (fState == TargetNodeState.CONNECTED) {
+            try {
+                setTargetNodeState(TargetNodeState.DISCONNECTING);
+                fRemoteProxy.disconnect();
+            } catch (Exception e) {
+                Activator.getDefault().logError(Messages.TraceControl_DisconnectionFailure + " (" + getName() + "). \n", e); //$NON-NLS-1$ //$NON-NLS-2$
+            } finally {
+                handleDisconnected();
+            }
+        }
+    }
+
+    /**
+     * Retrieves the trace configuration from the target node and populates the
+     * information in the tree model. The execution is done in a own job.
+     */
+    public void getConfigurationFromNode() {
+        Job job = new Job(Messages.TraceControl_RetrieveNodeConfigurationJob) {
+            @Override
+            protected IStatus run(IProgressMonitor monitor) {
+
+                try {
+                    // Get provider information from node
+                    TraceProviderGroup providerGroup = new TraceProviderGroup(Messages.TraceControl_ProviderDisplayName, TargetNodeComponent.this);
+                    addChild(providerGroup);
+
+                    // Get session information from node
+                    TraceSessionGroup sessionGroup = new TraceSessionGroup(Messages.TraceControl_AllSessionsDisplayName, TargetNodeComponent.this);
+                    addChild(sessionGroup);
+
+                    providerGroup.getProviderFromNode(monitor);
+                    sessionGroup.getSessionsFromNode(monitor);
+                } catch (ExecutionException e) {
+                    removeAllChildren();
+                    return new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.TraceControl_RetrieveNodeConfigurationFailure, e);
+                }
+
+                return Status.OK_STATUS;
+            }
+        };
+        job.setUser(true);
+        job.schedule();
+    }
+
+    /**
+     * Refresh the node configuration
+     */
+    public void refresh() {
+        removeAllChildren();
+        getConfigurationFromNode();
+    }
+
+    // ------------------------------------------------------------------------
+    // Helper function
+    // ------------------------------------------------------------------------
+
+    /**
+     * @return returns the control service for LTTng specific commands.
+     * @throws ExecutionException
+     */
+    private ILttngControlService createControlService() throws ExecutionException {
+        if (fService == null) {
+            try {
+                ICommandShell shell = fRemoteProxy.createCommandShell();
+                fShell = shell;
+                fService = LTTngControlServiceFactory.getLttngControlService(shell);
+            } catch (ExecutionException e) {
+                disposeControlService();
+                throw e;
+            }
+        }
+        return fService;
+    }
+
+    /**
+     * Handles the connected event.
+     */
+    private void handleConnected() {
+        try {
+            createControlService();
+            getConfigurationFromNode();
+            // Set connected only after the control service has been created and the jobs for creating the
+            // sub-nodes are scheduled.
+            setTargetNodeState(TargetNodeState.CONNECTED);
+        } catch (final ExecutionException e) {
+            // Disconnect only if no control service, otherwise stay connected.
+            if (getControlService() == NULL_CONTROL_SERVICE) {
+                fState = TargetNodeState.CONNECTED;
+                disconnect();
+            }
+
+            // Notify user
+            Display.getDefault().asyncExec(new Runnable() {
+                @Override
+                public void run() {
+                    ErrorDialog er = new ErrorDialog(PlatformUI.getWorkbench().getActiveWorkbenchWindow().getShell(),
+                            Messages.TraceControl_ErrorTitle, Messages.TraceControl_RetrieveNodeConfigurationFailure,
+                            new Status(IStatus.ERROR, Activator.PLUGIN_ID, e.getMessage(), e),
+                            IStatus.ERROR);
+                    er.open();
+                }
+            });
+            Activator.getDefault().logError(Messages.TraceControl_RetrieveNodeConfigurationFailure + " (" + getName() + "). \n", e); //$NON-NLS-1$ //$NON-NLS-2$
+        }
+    }
+
+    /**
+     * Handles the disconnected event.
+     */
+    private void handleDisconnected() {
+        disposeControlService();
+        setTargetNodeState(TargetNodeState.DISCONNECTED);
+        removeAllChildren();
+    }
+
+    @Override
+    public void addChild(ITraceControlComponent component) {
+        if (getTargetNodeState() == TargetNodeState.DISCONNECTED) {
+            return;
+        }
+        super.addChild(component);
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceChannelComponent.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceChannelComponent.java
new file mode 100644 (file)
index 0000000..bfdf766
--- /dev/null
@@ -0,0 +1,400 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2015 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.swt.graphics.Image;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IChannelInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IEventInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.LogLevelType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceChannelOutputType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEnablement;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.ChannelInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.ProbeEventInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.property.TraceChannelPropertySource;
+import org.eclipse.ui.views.properties.IPropertySource;
+
+
+/**
+ * <p>
+ * Implementation of the trace channel component.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class TraceChannelComponent extends TraceControlComponent {
+
+    // ------------------------------------------------------------------------
+    // Constants
+    // ------------------------------------------------------------------------
+
+    /**
+     * Path to icon file for this component (state enabled).
+     */
+    public static final String TRACE_CHANNEL_ICON_FILE_ENABLED = "icons/obj16/channel.gif"; //$NON-NLS-1$
+    /**
+     * Path to icon file for this component (state disabled).
+     */
+    public static final String TRACE_CHANNEL_ICON_FILE_DISABLED = "icons/obj16/channel_disabled.gif"; //$NON-NLS-1$
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+
+    /**
+     * The channel information.
+     */
+    private IChannelInfo fChannelInfo = null;
+    /**
+     * The image to be displayed in disabled state.
+     */
+    private Image fDisabledImage = null;
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+
+    /**
+     * Constructor
+     * @param name - the name of the component.
+     * @param parent - the parent of this component.
+     */
+    public TraceChannelComponent(String name, ITraceControlComponent parent) {
+        super(name, parent);
+        setImage(TRACE_CHANNEL_ICON_FILE_ENABLED);
+        setToolTip(Messages.TraceControl_ChannelDisplayName);
+        fChannelInfo = new ChannelInfo(name);
+        fDisabledImage = Activator.getDefault().loadIcon(TRACE_CHANNEL_ICON_FILE_DISABLED);
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    @Override
+    public Image getImage() {
+        if (fChannelInfo.getState() == TraceEnablement.DISABLED) {
+            return fDisabledImage;
+        }
+        return super.getImage();
+    }
+
+    /**
+     * Sets the channel information.
+     *
+     * @param channelInfo
+     *            The channel info to assign to this component
+     */
+    public void setChannelInfo(IChannelInfo channelInfo) {
+        fChannelInfo = channelInfo;
+        IEventInfo[] events = fChannelInfo.getEvents();
+        List<ITraceControlComponent> eventComponents = new ArrayList<>();
+        for (int i = 0; i < events.length; i++) {
+            TraceEventComponent event = null;
+            if (events[i].getClass() == ProbeEventInfo.class) {
+                event = new TraceProbeEventComponent(events[i].getName(), this);
+            } else {
+                event = new TraceEventComponent(events[i].getName(), this);
+            }
+
+            eventComponents.add(event);
+            event.setEventInfo(events[i]);
+        }
+        if (!eventComponents.isEmpty()) {
+            setChildren(eventComponents);
+        }
+    }
+
+    /**
+     * @return the overwrite mode value.
+     */
+    public boolean isOverwriteMode() {
+        return fChannelInfo.isOverwriteMode();
+    }
+    /**
+     * Sets the overwrite mode value to the given mode.
+     * @param mode - mode to set.
+     */
+    public void setOverwriteMode(boolean mode){
+        fChannelInfo.setOverwriteMode(mode);
+    }
+    /**
+     * @return the sub-buffer size.
+     */
+    public long getSubBufferSize() {
+        return fChannelInfo.getSubBufferSize();
+    }
+    /**
+     * Sets the sub-buffer size to the given value.
+     * @param bufferSize - size to set to set.
+     */
+    public void setSubBufferSize(long bufferSize) {
+        fChannelInfo.setSubBufferSize(bufferSize);
+    }
+    /**
+     * @return the number of sub-buffers.
+     */
+    public int getNumberOfSubBuffers() {
+        return fChannelInfo.getNumberOfSubBuffers();
+    }
+    /**
+     * Sets the number of sub-buffers to the given value.
+     * @param numberOfSubBuffers - value to set.
+     */
+    public void setNumberOfSubBuffers(int numberOfSubBuffers) {
+        fChannelInfo.setNumberOfSubBuffers(numberOfSubBuffers);
+    }
+    /**
+     * @return the switch timer interval.
+     */
+    public long getSwitchTimer() {
+        return fChannelInfo.getSwitchTimer();
+    }
+    /**
+     * Sets the switch timer interval to the given value.
+     * @param timer - timer value to set.
+     */
+    public void setSwitchTimer(long timer) {
+        fChannelInfo.setSwitchTimer(timer);
+    }
+    /**
+     * @return the read timer interval.
+     */
+    public long getReadTimer() {
+        return fChannelInfo.getReadTimer();
+    }
+    /**
+     * Sets the read timer interval to the given value.
+     * @param timer - timer value to set..
+     */
+    public void setReadTimer(long timer) {
+        fChannelInfo.setReadTimer(timer);
+    }
+    /**
+     * @return the output type.
+     */
+    public TraceChannelOutputType getOutputType() {
+        return fChannelInfo.getOutputType();
+    }
+    /**
+     * Sets the output type to the given value.
+     * @param type - type to set.
+     */
+    public void setOutputType(TraceChannelOutputType type) {
+        fChannelInfo.setOutputType(type);
+    }
+    /**
+     * Sets the output type to the given value.
+     * @param type - type to set.
+     */
+    public void setOutputType(String type) {
+        fChannelInfo.setOutputType(type);
+    }
+
+    /**
+     * @return the channel state (enabled or disabled).
+     */
+    public TraceEnablement getState() {
+        return fChannelInfo.getState();
+    }
+    /**
+     * Sets the channel state (enablement) to the given value.
+     * @param state - state to set.
+     */
+    public void setState(TraceEnablement state) {
+        fChannelInfo.setState(state);
+    }
+    /**
+     * Sets the channel state (enablement) to the value specified by the given name.
+     * @param stateName - state to set.
+     */
+    public void setState(String stateName) {
+        fChannelInfo.setState(stateName);
+    }
+
+    /**
+     * @return maximum size of trace files
+     */
+    public long getMaxSizeTraceFiles() {
+        return fChannelInfo.getMaxSizeTraceFiles();
+    }
+    /**
+     * @return maximum number of trace files
+     */
+    public int getMaxNumberTraceFiles() {
+        return fChannelInfo.getMaxNumberTraceFiles();
+    }
+
+    @Override
+    public Object getAdapter(Class adapter) {
+        if (adapter == IPropertySource.class) {
+            return new TraceChannelPropertySource(this);
+        }
+        return null;
+    }
+
+    /**
+     * @return session name from parent
+     */
+    public String getSessionName() {
+       return ((TraceDomainComponent)getParent()).getSessionName();
+    }
+
+    /**
+     * @return session from parent
+     */
+    public TraceSessionComponent getSession() {
+       return ((TraceDomainComponent)getParent()).getSession();
+    }
+
+    /**
+     * @return if domain is kernel or UST
+     */
+    public boolean isKernel() {
+        return ((TraceDomainComponent)getParent()).isKernel();
+    }
+
+    /**
+     * @return the parent target node
+     */
+    public TargetNodeComponent getTargetNode() {
+        return ((TraceDomainComponent)getParent()).getTargetNode();
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    /**
+     * Enables a list of events with no additional parameters.
+     *
+     * @param eventNames
+     *            - a list of event names to enabled.
+     * @param monitor
+     *            - a progress monitor
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    public void enableEvents(List<String> eventNames, IProgressMonitor monitor) throws ExecutionException {
+        enableEvents(eventNames, null,  monitor);
+    }
+
+    /**
+     * Enables a list of events with no additional parameters.
+     *
+     * @param eventNames
+     *            - a list of event names to enabled.
+     * @param filterExpression
+     *            - a filter expression
+     * @param monitor
+     *            - a progress monitor
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    public void enableEvents(List<String> eventNames, String filterExpression, IProgressMonitor monitor) throws ExecutionException {
+        getControlService().enableEvents(getSessionName(), getName(), eventNames, isKernel(), filterExpression,  monitor);
+    }
+
+    /**
+     * Enables all syscalls (for kernel domain)
+     *
+     * @param monitor
+     *            - a progress monitor
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    public void enableSyscalls(IProgressMonitor monitor) throws ExecutionException {
+        getControlService().enableSyscalls(getSessionName(), getName(), monitor);
+    }
+
+    /**
+     * Enables a dynamic probe (for kernel domain)
+     *
+     * @param eventName
+     *            - event name for probe
+     * @param isFunction
+     *            - true for dynamic function entry/return probe else false
+     * @param probe
+     *            - the actual probe
+     * @param monitor
+     *            - a progress monitor
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    public void enableProbe(String eventName, boolean isFunction, String probe,
+            IProgressMonitor monitor) throws ExecutionException {
+        getControlService().enableProbe(getSessionName(), getName(), eventName, isFunction, probe, monitor);
+    }
+
+    /**
+     * Enables events using log level.
+     *
+     * @param eventName
+     *            - a event name
+     * @param logLevelType
+     *            - a log level type
+     * @param level
+     *            - a log level
+     * @param filterExpression
+     *            - a filter expression
+     * @param monitor
+     *            - a progress monitor
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    public void enableLogLevel(String eventName, LogLevelType logLevelType,
+            TraceLogLevel level, String filterExpression, IProgressMonitor monitor)
+            throws ExecutionException {
+        getControlService().enableLogLevel(getSessionName(), getName(), eventName, logLevelType, level, filterExpression, monitor);
+    }
+
+    /**
+     * Enables a list of events with no additional parameters.
+     *
+     * @param eventNames
+     *            - a list of event names to enabled.
+     * @param monitor
+     *            - a progress monitor
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    public void disableEvent(List<String> eventNames, IProgressMonitor monitor)
+            throws ExecutionException {
+        getControlService().disableEvent(getParent().getParent().getName(),
+                getName(), eventNames, isKernel(), monitor);
+    }
+
+    /**
+     * Add contexts to given channels and or events
+     *
+     * @param contexts
+     *            - a list of contexts to add
+     * @param monitor
+     *            - a progress monitor
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    public void addContexts(List<String> contexts, IProgressMonitor monitor)
+            throws ExecutionException {
+        getControlService().addContexts(getSessionName(), getName(), null,
+                isKernel(), contexts, monitor);
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceControlComponent.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceControlComponent.java
new file mode 100644 (file)
index 0000000..f1ddf76
--- /dev/null
@@ -0,0 +1,333 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl;
+
+import java.util.ArrayList;
+import java.util.Iterator;
+import java.util.List;
+
+import org.eclipse.core.runtime.ListenerList;
+import org.eclipse.swt.graphics.Image;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TargetNodeState;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponentChangedListener;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.service.ILttngControlService;
+
+/**
+ * <p>
+ * Base implementation for trace control component.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class TraceControlComponent implements ITraceControlComponent {
+
+    // ------------------------------------------------------------------------
+    // Constants
+    // ------------------------------------------------------------------------
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+    /**
+     * The name of the component
+     */
+    private String fName = ""; //$NON-NLS-1$
+    /**
+     * The image to be displayed for the component.
+     */
+    private Image fImage = null;
+    /**
+     * The tool tip to be displayed for the component.
+     */
+    private String fToolTip = null;
+    /**
+     * The parent component.
+     */
+    private ITraceControlComponent fParent = null;
+    /**
+     * The list if children components.
+     */
+    private final List<ITraceControlComponent> fChildren = new ArrayList<>();
+    /**
+     * The list of listeners to be notified about changes.
+     */
+    private final ListenerList fListeners = new ListenerList();
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+
+    /**
+     * Constructor
+     * @param name - the name of the component.
+     */
+    public TraceControlComponent(String name) {
+        this(name, null);
+    }
+
+    /**
+     * Constructor
+     * @param name - the name of the component.
+     * @param parent - the parent component.
+     */
+    public TraceControlComponent(String name, ITraceControlComponent parent) {
+        fName = name;
+        fParent = parent;
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    @Override
+    public String getName() {
+        return fName;
+    }
+
+    @Override
+    public void setName(String name) {
+        fName = name;
+    }
+
+    @Override
+    public Image getImage() {
+        return fImage;
+    }
+
+    @Override
+    public void setImage(String path) {
+        fImage = Activator.getDefault().loadIcon(path);
+    }
+
+    @Override
+    public void setImage(Image image) {
+        fImage = image;
+    }
+
+    @Override
+    public String getToolTip() {
+        return fToolTip;
+    }
+
+    @Override
+    public void setToolTip(String toolTip) {
+        fToolTip = toolTip;
+    }
+
+    @Override
+    public TargetNodeState getTargetNodeState() {
+        if (getParent() != null) {
+            return getParent().getTargetNodeState();
+        }
+        return TargetNodeState.DISCONNECTED;
+    }
+
+    @Override
+    public void setTargetNodeState(TargetNodeState state) {
+        if (getParent() != null) {
+            getParent().setTargetNodeState(state);
+        }
+    }
+
+    @Override
+    public ITraceControlComponent getParent() {
+        return fParent;
+    }
+
+    @Override
+    public void setParent(ITraceControlComponent parent) {
+        fParent = parent;
+    }
+
+    @Override
+    public ITraceControlComponent[] getChildren() {
+        return fChildren.toArray(new ITraceControlComponent[fChildren.size()]);
+    }
+
+    @Override
+    public void setChildren(List<ITraceControlComponent> children) {
+        for (Iterator<ITraceControlComponent> iterator = children.iterator(); iterator.hasNext();) {
+            ITraceControlComponent traceControlComponent = iterator.next();
+            fChildren.add(traceControlComponent);
+            fireComponentChanged(this);
+        }
+    }
+
+    @Override
+    public ITraceControlComponent getChild(String name) {
+        ITraceControlComponent child = null;
+        for (int i = 0; i < fChildren.size(); i++) {
+            if (fChildren.get(i).getName().equals(name)) {
+                child = fChildren.get(i);
+                break;
+            }
+        }
+        return child;
+    }
+
+    @Override
+    public List<ITraceControlComponent> getChildren(Class<? extends ITraceControlComponent> clazz) {
+       List<ITraceControlComponent> list = new ArrayList<>();
+
+       for (Iterator<ITraceControlComponent> iterator = fChildren.iterator(); iterator.hasNext();) {
+           ITraceControlComponent child = iterator.next();
+           if (child.getClass() == clazz) {
+               list.add(child);
+           }
+       }
+       return list;
+    }
+
+    @Override
+    public ILttngControlService getControlService() {
+        if (getParent() != null) {
+            return getParent().getControlService();
+        }
+        return null;
+    }
+
+    @Override
+    public void setControlService(ILttngControlService service) {
+        if (getParent() != null) {
+            getParent().setControlService(service);
+        }
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    public void dispose() {
+        // default implementation
+    }
+
+    @Override
+    public void addChild(ITraceControlComponent component) {
+        if (component != null) {
+            fChildren.add(component);
+        }
+        fireComponentAdded(this, component);
+    }
+
+    @Override
+    public void removeChild(ITraceControlComponent component) {
+        if (component != null) {
+            fChildren.remove(component);
+            component.dispose();
+        }
+        fireComponentRemoved(this, component);
+    }
+
+    @Override
+    public void removeAllChildren() {
+        for (Iterator<ITraceControlComponent> iterator = fChildren.iterator(); iterator.hasNext();) {
+            ITraceControlComponent child = iterator.next();
+            child.removeAllChildren();
+        }
+        fChildren.clear();
+//        fireCompenentChanged(this);
+    }
+
+    @Override
+    public boolean containsChild(String name) {
+        boolean retValue = false;
+        for (int i = 0; i < fChildren.size(); i++) {
+            if (fChildren.get(i).getName().equals(name)) {
+                retValue = true;
+                break;
+            }
+        }
+        return retValue;
+    }
+
+    @Override
+    public boolean hasChildren() {
+        return !fChildren.isEmpty();
+    }
+
+    @Override
+    public void addComponentListener(ITraceControlComponentChangedListener listener) {
+        if (fParent != null) {
+            fParent.addComponentListener(listener);
+        } else {
+            fListeners.add(listener);
+        }
+    }
+
+    @Override
+    public void removeComponentListener(ITraceControlComponentChangedListener listener) {
+        if (fParent != null) {
+            fParent.removeComponentListener(listener);
+        } else {
+            fListeners.remove(listener);
+        }
+    }
+
+    @Override
+    public void fireComponentAdded(ITraceControlComponent parent, ITraceControlComponent component) {
+        if (component == null) {
+            return;
+        }
+
+        if (fParent != null) {
+            fParent.fireComponentAdded(parent, component);
+        } else {
+            Object[] listeners = fListeners.getListeners();
+            for (int i = 0; i < listeners.length; i++) {
+                ITraceControlComponentChangedListener listener = (ITraceControlComponentChangedListener) listeners[i];
+                listener.componentAdded(parent, component);
+            }
+        }
+    }
+
+    @Override
+    public void fireComponentRemoved(ITraceControlComponent parent, ITraceControlComponent component) {
+        if (component == null) {
+            return;
+        }
+
+        if (fParent != null) {
+            fParent.fireComponentRemoved(parent, component);
+        } else {
+            Object[] listeners = fListeners.getListeners();
+            for (int i = 0; i < listeners.length; i++) {
+                ITraceControlComponentChangedListener listener = (ITraceControlComponentChangedListener) listeners[i];
+                listener.componentRemoved(parent, component);
+            }
+        }
+    }
+
+    @Override
+    public void fireComponentChanged(ITraceControlComponent component) {
+        if (component == null) {
+            return;
+        }
+
+        if (fParent != null) {
+            fParent.fireComponentChanged(component);
+        } else {
+            Object[] listeners = fListeners.getListeners();
+            for (int i = 0; i < listeners.length; i++) {
+                ITraceControlComponentChangedListener listener = (ITraceControlComponentChangedListener) listeners[i];
+                listener.componentChanged(component);
+            }
+        }
+    }
+
+    @Override
+    public Object getAdapter(Class adapter) {
+        return null;
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceControlContentProvider.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceControlContentProvider.java
new file mode 100644 (file)
index 0000000..db9d145
--- /dev/null
@@ -0,0 +1,68 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl;
+
+import org.eclipse.jface.viewers.ITreeContentProvider;
+import org.eclipse.jface.viewers.Viewer;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
+
+/**
+ * <p>
+ * Tree content provider implementation for trace control view.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class TraceControlContentProvider implements ITreeContentProvider {
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    public void dispose() {
+    }
+
+    @Override
+    public void inputChanged(Viewer viewer, Object oldInput, Object newInput) {
+    }
+
+    @Override
+    public Object[] getElements(Object inputElement) {
+        return getChildren(inputElement);
+    }
+
+    @Override
+    public Object[] getChildren(Object parentElement) {
+
+        if (parentElement instanceof ITraceControlComponent) {
+            return ((ITraceControlComponent)parentElement).getChildren();
+        }
+        return new Object[0];
+    }
+
+    @Override
+    public Object getParent(Object element) {
+        if (element instanceof ITraceControlComponent) {
+            return ((ITraceControlComponent)element).getParent();
+        }
+        return null;
+    }
+
+    @Override
+    public boolean hasChildren(Object element) {
+        if (element instanceof ITraceControlComponent) {
+            return ((ITraceControlComponent)element).hasChildren();
+        }
+        return false;
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceControlLabelProvider.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceControlLabelProvider.java
new file mode 100644 (file)
index 0000000..dbfceee
--- /dev/null
@@ -0,0 +1,54 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl;
+
+import org.eclipse.jface.viewers.ColumnLabelProvider;
+import org.eclipse.swt.graphics.Image;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
+
+/**
+ * <p>
+ * Label provider for trace control tree viewer.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class TraceControlLabelProvider extends ColumnLabelProvider {
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    public Image getImage(Object element) {
+        if ((element != null) && (element instanceof ITraceControlComponent)) {
+            return ((ITraceControlComponent) element).getImage();
+        }
+        return null;
+    }
+
+    @Override
+    public String getText(Object element) {
+        if ((element != null) && (element instanceof ITraceControlComponent)) {
+            return ((ITraceControlComponent) element).getName();
+        }
+        return "";//$NON-NLS-1$
+    }
+
+    @Override
+    public String getToolTipText(Object element) {
+        if ((element != null) && (element instanceof ITraceControlComponent)) {
+            return ((ITraceControlComponent) element).getToolTip();
+        }
+        return null;
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceControlPropertyTester.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceControlPropertyTester.java
new file mode 100644 (file)
index 0000000..5c38085
--- /dev/null
@@ -0,0 +1,44 @@
+/**********************************************************************
+ * Copyright (c) 2013, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl;
+
+import org.eclipse.core.expressions.PropertyTester;
+
+/**
+ *
+ * Property Tester Implementation for Trace Control Components.
+ *
+ * @author Bernd Hufmann
+ */
+public class TraceControlPropertyTester extends PropertyTester {
+
+    // ------------------------------------------------------------------------
+    // Constants
+    // ------------------------------------------------------------------------
+    private static final String ADD_CONTEXT_SUPPORT_PROPERTY = "isAddContextOnEventSupported"; //$NON-NLS-1$
+
+
+    @Override
+    public boolean test(Object receiver, String property, Object[] args, Object expectedValue) {
+
+        // Check if node supports adding contexts on event level.
+        if (ADD_CONTEXT_SUPPORT_PROPERTY.equals(property)) {
+            if ((receiver != null) && (receiver instanceof TraceEventComponent)) {
+                TraceEventComponent event = (TraceEventComponent) receiver;
+                TargetNodeComponent node = event.getTargetNode();
+                return node.isContextOnEventSupported();
+            }
+        }
+        return false;
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceControlRoot.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceControlRoot.java
new file mode 100644 (file)
index 0000000..efdda45
--- /dev/null
@@ -0,0 +1,42 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl;
+
+
+/**
+ * <p>
+ * Root element in trace control tree.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class TraceControlRoot extends TraceControlComponent {
+
+    // ------------------------------------------------------------------------
+    // Constants
+    // ------------------------------------------------------------------------
+    /**
+     * The name of the root component
+     */
+    public static final String TRACE_CONTROL_ROOT_NAME = "trace_control_root"; //$NON-NLS-1$
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+    /**
+     * Default constructor
+     */
+    public TraceControlRoot() {
+        super(TRACE_CONTROL_ROOT_NAME);
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceDomainComponent.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceDomainComponent.java
new file mode 100644 (file)
index 0000000..70cb154
--- /dev/null
@@ -0,0 +1,299 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl;
+
+import java.util.List;
+
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IChannelInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IDomainInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.LogLevelType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.BufferType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.DomainInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.property.TraceDomainPropertySource;
+import org.eclipse.ui.views.properties.IPropertySource;
+
+/**
+ * <p>
+ * Implementation of the trace domain component.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class TraceDomainComponent extends TraceControlComponent {
+    // ------------------------------------------------------------------------
+    // Constants
+    // ------------------------------------------------------------------------
+    /**
+     * Path to icon file for this component.
+     */
+    public static final String TRACE_DOMAIN_ICON_FILE = "icons/obj16/domain.gif"; //$NON-NLS-1$
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+    /**
+     * The domain information.
+     */
+    private IDomainInfo fDomainInfo = null;
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+    /**
+     * Constructor
+     * @param name - the name of the component.
+     * @param parent - the parent of this component.
+     */
+    public TraceDomainComponent(String name, ITraceControlComponent parent) {
+        super(name, parent);
+        setImage(TRACE_DOMAIN_ICON_FILE);
+        setToolTip(Messages.TraceControl_DomainDisplayName);
+        fDomainInfo = new DomainInfo(name);
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+    /**
+     * Sets the domain information.
+     * @param domainInfo - the domain information to set.
+     */
+    public void setDomainInfo(IDomainInfo domainInfo) {
+        fDomainInfo = domainInfo;
+        IChannelInfo[] channels = fDomainInfo.getChannels();
+        for (int i = 0; i < channels.length; i++) {
+            TraceChannelComponent channel = new TraceChannelComponent(channels[i].getName(), this);
+            channel.setChannelInfo(channels[i]);
+            addChild(channel);
+        }
+    }
+
+    @Override
+    public Object getAdapter(Class adapter) {
+        if (adapter == IPropertySource.class) {
+            return new TraceDomainPropertySource(this);
+        }
+        return null;
+    }
+
+    /**
+     * @return session name from parent
+     */
+    public String getSessionName() {
+        return ((TraceSessionComponent)getParent()).getName();
+    }
+
+    /**
+     * @return session from parent
+     */
+    public TraceSessionComponent getSession() {
+       return (TraceSessionComponent)getParent();
+    }
+
+    /**
+     * @return true if domain is kernel, false for UST
+     */
+    public boolean isKernel() {
+        return fDomainInfo.isKernel();
+    }
+
+    /**
+     * Sets whether domain is  Kernel domain or UST
+     * @param isKernel true for kernel, false for UST
+     */
+    public void setIsKernel(boolean isKernel) {
+        fDomainInfo.setIsKernel(isKernel);
+    }
+
+    /**
+     * @return returns all available channels for this domain.
+     */
+    public TraceChannelComponent[] getChannels() {
+        List<ITraceControlComponent> channels = getChildren(TraceChannelComponent.class);
+        return channels.toArray(new TraceChannelComponent[channels.size()]);
+    }
+
+    /**
+     * @return the parent target node
+     */
+    public TargetNodeComponent getTargetNode() {
+        return ((TraceSessionComponent)getParent()).getTargetNode();
+    }
+
+    /**
+     * @return the buffer type
+     */
+    public BufferType getBufferType(){
+        return fDomainInfo.getBufferType();
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    /**
+     * Retrieves the session configuration from the node.
+     *
+     * @param monitor
+     *            - a progress monitor
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    public void getConfigurationFromNode(IProgressMonitor monitor) throws ExecutionException {
+        TraceSessionComponent session = (TraceSessionComponent) getParent();
+        session.getConfigurationFromNode(monitor);
+    }
+
+    /**
+     * Enables channels with given names which are part of this domain. If a
+     * given channel doesn't exists it creates a new channel with the given
+     * parameters (or default values if given parameter is null).
+     *
+     * @param channelNames
+     *            - a list of channel names to enable on this domain
+     * @param info
+     *            - channel information to set for the channel (use null for
+     *            default)
+     * @param monitor
+     *            - a progress monitor
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    public void enableChannels(List<String> channelNames, IChannelInfo info,
+            IProgressMonitor monitor) throws ExecutionException {
+        getControlService().enableChannels(getParent().getName(), channelNames,
+                isKernel(), info, monitor);
+    }
+
+    /**
+     * Disables channels with given names which are part of this domain.
+     *
+     * @param channelNames
+     *            - a list of channel names to enable on this domain
+     * @param monitor
+     *            - a progress monitor
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    public void disableChannels(List<String> channelNames,
+            IProgressMonitor monitor) throws ExecutionException {
+        getControlService().disableChannels(getParent().getName(),
+                channelNames, isKernel(), monitor);
+    }
+
+    /**
+     * Enables a list of events with no additional parameters.
+     *
+     * @param eventNames
+     *            - a list of event names to enabled.
+     * @param monitor
+     *            - a progress monitor
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    public void enableEvents(List<String> eventNames, IProgressMonitor monitor)
+            throws ExecutionException {
+        getControlService().enableEvents(getSessionName(), null, eventNames,
+                isKernel(), null, monitor);
+    }
+
+    /**
+     * Enables all syscalls (for kernel domain)
+     *
+     * @param monitor
+     *            - a progress monitor
+     * @throws ExecutionException
+     *             If the command fails
+     */
+
+    public void enableSyscalls(IProgressMonitor monitor)
+            throws ExecutionException {
+        getControlService().enableSyscalls(getSessionName(), null, monitor);
+    }
+
+    /**
+     * Enables a dynamic probe (for kernel domain)
+     *
+     * @param eventName
+     *            - event name for probe
+     * @param isFunction
+     *            - true for dynamic function entry/return probe else false
+     * @param probe
+     *            - the actual probe
+     * @param monitor
+     *            - a progress monitor
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    public void enableProbe(String eventName, boolean isFunction, String probe,
+            IProgressMonitor monitor) throws ExecutionException {
+        getControlService().enableProbe(getSessionName(), null, eventName,
+                isFunction, probe, monitor);
+    }
+
+    /**
+     * Enables events using log level.
+     *
+     * @param eventName
+     *            - a event name
+     * @param logLevelType
+     *            - a log level type
+     * @param level
+     *            - a log level
+     * @param filterExpression
+     *            - a filter expression
+     * @param monitor
+     *            - a progress monitor
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    public void enableLogLevel(String eventName, LogLevelType logLevelType,
+            TraceLogLevel level, String filterExpression, IProgressMonitor monitor)
+            throws ExecutionException {
+        getControlService().enableLogLevel(getSessionName(), null, eventName,
+                logLevelType, level, filterExpression, monitor);
+    }
+
+    /**
+     * Add contexts to given channels and or events
+     *
+     * @param contexts
+     *            - a list of contexts to add
+     * @param monitor
+     *            - a progress monitor
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    public void addContexts(List<String> contexts, IProgressMonitor monitor)
+            throws ExecutionException {
+        getControlService().addContexts(getSessionName(), null, null,
+                isKernel(), contexts, monitor);
+    }
+
+    /**
+     * Executes calibrate command to quantify LTTng overhead.
+     *
+     * @param monitor
+     *            - a progress monitor
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    public void calibrate(IProgressMonitor monitor) throws ExecutionException {
+        getControlService().calibrate(isKernel(), monitor);
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceEventComponent.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceEventComponent.java
new file mode 100644 (file)
index 0000000..c38c3d9
--- /dev/null
@@ -0,0 +1,264 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl;
+
+import java.util.List;
+
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.swt.graphics.Image;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IEventInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.LogLevelType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEnablement;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEventType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.EventInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.property.TraceEventPropertySource;
+import org.eclipse.ui.views.properties.IPropertySource;
+
+
+/**
+ * <p>
+ * Implementation of the trace channel component.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class TraceEventComponent extends TraceControlComponent {
+    // ------------------------------------------------------------------------
+    // Constants
+    // ------------------------------------------------------------------------
+    /**
+     * Path to icon file for this component (enabled state).
+     */
+    public static final String TRACE_EVENT_ICON_FILE_ENABLED = "icons/obj16/event_enabled.gif"; //$NON-NLS-1$
+    /**
+     * Path to icon file for this component (disabled state).
+     */
+    public static final String TRACE_EVENT_ICON_FILE_DISABLED = "icons/obj16/event_disabled.gif"; //$NON-NLS-1$
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+    /**
+     * The event information.
+     */
+    protected IEventInfo fEventInfo = null;
+    /**
+     * The image to be displayed when in disabled state.
+     */
+    private Image fDisabledImage = null;
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+    /**
+     * Constructor
+     * @param name - the name of the component.
+     * @param parent - the parent of this component.
+     */
+    public TraceEventComponent(String name, ITraceControlComponent parent) {
+        super(name, parent);
+        setImage(TRACE_EVENT_ICON_FILE_ENABLED);
+        setToolTip(Messages.TraceControl_EventDisplayName);
+        fEventInfo = new EventInfo(name);
+        fDisabledImage = Activator.getDefault().loadIcon(TRACE_EVENT_ICON_FILE_DISABLED);
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    @Override
+    public Image getImage() {
+        if (fEventInfo.getState() == TraceEnablement.DISABLED) {
+            return fDisabledImage;
+        }
+        return super.getImage();
+    }
+
+    /**
+     * Sets the event information.
+     * @param eventInfo - the event information to set.
+     */
+    public void setEventInfo(IEventInfo eventInfo) {
+        fEventInfo = eventInfo;
+    }
+
+    /**
+     * @return the trace event type
+     */
+    public TraceEventType getEventType() {
+        return fEventInfo.getEventType();
+    }
+
+    /**
+     * Sets the trace event type to the given type
+     * @param type - type to set
+     */
+    public void setEventType(TraceEventType type) {
+        fEventInfo.setEventType(type);
+    }
+
+    /**
+     * Sets the trace event type to the type specified by the given name.
+     * @param typeName - event type name
+     */
+    public void setEventType(String typeName) {
+        fEventInfo.setEventType(typeName);
+    }
+
+    /**
+     * @return the event state (enabled or disabled).
+     */
+    public TraceEnablement getState() {
+        return fEventInfo.getState();
+    }
+
+    /**
+     * Sets the event state (enablement) to the given value.
+     * @param state - state to set.
+     */
+    public void setState(TraceEnablement state) {
+        fEventInfo.setState(state);
+    }
+
+    /**
+     * Sets the event state (enablement) to the value specified by the given name.
+     * @param stateName - state to set.
+     */
+    public void setState(String stateName) {
+        fEventInfo.setState(stateName);
+    }
+
+    /**
+     * @return the trace event log level
+     */
+    public TraceLogLevel getLogLevel() {
+        return fEventInfo.getLogLevel();
+    }
+
+    /**
+     * Sets the trace event log level to the given level
+     * @param level - event log level to set
+     */
+    public void setLogLevel(TraceLogLevel level) {
+        fEventInfo.setLogLevel(level);
+    }
+
+    /**
+     * Sets the trace event log level to the level specified by the given name.
+     * @param levelName - event log level name
+     */
+    public void setLogLevel(String levelName) {
+        fEventInfo.setLogLevel(levelName);
+    }
+
+    /**
+     * Returns filter expression.
+     * @return filter expression
+     */
+    public String getFilterExpression() {
+        return fEventInfo.getFilterExpression();
+    }
+
+    /**
+     * Sets the filter expression.
+     * @param filter The filter expression to set
+     */
+    public void setFilterExpression(String filter) {
+        fEventInfo.setFilterExpression(filter);
+    }
+
+    /**
+     * Returns the log level type
+     * @return event log level type
+     */
+    public LogLevelType getLogLevelType() {
+        return fEventInfo.getLogLevelType();
+    }
+
+    /**
+     * Sets the trace event log level type to the given level type
+     * @param levelType - event log level type to set
+     */
+    public void setLogLevelType(LogLevelType levelType) {
+        fEventInfo.setLogLevelType(levelType);
+    }
+
+    @Override
+    public Object getAdapter(Class adapter) {
+        if (adapter == IPropertySource.class) {
+            return new TraceEventPropertySource(this);
+        }
+        return null;
+    }
+
+    /**
+     * @return target node component.
+     */
+    public TargetNodeComponent getTargetNode() {
+        return ((TraceChannelComponent)getParent()).getTargetNode();
+    }
+
+    /**
+     * @return session name from parent
+     */
+    public String getSessionName() {
+       return ((TraceChannelComponent)getParent()).getSessionName();
+    }
+
+    /**
+     * @return session from parent
+     */
+    public TraceSessionComponent getSession() {
+       return ((TraceChannelComponent)getParent()).getSession();
+    }
+
+    /**
+     * @return channel name from parent
+     */
+    public String getChannelName() {
+        return getParent().getName();
+    }
+
+    /**
+     * @return if domain is kernel or UST
+     */
+    public boolean isKernel() {
+        return ((TraceChannelComponent)getParent()).isKernel();
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    /**
+     * Add contexts to given channels and or events
+     *
+     * @param contexts
+     *            - a list of contexts to add
+     * @param monitor
+     *            - a progress monitor
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    public void addContexts(List<String> contexts, IProgressMonitor monitor)
+            throws ExecutionException {
+        getControlService().addContexts(getSessionName(), getChannelName(),
+                getName(), isKernel(), contexts, monitor);
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceProbeEventComponent.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceProbeEventComponent.java
new file mode 100644 (file)
index 0000000..1ad0685
--- /dev/null
@@ -0,0 +1,121 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl;
+
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IEventInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.ProbeEventInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.property.TraceProbeEventPropertySource;
+import org.eclipse.ui.views.properties.IPropertySource;
+
+
+/**
+ * <p>
+ * Implementation of the trace channel component.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class TraceProbeEventComponent extends TraceEventComponent {
+    // ------------------------------------------------------------------------
+    // Constants
+    // ------------------------------------------------------------------------
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+    /**
+     * Constructor
+     * @param name - the name of the component.
+     * @param parent - the parent of this component.
+     */
+    public TraceProbeEventComponent(String name, ITraceControlComponent parent) {
+        super(name, parent);
+        fEventInfo = new ProbeEventInfo(name);
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    /**
+     * Sets the event information.
+     * @param eventInfo - the event information to set.
+     */
+    @Override
+    public void setEventInfo(IEventInfo eventInfo) {
+        if (eventInfo instanceof ProbeEventInfo) {
+            fEventInfo = eventInfo;
+            return;
+        }
+        throw new IllegalArgumentException("Invalid type passed. Only class of type ProbeEventInfo allowed:\n" + eventInfo.getClass()); //$NON-NLS-1$
+    }
+
+    @Override
+    public Object getAdapter(Class adapter) {
+        if (adapter == IPropertySource.class) {
+            return new TraceProbeEventPropertySource(this);
+        }
+        return null;
+    }
+    /**
+     * @return the address of the probe. (null if Symbol is used)
+     */
+    public String getAddress() {
+        return getEventInfo().getAddress();
+    }
+    /**
+     * Sets the address of the probe.
+     * @param address - a address
+     */
+    public void setAddress(String address) {
+        getEventInfo().setAddress(address);
+    }
+    /**
+     * @return the offset applied to the symbol.
+     */
+    public String getOffset() {
+        return getEventInfo().getOffset();
+    }
+    /**
+     * Sets the offset applied to the symbol. (valid if symbol is used)
+     * @param offset - a offset
+     */
+    public void setOffset(String offset) {
+        getEventInfo().setOffset(offset);
+    }
+    /**
+     * @return the symbol name. (null if address is used)
+     */
+    public String getSymbol() {
+        return getEventInfo().getSymbol();
+    }
+    /**
+     * Sets the symbol name.
+     * @param symbol - a symbol name (null if address is used)
+     */
+    public void setSymbol(String symbol) {
+        getEventInfo().setSymbol(symbol);
+    }
+
+    // ------------------------------------------------------------------------
+    // Helper methods
+    // ------------------------------------------------------------------------
+    private ProbeEventInfo getEventInfo() {
+        return (ProbeEventInfo) fEventInfo;
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceProviderGroup.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceProviderGroup.java
new file mode 100644 (file)
index 0000000..83659bd
--- /dev/null
@@ -0,0 +1,108 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl;
+
+import java.util.Iterator;
+import java.util.List;
+
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IBaseEventInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IUstProviderInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
+
+/**
+ * <p>
+ * Implementation of the trace provider group.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class TraceProviderGroup extends TraceControlComponent {
+    // ------------------------------------------------------------------------
+    // Constants
+    // ------------------------------------------------------------------------
+    /**
+     * Path to icon file for this component.
+     */
+    public static final String TRACE_PROVIDERS_ICON_FILE = "icons/obj16/providers.gif"; //$NON-NLS-1$
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+    /**
+     * Constructor
+     * @param name - the name of the component.
+     * @param parent - the parent of this component.
+     */
+    public TraceProviderGroup(String name, ITraceControlComponent parent) {
+        super(name, parent);
+        setImage(TRACE_PROVIDERS_ICON_FILE);
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    /**
+     * Gets the provider information from the target node.
+     * @param monitor - a progress monitor
+     * @throws ExecutionException If the command fails
+     */
+    public void getProviderFromNode(IProgressMonitor monitor) throws ExecutionException {
+
+        List<IBaseEventInfo> eventInfos = getControlService().getKernelProvider(monitor);
+
+        if (!eventInfos.isEmpty()) {
+            KernelProviderComponent component = new KernelProviderComponent(Messages.TraceControl_KernelProviderDisplayName, this);
+            addChild(component);
+            component.setEventInfo(eventInfos);
+        }
+
+        List<IUstProviderInfo> allProviders = getControlService().getUstProvider(monitor);
+
+        for (Iterator<IUstProviderInfo> iterator = allProviders.iterator(); iterator.hasNext();) {
+            IUstProviderInfo ustProviderInfo = iterator.next();
+            UstProviderComponent ustComponent = new UstProviderComponent(ustProviderInfo.getName(), this);
+            addChild(ustComponent);
+            ustComponent.setUstProvider(ustProviderInfo);
+        }
+    }
+
+    /**
+     * Returns whether the kernel provider is available or not
+     * @return <code>true</code> if kernel provide is available or <code>false</code>
+     */
+    public boolean hasKernelProvider() {
+        List<ITraceControlComponent> kernelList = getChildren(KernelProviderComponent.class);
+        return !kernelList.isEmpty();
+    }
+
+    /**
+     * Returns if node supports filtering of events
+     * @return <code>true</code> if node supports filtering else <code>false</code>
+     */
+    public boolean isEventFilteringSupported() {
+        return ((TargetNodeComponent)getParent()).isEventFilteringSupported();
+    }
+}
+
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceSessionComponent.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceSessionComponent.java
new file mode 100644 (file)
index 0000000..5a6fa47
--- /dev/null
@@ -0,0 +1,478 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
+ *   Marc-Andre Laperle - Support for opening a live session
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl;
+
+import java.util.List;
+
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.swt.graphics.Image;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IChannelInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IDomainInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISessionInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISnapshotInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.LogLevelType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.SessionInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.property.TraceSessionPropertySource;
+import org.eclipse.ui.views.properties.IPropertySource;
+
+/**
+ * <p>
+ * Implementation of the trace session component.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class TraceSessionComponent extends TraceControlComponent {
+
+    // ------------------------------------------------------------------------
+    // Constants
+    // ------------------------------------------------------------------------
+    /**
+     * Path to icon file for this component (inactive state).
+     */
+    public static final String TRACE_SESSION_ICON_FILE_INACTIVE = "icons/obj16/session_inactive.gif"; //$NON-NLS-1$
+    /**
+     * Path to icon file for this component (active state).
+     */
+    public static final String TRACE_SESSION_ICON_FILE_ACTIVE = "icons/obj16/session_active.gif"; //$NON-NLS-1$
+    /**
+     * Path to icon file for this component (destroyed state).
+     */
+    public static final String TRACE_SESSION_ICON_FILE_DESTROYED = "icons/obj16/session_destroyed.gif"; //$NON-NLS-1$
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+    /**
+     * The session information.
+     */
+    private ISessionInfo fSessionInfo = null;
+    /**
+     * A flag to indicate if session has been destroyed.
+     */
+    private boolean fIsDestroyed = false;
+    /**
+     * The image to be displayed in state active.
+     */
+    private Image fActiveImage = null;
+    /**
+     * The image to be displayed in state destroyed
+     */
+    private Image fDestroyedImage = null;
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+    /**
+     * Constructor
+     * @param name - the name of the component.
+     * @param parent - the parent of this component.
+     */
+    public TraceSessionComponent(String name, ITraceControlComponent parent) {
+        super(name, parent);
+        setImage(TRACE_SESSION_ICON_FILE_INACTIVE);
+        setToolTip(Messages.TraceControl_SessionDisplayName);
+        fSessionInfo = new SessionInfo(name);
+        fActiveImage = Activator.getDefault().loadIcon(TRACE_SESSION_ICON_FILE_ACTIVE);
+        fDestroyedImage = Activator.getDefault().loadIcon(TRACE_SESSION_ICON_FILE_DESTROYED);
+    }
+
+    /**
+     * Constructor
+     *
+     * @param sessionInfo
+     *            the session information used to create the session
+     * @param parent
+     *            the parent of this component.
+     */
+    public TraceSessionComponent(ISessionInfo sessionInfo, ITraceControlComponent parent) {
+        this(sessionInfo.getName(), parent);
+        copyLiveInfo(sessionInfo);
+    }
+
+    private void copyLiveInfo(ISessionInfo sessionInfo) {
+        // Since we can't retrieve this information from the node, we copy it over
+        if (sessionInfo.getLivePort() != null) {
+            fSessionInfo.setLivePort(sessionInfo.getLivePort());
+        }
+        if (sessionInfo.getLiveUrl() != null) {
+            fSessionInfo.setLiveUrl(sessionInfo.getLiveUrl());
+        }
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    @Override
+    public Image getImage() {
+        if (fIsDestroyed) {
+            return fDestroyedImage;
+        }
+
+        if (fSessionInfo.getSessionState() == TraceSessionState.INACTIVE) {
+            return super.getImage();
+        }
+
+        return fActiveImage;
+    }
+
+    /**
+     * @return the whether the session is destroyed or not.
+     */
+    public boolean isDestroyed() {
+        return fIsDestroyed;
+    }
+
+    /**
+     * Sets the session destroyed state to the given value.
+     * @param destroyed - value to set.
+     */
+    public void setDestroyed(boolean destroyed) {
+        fIsDestroyed = destroyed;
+    }
+
+    /**
+     * @return the session state state (active or inactive).
+     */
+    public TraceSessionState getSessionState() {
+        return fSessionInfo.getSessionState();
+    }
+
+    /**
+     * Sets the session state  to the given value.
+     * @param state - state to set.
+     */
+    public void setSessionState(TraceSessionState state) {
+        fSessionInfo.setSessionState(state);
+    }
+
+    /**
+     * Sets the event state to the value specified by the given name.
+     * @param stateName - state to set.
+     */
+    public void setSessionState(String stateName) {
+        fSessionInfo.setSessionState(stateName);
+    }
+
+    /**
+     * @return path string where session is located.
+     */
+    public String getSessionPath() {
+        return fSessionInfo.getSessionPath();
+    }
+
+    /**
+     * Sets the path string (where session is located) to the given value.
+     * @param sessionPath - session path to set.
+     */
+    public void setSessionPath(String sessionPath) {
+        fSessionInfo.setSessionPath(sessionPath);
+    }
+
+    /**
+     * Returns if session is streamed over network
+     * @return <code>true</code> if streamed over network else <code>false</code>
+     */
+    public boolean isStreamedTrace() {
+        return fSessionInfo.isStreamedTrace();
+    }
+
+    /**
+     * Sets whether the trace is streamed or not
+     * @param isStreamedTrace <code>true</code> if streamed over network else <code>false</code>
+     */
+    public void setIsStreamedTrace(boolean isStreamedTrace) {
+        fSessionInfo.setStreamedTrace(isStreamedTrace);
+    }
+
+    /**
+     * Returns whether the session is snapshot session or not
+     * @return <code>true</code> if it is snapshot session else <code>false</code>
+     */
+    public boolean isSnapshotSession() {
+        return fSessionInfo.isSnapshotSession();
+    }
+
+    /**
+     * Gets the snapshot information if available whether the session is a snapshot session or not
+     * @return the snapshot information or null if it is not a snapshot session
+     */
+    public ISnapshotInfo getSnapshotInfo() {
+        return fSessionInfo.getSnapshotInfo();
+    }
+
+    @Override
+    public Object getAdapter(Class adapter) {
+        if (adapter == IPropertySource.class) {
+            return new TraceSessionPropertySource(this);
+        }
+        return null;
+    }
+
+    /**
+     * @return all available domains of this session.
+     */
+    public TraceDomainComponent[] getDomains() {
+        List<ITraceControlComponent> sessions = getChildren(TraceDomainComponent.class);
+        return sessions.toArray(new TraceDomainComponent[sessions.size()]);
+    }
+
+    /**
+     * @return the parent target node
+     */
+    public TargetNodeComponent getTargetNode() {
+        return ((TraceSessionGroup)getParent()).getTargetNode();
+    }
+
+    /**
+     * Returns whether the kernel provider is available or not
+     * @return <code>true</code> if kernel provide is available or <code>false</code>
+     */
+    public boolean hasKernelProvider() {
+        List<ITraceControlComponent> providerGroups = getTargetNode().getChildren(TraceProviderGroup.class);
+        return (!providerGroups.isEmpty() ? ((TraceProviderGroup) providerGroups.get(0)).hasKernelProvider() : false);
+    }
+
+    /**
+     * Returns if node supports filtering of events
+     * @return <code>true</code> if node supports filtering else <code>false</code>
+     */
+    public boolean isEventFilteringSupported() {
+        return ((TargetNodeComponent)getParent().getParent()).isEventFilteringSupported();
+    }
+
+    /**
+     * Returns if node supports snapshots or not
+     * @return <code>true</code> if it supports snapshots else <code>false</code>
+     *
+     */
+    public boolean isSnapshotSupported() {
+        return ((TargetNodeComponent)getParent().getParent()).isSnapshotSupported();
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    /**
+     * Retrieves the session configuration from the node.
+     *
+     * @param monitor
+     *            - a progress monitor
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    public void getConfigurationFromNode(IProgressMonitor monitor)
+            throws ExecutionException {
+        removeAllChildren();
+        ISessionInfo newInfo = getControlService().getSession(getName(), monitor);
+        if (newInfo != null) {
+            ISessionInfo oldSessionInfo = fSessionInfo;
+            fSessionInfo = newInfo;
+            copyLiveInfo(oldSessionInfo);
+
+            IDomainInfo[] domains = fSessionInfo.getDomains();
+            for (int i = 0; i < domains.length; i++) {
+                TraceDomainComponent domainComponent = new TraceDomainComponent(
+                        domains[i].getName(), this);
+                addChild(domainComponent);
+                domainComponent.setDomainInfo(domains[i]);
+            }
+        }
+    }
+
+    /**
+     * Starts the session.
+     *
+     * @param monitor
+     *            - a progress monitor
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    public void startSession(IProgressMonitor monitor)
+            throws ExecutionException {
+        getControlService().startSession(getName(), monitor);
+    }
+
+    /**
+     * Starts the session.
+     *
+     * @param monitor
+     *            - a progress monitor
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    public void stopSession(IProgressMonitor monitor) throws ExecutionException {
+        getControlService().stopSession(getName(), monitor);
+    }
+
+    /**
+     * Enables channels with given names which are part of this domain. If a
+     * given channel doesn't exists it creates a new channel with the given
+     * parameters (or default values if given parameter is null).
+     *
+     * @param channelNames
+     *            - a list of channel names to enable on this domain
+     * @param info
+     *            - channel information to set for the channel (use null for
+     *            default)
+     * @param isKernel
+     *            - a flag for indicating kernel or UST.
+     * @param monitor
+     *            - a progress monitor
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    public void enableChannels(List<String> channelNames, IChannelInfo info,
+            boolean isKernel, IProgressMonitor monitor)
+            throws ExecutionException {
+        getControlService().enableChannels(getName(), channelNames, isKernel,
+                info, monitor);
+    }
+
+    /**
+     * Enables a list of events with no additional parameters.
+     *
+     * @param eventNames
+     *            - a list of event names to enabled.
+     * @param isKernel
+     *            - a flag for indicating kernel or UST.
+     * @param filterExpression
+     *            - a filter expression
+     * @param monitor
+     *            - a progress monitor
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    public void enableEvents(List<String> eventNames, boolean isKernel,
+            String filterExpression, IProgressMonitor monitor) throws ExecutionException {
+        getControlService().enableEvents(getName(), null, eventNames, isKernel,
+                filterExpression, monitor);
+    }
+
+    /**
+     * Enables all syscalls (for kernel domain)
+     *
+     * @param monitor
+     *            - a progress monitor
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    public void enableSyscalls(IProgressMonitor monitor)
+            throws ExecutionException {
+        getControlService().enableSyscalls(getName(), null, monitor);
+    }
+
+    /**
+     * Enables a dynamic probe (for kernel domain)
+     *
+     * @param eventName
+     *            - event name for probe
+     * @param isFunction
+     *            - true for dynamic function entry/return probe else false
+     * @param probe
+     *            - the actual probe
+     * @param monitor
+     *            - a progress monitor
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    public void enableProbe(String eventName, boolean isFunction, String probe,
+            IProgressMonitor monitor) throws ExecutionException {
+        getControlService().enableProbe(getName(), null, eventName, isFunction,
+                probe, monitor);
+    }
+
+    /**
+     * Enables events using log level.
+     *
+     * @param eventName
+     *            - a event name
+     * @param logLevelType
+     *            - a log level type
+     * @param level
+     *            - a log level
+     * @param filterExpression
+     *            - a filter expression
+     * @param monitor
+     *            - a progress monitor
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    public void enableLogLevel(String eventName, LogLevelType logLevelType,
+            TraceLogLevel level, String filterExpression, IProgressMonitor monitor)
+            throws ExecutionException {
+        getControlService().enableLogLevel(getName(), null, eventName,
+                logLevelType, level, null, monitor);
+    }
+
+    /**
+     * Gets all available contexts to be added to channels/events.
+     *
+     * @param monitor
+     *            The monitor that will indicate the progress
+     * @return the list of available contexts
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    public List<String> getContextList(IProgressMonitor monitor)
+            throws ExecutionException {
+        return getControlService().getContextList(monitor);
+    }
+
+    /**
+     * Records a snapshot.
+     *
+     * @param monitor
+     *            - a progress monitor
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    public void recordSnapshot(IProgressMonitor monitor) throws ExecutionException {
+        getControlService().recordSnapshot(getName(), monitor);
+    }
+
+    /**
+     * Returns if session is live.
+     * @return <code>true</code> if session if live else <code>false</code>
+     */
+    public boolean isLiveTrace() {
+        return fSessionInfo.isLive();
+    }
+
+    /**
+     * Get the live URL.
+     *
+     * @return the live URL
+     */
+    public String getLiveUrl() {
+        return fSessionInfo.getLiveUrl();
+    }
+
+    /**
+     * Get the live port.
+     *
+     * @return the live port
+     */
+    public Integer getLivePort() {
+        return fSessionInfo.getLivePort();
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceSessionGroup.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceSessionGroup.java
new file mode 100644 (file)
index 0000000..ca91f58
--- /dev/null
@@ -0,0 +1,174 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl;
+
+import java.util.List;
+
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.core.runtime.NullProgressMonitor;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISessionInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
+
+/**
+ * <p>
+ * Implementation of the trace session group.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class TraceSessionGroup extends TraceControlComponent {
+    // ------------------------------------------------------------------------
+    // Constants
+    // ------------------------------------------------------------------------
+    /**
+     * Path to icon file for this component.
+     */
+    public static final String TRACE_SESSIONS_ICON_FILE = "icons/obj16/sessions.gif"; //$NON-NLS-1$
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+    /**
+     * Constructor
+     * @param name - the name of the component.
+     * @param parent - the parent of this component.
+     */
+    public TraceSessionGroup(String name, ITraceControlComponent parent) {
+        super(name, parent);
+        setImage(TRACE_SESSIONS_ICON_FILE);
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    /**
+     * @return the parent target node
+     */
+    public TargetNodeComponent getTargetNode() {
+        return (TargetNodeComponent)getParent();
+    }
+
+    /**
+     * Returns if node supports networks streaming or not
+     * @return <code>true</code> if node supports filtering else <code>false</code>
+     */
+    public boolean isNetworkStreamingSupported() {
+        return getTargetNode().isNetworkStreamingSupported();
+    }
+    /**
+     * Returns if node supports snapshots or not
+     * @return <code>true</code> if it supports snapshots else <code>false</code>
+     *
+     */    public boolean isSnapshotSupported() {
+        return getTargetNode().isSnapshotSupported();
+    }
+
+    /**
+     * Returns if node supports live or not
+     *
+     * @return <code>true</code> if it supports live else <code>false</code>
+     */
+    public boolean isLiveSupported() {
+        return getTargetNode().isLiveSupported();
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+    /**
+     * Retrieves the sessions information from the node.
+     *
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    public void getSessionsFromNode() throws ExecutionException {
+        getSessionsFromNode(new NullProgressMonitor());
+    }
+
+    /**
+     * Retrieves the sessions information from the node.
+     *
+     * @param monitor
+     *            - a progress monitor
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    public void getSessionsFromNode(IProgressMonitor monitor)
+            throws ExecutionException {
+        List<String> sessionNames = getControlService().getSessionNames(monitor);
+        for (String sessionName : sessionNames) {
+            TraceSessionComponent session =
+                    new TraceSessionComponent(sessionName, this);
+            addChild(session);
+            session.getConfigurationFromNode(monitor);
+        }
+    }
+
+    /**
+     * Creates a session with given session name and location.
+     *
+     * @param sessionInf
+     *            the session information used to create the session
+     *
+     * @param monitor
+     *            - a progress monitor
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    public void createSession(ISessionInfo sessionInf, IProgressMonitor monitor) throws ExecutionException {
+        ISessionInfo sessionInfo = getControlService().createSession(sessionInf, monitor);
+
+        if (sessionInfo != null) {
+            TraceSessionComponent session = new TraceSessionComponent(sessionInfo, TraceSessionGroup.this);
+            addChild(session);
+            session.getConfigurationFromNode(monitor);
+        }
+    }
+
+    /**
+     * Command to execute a list of commands
+     * @param monitor
+     *            - a progress monitor
+     * @param commands
+     *            - a list of commands to execute
+     * @throws ExecutionException
+     *            If the command fails
+     */
+    public void executeCommands(IProgressMonitor monitor, List<String> commands) throws ExecutionException {
+        getControlService().runCommands(monitor, commands);
+        getTargetNode().refresh();
+    }
+
+    /**
+     * Destroys a session with given session name.
+     *
+     * @param session
+     *            - a session component to destroy
+     * @param monitor
+     *            - a progress monitor
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    public void destroySession(TraceSessionComponent session,
+            IProgressMonitor monitor) throws ExecutionException {
+        getControlService().destroySession(session.getName(), monitor);
+        session.removeAllChildren();
+        removeChild(session);
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/UstProviderComponent.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/UstProviderComponent.java
new file mode 100644 (file)
index 0000000..0d167ea
--- /dev/null
@@ -0,0 +1,104 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl;
+
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IBaseEventInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IUstProviderInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.UstProviderInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.property.UstProviderPropertySource;
+import org.eclipse.ui.views.properties.IPropertySource;
+
+/**
+ * <p>
+ * Implementation of the UST provider component.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class UstProviderComponent extends TraceControlComponent {
+
+    // ------------------------------------------------------------------------
+    // Constants
+    // ------------------------------------------------------------------------
+    /**
+     * Path to icon file for this component.
+     */
+    public static final String USTL_PROVIDER_ICON_FILE = "icons/obj16/targets.gif"; //$NON-NLS-1$
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+    /**
+     * The UST provider information.
+     */
+    private IUstProviderInfo fProviderInfo = null;
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+    /**
+     * Constructor
+     * @param name - the name of the component.
+     * @param parent - the parent of this component.
+     */
+    public UstProviderComponent(String name, ITraceControlComponent parent) {
+        super(name, parent);
+        setImage(USTL_PROVIDER_ICON_FILE);
+        setToolTip(Messages.TraceControl_ProviderDisplayName);
+        fProviderInfo = new UstProviderInfo(name);
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+    /**
+     * Sets the UST provider information to the given value.
+     * @param providerInfo - the provider information to set
+     */
+    public void setUstProvider(IUstProviderInfo providerInfo) {
+        fProviderInfo = providerInfo;
+        IBaseEventInfo[] events = providerInfo.getEvents();
+        for (int i = 0; i < events.length; i++) {
+            BaseEventComponent component  = new BaseEventComponent(events[i].getName(), this);
+            component.setEventInfo(events[i]);
+            addChild(component);
+        }
+        setName(getName() + " [PID=" + fProviderInfo.getPid() + "]"); //$NON-NLS-1$ //$NON-NLS-2$
+    }
+
+    /**
+     * @return the process ID of the UST provider.
+     */
+    public int getPid() {
+        return fProviderInfo.getPid();
+    }
+
+    /**
+     * Sets the process ID of the UST provider to the given value.
+     * @param pid - process ID to set
+     */
+    public void setPid(int pid) {
+        fProviderInfo.setPid(pid);
+    }
+
+    @Override
+    public Object getAdapter(Class adapter) {
+        if (adapter == IPropertySource.class) {
+            return new UstProviderPropertySource(this);
+        }
+        return null;
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/preferences/ControlPreferenceInitializer.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/preferences/ControlPreferenceInitializer.java
new file mode 100644 (file)
index 0000000..9ad4333
--- /dev/null
@@ -0,0 +1,37 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.preferences;
+
+import org.eclipse.core.runtime.preferences.AbstractPreferenceInitializer;
+import org.eclipse.jface.preference.IPreferenceStore;
+
+/**
+ * <p>
+ * A class to initialize the preferences.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class ControlPreferenceInitializer extends AbstractPreferenceInitializer {
+
+    @Override
+    public void initializeDefaultPreferences() {
+        final IPreferenceStore store = ControlPreferences.getInstance().getPreferenceStore();
+
+        //Set default User ID if none already stored in preferences
+        store.setDefault(ControlPreferences.TRACE_CONTROL_TRACING_GROUP_PREF, ControlPreferences.TRACE_CONTROL_DEFAULT_TRACING_GROUP);
+        store.setDefault(ControlPreferences.TRACE_CONTROL_LOG_APPEND_PREF, false);
+        store.setDefault(ControlPreferences.TRACE_CONTROL_LOG_FILE_PATH_PREF, ControlPreferences.TRACE_CONTROL_DEFAULT_LOG_PATH);
+        store.setDefault(ControlPreferences.TRACE_CONTROL_LOG_COMMANDS_PREF, false);
+        store.setDefault(ControlPreferences.TRACE_CONTROL_VERBOSE_LEVEL_PREF, ControlPreferences.TRACE_CONTROL_VERBOSE_LEVEL_NONE);
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/preferences/ControlPreferencePage.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/preferences/ControlPreferencePage.java
new file mode 100644 (file)
index 0000000..d587382
--- /dev/null
@@ -0,0 +1,147 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.preferences;
+
+import org.eclipse.jface.preference.BooleanFieldEditor;
+import org.eclipse.jface.preference.FieldEditor;
+import org.eclipse.jface.preference.FieldEditorPreferencePage;
+import org.eclipse.jface.preference.IPreferenceStore;
+import org.eclipse.jface.preference.RadioGroupFieldEditor;
+import org.eclipse.jface.preference.StringFieldEditor;
+import org.eclipse.jface.util.PropertyChangeEvent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.logging.ControlCommandLogger;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
+import org.eclipse.ui.IWorkbench;
+import org.eclipse.ui.IWorkbenchPreferencePage;
+
+/**
+ * <p>
+ * Preference page implementation for configuring LTTng tracer control preferences.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class ControlPreferencePage extends FieldEditorPreferencePage implements IWorkbenchPreferencePage {
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+    private RadioGroupFieldEditor fVerboseLevel;
+    private BooleanFieldEditor  fIsAppend;
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+
+    /**
+     * Constructor
+     */
+    public ControlPreferencePage() {
+        super(FieldEditorPreferencePage.GRID);
+
+        // Set the preference store for the preference page.
+        IPreferenceStore store = ControlPreferences.getInstance().getPreferenceStore();
+        setPreferenceStore(store);
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    public void init(IWorkbench workbench) {
+    }
+
+    @Override
+    protected void createFieldEditors() {
+
+        StringFieldEditor tracingGroup = new StringFieldEditor(ControlPreferences.TRACE_CONTROL_TRACING_GROUP_PREF, Messages.TraceControl_TracingGroupPreference, getFieldEditorParent());
+        addField(tracingGroup);
+
+        BooleanFieldEditor logCommand = new BooleanFieldEditor(ControlPreferences.TRACE_CONTROL_LOG_COMMANDS_PREF, Messages.TraceControl_LoggingPreference, getFieldEditorParent());
+        addField(logCommand);
+
+        StringFieldEditor logfile = new StringFieldEditor(ControlPreferences.TRACE_CONTROL_LOG_FILE_PATH_PREF, Messages.TraceControl_LogfilePath, getFieldEditorParent());
+        addField(logfile);
+
+        fIsAppend = new BooleanFieldEditor(ControlPreferences.TRACE_CONTROL_LOG_APPEND_PREF, Messages.TraceControl_AppendLogfilePreference, getFieldEditorParent());
+        addField(fIsAppend);
+
+        fVerboseLevel = new RadioGroupFieldEditor (
+                ControlPreferences.TRACE_CONTROL_VERBOSE_LEVEL_PREF,
+                Messages.TraceControl_VerboseLevelsPreference,
+                4,
+                new String[][] {
+                    {
+                        Messages.TraceControl_VerboseLevelNonePreference,
+                        ControlPreferences.TRACE_CONTROL_VERBOSE_LEVEL_NONE,
+                    },
+                    {
+                        Messages.TraceControl_VerboseLevelVerbosePreference,
+                        ControlPreferences.TRACE_CONTROL_VERBOSE_LEVEL_VERBOSE
+                    },
+                    {
+                        Messages.TraceControl_VerboseLevelVeryVerbosePreference,
+                        ControlPreferences.TRACE_CONTROL_VERBOSE_LEVEL_V_VERBOSE
+                    },
+                    {
+                        Messages.TraceControl_VerboseLevelVeryVeryVerbosePreference,
+                        ControlPreferences.TRACE_CONTROL_VERBOSE_LEVEL_V_V_VERBOSE
+                    }
+                },
+                getFieldEditorParent(),
+                true);
+
+        addField(fVerboseLevel);
+
+        Boolean enabled = ControlPreferences.getInstance().isLoggingEnabled();
+        fVerboseLevel.setEnabled(enabled, getFieldEditorParent());
+        fIsAppend.setEnabled(enabled, getFieldEditorParent());
+        logfile.setEnabled(false, getFieldEditorParent());
+
+    }
+
+    @Override
+    public void propertyChange(PropertyChangeEvent event) {
+
+        if (event.getProperty().equals(FieldEditor.VALUE)) {
+            if (event.getSource() instanceof FieldEditor) {
+                FieldEditor editor = (FieldEditor) event.getSource();
+                if (editor.getPreferenceName().equals(ControlPreferences.TRACE_CONTROL_LOG_COMMANDS_PREF)) {
+                    Boolean enabled = (Boolean)event.getNewValue();
+                    fVerboseLevel.setEnabled(enabled, getFieldEditorParent());
+                    fIsAppend.setEnabled(enabled, getFieldEditorParent());
+                }
+            }
+        }
+        super.propertyChange(event);
+    }
+
+    @Override
+    protected void performDefaults() {
+        super.performDefaults();
+        fVerboseLevel.setEnabled(false, getFieldEditorParent());
+        fIsAppend.setEnabled(false, getFieldEditorParent());
+    }
+
+    @Override
+    public boolean performOk() {
+        boolean ret =  super.performOk();
+        // open or close log file
+        if (ControlPreferences.getInstance().isLoggingEnabled()) {
+            ControlCommandLogger.init(ControlPreferences.getInstance().getLogfilePath(), ControlPreferences.getInstance().isAppend());
+        } else {
+            ControlCommandLogger.close();
+        }
+        return ret;
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/preferences/ControlPreferences.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/preferences/ControlPreferences.java
new file mode 100644 (file)
index 0000000..9d88d22
--- /dev/null
@@ -0,0 +1,203 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.preferences;
+
+import java.io.File;
+
+import org.eclipse.jface.preference.IPreferenceStore;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.logging.ControlCommandLogger;
+
+/**
+ * <p>
+ * Singleton class to access LTTng tracer control preferences.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class ControlPreferences {
+
+    // ------------------------------------------------------------------------
+    // Constants
+    // ------------------------------------------------------------------------
+    /**
+     * Trace control log file
+     */
+    public static final String TRACE_CONTROL_LOG_FILENAME = "lttng_tracer_control.log"; //$NON-NLS-1$
+
+    // Preference strings
+    /**
+     * The tracing group preference
+     */
+    public static final String TRACE_CONTROL_TRACING_GROUP_PREF = "trace.control.tracing.group"; //$NON-NLS-1$
+    /**
+     * The log commands preference
+     */
+    public static final String TRACE_CONTROL_LOG_COMMANDS_PREF = "trace.control.log.commands"; //$NON-NLS-1$
+    /**
+     * The log append preference
+     */
+    public static final String TRACE_CONTROL_LOG_APPEND_PREF = "trace.control.log.append"; //$NON-NLS-1$
+    /**
+     * The log file path preference
+     */
+    public static final String TRACE_CONTROL_LOG_FILE_PATH_PREF = "trace.control.log.path"; //$NON-NLS-1$
+    /**
+     * The verbose level preference
+     */
+    public static final String TRACE_CONTROL_VERBOSE_LEVEL_PREF = "trace.control.verbose.level"; //$NON-NLS-1$
+    /**
+     * The verbose level value for none
+     */
+    public static final String TRACE_CONTROL_VERBOSE_LEVEL_NONE = "trace.control.verbose.level.none"; //$NON-NLS-1$
+    /**
+     * The verbose level value for level 1 (-v)
+     */
+    public static final String TRACE_CONTROL_VERBOSE_LEVEL_VERBOSE = "trace.control.verbose.level.v"; //$NON-NLS-1$
+    /**
+     * The verbose level value for level 2 (-vv)
+     */
+    public static final String TRACE_CONTROL_VERBOSE_LEVEL_V_VERBOSE = "trace.control.verbose.level.vv"; //$NON-NLS-1$
+    /**
+     * The verbose level value for level 3 (-vvv)
+     */
+    public static final String TRACE_CONTROL_VERBOSE_LEVEL_V_V_VERBOSE = "trace.control.verbose.level.vvv"; //$NON-NLS-1$
+    /**
+     * The default tracing group
+     */
+    public static final String TRACE_CONTROL_DEFAULT_TRACING_GROUP = "tracing"; //$NON-NLS-1$
+    /**
+     * The default tracing log file name with absolute path
+     */
+    public static final String TRACE_CONTROL_DEFAULT_LOG_PATH = System.getProperty("user.home") + File.separator + TRACE_CONTROL_LOG_FILENAME; //$NON-NLS-1$
+    /**
+     * Default timeout value used for executing commands, in seconds
+     */
+    public static final int TRACE_CONTROL_DEFAULT_TIMEOUT_VALUE = 15;
+    /**
+     * Minimum timeout value used for executing commands, in seconds
+     */
+    public static final int TRACE_CONTROL_MIN_TIMEOUT_VALUE = 5;
+    /**
+     * Maximum timeout value used for executing commands, in seconds
+     */
+    public static final int TRACE_CONTROL_MAX_TIMEOUT_VALUE = 600;
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+    /**
+     * The trace control preferences singleton instance.
+     */
+    private static ControlPreferences fInstance = null;
+    /**
+     * The preference store reference
+     */
+    private IPreferenceStore fPreferenceStore = null;
+
+    // ------------------------------------------------------------------------
+    // Constructor
+    // ------------------------------------------------------------------------
+    /**
+     * Private constructor
+     */
+    private ControlPreferences() {
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+    /**
+     * Returns the trace control preferences singleton instance
+     *
+     * @return the trace control preferences singleton instance
+     */
+    public static synchronized ControlPreferences getInstance() {
+        if (fInstance == null) {
+            fInstance = new ControlPreferences();
+        }
+        return fInstance;
+    }
+
+    /**
+     * @return the preference store
+     */
+    public IPreferenceStore getPreferenceStore() {
+        return fPreferenceStore;
+    }
+
+    /**
+     * @return true if tracing group is set to default
+     */
+    public boolean isDefaultTracingGroup() {
+        return fPreferenceStore.getString(TRACE_CONTROL_TRACING_GROUP_PREF).equals(fPreferenceStore.getDefaultString(TRACE_CONTROL_TRACING_GROUP_PREF));
+    }
+
+    /**
+     * @return value of tracing group preference
+     */
+    public String getTracingGroup() {
+        return fPreferenceStore.getString(TRACE_CONTROL_TRACING_GROUP_PREF);
+    }
+
+    /**
+     * @return whether is logging is enabled
+     */
+    public boolean isLoggingEnabled() {
+        return fPreferenceStore.getBoolean(TRACE_CONTROL_LOG_COMMANDS_PREF);
+    }
+
+    /**
+     * @return whether an existing log file will appended or not
+     */
+    public boolean isAppend() {
+        return fPreferenceStore.getBoolean(ControlPreferences.TRACE_CONTROL_LOG_APPEND_PREF);
+    }
+
+    /**
+     * @return verbose level preference
+     */
+    public String getVerboseLevel() {
+        return fPreferenceStore.getString(TRACE_CONTROL_VERBOSE_LEVEL_PREF);
+    }
+
+    /**
+     * @return absolute log file path
+     */
+    public String getLogfilePath() {
+        return fPreferenceStore.getString(TRACE_CONTROL_LOG_FILE_PATH_PREF);
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    /**
+     * Initializes the control preferences (e.g. enable open log file)
+     *
+     * @param preferenceStore
+     *            The preference store to assign
+     */
+    public void init(IPreferenceStore preferenceStore) {
+        fPreferenceStore = preferenceStore;
+
+        if (fPreferenceStore.getBoolean(ControlPreferences.TRACE_CONTROL_LOG_COMMANDS_PREF)) {
+            ControlCommandLogger.init(getLogfilePath(), isAppend());
+        }
+    }
+
+    /**
+     * Disposes any resource (e.g. close log file).
+     */
+    public void dispose() {
+        ControlCommandLogger.close();
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/BaseEventPropertySource.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/BaseEventPropertySource.java
new file mode 100644 (file)
index 0000000..8e2ba7a
--- /dev/null
@@ -0,0 +1,124 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *     Bernd Hufmann - Initial API and implementation
+ *     Bernd Hufmann - Updated for support of LTTng Tools 2.1
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.property;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.BaseEventComponent;
+import org.eclipse.tracecompass.tmf.ui.properties.ReadOnlyTextPropertyDescriptor;
+import org.eclipse.ui.views.properties.IPropertyDescriptor;
+
+/**
+ * <p>
+ * Property source implementation for the base event component.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class BaseEventPropertySource extends BasePropertySource {
+
+    // ------------------------------------------------------------------------
+    // Constants
+    // ------------------------------------------------------------------------
+
+    /**
+     * The base event 'name' property ID.
+     */
+    public static final String BASE_EVENT_NAME_PROPERTY_ID = "base.event.name"; //$NON-NLS-1$
+    /**
+     * The base event 'type' property ID.
+     */
+    public static final String BASE_EVENT_TYPE_PROPERTY_ID = "base.event.type"; //$NON-NLS-1$
+    /**
+     * The base event 'log level' property ID.
+     */
+    public static final String BASE_EVENT_LOGLEVEL_PROPERTY_ID = "base.event.loglevel"; //$NON-NLS-1$
+    /**
+     * The base event 'fields' property ID.
+     */
+    public static final String BASE_EVENT_FIELDS_PROPERTY_ID = "base.event.fields"; //$NON-NLS-1$
+    /**
+     *  The base event 'name' property name.
+     */
+    public static final String BASE_EVENT_NAME_PROPERTY_NAME = Messages.TraceControl_EventNamePropertyName;
+    /**
+     * The base event 'type' property name.
+     */
+    public static final String BASE_EVENT_TYPE_PROPERTY_NAME = Messages.TraceControl_EventTypePropertyName;
+    /**
+     * The base event 'log level' property name.
+     */
+    public static final String BASE_EVENT_LOGLEVEL_PROPERTY_NAME = Messages.TraceControl_LogLevelPropertyName;
+    /**
+     * The base event 'fields' property name.
+     */
+    public static final String BASE_EVENT_FIELDS_PROPERTY_NAME = Messages.TraceControl_FieldsPropertyName;
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+    /**
+     * The base event component which this property source is for.
+     */
+    private final BaseEventComponent fBaseEvent;
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+    /**
+     * Constructor
+     * @param component - the base event component
+     */
+    public BaseEventPropertySource(BaseEventComponent component) {
+        fBaseEvent = component;
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    public IPropertyDescriptor[] getPropertyDescriptors() {
+        List<IPropertyDescriptor> list = new ArrayList<> ();
+        list.add(new ReadOnlyTextPropertyDescriptor(BASE_EVENT_NAME_PROPERTY_ID, BASE_EVENT_NAME_PROPERTY_NAME));
+        list.add(new ReadOnlyTextPropertyDescriptor(BASE_EVENT_TYPE_PROPERTY_ID, BASE_EVENT_TYPE_PROPERTY_NAME));
+        if (fBaseEvent.getLogLevel() != TraceLogLevel.LEVEL_UNKNOWN) {
+            list.add(new ReadOnlyTextPropertyDescriptor(BASE_EVENT_LOGLEVEL_PROPERTY_ID, BASE_EVENT_LOGLEVEL_PROPERTY_NAME));
+        }
+        if (fBaseEvent.getFieldString() != null) {
+            list.add(new ReadOnlyTextPropertyDescriptor(BASE_EVENT_FIELDS_PROPERTY_ID, BASE_EVENT_FIELDS_PROPERTY_NAME));
+        }
+        return list.toArray(new IPropertyDescriptor[list.size()]);
+    }
+
+    @Override
+    public Object getPropertyValue(Object id) {
+        if(BASE_EVENT_NAME_PROPERTY_ID.equals(id)) {
+            return fBaseEvent.getName();
+        }
+        if (BASE_EVENT_TYPE_PROPERTY_ID.equals(id)) {
+            return fBaseEvent.getEventType().name();
+        }
+        if (BASE_EVENT_LOGLEVEL_PROPERTY_ID.equals(id)) {
+            return fBaseEvent.getLogLevel().name();
+        }
+        if (BASE_EVENT_FIELDS_PROPERTY_ID.equals(id)) {
+            return fBaseEvent.getFieldString();
+        }
+        return null;
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/BasePropertySource.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/BasePropertySource.java
new file mode 100644 (file)
index 0000000..5670b82
--- /dev/null
@@ -0,0 +1,53 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.property;
+
+import org.eclipse.ui.views.properties.IPropertyDescriptor;
+import org.eclipse.ui.views.properties.IPropertySource;
+
+/**
+ * <p>
+ * Base property source implementation.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public abstract class BasePropertySource implements IPropertySource {
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    public Object getEditableValue() {
+        return null;
+    }
+
+    @Override
+    public abstract IPropertyDescriptor[] getPropertyDescriptors();
+
+    @Override
+    public abstract Object getPropertyValue(Object id);
+
+    @Override
+    public boolean isPropertySet(Object id) {
+        return false;
+    }
+
+    @Override
+    public void resetPropertyValue(Object id) {
+    }
+
+    @Override
+    public void setPropertyValue(Object id, Object value) {
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/KernelProviderPropertySource.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/KernelProviderPropertySource.java
new file mode 100644 (file)
index 0000000..254ec6f
--- /dev/null
@@ -0,0 +1,80 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *     Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.property;
+
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.KernelProviderComponent;
+import org.eclipse.tracecompass.tmf.ui.properties.ReadOnlyTextPropertyDescriptor;
+import org.eclipse.ui.views.properties.IPropertyDescriptor;
+
+/**
+ * <p>
+ * Property source implementation for the kernl provider component.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class KernelProviderPropertySource extends BasePropertySource {
+
+    // ------------------------------------------------------------------------
+    // Constants
+    // ------------------------------------------------------------------------
+
+    /**
+     * The kernel provider 'name' property ID.
+     */
+    public static final String KERNEL_PROVIDER_NAME_PROPERTY_ID = "ust.provider.name"; //$NON-NLS-1$
+    /**
+     *  The kernel provider 'name' property name.
+     */
+    public static final String KERNEL_PROVIDER_NAME_PROPERTY_NAME = Messages.TraceControl_ProviderNamePropertyName;
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+
+    /**
+     * The kernel provider component which this property source is for.
+     */
+    private KernelProviderComponent fProvider;
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+
+    /**
+     * Constructor
+     * @param component - the kernel provider component
+     */
+    public KernelProviderPropertySource(KernelProviderComponent component) {
+        fProvider = component;
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    public IPropertyDescriptor[] getPropertyDescriptors() {
+        return new IPropertyDescriptor[] {
+                new ReadOnlyTextPropertyDescriptor(KERNEL_PROVIDER_NAME_PROPERTY_ID, KERNEL_PROVIDER_NAME_PROPERTY_NAME)};
+    }
+
+    @Override
+    public Object getPropertyValue(Object id) {
+        if(KERNEL_PROVIDER_NAME_PROPERTY_ID.equals(id)) {
+            return fProvider.getName();
+        }
+        return null;
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/TargetNodePropertySource.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/TargetNodePropertySource.java
new file mode 100644 (file)
index 0000000..b2850d6
--- /dev/null
@@ -0,0 +1,126 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2015 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Markus Schorn - Bug 448058: Use org.eclipse.remote in favor of RSE
+ *   Bernd Hufmann - Update to org.eclipse.remote API 2.0
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.property;
+
+import org.eclipse.remote.core.IRemoteConnectionHostService;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent;
+import org.eclipse.tracecompass.tmf.remote.core.proxy.RemoteSystemProxy;
+import org.eclipse.tracecompass.tmf.ui.properties.ReadOnlyTextPropertyDescriptor;
+import org.eclipse.ui.views.properties.IPropertyDescriptor;
+
+/**
+ * <p>
+ * Property source implementation for the target node component.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class TargetNodePropertySource extends BasePropertySource {
+
+    // ------------------------------------------------------------------------
+    // Constants
+    // ------------------------------------------------------------------------
+    /**
+     * The node name property ID.
+     */
+    public static final String TARGET_NODE_NAME_PROPERTY_ID = "target.node.name"; //$NON-NLS-1$
+    /**
+     * The node address property ID.
+     */
+    public static final String TARGET_NODE_ADDRESS_PROPERTY_ID = "target.node.address"; //$NON-NLS-1$
+    /**
+     * The state property ID.
+     */
+    public static final String TARGET_NODE_STATE_PROPERTY_ID = "target.node.state"; //$NON-NLS-1$
+    /**
+     * The node version property ID.
+     */
+    public static final String TARGET_NODE_VERSION_PROPERTY_ID = "target.node.version"; //$NON-NLS-1$
+
+    /**
+     *  The node name property name.
+     */
+    public static final String TARGET_NODE_NAME_PROPERTY_NAME = Messages.TraceControl_HostNamePropertyName;
+    /**
+     * The node address property name.
+     */
+    public static final String TARGET_NODE_ADDRESS_PROPERTY_NAME = Messages.TraceControl_HostAddressPropertyName;
+    /**
+     * The state address property name.
+     */
+    public static final String TARGET_NODE_STATE_PROPERTY_NAME = Messages.TraceControl_StatePropertyName;
+    /**
+     * The node version property name.
+     */
+    public static final String TARGET_NODE_VERSION_PROPERTY_NAME = Messages.TraceControl_VersionPropertyName;
+
+    /**
+     * The name of the address for local host
+     */
+    private static final String LOCAL_CONNECTION_HOST_NAME = "localhost"; //$NON-NLS-1$
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+    /**
+     * The node component which this property source is for.
+     */
+    private final TargetNodeComponent fTargetNode;
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+    /**
+     * Constructor
+     * @param component - the node component
+     */
+    public TargetNodePropertySource(TargetNodeComponent component) {
+        fTargetNode = component;
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    public IPropertyDescriptor[] getPropertyDescriptors() {
+        return new IPropertyDescriptor[] {
+                new ReadOnlyTextPropertyDescriptor(TARGET_NODE_NAME_PROPERTY_ID, TARGET_NODE_NAME_PROPERTY_NAME),
+                new ReadOnlyTextPropertyDescriptor(TARGET_NODE_ADDRESS_PROPERTY_ID, TARGET_NODE_ADDRESS_PROPERTY_NAME),
+                new ReadOnlyTextPropertyDescriptor(TARGET_NODE_STATE_PROPERTY_ID, TARGET_NODE_STATE_PROPERTY_NAME),
+                new ReadOnlyTextPropertyDescriptor(TARGET_NODE_VERSION_PROPERTY_ID, TARGET_NODE_VERSION_PROPERTY_NAME)};
+    }
+
+    @Override
+    public Object getPropertyValue(Object id) {
+        if(TARGET_NODE_NAME_PROPERTY_ID.equals(id)) {
+            return fTargetNode.getName();
+        }
+        if (TARGET_NODE_ADDRESS_PROPERTY_ID.equals(id)) {
+            RemoteSystemProxy proxy = fTargetNode.getRemoteSystemProxy();
+            if (proxy.getRemoteConnection().hasService(IRemoteConnectionHostService.class)) {
+                return proxy.getRemoteConnection().getService(IRemoteConnectionHostService.class).getHostname();
+            }
+            return LOCAL_CONNECTION_HOST_NAME;
+        }
+        if (TARGET_NODE_STATE_PROPERTY_ID.equals(id)) {
+            return fTargetNode.getTargetNodeState().name();
+        }
+        if (TARGET_NODE_VERSION_PROPERTY_ID.equals(id)) {
+            return fTargetNode.getNodeVersion();
+        }
+        return null;
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/TraceChannelPropertySource.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/TraceChannelPropertySource.java
new file mode 100644 (file)
index 0000000..786c1ce
--- /dev/null
@@ -0,0 +1,191 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2015 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:
+ *     Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.property;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent;
+import org.eclipse.tracecompass.tmf.ui.properties.ReadOnlyTextPropertyDescriptor;
+import org.eclipse.ui.views.properties.IPropertyDescriptor;
+
+/**
+ * <p>
+ * Property source implementation for the trace channel component.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class TraceChannelPropertySource extends BasePropertySource {
+
+    // ------------------------------------------------------------------------
+    // Constants
+    // ------------------------------------------------------------------------
+    /**
+     * The trace channel 'name' property ID.
+     */
+    public static final String TRACE_CHANNEL_NAME_PROPERTY_ID = "trace.channel.name"; //$NON-NLS-1$
+    /**
+     * The trace channel 'state' ID.
+     */
+    public static final String TRACE_CHANNEL_STATE_PROPERTY_ID = "trace.channel.state"; //$NON-NLS-1$
+    /**
+     * The trace channel 'overwrite mode' property ID.
+     */
+    public static final String TRACE_CHANNEL_OVERWRITE_MODE_PROPERTY_ID = "trace.channel.overwrite.mode"; //$NON-NLS-1$
+    /**
+     * The trace channel 'sub-buffer size' property ID.
+     */
+    public static final String TRACE_CHANNEL_SUBBUFFER_SIZE_PROPERTY_ID = "trace.channel.subbuffer.size"; //$NON-NLS-1$
+    /**
+     * The trace channel 'number of sub-buffers' property ID.
+     */
+    public static final String TRACE_CHANNEL_NO_SUBBUFFERS_PROPERTY_ID = "trace.channel.no.subbuffers"; //$NON-NLS-1$
+    /**
+     * The trace channel 'switch timer interval' property ID.
+     */
+    public static final String TRACE_CHANNEL_SWITCH_TIMER_PROPERTY_ID = "trace.channel.switch.timer"; //$NON-NLS-1$
+    /**
+     * The trace channel 'read timer interval' property ID.
+     */
+    public static final String TRACE_CHANNEL_READ_TIMER_PROPERTY_ID = "trace.channel.read.timer"; //$NON-NLS-1$
+    /**
+     * The trace channel 'output type' property ID.
+     */
+    public static final String TRACE_CHANNEL_OUTPUT_TYPE_PROPERTY_ID = "trace.channel.output.type"; //$NON-NLS-1$
+    /**
+     * The trace channel 'trace file count' property ID.
+     */
+    public static final String TRACE_CHANNEL_TRACE_FILE_COUNT_PROPERTY_ID = "trace.channel.trace.file.count"; //$NON-NLS-1$
+    /**
+     * The trace channel 'trace file size' property ID.
+     */
+    public static final String TRACE_CHANNEL_TRACE_FILE_SIZE_PROPERTY_ID = "trace.channel.trace.file.size"; //$NON-NLS-1$
+    /**
+     *  The trace channel 'name' property name.
+     */
+    public static final String TRACE_CHANNEL_NAME_PROPERTY_NAME = Messages.TraceControl_ChannelNamePropertyName;
+    /**
+     * The trace channel 'state' property name.
+     */
+    public static final String TRACE_CHANNEL_STATE_PROPERTY_NAME = Messages.TraceControl_StatePropertyName;
+    /**
+     *  The trace channel 'overwrite mode' property name.
+     */
+    public static final String TRACE_CHANNEL_OVERWRITE_MODE_PROPERTY_NAME = Messages.TraceControl_OverwriteModePropertyName;
+    /**
+     *  The trace channel 'sub-buffer size' property name.
+     */
+    public static final String TRACE_CHANNEL_SUBBUFFER_SIZE_PROPERTY_NAME = Messages.TraceControl_SubBufferSizePropertyName;
+    /**
+     *  The trace channel 'sub-buffer size' property name.
+     */
+    public static final String TRACE_CHANNEL_NO_SUBBUFFERS_PROPERTY_NAME = Messages.TraceControl_NbSubBuffersPropertyName;
+    /**
+     *  The trace channel 'switch timer interval' property name.
+     */
+    public static final String TRACE_CHANNEL_SWITCH_TIMER_PROPERTY_NAME = Messages.TraceControl_SwitchTimerPropertyName;
+    /**
+     *  The trace channel 'read timer interval' property name.
+     */
+    public static final String TRACE_CHANNEL_READ_TIMER_PROPERTY_NAME = Messages.TraceControl_ReadTimerPropertyName;
+    /**
+     *  The trace channel 'output type' property name.
+     */
+    public static final String TRACE_CHANNEL_OUTPUT_TYPEPROPERTY_NAME = Messages.TraceControl_OutputTypePropertyName;
+    /**
+     * The trace channel 'trace file count' property name.
+     */
+    public static final String TRACE_CHANNEL_TRACE_FILE_COUNT_PROPERTY_NAME = Messages.TraceControl_TraceFileCountPropertyName;
+    /**
+     * The trace channel 'trace file size' property name.
+     */
+    public static final String TRACE_CHANNEL_TRACE_FILE_SIZE_PROPERTY_NAME = Messages.TraceControl_TraceFileSizePropertyName;
+
+    // Attributes
+    // ------------------------------------------------------------------------
+    /**
+     * The channel component which this property source is for.
+     */
+    private final TraceChannelComponent fChannel;
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+    /**
+     * Constructor
+     * @param component - the channel component
+     */
+    public TraceChannelPropertySource(TraceChannelComponent component) {
+        fChannel = component;
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    public IPropertyDescriptor[] getPropertyDescriptors() {
+        List<IPropertyDescriptor> properties = new ArrayList<>();
+        properties.add(new ReadOnlyTextPropertyDescriptor(TRACE_CHANNEL_NAME_PROPERTY_ID, TRACE_CHANNEL_NAME_PROPERTY_NAME));
+        properties.add(new ReadOnlyTextPropertyDescriptor(TRACE_CHANNEL_STATE_PROPERTY_ID, TRACE_CHANNEL_STATE_PROPERTY_NAME));
+        properties.add(new ReadOnlyTextPropertyDescriptor(TRACE_CHANNEL_OVERWRITE_MODE_PROPERTY_ID, TRACE_CHANNEL_OVERWRITE_MODE_PROPERTY_NAME));
+        properties.add(new ReadOnlyTextPropertyDescriptor(TRACE_CHANNEL_SUBBUFFER_SIZE_PROPERTY_ID, TRACE_CHANNEL_SUBBUFFER_SIZE_PROPERTY_NAME));
+        properties.add(new ReadOnlyTextPropertyDescriptor(TRACE_CHANNEL_NO_SUBBUFFERS_PROPERTY_ID, TRACE_CHANNEL_NO_SUBBUFFERS_PROPERTY_NAME));
+        properties.add(new ReadOnlyTextPropertyDescriptor(TRACE_CHANNEL_SWITCH_TIMER_PROPERTY_ID, TRACE_CHANNEL_SWITCH_TIMER_PROPERTY_NAME));
+        properties.add(new ReadOnlyTextPropertyDescriptor(TRACE_CHANNEL_READ_TIMER_PROPERTY_ID, TRACE_CHANNEL_READ_TIMER_PROPERTY_NAME));
+        properties.add(new ReadOnlyTextPropertyDescriptor(TRACE_CHANNEL_OUTPUT_TYPE_PROPERTY_ID, TRACE_CHANNEL_OUTPUT_TYPEPROPERTY_NAME));
+
+        if (fChannel.getTargetNode().isVersionSupported("2.5.0")) { //$NON-NLS-1$
+            properties.add(new ReadOnlyTextPropertyDescriptor(TRACE_CHANNEL_TRACE_FILE_COUNT_PROPERTY_ID, TRACE_CHANNEL_TRACE_FILE_COUNT_PROPERTY_NAME));
+            properties.add(new ReadOnlyTextPropertyDescriptor(TRACE_CHANNEL_TRACE_FILE_SIZE_PROPERTY_ID, TRACE_CHANNEL_TRACE_FILE_SIZE_PROPERTY_NAME));
+        }
+        return properties.toArray(new IPropertyDescriptor[0]);
+    }
+
+    @Override
+    public Object getPropertyValue(Object id) {
+        if(TRACE_CHANNEL_NAME_PROPERTY_ID.equals(id)) {
+            return fChannel.getName();
+        }
+        if (TRACE_CHANNEL_STATE_PROPERTY_ID.equals(id)) {
+            return fChannel.getState().name();
+        }
+        if(TRACE_CHANNEL_OVERWRITE_MODE_PROPERTY_ID.equals(id)) {
+            return String.valueOf(fChannel.isOverwriteMode());
+        }
+        if(TRACE_CHANNEL_SUBBUFFER_SIZE_PROPERTY_ID.equals(id)) {
+            return String.valueOf(fChannel.getSubBufferSize());
+        }
+        if(TRACE_CHANNEL_NO_SUBBUFFERS_PROPERTY_ID.equals(id)) {
+            return String.valueOf(fChannel.getNumberOfSubBuffers());
+        }
+        if(TRACE_CHANNEL_SWITCH_TIMER_PROPERTY_ID.equals(id)) {
+            return String.valueOf(fChannel.getSwitchTimer());
+        }
+        if(TRACE_CHANNEL_READ_TIMER_PROPERTY_ID.equals(id)) {
+            return String.valueOf(fChannel.getReadTimer());
+        }
+        if(TRACE_CHANNEL_OUTPUT_TYPE_PROPERTY_ID.equals(id)) {
+            return fChannel.getOutputType().getInName();
+        }
+        if (TRACE_CHANNEL_TRACE_FILE_COUNT_PROPERTY_ID.equals(id)) {
+            return fChannel.getMaxNumberTraceFiles();
+        }
+        if (TRACE_CHANNEL_TRACE_FILE_SIZE_PROPERTY_ID.equals(id)) {
+            return fChannel.getMaxSizeTraceFiles();
+        }
+        return null;
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/TraceDomainPropertySource.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/TraceDomainPropertySource.java
new file mode 100644 (file)
index 0000000..799a821
--- /dev/null
@@ -0,0 +1,99 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *     Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.property;
+
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.BufferType;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent;
+import org.eclipse.tracecompass.tmf.ui.properties.ReadOnlyTextPropertyDescriptor;
+import org.eclipse.ui.views.properties.IPropertyDescriptor;
+
+/**
+ * <p>
+ * Property source implementation for the trace domain component.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class TraceDomainPropertySource extends BasePropertySource {
+
+    // ------------------------------------------------------------------------
+    // Constants
+    // ------------------------------------------------------------------------
+
+    /**
+     * The trace domain 'name' property ID.
+     */
+    public static final String TRACE_DOMAIN_NAME_PROPERTY_ID = "trace.domain.name"; //$NON-NLS-1$
+    /**
+     *  The trace domain 'name' property name.
+     */
+    public static final String TRACE_DOMAIN_NAME_PROPERTY_NAME = Messages.TraceControl_DomainNamePropertyName;
+    /**
+     * The domain 'buffer type' property ID.
+     */
+    public static final String BUFFER_TYPE_PROPERTY_ID = "trace.domain.bufferType"; //$NON-NLS-1$
+    /**
+     * The domain 'buffer type' property name.
+     */
+    public static final String BUFER_TYPE_PROPERTY_NAME = Messages.TraceControl_BufferTypePropertyName;
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+
+    /**
+     * The trace domain component which this property source is for.
+     */
+    private final TraceDomainComponent fDomain;
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+
+    /**
+     * Constructor
+     * @param component - the trace domain component
+     */
+    public TraceDomainPropertySource(TraceDomainComponent component) {
+        fDomain = component;
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    public IPropertyDescriptor[] getPropertyDescriptors() {
+        if (fDomain.getBufferType() == BufferType.BUFFER_TYPE_UNKNOWN) {
+            return new IPropertyDescriptor[] {
+                    new ReadOnlyTextPropertyDescriptor(TRACE_DOMAIN_NAME_PROPERTY_ID, TRACE_DOMAIN_NAME_PROPERTY_NAME) };
+        }
+
+        return new IPropertyDescriptor[] {
+                new ReadOnlyTextPropertyDescriptor(TRACE_DOMAIN_NAME_PROPERTY_ID, TRACE_DOMAIN_NAME_PROPERTY_NAME),
+                new ReadOnlyTextPropertyDescriptor(BUFFER_TYPE_PROPERTY_ID, BUFER_TYPE_PROPERTY_NAME) };
+    }
+
+    @Override
+    public Object getPropertyValue(Object id) {
+        if(BUFFER_TYPE_PROPERTY_ID.equals(id)){
+            return fDomain.getBufferType().getInName();
+        }
+
+        if(TRACE_DOMAIN_NAME_PROPERTY_ID.equals(id)) {
+            return fDomain.getName();
+        }
+        return null;
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/TraceEventPropertySource.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/TraceEventPropertySource.java
new file mode 100644 (file)
index 0000000..4867206
--- /dev/null
@@ -0,0 +1,145 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *     Bernd Hufmann - Initial API and implementation
+ *     Bernd Hufmann - Updated for support of LTTng Tools 2.1
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.property;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.LogLevelType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceEventComponent;
+import org.eclipse.tracecompass.tmf.ui.properties.ReadOnlyTextPropertyDescriptor;
+import org.eclipse.ui.views.properties.IPropertyDescriptor;
+
+/**
+ * <p>
+ * Property source implementation for the trace event component.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class TraceEventPropertySource extends BasePropertySource {
+
+    // ------------------------------------------------------------------------
+    // Constants
+    // ------------------------------------------------------------------------
+    /**
+     * The trace event 'name' property ID.
+     */
+    public static final String TRACE_EVENT_NAME_PROPERTY_ID = "trace.event.name"; //$NON-NLS-1$
+    /**
+     * The trace event 'type' property ID.
+     */
+    public static final String TRACE_EVENT_TYPE_PROPERTY_ID = "trace.event.type"; //$NON-NLS-1$
+    /**
+     * The trace event 'log level' property ID.
+     */
+    public static final String TRACE_EVENT_LOGLEVEL_PROPERTY_ID = "trace.event.loglevel"; //$NON-NLS-1$
+    /**
+     * The trace event 'state' property ID.
+     */
+    public static final String TRACE_EVENT_STATE_PROPERTY_ID = "trace.event.state"; //$NON-NLS-1$
+    /**
+     * The trace event 'filter' property ID.
+     */
+    public static final String TRACE_EVENT_FILTER_PROPERTY_ID = "trace.event.filter"; //$NON-NLS-1$
+
+    /**
+     *  The trace event 'name' property name.
+     */
+    public static final String TRACE_EVENT_NAME_PROPERTY_NAME = Messages.TraceControl_EventNamePropertyName;
+    /**
+     * The trace event 'type' property name.
+     */
+    public static final String TRACE_EVENT_TYPE_PROPERTY_NAME = Messages.TraceControl_EventTypePropertyName;
+    /**
+     * The trace event 'log level' property name.
+     */
+    public static final String TRACE_EVENT_LOGLEVEL_PROPERTY_NAME = Messages.TraceControl_LogLevelPropertyName;
+    /**
+     * The trace event 'state' property name.
+     */
+    public static final String TRACE_EVENT_STATE_PROPERTY_NAME = Messages.TraceControl_StatePropertyName;
+    /**
+     * The trace event 'filter' property name.
+     */
+    public static final String TRACE_EVENT_FILTER_PROPERTY_NAME = Messages.TraceControl_FilterPropertyName;
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+
+    /**
+     * The event component which this property source is for.
+     */
+    protected final TraceEventComponent fEvent;
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+
+    /**
+     * Constructor
+     * @param component - the base event component
+     */
+    public TraceEventPropertySource(TraceEventComponent component) {
+        fEvent = component;
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    public IPropertyDescriptor[] getPropertyDescriptors() {
+        List<IPropertyDescriptor> list = new ArrayList<> ();
+        list.add(new ReadOnlyTextPropertyDescriptor(TRACE_EVENT_NAME_PROPERTY_ID, TRACE_EVENT_NAME_PROPERTY_NAME));
+        list.add(new ReadOnlyTextPropertyDescriptor(TRACE_EVENT_TYPE_PROPERTY_ID, TRACE_EVENT_TYPE_PROPERTY_NAME));
+        list.add( new ReadOnlyTextPropertyDescriptor(TRACE_EVENT_STATE_PROPERTY_ID, TRACE_EVENT_STATE_PROPERTY_NAME));
+        if (fEvent.getLogLevel() != TraceLogLevel.LEVEL_UNKNOWN) {
+            list.add(new ReadOnlyTextPropertyDescriptor(TRACE_EVENT_LOGLEVEL_PROPERTY_ID, TRACE_EVENT_LOGLEVEL_PROPERTY_NAME));
+        }
+        if (fEvent.getFilterExpression() != null) {
+            list.add(new ReadOnlyTextPropertyDescriptor(TRACE_EVENT_FILTER_PROPERTY_ID, TRACE_EVENT_FILTER_PROPERTY_NAME));
+        }
+        return list.toArray(new IPropertyDescriptor[list.size()]);
+    }
+
+    @Override
+    public Object getPropertyValue(Object id) {
+        if(TRACE_EVENT_NAME_PROPERTY_ID.equals(id)) {
+            return fEvent.getName();
+        }
+        if (TRACE_EVENT_TYPE_PROPERTY_ID.equals(id)) {
+            return fEvent.getEventType().name();
+        }
+        if (TRACE_EVENT_LOGLEVEL_PROPERTY_ID.equals(id)) {
+            StringBuffer buffer = new StringBuffer();
+            if (fEvent.getLogLevelType() != LogLevelType.LOGLEVEL_NONE) {
+                buffer.append(fEvent.getLogLevelType().getShortName()).append(' ');
+            }
+            buffer.append(fEvent.getLogLevel().name());
+            return buffer.toString();
+        }
+        if (TRACE_EVENT_STATE_PROPERTY_ID.equals(id)) {
+            return fEvent.getState().name();
+        }
+        if (TRACE_EVENT_FILTER_PROPERTY_ID.equals(id)) {
+            return fEvent.getFilterExpression();
+        }
+
+        return null;
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/TraceProbeEventPropertySource.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/TraceProbeEventPropertySource.java
new file mode 100644 (file)
index 0000000..22f2e1a
--- /dev/null
@@ -0,0 +1,124 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *     Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.property;
+
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.List;
+
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceEventComponent;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceProbeEventComponent;
+import org.eclipse.tracecompass.tmf.ui.properties.ReadOnlyTextPropertyDescriptor;
+import org.eclipse.ui.views.properties.IPropertyDescriptor;
+
+/**
+ * <p>
+ * Property source implementation for the trace probe event component.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class TraceProbeEventPropertySource extends TraceEventPropertySource {
+
+    // ------------------------------------------------------------------------
+    // Constants
+    // ------------------------------------------------------------------------
+    /**
+     * The trace event 'probe address' property ID.
+     */
+    public static final String TRACE_EVENT_PROBE_ADDRESS_PROPERTY_ID = "trace.event.probe.address"; //$NON-NLS-1$
+    /**
+     * The trace event 'probe offset' property ID.
+     */
+    public static final String TRACE_EVENT_PROBE_OFFSET_PROPERTY_ID = "trace.event.probe.offset"; //$NON-NLS-1$
+    /**
+     * The trace event 'probe symbol' property ID.
+     */
+    public static final String TRACE_EVENT_PROBE_SYMBOL_PROPERTY_ID = "trace.event.probe.symbol"; //$NON-NLS-1$
+    /**
+     * The trace event 'probe address' property name.
+     */
+    public static final String TRACE_EVENT_PROBE_ADDRESS_PROPERTY_NAME = Messages.TraceControl_ProbeAddressPropertyName;
+    /**
+     * The trace event 'probe offset' property ID.
+     */
+    public static final String TRACE_EVENT_PROBE_OFFSET_PROPERTY_NAME = Messages.TraceControl_ProbeOffsetPropertyName;
+    /**
+     * The trace event 'probe symbol' property ID.
+     */
+    public static final String TRACE_EVENT_PROBE_SYMBOL_PROPERTY_NAME = Messages.TraceControl_ProbeSymbolPropertyName;
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+
+    /**
+     * Constructor
+     *
+     * @param component
+     *            A trace event component
+     */
+    public TraceProbeEventPropertySource(TraceEventComponent component) {
+        super(component);
+        if (component.getClass() != TraceProbeEventComponent.class) {
+            throw new IllegalArgumentException("Invalid type passed. Only class of type TraceProbeEventComponent allowed:\n" + component.getClass()); //$NON-NLS-1$
+        }
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    public IPropertyDescriptor[] getPropertyDescriptors() {
+        IPropertyDescriptor[] superProperties = super.getPropertyDescriptors();
+
+        List<IPropertyDescriptor> superList = Arrays.asList(superProperties);
+        ArrayList<IPropertyDescriptor> list = new ArrayList<>();
+        list.addAll(superList);
+
+        if (fEvent instanceof TraceProbeEventComponent) {
+            TraceProbeEventComponent event = (TraceProbeEventComponent) fEvent;
+            if (event.getAddress() != null) {
+                list.add(new ReadOnlyTextPropertyDescriptor(TRACE_EVENT_PROBE_ADDRESS_PROPERTY_ID, TRACE_EVENT_PROBE_ADDRESS_PROPERTY_NAME));
+            }
+
+            if (event.getOffset() != null) {
+                list.add(new ReadOnlyTextPropertyDescriptor(TRACE_EVENT_PROBE_OFFSET_PROPERTY_ID, TRACE_EVENT_PROBE_OFFSET_PROPERTY_NAME));
+            }
+
+            if (event.getSymbol() != null) {
+                list.add(new ReadOnlyTextPropertyDescriptor(TRACE_EVENT_PROBE_SYMBOL_PROPERTY_ID, TRACE_EVENT_PROBE_SYMBOL_PROPERTY_NAME));
+            }
+        }
+        return list.toArray(new IPropertyDescriptor[list.size()]);
+    }
+
+    @Override
+    public Object getPropertyValue(Object id) {
+        if(TRACE_EVENT_PROBE_ADDRESS_PROPERTY_ID.equals(id)) {
+            return ((TraceProbeEventComponent)fEvent).getAddress();
+        }
+        if (TRACE_EVENT_PROBE_OFFSET_PROPERTY_ID.equals(id)) {
+            return ((TraceProbeEventComponent)fEvent).getOffset();
+        }
+        if (TRACE_EVENT_PROBE_SYMBOL_PROPERTY_ID.equals(id)) {
+            return ((TraceProbeEventComponent)fEvent).getSymbol();
+        }
+        return super.getPropertyValue(id);
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/TraceSessionPropertySource.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/TraceSessionPropertySource.java
new file mode 100644 (file)
index 0000000..0d4310a
--- /dev/null
@@ -0,0 +1,147 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *     Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.property;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
+import org.eclipse.tracecompass.tmf.ui.properties.ReadOnlyTextPropertyDescriptor;
+import org.eclipse.ui.views.properties.IPropertyDescriptor;
+
+/**
+ * <p>
+ * Property source implementation for the trace session component.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class TraceSessionPropertySource extends BasePropertySource {
+
+    // ------------------------------------------------------------------------
+    // Constants
+    // ------------------------------------------------------------------------
+    /**
+     * The trace session name property ID.
+     */
+    public static final String TRACE_SESSION_NAME_PROPERTY_ID = "trace.session.name"; //$NON-NLS-1$
+    /**
+     * The trace session path property ID.
+     */
+    public static final String TRACE_SESSION_PATH_PROPERTY_ID = "trace.session.path"; //$NON-NLS-1$
+    /**
+     * The trace session state ID.
+     */
+    public static final String TRACE_SESSION_STATE_PROPERTY_ID = "trace.session.state"; //$NON-NLS-1$
+    /**
+     * The trace snapshot path property ID.
+     */
+    public static final String TRACE_SNAPSHOT_PATH_PROPERTY_ID = "trace.snapshot.path"; //$NON-NLS-1$
+    /**
+     * The snapshot name property.
+     */
+    public static final String TRACE_SNAPSHOT_NAME_PROPERTY_ID = "trace.snapshot.name"; //$NON-NLS-1$
+    /**
+     * The snapshot ID property.
+     */
+    public static final String TRACE_SNAPSHOT_ID_PROPERTY_ID = "trace.snapshot.id"; //$NON-NLS-1$
+
+    /**
+     *  The trace session name property name.
+     */
+    public static final String TRACE_SESSION_NAME_PROPERTY_NAME = Messages.TraceControl_SessionNamePropertyName;
+    /**
+     *  The trace session path property name.
+     */
+    public static final String TRACE_SESSION_PATH_PROPERTY_NAME = Messages.TraceControl_SessionPathPropertyName;
+    /**
+     * The trace session state property name.
+     */
+    public static final String TRACE_SESSION_STATE_PROPERTY_NAME = Messages.TraceControl_StatePropertyName;
+    /**
+     *  The snapshot path property name.
+     */
+    public static final String TRACE_SNAPSHOT_PATH_PROPERTY_NAME = Messages.TraceControl_SnapshotPathPropertyName;
+    /**
+     * The trace snapshot name property name.
+     */
+    public static final String TRACE_SNAPSHOT_NAME_PROPERTY_NAME = Messages.TraceControl_SnapshotNamePropertyName;
+    /**
+     * The trace snapshot ID property name.
+     */
+    public static final String TRACE_SNAPSHOT_ID_PROPERTY_NAME = Messages.TraceControl_SnapshotIdPropertyName;
+
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+
+    /**
+     * The session component which this property source is for.
+     */
+    private final TraceSessionComponent fSession;
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+
+    /**
+     * Constructor
+     * @param component - the session component
+     */
+    public TraceSessionPropertySource(TraceSessionComponent component) {
+        fSession = component;
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    public IPropertyDescriptor[] getPropertyDescriptors() {
+        List<IPropertyDescriptor> list = new ArrayList<>();
+        list.add(new ReadOnlyTextPropertyDescriptor(TRACE_SESSION_NAME_PROPERTY_ID, TRACE_SESSION_NAME_PROPERTY_NAME));
+        list.add(new ReadOnlyTextPropertyDescriptor(TRACE_SESSION_STATE_PROPERTY_ID, TRACE_SESSION_STATE_PROPERTY_NAME));
+        if (fSession.isSnapshotSession()) {
+            list.add(new ReadOnlyTextPropertyDescriptor(TRACE_SNAPSHOT_NAME_PROPERTY_ID, TRACE_SNAPSHOT_NAME_PROPERTY_NAME));
+            list.add(new ReadOnlyTextPropertyDescriptor(TRACE_SNAPSHOT_PATH_PROPERTY_ID, TRACE_SNAPSHOT_PATH_PROPERTY_NAME));
+            list.add(new ReadOnlyTextPropertyDescriptor(TRACE_SNAPSHOT_ID_PROPERTY_ID, TRACE_SNAPSHOT_ID_PROPERTY_NAME));
+        } else {
+            list.add(new ReadOnlyTextPropertyDescriptor(TRACE_SESSION_PATH_PROPERTY_ID, TRACE_SESSION_PATH_PROPERTY_NAME));
+        }
+        return(list.toArray(new IPropertyDescriptor[list.size()]));
+    }
+
+    @Override
+    public Object getPropertyValue(Object id) {
+        if(TRACE_SESSION_NAME_PROPERTY_ID.equals(id)) {
+            return fSession.getName();
+        }
+        if(TRACE_SESSION_PATH_PROPERTY_ID.equals(id)) {
+            return fSession.getSessionPath();
+        }
+        if (TRACE_SESSION_STATE_PROPERTY_ID.equals(id)) {
+            return fSession.getSessionState().name();
+        }
+        if (TRACE_SNAPSHOT_PATH_PROPERTY_ID.equals(id)) {
+            return (fSession.isSnapshotSession() ? fSession.getSnapshotInfo().getSnapshotPath() : ""); //$NON-NLS-1$
+        }
+        if (TRACE_SNAPSHOT_NAME_PROPERTY_ID.equals(id)) {
+            return (fSession.isSnapshotSession() ? fSession.getSnapshotInfo().getName() : ""); //$NON-NLS-1$
+        }
+        if (TRACE_SNAPSHOT_ID_PROPERTY_ID.equals(id)) {
+            return (fSession.isSnapshotSession() ? fSession.getSnapshotInfo().getId() : ""); //$NON-NLS-1$
+        }
+        return null;
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/UstProviderPropertySource.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/UstProviderPropertySource.java
new file mode 100644 (file)
index 0000000..908a791
--- /dev/null
@@ -0,0 +1,91 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *     Bernd Hufmann - Initial API and implementation
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.property;
+
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.UstProviderComponent;
+import org.eclipse.tracecompass.tmf.ui.properties.ReadOnlyTextPropertyDescriptor;
+import org.eclipse.ui.views.properties.IPropertyDescriptor;
+
+/**
+ * <p>
+ * Property source implementation for the UST provider component.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class UstProviderPropertySource extends BasePropertySource {
+
+    // ------------------------------------------------------------------------
+    // Constants
+    // ------------------------------------------------------------------------
+    /**
+     * The UST provider 'name' property ID.
+     */
+    public static final String UST_PROVIDER_NAME_PROPERTY_ID = "ust.provider.name"; //$NON-NLS-1$
+    /**
+     * The UST provider 'PID' property ID.
+     */
+    public static final String UST_PROVIDER_PID_PROPERTY_ID = "ust.provider.pid"; //$NON-NLS-1$
+    /**
+     *  The UST provider 'name' property name.
+     */
+    public static final String UST_PROVIDER_NAME_PROPERTY_NAME = Messages.TraceControl_ProviderNamePropertyName;
+    /**
+     * The UST provider 'type' property name.
+     */
+    public static final String UST_PROVIDER_PID_PROPERTY_NAME = Messages.TraceControl_ProcessIdPropertyName;
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+
+    /**
+     * The UST provider component which this property source is for.
+     */
+    private UstProviderComponent fUstProvider;
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+
+    /**
+     * Constructor
+     * @param component - the UST provider component
+     */
+    public UstProviderPropertySource(UstProviderComponent component) {
+        fUstProvider = component;
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    public IPropertyDescriptor[] getPropertyDescriptors() {
+        return new IPropertyDescriptor[] {
+                new ReadOnlyTextPropertyDescriptor(UST_PROVIDER_NAME_PROPERTY_ID, UST_PROVIDER_NAME_PROPERTY_NAME),
+                new ReadOnlyTextPropertyDescriptor(UST_PROVIDER_PID_PROPERTY_ID, UST_PROVIDER_PID_PROPERTY_NAME)};
+    }
+
+    @Override
+    public Object getPropertyValue(Object id) {
+        if(UST_PROVIDER_NAME_PROPERTY_ID.equals(id)) {
+            return fUstProvider.getName();
+        }
+        if (UST_PROVIDER_PID_PROPERTY_ID.equals(id)) {
+            return String.valueOf(fUstProvider.getPid());
+        }
+        return null;
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/service/ILttngControlService.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/service/ILttngControlService.java
new file mode 100644 (file)
index 0000000..81d9bd5
--- /dev/null
@@ -0,0 +1,403 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.service;
+
+import java.util.List;
+
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.jdt.annotation.NonNull;
+import org.eclipse.jdt.annotation.Nullable;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IBaseEventInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IChannelInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISessionInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISnapshotInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IUstProviderInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.LogLevelType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
+
+
+/**
+* <p>
+* Interface for LTTng trace control command service.
+* </p>
+*
+* @author Bernd Hufmann
+*/
+public interface ILttngControlService {
+
+    /**
+     * @return the LTTng version object
+     */
+    @NonNull LttngVersion getVersion();
+
+    /**
+     * @return the version string
+     */
+    @NonNull String getVersionString();
+
+    /**
+     * Checks if given version is supported by this ILTTngControlService implementation.
+     *
+     * @param version The version to check
+     * @return <code>true</code> if version is supported else <code>false</code>
+     */
+    boolean isVersionSupported(String version);
+
+    /**
+     * Retrieves the existing sessions names from the node.
+     *
+     * @param monitor
+     *            - a progress monitor
+     * @return a list of session names.
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    @NonNull List<String> getSessionNames(IProgressMonitor monitor) throws ExecutionException;
+
+    /**
+     * Retrieves the session information with the given name the node.
+     *
+     * @param sessionName
+     *            - the session name
+     * @param monitor
+     *            - a progress monitor
+     * @return session information
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    @Nullable ISessionInfo getSession(String sessionName, IProgressMonitor monitor)
+            throws ExecutionException;
+
+    /**
+     * Retrieves the snapshot output information from the node
+     * @param sessionName
+     *            - the session name
+     * @param monitor
+     *            - a progress monitor
+     * @return snapshot output information
+     * @throws ExecutionException
+     *          if command fails
+     */
+    @Nullable ISnapshotInfo getSnapshotInfo(String sessionName, IProgressMonitor monitor)
+            throws ExecutionException;
+
+    /**
+     * Retrieves the kernel provider information (i.e. the kernel events)
+     *
+     * @param monitor
+     *            - a progress monitor
+     * @return the list of existing kernel events.
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    @NonNull List<IBaseEventInfo> getKernelProvider(IProgressMonitor monitor)
+            throws ExecutionException;
+
+    /**
+     * Retrieves the UST provider information from the node.
+     *
+     * @return - the UST provider information.
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    @NonNull public List<IUstProviderInfo> getUstProvider() throws ExecutionException;
+
+    /**
+     * Retrieves the UST provider information from the node.
+     *
+     * @param monitor
+     *            - a progress monitor
+     * @return the UST provider information.
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    @NonNull List<IUstProviderInfo> getUstProvider(IProgressMonitor monitor)
+            throws ExecutionException;
+
+    /**
+     * Creates a session with given session name and location.
+     *
+     * @param sessionInfo
+     *            the session information used to create the session
+     * @param monitor
+     *            - a progress monitor
+     *
+     * @return the session information
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    @Nullable ISessionInfo createSession(ISessionInfo sessionInfo, IProgressMonitor monitor) throws ExecutionException;
+
+    /**
+     * Destroys a session with given session name.
+     *
+     * @param sessionName
+     *            - a session name to destroy
+     * @param monitor
+     *            - a progress monitor
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    void destroySession(String sessionName, IProgressMonitor monitor)
+            throws ExecutionException;
+
+    /**
+     * Starts a session with given session name.
+     *
+     * @param sessionName
+     *            - a session name to start
+     * @param monitor
+     *            - a progress monitor
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    void startSession(String sessionName, IProgressMonitor monitor)
+            throws ExecutionException;
+
+    /**
+     * Stops a session with given session name.
+     *
+     * @param sessionName
+     *            - a session name to stop
+     * @param monitor
+     *            - a progress monitor
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    void stopSession(String sessionName, IProgressMonitor monitor)
+            throws ExecutionException;
+
+    /**
+     * Enables a list of channels for given session and given channel
+     * information (configuration).
+     *
+     * @param sessionName
+     *            - a session name to create
+     * @param channelNames
+     *            - a list of channel names to be enabled
+     * @param isKernel
+     *            - a flag to indicate Kernel or UST (true for Kernel, false for
+     *            UST)
+     * @param info
+     *            - channel information used for creation of a channel (or null
+     *            for default)
+     * @param monitor
+     *            - a progress monitor
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    void enableChannels(String sessionName, List<String> channelNames,
+            boolean isKernel, IChannelInfo info, IProgressMonitor monitor)
+            throws ExecutionException;
+
+    /**
+     * Disables a list of channels for given session and given channel
+     * information (configuration).
+     *
+     * @param sessionName
+     *            - a session name to create
+     * @param channelNames
+     *            - a list of channel names to be enabled
+     * @param isKernel
+     *            - a flag to indicate Kernel or UST (true for Kernel, false for
+     *            UST)
+     * @param monitor
+     *            - a progress monitor
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    void disableChannels(String sessionName, List<String> channelNames,
+            boolean isKernel, IProgressMonitor monitor)
+            throws ExecutionException;
+
+    /**
+     * Enables a list of events with no additional parameters.
+     *
+     * @param sessionName
+     *            - a session name
+     * @param channelName
+     *            - a channel name or null for default channel
+     * @param eventNames
+     *            - a list of event names to be enabled, or null (list of size =
+     *            0)for all events .
+     * @param isKernel
+     *            - a flag for indicating kernel or UST.
+     * @param filterExpression
+     *            - a filter expression
+     * @param monitor
+     *            - a progress monitor
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    void enableEvents(String sessionName, String channelName,
+            List<String> eventNames, boolean isKernel, String filterExpression,
+            IProgressMonitor monitor)
+            throws ExecutionException;
+
+
+    /**
+     * Enables all syscall events.
+     *
+     * @param sessionName
+     *            - a session name
+     * @param channelName
+     *            - a channel name or null for default channel
+     * @param monitor
+     *            - a progress monitor
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    void enableSyscalls(String sessionName, String channelName,
+            IProgressMonitor monitor) throws ExecutionException;
+
+    /**
+     * Enables a dynamic probe or dynamic function entry/return probe.
+     *
+     * @param sessionName
+     *            - a session name
+     * @param channelName
+     *            - a channel name or null for default channel
+     * @param eventName
+     *            - a event name
+     * @param isFunction
+     *            - true for dynamic function entry/return probe else false
+     * @param probe
+     *            - a dynamic probe information
+     * @param monitor
+     *            - a progress monitor
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    void enableProbe(String sessionName, String channelName,
+            String eventName, boolean isFunction, String probe,
+            IProgressMonitor monitor) throws ExecutionException;
+
+    /**
+     * Enables events using log level
+     *
+     * @param sessionName
+     *            - a session name
+     * @param channelName
+     *            - a channel name (null for default channel)
+     * @param eventName
+     *            - a event name
+     * @param logLevelType
+     *            - a log level type
+     * @param level
+     *            - a log level
+     * @param filterExpression
+     *            - a filter expression
+     * @param monitor
+     *            - a progress monitor
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    void enableLogLevel(String sessionName, String channelName,
+            String eventName, LogLevelType logLevelType, TraceLogLevel level,
+            String filterExpression,
+            IProgressMonitor monitor) throws ExecutionException;
+
+    /**
+     * Disables a list of events with no additional parameters.
+     *
+     * @param sessionName
+     *            - a session name
+     * @param channelName
+     *            - a channel name (null for default channel)
+     * @param eventNames
+     *            - a list of event names to enabled.
+     * @param isKernel
+     *            - a flag for indicating kernel or UST.
+     * @param monitor
+     *            - a progress monitor
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    void disableEvent(String sessionName, String channelName,
+            List<String> eventNames, boolean isKernel, IProgressMonitor monitor)
+            throws ExecutionException;
+
+    /**
+     * Gets all available context names to be added to channels/events.
+     *
+     * @param monitor
+     *            The progress monitor
+     * @return the list of available contexts
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    @NonNull List<String> getContextList(IProgressMonitor monitor)
+            throws ExecutionException;
+
+    /**
+     * Add contexts to given channels and or events
+     *
+     * @param sessionName
+     *            - a session name
+     * @param channelName
+     *            - a channel name (null for all channels)
+     * @param eventName
+     *            - a event name (null for all events)
+     * @param isKernel
+     *            - a flag for indicating kernel or UST.
+     * @param contexts
+     *            - a list of name of contexts to add
+     * @param monitor
+     *            - a progress monitor
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    void addContexts(String sessionName, String channelName,
+            String eventName, boolean isKernel, List<String> contexts,
+            IProgressMonitor monitor) throws ExecutionException;
+
+    /**
+     * Executes calibrate command to quantify LTTng overhead.
+     *
+     * @param isKernel
+     *            - a flag for indicating kernel or UST.
+     * @param monitor
+     *            - a progress monitor
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    void calibrate(boolean isKernel, IProgressMonitor monitor)
+            throws ExecutionException;
+
+    /**
+     * Records a snapshot.
+     *
+     * @param sessionName
+     *            - a session name
+     * @param monitor
+     *            - a progress monitor
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    void recordSnapshot(String sessionName, IProgressMonitor monitor)
+            throws ExecutionException;
+
+    /**
+     * Executes a list of commands
+     *
+     * @param monitor
+     *      - a progress monitor
+     * @param commands
+     *      - array of commands
+     * @throws ExecutionException
+     *      If a command fails
+     */
+    void runCommands(IProgressMonitor monitor, List<String> commands)
+            throws ExecutionException;
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/service/LTTngControlService.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/service/LTTngControlService.java
new file mode 100644 (file)
index 0000000..ba3f323
--- /dev/null
@@ -0,0 +1,1538 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2015 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
+ *   Simon Delisle - Updated for support of LTTng Tools 2.2
+ *   Marc-Andre Laperle - Support for creating a live session
+ *   Markus Schorn - Bug 448058: Use org.eclipse.remote in favor of RSE
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.service;
+
+import static org.eclipse.tracecompass.common.core.NonNullUtils.checkNotNull;
+import static org.eclipse.tracecompass.common.core.NonNullUtils.nullToEmptyString;
+
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.Iterator;
+import java.util.List;
+import java.util.regex.Matcher;
+import java.util.regex.Pattern;
+
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.core.runtime.NullProgressMonitor;
+import org.eclipse.jdt.annotation.NonNull;
+import org.eclipse.jdt.annotation.Nullable;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IBaseEventInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IChannelInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IDomainInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IEventInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IFieldInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IProbeEventInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISessionInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISnapshotInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IUstProviderInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.LogLevelType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEventType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.BaseEventInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.BufferType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.ChannelInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.DomainInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.EventInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.FieldInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.ProbeEventInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.SessionInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.SnapshotInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.UstProviderInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.logging.ControlCommandLogger;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.preferences.ControlPreferences;
+import org.eclipse.tracecompass.tmf.remote.core.shell.ICommandInput;
+import org.eclipse.tracecompass.tmf.remote.core.shell.ICommandResult;
+import org.eclipse.tracecompass.tmf.remote.core.shell.ICommandShell;
+
+/**
+ * <p>
+ * Service for sending LTTng trace control commands to remote host.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+public class LTTngControlService implements ILttngControlService {
+
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+    /**
+     * The command shell implementation
+     */
+    private final @NonNull ICommandShell fCommandShell;
+
+    /**
+     * The version string.
+     */
+    private @NonNull LttngVersion fVersion = LttngVersion.NULL_VERSION;
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+
+    /**
+     * Constructor
+     *
+     * @param shell
+     *            - the command shell implementation to use
+     */
+    public LTTngControlService(@NonNull ICommandShell shell) {
+        fCommandShell = shell;
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    @Override
+    public String getVersionString() {
+        return nullToEmptyString(fVersion.toString());
+    }
+
+    @Override
+    public LttngVersion getVersion() {
+        return fVersion;
+    }
+
+    /**
+     * Sets the version of the LTTng 2.0 control service.
+     *
+     * @param version
+     *            - a version to set
+     */
+    public void setVersion(@Nullable String version) {
+        if (version != null) {
+            fVersion = new LttngVersion(version);
+        }
+    }
+
+    /**
+     * Sets the version of the LTTng 2.x control service.
+     *
+     * @param version
+     *            - a version to set
+     */
+    public void setVersion(LttngVersion version) {
+        if (version != null) {
+            fVersion = version;
+        }
+    }
+
+    @Override
+    public boolean isVersionSupported(String version) {
+        LttngVersion tmp = new LttngVersion(version);
+        return (fVersion.compareTo(tmp) >= 0) ? true : false;
+    }
+
+    /**
+     * Returns the command shell implementation.
+     *
+     * @return the command shell implementation
+     */
+    protected ICommandShell getCommandShell() {
+        return fCommandShell;
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    @Override
+    public List<String> getSessionNames(IProgressMonitor monitor) throws ExecutionException {
+        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_LIST);
+
+        ICommandResult result = executeCommand(command, monitor);
+
+        // Output:
+        // Available tracing sessions:
+        // 1) mysession1 (/home/user/lttng-traces/mysession1-20120123-083928)
+        // [inactive]
+        // 2) mysession (/home/user/lttng-traces/mysession-20120123-083318)
+        // [inactive]
+        //
+        // Use lttng list <session_name> for more details
+
+        ArrayList<String> retArray = new ArrayList<>();
+        for (String line : result.getOutput()) {
+            Matcher matcher = LTTngControlServiceConstants.SESSION_PATTERN.matcher(line);
+            if (matcher.matches()) {
+                retArray.add(matcher.group(2).trim());
+            }
+        }
+        return retArray;
+    }
+
+    /**
+     * Check if there is a pattern to be ignored into a sequence of string
+     *
+     * @param input
+     *            an input list of Strings
+     * @param pattern
+     *            the pattern to search for
+     * @return if the pattern exist in the array of string
+     */
+    protected boolean ignoredPattern(List<String> input, Pattern pattern) {
+        for (String line : input) {
+            Matcher matcher = pattern.matcher(line);
+            if (matcher.matches()) {
+                return true;
+            }
+        }
+        return false;
+    }
+
+    @Override
+    public ISessionInfo getSession(String sessionName, IProgressMonitor monitor) throws ExecutionException {
+        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_LIST, sessionName);
+        ICommandResult result = executeCommand(command, monitor);
+
+        int index = 0;
+
+        // Output:
+        // Tracing session mysession2: [inactive]
+        // Trace path: /home/eedbhu/lttng-traces/mysession2-20120123-110330
+        ISessionInfo sessionInfo = new SessionInfo(sessionName);
+
+        while (index < result.getOutput().size()) {
+            // Tracing session mysession2: [inactive]
+            // Trace path: /home/eedbhu/lttng-traces/mysession2-20120123-110330
+            //
+            // === Domain: Kernel ===
+            //
+            String line = result.getOutput().get(index);
+            Matcher matcher = LTTngControlServiceConstants.TRACE_SESSION_PATTERN.matcher(line);
+            if (matcher.matches()) {
+                sessionInfo.setSessionState(matcher.group(2));
+                index++;
+                continue;
+            }
+
+            matcher = LTTngControlServiceConstants.TRACE_SNAPSHOT_SESSION_PATTERN.matcher(line);
+            if (matcher.matches()) {
+                sessionInfo.setSessionState(matcher.group(2));
+                // real name will be set later
+                ISnapshotInfo snapshotInfo = new SnapshotInfo(""); //$NON-NLS-1$
+                sessionInfo.setSnapshotInfo(snapshotInfo);
+                index++;
+                continue;
+            }
+
+            if (!sessionInfo.isSnapshotSession()) {
+                matcher = LTTngControlServiceConstants.TRACE_NETWORK_PATH_PATTERN.matcher(line);
+                if (matcher.matches()) {
+                    sessionInfo.setStreamedTrace(true);
+                }
+
+                matcher = LTTngControlServiceConstants.TRACE_SESSION_PATH_PATTERN.matcher(line);
+                if (matcher.matches()) {
+                    sessionInfo.setSessionPath(matcher.group(1).trim());
+                    index++;
+                    continue;
+                }
+            }
+
+            matcher = LTTngControlServiceConstants.DOMAIN_KERNEL_PATTERN.matcher(line);
+            if (matcher.matches()) {
+                // Create Domain
+                IDomainInfo domainInfo = new DomainInfo(Messages.TraceControl_KernelDomainDisplayName);
+
+                // set kernel flag
+                domainInfo.setIsKernel(true);
+
+                // in domain kernel
+                ArrayList<IChannelInfo> channels = new ArrayList<>();
+                index = parseDomain(result.getOutput(), index, channels, domainInfo);
+
+                if (channels.size() > 0) {
+                    // add domain
+                    sessionInfo.addDomain(domainInfo);
+
+                    // set channels
+                    domainInfo.setChannels(channels);
+                }
+                continue;
+            }
+
+            matcher = LTTngControlServiceConstants.DOMAIN_UST_GLOBAL_PATTERN.matcher(line);
+            if (matcher.matches()) {
+                IDomainInfo domainInfo = new DomainInfo(Messages.TraceControl_UstGlobalDomainDisplayName);
+
+                // set kernel flag
+                domainInfo.setIsKernel(false);
+
+                // in domain UST
+                ArrayList<IChannelInfo> channels = new ArrayList<>();
+                index = parseDomain(result.getOutput(), index, channels, domainInfo);
+
+                if (channels.size() > 0) {
+                    // add domain
+                    sessionInfo.addDomain(domainInfo);
+
+                    // set channels
+                    domainInfo.setChannels(channels);
+                }
+                continue;
+            }
+            matcher = LTTngControlServiceConstants.LIST_LIVE_TIMER_INTERVAL_PATTERN.matcher(line);
+            if (matcher.matches()) {
+                long liveDelay = Long.parseLong(matcher.group(1));
+                if ((liveDelay > 0) && (liveDelay <= LTTngControlServiceConstants.MAX_LIVE_TIMER_INTERVAL)) {
+                    sessionInfo.setLive(true);
+                    sessionInfo.setLiveUrl(SessionInfo.DEFAULT_LIVE_NETWORK_URL);
+                    sessionInfo.setLivePort(SessionInfo.DEFAULT_LIVE_PORT);
+                    sessionInfo.setLiveDelay(liveDelay);
+                }
+                index++;
+                continue;
+            }
+
+            index++;
+        }
+
+        if (sessionInfo.isSnapshotSession()) {
+            ISnapshotInfo snapshot = getSnapshotInfo(sessionName, monitor);
+            sessionInfo.setSnapshotInfo(snapshot);
+        }
+
+        return sessionInfo;
+    }
+
+    @Override
+    public ISnapshotInfo getSnapshotInfo(String sessionName, IProgressMonitor monitor) throws ExecutionException {
+        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_SNAPSHOT, LTTngControlServiceConstants.COMMAND_LIST_SNAPSHOT_OUTPUT, LTTngControlServiceConstants.OPTION_SESSION, sessionName);
+        ICommandResult result = executeCommand(command, monitor);
+
+        int index = 0;
+
+        // Output:
+        // [1] snapshot-1: /home/user/lttng-traces/my-20130909-114431
+        // or
+        // [3] snapshot-3: net4://172.0.0.1/
+        ISnapshotInfo snapshotInfo = new SnapshotInfo(""); //$NON-NLS-1$
+
+        while (index < result.getOutput().size()) {
+            String line = result.getOutput().get(index);
+            Matcher matcher = LTTngControlServiceConstants.LIST_SNAPSHOT_OUTPUT_PATTERN.matcher(line);
+            if (matcher.matches()) {
+                snapshotInfo.setId(Integer.valueOf(matcher.group(1)));
+                snapshotInfo.setName(matcher.group(2));
+                snapshotInfo.setSnapshotPath(matcher.group(3));
+
+                Matcher matcher2 = LTTngControlServiceConstants.SNAPSHOT_NETWORK_PATH_PATTERN.matcher(snapshotInfo.getSnapshotPath());
+                if (matcher2.matches()) {
+                    snapshotInfo.setStreamedSnapshot(true);
+                }
+
+                index++;
+                break;
+            }
+            index++;
+        }
+
+        return snapshotInfo;
+    }
+
+    @Override
+    public List<IBaseEventInfo> getKernelProvider(IProgressMonitor monitor) throws ExecutionException {
+        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_LIST, LTTngControlServiceConstants.OPTION_KERNEL);
+        ICommandResult result = executeCommand(command, monitor, false);
+
+        List<IBaseEventInfo> events = new ArrayList<>();
+
+        // Ignore the following 2 cases:
+        // Spawning a session daemon
+        // Error: Unable to list kernel events
+        // or:
+        // Error: Unable to list kernel events
+        //
+        if (ignoredPattern(result.getErrorOutput(), LTTngControlServiceConstants.LIST_KERNEL_NO_KERNEL_PROVIDER_PATTERN)) {
+            return events;
+        }
+
+        if (isError(result)) {
+            throw new ExecutionException(Messages.TraceControl_CommandError + " " + command.toString() + "\n" + result.toString()); //$NON-NLS-1$ //$NON-NLS-2$
+        }
+
+        // Kernel events:
+        // -------------
+        // sched_kthread_stop (type: tracepoint)
+        getProviderEventInfo(result.getOutput(), 0, events);
+        return events;
+    }
+
+    @Override
+    public List<IUstProviderInfo> getUstProvider() throws ExecutionException {
+        return getUstProvider(new NullProgressMonitor());
+    }
+
+    @Override
+    public List<IUstProviderInfo> getUstProvider(IProgressMonitor monitor) throws ExecutionException {
+        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_LIST, LTTngControlServiceConstants.OPTION_UST);
+
+        if (isVersionSupported("2.1.0")) { //$NON-NLS-1$
+            command.add(LTTngControlServiceConstants.OPTION_FIELDS);
+        }
+
+        ICommandResult result = executeCommand(command, monitor, false);
+        List<IUstProviderInfo> allProviders = new ArrayList<>();
+
+        // Workaround for versions 2.0.x which causes a segmentation fault for
+        // this command
+        // if LTTng Tools is compiled without UST support.
+        if (!isVersionSupported("2.1.0") && (result.getResult() != 0)) { //$NON-NLS-1$
+            return allProviders;
+        }
+
+        // Ignore the following 2 cases:
+        // Spawning a session daemon
+        // Error: Unable to list UST events: Listing UST events failed
+        // or:
+        // Error: Unable to list UST events: Listing UST events failed
+        //
+        if (ignoredPattern(result.getErrorOutput(), LTTngControlServiceConstants.LIST_UST_NO_UST_PROVIDER_PATTERN)) {
+            return allProviders;
+        }
+
+        if (isError(result)) {
+            throw new ExecutionException(Messages.TraceControl_CommandError + " " + command.toString() + "\n" + result.toString()); //$NON-NLS-1$ //$NON-NLS-2$
+        }
+
+        // Note that field print-outs exists for version >= 2.1.0
+        //
+        // UST events:
+        // -------------
+        //
+        // PID: 3635 - Name:
+        // /home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello
+        // ust_tests_hello:tptest_sighandler (loglevel: TRACE_EMERG0) (type:
+        // tracepoint)
+        // ust_tests_hello:tptest (loglevel: TRACE_EMERG0) (type: tracepoint)
+        // field: doublefield (float)
+        // field: floatfield (float)
+        // field: stringfield (string)
+        //
+        // PID: 6459 - Name:
+        // /home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello
+        // ust_tests_hello:tptest_sighandler (loglevel: TRACE_EMERG0) (type:
+        // tracepoint)
+        // ust_tests_hello:tptest (loglevel: TRACE_EMERG0) (type: tracepoint)
+        // field: doublefield (float)
+        // field: floatfield (float)
+        // field: stringfield (string)
+
+        IUstProviderInfo provider = null;
+
+        int index = 0;
+        while (index < result.getOutput().size()) {
+            String line = result.getOutput().get(index);
+            Matcher matcher = LTTngControlServiceConstants.UST_PROVIDER_PATTERN.matcher(line);
+            if (matcher.matches()) {
+                provider = new UstProviderInfo(matcher.group(2).trim());
+                provider.setPid(Integer.valueOf(matcher.group(1).trim()));
+                List<IBaseEventInfo> events = new ArrayList<>();
+                index = getProviderEventInfo(result.getOutput(), ++index, events);
+                provider.setEvents(events);
+                allProviders.add(provider);
+            } else {
+                index++;
+            }
+        }
+        return allProviders;
+    }
+
+    @Override
+    public ISessionInfo createSession(ISessionInfo sessionInfo, IProgressMonitor monitor) throws ExecutionException {
+        if (sessionInfo.isStreamedTrace()) {
+            return createStreamedSession(sessionInfo, monitor);
+        }
+
+        ICommandInput command = prepareSessionCreationCommand(sessionInfo);
+
+        ICommandResult result = executeCommand(command, monitor);
+
+        // Session myssession2 created.
+        // Traces will be written in
+        // /home/user/lttng-traces/myssession2-20120209-095418
+        List<String> output = result.getOutput();
+
+        // Get and session name and path
+        String name = null;
+        String path = null;
+
+        for (String line : output) {
+            Matcher nameMatcher = LTTngControlServiceConstants.CREATE_SESSION_NAME_PATTERN.matcher(line);
+            Matcher pathMatcher = LTTngControlServiceConstants.CREATE_SESSION_PATH_PATTERN.matcher(line);
+            if (nameMatcher.matches()) {
+                name = String.valueOf(nameMatcher.group(1).trim());
+            } else if (pathMatcher.matches()) {
+                path = String.valueOf(pathMatcher.group(1).trim());
+            }
+        }
+
+        // Verify session name
+        if ((name == null) || (!"".equals(sessionInfo.getName()) && !name.equals(sessionInfo.getName()))) { //$NON-NLS-1$
+            // Unexpected name returned
+            throw new ExecutionException(Messages.TraceControl_CommandError + " " + command.toString() + "\n" + //$NON-NLS-1$ //$NON-NLS-2$
+                    Messages.TraceControl_UnexpectedNameError + ": " + name); //$NON-NLS-1$
+        }
+
+        sessionInfo.setName(name);
+        // Verify session path
+        if (!sessionInfo.isSnapshotSession() &&
+                ((path == null) || ((sessionInfo.getSessionPath() != null) && (!path.contains(sessionInfo.getSessionPath()))))) {
+            // Unexpected path
+            throw new ExecutionException(Messages.TraceControl_CommandError + " " + command.toString() + "\n" + //$NON-NLS-1$ //$NON-NLS-2$
+                    Messages.TraceControl_UnexpectedPathError + ": " + name); //$NON-NLS-1$
+        }
+
+        if (sessionInfo.isSnapshotSession()) {
+            // Make it a snapshot session - content of snapshot info need to
+            // set afterwards using getSession() or getSnapshotInfo()
+            sessionInfo.setSnapshotInfo(new SnapshotInfo("")); //$NON-NLS-1$
+        } else {
+            sessionInfo.setSessionPath(path);
+        }
+
+        return sessionInfo;
+
+    }
+
+    /**
+     * Basic generation of command for session creation
+     *
+     * @param sessionInfo
+     *            the session to create
+     * @return the basic command for command creation
+     */
+    protected @NonNull ICommandInput prepareSessionCreationCommand(ISessionInfo sessionInfo) {
+        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_CREATE_SESSION);
+        if (!sessionInfo.getName().isEmpty()) {
+            command.add(sessionInfo.getName());
+        }
+
+        String newPath = sessionInfo.getSessionPath();
+        if (newPath != null && !"".equals(newPath)) { //$NON-NLS-1$
+            command.add(LTTngControlServiceConstants.OPTION_OUTPUT_PATH);
+            command.add(newPath);
+        }
+
+        if (sessionInfo.isSnapshotSession()) {
+            command.add(LTTngControlServiceConstants.OPTION_SNAPSHOT);
+        }
+        return command;
+    }
+
+    private @NonNull ISessionInfo createStreamedSession(ISessionInfo sessionInfo, IProgressMonitor monitor) throws ExecutionException {
+
+        ICommandInput command = prepareStreamedSessionCreationCommand(sessionInfo);
+
+        ICommandResult result = executeCommand(command, monitor);
+
+        // Verify output
+        List<String> output = result.getOutput();
+
+        // Get and session name and path
+        String name = null;
+        String path = null;
+
+        for (String line : output) {
+            Matcher nameMatcher = LTTngControlServiceConstants.CREATE_SESSION_NAME_PATTERN.matcher(line);
+            Matcher pathMatcher = LTTngControlServiceConstants.CREATE_SESSION_PATH_PATTERN.matcher(line);
+
+            if (nameMatcher.matches()) {
+                name = String.valueOf(nameMatcher.group(1).trim());
+            } else if (pathMatcher.matches() && (sessionInfo.getNetworkUrl() != null)) {
+                path = String.valueOf(pathMatcher.group(1).trim());
+            }
+        }
+
+        // Verify session name
+        if ((name == null) || (!"".equals(sessionInfo.getName()) && !name.equals(sessionInfo.getName()))) { //$NON-NLS-1$
+            // Unexpected name returned
+            throw new ExecutionException(Messages.TraceControl_CommandError + " " + command.toString() + "\n" + //$NON-NLS-1$ //$NON-NLS-2$
+                    Messages.TraceControl_UnexpectedNameError + ": " + name); //$NON-NLS-1$
+        }
+
+        sessionInfo.setName(name);
+
+        sessionInfo.setStreamedTrace(true);
+
+        // Verify session path
+        if (sessionInfo.getNetworkUrl() != null) {
+            if (!sessionInfo.isSnapshotSession() && (path == null)) {
+                // Unexpected path
+                throw new ExecutionException(Messages.TraceControl_CommandError + " " + command.toString() + "\n" + //$NON-NLS-1$ //$NON-NLS-2$
+                        Messages.TraceControl_UnexpectedPathError + ": " + name); //$NON-NLS-1$
+            }
+
+            if (sessionInfo.isSnapshotSession()) {
+                sessionInfo.setStreamedTrace(false);
+            } else {
+                sessionInfo.setSessionPath(path);
+                // Check file protocol
+                Matcher matcher = LTTngControlServiceConstants.TRACE_FILE_PROTOCOL_PATTERN.matcher(path);
+                if (matcher.matches()) {
+                    sessionInfo.setStreamedTrace(false);
+                }
+            }
+        }
+
+        // When using controlUrl and dataUrl the full session path is not known
+        // yet and will be set later on when listing the session
+
+        return sessionInfo;
+    }
+
+    /**
+     * Basic generation of command for streamed session creation
+     *
+     * @param sessionInfo
+     *            the session to create
+     * @return the basic command for command creation
+     */
+     protected @NonNull ICommandInput prepareStreamedSessionCreationCommand(ISessionInfo sessionInfo) {
+        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_CREATE_SESSION);
+        if (!sessionInfo.getName().isEmpty()) {
+            command.add(sessionInfo.getName());
+        }
+
+        if (sessionInfo.isSnapshotSession()) {
+            command.add(LTTngControlServiceConstants.OPTION_SNAPSHOT);
+        } else if (sessionInfo.isLive()) {
+            command.add(LTTngControlServiceConstants.OPTION_LIVE);
+            if (sessionInfo.getLiveDelay() != LTTngControlServiceConstants.UNUSED_VALUE) {
+                command.add(String.valueOf(sessionInfo.getLiveDelay()));
+            }
+        }
+
+        if (sessionInfo.getNetworkUrl() != null) {
+            command.add(LTTngControlServiceConstants.OPTION_NETWORK_URL);
+            command.add(sessionInfo.getNetworkUrl());
+        } else {
+            command.add(LTTngControlServiceConstants.OPTION_CONTROL_URL);
+            command.add(sessionInfo.getControlUrl());
+
+            command.add(LTTngControlServiceConstants.OPTION_DATA_URL);
+            command.add(sessionInfo.getDataUrl());
+        }
+        return command;
+    }
+
+    @Override
+    public void destroySession(String sessionName, IProgressMonitor monitor) throws ExecutionException {
+
+        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_DESTROY_SESSION, sessionName);
+
+        ICommandResult result = executeCommand(command, monitor, false);
+        boolean isError = isError(result);
+        if (isError && !ignoredPattern(result.getErrorOutput(), LTTngControlServiceConstants.SESSION_NOT_FOUND_ERROR_PATTERN)) {
+            throw new ExecutionException(Messages.TraceControl_CommandError + " " + command.toString() + "\n" + result.toString()); //$NON-NLS-1$ //$NON-NLS-2$
+        }
+
+        // Session <sessionName> destroyed
+    }
+
+    @Override
+    public void startSession(String sessionName, IProgressMonitor monitor) throws ExecutionException {
+
+        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_START_SESSION, sessionName);
+
+        executeCommand(command, monitor);
+
+        // Session <sessionName> started
+    }
+
+    @Override
+    public void stopSession(String sessionName, IProgressMonitor monitor) throws ExecutionException {
+        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_STOP_SESSION, sessionName);
+
+        executeCommand(command, monitor);
+
+        // Session <sessionName> stopped
+
+    }
+
+    @Override
+    public void enableChannels(String sessionName, List<String> channelNames, boolean isKernel, IChannelInfo info, IProgressMonitor monitor) throws ExecutionException {
+
+        // no channels to enable
+        if (channelNames.isEmpty()) {
+            return;
+        }
+
+        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_ENABLE_CHANNEL);
+
+        command.add(toCsv(channelNames));
+
+        if (isKernel) {
+            command.add(LTTngControlServiceConstants.OPTION_KERNEL);
+        } else {
+            command.add(LTTngControlServiceConstants.OPTION_UST);
+        }
+
+        command.add(LTTngControlServiceConstants.OPTION_SESSION);
+        command.add(sessionName);
+
+        if (info != null) {
+            // --discard Discard event when buffers are full (default)
+
+            // --overwrite Flight recorder mode
+            if (info.isOverwriteMode()) {
+                command.add(LTTngControlServiceConstants.OPTION_OVERWRITE);
+            }
+            // --subbuf-size SIZE Subbuffer size in bytes
+            // (default: 4096, kernel default: 262144)
+            if (info.getSubBufferSize() != LTTngControlServiceConstants.UNUSED_VALUE) {
+                command.add(LTTngControlServiceConstants.OPTION_SUB_BUFFER_SIZE);
+                command.add(String.valueOf(info.getSubBufferSize()));
+            }
+
+            // --num-subbuf NUM Number of subbufers
+            if (info.getNumberOfSubBuffers() != LTTngControlServiceConstants.UNUSED_VALUE) {
+                command.add(LTTngControlServiceConstants.OPTION_NUM_SUB_BUFFERS);
+                command.add(String.valueOf(info.getNumberOfSubBuffers()));
+            }
+
+            // --switch-timer USEC Switch timer interval in usec
+            if (info.getSwitchTimer() != LTTngControlServiceConstants.UNUSED_VALUE) {
+                command.add(LTTngControlServiceConstants.OPTION_SWITCH_TIMER);
+                command.add(String.valueOf(info.getSwitchTimer()));
+            }
+
+            // --read-timer USEC Read timer interval in usec
+            if (info.getReadTimer() != LTTngControlServiceConstants.UNUSED_VALUE) {
+                command.add(LTTngControlServiceConstants.OPTION_READ_TIMER);
+                command.add(String.valueOf(info.getReadTimer()));
+            }
+
+            if (isVersionSupported("2.2.0")) { //$NON-NLS-1$
+                // --buffers-uid Every application sharing the same UID use the
+                // same buffers --buffers-pid Buffers are allocated per PID
+                if (!isKernel) {
+                    if (info.getBufferType() == BufferType.BUFFER_PER_PID) {
+                        command.add(LTTngControlServiceConstants.OPTION_PER_PID_BUFFERS);
+
+                    } else if (info.getBufferType() == BufferType.BUFFER_PER_UID) {
+                        command.add(LTTngControlServiceConstants.OPTION_PER_UID_BUFFERS);
+                    }
+                }
+
+                // -C SIZE Maximum size of trace files in bytes
+                if (info.getMaxSizeTraceFiles() != LTTngControlServiceConstants.UNUSED_VALUE) {
+                    command.add(LTTngControlServiceConstants.OPTION_MAX_SIZE_TRACE_FILES);
+                    command.add(String.valueOf(info.getMaxSizeTraceFiles()));
+                }
+
+                // -W NUM Maximum number of trace files
+                if (info.getMaxNumberTraceFiles() != LTTngControlServiceConstants.UNUSED_VALUE) {
+                    command.add(LTTngControlServiceConstants.OPTION_MAX_TRACE_FILES);
+                    command.add(String.valueOf(info.getMaxNumberTraceFiles()));
+                }
+            }
+        }
+
+        executeCommand(command, monitor);
+
+    }
+
+    @Override
+    public void disableChannels(String sessionName, List<String> channelNames, boolean isKernel, IProgressMonitor monitor) throws ExecutionException {
+
+        // no channels to enable
+        if (channelNames.isEmpty()) {
+            return;
+        }
+
+        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_DISABLE_CHANNEL);
+
+        command.add(toCsv(channelNames));
+
+        if (isKernel) {
+            command.add(LTTngControlServiceConstants.OPTION_KERNEL);
+        } else {
+            command.add(LTTngControlServiceConstants.OPTION_UST);
+        }
+
+        command.add(LTTngControlServiceConstants.OPTION_SESSION);
+        command.add(sessionName);
+
+        executeCommand(command, monitor);
+    }
+
+    @Override
+    public void enableEvents(String sessionName, String channelName, List<String> eventNames, boolean isKernel, String filterExpression, IProgressMonitor monitor) throws ExecutionException {
+
+        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_ENABLE_EVENT);
+
+        if (eventNames == null || eventNames.isEmpty()) {
+            command.add(LTTngControlServiceConstants.OPTION_ALL);
+        } else {
+            command.add(toCsv(eventNames));
+        }
+
+        if (isKernel) {
+            command.add(LTTngControlServiceConstants.OPTION_KERNEL);
+        } else {
+            command.add(LTTngControlServiceConstants.OPTION_UST);
+        }
+
+        command.add(LTTngControlServiceConstants.OPTION_SESSION);
+        command.add(sessionName);
+
+        if (channelName != null) {
+            command.add(LTTngControlServiceConstants.OPTION_CHANNEL);
+            command.add(channelName);
+        }
+
+        command.add(LTTngControlServiceConstants.OPTION_TRACEPOINT);
+
+        if (filterExpression != null) {
+            command.add(LTTngControlServiceConstants.OPTION_FILTER);
+            command.add(filterExpression);
+        }
+
+        executeCommand(command, monitor);
+
+    }
+
+    @Override
+    public void enableSyscalls(String sessionName, String channelName, IProgressMonitor monitor) throws ExecutionException {
+
+        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_ENABLE_EVENT);
+
+        command.add(LTTngControlServiceConstants.OPTION_ALL);
+        command.add(LTTngControlServiceConstants.OPTION_KERNEL);
+
+
+        command.add(LTTngControlServiceConstants.OPTION_SESSION);
+        command.add(sessionName);
+
+        if (channelName != null) {
+            command.add(LTTngControlServiceConstants.OPTION_CHANNEL);
+            command.add(channelName);
+        }
+
+        command.add(LTTngControlServiceConstants.OPTION_SYSCALL);
+
+        executeCommand(command, monitor);
+    }
+
+    @Override
+    public void enableProbe(String sessionName, String channelName, String eventName, boolean isFunction, String probe, IProgressMonitor monitor) throws ExecutionException {
+        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_ENABLE_EVENT);
+
+        command.add(eventName);
+        command.add(LTTngControlServiceConstants.OPTION_KERNEL);
+
+        command.add(LTTngControlServiceConstants.OPTION_SESSION);
+        command.add(sessionName);
+
+        if (channelName != null) {
+            command.add(LTTngControlServiceConstants.OPTION_CHANNEL);
+            command.add(channelName);
+        }
+        if (isFunction) {
+            command.add(LTTngControlServiceConstants.OPTION_FUNCTION_PROBE);
+        } else {
+            command.add(LTTngControlServiceConstants.OPTION_PROBE);
+        }
+
+        command.add(probe);
+
+        executeCommand(command, monitor);
+    }
+
+    @Override
+    public void enableLogLevel(String sessionName, String channelName, String eventName, LogLevelType logLevelType, TraceLogLevel level, String filterExpression, IProgressMonitor monitor) throws ExecutionException {
+        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_ENABLE_EVENT);
+
+        command.add(eventName);
+        command.add(LTTngControlServiceConstants.OPTION_UST);
+
+        command.add(LTTngControlServiceConstants.OPTION_SESSION);
+        command.add(sessionName);
+
+        if (channelName != null) {
+            command.add(LTTngControlServiceConstants.OPTION_CHANNEL);
+            command.add(channelName);
+        }
+
+        if (logLevelType == LogLevelType.LOGLEVEL) {
+            command.add(LTTngControlServiceConstants.OPTION_LOGLEVEL);
+        } else if (logLevelType == LogLevelType.LOGLEVEL_ONLY) {
+            command.add(LTTngControlServiceConstants.OPTION_LOGLEVEL_ONLY);
+
+        } else {
+            return;
+        }
+        command.add(level.getInName());
+
+        executeCommand(command, monitor);
+    }
+
+    @Override
+    public void disableEvent(String sessionName, String channelName, List<String> eventNames, boolean isKernel, IProgressMonitor monitor) throws ExecutionException {
+        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_DISABLE_EVENT);
+
+        if (eventNames == null) {
+            command.add(LTTngControlServiceConstants.OPTION_ALL);
+        } else {
+            // no events to disable
+            if (eventNames.isEmpty()) {
+                return;
+            }
+
+            StringBuffer eventNameParameter = new StringBuffer();
+            for (Iterator<String> iterator = eventNames.iterator(); iterator.hasNext();) {
+                String event = iterator.next();
+                eventNameParameter.append(event);
+                if (iterator.hasNext()) {
+                    eventNameParameter.append(',');
+                }
+            }
+            command.add(eventNameParameter.toString());
+        }
+
+        if (isKernel) {
+            command.add(LTTngControlServiceConstants.OPTION_KERNEL);
+        } else {
+            command.add(LTTngControlServiceConstants.OPTION_UST);
+        }
+
+        command.add(LTTngControlServiceConstants.OPTION_SESSION);
+        command.add(sessionName);
+
+        if (channelName != null) {
+            command.add(LTTngControlServiceConstants.OPTION_CHANNEL);
+            command.add(channelName);
+        }
+
+        executeCommand(command, monitor);
+    }
+
+    @Override
+    public List<String> getContextList(IProgressMonitor monitor) throws ExecutionException {
+
+        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_ADD_CONTEXT, LTTngControlServiceConstants.OPTION_HELP);
+
+        ICommandResult result = executeCommand(command, monitor);
+
+        List<String> output = result.getOutput();
+
+        List<String> contexts = new ArrayList<>(0);
+
+        int index = 0;
+        boolean inList = false;
+        while (index < output.size()) {
+            String line = output.get(index);
+
+            Matcher startMatcher = LTTngControlServiceConstants.ADD_CONTEXT_HELP_CONTEXTS_INTRO.matcher(line);
+            Matcher endMatcher = LTTngControlServiceConstants.ADD_CONTEXT_HELP_CONTEXTS_END_LINE.matcher(line);
+
+            if (startMatcher.matches()) {
+                inList = true;
+            } else if (endMatcher.matches()) {
+                break;
+            } else if (inList == true) {
+                String[] tmp = line.split(","); //$NON-NLS-1$
+                for (int i = 0; i < tmp.length; i++) {
+                    contexts.add(tmp[i].trim());
+                }
+            }
+            index++;
+        }
+        return contexts;
+    }
+
+    @Override
+    public void addContexts(String sessionName, String channelName, String eventName, boolean isKernel, List<String> contextNames, IProgressMonitor monitor) throws ExecutionException {
+        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_ADD_CONTEXT);
+
+        command.add(LTTngControlServiceConstants.OPTION_SESSION);
+        command.add(sessionName);
+
+        if (channelName != null) {
+            command.add(LTTngControlServiceConstants.OPTION_CHANNEL);
+            command.add(channelName);
+        }
+
+        if (eventName != null) {
+            command.add(LTTngControlServiceConstants.OPTION_EVENT);
+            command.add(eventName);
+        }
+
+        if (isKernel) {
+            command.add(LTTngControlServiceConstants.OPTION_KERNEL);
+        } else {
+            command.add(LTTngControlServiceConstants.OPTION_UST);
+        }
+
+        for (Iterator<String> iterator = contextNames.iterator(); iterator.hasNext();) {
+            String context = iterator.next();
+            command.add(LTTngControlServiceConstants.OPTION_CONTEXT_TYPE);
+            command.add(context);
+        }
+
+        executeCommand(command, monitor);
+
+    }
+
+    @Override
+    public void calibrate(boolean isKernel, IProgressMonitor monitor) throws ExecutionException {
+        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_CALIBRATE);
+
+        if (isKernel) {
+            command.add(LTTngControlServiceConstants.OPTION_KERNEL);
+        } else {
+            command.add(LTTngControlServiceConstants.OPTION_UST);
+        }
+
+        command.add(LTTngControlServiceConstants.OPTION_FUNCTION_PROBE);
+
+        executeCommand(command, monitor);
+    }
+
+    @Override
+    public void recordSnapshot(String sessionName, IProgressMonitor monitor)
+            throws ExecutionException {
+        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_SNAPSHOT, LTTngControlServiceConstants.COMMAND_RECORD_SNAPSHOT);
+
+        String newSessionName = sessionName;
+        command.add(LTTngControlServiceConstants.OPTION_SESSION);
+        command.add(newSessionName);
+
+        executeCommand(command, monitor);
+    }
+
+    @Override
+    public void runCommands(IProgressMonitor monitor, List<String> commandLines) throws ExecutionException {
+        for (String commandLine : commandLines) {
+            if (monitor.isCanceled()) {
+                return;
+            }
+
+            if (commandLine.isEmpty() || commandLine.startsWith("#")) { //$NON-NLS-1$
+                continue;
+            }
+            String[] args = commandLine.split("\\s+"); //$NON-NLS-1$
+            ICommandInput command = fCommandShell.createCommand();
+            command.addAll(checkNotNull(Arrays.asList(args)));
+            ICommandResult result = executeCommand(command, monitor);
+
+            if (isError(result)) {
+                throw new ExecutionException(Messages.TraceControl_CommandError + " " + command.toString() + "\n" + result.toString()); //$NON-NLS-1$ //$NON-NLS-2$
+            }
+        }
+    }
+
+    // ------------------------------------------------------------------------
+    // Helper methods
+    // ------------------------------------------------------------------------
+
+    /**
+     * Checks if command result is an error result.
+     *
+     * @param result
+     *            - the command result to check
+     * @return true if error else false
+     */
+    protected boolean isError(ICommandResult result) {
+        // Check return code and length of returned strings
+
+        if ((result.getResult()) != 0) {
+            return true;
+        }
+
+        // Look for error pattern
+        for (String line : result.getErrorOutput()) {
+            Matcher matcher = LTTngControlServiceConstants.ERROR_PATTERN.matcher(line);
+            if (matcher.matches()) {
+                return true;
+            }
+        }
+
+        return false;
+    }
+
+    /**
+     * Creates a comma separated string from list of names
+     * @param names
+     *          List of name to convert
+     * @return comma separated string
+     */
+    protected String toCsv(List<String> names) {
+        StringBuilder csvString = new StringBuilder();
+        for (Iterator<String> iterator = names.iterator(); iterator.hasNext();) {
+            String name = iterator.next();
+            csvString.append(name);
+            if (iterator.hasNext()) {
+                csvString.append(',');
+            }
+        }
+        return csvString.toString();
+    }
+
+    /**
+     * Parses the domain information.
+     *
+     * @param output
+     *            a command output list
+     * @param currentIndex
+     *            current index in command output list
+     * @param channels
+     *            list for returning channel information
+     * @param domainInfo
+     *            The domain information
+     * @return the new current index in command output list
+     */
+    protected int parseDomain(List<String> output, int currentIndex, List<IChannelInfo> channels, IDomainInfo domainInfo) {
+        int index = currentIndex;
+
+        // if kernel set the buffer type to shared
+        if (domainInfo.isKernel()) {
+            domainInfo.setBufferType(BufferType.BUFFER_SHARED);
+        }
+
+        // Channels:
+        // -------------
+        // - channnel1: [enabled]
+        //
+        // Attributes:
+        // overwrite mode: 0
+        // subbufers size: 262144
+        // number of subbufers: 4
+        // switch timer interval: 0
+        // read timer interval: 200
+        // output: splice()
+
+        while (index < output.size()) {
+            String line = output.get(index);
+
+            if (isVersionSupported("2.2.0")) { //$NON-NLS-1$
+                Matcher bufferTypeMatcher = LTTngControlServiceConstants.BUFFER_TYPE_PATTERN.matcher(line);
+                if (bufferTypeMatcher.matches()) {
+                    String bufferTypeString = getAttributeValue(line);
+                    if (BufferType.BUFFER_PER_PID.getInName().equals(bufferTypeString)) {
+                        domainInfo.setBufferType(BufferType.BUFFER_PER_PID);
+                    } else if (BufferType.BUFFER_PER_UID.getInName().equals(bufferTypeString)) {
+                        domainInfo.setBufferType(BufferType.BUFFER_PER_UID);
+                    } else {
+                        domainInfo.setBufferType(BufferType.BUFFER_TYPE_UNKNOWN);
+                    }
+                }
+            } else {
+                domainInfo.setBufferType(BufferType.BUFFER_TYPE_UNKNOWN);
+            }
+            Matcher outerMatcher = LTTngControlServiceConstants.CHANNELS_SECTION_PATTERN.matcher(line);
+            Matcher noKernelChannelMatcher = LTTngControlServiceConstants.DOMAIN_NO_KERNEL_CHANNEL_PATTERN.matcher(line);
+            Matcher noUstChannelMatcher = LTTngControlServiceConstants.DOMAIN_NO_UST_CHANNEL_PATTERN.matcher(line);
+            if (outerMatcher.matches()) {
+                IChannelInfo channelInfo = null;
+                while (index < output.size()) {
+                    String subLine = output.get(index);
+
+                    Matcher innerMatcher = LTTngControlServiceConstants.CHANNEL_PATTERN.matcher(subLine);
+                    if (innerMatcher.matches()) {
+                        channelInfo = new ChannelInfo(""); //$NON-NLS-1$
+                        // get channel name
+                        channelInfo.setName(innerMatcher.group(1));
+
+                        // get channel enablement
+                        channelInfo.setState(innerMatcher.group(2));
+
+                        // set BufferType
+                        channelInfo.setBufferType(domainInfo.getBufferType());
+
+                        // add channel
+                        channels.add(channelInfo);
+
+                    } else if (LTTngControlServiceConstants.OVERWRITE_MODE_ATTRIBUTE.matcher(subLine).matches()) {
+                        String value = getAttributeValue(subLine);
+                        if (channelInfo != null) {
+                            channelInfo.setOverwriteMode(!LTTngControlServiceConstants.OVERWRITE_MODE_ATTRIBUTE_FALSE.equals(value));
+                        }
+                    } else if (LTTngControlServiceConstants.SUBBUFFER_SIZE_ATTRIBUTE.matcher(subLine).matches()) {
+                        if (channelInfo != null) {
+                            channelInfo.setSubBufferSize(Long.valueOf(getAttributeValue(subLine)));
+                        }
+
+                    } else if (LTTngControlServiceConstants.NUM_SUBBUFFERS_ATTRIBUTE.matcher(subLine).matches()) {
+                        if (channelInfo != null) {
+                            channelInfo.setNumberOfSubBuffers(Integer.valueOf(getAttributeValue(subLine)));
+                        }
+
+                    } else if (LTTngControlServiceConstants.SWITCH_TIMER_ATTRIBUTE.matcher(subLine).matches()) {
+                        if (channelInfo != null) {
+                            channelInfo.setSwitchTimer(Long.valueOf(getAttributeValue(subLine)));
+                        }
+
+                    } else if (LTTngControlServiceConstants.READ_TIMER_ATTRIBUTE.matcher(subLine).matches()) {
+                        if (channelInfo != null) {
+                            channelInfo.setReadTimer(Long.valueOf(getAttributeValue(subLine)));
+                        }
+
+                    } else if (LTTngControlServiceConstants.OUTPUT_ATTRIBUTE.matcher(subLine).matches()) {
+                        if (channelInfo != null) {
+                            channelInfo.setOutputType(getAttributeValue(subLine));
+                        }
+
+                    } else if (LTTngControlServiceConstants.TRACE_FILE_COUNT_ATTRIBUTE.matcher(subLine).matches()) {
+                        if (channelInfo != null) {
+                            channelInfo.setMaxNumberTraceFiles(Integer.valueOf(getAttributeValue(subLine)));
+                        }
+
+                    } else if (LTTngControlServiceConstants.TRACE_FILE_SIZE_ATTRIBUTE.matcher(subLine).matches()) {
+                        if (channelInfo != null) {
+                            channelInfo.setMaxSizeTraceFiles(Long.valueOf(getAttributeValue(subLine)));
+                        }
+                    } else if (LTTngControlServiceConstants.EVENT_SECTION_PATTERN.matcher(subLine).matches()) {
+                        List<IEventInfo> events = new ArrayList<>();
+                        index = parseEvents(output, index, events);
+                        if (channelInfo != null) {
+                            channelInfo.setEvents(events);
+                        }
+                        // we want to stay at the current index to be able to
+                        // exit the domain
+                        continue;
+                    } else if (LTTngControlServiceConstants.DOMAIN_KERNEL_PATTERN.matcher(subLine).matches()) {
+                        return index;
+
+                    } else if (LTTngControlServiceConstants.DOMAIN_UST_GLOBAL_PATTERN.matcher(subLine).matches()) {
+                        return index;
+                    }
+                    index++;
+                }
+            } else if (noKernelChannelMatcher.matches() || noUstChannelMatcher.matches()) {
+                // domain indicates that no channels were found -> return
+                index++;
+                return index;
+            }
+            index++;
+        }
+        return index;
+    }
+
+    /**
+     * Parses the event information within a domain.
+     *
+     * @param output
+     *            a command output list
+     * @param currentIndex
+     *            current index in command output list
+     * @param events
+     *            list for returning event information
+     * @return the new current index in command output list
+     */
+    protected int parseEvents(List<String> output, int currentIndex, List<IEventInfo> events) {
+        int index = currentIndex;
+
+        while (index < output.size()) {
+            String line = output.get(index);
+            if (LTTngControlServiceConstants.CHANNEL_PATTERN.matcher(line).matches()) {
+                // end of channel
+                return index;
+            } else if (LTTngControlServiceConstants.DOMAIN_KERNEL_PATTERN.matcher(line).matches()) {
+                // end of domain
+                return index;
+            } else if (LTTngControlServiceConstants.DOMAIN_UST_GLOBAL_PATTERN.matcher(line).matches()) {
+                // end of domain
+                return index;
+            }
+
+            Matcher matcher = LTTngControlServiceConstants.EVENT_PATTERN.matcher(line);
+            Matcher matcher2 = LTTngControlServiceConstants.WILDCARD_EVENT_PATTERN.matcher(line);
+
+            if (matcher.matches()) {
+                IEventInfo eventInfo = new EventInfo(matcher.group(1).trim());
+                eventInfo.setLogLevelType(matcher.group(2).trim());
+                eventInfo.setLogLevel(matcher.group(3).trim());
+                eventInfo.setEventType(matcher.group(4).trim());
+                eventInfo.setState(matcher.group(5));
+                String filter = matcher.group(6);
+                if (filter != null) {
+                    // remove '[' and ']'
+                    filter = filter.substring(1, filter.length() - 1);
+                    eventInfo.setFilterExpression(filter);
+                }
+                events.add(eventInfo);
+                index++;
+            } else if (matcher2.matches()) {
+                IEventInfo eventInfo = new EventInfo(matcher2.group(1).trim());
+                eventInfo.setLogLevel(TraceLogLevel.LEVEL_UNKNOWN);
+                eventInfo.setEventType(matcher2.group(2).trim());
+                eventInfo.setState(matcher2.group(3));
+                String filter = matcher2.group(4);
+                if (filter != null) {
+                    // remove '[' and ']'
+                    filter = filter.substring(1, filter.length() - 1);
+                    eventInfo.setFilterExpression(filter);
+                }
+
+                if ((eventInfo.getEventType() == TraceEventType.PROBE) ||
+                        (eventInfo.getEventType() == TraceEventType.FUNCTION)) {
+                    IProbeEventInfo probeEvent = new ProbeEventInfo(eventInfo.getName());
+                    probeEvent.setLogLevel(eventInfo.getLogLevel());
+                    probeEvent.setEventType(eventInfo.getEventType());
+                    probeEvent.setState(eventInfo.getState());
+
+                    // Overwrite eventinfo
+                    eventInfo = probeEvent;
+
+                    // myevent2 (type: probe) [enabled]
+                    // addr: 0xc0101340
+                    // myevent0 (type: function) [enabled]
+                    // offset: 0x0
+                    // symbol: init_post
+                    index++;
+                    while (index < output.size()) {
+                        String probeLine = output.get(index);
+                        // parse probe
+                        Matcher addrMatcher = LTTngControlServiceConstants.PROBE_ADDRESS_PATTERN.matcher(probeLine);
+                        Matcher offsetMatcher = LTTngControlServiceConstants.PROBE_OFFSET_PATTERN.matcher(probeLine);
+                        Matcher symbolMatcher = LTTngControlServiceConstants.PROBE_SYMBOL_PATTERN.matcher(probeLine);
+                        if (addrMatcher.matches()) {
+                            String addr = addrMatcher.group(2).trim();
+                            probeEvent.setAddress(addr);
+                        } else if (offsetMatcher.matches()) {
+                            String offset = offsetMatcher.group(2).trim();
+                            probeEvent.setOffset(offset);
+                        } else if (symbolMatcher.matches()) {
+                            String symbol = symbolMatcher.group(2).trim();
+                            probeEvent.setSymbol(symbol);
+                        } else if ((LTTngControlServiceConstants.EVENT_PATTERN.matcher(probeLine).matches()) || (LTTngControlServiceConstants.WILDCARD_EVENT_PATTERN.matcher(probeLine).matches())) {
+                            break;
+                        } else if (LTTngControlServiceConstants.CHANNEL_PATTERN.matcher(probeLine).matches()) {
+                            break;
+                        } else if (LTTngControlServiceConstants.DOMAIN_KERNEL_PATTERN.matcher(probeLine).matches()) {
+                            // end of domain
+                            break;
+                        } else if (LTTngControlServiceConstants.DOMAIN_UST_GLOBAL_PATTERN.matcher(probeLine).matches()) {
+                            // end of domain
+                            break;
+                        }
+                        index++;
+                    }
+                    events.add(eventInfo);
+                } else {
+                    events.add(eventInfo);
+                    index++;
+                    continue;
+                }
+            } else {
+                index++;
+            }
+        }
+
+        return index;
+    }
+
+    /**
+     * Parses a line with attributes: <attribute Name>: <attribute value>
+     *
+     * @param line
+     *            - attribute line to parse
+     * @return the attribute value as string
+     */
+    protected String getAttributeValue(String line) {
+        String[] temp = line.split("\\: "); //$NON-NLS-1$
+        return temp[1];
+    }
+
+    /**
+     * Parses the event information within a provider.
+     *
+     * @param output
+     *            a command output list
+     * @param currentIndex
+     *            current index in command output list
+     * @param events
+     *            list for returning event information
+     * @return the new current index in command output list
+     */
+    protected int getProviderEventInfo(List<String> output, int currentIndex, List<IBaseEventInfo> events) {
+        int index = currentIndex;
+        IBaseEventInfo eventInfo = null;
+        while (index < output.size()) {
+            String line = output.get(index);
+            Matcher matcher = LTTngControlServiceConstants.PROVIDER_EVENT_PATTERN.matcher(line);
+            if (matcher.matches()) {
+                // sched_kthread_stop (loglevel: TRACE_EMERG0) (type:
+                // tracepoint)
+                eventInfo = new BaseEventInfo(matcher.group(1).trim());
+                eventInfo.setLogLevel(matcher.group(2).trim());
+                eventInfo.setEventType(matcher.group(3).trim());
+                events.add(eventInfo);
+                index++;
+            } else if (LTTngControlServiceConstants.EVENT_FIELD_PATTERN.matcher(line).matches()) {
+                if (eventInfo != null) {
+                    List<IFieldInfo> fields = new ArrayList<>();
+                    index = getFieldInfo(output, index, fields);
+                    eventInfo.setFields(fields);
+                } else {
+                    index++;
+                }
+            }
+            else if (LTTngControlServiceConstants.UST_PROVIDER_PATTERN.matcher(line).matches()) {
+                return index;
+            } else {
+                index++;
+            }
+        }
+        return index;
+    }
+
+    /**
+     * Parse a field's information.
+     *
+     * @param output
+     *            A command output list
+     * @param currentIndex
+     *            The current index in the command output list
+     * @param fields
+     *            List for returning the field information
+     * @return The new current index in the command output list
+     */
+    protected int getFieldInfo(List<String> output, int currentIndex, List<IFieldInfo> fields) {
+        int index = currentIndex;
+        IFieldInfo fieldInfo = null;
+        while (index < output.size()) {
+            String line = output.get(index);
+            Matcher matcher = LTTngControlServiceConstants.EVENT_FIELD_PATTERN.matcher(line);
+            if (matcher.matches()) {
+                // field: content (string)
+                fieldInfo = new FieldInfo(matcher.group(2).trim());
+                fieldInfo.setFieldType(matcher.group(3).trim());
+                fields.add(fieldInfo);
+            } else if (LTTngControlServiceConstants.PROVIDER_EVENT_PATTERN.matcher(line).matches()) {
+                return index;
+            } else if (LTTngControlServiceConstants.UST_PROVIDER_PATTERN.matcher(line).matches()) {
+                return index;
+            }
+            index++;
+        }
+        return index;
+    }
+
+    /**
+     * Creates a command input instance
+     *
+     * @param segments
+     *            array of string that makes up a command line
+     * @return {@link ICommandInput} instance
+     */
+    protected @NonNull ICommandInput createCommand(String... segments) {
+        ICommandInput command = fCommandShell.createCommand();
+        command.add(LTTngControlServiceConstants.CONTROL_COMMAND);
+        List<String> groupOption = getTracingGroupOption();
+        if (!groupOption.isEmpty()) {
+            command.addAll(groupOption);
+        }
+        String verboseOption = getVerboseOption();
+        if (!verboseOption.isEmpty()) {
+            command.add(verboseOption);
+        }
+        for (String string : segments) {
+            command.add(checkNotNull(string));
+        }
+        return command;
+    }
+
+    /**
+     * @return the tracing group option if configured in the preferences
+     */
+    protected @NonNull List<String> getTracingGroupOption() {
+        List<String> groupOption = new ArrayList<>();
+        if (!ControlPreferences.getInstance().isDefaultTracingGroup() && !ControlPreferences.getInstance().getTracingGroup().equals("")) { //$NON-NLS-1$
+            groupOption.add(LTTngControlServiceConstants.OPTION_TRACING_GROUP);
+            groupOption.add(ControlPreferences.getInstance().getTracingGroup());
+        }
+        return groupOption;
+    }
+
+    /**
+     * @return the verbose option as configured in the preferences
+     */
+    protected String getVerboseOption() {
+        if (ControlPreferences.getInstance().isLoggingEnabled()) {
+            String level = ControlPreferences.getInstance().getVerboseLevel();
+            if (ControlPreferences.TRACE_CONTROL_VERBOSE_LEVEL_VERBOSE.equals(level)) {
+                return LTTngControlServiceConstants.OPTION_VERBOSE;
+            }
+            if (ControlPreferences.TRACE_CONTROL_VERBOSE_LEVEL_V_VERBOSE.equals(level)) {
+                return LTTngControlServiceConstants.OPTION_VERY_VERBOSE;
+            }
+            if (ControlPreferences.TRACE_CONTROL_VERBOSE_LEVEL_V_V_VERBOSE.equals(level)) {
+                return LTTngControlServiceConstants.OPTION_VERY_VERY_VERBOSE;
+            }
+        }
+        return ""; //$NON-NLS-1$
+    }
+
+    /**
+     * Method that logs the command and command result if logging is enabled as
+     * well as forwards the command execution to the shell.
+     *
+     * @param command
+     *            - the command to execute
+     * @param monitor
+     *            - a progress monitor
+     * @return the command result
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    protected ICommandResult executeCommand(@NonNull ICommandInput command,
+            @Nullable IProgressMonitor monitor) throws ExecutionException {
+        return executeCommand(command, monitor, true);
+    }
+
+    /**
+     * Method that logs the command and command result if logging is enabled as
+     * well as forwards the command execution to the shell.
+     *
+     * @param command
+     *            - the command to execute
+     * @param monitor
+     *            - a progress monitor
+     * @param checkForError
+     *            - true to verify command result, else false
+     * @return the command result
+     * @throws ExecutionException
+     *             in case of error result
+     */
+    protected ICommandResult executeCommand(@NonNull ICommandInput command,
+            @Nullable IProgressMonitor monitor, boolean checkForError)
+            throws ExecutionException {
+        if (ControlPreferences.getInstance().isLoggingEnabled()) {
+            ControlCommandLogger.log(command.toString());
+        }
+
+        ICommandResult result = fCommandShell.executeCommand(command, monitor);
+
+        if (ControlPreferences.getInstance().isLoggingEnabled()) {
+            ControlCommandLogger.log(result.toString());
+        }
+
+        if (checkForError && isError(result)) {
+            throw new ExecutionException(Messages.TraceControl_CommandError
+                    + " " + command.toString() + "\n" + result.toString()); //$NON-NLS-1$ //$NON-NLS-2$
+        }
+
+        return result;
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/service/LTTngControlServiceConstants.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/service/LTTngControlServiceConstants.java
new file mode 100644 (file)
index 0000000..7190e78
--- /dev/null
@@ -0,0 +1,474 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2015 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
+ *   Simon Delisle - Updated for support of LTTng Tools 2.2
+ *   Marc-Andre Laperle - Support for creating a live session
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.service;
+
+import static org.eclipse.tracecompass.common.core.NonNullUtils.checkNotNull;
+
+import java.util.regex.Pattern;
+
+import org.eclipse.jdt.annotation.NonNullByDefault;
+
+/**
+ * <p>
+ * Constants for LTTng Control Service.
+ * </p>
+ *
+ * @author Bernd Hufmann
+ */
+@NonNullByDefault
+public interface LTTngControlServiceConstants {
+
+    // ------------------------------------------------------------------------
+    // Version constants
+    // ------------------------------------------------------------------------
+    /**
+     * Pattern to match the LTTng toolchain version 2.x.y.
+     */
+    Pattern VERSION_2_PATTERN = checkNotNull(Pattern.compile("(2\\.\\d+\\.\\d+).*")); //$NON-NLS-1$
+
+    // ------------------------------------------------------------------------
+    // Constants
+    // ------------------------------------------------------------------------
+    /**
+     * Unused value
+     */
+    int UNUSED_VALUE = -1;
+    /**
+     * String representation of numerical true element
+     */
+    String TRUE_NUMERICAL = "1"; //$NON-NLS-1$
+
+    // ------------------------------------------------------------------------
+    // LTTng Machine Interface constants
+    // ------------------------------------------------------------------------
+
+    /**
+     * Name of the XSD to validate against the xml machine interface
+     * output from LTTng
+     */
+    String MI_XSD_FILENAME = "mi_lttng.xsd"; //$NON-NLS-1$
+    // ------------------------------------------------------------------------
+    // Command constants
+    // ------------------------------------------------------------------------
+    /**
+     * The lttng tools command.
+     */
+    String CONTROL_COMMAND = "lttng"; //$NON-NLS-1$
+    /**
+     * The lttng tools machine interface command.
+     */
+    String CONTROL_COMMAND_MI_OPTION = "--mi"; //$NON-NLS-1$
+    /**
+     * The lttng tools XML machine interface command.
+     */
+    String CONTROL_COMMAND_MI_XML = "xml"; //$NON-NLS-1$
+    /**
+     * Command: lttng version.
+     */
+    String COMMAND_VERSION = "version"; //$NON-NLS-1$
+    /**
+     * Command: lttng list.
+     */
+    String COMMAND_LIST = "list"; //$NON-NLS-1$
+    /**
+     * Command to create a session.
+     */
+    String COMMAND_CREATE_SESSION = "create"; //$NON-NLS-1$
+    /**
+     * Command to destroy a session.
+     */
+    String COMMAND_DESTROY_SESSION = "destroy"; //$NON-NLS-1$
+    /**
+     * Command to destroy a session.
+     */
+    String COMMAND_START_SESSION = "start"; //$NON-NLS-1$
+    /**
+     * Command to destroy a session.
+     */
+    String COMMAND_STOP_SESSION = "stop"; //$NON-NLS-1$
+    /**
+     * Command to enable a channel.
+     */
+    String COMMAND_ENABLE_CHANNEL = "enable-channel"; //$NON-NLS-1$
+    /**
+     * Command to disable a channel.
+     */
+    String COMMAND_DISABLE_CHANNEL = "disable-channel"; //$NON-NLS-1$
+    /**
+     * Command to enable a event.
+     */
+    String COMMAND_ENABLE_EVENT = "enable-event"; //$NON-NLS-1$
+    /**
+     * Command to disable a event.
+     */
+    String COMMAND_DISABLE_EVENT = "disable-event"; //$NON-NLS-1$
+    /**
+     * Command to add a context to channels and/or events
+     */
+    String COMMAND_ADD_CONTEXT = "add-context"; //$NON-NLS-1$
+    /**
+     * Command to execute calibrate command to quantify LTTng overhead
+     */
+    String COMMAND_CALIBRATE = "calibrate"; //$NON-NLS-1$
+    /**
+     * Command to execute sub-command snapshot
+     */
+    String COMMAND_SNAPSHOT = "snapshot"; //$NON-NLS-1$
+    /**
+     * Command to list the snapshot outputs
+     */
+    String COMMAND_LIST_SNAPSHOT_OUTPUT = "list-output"; //$NON-NLS-1$
+    /**
+     * Command to record a snapshot
+     */
+    String COMMAND_RECORD_SNAPSHOT = "record"; //$NON-NLS-1$
+
+    // ------------------------------------------------------------------------
+    // Command line options constants
+    // ------------------------------------------------------------------------
+    /**
+     * Command line option to add tracing group of user.
+     */
+    String OPTION_TRACING_GROUP = "-g";  //$NON-NLS-1$
+    /**
+     * Command line option for verbose output.
+     */
+    String OPTION_VERBOSE = "-v";  //$NON-NLS-1$
+    /**
+     * Command line option for verbose output.
+     */
+    String OPTION_VERY_VERBOSE = "-vv";  //$NON-NLS-1$
+    /**
+     * Command line option for verbose output.
+     */
+    String OPTION_VERY_VERY_VERBOSE = "-vvv";  //$NON-NLS-1$
+    /**
+     * Command line option for output path.
+     */
+    String OPTION_OUTPUT_PATH = "-o"; //$NON-NLS-1$
+    /**
+     * Command line option for output path.
+     */
+    String OPTION_SNAPSHOT = "--snapshot"; //$NON-NLS-1$
+    /**
+     * Command line option for live
+     */
+    String OPTION_LIVE = "--live"; //$NON-NLS-1$
+    /**
+     * Command line option for kernel tracer.
+     */
+    String OPTION_KERNEL = "-k"; //$NON-NLS-1$
+    /**
+     * Command line option for UST tracer.
+     */
+    String OPTION_UST = "-u"; //$NON-NLS-1$
+    /**
+     * Command line option for specifying a session.
+     */
+    String OPTION_SESSION = "-s";  //$NON-NLS-1$
+    /**
+     * Command line option for specifying a channel.
+     */
+    String OPTION_CHANNEL = "-c";  //$NON-NLS-1$
+    /**
+     * Command line option for specifying a event.
+     */
+    String OPTION_EVENT = "-e";  //$NON-NLS-1$
+    /**
+     * Command line option for specifying all events.
+     */
+    String OPTION_ALL = "-a";  //$NON-NLS-1$
+    /**
+     * Command line option for specifying a context.
+     */
+    String OPTION_CONTEXT_TYPE = "-t";  //$NON-NLS-1$
+    /**
+     * Command line option for specifying tracepoint events.
+     */
+    String OPTION_TRACEPOINT = "--tracepoint";  //$NON-NLS-1$
+    /**
+     * Command line option for specifying syscall events.
+     */
+    String OPTION_SYSCALL = "--syscall";  //$NON-NLS-1$
+    /**
+     * Command line option for specifying a dynamic probe.
+     */
+    String OPTION_PROBE = "--probe";  //$NON-NLS-1$
+    /**
+     * Command line option for specifying a dynamic function entry/return probe.
+     */
+    String OPTION_FUNCTION_PROBE = "--function";  //$NON-NLS-1$
+    /**
+     * Command line option for specifying a log level range.
+     */
+    String OPTION_LOGLEVEL = "--loglevel";  //$NON-NLS-1$
+    /**
+     * Command line option for specifying a specific log level.
+     */
+    String OPTION_LOGLEVEL_ONLY = "--loglevel-only";  //$NON-NLS-1$
+    /**
+     * Optional command line option for configuring a channel's overwrite mode.
+     */
+    String OPTION_OVERWRITE = "--overwrite";  //$NON-NLS-1$
+    /**
+     * Optional command line option for configuring a channel's number of sub buffers.
+     */
+    String OPTION_NUM_SUB_BUFFERS = "--num-subbuf";  //$NON-NLS-1$
+    /**
+     * Optional command line option for configuring a channel's sub buffer size.
+     */
+    String OPTION_SUB_BUFFER_SIZE = "--subbuf-size";  //$NON-NLS-1$
+    /**
+     * Optional command line option for configuring a channel's switch timer interval.
+     */
+    String OPTION_SWITCH_TIMER = "--switch-timer";  //$NON-NLS-1$
+    /**
+     * Optional command line option for configuring a channel's read timer interval.
+     */
+    String OPTION_READ_TIMER = "--read-timer";  //$NON-NLS-1$
+    /**
+     * Command line option for printing the help of a specif command
+     */
+    String OPTION_HELP = "-h";  //$NON-NLS-1$
+    /**
+     * Command line option for listing the fields of UST tracepoints
+     */
+    String OPTION_FIELDS = "-f"; //$NON-NLS-1$
+    /**
+     * Command line option for configuring event's filter
+     */
+    String OPTION_FILTER = "--filter"; //$NON-NLS-1$
+    /**
+     * Command line option for configuring the streaming network URL (common for control and data channel).
+     */
+    String OPTION_NETWORK_URL = "-U"; //$NON-NLS-1$
+    /**
+     * Command line option for configuring the streaming control URL.
+     */
+    String OPTION_CONTROL_URL = "-C"; //$NON-NLS-1$
+    /**
+     * Command line option for configuring the streaming data URL.
+     */
+    String OPTION_DATA_URL = "-D"; //$NON-NLS-1$
+    /**
+     * Command line option for per UID buffers
+     */
+    String OPTION_PER_UID_BUFFERS = "--buffers-uid"; //$NON-NLS-1$
+    /**
+     * Command line option for per PID buffers
+     */
+    String OPTION_PER_PID_BUFFERS = "--buffers-pid"; //$NON-NLS-1$
+    /**
+     * Command line option for maximum size of trace files
+     */
+    String OPTION_MAX_SIZE_TRACE_FILES = "-C"; //$NON-NLS-1$
+    /**
+     * Command line option for maximum trace files
+     */
+    String OPTION_MAX_TRACE_FILES = "-W"; //$NON-NLS-1$
+
+    /**
+     * Maximum live timer interval value
+     */
+    Long MAX_LIVE_TIMER_INTERVAL = 0xFFFFFFFEL;
+
+    // ------------------------------------------------------------------------
+    // Parsing constants
+    // ------------------------------------------------------------------------
+    /**
+     * Pattern to match the version.
+     */
+    Pattern VERSION_PATTERN = checkNotNull(Pattern.compile(".*lttng\\s+version\\s+.*(\\d+\\.\\d+\\.\\d+).*")); //$NON-NLS-1$
+    /**
+     * Pattern to match for error output
+     */
+    Pattern ERROR_PATTERN = checkNotNull(Pattern.compile("\\s*Error\\:.*")); //$NON-NLS-1$
+    /**
+     * Pattern to match for session information (lttng list)
+     */
+    Pattern SESSION_PATTERN = checkNotNull(Pattern.compile("\\s+(\\d+)\\)\\s+(.*)\\s+\\((.*)\\)\\s+\\[(active|inactive).*\\].*")); //$NON-NLS-1$
+    /**
+     * Pattern to match for session information (lttng list <session>)
+     */
+    Pattern TRACE_SESSION_PATTERN = checkNotNull(Pattern.compile("\\s*Tracing\\s+session\\s+(.*)\\:\\s+\\[(active|inactive)\\].*")); //$NON-NLS-1$
+    /**
+     * Pattern to match for snapshot session information (lttng list <session>)
+     */
+    Pattern TRACE_SNAPSHOT_SESSION_PATTERN = checkNotNull(Pattern.compile("\\s*Tracing\\s+session\\s+(.*)\\:\\s+\\[(active|inactive)\\s*snapshot\\].*")); //$NON-NLS-1$
+    /**
+     * Pattern to match for session path information (lttng list <session>)
+     */
+    Pattern TRACE_SESSION_PATH_PATTERN = checkNotNull(Pattern.compile("\\s*Trace\\s+path\\:\\s+(.*)")); //$NON-NLS-1$
+    /**
+     * Pattern to match session path for network tracing (lttng list <session>)
+     * Note: file for protocol is not considered as network trace since local consumer will be used.
+     */
+    Pattern TRACE_NETWORK_PATH_PATTERN = checkNotNull(Pattern.compile("\\s*Trace\\s+path\\:\\s+(net|net4|net6|tcp|tcp4|tcp6)\\:\\/\\/(.*)(\\:(\\d*)\\/(.*)\\[data\\:\\s+(\\d*)\\]){0,1}")); //$NON-NLS-1$
+    /**
+     * Pattern to match session path for network tracing
+     * Note: file for protocol is not considered as network trace since local consumer will be used.
+     */
+    Pattern TRACE_NETWORK_PATTERN = checkNotNull(Pattern.compile("\\s*(net|net4|net6|tcp|tcp4|tcp6)\\:\\/\\/(.*)(\\:(\\d*)\\/(.*)\\[data\\:\\s+(\\d*)\\]){0,1}")); //$NON-NLS-1$
+    /**
+     * Sub-pattern to pattern TRACE_NETWORK_PATH_PATTERN to match file protocol
+     */
+    Pattern TRACE_FILE_PROTOCOL_PATTERN = checkNotNull(Pattern.compile("(file)\\:\\/\\/(.*)")); //$NON-NLS-1$
+    /**
+     * Pattern to match for kernel domain information (lttng list <session>)
+     */
+    Pattern DOMAIN_KERNEL_PATTERN = checkNotNull(Pattern.compile("=== Domain: Kernel ===")); //$NON-NLS-1$
+    /**
+     * Pattern to match for ust domain information (lttng list <session>)
+     */
+    Pattern DOMAIN_UST_GLOBAL_PATTERN = checkNotNull(Pattern.compile("=== Domain: UST global ===")); //$NON-NLS-1$
+    /**
+     * Pattern to match for matching warning about no kernel channel
+     */
+    Pattern DOMAIN_NO_KERNEL_CHANNEL_PATTERN = checkNotNull(Pattern.compile("\\s*Warning\\:\\s+No kernel\\s+channel.*")); //$NON-NLS-1$
+    /**
+     * Pattern to match for matching warning about no UST channel
+     */
+    Pattern DOMAIN_NO_UST_CHANNEL_PATTERN = checkNotNull(Pattern.compile("\\s*Error\\:\\s+UST\\s+channel\\s+not\\s+found.*")); //$NON-NLS-1$
+    /**
+     * Pattern to match for buffer type (lttng list <session>)
+     */
+    Pattern BUFFER_TYPE_PATTERN = checkNotNull(Pattern.compile("\\s*Buffer\\s+type\\:.*")); //$NON-NLS-1$
+    /**
+     * Pattern to match for channels section (lttng list <session>)
+     */
+    Pattern CHANNELS_SECTION_PATTERN = checkNotNull(Pattern.compile("\\s*Channels\\:")); //$NON-NLS-1$
+    /**
+     * Pattern to match for channel information (lttng list <session>)
+     */
+    Pattern CHANNEL_PATTERN = checkNotNull(Pattern.compile("\\s*-\\s+(.*)\\:\\s+\\[(enabled|disabled)\\]")); //$NON-NLS-1$
+    /**
+     * Pattern to match for events section information (lttng list <session>)
+     */
+    Pattern EVENT_SECTION_PATTERN = checkNotNull(Pattern.compile("\\s*Events\\:")); //$NON-NLS-1$
+    /**
+     * Pattern to match for event information (lttng list <session>)
+     */
+    Pattern EVENT_PATTERN = checkNotNull(Pattern.compile("\\s+(.*)\\s+\\(loglevel\\s*(:|<=|==)\\s+(.*)\\s+\\(\\d*\\)\\)\\s+\\(type:\\s+(.*)\\)\\s+\\[(enabled|disabled)\\]\\s*(\\[.*\\]){0,1}.*")); //$NON-NLS-1$
+    /**
+     * Pattern to match a wildcarded event information (lttng list <session>)
+     */
+    Pattern WILDCARD_EVENT_PATTERN = checkNotNull(Pattern.compile("\\s+(.*)\\s+\\(type:\\s+(.*)\\)\\s+\\[(enabled|disabled)\\]\\s*(\\[.*\\]){0,1}.*")); //$NON-NLS-1$
+    /**
+     * Pattern to match a probe address information (lttng list <session>)
+     */
+    Pattern PROBE_ADDRESS_PATTERN = checkNotNull(Pattern.compile("\\s+(addr)\\:\\s+(0x[0-9a-fA-F]{1,16})")); //$NON-NLS-1$
+    /**
+     * Pattern to match a probe OFFSET information (lttng list <session>)
+     */
+    Pattern PROBE_OFFSET_PATTERN = checkNotNull(Pattern.compile("\\s+(offset)\\:\\s+(0x[0-9a-fA-F]{1,16})")); //$NON-NLS-1$
+    /**
+     * Pattern to match a probe SYMBOL information (lttng list <session>)
+     */
+    Pattern PROBE_SYMBOL_PATTERN = checkNotNull(Pattern.compile("\\s+(symbol)\\:\\s+(.+)")); //$NON-NLS-1$
+    /**
+     * Pattern to match for channel (overwite mode) information (lttng list <session>)
+     */
+    Pattern OVERWRITE_MODE_ATTRIBUTE = checkNotNull(Pattern.compile("\\s+overwrite\\s+mode\\:.*")); //$NON-NLS-1$
+    /**
+     * Pattern to match indicating false for overwrite mode
+     */
+    String OVERWRITE_MODE_ATTRIBUTE_FALSE = "0"; //$NON-NLS-1$
+    /**
+     * Pattern to match indicating false for overwrite mode in machine interface mode
+     */
+    String OVERWRITE_MODE_ATTRIBUTE_FALSE_MI = "DISCARD"; //$NON-NLS-1$
+    /**
+     * Pattern to match for channel (sub-buffer size) information (lttng list <session>)
+     */
+    Pattern SUBBUFFER_SIZE_ATTRIBUTE = checkNotNull(Pattern.compile("\\s+subbufers\\s+size\\:.*")); //$NON-NLS-1$
+    /**
+     * Pattern to match for channel (number of sub-buffers) information (lttng list <session>)
+     */
+    Pattern NUM_SUBBUFFERS_ATTRIBUTE = checkNotNull(Pattern.compile("\\s+number\\s+of\\s+subbufers\\:.*")); //$NON-NLS-1$
+    /**
+     * Pattern to match for channel (switch timer) information (lttng list <session>)
+     */
+    Pattern SWITCH_TIMER_ATTRIBUTE = checkNotNull(Pattern.compile("\\s+switch\\s+timer\\s+interval\\:.*")); //$NON-NLS-1$
+    /**
+     * Pattern to match for channel (read timer) information (lttng list <session>)
+     */
+    Pattern READ_TIMER_ATTRIBUTE = checkNotNull(Pattern.compile("\\s+read\\s+timer\\s+interval\\:.*")); //$NON-NLS-1$
+    /**
+     * Pattern to match for channel (output type) information (lttng list <session>)
+     */
+    Pattern OUTPUT_ATTRIBUTE = checkNotNull(Pattern.compile("\\s+output\\:.*")); //$NON-NLS-1$
+    /**
+     * Pattern to match for channel (trace file size) information (lttng list <session>)
+     */
+    Pattern TRACE_FILE_COUNT_ATTRIBUTE = checkNotNull(Pattern.compile("\\s+trace\\s+file\\s+count\\:.*")); //$NON-NLS-1$
+    /**
+     * Pattern to match for channel (trace file size) information (lttng list <session>)
+     */
+    Pattern TRACE_FILE_SIZE_ATTRIBUTE = checkNotNull(Pattern.compile("\\s+trace\\s+file\\s+size\\s+\\(bytes\\)\\:.*")); //$NON-NLS-1$
+    /**
+     * Pattern to match for provider information (lttng list -k/-u)
+     */
+    Pattern PROVIDER_EVENT_PATTERN = checkNotNull(Pattern.compile("\\s*(.*)\\s+\\(loglevel:\\s+(.*)\\s+\\(\\d*\\)\\)\\s+\\(type:\\s+(.*)\\)")); //$NON-NLS-1$
+    /**
+     * Pattern to match event fields
+     */
+    Pattern EVENT_FIELD_PATTERN = checkNotNull(Pattern.compile("\\s*(field:)\\s+(.*)\\s+\\((.*)\\)")); //$NON-NLS-1$
+    /**
+     * Pattern to match for UST provider information (lttng list -u)
+     */
+    Pattern UST_PROVIDER_PATTERN = checkNotNull(Pattern.compile("\\s*PID\\:\\s+(\\d+)\\s+-\\s+Name\\:\\s+(.*)")); //$NON-NLS-1$
+    /**
+     * Pattern to match for session information (lttng create <session name>)
+     */
+    Pattern CREATE_SESSION_NAME_PATTERN = checkNotNull(Pattern.compile(".*Session\\s+(.*)\\s+created\\.")); //$NON-NLS-1$
+    /**
+     * Pattern to match for session path information (lttng create <session name>)
+     */
+    Pattern CREATE_SESSION_PATH_PATTERN = checkNotNull(Pattern.compile("\\s*Traces\\s+will\\s+be\\s+written\\s+in\\s+(.*).*")); //$NON-NLS-1$
+    /**
+     * Pattern to match for session command output for "session name not found".
+     */
+    Pattern SESSION_NOT_FOUND_ERROR_PATTERN = checkNotNull(Pattern.compile("\\s*Error:\\s+Session\\s+name\\s.*not\\s+found")); //$NON-NLS-1$
+    /**
+     * Pattern to match introduction line of context list.
+     */
+    Pattern ADD_CONTEXT_HELP_CONTEXTS_INTRO = checkNotNull(Pattern.compile("\\s*TYPE can\\s+be\\s+one\\s+of\\s+the\\s+strings\\s+below.*")); //$NON-NLS-1$
+    /**
+     * Pattern to match introduction line of context list.
+     */
+    Pattern ADD_CONTEXT_HELP_CONTEXTS_END_LINE = checkNotNull(Pattern.compile("\\s*Example.*")); //$NON-NLS-1$
+    /**
+     * Pattern to match error line if no kernel tracer is available or installed.
+     */
+    Pattern LIST_KERNEL_NO_KERNEL_PROVIDER_PATTERN = checkNotNull(Pattern.compile("\\s*Error:\\s+Unable\\s+to\\s+list\\s+kernel\\s+events.*")); //$NON-NLS-1$;
+    /**
+     * Pattern to match error line if no ust tracer is available or installed.
+     */
+    Pattern LIST_UST_NO_UST_PROVIDER_PATTERN = checkNotNull(Pattern.compile(".*Unable\\s*to\\s*list\\s*UST\\s*event.*")); //$NON-NLS-1$;
+    /**
+     * Pattern to match for list snapshot information (lttng snapshot list-output)
+     */
+    Pattern LIST_SNAPSHOT_OUTPUT_PATTERN = checkNotNull(Pattern.compile("\\s+\\[(\\d+)\\]\\s+(\\S*)\\:\\s+(\\S*)(.*)")); //$NON-NLS-1$
+    /**
+     * Pattern to match the live timer interval line of session list.
+     */
+    Pattern LIST_LIVE_TIMER_INTERVAL_PATTERN = checkNotNull(Pattern.compile("\\s*Live\\stimer\\sinterval\\s\\(usec\\):\\s(\\d+)")); //$NON-NLS-1$
+    /**
+     * Pattern to match snapshot path for network tracing (lttng list <session>)
+     * Note: file for protocol is not considered as network trace since local consumer will be used.
+     */
+    Pattern SNAPSHOT_NETWORK_PATH_PATTERN = checkNotNull(Pattern.compile("(net|net4|net6|tcp|tcp4|tcp6)\\:\\/\\/(.*)(\\:(\\d*)\\/(.*)\\[data\\:\\s+(\\d*)\\]){0,1}")); //$NON-NLS-1$
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/service/LTTngControlServiceFactory.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/service/LTTngControlServiceFactory.java
new file mode 100644 (file)
index 0000000..6d94077
--- /dev/null
@@ -0,0 +1,126 @@
+/**********************************************************************
+ * Copyright (c) 2012, 2015 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Jonathan Rajotte - machine interface support
+ **********************************************************************/
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.service;
+
+import static org.eclipse.tracecompass.common.core.NonNullUtils.checkNotNull;
+
+import java.util.regex.Matcher;
+
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.core.runtime.NullProgressMonitor;
+import org.eclipse.jdt.annotation.NonNullByDefault;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.logging.ControlCommandLogger;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.preferences.ControlPreferences;
+import org.eclipse.tracecompass.tmf.remote.core.shell.ICommandInput;
+import org.eclipse.tracecompass.tmf.remote.core.shell.ICommandResult;
+import org.eclipse.tracecompass.tmf.remote.core.shell.ICommandShell;
+
+/**
+ * Factory to create LTTngControlService instances depending on the version of
+ * the LTTng Trace Control installed on the remote host.
+ *
+ * @author Bernd Hufmann
+ */
+@NonNullByDefault
+public final class LTTngControlServiceFactory {
+
+    // ------------------------------------------------------------------------
+    // Constructor
+    // ------------------------------------------------------------------------
+    /**
+     * Constructor
+     */
+    private LTTngControlServiceFactory() {
+    }
+
+    // ------------------------------------------------------------------------
+    // Factory method
+    // ------------------------------------------------------------------------
+    /**
+     * Gets the LTTng Control Service implementation based on the version of the
+     * remote LTTng Tools.
+     *
+     * @param shell
+     *            - the shell implementation to pass to the service
+     * @return - LTTng Control Service implementation
+     * @throws ExecutionException
+     *             If the command fails
+     */
+    public static ILttngControlService getLttngControlService(ICommandShell shell) throws ExecutionException {
+        // get the version
+        boolean machineInterfaceMode = true;
+
+        // Looking for a machine interface on LTTng side
+        ICommandInput command = shell.createCommand();
+        command.add(LTTngControlServiceConstants.CONTROL_COMMAND);
+        command.add(LTTngControlServiceConstants.CONTROL_COMMAND_MI_OPTION);
+        command.add(LTTngControlServiceConstants.CONTROL_COMMAND_MI_XML);
+        command.add(LTTngControlServiceConstants.COMMAND_VERSION);
+        ICommandResult result = executeCommand(shell, command);
+
+        if (result.getResult() != 0) {
+            machineInterfaceMode = false;
+            // Fall back if no machine interface is present
+            command = shell.createCommand();
+            command.add(LTTngControlServiceConstants.CONTROL_COMMAND);
+            command.add(LTTngControlServiceConstants.COMMAND_VERSION);
+            result = executeCommand(shell, command);
+        }
+
+        if ((result.getResult() == 0) && (!result.getOutput().isEmpty())) {
+            if (machineInterfaceMode) {
+                LTTngControlServiceMI service = new LTTngControlServiceMI(shell, LTTngControlService.class.getResource(LTTngControlServiceConstants.MI_XSD_FILENAME));
+                service.setVersion(result.getOutput());
+                return service;
+            }
+
+            for (String line : result.getOutput()) {
+                line = line.replace("-", ".");  //$NON-NLS-1$//$NON-NLS-2$
+                Matcher versionMatcher = LTTngControlServiceConstants.VERSION_PATTERN.matcher(line);
+                if (versionMatcher.matches()) {
+                    String version = versionMatcher.group(1).trim();
+                    Matcher matcher = LTTngControlServiceConstants.VERSION_2_PATTERN.matcher(version);
+                    if (matcher.matches()) {
+                        LTTngControlService service = new LTTngControlService(shell);
+                        service.setVersion(checkNotNull(version));
+                        return service;
+                    }
+                    throw new ExecutionException(Messages.TraceControl_UnsupportedVersionError + ": " + version); //$NON-NLS-1$
+                }
+            }
+        }
+        throw new ExecutionException(Messages.TraceControl_GettingVersionError);
+    }
+
+    private static ICommandResult executeCommand(ICommandShell shell, ICommandInput command) throws ExecutionException {
+        // Logging
+        if (ControlPreferences.getInstance().isLoggingEnabled()) {
+            ControlCommandLogger.log(command.toString());
+        }
+
+        ICommandResult result = null;
+
+        try {
+            result = shell.executeCommand(command, new NullProgressMonitor());
+        } catch (ExecutionException e) {
+            throw new ExecutionException(Messages.TraceControl_GettingVersionError + ": " + e); //$NON-NLS-1$
+        }
+
+        // Output logging
+        if (ControlPreferences.getInstance().isLoggingEnabled()) {
+            ControlCommandLogger.log(result.toString());
+        }
+        return result;
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/service/LTTngControlServiceMI.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/service/LTTngControlServiceMI.java
new file mode 100644 (file)
index 0000000..0b1c77f
--- /dev/null
@@ -0,0 +1,967 @@
+/**********************************************************************
+ * Copyright (c) 2014, 2015 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:
+ *   Jonathan Rajotte - Initial support for machine interface lttng 2.6
+ *   Bernd Hufmann - Fix check for live session
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.service;
+
+import static org.eclipse.tracecompass.common.core.NonNullUtils.checkNotNull;
+
+import java.io.IOException;
+import java.io.StringReader;
+import java.math.BigInteger;
+import java.net.URL;
+import java.util.ArrayList;
+import java.util.List;
+import java.util.regex.Matcher;
+
+import javax.xml.XMLConstants;
+import javax.xml.parsers.DocumentBuilder;
+import javax.xml.parsers.DocumentBuilderFactory;
+import javax.xml.parsers.ParserConfigurationException;
+import javax.xml.validation.SchemaFactory;
+
+import org.eclipse.core.commands.ExecutionException;
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.jdt.annotation.NonNull;
+import org.eclipse.jdt.annotation.Nullable;
+import org.eclipse.osgi.util.NLS;
+import org.eclipse.tracecompass.common.core.NonNullUtils;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IBaseEventInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IChannelInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IDomainInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IEventInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IFieldInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IProbeEventInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISessionInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISnapshotInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.IUstProviderInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.LogLevelType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceDomainType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEnablement;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEventType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.BaseEventInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.BufferType;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.ChannelInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.DomainInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.EventInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.FieldInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.ProbeEventInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.SessionInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.SnapshotInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.UstProviderInfo;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.XmlMiValidationErrorHandler;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
+import org.eclipse.tracecompass.tmf.remote.core.shell.ICommandInput;
+import org.eclipse.tracecompass.tmf.remote.core.shell.ICommandResult;
+import org.eclipse.tracecompass.tmf.remote.core.shell.ICommandShell;
+import org.w3c.dom.Document;
+import org.w3c.dom.Node;
+import org.w3c.dom.NodeList;
+import org.xml.sax.InputSource;
+import org.xml.sax.SAXException;
+
+/**
+ * Service for sending LTTng trace control commands to remote host via machine
+ * interface mode.
+ *
+ * @author Jonathan Rajotte
+ */
+public class LTTngControlServiceMI extends LTTngControlService {
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+
+    private final DocumentBuilder fDocumentBuilder;
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+
+    /**
+     * Constructor
+     *
+     * @param shell
+     *            the command shell implementation to use
+     * @param xsdUrl
+     *            the xsd schema file for validation
+     * @throws ExecutionException
+     *             if the creation of the Schema and DocumentBuilder objects
+     *             fails
+     */
+    public LTTngControlServiceMI(@NonNull ICommandShell shell, @Nullable URL xsdUrl) throws ExecutionException {
+        super(shell);
+
+        DocumentBuilderFactory docBuilderFactory = DocumentBuilderFactory.newInstance();
+        docBuilderFactory.setValidating(false);
+
+        // Validate XSD schema
+        if (xsdUrl != null) {
+            SchemaFactory schemaFactory = SchemaFactory.newInstance(XMLConstants.W3C_XML_SCHEMA_NS_URI);
+            try {
+                docBuilderFactory.setSchema(schemaFactory.newSchema(xsdUrl));
+            } catch (SAXException e) {
+                throw new ExecutionException(Messages.TraceControl_InvalidSchemaError, e);
+            }
+        }
+
+        try {
+            fDocumentBuilder = docBuilderFactory.newDocumentBuilder();
+        } catch (ParserConfigurationException e) {
+            throw new ExecutionException(Messages.TraceControl_XmlDocumentBuilderError, e);
+        }
+
+        fDocumentBuilder.setErrorHandler(new XmlMiValidationErrorHandler());
+
+    }
+
+    /**
+     * Generate a Document object from an list of Strings.
+     *
+     * @param xmlStrings
+     *            list of strings representing an xml input
+     * @return Document generated from strings input
+     * @throws ExecutionException
+     *             when parsing has failed
+     */
+    private Document getDocumentFromStrings(List<String> xmlStrings) throws ExecutionException {
+        StringBuilder concatenedString = new StringBuilder();
+        for (String string : xmlStrings) {
+            concatenedString.append(string);
+        }
+        InputSource stream = new InputSource(new StringReader(concatenedString.toString()));
+
+        Document document;
+        try {
+            document = fDocumentBuilder.parse(stream);
+        } catch (SAXException | IOException e) {
+            throw new ExecutionException(Messages.TraceControl_XmlParsingError + ':' + e.toString(), e);
+        }
+        return document;
+
+    }
+
+    /**
+     * Parse, populate and set the internal LTTngVersion variable
+     *
+     * @param xmlOutput
+     *            the mi xml output of lttng version
+     * @throws ExecutionException
+     *             when xml extraction fail
+     */
+    public void setVersion(List<String> xmlOutput) throws ExecutionException {
+        Document doc = getDocumentFromStrings(xmlOutput);
+        NodeList element = doc.getElementsByTagName(MIStrings.VERSION);
+        int major = 0;
+        int minor = 0;
+        int patchLevel = 0;
+        String license = ""; //$NON-NLS-1$
+        String commit = ""; //$NON-NLS-1$
+        String name = ""; //$NON-NLS-1$
+        String description = ""; //$NON-NLS-1$
+        String url = ""; //$NON-NLS-1$
+        String fullVersion = ""; //$NON-NLS-1$
+        if (element.getLength() == 1) {
+            NodeList child = element.item(0).getChildNodes();
+            // Get basic information
+            for (int i = 0; i < child.getLength(); i++) {
+                Node node = child.item(i);
+                switch (node.getNodeName()) {
+                case MIStrings.VERSION_MAJOR:
+                    major = Integer.parseInt(node.getTextContent());
+                    break;
+                case MIStrings.VERSION_MINOR:
+                    minor = Integer.parseInt(node.getTextContent());
+                    break;
+                case MIStrings.VERSION_PATCH_LEVEL:
+                    patchLevel = Integer.parseInt(node.getTextContent());
+                    break;
+                case MIStrings.VERSION_COMMIT:
+                    commit = node.getTextContent();
+                    break;
+                case MIStrings.VERSION_DESCRIPTION:
+                    description = node.getTextContent();
+                    break;
+                case MIStrings.VERSION_LICENSE:
+                    license = node.getTextContent();
+                    break;
+                case MIStrings.VERSION_NAME:
+                    name = node.getTextContent();
+                    break;
+                case MIStrings.VERSION_STR:
+                    fullVersion = node.getTextContent();
+                    break;
+                case MIStrings.VERSION_WEB:
+                    url = node.getTextContent();
+                    break;
+                default:
+                    break;
+                }
+            }
+            setVersion(new LttngVersion(major, minor, patchLevel, license, commit, name, description, url, fullVersion));
+        } else {
+            throw new ExecutionException(Messages.TraceControl_UnsupportedVersionError);
+        }
+    }
+
+    @Override
+    public List<String> getSessionNames(IProgressMonitor monitor) throws ExecutionException {
+        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_LIST);
+        ICommandResult result = executeCommand(command, monitor);
+
+        Document doc = getDocumentFromStrings(result.getOutput());
+
+        NodeList elements = doc.getElementsByTagName(MIStrings.NAME);
+
+        ArrayList<String> retArray = new ArrayList<>();
+        for (int i = 0; i < elements.getLength(); i++) {
+            Node node = elements.item(i);
+            if (node.getParentNode().getNodeName().equalsIgnoreCase(MIStrings.SESSION)) {
+                retArray.add(node.getTextContent());
+            }
+        }
+        return retArray;
+    }
+
+    @Override
+    public ISessionInfo getSession(String sessionName, IProgressMonitor monitor) throws ExecutionException {
+        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_LIST, sessionName);
+        ICommandResult result = executeCommand(command, monitor);
+
+        ISessionInfo sessionInfo = new SessionInfo(sessionName);
+        Document document = getDocumentFromStrings(result.getOutput());
+
+        NodeList sessionsNode = document.getElementsByTagName(MIStrings.SESSION);
+        // There should be only one session
+        if (sessionsNode.getLength() != 1) {
+            throw new ExecutionException(NLS.bind(Messages.TraceControl_MiInvalidNumberOfElementError, MIStrings.SESSION));
+        }
+
+        // Populate session information
+        Node rawSession = sessionsNode.item(0);
+        parseSession(sessionInfo, rawSession);
+
+        // Fetch the snapshot info
+        if (sessionInfo.isSnapshotSession()) {
+            ISnapshotInfo snapshot = getSnapshotInfo(sessionName, monitor);
+            sessionInfo.setSnapshotInfo(snapshot);
+        }
+
+        return sessionInfo;
+    }
+
+    /**
+     * @param sessionInfo
+     * @param rawSession
+     * @throws ExecutionException
+     */
+    private void parseSession(ISessionInfo sessionInfo, Node rawSession) throws ExecutionException {
+        if (!rawSession.getNodeName().equalsIgnoreCase(MIStrings.SESSION)) {
+            throw new ExecutionException(Messages.TraceControl_MiInvalidElementError);
+        }
+        NodeList rawSessionInfos = rawSession.getChildNodes();
+        for (int i = 0; i < rawSessionInfos.getLength(); i++) {
+            Node rawInfo = rawSessionInfos.item(i);
+            switch (rawInfo.getNodeName()) {
+            case MIStrings.NAME:
+                sessionInfo.setName(rawInfo.getTextContent());
+                break;
+            case MIStrings.PATH:
+                sessionInfo.setSessionPath(rawInfo.getTextContent());
+                break;
+            case MIStrings.ENABLED:
+                sessionInfo.setSessionState(rawInfo.getTextContent());
+                break;
+            case MIStrings.SNAPSHOT_MODE:
+                if (rawInfo.getTextContent().equals(LTTngControlServiceConstants.TRUE_NUMERICAL)) {
+                    // real name will be set later
+                    ISnapshotInfo snapshotInfo = new SnapshotInfo(""); //$NON-NLS-1$
+                    sessionInfo.setSnapshotInfo(snapshotInfo);
+                }
+                break;
+            case MIStrings.LIVE_TIMER_INTERVAL:
+                long liveDelay = Long.parseLong(rawInfo.getTextContent());
+                if ((liveDelay > 0 && (liveDelay <= LTTngControlServiceConstants.MAX_LIVE_TIMER_INTERVAL))) {
+                    sessionInfo.setLive(true);
+                    sessionInfo.setLiveUrl(SessionInfo.DEFAULT_LIVE_NETWORK_URL);
+                    sessionInfo.setLivePort(SessionInfo.DEFAULT_LIVE_PORT);
+                    sessionInfo.setLiveDelay(liveDelay);
+                }
+                break;
+            case MIStrings.DOMAINS:
+                // Extract the domains node
+                NodeList rawDomains = rawInfo.getChildNodes();
+                IDomainInfo domain = null;
+                for (int j = 0; j < rawDomains.getLength(); j++) {
+                    if (rawDomains.item(j).getNodeName().equalsIgnoreCase(MIStrings.DOMAIN)) {
+                        domain = parseDomain(rawDomains.item(j));
+                        sessionInfo.addDomain(domain);
+                    }
+                }
+                break;
+            default:
+                break;
+            }
+        }
+
+        if (!sessionInfo.isSnapshotSession()) {
+            Matcher matcher = LTTngControlServiceConstants.TRACE_NETWORK_PATTERN.matcher(sessionInfo.getSessionPath());
+            if (matcher.matches()) {
+                sessionInfo.setStreamedTrace(true);
+            }
+        }
+    }
+
+    /**
+     * Parse a raw domain XML node to a IDomainInfo object
+     *
+     * @param rawDomain
+     *            a domain xml node
+     * @return a populated {@link DomainInfo} object
+     * @throws ExecutionException
+     *             when missing required xml element (type)
+     */
+    protected IDomainInfo parseDomain(Node rawDomain) throws ExecutionException {
+        IDomainInfo domain = null;
+        // Get the type
+        Node rawType = getFirstOf(rawDomain.getChildNodes(), MIStrings.TYPE);
+        if (rawType == null) {
+            throw new ExecutionException(Messages.TraceControl_MiMissingRequiredError);
+        }
+        String rawTypeString = rawType.getTextContent().toLowerCase();
+        TraceDomainType domainType = TraceDomainType.valueOfString(rawTypeString);
+        switch (domainType) {
+        case KERNEL:
+            domain = new DomainInfo(Messages.TraceControl_KernelProviderDisplayName);
+            domain.setIsKernel(true);
+            break;
+        case UST:
+            domain = new DomainInfo(Messages.TraceControl_UstGlobalDomainDisplayName);
+            domain.setIsKernel(false);
+            break;
+        case JUL:
+            /**
+             * TODO: Support for JUL JUL substructure and semantic is not the
+             * same as a regular UST or Kernel Domain There is no channel under
+             * JUL domain only events. The channel is activated in UST Channel
+             */
+            domain = new DomainInfo(Messages.TraceControl_JULDomainDisplayName);
+            domain.setIsKernel(false);
+            break;
+        case UNKNOWN:
+            domain = new DomainInfo(Messages.TraceControl_UnknownDomainDisplayName);
+            domain.setIsKernel(false);
+            break;
+        default:
+            throw new ExecutionException(Messages.TraceControl_MiInvalidElementError);
+        }
+
+        NodeList rawInfos = rawDomain.getChildNodes();
+        for (int i = 0; i < rawInfos.getLength(); i++) {
+            Node rawInfo = rawInfos.item(i);
+            switch (rawInfo.getNodeName()) {
+            case MIStrings.BUFFER_TYPE:
+                BufferType bufferType = BufferType.valueOfString(rawInfo.getTextContent());
+                domain.setBufferType(bufferType);
+                break;
+            case MIStrings.CHANNELS:
+                ArrayList<IChannelInfo> channels = new ArrayList<>();
+                parseChannels(rawInfo.getChildNodes(), channels);
+                if (channels.size() > 0) {
+                    domain.setChannels(channels);
+                }
+                break;
+            default:
+                break;
+            }
+        }
+
+        return domain;
+    }
+
+    /**
+     * Parse a list of raw channel XML node into an ArrayList of IChannelInfo
+     *
+     * @param rawChannes
+     *            List of raw channel XML node
+     * @param channels
+     *            the parsed channels list
+     * @throws ExecutionException
+     *             when missing required xml element (type)
+     */
+    private static void parseChannels(NodeList rawChannels, ArrayList<IChannelInfo> channels) throws ExecutionException {
+        IChannelInfo channel = null;
+        for (int i = 0; i < rawChannels.getLength(); i++) {
+            Node rawChannel = rawChannels.item(i);
+            if (rawChannel.getNodeName().equalsIgnoreCase(MIStrings.CHANNEL)) {
+                channel = new ChannelInfo(""); //$NON-NLS-1$
+
+                // Populate the channel
+                NodeList rawInfos = rawChannel.getChildNodes();
+                Node rawInfo = null;
+                for (int j = 0; j < rawInfos.getLength(); j++) {
+                    rawInfo = rawInfos.item(j);
+                    switch (rawInfo.getNodeName()) {
+                    case MIStrings.NAME:
+                        channel.setName(rawInfo.getTextContent());
+                        break;
+                    case MIStrings.ENABLED:
+                        channel.setState(TraceEnablement.valueOfString(rawInfo.getTextContent()));
+                        break;
+                    case MIStrings.EVENTS:
+                        List<IEventInfo> events = new ArrayList<>();
+                        getEventInfo(rawInfo.getChildNodes(), events);
+                        channel.setEvents(events);
+                        break;
+                    case MIStrings.ATTRIBUTES:
+                        NodeList rawAttributes = rawInfo.getChildNodes();
+                        for (int k = 0; k < rawAttributes.getLength(); k++) {
+                            Node attribute = rawAttributes.item(k);
+                            switch (attribute.getNodeName()) {
+                            case MIStrings.OVERWRITE_MODE:
+                                channel.setOverwriteMode(!LTTngControlServiceConstants.OVERWRITE_MODE_ATTRIBUTE_FALSE_MI.equalsIgnoreCase(attribute.getTextContent()));
+                                break;
+                            case MIStrings.SUBBUF_SIZE:
+                                channel.setSubBufferSize(Long.valueOf(attribute.getTextContent()));
+                                break;
+                            case MIStrings.NUM_SUBBUF:
+                                channel.setNumberOfSubBuffers(Integer.valueOf(attribute.getTextContent()));
+                                break;
+                            case MIStrings.SWITCH_TIMER_INTERVAL:
+                                channel.setSwitchTimer(Long.valueOf(attribute.getTextContent()));
+                                break;
+                            case MIStrings.READ_TIMER_INTERVAL:
+                                channel.setReadTimer(Long.valueOf(attribute.getTextContent()));
+                                break;
+                            case MIStrings.OUTPUT_TYPE:
+                                channel.setOutputType(attribute.getTextContent());
+                                break;
+                            case MIStrings.TRACEFILE_SIZE:
+                                channel.setMaxSizeTraceFiles(Long.parseLong(attribute.getTextContent()));
+                                break;
+                            case MIStrings.TRACEFILE_COUNT:
+                                channel.setMaxNumberTraceFiles(Integer.parseInt(attribute.getTextContent()));
+                                break;
+                            case MIStrings.LIVE_TIMER_INTERVAL:
+                                // TODO: currently not supported by tmf
+                                break;
+                            default:
+                                break;
+                            }
+                        }
+                        break;
+                    default:
+                        break;
+                    }
+                }
+                channels.add(channel);
+            }
+        }
+
+    }
+
+    @Override
+    public ISnapshotInfo getSnapshotInfo(String sessionName, IProgressMonitor monitor) throws ExecutionException {
+        // TODO A session can have multiple snapshot output. This need to be
+        // supported in the future.
+        // Currently the SessionInfo object does not support multiple snashot
+        // output.
+        // For now only keep the last one.
+        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_SNAPSHOT, LTTngControlServiceConstants.COMMAND_LIST_SNAPSHOT_OUTPUT, LTTngControlServiceConstants.OPTION_SESSION, sessionName);
+        ICommandResult result = executeCommand(command, monitor);
+        Document doc = getDocumentFromStrings(result.getOutput());
+        NodeList rawSnapshotsOutputs = doc.getElementsByTagName(MIStrings.SNAPSHOT_OUTPUTS);
+
+        ISnapshotInfo snapshotInfo = new SnapshotInfo(""); //$NON-NLS-1$
+
+        // TODO: tmf does not have a notion of a ctrl url.
+        for (int i = 0; i < rawSnapshotsOutputs.getLength(); i++) {
+            NodeList rawSnapshotOutput = rawSnapshotsOutputs.item(i).getChildNodes();
+            for (int j = 0; j < rawSnapshotOutput.getLength(); j++) {
+                Node rawInfo = rawSnapshotOutput.item(j);
+                switch (rawInfo.getNodeName()) {
+                case MIStrings.ID:
+                    snapshotInfo.setId(Integer.parseInt(rawInfo.getTextContent()));
+                    break;
+                case MIStrings.NAME:
+                    snapshotInfo.setName(rawInfo.getTextContent());
+                    break;
+                case MIStrings.SNAPSHOT_CTRL_URL:
+                    // The use of the ctrl_url for the snapshot path is to assure
+                    // basic support. Refactoring is necessary in lttng and
+                    // tmf side.
+                    // See http://bugs.lttng.org/issues/828 (+comment)
+                    snapshotInfo.setSnapshotPath(rawInfo.getTextContent());
+                    break;
+                default:
+                    break;
+                }
+            }
+        }
+
+        // Check if the snapshot output is Streamed
+        Matcher matcher2 = LTTngControlServiceConstants.TRACE_NETWORK_PATTERN.matcher(snapshotInfo.getSnapshotPath());
+        if (matcher2.matches()) {
+            snapshotInfo.setStreamedSnapshot(true);
+        }
+
+        return snapshotInfo;
+    }
+
+    @Override
+    public List<IBaseEventInfo> getKernelProvider(IProgressMonitor monitor) throws ExecutionException {
+        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_LIST, LTTngControlServiceConstants.OPTION_KERNEL);
+        ICommandResult result = executeCommand(command, monitor, false);
+        List<IBaseEventInfo> events = new ArrayList<>();
+
+        if (isError(result)) {
+            // Ignore the following 2 cases:
+            // Spawning a session daemon
+            // Error: Unable to list kernel events
+            // or:
+            // Error: Unable to list kernel events
+            if (ignoredPattern(result.getErrorOutput(), LTTngControlServiceConstants.LIST_KERNEL_NO_KERNEL_PROVIDER_PATTERN)) {
+                return events;
+            }
+            throw new ExecutionException(Messages.TraceControl_CommandError + command.toString());
+        }
+
+        Document document = getDocumentFromStrings(result.getOutput());
+        NodeList rawEvents = document.getElementsByTagName(MIStrings.EVENT);
+        getBaseEventInfo(rawEvents, events);
+        return events;
+    }
+
+    @Override
+    public List<IUstProviderInfo> getUstProvider(IProgressMonitor monitor) throws ExecutionException {
+        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_LIST, LTTngControlServiceConstants.OPTION_UST);
+        // Get the field to
+        command.add(LTTngControlServiceConstants.OPTION_FIELDS);
+
+        // Execute
+        ICommandResult result = executeCommand(command, monitor, false);
+        List<IUstProviderInfo> allProviders = new ArrayList<>();
+
+        if (isError(result)) {
+            // Ignore the following 2 cases:
+            // Spawning a session daemon
+            // Error: Unable to list UST events: Listing UST events failed
+            // or:
+            // Error: Unable to list UST events: Listing UST events failed
+            if (ignoredPattern(result.getErrorOutput(), LTTngControlServiceConstants.LIST_UST_NO_UST_PROVIDER_PATTERN)) {
+                return allProviders;
+            }
+            throw new ExecutionException(Messages.TraceControl_CommandError + command.toString());
+        }
+
+        Document document = getDocumentFromStrings(result.getOutput());
+        NodeList rawProviders = document.getElementsByTagName(MIStrings.PID);
+
+        IUstProviderInfo providerInfo = null;
+
+        for (int i = 0; i < rawProviders.getLength(); i++) {
+            Node provider = rawProviders.item(i);
+            Node name = getFirstOf(provider.getChildNodes(), MIStrings.NAME);
+            if (name == null) {
+                throw new ExecutionException(Messages.TraceControl_MiInvalidProviderError);
+            }
+            providerInfo = new UstProviderInfo(name.getTextContent());
+
+            // Populate provider
+            NodeList infos = provider.getChildNodes();
+            for (int j = 0; j < infos.getLength(); j++) {
+                Node info = infos.item(j);
+                switch (info.getNodeName()) {
+                case MIStrings.PID_ID:
+                    providerInfo.setPid(Integer.parseInt(info.getTextContent()));
+                    break;
+                case MIStrings.EVENTS:
+                    List<IBaseEventInfo> events = new ArrayList<>();
+                    NodeList rawEvents = info.getChildNodes();
+                    getBaseEventInfo(rawEvents, events);
+                    providerInfo.setEvents(events);
+                    break;
+                default:
+                    break;
+                }
+            }
+            allProviders.add(providerInfo);
+        }
+
+        return allProviders;
+    }
+
+    @Override
+    public ISessionInfo createSession(ISessionInfo sessionInfo, IProgressMonitor monitor) throws ExecutionException {
+        if (sessionInfo.isStreamedTrace()) {
+            return createStreamedSession(sessionInfo, monitor);
+        }
+
+        ICommandInput command = prepareSessionCreationCommand(sessionInfo);
+        ICommandResult result = executeCommand(command, monitor);
+
+        Document document = getDocumentFromStrings(result.getOutput());
+        NodeList sessions = document.getElementsByTagName(MIStrings.SESSION);
+
+        // Number of session should be equal to 1
+        if (sessions.getLength() != 1) {
+            throw new ExecutionException(Messages.TraceControl_CommandError + " " + command + "\n" //$NON-NLS-1$//$NON-NLS-2$
+                    + NLS.bind(Messages.TraceControl_UnexpectedNumberOfElementError, MIStrings.SESSION) + " " + sessions.getLength()); //$NON-NLS-1$
+        }
+
+        // Fetch a session from output
+        ISessionInfo outputSession = new SessionInfo(""); //$NON-NLS-1$
+        parseSession(outputSession, sessions.item(0));
+
+        // Verify session name
+        if ((outputSession.getName().equals("")) || (!"".equals(sessionInfo.getName()) && !outputSession.getName().equals(sessionInfo.getName()))) { //$NON-NLS-1$ //$NON-NLS-2$
+            // Unexpected name returned
+            throw new ExecutionException(Messages.TraceControl_CommandError + " " + command + "\n" + //$NON-NLS-1$ //$NON-NLS-2$
+                    Messages.TraceControl_UnexpectedNameError + ": " + outputSession.getName()); //$NON-NLS-1$
+        }
+
+        // Verify session path
+        if (!sessionInfo.isSnapshotSession() &&
+                ((outputSession.getSessionPath() == null) || ((sessionInfo.getSessionPath() != null) && (!outputSession.getSessionPath().contains(sessionInfo.getSessionPath()))))) {
+            // Unexpected path
+            throw new ExecutionException(Messages.TraceControl_CommandError + " " + command + "\n" + //$NON-NLS-1$ //$NON-NLS-2$
+                    Messages.TraceControl_UnexpectedPathError + ": " + outputSession.getName()); //$NON-NLS-1$
+        }
+
+        if (sessionInfo.isSnapshotSession()) {
+            // Make it a snapshot session - content of snapshot info need to
+            // set afterwards using getSession() or getSnapshotInfo()
+            outputSession.setSnapshotInfo(new SnapshotInfo("")); //$NON-NLS-1$
+        }
+
+        return outputSession;
+    }
+
+    private @NonNull ISessionInfo createStreamedSession(ISessionInfo sessionInfo, IProgressMonitor monitor) throws ExecutionException {
+
+        ICommandInput command = prepareStreamedSessionCreationCommand(sessionInfo);
+
+        ICommandResult result = executeCommand(command, monitor);
+
+        Document document = getDocumentFromStrings(result.getOutput());
+        NodeList sessions = document.getElementsByTagName(MIStrings.SESSION);
+
+        // Number of session should be equal to 1
+        if (sessions.getLength() != 1) {
+            throw new ExecutionException(Messages.TraceControl_CommandError + " " + command + "\n" //$NON-NLS-1$//$NON-NLS-2$
+                    + NLS.bind(Messages.TraceControl_UnexpectedNumberOfElementError, MIStrings.SESSION) + " " + sessions.getLength()); //$NON-NLS-1$
+        }
+
+        // Fetch a session from output
+        ISessionInfo outputSession = new SessionInfo(""); //$NON-NLS-1$
+        parseSession(outputSession, sessions.item(0));
+
+        // Verify session name
+        if ((outputSession.getName().equals("")) || (!"".equals(sessionInfo.getName()) && !outputSession.getName().equals(sessionInfo.getName()))) { //$NON-NLS-1$ //$NON-NLS-2$
+            // Unexpected name returned
+            throw new ExecutionException(Messages.TraceControl_CommandError + " " + command + "\n" + //$NON-NLS-1$ //$NON-NLS-2$
+                    Messages.TraceControl_UnexpectedNameError + ": " + outputSession.getName()); //$NON-NLS-1$
+        }
+
+        sessionInfo.setName(outputSession.getName());
+        sessionInfo.setStreamedTrace(true);
+
+        // Verify session path
+        if (sessionInfo.getNetworkUrl() != null) {
+            if (!sessionInfo.isSnapshotSession() && (outputSession.getSessionPath() == null)) {
+                // Unexpected path
+                throw new ExecutionException(Messages.TraceControl_CommandError + " " + command + "\n" + //$NON-NLS-1$ //$NON-NLS-2$
+                        Messages.TraceControl_UnexpectedPathError + ": " + outputSession.getName()); //$NON-NLS-1$
+            }
+
+            if (sessionInfo.isSnapshotSession()) {
+                sessionInfo.setStreamedTrace(false);
+            } else {
+                sessionInfo.setSessionPath(outputSession.getSessionPath());
+                // Check file protocol
+                Matcher matcher = LTTngControlServiceConstants.TRACE_FILE_PROTOCOL_PATTERN.matcher(outputSession.getSessionPath());
+                if (matcher.matches()) {
+                    sessionInfo.setStreamedTrace(false);
+                }
+            }
+        }
+
+        // When using controlUrl and dataUrl the full session path is not known
+        // yet
+        // and will be set later on when listing the session
+        return sessionInfo;
+    }
+
+    @Override
+    public void destroySession(String sessionName, IProgressMonitor monitor) throws ExecutionException {
+        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_DESTROY_SESSION, sessionName);
+
+        ICommandResult result = executeCommand(command, monitor, false);
+        List<String> errorOutput = result.getErrorOutput();
+
+        if (isError(result)) {
+            // Don't treat this as an error
+            if (ignoredPattern(errorOutput, LTTngControlServiceConstants.SESSION_NOT_FOUND_ERROR_PATTERN)) {
+                return;
+
+            }
+            throw new ExecutionException(Messages.TraceControl_CommandError + " " + command.toString() + "\n" + result.toString()); //$NON-NLS-1$ //$NON-NLS-2$
+        }
+
+        // Check for action effect
+        Document doc = getDocumentFromStrings(result.getOutput());
+        NodeList sessions = doc.getElementsByTagName(MIStrings.SESSION);
+        if (sessions.getLength() != 1) {
+            throw new ExecutionException(NLS.bind(Messages.TraceControl_MiInvalidNumberOfElementError, MIStrings.SESSION));
+        }
+
+        Node rawSessionName = getFirstOf(sessions.item(0).getChildNodes(), MIStrings.NAME);
+        if (rawSessionName == null) {
+            throw new ExecutionException(Messages.TraceControl_MiMissingRequiredError);
+        }
+
+        // Validity check
+        if (!rawSessionName.getTextContent().equals(sessionName)) {
+            throw new ExecutionException(NLS.bind(Messages.TraceControl_UnexpectedValueError, rawSessionName.getTextContent(), sessionName));
+        }
+    }
+
+    @Override
+    protected ICommandInput createCommand(String... strings) {
+        ICommandInput command = getCommandShell().createCommand();
+        command.add(LTTngControlServiceConstants.CONTROL_COMMAND);
+        List<String> groupOption = getTracingGroupOption();
+        if (!groupOption.isEmpty()) {
+            command.addAll(groupOption);
+        }
+        command.add(LTTngControlServiceConstants.CONTROL_COMMAND_MI_OPTION);
+        command.add(LTTngControlServiceConstants.CONTROL_COMMAND_MI_XML);
+        for (String string : strings) {
+            command.add(checkNotNull(string));
+        }
+        return command;
+    }
+
+    /**
+     * @param xmlBaseEvents
+     *            a Node list of base xml event element
+     * @param events
+     *            list of event generated by the parsing of the xml event
+     *            element
+     * @throws ExecutionException
+     *             when a raw event is not a complete/valid xml event
+     */
+    private static void getBaseEventInfo(NodeList xmlBaseEvents, List<IBaseEventInfo> events) throws ExecutionException {
+        IBaseEventInfo eventInfo = null;
+        for (int i = 0; i < xmlBaseEvents.getLength(); i++) {
+            NodeList rawInfos = xmlBaseEvents.item(i).getChildNodes();
+            // Search for name
+            if (xmlBaseEvents.item(i).getNodeName().equalsIgnoreCase(MIStrings.EVENT)) {
+                Node rawName = getFirstOf(rawInfos, MIStrings.NAME);
+                if (rawName == null) {
+                    throw new ExecutionException(Messages.TraceControl_MiMissingRequiredError);
+                }
+                eventInfo = new BaseEventInfo(rawName.getTextContent());
+
+                // Populate the event
+                for (int j = 0; j < rawInfos.getLength(); j++) {
+                    Node infoNode = rawInfos.item(j);
+                    switch (infoNode.getNodeName()) {
+                    case MIStrings.TYPE:
+                        eventInfo.setEventType(infoNode.getTextContent());
+                        break;
+                    case MIStrings.LOGLEVEL:
+                        eventInfo.setLogLevel(infoNode.getTextContent());
+                        break;
+                    case MIStrings.EVENT_FIELDS:
+                        List<IFieldInfo> fields = new ArrayList<>();
+                        getFieldInfo(infoNode.getChildNodes(), fields);
+                        eventInfo.setFields(fields);
+                        break;
+                    default:
+                        break;
+                    }
+                }
+                events.add(eventInfo);
+            }
+        }
+    }
+
+    /**
+     * @param xmlBaseEvents
+     *            a Node list of xml event element linked to a session
+     * @param events
+     *            list of event generated by the parsing of the xml event
+     *            element
+     * @throws ExecutionException
+     *             when a raw event is not a complete/valid xml event
+     */
+    static void getEventInfo(NodeList xmlEvents, List<IEventInfo> events) throws ExecutionException {
+        IEventInfo eventInfo = null;
+        for (int i = 0; i < xmlEvents.getLength(); i++) {
+            NodeList rawInfos = xmlEvents.item(i).getChildNodes();
+            // Search for name
+            if (xmlEvents.item(i).getNodeName().equalsIgnoreCase(MIStrings.EVENT)) {
+                Node rawName = getFirstOf(rawInfos, MIStrings.NAME);
+                if (rawName == null) {
+                    throw new ExecutionException(Messages.TraceControl_MiMissingRequiredError);
+                }
+
+                eventInfo = new EventInfo(rawName.getTextContent());
+
+                // Basic information
+                for (int j = 0; j < rawInfos.getLength(); j++) {
+                    Node infoNode = rawInfos.item(j);
+                    switch (infoNode.getNodeName()) {
+                    case MIStrings.TYPE:
+                        eventInfo.setEventType(infoNode.getTextContent());
+                        break;
+                    case MIStrings.LOGLEVEL_TYPE:
+                        eventInfo.setLogLevelType(LogLevelType.valueOfString(infoNode.getTextContent()));
+                        break;
+                    case MIStrings.LOGLEVEL:
+                        eventInfo.setLogLevel(TraceLogLevel.valueOfString(infoNode.getTextContent()));
+                        break;
+                    case MIStrings.ENABLED:
+                        eventInfo.setState(TraceEnablement.valueOfString(infoNode.getTextContent()));
+                        break;
+                    case MIStrings.FILTER:
+                        // TODO
+                        // See bug 334 http://bugs.lttng.org/issues/334 from
+                        // LTTng
+                        // For now we emulate the non-mi behavior and simply put
+                        // "with filter"
+                        eventInfo.setFilterExpression("with filter"); //$NON-NLS-1$
+                        break;
+                    case MIStrings.EXCLUSION:
+                        // TODO: Currently not supported by tmf
+                        // ExclusionS element is ignored
+                        break;
+                    default:
+                        break;
+                    }
+                }
+
+                boolean isProbeFunction = (eventInfo.getEventType().equals(TraceEventType.PROBE)) || (eventInfo.getEventType().equals(TraceEventType.FUNCTION));
+                if (isProbeFunction) {
+                    IProbeEventInfo probeEvent = new ProbeEventInfo(eventInfo);
+                    eventInfo = probeEvent;
+
+                    Node rawDataNode = null;
+                    switch (probeEvent.getEventType()) {
+                    case FUNCTION:
+                    case PROBE: {
+                        // get attributes
+                        Node rawAttributes = getFirstOf(rawInfos, MIStrings.ATTRIBUTES);
+                        if (rawAttributes == null) {
+                            throw new ExecutionException(Messages.TraceControl_MiMissingRequiredError);
+                        }
+                        rawDataNode = getFirstOf(rawAttributes.getChildNodes(), MIStrings.PROBE_ATTRIBUTES);
+                        break;
+                    }
+                    case SYSCALL:
+                    case TRACEPOINT:
+                    case UNKNOWN:
+                    default:
+                        throw new ExecutionException(Messages.TraceControl_MiInvalidElementError);
+                    }
+
+                    if (rawDataNode == null) {
+                        throw new ExecutionException(Messages.TraceControl_MiInvalidElementError);
+                    }
+
+                    // Extract info
+                    NodeList rawDatas = rawDataNode.getChildNodes();
+                    for (int j = 0; j < rawDatas.getLength(); j++) {
+                        Node rawData = rawDatas.item(j);
+                        switch (rawData.getNodeName()) {
+                        case MIStrings.SYMBOL_NAME:
+                            probeEvent.setSymbol(rawData.getTextContent());
+                            break;
+                        case MIStrings.ADDRESS:
+                            probeEvent.setAddress(String.format("%#016x", new BigInteger(rawData.getTextContent()))); //$NON-NLS-1$
+                            break;
+                        case MIStrings.OFFSET:
+                            probeEvent.setOffset(String.format("%#016x", new BigInteger(rawData.getTextContent()))); //$NON-NLS-1$
+                            break;
+                        default:
+                            break;
+                        }
+                    }
+                }
+
+                // Add the event
+                events.add(eventInfo);
+            }
+        }
+    }
+
+    /**
+     * @param fieldsList
+     *            a list of xml event_field element
+     * @param fields
+     *            a list of field generated by xml parsing
+     * @throws ExecutionException
+     *             when parsing fail or required elements are missing
+     */
+    private static void getFieldInfo(NodeList fieldsList, List<IFieldInfo> fields) throws ExecutionException {
+        IFieldInfo fieldInfo = null;
+        for (int i = 0; i < fieldsList.getLength(); i++) {
+            Node field = fieldsList.item(i);
+            if (field.getNodeName().equalsIgnoreCase(MIStrings.EVENT_FIELD)) {
+                // Get name
+                Node name = getFirstOf(field.getChildNodes(), MIStrings.NAME);
+                if (name == null) {
+                    throw new ExecutionException(Messages.TraceControl_MiMissingRequiredError);
+                }
+                fieldInfo = new FieldInfo(name.getTextContent());
+
+                // Populate the field information
+                NodeList infos = field.getChildNodes();
+                for (int j = 0; j < infos.getLength(); j++) {
+                    Node info = infos.item(j);
+                    switch (info.getNodeName()) {
+                    case MIStrings.TYPE:
+                        fieldInfo.setFieldType(info.getTextContent());
+                        break;
+                    default:
+                        break;
+                    }
+                }
+                fields.add(fieldInfo);
+            }
+        }
+    }
+
+    /**
+     * Retrieve the fist instance of a given node with tag name equal to tagName
+     * parameter
+     *
+     * @param nodeList
+     *            the list of Node to search against
+     * @param tagName
+     *            the tag name of the desired node
+     * @return the first occurrence of a node with a tag name equals to tagName
+     */
+    private static @Nullable Node getFirstOf(NodeList nodeList, String tagName) {
+        Node node = null;
+        for (int i = 0; i < nodeList.getLength(); i++) {
+            if (NonNullUtils.equalsNullable(nodeList.item(i).getNodeName(), tagName)) {
+                node = nodeList.item(i);
+                break;
+            }
+        }
+        return node;
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/service/LttngVersion.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/service/LttngVersion.java
new file mode 100644 (file)
index 0000000..92313d4
--- /dev/null
@@ -0,0 +1,156 @@
+/**********************************************************************
+ * Copyright (c) 2013, 2014 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Jonathan Rajotte - Machine interface support and new information
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.service;
+
+import org.eclipse.jdt.annotation.NonNull;
+import org.osgi.framework.Version;
+
+/**
+ * A version implementation with a special compareTo implementation to bypass
+ * problems of older implementation of org.osgi.framework.Version.
+ *
+ * @author Bernd Hufmann
+ */
+public class LttngVersion extends Version {
+
+    /** A null version */
+    public static final @NonNull LttngVersion NULL_VERSION = new LttngVersion(Version.emptyVersion.toString());
+
+    private final String fLicense;
+    private final String fCommit;
+    private final String fName;
+    private final String fDescription;
+    private final String fUrl;
+    private final String fFullVersion;
+
+    /**
+     * Constructor
+     *
+     * @param version
+     *            The version string
+     */
+    public LttngVersion(String version) {
+        super(version);
+        fLicense = ""; //$NON-NLS-1$
+        fCommit = ""; //$NON-NLS-1$
+        fName = ""; //$NON-NLS-1$
+        fDescription = ""; //$NON-NLS-1$
+        fUrl = ""; //$NON-NLS-1$
+        fFullVersion = ""; //$NON-NLS-1$
+    }
+
+    /**
+     * @param major
+     *            major version number
+     * @param minor
+     *            minor version number
+     * @param micro
+     *            micro version number
+     * @param license
+     *            licence text of LTTng
+     * @param commit
+     *            current git commit information about LTTng
+     * @param name
+     *            name of the version
+     * @param description
+     *            description of the version
+     * @param url
+     *            url to website
+     * @param fullVersion
+     *            complete string representation of the version
+     */
+    public LttngVersion(int major, int minor, int micro, String license, String commit, String name, String description, String url, String fullVersion) {
+        super(major, minor, micro);
+        fLicense = license;
+        fCommit = commit;
+        fName = name;
+        fDescription = description;
+        fUrl = url;
+        fFullVersion = fullVersion;
+    }
+
+    /**
+     * Special compareTo method to fix problem of older implementations of
+     * org.osgi.framework.Version where {@code Version.compareTo} takes an
+     * {@code Object} instead a {@code Version} as argument.
+     *
+     * @param other
+     *            - Other version to compare
+     * @return a negative integer, zero, or a positive integer if this version
+     *         is less than, equal to, or greater than the specified
+     *         {@code LttngVersion} object.
+     */
+    public int compareTo(LttngVersion other) {
+        if (other == this) { // quicktest
+            return 0;
+        }
+        int result = getMajor() - other.getMajor();
+        if (result != 0) {
+            return result;
+        }
+
+        result = getMinor() - other.getMinor();
+        if (result != 0) {
+            return result;
+        }
+
+        result = getMicro() - other.getMicro();
+        if (result != 0) {
+            return result;
+        }
+        return getQualifier().compareTo(other.getQualifier());
+    }
+
+    /**
+     * @return String representing the lttng license
+     */
+    public String getLicense() {
+        return fLicense;
+    }
+
+    /**
+     * @return commit id of lttng
+     */
+    public String getCommit() {
+        return fCommit;
+    }
+
+    /**
+     * @return name of lttng version
+     */
+    public String getName() {
+        return fName;
+    }
+
+    /**
+     * @return full description of lttng
+     */
+    public String getDescription() {
+        return fDescription;
+    }
+
+    /**
+     * @return url of lttng
+     */
+    public String getUrl() {
+        return fUrl;
+    }
+
+    /**
+     * @return the full_version
+     */
+    public String getFullVersion() {
+        return fFullVersion;
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/service/MIStrings.java b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/service/MIStrings.java
new file mode 100644 (file)
index 0000000..15c69ef
--- /dev/null
@@ -0,0 +1,578 @@
+/*******************************************************************************
+ * Copyright (c) 2014, 2015 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:
+ *   Jonathan Rajotte Julien - Initial API and implementation
+ *   Bernd Hufmann - Added null annotations
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.control.ui.views.service;
+
+import org.eclipse.jdt.annotation.NonNullByDefault;
+
+
+/**
+ * Non-externalized strings for use with the LTTng Control services. This
+ * information is extracted from mi_lttng.xsd from lttng-tool libmi.
+ *
+ * @author Jonathan Rajotte
+ */
+@SuppressWarnings("nls")
+@NonNullByDefault
+public interface MIStrings {
+
+    /**
+     * Represent the command_action xml element
+     */
+     String COMMAND_ACTION = "snapshot_action";
+
+    /**
+     * Represent the command_add_context xml element
+     */
+     String COMMAND_ADD_CONTEXT = "add-context";
+
+    /**
+     * Represent the command_calibrate xml element
+     */
+     String COMMAND_CALIBRATE = "calibrate";
+
+    /**
+     * Represent the command_create xml element
+     */
+     String COMMAND_CREATE = "create";
+
+    /**
+     * Represent the command_destroy xml element
+     */
+     String COMMAND_DESTROY = "destroy";
+
+    /**
+     * Represent the command_disable_channel xml element
+     */
+     String COMMAND_DISABLE_CHANNEL = "disable-channel";
+
+    /**
+     * Represent the command_disable_event xml element
+     */
+     String COMMAND_DISABLE_EVENT = "disable-event";
+
+    /**
+     * Represent the command_enable_channels xml element
+     */
+     String COMMAND_ENABLE_CHANNELS = "enable-channel";
+
+    /**
+     * Represent the command_enable_event xml element
+     */
+     String COMMAND_ENABLE_EVENT = "enable-event";
+
+    /**
+     * Represent the command_list xml element
+     */
+     String COMMAND_LIST = "list";
+
+    /**
+     * Represent the command_load xml element
+     */
+     String COMMAND_LOAD = "load";
+
+    /**
+     * Represent the command_name xml element
+     */
+     String COMMAND_NAME = "name";
+
+    /**
+     * Represent the command_output xml element
+     */
+     String COMMAND_OUTPUT = "output";
+
+    /**
+     * Represent the command_save xml element
+     */
+     String COMMAND_SAVE = "save";
+
+    /**
+     * Represent the command_set_session xml element
+     */
+     String COMMAND_SET_SESSION = "set-session";
+
+    /**
+     * Represent the command_snapshot xml element
+     */
+     String COMMAND_SNAPSHOT = "snapshot";
+
+    /**
+     * Represent the command_snapshot_add xml element
+     */
+     String COMMAND_SNAPSHOT_ADD = "add_snapshot";
+
+    /**
+     * Represent the command_snapshot_del xml element
+     */
+     String COMMAND_SNAPSHOT_DEL = "del_snapshot";
+
+    /**
+     * Represent the command_snapshot_list xml element
+     */
+     String COMMAND_SNAPSHOT_LIST = "list_snapshot";
+
+    /**
+     * Represent the command_snapshot_record xml element
+     */
+     String COMMAND_SNAPSHOT_RECORD = "record_snapshot";
+
+    /**
+     * Represent the command_start xml element
+     */
+     String COMMAND_START = "start";
+
+    /**
+     * Represent the command_stop xml element
+     */
+     String COMMAND_STOP = "stop";
+
+    /**
+     * Represent the command_success xml element
+     */
+     String COMMAND_SUCCESS = "success";
+
+    /**
+     * Represent the command_version xml element
+     */
+     String COMMAND_VERSION = "version";
+
+    /**
+     * Represent the version xml element
+     */
+     String VERSION = "version";
+
+    /**
+     * Represent the version_commit xml element
+     */
+     String VERSION_COMMIT = "commit";
+
+    /**
+     * Represent the version_description xml element
+     */
+     String VERSION_DESCRIPTION = "description";
+
+    /**
+     * Represent the version_license xml element
+     */
+     String VERSION_LICENSE = "license";
+
+    /**
+     * Represent the version_major xml element
+     */
+     String VERSION_MAJOR = "major";
+
+    /**
+     * Represent the version_minor xml element
+     */
+     String VERSION_MINOR = "minor";
+
+    /**
+     * Represent the version_patch_level xml element
+     */
+     String VERSION_PATCH_LEVEL = "patchLevel";
+
+    /**
+     * Represent the version_str xml element
+     */
+     String VERSION_STR = "string";
+
+    /**
+     * Represent the version_web xml element
+     */
+     String VERSION_WEB = "url";
+
+    /**
+     * Represent the version_name xml element
+     */
+     String VERSION_NAME = "name";
+    /* String related to a lttng_event_field */
+
+    /**
+     * Represent the event_field xml element
+     */
+     String EVENT_FIELD = "event_field";
+
+    /**
+     * Represent the event_fields xml element
+     */
+     String EVENT_FIELDS = "event_fields";
+
+    /**
+     * Represent the perf_counter_context xml element
+     */
+     String PERF_COUNTER_CONTEXT = "perf_counter_context";
+
+     // ------------------------------------------------------------------------
+     // String related to pid
+     // ------------------------------------------------------------------------/
+
+    /**
+     * Represent the pids xml element
+     */
+     String PIDS = "pids";
+
+    /**
+     * Represent the pid xml element
+     */
+     String PID = "pid";
+
+    /**
+     * Represent the pid_id xml element
+     */
+     String PID_ID = "id";
+
+     // ------------------------------------------------------------------------
+     // String related to save command
+     // ------------------------------------------------------------------------
+    /**
+     * Represent the save xml element
+     */
+     String SAVE = "save";
+
+     // ------------------------------------------------------------------------
+     // String related to load command
+     // ------------------------------------------------------------------------
+    /**
+     * Represent the load xml element
+     */
+     String LOAD = "load";
+
+     // ------------------------------------------------------------------------
+     // String related to general element of mi_lttng
+     // ------------------------------------------------------------------------
+    /**
+     * Represent the empty xml element
+     */
+     String EMPTY = "";
+
+    /**
+     * Represent the id xml element
+     */
+     String ID = "id";
+
+    /**
+     * Represent the nowrite xml element
+     */
+     String NOWRITE = "nowrite";
+
+    /**
+     * Represent the success xml element
+     */
+     String SUCCESS = "success";
+
+    /**
+     * Represent the type_enum xml element
+     */
+     String TYPE_ENUM = "ENUM";
+
+    /**
+     * Represent the type_float xml element
+     */
+     String TYPE_FLOAT = "FLOAT";
+
+    /**
+     * Represent the type_integer xml element
+     */
+     String TYPE_INTEGER = "INTEGER";
+
+    /**
+     * Represent the type_other xml element
+     */
+     String TYPE_OTHER = "OTHER";
+
+    /**
+     * Represent the type_string xml element
+     */
+     String TYPE_STRING = "STRING";
+
+     // ------------------------------------------------------------------------
+     // String related to lttng_calibrate
+     // ------------------------------------------------------------------------
+    /**
+     * Represent the calibrate xml element
+     */
+     String CALIBRATE = "calibrate";
+
+    /**
+     * Represent the calibrate_function xml element
+     */
+     String CALIBRATE_FUNCTION = "FUNCTION";
+
+     // ------------------------------------------------------------------------
+     // String related to a lttng_snapshot_output
+     // ------------------------------------------------------------------------
+    /**
+     * Represent the snapshot_ctrl_url xml element
+     */
+     String SNAPSHOT_CTRL_URL = "ctrl_url";
+
+    /**
+     * Represent the snapshot_data_url xml element
+     */
+     String SNAPSHOT_DATA_URL = "data_url";
+
+    /**
+     * Represent the snapshot_max_size xml element
+     */
+
+     String SNAPSHOT_MAX_SIZE = "max_size";
+
+    /**
+     * Represent the snapshot_n_ptr xml element
+     */
+     String SNAPSHOT_N_PTR = "n_ptr";
+
+    /**
+     * Represent the snapshot_session_name xml element
+     */
+     String SNAPSHOT_SESSION_NAME = "session_name";
+
+    /**
+     * Represent the snapshots xml element
+     */
+     String SNAPSHOTS = "snapshots";
+    /**
+     * Represent the channel xml element
+     */
+     String CHANNEL = "channel";
+
+    /**
+     * Represent the channels xml element
+     */
+     String CHANNELS = "channels";
+
+    /**
+     * Represent the domain xml element
+     */
+     String DOMAIN = "domain";
+
+    /**
+     * Represent the domains xml element
+     */
+     String DOMAINS = "domains";
+
+    /**
+     * Represent the event xml element
+     */
+     String EVENT = "event";
+
+    /**
+     * Represent the events xml element
+     */
+     String EVENTS = "events";
+
+    /**
+     * Represent the context xml element
+     */
+     String CONTEXT = "context";
+
+    /**
+     * Represent the contexts xml element
+     */
+     String CONTEXTS = "contexts";
+
+    /**
+     * Represent the attributes xml element
+     */
+     String ATTRIBUTES = "attributes";
+
+    /**
+     * Represent the exclusion xml element
+     */
+     String EXCLUSION = "exclusion";
+
+    /**
+     * Represent the exclusions xml element
+     */
+     String EXCLUSIONS = "exclusions";
+
+    /**
+     * Represent the function_attributes xml element
+     */
+     String FUNCTION_ATTRIBUTES = "function_attributes";
+
+    /**
+     * Represent the probe_attributes xml element
+     */
+     String PROBE_ATTRIBUTES = "probe_attributes";
+
+    /**
+     * Represent the symbol_name xml element
+     */
+     String SYMBOL_NAME = "symbol_name";
+
+    /**
+     * Represent the address xml element
+     */
+     String ADDRESS = "address";
+
+    /**
+     * Represent the offset xml element
+     */
+     String OFFSET = "offset";
+
+    /**
+     * Represent the name xml element
+     */
+     String NAME = "name";
+
+    /**
+     * Represent the enabled xml element
+     */
+     String ENABLED = "enabled";
+
+    /**
+     * Represent the overwrite_mode xml element
+     */
+     String OVERWRITE_MODE = "overwrite_mode";
+
+    /**
+     * Represent the subbuf_size xml element
+     */
+     String SUBBUF_SIZE = "subbuffer_size";
+
+    /**
+     * Represent the num_subbuf xml element
+     */
+     String NUM_SUBBUF = "subbuffer_count";
+
+    /**
+     * Represent the switch_timer_interval xml element
+     */
+     String SWITCH_TIMER_INTERVAL = "switch_timer_interval";
+
+    /**
+     * Represent the read_timer_interval xml element
+     */
+     String READ_TIMER_INTERVAL = "read_timer_interval";
+
+    /**
+     * Represent the output xml element
+     */
+     String OUTPUT = "output";
+
+    /**
+     * Represent the output_type xml element
+     */
+     String OUTPUT_TYPE = "output_type";
+
+    /**
+     * Represent the tracefile_size xml element
+     */
+     String TRACEFILE_SIZE = "tracefile_size";
+
+    /**
+     * Represent the tracefile_count xml element
+     */
+     String TRACEFILE_COUNT = "tracefile_count";
+
+    /**
+     * Represent the live_timer_interval xml element
+     */
+     String LIVE_TIMER_INTERVAL = "live_timer_interval";
+
+    /**
+     * Represent the type xml element
+     */
+     String TYPE = "type";
+
+    /**
+     * Represent the buffer_type xml element
+     */
+     String BUFFER_TYPE = "buffer_type";
+
+    /**
+     * Represent the session xml element
+     */
+     String SESSION = "session";
+
+    /**
+     * Represent the sessions xml element
+     */
+     String SESSIONS = "sessions";
+
+    /**
+     * Represent the perf xml element
+     */
+     String PERF = "perf";
+
+    /**
+     * Represent the config xml element
+     */
+     String CONFIG = "config";
+
+    /**
+     * Represent the started xml element
+     */
+     String STARTED = "started";
+
+    /**
+     * Represent the snapshot_mode xml element
+     */
+     String SNAPSHOT_MODE = "snapshot_mode";
+
+    /**
+     * Represent the loglevel xml element
+     */
+     String LOGLEVEL = "loglevel";
+
+    /**
+     * Represent the loglevel_type xml element
+     */
+     String LOGLEVEL_TYPE = "loglevel_type";
+
+    /**
+     * Represent the filter xml element
+     */
+     String FILTER = "filter";
+
+    /**
+     * Represent the snapshot_outputs xml element
+     */
+     String SNAPSHOT_OUTPUTS = "snapshot";
+
+    /**
+     * Represent the consumer_output xml element
+     */
+     String CONSUMER_OUTPUT = "consumer_output";
+
+    /**
+     * Represent the destination xml element
+     */
+     String DESTINATION = "destination";
+
+    /**
+     * Represent the path xml element
+     */
+     String PATH = "path";
+
+    /**
+     * Represent the net_output xml element
+     */
+     String NET_OUTPUT = "net_output";
+
+    /**
+     * Represent the control_uri xml element
+     */
+     String CONTROL_URI = "control_uri";
+
+    /**
+     * Represent the data_uri xml element
+     */
+     String DATA_URI = "data_uri";
+
+    /**
+     * Represent the max_size xml element
+     */
+    String MAX_SIZE = "max_size";
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/service/mi_lttng.xsd b/lttng/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/service/mi_lttng.xsd
new file mode 100644 (file)
index 0000000..f5fc729
--- /dev/null
@@ -0,0 +1,495 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+Copyright (c) 2014 - Oliver Cotte <olivier.cotte@polymtl.ca>
+                   - Jonathan Rajotte <jonathan.r.julien@gmail.com>
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+THE SOFTWARE.
+-->
+<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
+       elementFormDefault="qualified" version="2.5">
+
+       <!-- Maps to the uint32_t type -->
+       <xs:simpleType name="uint32_type">
+               <xs:restriction base="xs:integer">
+                       <xs:minInclusive value="0" />
+                       <xs:maxInclusive value="4294967295" />
+               </xs:restriction>
+       </xs:simpleType>
+
+       <!-- Maps to the uint64_t type -->
+       <xs:simpleType name="uint64_type">
+               <xs:restriction base="xs:integer">
+                       <xs:minInclusive value="0" />
+                       <xs:maxInclusive value="18446744073709551615" />
+               </xs:restriction>
+       </xs:simpleType>
+
+       <!-- Maps to the char name[LTTNG_SYMBOL_NAME_LEN] -->
+       <xs:simpleType name="name_type">
+               <xs:restriction base="xs:string">
+                       <xs:maxLength value="255" />
+               </xs:restriction>
+       </xs:simpleType>
+
+       <!-- Maps to the lttng_event_type enum -->
+       <xs:simpleType name="event_type_type">
+               <xs:restriction base="xs:string">
+                       <xs:enumeration value="ALL" />
+                       <xs:enumeration value="TRACEPOINT" />
+                       <xs:enumeration value="PROBE" />
+                       <xs:enumeration value="FUNCTION" />
+                       <xs:enumeration value="FUNCTION_ENTRY" />
+                       <xs:enumeration value="NOOP" />
+                       <xs:enumeration value="SYSCALL" />
+                       <xs:enumeration value="KPROBE" />
+                       <xs:enumeration value="KRETPROBE" />
+               </xs:restriction>
+       </xs:simpleType>
+
+       <!-- Maps to the lttng_event_field_type enum -->
+       <xs:simpleType name="event_field_type_type">
+               <xs:restriction base="xs:string">
+                       <xs:enumeration value="OTHER" />
+                       <xs:enumeration value="INTEGER" />
+                       <xs:enumeration value="ENUM" />
+                       <xs:enumeration value="FLOAT" />
+                       <xs:enumeration value="STRING" />
+               </xs:restriction>
+       </xs:simpleType>
+
+       <!-- Maps to the lttng_loglevel_type enum -->
+       <xs:simpleType name="loglevel_type">
+               <xs:restriction base="xs:string">
+                       <xs:enumeration value="ALL" />
+                       <xs:enumeration value="RANGE" />
+                       <xs:enumeration value="SINGLE" />
+                       <xs:enumeration value="UNKNOWN" />
+               </xs:restriction>
+       </xs:simpleType>
+
+       <!-- Maps to the lttng_event_context_type enum -->
+       <xs:simpleType name="context_type_type">
+               <xs:restriction base="xs:string">
+                       <xs:enumeration value="PERF_COUNTER" />
+                       <xs:enumeration value="PERF_CPU_COUNTER" />
+                       <xs:enumeration value="PERF_THREAD_COUNTER" />
+                       <xs:enumeration value="PID" />
+                       <xs:enumeration value="PROCNAME" />
+                       <xs:enumeration value="PRIO" />
+                       <xs:enumeration value="NICE" />
+                       <xs:enumeration value="VPID" />
+                       <xs:enumeration value="TID" />
+                       <xs:enumeration value="VTID" />
+                       <xs:enumeration value="PPID" />
+                       <xs:enumeration value="VPPID" />
+                       <xs:enumeration value="PTHREAD_ID" />
+                       <xs:enumeration value="HOSTNAME" />
+                       <xs:enumeration value="IP" />
+               </xs:restriction>
+       </xs:simpleType>
+
+       <!-- Maps to loglevel_string char * -->
+       <xs:simpleType name="loglevel_string_type">
+               <xs:restriction base="xs:string">
+                       <xs:enumeration value="" />
+                       <xs:enumeration value="TRACE_EMERG" />
+                       <xs:enumeration value="TRACE_ALERT" />
+                       <xs:enumeration value="TRACE_CRIT" />
+                       <xs:enumeration value="TRACE_ERR" />
+                       <xs:enumeration value="TRACE_WARNING" />
+                       <xs:enumeration value="TRACE_NOTICE" />
+                       <xs:enumeration value="TRACE_INFO" />
+                       <xs:enumeration value="TRACE_DEBUG_SYSTEM" />
+                       <xs:enumeration value="TRACE_DEBUG_PROGRAM" />
+                       <xs:enumeration value="TRACE_DEBUG_PROCESS" />
+                       <xs:enumeration value="TRACE_DEBUG_MODULE" />
+                       <xs:enumeration value="TRACE_DEBUG_UNIT" />
+                       <xs:enumeration value="TRACE_DEBUG_FUNCTION" />
+                       <xs:enumeration value="TRACE_DEBUG_LINE" />
+                       <xs:enumeration value="TRACE_DEBUG" />
+                       <xs:enumeration value="JUL_OFF" />
+                       <xs:enumeration value="JUL_SEVERE" />
+                       <xs:enumeration value="JUL_WARNING" />
+                       <xs:enumeration value="JUL_INFO" />
+                       <xs:enumeration value="JUL_CONFIG" />
+                       <xs:enumeration value="JUL_FINE" />
+                       <xs:enumeration value="JUL_FINER" />
+                       <xs:enumeration value="JUL_FINEST" />
+                       <xs:enumeration value="JUL_ALL" />
+                       <xs:enumeration value="LOG4J_OFF" />
+                       <xs:enumeration value="LOG4J_FATAL" />
+                       <xs:enumeration value="LOG4J_ERROR" />
+                       <xs:enumeration value="LOG4J_WARN" />
+                       <xs:enumeration value="LOG4J_INFO" />
+                       <xs:enumeration value="LOG4J_DEBUG" />
+                       <xs:enumeration value="LOG4J_TRACE" />
+                       <xs:enumeration value="LOG4J_ALL" />
+                       <xs:enumeration value="UNKNOWN" />
+               </xs:restriction>
+       </xs:simpleType>
+
+       <!-- Maps to the lttng_calibrate_type enum -->
+       <xs:simpleType name="calibrate_type_type">
+               <xs:restriction base="xs:string">
+                       <xs:enumeration value="FUNCTION" />
+               </xs:restriction>
+       </xs:simpleType>
+
+       <!-- Maps to the lttng_event_probe_attr struct -->
+       <xs:complexType name="event_probe_attributes_type">
+               <xs:all>
+                       <xs:element name="address" type="uint64_type" minOccurs="0" />
+                       <xs:element name="offset" type="uint64_type" minOccurs="0" />
+                       <xs:element name="symbol_name" type="name_type" minOccurs="0" />
+               </xs:all>
+       </xs:complexType>
+
+       <!-- Maps to the lttng_event_function_attr struct -->
+       <xs:complexType name="event_ftrace_attributes_type">
+               <xs:all>
+                       <xs:element name="symbol_name" type="name_type" />
+               </xs:all>
+       </xs:complexType>
+
+       <!-- Maps to per event type configuration -->
+       <xs:complexType name="event_attributes_type">
+               <xs:choice>
+                       <xs:element name="probe_attributes" type="event_probe_attributes_type" />
+                       <xs:element name="function_attributes" type="event_ftrace_attributes_type" />
+               </xs:choice>
+       </xs:complexType>
+
+       <!-- Maps to exclusion type -->
+       <xs:complexType name="event_exclusion_list_type">
+               <xs:sequence>
+                       <xs:element name="exclusion" type="xs:string" minOccurs="0" maxOccurs="unbounded"/>
+               </xs:sequence>
+       </xs:complexType>
+
+       <!-- Maps to lttng_event struct -->
+       <xs:complexType name="event_type">
+               <xs:all>
+                       <xs:element name="type" type="event_type_type" default="TRACEPOINT" minOccurs="0" />
+                       <xs:element name="name" type="name_type" minOccurs="0" />
+                       <xs:element name="loglevel_type" type="loglevel_type" default="ALL" minOccurs="0" />
+                       <xs:element name="loglevel" type="loglevel_string_type" default="" minOccurs="0" />
+                       <xs:element name="enabled" type="xs:boolean" default="false" minOccurs="0" />
+                       <xs:element name="filter" type="xs:boolean" minOccurs="0" />
+                       <xs:element name="exclusion" type="xs:boolean" minOccurs="0" />
+                       <xs:element name="exclusions" type="event_exclusion_list_type" minOccurs="0"/>
+                       <xs:element name="attributes" type="event_attributes_type" minOccurs="0" />
+                       <xs:element name="event_fields" type="event_fields_type" minOccurs="0" />
+                       <xs:element name="success" type="xs:boolean" minOccurs="0" />
+               </xs:all>
+       </xs:complexType>
+
+       <!-- Maps to mi_lttng_version struct -->
+       <xs:complexType name="version_type">
+               <xs:all>
+                       <xs:element name="name" type="name_type" />
+                       <xs:element name="string" type="name_type" />
+                       <xs:element name="major" type="uint32_type" />
+                       <xs:element name="url" type="xs:string" />
+                       <xs:element name="minor" type="uint32_type" />
+                       <xs:element name="commit" type="xs:string" />
+                       <xs:element name="license" type="xs:string" />
+                       <xs:element name="patchLevel" type="uint32_type" />
+                       <xs:element name="description" type="xs:string" />
+               </xs:all>
+       </xs:complexType>
+
+       <!-- Maps to an array of event -->
+       <xs:complexType name="event_list_type">
+               <xs:sequence>
+                       <xs:element name="event" type="event_type" minOccurs="0" maxOccurs="unbounded" />
+               </xs:sequence>
+       </xs:complexType>
+
+       <!-- Maps to the lttng_domain_type enum -->
+       <xs:simpleType name="domain_type_type">
+               <xs:restriction base="xs:string">
+                       <xs:enumeration value="KERNEL"/>
+                       <xs:enumeration value="UST"/>
+                       <xs:enumeration value="JUL"/>
+                       <xs:enumeration value="LOG4J"/>
+               </xs:restriction>
+       </xs:simpleType>
+
+       <!-- Maps to the lttng_buffer_type enum -->
+       <xs:simpleType name="domain_buffer_type">
+               <xs:restriction base="xs:string">
+                       <xs:enumeration value="PER_PID"/>
+                       <xs:enumeration value="PER_UID"/>
+                       <xs:enumeration value="GLOBAL"/>
+               </xs:restriction>
+       </xs:simpleType>
+
+       <!-- Maps to the type mode of a channel -->
+       <xs:simpleType name="channel_overwrite_mode_type">
+               <xs:restriction base="xs:string">
+                       <xs:enumeration value="DISCARD" />
+                       <xs:enumeration value="OVERWRITE" />
+               </xs:restriction>
+       </xs:simpleType>
+
+       <!-- Maps to the lttng_event_output enum -->
+       <xs:simpleType name="event_output_type">
+               <xs:restriction base="xs:string">
+                       <xs:enumeration value="SPLICE" />
+                       <xs:enumeration value="MMAP" />
+               </xs:restriction>
+       </xs:simpleType>
+
+       <!-- map to a pid -->
+       <xs:complexType name="pid_type">
+               <xs:all>
+                       <xs:element name="id" type="xs:int" />
+                       <xs:element name="name" type="name_type" />
+                       <xs:element name="events" type="event_list_type" minOccurs="0" />
+               </xs:all>
+       </xs:complexType>
+
+       <!-- maps to an array of pid -->
+       <xs:complexType name="pids_type">
+               <xs:sequence>
+                       <xs:element name="pid" type="pid_type" minOccurs="0" maxOccurs="unbounded" />
+               </xs:sequence>
+       </xs:complexType>
+
+       <!-- Maps to struct lttng_domain and contains channels -->
+       <xs:complexType name="domain_type">
+               <xs:all>
+                       <xs:element name="type" type="domain_type_type" />
+                       <xs:element name="buffer_type" type="domain_buffer_type" />
+                       <xs:element name="pids" type="pids_type" minOccurs="0" />
+                       <xs:element name="channels" type="channels_type" minOccurs="0" />
+                       <xs:element name="events" type="event_list_type" minOccurs="0" />
+               </xs:all>
+       </xs:complexType>
+
+       <!-- Maps to struct lttng_channel -->
+       <xs:complexType name="channel_type">
+               <xs:all>
+                       <xs:element name="name" type="name_type" />
+                       <xs:element name="enabled" type="xs:boolean" default="true" minOccurs="0" />
+                       <xs:element name="attributes" type="channel_attributes_type" minOccurs="0" />
+                       <xs:element name="events" type="event_list_type" minOccurs="0" />
+                       <xs:element name="success" type="xs:boolean" default="false" minOccurs="0" />
+               </xs:all>
+       </xs:complexType>
+
+       <!-- Maps to struct lttng_channel_attr -->
+       <xs:complexType name="channel_attributes_type">
+               <xs:all>
+                       <xs:element name="overwrite_mode" type="channel_overwrite_mode_type" default="DISCARD" minOccurs="0" />
+                       <xs:element name="subbuffer_size" type="uint64_type" minOccurs="0" /> <!-- bytes -->
+                       <xs:element name="subbuffer_count" type="uint64_type" default="4" minOccurs="0" />
+                       <xs:element name="switch_timer_interval" type="uint32_type" default="0" minOccurs="0" />  <!-- usec -->
+                       <xs:element name="read_timer_interval" type="uint32_type" />  <!-- usec -->
+                       <xs:element name="output_type" type="event_output_type" />
+                       <xs:element name="tracefile_size" type="uint64_type" default="0" minOccurs="0" /> <!-- bytes -->
+                       <xs:element name="tracefile_count" type="uint64_type" default="0" minOccurs="0" />
+                       <xs:element name="live_timer_interval" type="uint32_type" default="0" minOccurs="0" /> <!-- usec -->
+               </xs:all>
+       </xs:complexType>
+
+       <!-- Maps to struct lttng_snapshot_output -->
+       <xs:complexType name="snapshot_type">
+               <xs:all>
+                       <xs:element name="id" type="uint32_type" minOccurs="0" />
+                       <xs:element name="max_size" type="uint64_type" minOccurs="0" />
+                       <xs:element name="name" type="name_type" minOccurs="0" />
+                       <xs:element name="session_name" type="name_type" minOccurs="0" />
+                       <xs:element name="ctrl_url" type="name_type" minOccurs="0" />
+                       <xs:element name="data_url" type="name_type" minOccurs="0" />
+               </xs:all>
+       </xs:complexType>
+
+       <xs:complexType name="snapshots_type">
+               <xs:sequence>
+                       <xs:element name="snapshot" type="snapshot_type" minOccurs="0" maxOccurs="unbounded" />
+               </xs:sequence>
+       </xs:complexType>
+
+       <xs:complexType name="channels_type">
+               <xs:sequence>
+                       <xs:element name="channel" type="channel_type" minOccurs="0" maxOccurs="unbounded" />
+               </xs:sequence>
+       </xs:complexType>
+
+       <!-- Maps to a lttng_session -->
+       <xs:complexType name="session_type">
+               <xs:all>
+                       <xs:element name="name" type="name_type" />
+                       <xs:element name="path" type="name_type" minOccurs="0" />
+                       <xs:element name="enabled" type="xs:boolean" default="false" minOccurs="0" />
+                       <xs:element name="snapshot_mode" type="uint32_type" minOccurs="0" />
+                       <xs:element name="live_timer_interval" type="uint32_type" minOccurs="0" />
+                       <xs:element name="channels" type="channels_type" minOccurs="0" />
+                       <xs:element name="domains" type="domains_type" minOccurs="0" />
+                       <xs:element name="snapshots" type="snapshots_type" minOccurs="0" />
+               </xs:all>
+       </xs:complexType>
+
+       <!-- Maps to a lttng_event_field -->
+       <xs:complexType name="event_field_type">
+               <xs:all>
+                       <xs:element name="name" type="name_type" />
+                       <xs:element name="type" type="event_field_type_type" />
+                       <xs:element name="nowrite" type="xs:int" />
+               </xs:all>
+       </xs:complexType>
+
+       <!-- Map to the save command -->
+       <xs:complexType name="save_type">
+               <xs:all>
+                       <xs:element name="session" type="session_type" />
+                       <xs:element name="path" type="name_type" />
+               </xs:all>
+       </xs:complexType>
+
+       <!-- Map to the load command -->
+       <xs:complexType name="load_type">
+               <xs:all>
+                       <xs:element name="session" type="session_type" />
+                       <xs:element name="path" type="name_type" />
+               </xs:all>
+       </xs:complexType>
+
+       <!-- Maps to struct lttng_calibrate -->
+       <xs:complexType name="calibrate_type">
+               <xs:all>
+                       <xs:element name="type" type="calibrate_type_type" />
+               </xs:all>
+       </xs:complexType>
+
+       <!-- Map to lttng_event_perf_counter_ctx -->
+       <xs:complexType name="perf_counter_context_type">
+               <xs:all>
+                       <xs:element name="type" type="uint32_type" />
+                       <xs:element name="config" type="uint64_type" />
+                       <xs:element name="name" type="name_type" />
+               </xs:all>
+       </xs:complexType>
+
+       <!-- Map to lttng_event_context -->
+       <xs:complexType name="context_type">
+               <xs:all>
+                       <xs:element name="type" type="context_type_type" />
+                       <xs:element name="perf_counter_context" type="perf_counter_context_type" minOccurs="0" />
+                       <xs:element name="success" type="xs:boolean" default="false" minOccurs="0" />
+               </xs:all>
+       </xs:complexType>
+
+       <!-- Maps to an array of domain -->
+       <xs:complexType name="domains_type">
+               <xs:sequence>
+                       <xs:element name="domain" type="domain_type" minOccurs="0" maxOccurs="unbounded" />
+               </xs:sequence>
+       </xs:complexType>
+
+       <!-- Maps to an array of session -->
+       <xs:complexType name="sessions_type">
+               <xs:sequence>
+                       <xs:element name="session" type="session_type" minOccurs="0" maxOccurs="unbounded" />
+               </xs:sequence>
+       </xs:complexType>
+
+       <!-- Maps to an array of event_field -->
+       <xs:complexType name="event_fields_type">
+               <xs:sequence>
+                       <xs:element name="event_field" type="event_field_type" minOccurs="0" maxOccurs="unbounded" />
+               </xs:sequence>
+       </xs:complexType>
+
+       <!-- Maps to an array of context -->
+       <xs:complexType name="contexts_type">
+               <xs:sequence>
+                       <xs:element name="context" type="context_type" minOccurs="0" maxOccurs="unbounded" />
+               </xs:sequence>
+       </xs:complexType>
+
+       <!-- Maps to an action dutring snapshot command -->
+       <xs:complexType name="snapshot_action_type">
+               <xs:sequence>
+                       <xs:element name="name" type="snapshot_actiontype_type" minOccurs="0" />
+                       <xs:element name="output" type="output_type" minOccurs="0" />
+               </xs:sequence>
+       </xs:complexType>
+
+       <!-- Type of snapshot commands -->
+       <xs:simpleType name="snapshot_actiontype_type">
+               <xs:restriction base="xs:string">
+                       <xs:enumeration value="list-output" />
+                       <xs:enumeration value="del-output" />
+                       <xs:enumeration value="add-output" />
+                       <xs:enumeration value="record-output" />
+               </xs:restriction>
+       </xs:simpleType>
+
+       <xs:complexType name="output_type">
+               <xs:choice>
+                       <xs:element name="domains" type="domains_type" minOccurs="0" />
+                       <xs:element name="sessions" type="sessions_type" minOccurs="0" />
+                       <xs:element name="session" type="session_type" minOccurs="0" />
+                       <xs:element name="snapshot_action" type="snapshot_action_type" minOccurs="0" />
+                       <xs:element name="snapshot" type="snapshot_type" minOccurs="0" />
+                       <xs:element name="version" type="version_type" minOccurs="0" />
+                       <xs:element name="save" type="save_type" minOccurs="0" />
+                       <xs:element name="load" type="load_type" minOccurs="0" />
+                       <xs:element name="calibrate" type="calibrate_type" minOccurs="0" />
+                       <xs:element name="contexts" type="contexts_type" minOccurs="0" />
+                       <xs:element name="channels" type="channels_type" minOccurs="0" />
+                       <xs:element name="events" type="event_list_type" minOccurs="0" />
+                       <xs:element name="channel" type="channel_type" minOccurs="0" />
+               </xs:choice>
+       </xs:complexType>
+
+       <!-- Maps to the mi_lttng commands -->
+       <xs:simpleType name="command_string_type">
+               <xs:restriction base="xs:string">
+                       <xs:enumeration value="create" />
+                       <xs:enumeration value="list" />
+                       <xs:enumeration value="snapshot" />
+                       <xs:enumeration value="version" />
+                       <xs:enumeration value="save" />
+                       <xs:enumeration value="load" />
+                       <xs:enumeration value="start" />
+                       <xs:enumeration value="stop" />
+                       <xs:enumeration value="destroy" />
+                       <xs:enumeration value="calibrate" />
+                       <xs:enumeration value="add-context" />
+                       <xs:enumeration value="enable-channel" />
+                       <xs:enumeration value="enable-event" />
+                       <xs:enumeration value="set-session" />
+                       <xs:enumeration value="disable-event" />
+                       <xs:enumeration value="disable-channel" />
+               </xs:restriction>
+       </xs:simpleType>
+
+       <xs:element name="command">
+               <xs:complexType>
+                       <xs:all>
+                               <xs:element name="name" type="command_string_type" maxOccurs="1" />
+                               <xs:element name="output" type="output_type" maxOccurs="1" />
+                               <xs:element name="success" type="xs:boolean" minOccurs="0" maxOccurs="1" />
+                       </xs:all>
+               </xs:complexType>
+       </xs:element>
+</xs:schema>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control/.project b/lttng/org.eclipse.tracecompass.lttng2.control/.project
new file mode 100644 (file)
index 0000000..746cab5
--- /dev/null
@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+       <name>org.eclipse.tracecompass.lttng2.control</name>
+       <comment></comment>
+       <projects>
+       </projects>
+       <buildSpec>
+               <buildCommand>
+                       <name>org.eclipse.pde.FeatureBuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+       </buildSpec>
+       <natures>
+               <nature>org.eclipse.pde.FeatureNature</nature>
+       </natures>
+</projectDescription>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control/.settings/org.eclipse.core.resources.prefs b/lttng/org.eclipse.tracecompass.lttng2.control/.settings/org.eclipse.core.resources.prefs
new file mode 100644 (file)
index 0000000..99f26c0
--- /dev/null
@@ -0,0 +1,2 @@
+eclipse.preferences.version=1
+encoding/<project>=UTF-8
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control/.settings/org.eclipse.core.runtime.prefs b/lttng/org.eclipse.tracecompass.lttng2.control/.settings/org.eclipse.core.runtime.prefs
new file mode 100644 (file)
index 0000000..5a0ad22
--- /dev/null
@@ -0,0 +1,2 @@
+eclipse.preferences.version=1
+line.separator=\n
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control/build.properties b/lttng/org.eclipse.tracecompass.lttng2.control/build.properties
new file mode 100644 (file)
index 0000000..9991fff
--- /dev/null
@@ -0,0 +1,16 @@
+###############################################################################
+# Copyright (c) 2013, 2014 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:
+#     Ericsson - Initial API and implementation
+###############################################################################
+
+bin.includes = feature.xml,\
+               feature.properties,\
+               p2.inf
+src.includes = sourceTemplateFeature/p2.inf
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control/feature.properties b/lttng/org.eclipse.tracecompass.lttng2.control/feature.properties
new file mode 100644 (file)
index 0000000..c9f78ae
--- /dev/null
@@ -0,0 +1,21 @@
+###############################################################################
+# Copyright (c) 2012, 2015 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:
+#     Ericsson - Initial API and implementation
+###############################################################################
+
+featureName=LTTng Tracer Control
+
+description=Plug-ins to integrate the LTTng tracer control into the workbench. \
+Includes the TMF (Tracing and Monitoring Framework) and CTF (Common Trace Format) features.
+
+featureProvider=Eclipse Trace Compass
+
+copyright=Copyright 2015 Ericsson
+
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control/feature.xml b/lttng/org.eclipse.tracecompass.lttng2.control/feature.xml
new file mode 100644 (file)
index 0000000..6ce0aa4
--- /dev/null
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<feature
+      id="org.eclipse.tracecompass.lttng2.control"
+      label="%featureName"
+      version="1.0.0.qualifier"
+      provider-name="%featureProvider"
+      license-feature="org.eclipse.license"
+      license-feature-version="0.0.0">
+
+   <description url="http://www.example.com/description">
+      %description
+   </description>
+
+   <copyright url="http://www.example.com/copyright">
+      %copyright
+   </copyright>
+
+   <license url="%licenseURL">
+      %license
+   </license>
+
+   <includes
+         id="org.eclipse.tracecompass.tmf.ctf"
+         version="0.0.0"/>
+
+   <requires>
+      <import plugin="org.eclipse.core.runtime"/>
+      <import plugin="org.eclipse.ui"/>
+      <import plugin="org.eclipse.ui.ide"/>
+      <import plugin="org.eclipse.core.resources"/>
+      <import plugin="org.eclipse.tracecompass.ctf.core" version="1.0.0" match="greaterOrEqual"/>
+      <import plugin="org.eclipse.tracecompass.lttng2.control.core" version="1.0.0" match="greaterOrEqual"/>
+      <import plugin="org.eclipse.tracecompass.tmf.core" version="1.0.0" match="greaterOrEqual"/>
+      <import plugin="org.eclipse.tracecompass.tmf.ctf.core" version="1.0.0" match="greaterOrEqual"/>
+      <import plugin="org.eclipse.tracecompass.tmf.remote.core" version="1.0.0" match="greaterOrEqual"/>
+      <import plugin="org.eclipse.tracecompass.tmf.remote.ui" version="1.0.0" match="greaterOrEqual"/>
+      <import plugin="org.eclipse.tracecompass.tmf.ui" version="1.0.0" match="greaterOrEqual"/>
+      <import plugin="org.eclipse.help"/>
+      <import feature="org.eclipse.remote" version="2.0.0" match="greaterOrEqual"/>
+      <import plugin="com.google.guava"/>
+      <import plugin="org.eclipse.core.expressions"/>
+   </requires>
+
+   <plugin
+         id="org.eclipse.tracecompass.lttng2.control.core"
+         download-size="0"
+         install-size="0"
+         version="0.0.0"
+         unpack="false"/>
+
+   <plugin
+         id="org.eclipse.tracecompass.lttng2.control.ui"
+         download-size="0"
+         install-size="0"
+         version="0.0.0"
+         unpack="false"/>
+
+   <plugin
+         id="org.eclipse.tracecompass.doc.user"
+         download-size="0"
+         install-size="0"
+         version="0.0.0"/>
+
+   <plugin
+         id="org.eclipse.tracecompass.tmf.remote.core"
+         download-size="0"
+         install-size="0"
+         version="0.0.0"
+         unpack="false"/>
+
+   <plugin
+         id="org.eclipse.tracecompass.tmf.remote.ui"
+         download-size="0"
+         install-size="0"
+         version="0.0.0"
+         unpack="false"/>
+
+</feature>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control/p2.inf b/lttng/org.eclipse.tracecompass.lttng2.control/p2.inf
new file mode 100644 (file)
index 0000000..5b8cc7b
--- /dev/null
@@ -0,0 +1 @@
+update.matchExp=providedCapabilities.exists(pc | pc.namespace == 'org.eclipse.equinox.p2.iu' && (pc.name == 'org.eclipse.linuxtools.lttng2.feature.group' || pc.name == 'org.eclipse.linuxtools.lttng2.control.feature.group' || pc.name == 'org.eclipse.tracecompass.lttng2.control.feature.group'))
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control/pom.xml b/lttng/org.eclipse.tracecompass.lttng2.control/pom.xml
new file mode 100644 (file)
index 0000000..7ee65cf
--- /dev/null
@@ -0,0 +1,63 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+   Copyright (C) 2011, Red Hat, Inc.
+
+   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
+-->
+<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>
+    <artifactId>org.eclipse.tracecompass.lttng-parent</artifactId>
+    <groupId>org.eclipse.tracecompass</groupId>
+    <version>1.0.0-SNAPSHOT</version>
+  </parent>
+
+  <artifactId>org.eclipse.tracecompass.lttng2.control</artifactId>
+  <groupId>org.eclipse.tracecompass</groupId>
+  <version>1.0.0-SNAPSHOT</version>
+  <packaging>eclipse-feature</packaging>
+
+  <name>Trace Compass LTTng (Linux Tracing Toolkit) Feature</name>
+
+  <build>
+    <plugins>
+      <plugin>
+        <groupId>org.eclipse.tycho.extras</groupId>
+        <artifactId>tycho-source-feature-plugin</artifactId>
+        <executions>
+          <execution>
+            <id>source-feature</id>
+            <phase>package</phase>
+            <goals>
+              <goal>source-feature</goal>
+            </goals>
+            <configuration>
+              <excludes>
+                <plugin id="org.eclipse.tracecompass.doc.user"/>
+              </excludes>
+            </configuration>
+          </execution>
+        </executions>
+      </plugin>
+      <plugin>
+        <groupId>org.eclipse.tycho</groupId>
+        <artifactId>tycho-p2-plugin</artifactId>
+        <version>${tycho-version}</version>
+        <executions>
+          <execution>
+            <id>attached-p2-metadata</id>
+            <phase>package</phase>
+            <goals>
+              <goal>p2-metadata</goal>
+            </goals>
+          </execution>
+        </executions>
+      </plugin>
+    </plugins>
+  </build>
+</project>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.control/sourceTemplateFeature/p2.inf b/lttng/org.eclipse.tracecompass.lttng2.control/sourceTemplateFeature/p2.inf
new file mode 100644 (file)
index 0000000..e6ea35d
--- /dev/null
@@ -0,0 +1 @@
+update.matchExp=providedCapabilities.exists(pc | pc.namespace == 'org.eclipse.equinox.p2.iu' && (pc.name == 'org.eclipse.linuxtools.lttng2.source.feature.group' || pc.name == 'org.eclipse.linuxtools.lttng2.control.source.feature.group' || pc.name == 'org.eclipse.tracecompass.lttng2.control.source.feature.group'))
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/.classpath b/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/.classpath
new file mode 100644 (file)
index 0000000..8fbc9a2
--- /dev/null
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+       <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7"/>
+       <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
+       <classpathentry kind="src" path="src"/>
+       <classpathentry kind="src" path="perf"/>
+       <classpathentry kind="src" path="shared"/>
+       <classpathentry kind="output" path="bin"/>
+</classpath>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/.project b/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/.project
new file mode 100644 (file)
index 0000000..26161b2
--- /dev/null
@@ -0,0 +1,34 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+       <name>org.eclipse.tracecompass.lttng2.kernel.core.tests</name>
+       <comment></comment>
+       <projects>
+       </projects>
+       <buildSpec>
+               <buildCommand>
+                       <name>org.eclipse.jdt.core.javabuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+               <buildCommand>
+                       <name>org.eclipse.pde.ManifestBuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+               <buildCommand>
+                       <name>org.eclipse.pde.SchemaBuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+               <buildCommand>
+                       <name>org.eclipse.pde.api.tools.apiAnalysisBuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+       </buildSpec>
+       <natures>
+               <nature>org.eclipse.pde.PluginNature</nature>
+               <nature>org.eclipse.jdt.core.javanature</nature>
+               <nature>org.eclipse.pde.api.tools.apiAnalysisNature</nature>
+       </natures>
+</projectDescription>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/.settings/org.eclipse.core.resources.prefs b/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/.settings/org.eclipse.core.resources.prefs
new file mode 100644 (file)
index 0000000..99f26c0
--- /dev/null
@@ -0,0 +1,2 @@
+eclipse.preferences.version=1
+encoding/<project>=UTF-8
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/.settings/org.eclipse.core.runtime.prefs b/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/.settings/org.eclipse.core.runtime.prefs
new file mode 100644 (file)
index 0000000..5a0ad22
--- /dev/null
@@ -0,0 +1,2 @@
+eclipse.preferences.version=1
+line.separator=\n
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/.settings/org.eclipse.jdt.core.prefs b/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/.settings/org.eclipse.jdt.core.prefs
new file mode 100644 (file)
index 0000000..0409c61
--- /dev/null
@@ -0,0 +1,403 @@
+eclipse.preferences.version=1
+org.eclipse.jdt.core.codeComplete.argumentPrefixes=
+org.eclipse.jdt.core.codeComplete.argumentSuffixes=
+org.eclipse.jdt.core.codeComplete.fieldPrefixes=f
+org.eclipse.jdt.core.codeComplete.fieldSuffixes=
+org.eclipse.jdt.core.codeComplete.localPrefixes=
+org.eclipse.jdt.core.codeComplete.localSuffixes=
+org.eclipse.jdt.core.codeComplete.staticFieldPrefixes=
+org.eclipse.jdt.core.codeComplete.staticFieldSuffixes=
+org.eclipse.jdt.core.codeComplete.staticFinalFieldPrefixes=
+org.eclipse.jdt.core.codeComplete.staticFinalFieldSuffixes=
+org.eclipse.jdt.core.compiler.annotation.inheritNullAnnotations=enabled
+org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore
+org.eclipse.jdt.core.compiler.annotation.nonnull=org.eclipse.jdt.annotation.NonNull
+org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=org.eclipse.jdt.annotation.NonNullByDefault
+org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nullable
+org.eclipse.jdt.core.compiler.annotation.nullanalysis=enabled
+org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
+org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
+org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
+org.eclipse.jdt.core.compiler.compliance=1.7
+org.eclipse.jdt.core.compiler.debug.lineNumber=generate
+org.eclipse.jdt.core.compiler.debug.localVariable=generate
+org.eclipse.jdt.core.compiler.debug.sourceFile=generate
+org.eclipse.jdt.core.compiler.doc.comment.support=enabled
+org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=error
+org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
+org.eclipse.jdt.core.compiler.problem.autoboxing=ignore
+org.eclipse.jdt.core.compiler.problem.comparingIdentical=error
+org.eclipse.jdt.core.compiler.problem.deadCode=error
+org.eclipse.jdt.core.compiler.problem.deprecation=error
+org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled
+org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=enabled
+org.eclipse.jdt.core.compiler.problem.discouragedReference=error
+org.eclipse.jdt.core.compiler.problem.emptyStatement=error
+org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
+org.eclipse.jdt.core.compiler.problem.explicitlyClosedAutoCloseable=error
+org.eclipse.jdt.core.compiler.problem.fallthroughCase=error
+org.eclipse.jdt.core.compiler.problem.fatalOptionalError=disabled
+org.eclipse.jdt.core.compiler.problem.fieldHiding=error
+org.eclipse.jdt.core.compiler.problem.finalParameterBound=error
+org.eclipse.jdt.core.compiler.problem.finallyBlockNotCompletingNormally=error
+org.eclipse.jdt.core.compiler.problem.forbiddenReference=error
+org.eclipse.jdt.core.compiler.problem.hiddenCatchBlock=error
+org.eclipse.jdt.core.compiler.problem.includeNullInfoFromAsserts=disabled
+org.eclipse.jdt.core.compiler.problem.incompatibleNonInheritedInterfaceMethod=error
+org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch=error
+org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=error
+org.eclipse.jdt.core.compiler.problem.invalidJavadoc=warning
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTags=enabled
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsDeprecatedRef=enabled
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsNotVisibleRef=enabled
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsVisibility=protected
+org.eclipse.jdt.core.compiler.problem.localVariableHiding=error
+org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=error
+org.eclipse.jdt.core.compiler.problem.missingDefaultCase=error
+org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=error
+org.eclipse.jdt.core.compiler.problem.missingEnumCaseDespiteDefault=enabled
+org.eclipse.jdt.core.compiler.problem.missingHashCodeMethod=error
+org.eclipse.jdt.core.compiler.problem.missingJavadocComments=warning
+org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsOverriding=disabled
+org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsVisibility=protected
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagDescription=all_standard_tags
+org.eclipse.jdt.core.compiler.problem.missingJavadocTags=warning
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagsMethodTypeParameters=disabled
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagsOverriding=disabled
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagsVisibility=protected
+org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotation=error
+org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotationForInterfaceMethodImplementation=enabled
+org.eclipse.jdt.core.compiler.problem.missingSerialVersion=error
+org.eclipse.jdt.core.compiler.problem.missingSynchronizedOnInheritedMethod=error
+org.eclipse.jdt.core.compiler.problem.noEffectAssignment=error
+org.eclipse.jdt.core.compiler.problem.noImplicitStringConversion=error
+org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=ignore
+org.eclipse.jdt.core.compiler.problem.nonnullParameterAnnotationDropped=warning
+org.eclipse.jdt.core.compiler.problem.nullAnnotationInferenceConflict=warning
+org.eclipse.jdt.core.compiler.problem.nullReference=error
+org.eclipse.jdt.core.compiler.problem.nullSpecViolation=error
+org.eclipse.jdt.core.compiler.problem.nullUncheckedConversion=warning
+org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=error
+org.eclipse.jdt.core.compiler.problem.parameterAssignment=error
+org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=error
+org.eclipse.jdt.core.compiler.problem.potentialNullReference=error
+org.eclipse.jdt.core.compiler.problem.potentiallyUnclosedCloseable=warning
+org.eclipse.jdt.core.compiler.problem.rawTypeReference=error
+org.eclipse.jdt.core.compiler.problem.redundantNullAnnotation=warning
+org.eclipse.jdt.core.compiler.problem.redundantNullCheck=error
+org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=error
+org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=error
+org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore
+org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=error
+org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled
+org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=error
+org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=disabled
+org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled
+org.eclipse.jdt.core.compiler.problem.syntacticNullAnalysisForFields=enabled
+org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=ignore
+org.eclipse.jdt.core.compiler.problem.typeParameterHiding=error
+org.eclipse.jdt.core.compiler.problem.unavoidableGenericTypeProblems=disabled
+org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=error
+org.eclipse.jdt.core.compiler.problem.unclosedCloseable=error
+org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=ignore
+org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=error
+org.eclipse.jdt.core.compiler.problem.unnecessaryElse=error
+org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=error
+org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=error
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionExemptExceptionAndThrowable=disabled
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionIncludeDocCommentReference=disabled
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverriding=disabled
+org.eclipse.jdt.core.compiler.problem.unusedImport=error
+org.eclipse.jdt.core.compiler.problem.unusedLabel=error
+org.eclipse.jdt.core.compiler.problem.unusedLocal=error
+org.eclipse.jdt.core.compiler.problem.unusedObjectAllocation=ignore
+org.eclipse.jdt.core.compiler.problem.unusedParameter=ignore
+org.eclipse.jdt.core.compiler.problem.unusedParameterIncludeDocCommentReference=enabled
+org.eclipse.jdt.core.compiler.problem.unusedParameterWhenImplementingAbstract=disabled
+org.eclipse.jdt.core.compiler.problem.unusedParameterWhenOverridingConcrete=disabled
+org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=error
+org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=ignore
+org.eclipse.jdt.core.compiler.problem.unusedWarningToken=error
+org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=error
+org.eclipse.jdt.core.compiler.source=1.7
+org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=16
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_call=16
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation=16
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression=16
+org.eclipse.jdt.core.formatter.alignment_for_assignment=0
+org.eclipse.jdt.core.formatter.alignment_for_binary_expression=16
+org.eclipse.jdt.core.formatter.alignment_for_compact_if=16
+org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=80
+org.eclipse.jdt.core.formatter.alignment_for_enum_constants=0
+org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=16
+org.eclipse.jdt.core.formatter.alignment_for_method_declaration=0
+org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16
+org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=80
+org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation=0
+org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_constructor_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_method_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_union_type_in_multicatch=16
+org.eclipse.jdt.core.formatter.blank_lines_after_imports=1
+org.eclipse.jdt.core.formatter.blank_lines_after_package=1
+org.eclipse.jdt.core.formatter.blank_lines_before_field=0
+org.eclipse.jdt.core.formatter.blank_lines_before_first_class_body_declaration=0
+org.eclipse.jdt.core.formatter.blank_lines_before_imports=1
+org.eclipse.jdt.core.formatter.blank_lines_before_member_type=1
+org.eclipse.jdt.core.formatter.blank_lines_before_method=1
+org.eclipse.jdt.core.formatter.blank_lines_before_new_chunk=1
+org.eclipse.jdt.core.formatter.blank_lines_before_package=0
+org.eclipse.jdt.core.formatter.blank_lines_between_import_groups=1
+org.eclipse.jdt.core.formatter.blank_lines_between_type_declarations=1
+org.eclipse.jdt.core.formatter.brace_position_for_annotation_type_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_array_initializer=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_block=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_block_in_case=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_constructor_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_enum_constant=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_enum_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_method_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_switch=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_type_declaration=end_of_line
+org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_block_comment=false
+org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_javadoc_comment=false
+org.eclipse.jdt.core.formatter.comment.format_block_comments=true
+org.eclipse.jdt.core.formatter.comment.format_header=false
+org.eclipse.jdt.core.formatter.comment.format_html=true
+org.eclipse.jdt.core.formatter.comment.format_javadoc_comments=true
+org.eclipse.jdt.core.formatter.comment.format_line_comments=true
+org.eclipse.jdt.core.formatter.comment.format_source_code=true
+org.eclipse.jdt.core.formatter.comment.indent_parameter_description=true
+org.eclipse.jdt.core.formatter.comment.indent_root_tags=true
+org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags=insert
+org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter=insert
+org.eclipse.jdt.core.formatter.comment.line_length=80
+org.eclipse.jdt.core.formatter.comment.new_lines_at_block_boundaries=true
+org.eclipse.jdt.core.formatter.comment.new_lines_at_javadoc_boundaries=true
+org.eclipse.jdt.core.formatter.comment.preserve_white_space_between_code_and_line_comments=false
+org.eclipse.jdt.core.formatter.compact_else_if=true
+org.eclipse.jdt.core.formatter.continuation_indentation=2
+org.eclipse.jdt.core.formatter.continuation_indentation_for_array_initializer=2
+org.eclipse.jdt.core.formatter.disabling_tag=@formatter\:off
+org.eclipse.jdt.core.formatter.enabling_tag=@formatter\:on
+org.eclipse.jdt.core.formatter.format_guardian_clause_on_one_line=false
+org.eclipse.jdt.core.formatter.format_line_comment_starting_on_first_column=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_annotation_declaration_header=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_constant_header=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_declaration_header=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_type_header=true
+org.eclipse.jdt.core.formatter.indent_breaks_compare_to_cases=true
+org.eclipse.jdt.core.formatter.indent_empty_lines=false
+org.eclipse.jdt.core.formatter.indent_statements_compare_to_block=true
+org.eclipse.jdt.core.formatter.indent_statements_compare_to_body=true
+org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_cases=true
+org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_switch=false
+org.eclipse.jdt.core.formatter.indentation.size=4
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_field=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_local_variable=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_method=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_package=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_parameter=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_type=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_label=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_opening_brace_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_at_end_of_file_if_missing=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_finally_in_try_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_while_in_do_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_annotation_declaration=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_anonymous_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_block=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter=insert
+org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_binary_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_paren_in_cast=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_assert=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_case=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_labeled_statement=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_allocation_expression=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_annotation=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_throws=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_constant_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_declarations=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_explicitconstructorcall_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_increments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_inits=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_throws=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_invocation_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_field_declarations=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_local_declarations=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_parameterized_type_reference=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_superinterfaces=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_ellipsis=insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_brace_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_cast=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_catch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_for=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_if=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_parenthesized_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_switch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_synchronized=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_try=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_while=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_try_resources=insert
+org.eclipse.jdt.core.formatter.insert_space_after_unary_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter=insert
+org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_binary_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_brace_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_cast=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_catch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_for=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_if=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_parenthesized_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_switch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_synchronized=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_try=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_while=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_assert=insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_case=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_default=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_labeled_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_throws=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_constant_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_declarations=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_explicitconstructorcall_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_increments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_inits=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_throws=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_invocation_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_field_declarations=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_local_declarations=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_superinterfaces=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_ellipsis=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_annotation_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_anonymous_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_block=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_constructor_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_constant=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_method_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_switch=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation_type_member_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_catch=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_if=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_parenthesized_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_switch=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_synchronized=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_try=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_while=insert
+org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_return=insert
+org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_throw=insert
+org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_semicolon=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_try_resources=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_unary_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_brackets_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_annotation_type_member_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.join_lines_in_comments=true
+org.eclipse.jdt.core.formatter.join_wrapped_lines=false
+org.eclipse.jdt.core.formatter.keep_else_statement_on_same_line=false
+org.eclipse.jdt.core.formatter.keep_empty_array_initializer_on_one_line=false
+org.eclipse.jdt.core.formatter.keep_imple_if_on_one_line=false
+org.eclipse.jdt.core.formatter.keep_then_statement_on_same_line=false
+org.eclipse.jdt.core.formatter.lineSplit=250
+org.eclipse.jdt.core.formatter.never_indent_block_comments_on_first_column=false
+org.eclipse.jdt.core.formatter.never_indent_line_comments_on_first_column=false
+org.eclipse.jdt.core.formatter.number_of_blank_lines_at_beginning_of_method_body=0
+org.eclipse.jdt.core.formatter.number_of_empty_lines_to_preserve=1
+org.eclipse.jdt.core.formatter.put_empty_statement_on_new_line=true
+org.eclipse.jdt.core.formatter.tabulation.char=space
+org.eclipse.jdt.core.formatter.tabulation.size=4
+org.eclipse.jdt.core.formatter.use_on_off_tags=false
+org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false
+org.eclipse.jdt.core.formatter.wrap_before_binary_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_or_operator_multicatch=true
+org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/.settings/org.eclipse.jdt.ui.prefs b/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/.settings/org.eclipse.jdt.ui.prefs
new file mode 100644 (file)
index 0000000..232a3fd
--- /dev/null
@@ -0,0 +1,60 @@
+eclipse.preferences.version=1
+editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true
+formatter_profile=_tmf-style
+formatter_settings_version=12
+org.eclipse.jdt.ui.exception.name=e
+org.eclipse.jdt.ui.gettersetter.use.is=true
+org.eclipse.jdt.ui.keywordthis=false
+org.eclipse.jdt.ui.overrideannotation=true
+sp_cleanup.add_default_serial_version_id=true
+sp_cleanup.add_generated_serial_version_id=false
+sp_cleanup.add_missing_annotations=false
+sp_cleanup.add_missing_deprecated_annotations=true
+sp_cleanup.add_missing_methods=false
+sp_cleanup.add_missing_nls_tags=false
+sp_cleanup.add_missing_override_annotations=true
+sp_cleanup.add_missing_override_annotations_interface_methods=true
+sp_cleanup.add_serial_version_id=false
+sp_cleanup.always_use_blocks=true
+sp_cleanup.always_use_parentheses_in_expressions=false
+sp_cleanup.always_use_this_for_non_static_field_access=false
+sp_cleanup.always_use_this_for_non_static_method_access=false
+sp_cleanup.convert_to_enhanced_for_loop=false
+sp_cleanup.correct_indentation=false
+sp_cleanup.format_source_code=false
+sp_cleanup.format_source_code_changes_only=false
+sp_cleanup.make_local_variable_final=false
+sp_cleanup.make_parameters_final=false
+sp_cleanup.make_private_fields_final=true
+sp_cleanup.make_type_abstract_if_missing_method=false
+sp_cleanup.make_variable_declarations_final=false
+sp_cleanup.never_use_blocks=false
+sp_cleanup.never_use_parentheses_in_expressions=true
+sp_cleanup.on_save_use_additional_actions=true
+sp_cleanup.organize_imports=false
+sp_cleanup.qualify_static_field_accesses_with_declaring_class=false
+sp_cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=true
+sp_cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=true
+sp_cleanup.qualify_static_member_accesses_with_declaring_class=false
+sp_cleanup.qualify_static_method_accesses_with_declaring_class=false
+sp_cleanup.remove_private_constructors=true
+sp_cleanup.remove_trailing_whitespaces=true
+sp_cleanup.remove_trailing_whitespaces_all=true
+sp_cleanup.remove_trailing_whitespaces_ignore_empty=false
+sp_cleanup.remove_unnecessary_casts=false
+sp_cleanup.remove_unnecessary_nls_tags=false
+sp_cleanup.remove_unused_imports=false
+sp_cleanup.remove_unused_local_variables=false
+sp_cleanup.remove_unused_private_fields=true
+sp_cleanup.remove_unused_private_members=false
+sp_cleanup.remove_unused_private_methods=true
+sp_cleanup.remove_unused_private_types=true
+sp_cleanup.sort_members=false
+sp_cleanup.sort_members_all=false
+sp_cleanup.use_blocks=true
+sp_cleanup.use_blocks_only_for_return_and_throw=false
+sp_cleanup.use_parentheses_in_expressions=false
+sp_cleanup.use_this_for_non_static_field_access=false
+sp_cleanup.use_this_for_non_static_field_access_only_if_necessary=true
+sp_cleanup.use_this_for_non_static_method_access=false
+sp_cleanup.use_this_for_non_static_method_access_only_if_necessary=true
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/.settings/org.eclipse.pde.api.tools.prefs b/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/.settings/org.eclipse.pde.api.tools.prefs
new file mode 100644 (file)
index 0000000..acc3abd
--- /dev/null
@@ -0,0 +1,97 @@
+ANNOTATION_ELEMENT_TYPE_ADDED_METHOD_WITHOUT_DEFAULT_VALUE=Error
+ANNOTATION_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+ANNOTATION_ELEMENT_TYPE_REMOVED_FIELD=Error
+ANNOTATION_ELEMENT_TYPE_REMOVED_METHOD=Error
+ANNOTATION_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_API_TYPE=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_API_TYPE=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_TYPE=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_TYPE=Error
+API_USE_SCAN_FIELD_SEVERITY=Error
+API_USE_SCAN_METHOD_SEVERITY=Error
+API_USE_SCAN_TYPE_SEVERITY=Error
+CLASS_ELEMENT_TYPE_ADDED_METHOD=Error
+CLASS_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
+CLASS_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+CLASS_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
+CLASS_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+CLASS_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
+CLASS_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
+CLASS_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+CLASS_ELEMENT_TYPE_REMOVED_CONSTRUCTOR=Error
+CLASS_ELEMENT_TYPE_REMOVED_FIELD=Error
+CLASS_ELEMENT_TYPE_REMOVED_METHOD=Error
+CLASS_ELEMENT_TYPE_REMOVED_SUPERCLASS=Error
+CLASS_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+CLASS_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+CONSTRUCTOR_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+CONSTRUCTOR_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+CONSTRUCTOR_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
+CONSTRUCTOR_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+ENUM_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
+ENUM_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+ENUM_ELEMENT_TYPE_REMOVED_ENUM_CONSTANT=Error
+ENUM_ELEMENT_TYPE_REMOVED_FIELD=Error
+ENUM_ELEMENT_TYPE_REMOVED_METHOD=Error
+ENUM_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+FIELD_ELEMENT_TYPE_ADDED_VALUE=Error
+FIELD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+FIELD_ELEMENT_TYPE_CHANGED_FINAL_TO_NON_FINAL_STATIC_CONSTANT=Error
+FIELD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
+FIELD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
+FIELD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
+FIELD_ELEMENT_TYPE_CHANGED_TYPE=Error
+FIELD_ELEMENT_TYPE_CHANGED_VALUE=Error
+FIELD_ELEMENT_TYPE_REMOVED_TYPE_ARGUMENT=Error
+FIELD_ELEMENT_TYPE_REMOVED_VALUE=Error
+ILLEGAL_EXTEND=Warning
+ILLEGAL_IMPLEMENT=Warning
+ILLEGAL_INSTANTIATE=Warning
+ILLEGAL_OVERRIDE=Warning
+ILLEGAL_REFERENCE=Warning
+INTERFACE_ELEMENT_TYPE_ADDED_FIELD=Error
+INTERFACE_ELEMENT_TYPE_ADDED_METHOD=Error
+INTERFACE_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
+INTERFACE_ELEMENT_TYPE_ADDED_SUPER_INTERFACE_WITH_METHODS=Error
+INTERFACE_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+INTERFACE_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
+INTERFACE_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_FIELD=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_METHOD=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+INVALID_JAVADOC_TAG=Warning
+INVALID_REFERENCE_IN_SYSTEM_LIBRARIES=Warning
+LEAK_EXTEND=Warning
+LEAK_FIELD_DECL=Warning
+LEAK_IMPLEMENT=Warning
+LEAK_METHOD_PARAM=Warning
+LEAK_METHOD_RETURN_TYPE=Warning
+METHOD_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
+METHOD_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+METHOD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+METHOD_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
+METHOD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
+METHOD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
+METHOD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
+METHOD_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
+METHOD_ELEMENT_TYPE_REMOVED_ANNOTATION_DEFAULT_VALUE=Error
+METHOD_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+MISSING_EE_DESCRIPTIONS=Ignore
+TYPE_PARAMETER_ELEMENT_TYPE_ADDED_CLASS_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_ADDED_INTERFACE_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_CLASS_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_INTERFACE_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_CLASS_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_INTERFACE_BOUND=Error
+UNUSED_PROBLEM_FILTERS=Warning
+automatically_removed_unused_problem_filters=false
+eclipse.preferences.version=1
+incompatible_api_component_version=Error
+incompatible_api_component_version_include_major_without_breaking_change=Disabled
+incompatible_api_component_version_include_minor_without_api_change=Disabled
+invalid_since_tag_version=Error
+malformed_since_tag=Error
+missing_since_tag=Error
+report_api_breakage_when_major_version_incremented=Disabled
+report_resolution_errors_api_component=Warning
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/.settings/org.eclipse.pde.prefs b/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/.settings/org.eclipse.pde.prefs
new file mode 100644 (file)
index 0000000..62cfa90
--- /dev/null
@@ -0,0 +1,32 @@
+compilers.f.unresolved-features=1
+compilers.f.unresolved-plugins=1
+compilers.incompatible-environment=1
+compilers.p.build=1
+compilers.p.build.bin.includes=1
+compilers.p.build.encodings=2
+compilers.p.build.java.compiler=2
+compilers.p.build.java.compliance=1
+compilers.p.build.missing.output=2
+compilers.p.build.output.library=1
+compilers.p.build.source.library=1
+compilers.p.build.src.includes=1
+compilers.p.deprecated=1
+compilers.p.discouraged-class=1
+compilers.p.internal=1
+compilers.p.missing-packages=2
+compilers.p.missing-version-export-package=2
+compilers.p.missing-version-import-package=2
+compilers.p.missing-version-require-bundle=2
+compilers.p.no-required-att=0
+compilers.p.not-externalized-att=2
+compilers.p.unknown-attribute=1
+compilers.p.unknown-class=1
+compilers.p.unknown-element=1
+compilers.p.unknown-identifier=1
+compilers.p.unknown-resource=1
+compilers.p.unresolved-ex-points=0
+compilers.p.unresolved-import=0
+compilers.s.create-docs=false
+compilers.s.doc-folder=doc
+compilers.s.open-tags=1
+eclipse.preferences.version=1
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/META-INF/MANIFEST.MF b/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/META-INF/MANIFEST.MF
new file mode 100644 (file)
index 0000000..271ede2
--- /dev/null
@@ -0,0 +1,31 @@
+Manifest-Version: 1.0
+Bundle-ManifestVersion: 2
+Bundle-Name: %Bundle-Name
+Bundle-Vendor: %Bundle-Vendor
+Bundle-Version: 1.0.0.qualifier
+Bundle-Localization: plugin
+Bundle-SymbolicName: org.eclipse.tracecompass.lttng2.kernel.core.tests;singleton:=true
+Bundle-Activator: org.eclipse.tracecompass.lttng2.kernel.core.tests.Activator
+Bundle-ActivationPolicy: lazy
+Bundle-RequiredExecutionEnvironment: JavaSE-1.7
+Require-Bundle: org.junit;bundle-version="4.0.0",
+ org.eclipse.core.runtime,
+ org.eclipse.tracecompass.common.core,
+ org.eclipse.tracecompass.tmf.core,
+ org.eclipse.tracecompass.tmf.core.tests,
+ org.eclipse.tracecompass.tmf.ctf.core,
+ org.eclipse.tracecompass.tmf.ctf.core.tests,
+ org.eclipse.tracecompass.lttng2.kernel.core,
+ org.eclipse.core.resources,
+ org.eclipse.tracecompass.lttng2.control.core,
+ org.eclipse.tracecompass.analysis.os.linux.core,
+ org.eclipse.tracecompass.analysis.os.linux.core.tests
+Export-Package: org.eclipse.tracecompass.lttng2.kernel.core.tests,
+ org.eclipse.tracecompass.lttng2.kernel.core.tests.analysis.kernel;x-internal:=true,
+ org.eclipse.tracecompass.lttng2.kernel.core.tests.analysis.kernel.statesystem;x-internal:=true,
+ org.eclipse.tracecompass.lttng2.kernel.core.tests.event.matchandsync;x-internal:=true,
+ org.eclipse.tracecompass.lttng2.kernel.core.tests.perf,
+ org.eclipse.tracecompass.lttng2.kernel.core.tests.perf.analysis;x-internal:=true,
+ org.eclipse.tracecompass.lttng2.lttng.kernel.core.tests.shared.vm
+Import-Package: com.google.common.collect,
+ org.eclipse.test.performance
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/about.html b/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/about.html
new file mode 100644 (file)
index 0000000..c258ef5
--- /dev/null
@@ -0,0 +1,28 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"/>
+<title>About</title>
+</head>
+<body lang="EN-US">
+<h2>About This Content</h2>
+<p>June 5, 2006</p>    
+<h3>License</h3>
+
+<p>The Eclipse Foundation makes available all content in this plug-in (&quot;Content&quot;).  Unless otherwise 
+indicated below, the Content is provided to you under the terms and conditions of the
+Eclipse Public License Version 1.0 (&quot;EPL&quot;).  A copy of the EPL is available 
+at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>.
+For purposes of the EPL, &quot;Program&quot; will mean the Content.</p>
+
+<p>If you did not receive this Content directly from the Eclipse Foundation, the Content is 
+being redistributed by another party (&quot;Redistributor&quot;) and different terms and conditions may
+apply to your use of any object code in the Content.  Check the Redistributor's license that was 
+provided with the Content.  If no such license exists, contact the Redistributor.  Unless otherwise
+indicated below, the terms and conditions of the EPL still apply to any source code in the Content
+and such source code may be obtained at <a href="http://www.eclipse.org/">http://www.eclipse.org</a>.</p>
+
+</body>
+</html>
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/build.properties b/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/build.properties
new file mode 100644 (file)
index 0000000..68a4f26
--- /dev/null
@@ -0,0 +1,23 @@
+###############################################################################
+# Copyright (c) 2013, 2015 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:
+#     Ericsson - Initial API and implementation
+###############################################################################
+
+source.. = src/,\
+           perf/,\
+           shared/
+output.. = bin/
+bin.includes = META-INF/,\
+               .,\
+               plugin.properties,\
+               about.html
+src.includes = about.html
+additional.bundles = org.eclipse.jdt.annotation
+jars.extra.classpath = platform:/plugin/org.eclipse.jdt.annotation
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/perf/org/eclipse/tracecompass/lttng2/kernel/core/tests/perf/AllPerfTests.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/perf/org/eclipse/tracecompass/lttng2/kernel/core/tests/perf/AllPerfTests.java
new file mode 100644 (file)
index 0000000..7d3b2bf
--- /dev/null
@@ -0,0 +1,30 @@
+/*******************************************************************************
+ * Copyright (c) 2014 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:
+ *   Alexandre Montplaisir - Initial implementation and API
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.kernel.core.tests.perf;
+
+import org.junit.runner.RunWith;
+import org.junit.runners.Suite;
+
+/**
+ * Run all performance test suites.
+ *
+ * @author Alexandre Montplaisir
+ */
+@RunWith(Suite.class)
+@Suite.SuiteClasses({
+        org.eclipse.tracecompass.lttng2.kernel.core.tests.perf.analysis.AllPerfTests.class,
+        org.eclipse.tracecompass.lttng2.kernel.core.tests.perf.event.matching.AllPerfTests.class
+})
+public class AllPerfTests {
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/perf/org/eclipse/tracecompass/lttng2/kernel/core/tests/perf/analysis/AllPerfTests.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/perf/org/eclipse/tracecompass/lttng2/kernel/core/tests/perf/analysis/AllPerfTests.java
new file mode 100644 (file)
index 0000000..cd949ec
--- /dev/null
@@ -0,0 +1,26 @@
+/*******************************************************************************
+ * Copyright (c) 2014 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:
+ *   Alexandre Montplaisir - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.kernel.core.tests.perf.analysis;
+
+import org.junit.runner.RunWith;
+import org.junit.runners.Suite;
+
+/**
+ * Test suite
+ */
+@RunWith(Suite.class)
+@Suite.SuiteClasses({
+        AnalysisBenchmark.class
+})
+public class AllPerfTests {
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/perf/org/eclipse/tracecompass/lttng2/kernel/core/tests/perf/analysis/AnalysisBenchmark.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/perf/org/eclipse/tracecompass/lttng2/kernel/core/tests/perf/analysis/AnalysisBenchmark.java
new file mode 100644 (file)
index 0000000..3233cce
--- /dev/null
@@ -0,0 +1,97 @@
+/*******************************************************************************
+ * Copyright (c) 2014, 2015 École Polytechnique de Montréal
+ *
+ * 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:
+ *   Geneviève Bastien - Initial API and implementation
+ *   Alexandre Montplaisir - Convert to org.eclipse.test.performance test
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.kernel.core.tests.perf.analysis;
+
+import static org.junit.Assert.fail;
+import static org.junit.Assume.assumeTrue;
+
+import java.io.File;
+
+import org.eclipse.test.performance.Dimension;
+import org.eclipse.test.performance.Performance;
+import org.eclipse.test.performance.PerformanceMeter;
+import org.eclipse.tracecompass.analysis.os.linux.core.kernelanalysis.KernelAnalysisModule;
+import org.eclipse.tracecompass.lttng2.kernel.core.trace.LttngKernelTrace;
+import org.eclipse.tracecompass.tmf.core.analysis.IAnalysisModule;
+import org.eclipse.tracecompass.tmf.core.exceptions.TmfAnalysisException;
+import org.eclipse.tracecompass.tmf.core.exceptions.TmfTraceException;
+import org.eclipse.tracecompass.tmf.core.tests.shared.TmfTestHelper;
+import org.eclipse.tracecompass.tmf.core.trace.TmfTraceManager;
+import org.eclipse.tracecompass.tmf.ctf.core.event.CtfTmfEvent;
+import org.eclipse.tracecompass.tmf.ctf.core.tests.shared.CtfTmfTestTrace;
+import org.junit.Test;
+
+/**
+ * This is a test of the time to build a kernel state system
+ *
+ * @author Genevieve Bastien
+ */
+public class AnalysisBenchmark {
+
+    private static final String TEST_ID = "org.eclipse.linuxtools#LTTng kernel analysis";
+    private static final int LOOP_COUNT = 25;
+
+    /**
+     * Run the benchmark with "trace2"
+     */
+    @Test
+    public void testTrace2() {
+        runTest(CtfTmfTestTrace.TRACE2, "Trace2");
+    }
+
+    private static void runTest(CtfTmfTestTrace testTrace, String testName) {
+        assumeTrue(testTrace.exists());
+
+        Performance perf = Performance.getDefault();
+        PerformanceMeter pm = perf.createPerformanceMeter(TEST_ID + '#' + testName);
+        perf.tagAsSummary(pm, "LTTng Kernel Analysis: " + testName, Dimension.CPU_TIME);
+
+        if (testTrace == CtfTmfTestTrace.TRACE2) {
+            /* Do not show all traces in the global summary */
+            perf.tagAsGlobalSummary(pm, "LTTng Kernel Analysis: " + testName, Dimension.CPU_TIME);
+        }
+
+        for (int i = 0; i < LOOP_COUNT; i++) {
+            IAnalysisModule module = null;
+            try (LttngKernelTrace trace = new LttngKernelTrace()) {
+                module = new KernelAnalysisModule();
+                module.setId("test");
+                trace.initTrace(null, testTrace.getPath(), CtfTmfEvent.class);
+                module.setTrace(trace);
+
+                pm.start();
+                TmfTestHelper.executeAnalysis(module);
+                pm.stop();
+
+                /*
+                 * Delete the supplementary files, so that the next iteration
+                 * rebuilds the state system.
+                 */
+                File suppDir = new File(TmfTraceManager.getSupplementaryFileDir(trace));
+                for (File file : suppDir.listFiles()) {
+                    file.delete();
+                }
+
+            } catch (TmfAnalysisException | TmfTraceException e) {
+                fail(e.getMessage());
+            } finally {
+                if (module != null) {
+                    module.dispose();
+                }
+            }
+        }
+        pm.commit();
+        testTrace.dispose();
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/perf/org/eclipse/tracecompass/lttng2/kernel/core/tests/perf/event/matching/AllPerfTests.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/perf/org/eclipse/tracecompass/lttng2/kernel/core/tests/perf/event/matching/AllPerfTests.java
new file mode 100644 (file)
index 0000000..a9b017b
--- /dev/null
@@ -0,0 +1,28 @@
+/*******************************************************************************
+ * Copyright (c) 2014 École Polytechnique de Montréal
+ *
+ * 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:
+ *   Geneviève Bastien - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.kernel.core.tests.perf.event.matching;
+
+import org.junit.runner.RunWith;
+import org.junit.runners.Suite;
+
+/**
+ * Test suite
+ */
+@RunWith(Suite.class)
+@Suite.SuiteClasses({
+        EventMatchingBenchmark.class,
+        TraceSynchronizationBenchmark.class
+})
+public class AllPerfTests {
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/perf/org/eclipse/tracecompass/lttng2/kernel/core/tests/perf/event/matching/EventMatchingBenchmark.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/perf/org/eclipse/tracecompass/lttng2/kernel/core/tests/perf/event/matching/EventMatchingBenchmark.java
new file mode 100644 (file)
index 0000000..4e35cf4
--- /dev/null
@@ -0,0 +1,119 @@
+/*******************************************************************************
+ * Copyright (c) 2014 École Polytechnique de Montréal
+ *
+ * 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:
+ *   Geneviève Bastien - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.kernel.core.tests.perf.event.matching;
+
+import static org.junit.Assume.assumeTrue;
+
+import java.util.Set;
+
+import org.eclipse.test.performance.Dimension;
+import org.eclipse.test.performance.Performance;
+import org.eclipse.test.performance.PerformanceMeter;
+import org.eclipse.tracecompass.internal.lttng2.kernel.core.event.matching.TcpEventMatching;
+import org.eclipse.tracecompass.internal.lttng2.kernel.core.event.matching.TcpLttngEventMatching;
+import org.eclipse.tracecompass.tmf.core.event.matching.TmfEventMatching;
+import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace;
+import org.eclipse.tracecompass.tmf.ctf.core.tests.shared.CtfTmfTestTrace;
+import org.eclipse.tracecompass.tmf.ctf.core.trace.CtfTmfTrace;
+import org.junit.BeforeClass;
+import org.junit.Test;
+
+import com.google.common.collect.ImmutableSet;
+
+/**
+ * Benchmark simple event matching, without trace synchronization
+ *
+ * @author Geneviève Bastien
+ */
+public class EventMatchingBenchmark {
+
+    private static final String TEST_ID = "org.eclipse.linuxtools#Event matching#";
+    private static final String TIME = " (time)";
+    private static final String MEMORY = " (memory usage)";
+    private static final String TEST_SUMMARY = "Event matching";
+
+    /**
+     * Initialize some data
+     */
+    @BeforeClass
+    public static void setUp() {
+        TmfEventMatching.registerMatchObject(new TcpEventMatching());
+        TmfEventMatching.registerMatchObject(new TcpLttngEventMatching());
+    }
+
+    /**
+     * Run the benchmark with 2 small traces
+     */
+    @Test
+    public void testSmallTraces() {
+        assumeTrue(CtfTmfTestTrace.SYNC_SRC.exists());
+        assumeTrue(CtfTmfTestTrace.SYNC_DEST.exists());
+        try (CtfTmfTrace trace1 = CtfTmfTestTrace.SYNC_SRC.getTrace();
+                CtfTmfTrace trace2 = CtfTmfTestTrace.SYNC_DEST.getTrace();) {
+            Set<ITmfTrace> traces = ImmutableSet.of((ITmfTrace) trace1, trace2);
+            runCpuTest(traces, "Match TCP events", 100);
+        }
+    }
+
+    /**
+     * Run the benchmark with 3 bigger traces
+     */
+    @Test
+    public void testDjangoTraces() {
+        assumeTrue(CtfTmfTestTrace.DJANGO_CLIENT.exists());
+        assumeTrue(CtfTmfTestTrace.DJANGO_DB.exists());
+        assumeTrue(CtfTmfTestTrace.DJANGO_HTTPD.exists());
+        try (CtfTmfTrace trace1 = CtfTmfTestTrace.DJANGO_CLIENT.getTrace();
+                CtfTmfTrace trace2 = CtfTmfTestTrace.DJANGO_DB.getTrace();
+                CtfTmfTrace trace3 = CtfTmfTestTrace.DJANGO_HTTPD.getTrace();) {
+            Set<ITmfTrace> traces = ImmutableSet.of((ITmfTrace) trace1, trace2, trace3);
+            runCpuTest(traces, "Django traces", 10);
+            runMemoryTest(traces, "Django traces", 10);
+        }
+    }
+
+    private static void runCpuTest(Set<ITmfTrace> testTraces, String testName, int loop_count) {
+        Performance perf = Performance.getDefault();
+        PerformanceMeter pm = perf.createPerformanceMeter(TEST_ID + testName + TIME);
+        perf.tagAsSummary(pm, TEST_SUMMARY + ':' + testName + TIME, Dimension.CPU_TIME);
+
+        for (int i = 0; i < loop_count; i++) {
+            TmfEventMatching traceMatch = new TmfEventMatching(testTraces);
+
+            pm.start();
+            traceMatch.matchEvents();
+            pm.stop();
+        }
+        pm.commit();
+
+    }
+
+    /* Benchmark memory used by the algorithm */
+    private static void runMemoryTest(Set<ITmfTrace> testTraces, String testName, int loop_count) {
+        Performance perf = Performance.getDefault();
+        PerformanceMeter pm = perf.createPerformanceMeter(TEST_ID + testName + MEMORY);
+        perf.tagAsSummary(pm, TEST_SUMMARY + ':' + testName + MEMORY, Dimension.USED_JAVA_HEAP);
+
+        for (int i = 0; i < loop_count; i++) {
+            TmfEventMatching traceMatch = new TmfEventMatching(testTraces);
+
+            System.gc();
+            pm.start();
+            traceMatch.matchEvents();
+            System.gc();
+            pm.stop();
+        }
+        pm.commit();
+
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/perf/org/eclipse/tracecompass/lttng2/kernel/core/tests/perf/event/matching/TraceSynchronizationBenchmark.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/perf/org/eclipse/tracecompass/lttng2/kernel/core/tests/perf/event/matching/TraceSynchronizationBenchmark.java
new file mode 100644 (file)
index 0000000..802bc8a
--- /dev/null
@@ -0,0 +1,122 @@
+/*******************************************************************************
+ * Copyright (c) 2014 École Polytechnique de Montréal
+ *
+ * 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:
+ *   Geneviève Bastien - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.kernel.core.tests.perf.event.matching;
+
+import static org.junit.Assert.assertNotNull;
+import static org.junit.Assume.assumeTrue;
+
+import java.util.Collections;
+
+import org.eclipse.test.performance.Dimension;
+import org.eclipse.test.performance.Performance;
+import org.eclipse.test.performance.PerformanceMeter;
+import org.eclipse.tracecompass.internal.lttng2.kernel.core.event.matching.TcpEventMatching;
+import org.eclipse.tracecompass.internal.lttng2.kernel.core.event.matching.TcpLttngEventMatching;
+import org.eclipse.tracecompass.tmf.core.event.matching.TmfEventMatching;
+import org.eclipse.tracecompass.tmf.core.synchronization.SynchronizationAlgorithm;
+import org.eclipse.tracecompass.tmf.core.synchronization.SynchronizationManager;
+import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace;
+import org.eclipse.tracecompass.tmf.core.trace.experiment.TmfExperiment;
+import org.eclipse.tracecompass.tmf.ctf.core.event.CtfTmfEvent;
+import org.eclipse.tracecompass.tmf.ctf.core.tests.shared.CtfTmfTestTrace;
+import org.eclipse.tracecompass.tmf.ctf.core.trace.CtfTmfTrace;
+import org.junit.BeforeClass;
+import org.junit.Test;
+
+/**
+ * Benchmark trace synchronization
+ *
+ * @author Geneviève Bastien
+ */
+public class TraceSynchronizationBenchmark {
+
+    private static final String TEST_ID = "org.eclipse.linuxtools#Trace synchronization#";
+    private static final String TIME = " (time)";
+    private static final String MEMORY = " (memory usage)";
+    private static final String TEST_SUMMARY = "Trace synchronization";
+
+    /**
+     * Initialize some data
+     */
+    @BeforeClass
+    public static void setUp() {
+        TmfEventMatching.registerMatchObject(new TcpEventMatching());
+        TmfEventMatching.registerMatchObject(new TcpLttngEventMatching());
+    }
+
+    /**
+     * Run the benchmark with 2 small traces
+     */
+    @Test
+    public void testSmallTraces() {
+        assumeTrue(CtfTmfTestTrace.SYNC_SRC.exists());
+        assumeTrue(CtfTmfTestTrace.SYNC_DEST.exists());
+        try (CtfTmfTrace trace1 = CtfTmfTestTrace.SYNC_SRC.getTrace();
+                CtfTmfTrace trace2 = CtfTmfTestTrace.SYNC_DEST.getTrace();) {
+            ITmfTrace[] traces = { trace1, trace2 };
+            TmfExperiment experiment = new TmfExperiment(CtfTmfEvent.class, "Test experiment", traces, TmfExperiment.DEFAULT_INDEX_PAGE_SIZE, null);
+            runCpuTest(experiment, "Match TCP events", 40);
+        }
+    }
+
+    /**
+     * Run the benchmark with 3 bigger traces
+     */
+    @Test
+    public void testDjangoTraces() {
+        assumeTrue(CtfTmfTestTrace.DJANGO_CLIENT.exists());
+        assumeTrue(CtfTmfTestTrace.DJANGO_DB.exists());
+        assumeTrue(CtfTmfTestTrace.DJANGO_HTTPD.exists());
+        try (CtfTmfTrace trace1 = CtfTmfTestTrace.DJANGO_CLIENT.getTrace();
+                CtfTmfTrace trace2 = CtfTmfTestTrace.DJANGO_DB.getTrace();
+                CtfTmfTrace trace3 = CtfTmfTestTrace.DJANGO_HTTPD.getTrace();) {
+            ITmfTrace[] traces = { trace1, trace2, trace3 };
+            TmfExperiment experiment = new TmfExperiment(CtfTmfEvent.class, "Test experiment", traces, TmfExperiment.DEFAULT_INDEX_PAGE_SIZE, null);
+            runCpuTest(experiment, "Django traces", 10);
+            runMemoryTest(experiment, "Django traces", 10);
+        }
+    }
+
+    private static void runCpuTest(TmfExperiment experiment, String testName, int loop_count) {
+        Performance perf = Performance.getDefault();
+        PerformanceMeter pm = perf.createPerformanceMeter(TEST_ID + testName + TIME);
+        perf.tagAsSummary(pm, TEST_SUMMARY + ':' + testName + TIME, Dimension.CPU_TIME);
+
+        for (int i = 0; i < loop_count; i++) {
+            pm.start();
+            SynchronizationManager.synchronizeTraces(null, Collections.<ITmfTrace> singleton(experiment), true);
+            pm.stop();
+        }
+        pm.commit();
+
+    }
+
+    /* Benchmark memory used by the algorithm */
+    private static void runMemoryTest(TmfExperiment experiment, String testName, int loop_count) {
+        Performance perf = Performance.getDefault();
+        PerformanceMeter pm = perf.createPerformanceMeter(TEST_ID + testName + MEMORY);
+        perf.tagAsSummary(pm, TEST_SUMMARY + ':' + testName + MEMORY, Dimension.USED_JAVA_HEAP);
+
+        for (int i = 0; i < loop_count; i++) {
+
+            System.gc();
+            pm.start();
+            SynchronizationAlgorithm algo = SynchronizationManager.synchronizeTraces(null, Collections.<ITmfTrace> singleton(experiment), true);
+            assertNotNull(algo);
+
+            System.gc();
+            pm.stop();
+        }
+        pm.commit();
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/plugin.properties b/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/plugin.properties
new file mode 100644 (file)
index 0000000..5ed44d2
--- /dev/null
@@ -0,0 +1,14 @@
+###############################################################################
+# Copyright (c) 2013, 2014 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:
+#     Ericsson - Initial API and implementation
+###############################################################################
+
+Bundle-Vendor = Eclipse Trace Compass
+Bundle-Name = Trace Compass LTTng Kernel Analysis Core Tests Plug-in
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/pom.xml b/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/pom.xml
new file mode 100644 (file)
index 0000000..601a469
--- /dev/null
@@ -0,0 +1,44 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+   Copyright (C) 2011, Red Hat, Inc.
+
+   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
+-->
+<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>
+    <artifactId>org.eclipse.tracecompass.lttng-parent</artifactId>
+    <groupId>org.eclipse.tracecompass</groupId>
+    <version>1.0.0-SNAPSHOT</version>
+  </parent>
+
+  <artifactId>org.eclipse.tracecompass.lttng2.kernel.core.tests</artifactId>
+  <version>1.0.0-SNAPSHOT</version>
+  <packaging>eclipse-test-plugin</packaging>
+
+  <name>Trace Compass LTTng Kernel Analysis Core Tests Plug-in</name>
+
+ <build>
+    <plugins>
+      <plugin>
+        <groupId>org.eclipse.tycho</groupId>
+        <artifactId>tycho-surefire-plugin</artifactId>
+        <version>${tycho-version}</version>
+        <configuration>
+          <testSuite>org.eclipse.tracecompass.lttng2.kernel.core.tests</testSuite>
+          <testClass>org.eclipse.tracecompass.lttng2.kernel.core.tests.AllTests</testClass>
+          <useUIHarness>false</useUIHarness>
+          <useUIThread>false</useUIThread>
+          <product>org.eclipse.platform.ide</product>
+        </configuration>
+      </plugin>
+    </plugins>
+  </build>
+
+ <groupId>org.eclipse.tracecompass</groupId>
+</project>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/shared/org/eclipse/tracecompass/lttng2/lttng/kernel/core/tests/shared/vm/VmTestExperiment.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/shared/org/eclipse/tracecompass/lttng2/lttng/kernel/core/tests/shared/vm/VmTestExperiment.java
new file mode 100644 (file)
index 0000000..8fe1869
--- /dev/null
@@ -0,0 +1,95 @@
+/*******************************************************************************
+ * Copyright (c) 2014 École Polytechnique de Montréal
+ *
+ * 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:
+ *   Geneviève Bastien - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.lttng.kernel.core.tests.shared.vm;
+
+import java.io.File;
+import java.util.HashSet;
+import java.util.Set;
+
+import org.eclipse.jdt.annotation.NonNull;
+import org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.trace.VirtualMachineExperiment;
+import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace;
+import org.eclipse.tracecompass.tmf.core.trace.TmfTraceManager;
+import org.eclipse.tracecompass.tmf.core.trace.experiment.TmfExperiment;
+
+/**
+ * List virtual machine experiments that can be used in unit tests
+ *
+ * @author Geneviève Bastien
+ */
+public enum VmTestExperiment {
+
+    /**
+     * Virtual machine experiment: 1 guest, 1 host, using QEMU/KVM model
+     */
+    ONE_QEMUKVM(VmTraces.HOST_ONE_QEMUKVM, VmTraces.GUEST_ONE_QEMUKVM);
+
+    private Set<VmTraces> fTraces = new HashSet<>();
+
+    private VmTestExperiment(VmTraces... traces) {
+        for (VmTraces trace : traces) {
+            fTraces.add(trace);
+        }
+    }
+
+    /**
+     * Return a VirtualMachineExperiment object for this experiment with all its
+     * traces. It will be already initTrace()'ed.
+     *
+     * Make sure you call {@link #exists()} before calling this! This will make
+     * sure all traces in the experiment are available
+     *
+     * After being used by unit tests, the experiment must be properly disposed
+     * of by calling the {@link VirtualMachineExperiment#dispose()} method on
+     * the object returned by this method.
+     *
+     * @param deleteSuppFiles
+     *            Indicate whether to make sure supplementary files are deleted
+     * @return A VirtualMachineExperiment object corresponding to this
+     *         experiment
+     */
+    public synchronized TmfExperiment getExperiment(boolean deleteSuppFiles) {
+        Set<ITmfTrace> traces = new HashSet<>();
+        for (VmTraces trace : fTraces) {
+            traces.add(trace.getTrace());
+        }
+        @SuppressWarnings("null")
+        @NonNull String expName = this.name();
+        VirtualMachineExperiment experiment = new VirtualMachineExperiment(expName, traces);
+        if (deleteSuppFiles) {
+            /*
+             * Delete the supplementary files, so that the next iteration
+             * rebuilds the state system.
+             */
+            File suppDir = new File(TmfTraceManager.getSupplementaryFileDir(experiment));
+            for (File file : suppDir.listFiles()) {
+                file.delete();
+            }
+        }
+        return experiment;
+    }
+
+    /**
+     * Check if all the traces actually exist on disk or not.
+     *
+     * @return If all traces for this experiment are present
+     */
+    public boolean exists() {
+        boolean exists = true;
+        for (VmTraces trace : fTraces) {
+            exists &= trace.exists();
+        }
+        return exists;
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/shared/org/eclipse/tracecompass/lttng2/lttng/kernel/core/tests/shared/vm/VmTraces.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/shared/org/eclipse/tracecompass/lttng2/lttng/kernel/core/tests/shared/vm/VmTraces.java
new file mode 100644 (file)
index 0000000..e464161
--- /dev/null
@@ -0,0 +1,94 @@
+/*******************************************************************************
+ * Copyright (c) 2014 École Polytechnique de Montréal
+ *
+ * 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:
+ *   Geneviève Bastien - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.lttng.kernel.core.tests.shared.vm;
+
+import java.io.File;
+import java.io.IOException;
+import java.net.URL;
+
+import org.eclipse.core.runtime.FileLocator;
+import org.eclipse.core.runtime.IPath;
+import org.eclipse.core.runtime.IStatus;
+import org.eclipse.core.runtime.Path;
+import org.eclipse.jdt.annotation.NonNull;
+import org.eclipse.tracecompass.lttng2.kernel.core.tests.Activator;
+import org.eclipse.tracecompass.tmf.core.event.TmfEvent;
+import org.eclipse.tracecompass.tmf.core.exceptions.TmfTraceException;
+import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace;
+import org.eclipse.tracecompass.tmf.tests.stubs.trace.xml.TmfXmlTraceStub;
+
+/**
+ * List the available virtual machine host and guest traces
+ *
+ * @author Geneviève Bastien
+ */
+public enum VmTraces {
+
+    /** Host from simple QEMU/KVM experiment */
+    HOST_ONE_QEMUKVM("vm/OneQemuKvm/host.xml"),
+    /** Guest from simple QEMU/KVM experiment */
+    GUEST_ONE_QEMUKVM("vm/OneQemuKvm/guest.xml");
+
+    private static final @NonNull String filePath = "testfiles";
+
+    private final IPath fPath;
+
+    VmTraces(String path) {
+        IPath relativePath = new Path(filePath + File.separator + path);
+        Activator plugin = Activator.getDefault();
+        if (plugin == null) {
+            /*
+             * Shouldn't happen but at least throw something to get the test to
+             * fail early
+             */
+            throw new IllegalStateException();
+        }
+        URL location = FileLocator.find(plugin.getBundle(), relativePath, null);
+        try {
+            fPath = new Path(FileLocator.toFileURL(location).getPath());
+        } catch (IOException e) {
+            throw new IllegalStateException();
+        }
+    }
+
+    /**
+     * Return a TmfXmlTraceStub object of this test trace. It will be already
+     * initTrace()'ed.
+     *
+     * Make sure you call {@link #exists()} before calling this!
+     *
+     * @return A TmfXmlTraceStub reference to this trace
+     */
+    public ITmfTrace getTrace() {
+        ITmfTrace trace = new TmfXmlTraceStub();
+        IStatus status = trace.validate(null, fPath.toOSString());
+        if (!status.isOK()) {
+            return null;
+        }
+        try {
+            trace.initTrace(null, fPath.toOSString(), TmfEvent.class);
+        } catch (TmfTraceException e) {
+            return null;
+        }
+        return trace;
+    }
+
+    /**
+     * Check if the trace actually exists on disk or not.
+     *
+     * @return If the trace is present
+     */
+    public boolean exists() {
+        return fPath.toFile().exists();
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/Activator.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/Activator.java
new file mode 100644 (file)
index 0000000..2b12ca1
--- /dev/null
@@ -0,0 +1,106 @@
+/*******************************************************************************
+ * Copyright (c) 2014 École Polytechnique de Montréal
+ *
+ * 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:
+ *   Geneviève Bastien - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.kernel.core.tests;
+
+import java.io.IOException;
+import java.net.URL;
+
+import org.eclipse.core.runtime.FileLocator;
+import org.eclipse.core.runtime.IPath;
+import org.eclipse.core.runtime.Path;
+import org.eclipse.core.runtime.Plugin;
+import org.osgi.framework.BundleContext;
+
+/**
+ * Activator for the lttng2.kernel.core.tests plugin
+ *
+ * @author Geneviève Bastien
+ */
+public class Activator extends Plugin {
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+
+    /**
+     * The plug-in ID
+     */
+    public static final String PLUGIN_ID = "org.eclipse.tracecompass.lttng2.kernel.core.tests"; //$NON-NLS-1$
+
+    /**
+     * The shared instance
+     */
+    private static Activator PLUGIN;
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+
+    /**
+     * The constructor
+     */
+    public Activator() {
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    /**
+     * Returns the shared instance
+     *
+     * @return the shared instance
+     */
+    public static Activator getDefault() {
+        return PLUGIN;
+    }
+
+    // ------------------------------------------------------------------------
+    // Operators
+    // ------------------------------------------------------------------------
+
+    @Override
+    public void start(BundleContext context) throws Exception {
+        super.start(context);
+        PLUGIN = this;
+    }
+
+    @Override
+    public void stop(BundleContext context) throws Exception {
+        PLUGIN = null;
+        super.stop(context);
+    }
+
+    /**
+     * Return a path to a file relative to this plugin's base directory
+     *
+     * @param relativePath
+     *            The path relative to the plugin's root directory
+     * @return The path corresponding to the relative path in parameter
+     */
+    public static IPath getAbsoluteFilePath(String relativePath) {
+        Activator plugin = Activator.getDefault();
+        if (plugin == null) {
+            /*
+             * Shouldn't happen but at least throw something to get the test to
+             * fail early
+             */
+            throw new IllegalStateException();
+        }
+        URL location = FileLocator.find(plugin.getBundle(), new Path(relativePath), null);
+        try {
+            return new Path(FileLocator.toFileURL(location).getPath());
+        } catch (IOException e) {
+            throw new IllegalStateException();
+        }
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/ActivatorTest.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/ActivatorTest.java
new file mode 100644 (file)
index 0000000..12b265c
--- /dev/null
@@ -0,0 +1,96 @@
+/*******************************************************************************
+ * Copyright (c) 2012, 2015 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:
+ *   Francois Chouinard - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.kernel.core.tests;
+
+import junit.framework.TestCase;
+
+import org.junit.After;
+import org.junit.AfterClass;
+import org.junit.Before;
+import org.junit.BeforeClass;
+import org.junit.Test;
+
+/**
+ * <b><u>ActivatorTest</u></b>
+ * <p>
+ * Test suite for the Activator class
+ * <p>
+ */
+@SuppressWarnings("javadoc")
+public class ActivatorTest extends TestCase {
+
+    // ------------------------------------------------------------------------
+    // JUnit
+    // ------------------------------------------------------------------------
+
+    @BeforeClass
+    public static void setUpBeforeClass() {
+    }
+
+    @AfterClass
+    public static void tearDownAfterClass() {
+    }
+
+    /**
+     * @throws java.lang.Exception
+     */
+    @Before
+    @Override
+    public void setUp() throws Exception {
+    }
+
+    /**
+     * @throws java.lang.Exception
+     */
+    @After
+    @Override
+    public void tearDown() throws Exception {
+    }
+
+    // ------------------------------------------------------------------------
+    // Tests
+    // ------------------------------------------------------------------------
+
+    /**
+     * Test method for {@link org.eclipse.tracecompass.lttng2.kernel.core.Activator#Activator()}.
+     */
+    @Test
+    public void testActivator() {
+        assertTrue(true);
+    }
+
+    /**
+     * Test method for {@link org.eclipse.tracecompass.lttng2.kernel.core.Activator#getDefault()}.
+     */
+    @Test
+    public void testGetDefault() {
+        assertTrue(true);
+    }
+
+    /**
+     * Test method for {@link org.eclipse.tracecompass.lttng2.kernel.core.Activator#start(org.osgi.framework.BundleContext)}.
+     */
+    @Test
+    public void testStartBundleContext() {
+        assertTrue(true);
+    }
+
+    /**
+     * Test method for {@link org.eclipse.tracecompass.lttng2.kernel.core.Activator#stop(org.osgi.framework.BundleContext)}.
+     */
+    @Test
+    public void testStopBundleContext() {
+        assertTrue(true);
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/AllTests.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/AllTests.java
new file mode 100644 (file)
index 0000000..2150b4e
--- /dev/null
@@ -0,0 +1,31 @@
+/*******************************************************************************
+ * Copyright (c) 2012, 2015 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:
+ *   Francois Chouinard - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.kernel.core.tests;
+
+import org.eclipse.tracecompass.tmf.core.tests.shared.DebugSuite;
+import org.junit.runner.RunWith;
+
+/**
+ * Runner for the lttng2.kernel unit tests.
+ */
+@RunWith(DebugSuite.class)
+@DebugSuite.SuiteClasses({
+    ActivatorTest.class,
+    org.eclipse.tracecompass.lttng2.kernel.core.tests.analysis.kernel.AllTests.class,
+    org.eclipse.tracecompass.lttng2.kernel.core.tests.analysis.kernel.statesystem.TestAll.class,
+    org.eclipse.tracecompass.lttng2.kernel.core.tests.analysis.vm.AllTests.class,
+    org.eclipse.tracecompass.lttng2.kernel.core.tests.event.matchandsync.AllTests.class
+})
+public class AllTests {
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/AllTests.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/AllTests.java
new file mode 100644 (file)
index 0000000..8db6614
--- /dev/null
@@ -0,0 +1,27 @@
+/*******************************************************************************
+ * Copyright (c) 2014, 2015 École Polytechnique de Montréal
+ *
+ * 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:
+ *   Geneviève Bastien - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.kernel.core.tests.analysis.kernel;
+
+import org.junit.runner.RunWith;
+import org.junit.runners.Suite;
+
+/**
+ * Test suite for org.eclipse.linuxtools.lttng2.kernel.core.analysis package
+ */
+@RunWith(Suite.class)
+@Suite.SuiteClasses({
+    LttngKernelAnalysisTest.class
+})
+public class AllTests {
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/LttngKernelAnalysisTest.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/LttngKernelAnalysisTest.java
new file mode 100644 (file)
index 0000000..6d6a697
--- /dev/null
@@ -0,0 +1,197 @@
+/*******************************************************************************
+ * Copyright (c) 2014, 2015 École Polytechnique de Montréal
+ *
+ * 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:
+ *   Geneviève Bastien - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.kernel.core.tests.analysis.kernel;
+
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertFalse;
+import static org.junit.Assert.assertNotNull;
+import static org.junit.Assert.assertNull;
+import static org.junit.Assert.assertTrue;
+import static org.junit.Assert.fail;
+import static org.junit.Assume.assumeTrue;
+
+import java.util.List;
+import java.util.Set;
+
+import org.eclipse.tracecompass.analysis.os.linux.core.kernelanalysis.KernelAnalysisModule;
+import org.eclipse.tracecompass.lttng2.control.core.session.SessionConfigStrings;
+import org.eclipse.tracecompass.lttng2.kernel.core.trace.LttngKernelTrace;
+import org.eclipse.tracecompass.statesystem.core.ITmfStateSystem;
+import org.eclipse.tracecompass.tmf.core.analysis.TmfAnalysisRequirement;
+import org.eclipse.tracecompass.tmf.core.exceptions.TmfAnalysisException;
+import org.eclipse.tracecompass.tmf.core.exceptions.TmfTraceException;
+import org.eclipse.tracecompass.tmf.core.tests.shared.TmfTestHelper;
+import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace;
+import org.eclipse.tracecompass.tmf.ctf.core.event.CtfTmfEvent;
+import org.eclipse.tracecompass.tmf.ctf.core.tests.shared.CtfTmfTestTrace;
+import org.eclipse.tracecompass.tmf.ctf.core.trace.CtfTmfTrace;
+import org.junit.After;
+import org.junit.Before;
+import org.junit.BeforeClass;
+import org.junit.Ignore;
+import org.junit.Test;
+
+import com.google.common.collect.ImmutableSet;
+
+/**
+ * Test the {@link KernelAnalysisModule} class
+ *
+ * @author Geneviève Bastien
+ */
+public class LttngKernelAnalysisTest {
+
+    private LttngKernelTrace fTrace;
+    private KernelAnalysisModule fKernelAnalysisModule;
+
+    /**
+     * Class setup
+     */
+    @BeforeClass
+    public static void setUpClass() {
+        assumeTrue(CtfTmfTestTrace.KERNEL.exists());
+    }
+
+    /**
+     * Set-up the test
+     */
+    @Before
+    public void setUp() {
+        fKernelAnalysisModule = new KernelAnalysisModule();
+        fTrace = new LttngKernelTrace();
+        try {
+            fTrace.initTrace(null, CtfTmfTestTrace.KERNEL.getPath(), CtfTmfEvent.class);
+        } catch (TmfTraceException e) {
+            /* Should not happen if tracesExist() passed */
+            throw new RuntimeException(e);
+        }
+    }
+
+    /**
+     * Dispose test objects
+     */
+    @After
+    public void tearDown() {
+        fTrace.dispose();
+        fKernelAnalysisModule.dispose();
+        fTrace = null;
+        fKernelAnalysisModule = null;
+    }
+
+    /**
+     * Test the LTTng kernel analysis execution
+     */
+    @Test
+    public void testAnalysisExecution() {
+        fKernelAnalysisModule.setId("test");
+        ITmfTrace trace = fTrace;
+        assertNotNull(trace);
+        try {
+            assertTrue(fKernelAnalysisModule.setTrace(trace));
+        } catch (TmfAnalysisException e) {
+            fail(e.getMessage());
+        }
+        // Assert the state system has not been initialized yet
+        ITmfStateSystem ss = fKernelAnalysisModule.getStateSystem();
+        assertNull(ss);
+
+        assertTrue(TmfTestHelper.executeAnalysis(fKernelAnalysisModule));
+
+        ss = fKernelAnalysisModule.getStateSystem();
+        assertNotNull(ss);
+
+        List<Integer> quarks = ss.getQuarks("*");
+        assertFalse(quarks.isEmpty());
+    }
+
+    /**
+     * Test the canExecute method on valid and invalid traces
+     */
+    @Test
+    public void testCanExecute() {
+        /* Test with a valid kernel trace */
+        assertNotNull(fTrace);
+        assertTrue(fKernelAnalysisModule.canExecute(fTrace));
+
+        /* Test with a CTF trace that does not have required events */
+        assumeTrue(CtfTmfTestTrace.CYG_PROFILE.exists());
+        try (CtfTmfTrace trace = CtfTmfTestTrace.CYG_PROFILE.getTrace();) {
+            /*
+             * TODO: This should be false, but for now there is no mandatory
+             * events in the kernel analysis so it will return true.
+             */
+            assertTrue(fKernelAnalysisModule.canExecute(trace));
+        }
+    }
+
+    /**
+     * Test for {@link KernelAnalysisModule#getAnalysisRequirements()}
+     *
+     * FIXME Ignored for now because the analysis does not provide any
+     * requirements (it doesn't look for particular event names anymore).
+     */
+    @Test
+    @Ignore
+    public void testGetAnalysisRequirements() {
+        Iterable<TmfAnalysisRequirement> requirements = fKernelAnalysisModule.getAnalysisRequirements();
+        assertNotNull(requirements);
+
+        /* There should be the event and domain type */
+        TmfAnalysisRequirement eventReq = null;
+        TmfAnalysisRequirement domainReq = null;
+        int numberOfRequirement = 0;
+        for (TmfAnalysisRequirement requirement : requirements) {
+            ++numberOfRequirement;
+            if (requirement.getType().equals(SessionConfigStrings.CONFIG_ELEMENT_EVENT)) {
+                eventReq = requirement;
+            } else if (requirement.getType().equals(SessionConfigStrings.CONFIG_ELEMENT_DOMAIN)) {
+                domainReq = requirement;
+            }
+        }
+        assertNotNull(eventReq);
+        assertNotNull(domainReq);
+
+        /* There should be two requirements */
+        assertEquals(2, numberOfRequirement);
+
+        /* Verify the content of the requirements themselves */
+        /* Domain should be kernel */
+        assertEquals(1, domainReq.getValues().size());
+        for (String domain : domainReq.getValues()) {
+            assertEquals(SessionConfigStrings.CONFIG_DOMAIN_TYPE_KERNEL, domain);
+        }
+
+        /* Events */
+        Set<String> expectedEvents = ImmutableSet.of(
+//                LttngStrings.EXIT_SYSCALL,
+//                LttngStrings.IRQ_HANDLER_ENTRY,
+//                LttngStrings.IRQ_HANDLER_EXIT,
+//                LttngStrings.SOFTIRQ_ENTRY,
+//                LttngStrings.SOFTIRQ_EXIT,
+//                LttngStrings.SOFTIRQ_RAISE,
+//                LttngStrings.SCHED_SWITCH,
+//                LttngStrings.SCHED_PROCESS_FORK,
+//                LttngStrings.SCHED_PROCESS_EXIT,
+//                LttngStrings.SCHED_PROCESS_FREE,
+//                LttngStrings.STATEDUMP_PROCESS_STATE,
+//                LttngStrings.SCHED_WAKEUP,
+//                LttngStrings.SCHED_WAKEUP_NEW,
+//                /* Add the prefix for syscalls */
+//                LttngStrings.SYSCALL_PREFIX
+                );
+
+        assertEquals(0, eventReq.getValues().size());
+        for (String event : eventReq.getValues()) {
+            assertTrue("Unexpected event " + event, expectedEvents.contains(event));
+        }
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/statesystem/GenerateTestValues.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/statesystem/GenerateTestValues.java
new file mode 100644 (file)
index 0000000..a63ca7f
--- /dev/null
@@ -0,0 +1,140 @@
+/*******************************************************************************
+ * Copyright (c) 2013, 2015 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:
+ *   Alexandre Montplaisir - Initial API and implementation
+ ******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.kernel.core.tests.analysis.kernel.statesystem;
+
+import java.io.File;
+import java.io.FileWriter;
+import java.io.PrintWriter;
+import java.util.List;
+
+import org.eclipse.tracecompass.analysis.os.linux.core.kernelanalysis.KernelAnalysisModule;
+import org.eclipse.tracecompass.statesystem.core.ITmfStateSystem;
+import org.eclipse.tracecompass.statesystem.core.interval.ITmfStateInterval;
+import org.eclipse.tracecompass.statesystem.core.statevalue.ITmfStateValue;
+import org.eclipse.tracecompass.tmf.core.statesystem.TmfStateSystemAnalysisModule;
+import org.eclipse.tracecompass.tmf.ctf.core.tests.shared.CtfTmfTestTrace;
+import org.eclipse.tracecompass.tmf.ctf.core.trace.CtfTmfTrace;
+
+/**
+ * Small program to regenerate the values used in "TestValues.java" from the
+ * current LTTng-kernel state provider.
+ *
+ * It will write its output the a file called 'TestValues<something>.java' in your
+ * temporary files directory.
+ *
+ * @author Alexandre Montplaisir
+ */
+public class GenerateTestValues {
+
+    private static CtfTmfTestTrace testTrace = CtfTmfTestTrace.TRACE2;
+    private static final long targetTimestamp = 18670067372290L + 1331649577946812237L;
+    private static final String INDENT = "    ";
+
+    /**
+     * Run the program
+     *
+     * @param args
+     *            Command-line arguments, unused.
+     * @throws Exception
+     *             I'm messing with Exception. Come at me bro!
+     */
+    public static void main(String[] args) throws Exception {
+        if (!testTrace.exists()) {
+            System.err.println("Trace files not present.");
+            return;
+        }
+
+        /* Prepare the files */
+        File logFile = File.createTempFile("TestValues", ".java");
+        try (final CtfTmfTrace trace = testTrace.getTrace();
+                PrintWriter writer = new PrintWriter(new FileWriter(logFile), true);) {
+
+            /* Build and query the state system */
+            TmfStateSystemAnalysisModule module = new KernelAnalysisModule() {
+                @Override
+                protected String getSsFileName() {
+                    return "test-values";
+                }
+            };
+
+            if (!module.setTrace(trace)) {
+                throw new IllegalStateException();
+            }
+            module.setId("test-values");
+            module.schedule();
+            module.waitForCompletion();
+            ITmfStateSystem ssq = module.getStateSystem();
+            if (ssq == null) {
+                throw new IllegalStateException();
+            }
+
+            List<ITmfStateInterval> fullState = ssq.queryFullState(targetTimestamp);
+
+            /* Start printing the java file's contents */
+            writer.println("interface TestValues {");
+            writer.println();
+            writer.println(INDENT + "int size = " + fullState.size() + ";");
+            writer.println();
+
+            /* Print the array contents */
+            writer.println(INDENT + "long[] startTimes = {");
+            for (ITmfStateInterval interval : fullState) {
+                writer.println(INDENT + INDENT + String.valueOf(interval.getStartTime()) + "L,");
+            }
+            writer.println(INDENT + "};");
+            writer.println();
+
+            writer.println(INDENT + "long[] endTimes = {");
+            for (ITmfStateInterval interval : fullState) {
+                writer.println(INDENT + INDENT + String.valueOf(interval.getEndTime()) + "L,");
+            }
+            writer.println(INDENT + "};");
+            writer.println();
+
+            writer.println(INDENT + "ITmfStateValue[] values = {");
+            for (ITmfStateInterval interval : fullState) {
+                ITmfStateValue val = interval.getStateValue();
+                writer.print(INDENT + INDENT);
+
+                switch (val.getType()) {
+                case NULL:
+                    writer.println("TmfStateValue.nullValue(),");
+                    break;
+                case INTEGER:
+                    writer.println("TmfStateValue.newValueInt(" + val.unboxInt() + "),");
+                    break;
+                case LONG:
+                    writer.println("TmfStateValue.newValueLong(" + val.unboxLong() + "),");
+                    break;
+                case DOUBLE:
+                    writer.println("TmfStateValue.newValueDouble(" + val.unboxDouble() + "),");
+                    break;
+                case STRING:
+                    writer.println("TmfStateValue.newValueString(\"" + val.unboxStr() + "\"),");
+                    break;
+                default:
+                    writer.println(val.toString());
+                    break;
+                }
+            }
+            writer.println(INDENT + "};");
+
+            writer.println("}");
+            writer.println();
+
+            module.dispose();
+        }
+        System.exit(0);
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/statesystem/PartialStateSystemTest.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/statesystem/PartialStateSystemTest.java
new file mode 100644 (file)
index 0000000..7dfbae8
--- /dev/null
@@ -0,0 +1,189 @@
+/*******************************************************************************
+ * Copyright (c) 2013, 2015 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:
+ *   Alexandre Montplaisir - Initial API and implementation
+ *   Bernd Hufmann - Use state system analysis module instead of factory
+ ******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.kernel.core.tests.analysis.kernel.statesystem;
+
+import static org.junit.Assert.assertTrue;
+import static org.junit.Assert.fail;
+
+import java.io.File;
+
+import org.eclipse.jdt.annotation.NonNull;
+import org.eclipse.jdt.annotation.NonNullByDefault;
+import org.eclipse.jdt.annotation.Nullable;
+import org.eclipse.tracecompass.analysis.os.linux.core.kernelanalysis.KernelAnalysisModule;
+import org.eclipse.tracecompass.statesystem.core.exceptions.TimeRangeException;
+import org.eclipse.tracecompass.tmf.core.exceptions.TmfAnalysisException;
+import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace;
+import org.eclipse.tracecompass.tmf.core.trace.TmfTraceManager;
+import org.eclipse.tracecompass.tmf.ctf.core.trace.CtfTmfTrace;
+import org.junit.AfterClass;
+import org.junit.BeforeClass;
+import org.junit.Ignore;
+import org.junit.Test;
+
+/**
+ * State system tests using a partial history.
+ *
+ * @author Alexandre Montplaisir
+ */
+@Ignore
+public class PartialStateSystemTest extends StateSystemTest {
+
+    private static final @NonNull String TEST_FILE_NAME = "test-partial";
+
+    private static File stateFile;
+    private static TestLttngKernelAnalysisModule module;
+
+    /**
+     * Test class setup
+     */
+    @BeforeClass
+    public static void initialize() {
+        if (!testTrace.exists()) {
+            traceIsPresent = false;
+            return;
+        }
+        traceIsPresent = true;
+
+        stateFile = new File(TmfTraceManager.getSupplementaryFileDir(testTrace.getTrace()) + TEST_FILE_NAME);
+        if (stateFile.exists()) {
+            stateFile.delete();
+        }
+
+        module = new TestLttngKernelAnalysisModule(TEST_FILE_NAME);
+        try {
+            assertTrue(module.setTrace(testTrace.getTrace()));
+        } catch (TmfAnalysisException e) {
+            fail();
+        }
+        module.schedule();
+        assertTrue(module.waitForCompletion());
+
+        fixture = module.getStateSystem();
+    }
+
+    /**
+     * Class clean-up
+     */
+    @AfterClass
+    public static void cleanup() {
+        if (module != null) {
+            module.dispose();
+        }
+        if (stateFile != null) {
+            stateFile.delete();
+        }
+        if (fixture != null) {
+            fixture.dispose();
+        }
+        module = null;
+        fixture = null;
+    }
+
+    /**
+     * Partial histories cannot get the intervals' end times. The fake value that
+     * is returned is equal to the query's timestamp. So override this here
+     * so that {@link #testFullQueryThorough} keeps working.
+     */
+    @Override
+    protected long getEndTimes(int idx) {
+        return interestingTimestamp1;
+    }
+
+    // ------------------------------------------------------------------------
+    // Skip tests using single-queries (unsupported in partial history)
+    // ------------------------------------------------------------------------
+
+    @Override
+    @Test(expected = UnsupportedOperationException.class)
+    public void testSingleQuery1() {
+        super.testSingleQuery1();
+    }
+
+    @Override
+    @Test(expected = UnsupportedOperationException.class)
+    public void testRangeQuery1() {
+        super.testRangeQuery1();
+    }
+
+    @Override
+    @Test(expected = UnsupportedOperationException.class)
+    public void testRangeQuery2() {
+        super.testRangeQuery2();
+    }
+
+    @Override
+    @Test(expected = UnsupportedOperationException.class)
+    public void testRangeQuery3() {
+        super.testRangeQuery3();
+    }
+
+    @Override
+    @Test(expected = UnsupportedOperationException.class)
+    public void testSingleQueryInvalidTime1() throws TimeRangeException {
+        super.testSingleQueryInvalidTime1();
+    }
+
+    @Override
+    @Test(expected = UnsupportedOperationException.class)
+    public void testSingleQueryInvalidTime2() throws TimeRangeException {
+        super.testSingleQueryInvalidTime2();
+    }
+
+    @Override
+    @Test(expected = UnsupportedOperationException.class)
+    public void testRangeQueryInvalidTime1() throws TimeRangeException {
+        super.testRangeQueryInvalidTime1();
+    }
+
+    @Override
+    @Test(expected = UnsupportedOperationException.class)
+    public void testRangeQueryInvalidTime2() throws TimeRangeException {
+        super.testRangeQueryInvalidTime2();
+    }
+
+    @NonNullByDefault
+    private static class TestLttngKernelAnalysisModule extends KernelAnalysisModule {
+
+        private final String htFileName;
+
+        /**
+         * Constructor adding the views to the analysis
+         * @param htFileName
+         *      The History File Name
+         */
+        public TestLttngKernelAnalysisModule(String htFileName) {
+            super();
+            this.htFileName = htFileName;
+        }
+
+        @Override
+        public boolean setTrace(@Nullable ITmfTrace trace) throws TmfAnalysisException {
+            if (!(trace instanceof CtfTmfTrace)) {
+                return false;
+            }
+            return super.setTrace(trace);
+        }
+
+        @Override
+        protected StateSystemBackendType getBackendType() {
+            return StateSystemBackendType.PARTIAL;
+        }
+
+        @Override
+        protected String getSsFileName() {
+            return htFileName;
+        }
+
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/statesystem/StateSystemFullHistoryTest.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/statesystem/StateSystemFullHistoryTest.java
new file mode 100644 (file)
index 0000000..ad4f25c
--- /dev/null
@@ -0,0 +1,192 @@
+/*******************************************************************************
+ * Copyright (c) 2012, 2015 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:
+ *   Alexandre Montplaisir - Initial API and implementation
+ *   Bernd Hufmann - Use state system analysis module instead of factory
+ ******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.kernel.core.tests.analysis.kernel.statesystem;
+
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertNotNull;
+import static org.junit.Assert.assertTrue;
+import static org.junit.Assert.fail;
+
+import java.io.File;
+
+import org.eclipse.jdt.annotation.NonNull;
+import org.eclipse.jdt.annotation.NonNullByDefault;
+import org.eclipse.jdt.annotation.Nullable;
+import org.eclipse.tracecompass.analysis.os.linux.core.kernelanalysis.KernelAnalysisModule;
+import org.eclipse.tracecompass.statesystem.core.ITmfStateSystem;
+import org.eclipse.tracecompass.tmf.core.exceptions.TmfAnalysisException;
+import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace;
+import org.eclipse.tracecompass.tmf.core.trace.TmfTraceManager;
+import org.eclipse.tracecompass.tmf.ctf.core.trace.CtfTmfTrace;
+import org.junit.AfterClass;
+import org.junit.BeforeClass;
+import org.junit.Test;
+
+/**
+ * State system tests using a full history back-end and the LTTng kernel state
+ * input.
+ *
+ * @author Alexandre Montplaisir
+ */
+public class StateSystemFullHistoryTest extends StateSystemTest {
+
+    private static final @NonNull String TEST_FILE_NAME = "test.ht";
+    private static final @NonNull String BENCHMARK_FILE_NAME = "test.benchmark.ht";
+
+    private static File stateFile;
+    private static File stateFileBenchmark;
+    private static TestLttngKernelAnalysisModule module;
+
+    /**
+     * Test class setup
+     */
+    @BeforeClass
+    public static void initialize() {
+        if (!testTrace.exists()) {
+            traceIsPresent = false;
+            return;
+        }
+        traceIsPresent = true;
+
+        stateFile = createStateFile(TEST_FILE_NAME);
+        stateFileBenchmark = createStateFile(BENCHMARK_FILE_NAME);
+
+        module = new TestLttngKernelAnalysisModule(TEST_FILE_NAME);
+        try {
+            assertTrue(module.setTrace(testTrace.getTrace()));
+        } catch (TmfAnalysisException e) {
+            fail();
+        }
+        module.schedule();
+        assertTrue(module.waitForCompletion());
+
+        fixture = module.getStateSystem();
+    }
+
+    /**
+     * Clean-up
+     */
+    @AfterClass
+    public static void cleanup() {
+        if (module != null) {
+            module.dispose();
+        }
+        if (stateFile != null) {
+            stateFile.delete();
+        }
+        if (stateFileBenchmark != null) {
+            stateFileBenchmark.delete();
+        }
+        if (fixture != null) {
+            fixture.dispose();
+        }
+        module = null;
+        fixture = null;
+    }
+
+    // ------------------------------------------------------------------------
+    // Tests specific to a full-history
+    // ------------------------------------------------------------------------
+
+    /**
+     * Rebuild independently so we can benchmark it. Too bad JUnit doesn't allow
+     * us to @Test the @BeforeClass...
+     */
+    @Test
+    public void testBuild() {
+        TestLttngKernelAnalysisModule module2 = new TestLttngKernelAnalysisModule(BENCHMARK_FILE_NAME);
+        try {
+            assertTrue(module2.setTrace(testTrace.getTrace()));
+        } catch (TmfAnalysisException e) {
+            module2.dispose();
+            fail();
+        }
+        module2.schedule();
+        assertTrue(module2.waitForCompletion());
+        ITmfStateSystem ssb2 = module2.getStateSystem();
+
+        assertNotNull(ssb2);
+        assertEquals(startTime, ssb2.getStartTime());
+        assertEquals(endTime, ssb2.getCurrentEndTime());
+
+        module2.dispose();
+    }
+
+    /**
+     * Test re-opening the existing file.
+     */
+    @Test
+    public void testOpenExistingStateFile() {
+        /* 'newStateFile' should have already been created */
+        TestLttngKernelAnalysisModule module2 = new TestLttngKernelAnalysisModule(TEST_FILE_NAME);
+        try {
+            assertTrue(module2.setTrace(testTrace.getTrace()));
+        } catch (TmfAnalysisException e) {
+            module2.dispose();
+            fail();
+        }
+        module2.schedule();
+        assertTrue(module2.waitForCompletion());
+        ITmfStateSystem ssb2 = module2.getStateSystem();
+
+        assertNotNull(ssb2);
+        assertEquals(startTime, ssb2.getStartTime());
+        assertEquals(endTime, ssb2.getCurrentEndTime());
+
+        module2.dispose();
+    }
+
+    @NonNullByDefault
+    private static class TestLttngKernelAnalysisModule extends KernelAnalysisModule {
+
+        private final String htFileName;
+
+        /**
+         * Constructor adding the views to the analysis
+         * @param htFileName
+         *      The History File Name
+         */
+        public TestLttngKernelAnalysisModule(String htFileName) {
+            super();
+            this.htFileName = htFileName;
+        }
+
+        @Override
+        public boolean setTrace(@Nullable ITmfTrace trace) throws TmfAnalysisException {
+            if (!(trace instanceof CtfTmfTrace)) {
+                return false;
+            }
+            return super.setTrace(trace);
+        }
+
+        @Override
+        protected StateSystemBackendType getBackendType() {
+            return StateSystemBackendType.FULL;
+        }
+
+        @Override
+        protected String getSsFileName() {
+            return htFileName;
+        }
+    }
+
+    private static File createStateFile(String name) {
+        File file = new File(TmfTraceManager.getSupplementaryFileDir(testTrace.getTrace()) + name);
+        if (file.exists()) {
+            file.delete();
+        }
+        return file;
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/statesystem/StateSystemInMemoryTest.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/statesystem/StateSystemInMemoryTest.java
new file mode 100644 (file)
index 0000000..1840a7a
--- /dev/null
@@ -0,0 +1,95 @@
+/*******************************************************************************
+ * Copyright (c) 2013, 2015 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:
+ *   Alexandre Montplaisir - Initial API and implementation
+ *   Bernd Hufmann - Use state system analysis module instead of factory
+ ******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.kernel.core.tests.analysis.kernel.statesystem;
+
+import static org.junit.Assert.assertTrue;
+import static org.junit.Assert.fail;
+
+import org.eclipse.tracecompass.analysis.os.linux.core.kernelanalysis.KernelAnalysisModule;
+import org.eclipse.tracecompass.tmf.core.exceptions.TmfAnalysisException;
+import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace;
+import org.eclipse.tracecompass.tmf.ctf.core.trace.CtfTmfTrace;
+import org.junit.AfterClass;
+import org.junit.BeforeClass;
+
+/**
+ * State system tests using the in-memory back-end.
+ *
+ * @author Alexandre Montplaisir
+ */
+public class StateSystemInMemoryTest extends StateSystemTest {
+
+    private static TestLttngKernelAnalysisModule module;
+
+    /**
+     * Test class setup
+     */
+    @BeforeClass
+    public static void initialize() {
+        if (!testTrace.exists()) {
+            traceIsPresent = false;
+            return;
+        }
+        traceIsPresent = true;
+
+        module = new TestLttngKernelAnalysisModule();
+        try {
+            assertTrue(module.setTrace(testTrace.getTrace()));
+        } catch (TmfAnalysisException e) {
+            fail();
+        }
+        module.schedule();
+        assertTrue(module.waitForCompletion());
+
+        fixture = module.getStateSystem();
+    }
+
+    /**
+     * Class cleanup
+     */
+    @AfterClass
+    public static void cleanup() {
+        if (module != null) {
+            module.dispose();
+        }
+        if (fixture != null) {
+            fixture.dispose();
+        }
+        module = null;
+        fixture = null;
+    }
+
+    private static class TestLttngKernelAnalysisModule extends KernelAnalysisModule {
+
+        /**
+         * Constructor adding the views to the analysis
+         */
+        public TestLttngKernelAnalysisModule() {
+            super();
+        }
+
+        @Override
+        public boolean setTrace(ITmfTrace trace) throws TmfAnalysisException {
+            if (!(trace instanceof CtfTmfTrace)) {
+                return false;
+            }
+            return super.setTrace(trace);
+        }
+
+        @Override
+        protected StateSystemBackendType getBackendType() {
+            return StateSystemBackendType.INMEM;
+        }
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/statesystem/StateSystemTest.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/statesystem/StateSystemTest.java
new file mode 100644 (file)
index 0000000..a66b2a0
--- /dev/null
@@ -0,0 +1,436 @@
+/*******************************************************************************
+ * Copyright (c) 2012, 2015 Ericsson
+ * Copyright (c) 2010, 2011 École Polytechnique de Montréal
+ * Copyright (c) 2010, 2011 Alexandre Montplaisir <alexandre.montplaisir@gmail.com>
+ *
+ * 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
+ *
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.kernel.core.tests.analysis.kernel.statesystem;
+
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertNotNull;
+import static org.junit.Assert.fail;
+import static org.junit.Assume.assumeTrue;
+
+import java.util.List;
+
+import org.eclipse.tracecompass.analysis.os.linux.core.kernelanalysis.Attributes;
+import org.eclipse.tracecompass.statesystem.core.ITmfStateSystem;
+import org.eclipse.tracecompass.statesystem.core.StateSystemUtils;
+import org.eclipse.tracecompass.statesystem.core.exceptions.AttributeNotFoundException;
+import org.eclipse.tracecompass.statesystem.core.exceptions.StateSystemDisposedException;
+import org.eclipse.tracecompass.statesystem.core.exceptions.StateValueTypeException;
+import org.eclipse.tracecompass.statesystem.core.exceptions.TimeRangeException;
+import org.eclipse.tracecompass.statesystem.core.interval.ITmfStateInterval;
+import org.eclipse.tracecompass.statesystem.core.statevalue.ITmfStateValue;
+import org.eclipse.tracecompass.tmf.ctf.core.tests.shared.CtfTmfTestTrace;
+import org.junit.Before;
+import org.junit.Rule;
+import org.junit.Test;
+import org.junit.rules.TestRule;
+import org.junit.rules.Timeout;
+
+/**
+ * Base unit tests for the StateHistorySystem. Extension can be made to test
+ * different state back-end types or configurations.
+ *
+ * @author Alexandre Montplaisir
+ */
+@SuppressWarnings("javadoc")
+public abstract class StateSystemTest {
+
+    /** Timeout the tests after 2 minutes */
+    @Rule
+    public TestRule timeoutRule = new Timeout(120000);
+
+    /** Test trace used for these tests */
+    protected static final CtfTmfTestTrace testTrace = CtfTmfTestTrace.TRACE2;
+
+    /** Expected start time of the test trace/state history */
+    protected static final long startTime = 1331668247314038062L;
+
+    /** Expected end time of the state history built from the test trace */
+    protected static final long endTime = 1331668259054285979L;
+
+    /** Offset in the trace + start time of the trace */
+    protected static final long interestingTimestamp1 = 18670067372290L + 1331649577946812237L;
+
+    /** Number of nanoseconds in one second */
+    private static final long NANOSECS_PER_SEC = 1000000000L;
+
+    protected static ITmfStateSystem fixture;
+    protected static boolean traceIsPresent = false;
+
+    /**
+     * Test set-up
+     */
+    @Before
+    public void setUp() {
+        assumeTrue(traceIsPresent);
+        /* Subclasses should set-up 'fixture' */
+        assertNotNull(fixture);
+    }
+
+    @Test
+    public void testFullQuery1() {
+        List<ITmfStateInterval> list;
+        ITmfStateInterval interval;
+        int quark, valueInt;
+        String valueStr;
+
+        try {
+            list = fixture.queryFullState(interestingTimestamp1);
+
+            quark = fixture.getQuarkAbsolute(Attributes.CPUS, "0", Attributes.CURRENT_THREAD);
+            interval = list.get(quark);
+            valueInt = interval.getStateValue().unboxInt();
+            assertEquals(1397, valueInt);
+
+            quark = fixture.getQuarkAbsolute(Attributes.THREADS, "1432", Attributes.EXEC_NAME);
+            interval = list.get(quark);
+            valueStr = interval.getStateValue().unboxStr();
+            assertEquals("gdbus", valueStr);
+
+            quark = fixture.getQuarkAbsolute(Attributes.THREADS, "1432", Attributes.SYSTEM_CALL);
+            interval = list.get(quark);
+            valueStr = interval.getStateValue().unboxStr();
+            assertEquals("sys_poll", valueStr);
+
+        } catch (AttributeNotFoundException | StateSystemDisposedException e) {
+            fail();
+        }
+    }
+
+    @Test
+    public void testSingleQuery1() {
+        long timestamp = interestingTimestamp1;
+        int quark;
+        ITmfStateInterval interval;
+        String valueStr;
+
+        try {
+            quark = fixture.getQuarkAbsolute(Attributes.THREADS, "1432", Attributes.EXEC_NAME);
+            interval = fixture.querySingleState(timestamp, quark);
+            valueStr = interval.getStateValue().unboxStr();
+            assertEquals("gdbus", valueStr);
+
+        } catch (AttributeNotFoundException | StateSystemDisposedException e) {
+            fail();
+        }
+    }
+
+    /**
+     * Test a range query (with no resolution parameter, so all intervals)
+     */
+    @Test
+    public void testRangeQuery1() {
+        long time1 = interestingTimestamp1;
+        long time2 = time1 + 1L * NANOSECS_PER_SEC;
+        int quark;
+        List<ITmfStateInterval> intervals;
+
+        final ITmfStateSystem ss = fixture;
+        assertNotNull(ss);
+
+        try {
+            quark = ss.getQuarkAbsolute(Attributes.CPUS, "0", Attributes.CURRENT_THREAD);
+            intervals = StateSystemUtils.queryHistoryRange(ss, quark, time1, time2);
+            assertEquals(487, intervals.size()); /* Number of context switches! */
+            assertEquals(1685, intervals.get(100).getStateValue().unboxInt());
+            assertEquals(1331668248427681372L, intervals.get(205).getEndTime());
+
+        } catch (AttributeNotFoundException | StateSystemDisposedException e) {
+            fail();
+        }
+    }
+
+    /**
+     * Range query, but with a t2 far off the end of the trace. The result
+     * should still be valid.
+     */
+    @Test
+    public void testRangeQuery2() {
+        List<ITmfStateInterval> intervals;
+
+        final ITmfStateSystem ss = fixture;
+        assertNotNull(ss);
+
+        try {
+            int quark = ss.getQuarkAbsolute(Attributes.RESOURCES, Attributes.IRQS, "1");
+            long ts1 = ss.getStartTime(); /* start of the trace */
+            long ts2 = startTime + 20L * NANOSECS_PER_SEC; /* invalid, but ignored */
+
+            intervals = StateSystemUtils.queryHistoryRange(ss, quark, ts1, ts2);
+
+            /* Activity of IRQ 1 over the whole trace */
+            assertEquals(65, intervals.size());
+
+        } catch (AttributeNotFoundException | StateSystemDisposedException e) {
+            fail();
+        }
+    }
+
+    /**
+     * Test a range query with a resolution
+     */
+    @Test
+    public void testRangeQuery3() {
+        long time1 = interestingTimestamp1;
+        long time2 = time1 + 1L * NANOSECS_PER_SEC;
+        long resolution = 1000000; /* One query every millisecond */
+        int quark;
+        List<ITmfStateInterval> intervals;
+
+        final ITmfStateSystem ss = fixture;
+        assertNotNull(ss);
+
+        try {
+            quark = ss.getQuarkAbsolute(Attributes.CPUS, "0", Attributes.CURRENT_THREAD);
+            intervals = StateSystemUtils.queryHistoryRange(ss, quark, time1, time2, resolution, null);
+            assertEquals(126, intervals.size()); /* Number of context switches! */
+            assertEquals(1452, intervals.get(50).getStateValue().unboxInt());
+            assertEquals(1331668248815698779L, intervals.get(100).getEndTime());
+
+        } catch (AttributeNotFoundException | StateSystemDisposedException e) {
+            fail();
+        }
+    }
+
+    /**
+     * Ask for a time range outside of the trace's range
+     */
+    @Test(expected = TimeRangeException.class)
+    public void testFullQueryInvalidTime1() throws TimeRangeException,
+            StateSystemDisposedException {
+        long ts = startTime + 20L * NANOSECS_PER_SEC;
+        fixture.queryFullState(ts);
+    }
+
+    @Test(expected = TimeRangeException.class)
+    public void testFullQueryInvalidTime2() throws TimeRangeException,
+            StateSystemDisposedException {
+        long ts = startTime - 20L * NANOSECS_PER_SEC;
+        fixture.queryFullState(ts);
+    }
+
+    @Test(expected = TimeRangeException.class)
+    public void testSingleQueryInvalidTime1() throws TimeRangeException {
+        try {
+            int quark = fixture.getQuarkAbsolute(Attributes.CPUS, "0", Attributes.CURRENT_THREAD);
+            long ts = startTime + 20L * NANOSECS_PER_SEC;
+            fixture.querySingleState(ts, quark);
+
+        } catch (AttributeNotFoundException | StateSystemDisposedException e) {
+            fail();
+        }
+    }
+
+    @Test(expected = TimeRangeException.class)
+    public void testSingleQueryInvalidTime2() throws TimeRangeException {
+        try {
+            int quark = fixture.getQuarkAbsolute(Attributes.CPUS, "0", Attributes.CURRENT_THREAD);
+            long ts = startTime - 20L * NANOSECS_PER_SEC;
+            fixture.querySingleState(ts, quark);
+
+        } catch (AttributeNotFoundException | StateSystemDisposedException e) {
+            fail();
+        }
+    }
+
+    @Test(expected = TimeRangeException.class)
+    public void testRangeQueryInvalidTime1() throws TimeRangeException {
+        final ITmfStateSystem ss = fixture;
+        assertNotNull(ss);
+
+        try {
+            int quark = ss.getQuarkAbsolute(Attributes.CPUS, "0", Attributes.CURRENT_THREAD);
+            long ts1 = startTime - 20L * NANOSECS_PER_SEC; /* invalid */
+            long ts2 = startTime + 1L * NANOSECS_PER_SEC; /* valid */
+            StateSystemUtils.queryHistoryRange(ss, quark, ts1, ts2);
+
+        } catch (AttributeNotFoundException e) {
+            fail();
+        } catch (StateSystemDisposedException e) {
+            fail();
+        }
+    }
+
+    @Test(expected = TimeRangeException.class)
+    public void testRangeQueryInvalidTime2() throws TimeRangeException {
+        final ITmfStateSystem ss = fixture;
+        assertNotNull(ss);
+
+        try {
+            int quark = ss.getQuarkAbsolute(Attributes.CPUS, "0", Attributes.CURRENT_THREAD);
+            long ts1 = startTime - 1L * NANOSECS_PER_SEC; /* invalid */
+            long ts2 = startTime + 20L * NANOSECS_PER_SEC; /* invalid */
+            StateSystemUtils.queryHistoryRange(ss, quark, ts1, ts2);
+
+        } catch (AttributeNotFoundException | StateSystemDisposedException e) {
+            fail();
+        }
+    }
+
+    /**
+     * Ask for a non-existing attribute
+     *
+     * @throws AttributeNotFoundException
+     */
+    @Test(expected = AttributeNotFoundException.class)
+    public void testQueryInvalidAttribute() throws AttributeNotFoundException {
+        fixture.getQuarkAbsolute("There", "is", "no", "cow", "level");
+    }
+
+    /**
+     * Query but with the wrong State Value type
+     */
+    @Test(expected = StateValueTypeException.class)
+    public void testQueryInvalidValuetype1() throws StateValueTypeException {
+        List<ITmfStateInterval> list;
+        ITmfStateInterval interval;
+        int quark;
+
+        try {
+            list = fixture.queryFullState(interestingTimestamp1);
+            quark = fixture.getQuarkAbsolute(Attributes.CPUS, "0", Attributes.CURRENT_THREAD);
+            interval = list.get(quark);
+
+            /* This is supposed to be an int value */
+            interval.getStateValue().unboxStr();
+
+        } catch (AttributeNotFoundException | StateSystemDisposedException e) {
+            fail();
+        }
+    }
+
+    @Test(expected = StateValueTypeException.class)
+    public void testQueryInvalidValuetype2() throws StateValueTypeException {
+        List<ITmfStateInterval> list;
+        ITmfStateInterval interval;
+        int quark;
+
+        try {
+            list = fixture.queryFullState(interestingTimestamp1);
+            quark = fixture.getQuarkAbsolute(Attributes.THREADS, "1432", Attributes.EXEC_NAME);
+            interval = list.get(quark);
+
+            /* This is supposed to be a String value */
+            interval.getStateValue().unboxInt();
+
+        } catch (AttributeNotFoundException | StateSystemDisposedException e) {
+            fail();
+        }
+    }
+
+    @Test
+    public void testFullAttributeName() {
+        try {
+            int quark = fixture.getQuarkAbsolute(Attributes.CPUS, "0", Attributes.CURRENT_THREAD);
+            String name = fixture.getFullAttributePath(quark);
+            assertEquals(name, "CPUs/0/Current_thread");
+
+        } catch (AttributeNotFoundException e) {
+            fail();
+        }
+    }
+
+    @Test
+    public void testGetQuarks_begin() {
+        List<Integer> list = fixture.getQuarks("*", "1577", Attributes.EXEC_NAME);
+
+        assertEquals(1, list.size());
+    }
+
+    @Test
+    public void testGetQuarks_middle() {
+        List<Integer> list = fixture.getQuarks(Attributes.THREADS, "*", Attributes.EXEC_NAME);
+
+        /* Number of different kernel threads in the trace */
+        assertEquals(168, list.size());
+    }
+
+    @Test
+    public void testGetQuarks_end() {
+        List<Integer> list = fixture.getQuarks(Attributes.THREADS, "1577", "*");
+
+        /* There should be 5 sub-attributes for each Thread node */
+        assertEquals(5, list.size());
+    }
+
+    // ------------------------------------------------------------------------
+    // Tests verifying the *complete* results of a full queries
+    // ------------------------------------------------------------------------
+
+    protected long getStartTimes(int idx) {
+        return TestValues.startTimes[idx];
+    }
+
+    protected long getEndTimes(int idx) {
+        return TestValues.endTimes[idx];
+    }
+
+    protected ITmfStateValue getStateValues(int idx) {
+        return TestValues.values[idx];
+    }
+
+    @Test
+    public void testFullQueryThorough() {
+        try {
+            List<ITmfStateInterval> state = fixture.queryFullState(interestingTimestamp1);
+            assertEquals(TestValues.size, state.size());
+
+            for (int i = 0; i < state.size(); i++) {
+                /* Test each component of the intervals */
+                assertEquals(getStartTimes(i), state.get(i).getStartTime());
+                assertEquals(getEndTimes(i), state.get(i).getEndTime());
+                assertEquals(i, state.get(i).getAttribute());
+                assertEquals(getStateValues(i), state.get(i).getStateValue());
+            }
+
+        } catch (StateSystemDisposedException e) {
+            fail();
+        }
+    }
+
+    @Test
+    public void testFirstIntervalIsConsidered() {
+        try {
+            int quark = fixture.getQuarkAbsolute(Attributes.THREADS, "1397", Attributes.STATUS);
+            List<ITmfStateInterval> list = fixture.queryFullState(1331668248014135800L);
+            ITmfStateInterval interval = list.get(quark);
+            assertEquals(1331668247516664825L, interval.getStartTime());
+
+            int valueInt = interval.getStateValue().unboxInt();
+            assertEquals(1, valueInt);
+
+        } catch (StateSystemDisposedException | AttributeNotFoundException e) {
+            fail();
+        }
+    }
+
+    @Test
+    public void testParentAttribute() {
+        String[] path = { "CPUs/0/Current_thread",
+                          "CPUs/0",
+                          "CPUs" };
+        try {
+            int q = fixture.getQuarkAbsolute(Attributes.CPUS, "0", Attributes.CURRENT_THREAD);
+            for (int i = 0; i < path.length; i++) {
+                String name = fixture.getFullAttributePath(q);
+                assertEquals(path[i], name);
+                q = fixture.getParentAttributeQuark(q);
+            }
+            assertEquals(-1, q);
+            q = fixture.getParentAttributeQuark(q);
+            assertEquals(-1, q);
+        } catch (AttributeNotFoundException e) {
+            fail();
+        }
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/statesystem/TestAll.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/statesystem/TestAll.java
new file mode 100644 (file)
index 0000000..0fe407d
--- /dev/null
@@ -0,0 +1,29 @@
+/*******************************************************************************
+ * Copyright (c) 2012, 2014 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:
+ *   Alexandre Montplaisir - Initial implementation
+ ******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.kernel.core.tests.analysis.kernel.statesystem;
+
+import org.junit.runner.RunWith;
+import org.junit.runners.Suite;
+
+/**
+ * Runner for the LTTng kernel state system tests.
+ */
+@RunWith(Suite.class)
+@Suite.SuiteClasses({
+    PartialStateSystemTest.class,
+    StateSystemFullHistoryTest.class,
+    StateSystemInMemoryTest.class
+})
+public class TestAll {
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/statesystem/TestValues.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/statesystem/TestValues.java
new file mode 100644 (file)
index 0000000..353f6bc
--- /dev/null
@@ -0,0 +1,3132 @@
+/*******************************************************************************
+ * Copyright (c) 2013, 2015 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:
+ *   Alexandre Montplaisir - Initial API and implementation
+ ******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.kernel.core.tests.analysis.kernel.statesystem;
+
+import org.eclipse.tracecompass.statesystem.core.statevalue.ITmfStateValue;
+import org.eclipse.tracecompass.statesystem.core.statevalue.TmfStateValue;
+
+/**
+ * Expected return values of querying test trace #1's state system at time
+ * "18670067372290L + 1331649577946812237L".
+ *
+ * This file is can be generated using the {@link GenerateTestValues} script.
+ *
+ * @author Alexandre Montplaisir
+ */
+interface TestValues {
+
+    int size = 1031;
+
+    long[] startTimes = {
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668248014145796L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247399757985L,
+        1331668247316320929L,
+        1331668247316334243L,
+        1331668247314046266L,
+        1331668247316120937L,
+        1331668247314038062L,
+        1331668248014183954L,
+        1331668247314038062L,
+        1331668247327098502L,
+        1331668247327098502L,
+        1331668247327098502L,
+        1331668247327098502L,
+        1331668247327098502L,
+        1331668247314038062L,
+        1331668247415001807L,
+        1331668247415001807L,
+        1331668247415001807L,
+        1331668247415001807L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668248013353414L,
+        1331668248004935409L,
+        1331668247314601653L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668248014184526L,
+        1331668248014130616L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668248011125682L,
+        1331668247314038062L,
+        1331668247931793142L,
+        1331668247930941981L,
+        1331668247959041965L,
+        1331668248011129576L,
+        1331668247314038062L,
+        1331668247335106720L,
+        1331668247335106720L,
+        1331668247335106720L,
+        1331668247335106720L,
+        1331668247335106720L,
+        1331668247931782426L,
+        1331668247315274351L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247335112802L,
+        1331668247335112802L,
+        1331668247335112802L,
+        1331668247335112802L,
+        1331668247335112802L,
+        1331668247314038062L,
+        1331668248004705322L,
+        1331668247314038062L,
+        1331668248004935409L,
+        1331668248004770916L,
+        1331668248004925240L,
+        1331668247316553071L,
+        1331668247314038062L,
+        1331668247399148733L,
+        1331668247399743968L,
+        1331668247316925661L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247999256178L,
+        1331668247999239403L,
+        1331668247999250697L,
+        1331668247318567561L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247999336085L,
+        1331668247999131058L,
+        1331668247999327778L,
+        1331668247318631139L,
+        1331668247314038062L,
+        1331668247960265258L,
+        1331668247314038062L,
+        1331668247903884233L,
+        1331668247902254797L,
+        1331668247903869067L,
+        1331668247328403934L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247908495390L,
+        1331668247908391792L,
+        1331668247908464125L,
+        1331668247328921944L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247903840082L,
+        1331668247902986051L,
+        1331668247903831313L,
+        1331668247329404733L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247960291263L,
+        1331668247960272741L,
+        1331668247314038062L,
+        1331668247330548245L,
+        1331668247314038062L,
+        1331668247340039213L,
+        1331668247340083580L,
+        1331668247966976915L,
+        1331668247314038062L,
+        1331668248004729173L,
+        1331668248004720009L,
+        1331668247314038062L,
+        1331668247371137735L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247387196023L,
+        1331668247387154824L,
+        1331668247387191465L,
+        1331668247376420842L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247400231496L,
+        1331668247400130260L,
+        1331668247400218303L,
+        1331668247378430187L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247751186217L,
+        1331668247751173305L,
+        1331668247314038062L,
+        1331668247387136191L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247415047817L,
+        1331668247415047817L,
+        1331668247415047817L,
+        1331668247415047817L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247400095883L,
+        1331668247399991225L,
+        1331668247400085049L,
+        1331668247399991225L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247401441000L,
+        1331668247401408057L,
+        1331668247401428073L,
+        1331668247400779449L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247410754305L,
+        1331668247410594291L,
+        1331668247314038062L,
+        1331668247519727372L,
+        1331668247519619353L,
+        1331668247314038062L,
+        1331668247412887695L,
+        1331668247412803787L,
+        1331668247314038062L,
+        1331668247413704524L,
+        1331668247413576917L,
+        1331668247412877246L,
+        1331668247410583861L,
+        1331668247314038062L,
+        1331668247410735104L,
+        1331668247410594291L,
+        1331668247314038062L,
+        1331668247413682702L,
+        1331668247410844189L,
+        1331668247314038062L,
+        1331668247519712481L,
+        1331668247411099759L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247924029486L,
+        1331668247923412966L,
+        1331668247924012402L,
+        1331668247412302666L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247924105876L,
+        1331668247924010016L,
+        1331668247924098044L,
+        1331668247417574343L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668248014184526L,
+        1331668248013799545L,
+        1331668248014130616L,
+        1331668247417635948L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247928627023L,
+        1331668247928556625L,
+        1331668247928621067L,
+        1331668247417978805L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247928556625L,
+        1331668247927469138L,
+        1331668247928529840L,
+        1331668247418470511L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247930341625L,
+        1331668247928614605L,
+        1331668247314038062L,
+        1331668248014184526L,
+        1331668248014184526L,
+        1331668248013793850L,
+        1331668247419578477L,
+        1331668247314038062L,
+        1331668247930328175L,
+        1331668247419655652L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668248013753736L,
+        1331668248013353414L,
+        1331668248013749389L,
+        1331668247420382626L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247930579872L,
+        1331668247930316322L,
+        1331668247930574368L,
+        1331668247420451876L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247926378321L,
+        1331668247925622863L,
+        1331668247926367737L,
+        1331668247423543945L,
+        1331668247314038062L,
+        1331668247619316825L,
+        1331668247619491008L,
+        1331668247314038062L,
+        1331668247619505885L,
+        1331668247619392829L,
+        1331668247619495072L,
+        1331668247434248026L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247434551326L,
+        1331668247434365352L,
+        1331668247434546203L,
+        1331668247434365352L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247908325947L,
+        1331668247908264450L,
+        1331668247908319810L,
+        1331668247467380509L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247908677700L,
+        1331668247908325947L,
+        1331668247908640244L,
+        1331668247467447781L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247869556425L,
+        1331668247869483379L,
+        1331668247869544380L,
+        1331668247503177108L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247504321893L,
+        1331668247504294050L,
+        1331668247504319470L,
+        1331668247503423094L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668248014183954L,
+        1331668248014145796L,
+        1331668248014183954L,
+        1331668247512172527L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247539381562L,
+        1331668247539325848L,
+        1331668247539369787L,
+        1331668247539325848L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247735177820L,
+        1331668247735128110L,
+        1331668247735170303L,
+        1331668247735128110L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247735168206L,
+        1331668247735152717L,
+        1331668247735161964L,
+        1331668247735152717L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247775218227L,
+        1331668247775191569L,
+        1331668247314038062L,
+        1331668247775231079L,
+        1331668247775218227L,
+        1331668247775205377L,
+        1331668247775191569L,
+        1331668247314038062L,
+        1331668247775223776L,
+        1331668247775218227L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247869483379L,
+        1331668247869457807L,
+        1331668247869477795L,
+        1331668247869457807L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247941667986L,
+        1331668247941620894L,
+        1331668247941650415L,
+        1331668247941620894L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+        1331668247314038062L,
+    };
+
+    long[] endTimes = {
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668248014620024L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054130388L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668248014185078L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668248014620024L,
+        1331668248014620024L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668248014548923L,
+        1331668248014188534L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668248015040151L,
+        1331668259054285979L,
+        1331668248482983146L,
+        1331668248482983146L,
+        1331668248015041609L,
+        1331668248015176320L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668248483009726L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668248015959980L,
+        1331668259054285979L,
+        1331668248016172023L,
+        1331668248016172023L,
+        1331668248016194935L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054130388L,
+        1331668259054136697L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668248016556933L,
+        1331668248016556933L,
+        1331668248016592456L,
+        1331668252511012367L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668248016623209L,
+        1331668248016623209L,
+        1331668248016645047L,
+        1331668252843104826L,
+        1331668259054285979L,
+        1331668248486545657L,
+        1331668259054285979L,
+        1331668248502954816L,
+        1331668248502954816L,
+        1331668248503000162L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668248020364249L,
+        1331668248020364249L,
+        1331668248020419523L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668248020866943L,
+        1331668248020866943L,
+        1331668248020888352L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668248531200073L,
+        1331668248531200073L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668257323835062L,
+        1331668257323879563L,
+        1331668248021867385L,
+        1331668259054285979L,
+        1331668248175307354L,
+        1331668248175307354L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259051873438L,
+        1331668259051873438L,
+        1331668259051879701L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668248751061201L,
+        1331668248751061201L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259051838247L,
+        1331668259051838247L,
+        1331668259051846351L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668257325265220L,
+        1331668257325265220L,
+        1331668257325277639L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668250005943125L,
+        1331668250005943125L,
+        1331668259054285979L,
+        1331668248014565260L,
+        1331668248014565260L,
+        1331668259054285979L,
+        1331668250006219013L,
+        1331668250006219013L,
+        1331668259054285979L,
+        1331668250004649129L,
+        1331668250004649129L,
+        1331668250006228246L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668250005962644L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668250004668081L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668248014624125L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668248414826115L,
+        1331668248414826115L,
+        1331668248414875444L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668248420327828L,
+        1331668248420327828L,
+        1331668248420342919L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668248015353903L,
+        1331668248015353903L,
+        1331668248015428919L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668248420617453L,
+        1331668248420617453L,
+        1331668248420709272L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668248421112139L,
+        1331668248421112139L,
+        1331668248421137268L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668248421291701L,
+        1331668248421291701L,
+        1331668259054285979L,
+        1331668248014188534L,
+        1331668248015518081L,
+        1331668248014188534L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668248421940554L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668248014548923L,
+        1331668248016397030L,
+        1331668248014550770L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668248422509298L,
+        1331668248422509298L,
+        1331668248422523601L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668248424325503L,
+        1331668248424325503L,
+        1331668248424394073L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668248140683324L,
+        1331668248140686546L,
+        1331668259054285979L,
+        1331668248140727269L,
+        1331668248140727269L,
+        1331668248140780012L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668251031789570L,
+        1331668251031789570L,
+        1331668251031812282L,
+        1331668252047037657L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668248269586770L,
+        1331668248269586770L,
+        1331668248269613258L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668248141167328L,
+        1331668248141167328L,
+        1331668248141400164L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668248141004006L,
+        1331668248141004006L,
+        1331668248141028631L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668248141324868L,
+        1331668248141324868L,
+        1331668248141345677L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668248014185078L,
+        1331668248015165243L,
+        1331668248014185078L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668248539549580L,
+        1331668248539549580L,
+        1331668248539579511L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668255234884605L,
+        1331668255234884605L,
+        1331668255234905622L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668255234936617L,
+        1331668255234936617L,
+        1331668255234941684L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668252778982101L,
+        1331668252778982101L,
+        1331668259054285979L,
+        1331668252779007563L,
+        1331668252779007563L,
+        1331668252781320133L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668252781341690L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668248869653287L,
+        1331668248869653287L,
+        1331668248869679933L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668248941858743L,
+        1331668248941858743L,
+        1331668248941885421L,
+        1331668252782929207L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668248207116451L,
+        1331668248207116451L,
+        1331668248207177650L,
+        1331668248207163589L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668248207165629L,
+        1331668248207165629L,
+        1331668248207212201L,
+        1331668248207197204L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668248763171129L,
+        1331668248763171129L,
+        1331668259054285979L,
+        1331668248763179780L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668248895005379L,
+        1331668248895005379L,
+        1331668248895062414L,
+        1331668248895035146L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668249000328909L,
+        1331668249000328909L,
+        1331668249000373092L,
+        1331668249000350716L,
+        1331668259054285979L,
+        1331668249548101920L,
+        1331668259054285979L,
+        1331668249947171998L,
+        1331668249947171998L,
+        1331668249947269897L,
+        1331668249947249018L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668249951033184L,
+        1331668249951033184L,
+        1331668249951077605L,
+        1331668249951058138L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668249959079406L,
+        1331668249959079406L,
+        1331668259054285979L,
+        1331668249959100633L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668249970937981L,
+        1331668249970937981L,
+        1331668259054285979L,
+        1331668249970963407L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668250007423753L,
+        1331668250007423753L,
+        1331668250007449251L,
+        1331668250007428034L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668250231124169L,
+        1331668250231124169L,
+        1331668250231169946L,
+        1331668250231148973L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668250326525622L,
+        1331668250326525622L,
+        1331668250329519305L,
+        1331668250329507458L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668251063191270L,
+        1331668251063191270L,
+        1331668251063256143L,
+        1331668251063222335L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668251065026369L,
+        1331668251065026369L,
+        1331668251065048462L,
+        1331668251065030498L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668251065058051L,
+        1331668251065058051L,
+        1331668251065091761L,
+        1331668251065069765L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668251065364590L,
+        1331668251065364590L,
+        1331668251065412381L,
+        1331668251065407607L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668251065462500L,
+        1331668251065462500L,
+        1331668251065477027L,
+        1331668251065465604L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668251065780572L,
+        1331668251065780572L,
+        1331668251065836719L,
+        1331668251065829440L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668251065899750L,
+        1331668251065899750L,
+        1331668251065913891L,
+        1331668251065902892L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668251066057402L,
+        1331668251066057402L,
+        1331668251066070617L,
+        1331668251066060363L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668251066495616L,
+        1331668251066495616L,
+        1331668251066520321L,
+        1331668251066506338L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668251066532840L,
+        1331668251066532840L,
+        1331668251066546436L,
+        1331668251066535866L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668251066658006L,
+        1331668251066658006L,
+        1331668251066671812L,
+        1331668251066660635L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668251066883302L,
+        1331668251066883302L,
+        1331668251066906446L,
+        1331668251066887423L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668251067153808L,
+        1331668251067153808L,
+        1331668251067176405L,
+        1331668251067157534L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668251067407214L,
+        1331668251067407214L,
+        1331668251067420770L,
+        1331668251067410220L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668251067763731L,
+        1331668251067763731L,
+        1331668251067818612L,
+        1331668251067811009L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668251067884367L,
+        1331668251067884367L,
+        1331668251067897382L,
+        1331668251067887136L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668251068275691L,
+        1331668251068275691L,
+        1331668251068288692L,
+        1331668251068278423L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668251068706355L,
+        1331668251068706355L,
+        1331668251068719015L,
+        1331668251068709290L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668251069067645L,
+        1331668251069067645L,
+        1331668251069122518L,
+        1331668251069116275L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668251069178617L,
+        1331668251069178617L,
+        1331668251069191305L,
+        1331668251069181300L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668251069664884L,
+        1331668251069664884L,
+        1331668251069684555L,
+        1331668251069668097L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668251069682852L,
+        1331668251069682852L,
+        1331668251069708201L,
+        1331668251069690226L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668251715054925L,
+        1331668251715054925L,
+        1331668259054285979L,
+        1331668251715066022L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668251803784493L,
+        1331668251803784493L,
+        1331668251803827591L,
+        1331668251803808547L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668251983438636L,
+        1331668251983438636L,
+        1331668251983448709L,
+        1331668251983441583L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668251992993580L,
+        1331668251992993580L,
+        1331668251993008591L,
+        1331668251992998928L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668252022091542L,
+        1331668252022091542L,
+        1331668252022091542L,
+        1331668252022091542L,
+        1331668252022095079L,
+        1331668259054285979L,
+        1331668252031771660L,
+        1331668252031771660L,
+        1331668252031777595L,
+        1331668252031773847L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668252032463013L,
+        1331668252032463013L,
+        1331668252032502964L,
+        1331668252032497700L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668252032506884L,
+        1331668252032506884L,
+        1331668252032559227L,
+        1331668252032539402L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668252039535067L,
+        1331668252039535067L,
+        1331668259054285979L,
+        1331668252039537404L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668252044008981L,
+        1331668252044008981L,
+        1331668252044014257L,
+        1331668252044010861L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668252044059151L,
+        1331668252044059151L,
+        1331668252044064004L,
+        1331668252044060420L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668252179391423L,
+        1331668252179391423L,
+        1331668252184781913L,
+        1331668252184772369L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668252193425490L,
+        1331668252193425490L,
+        1331668252193432385L,
+        1331668252193427706L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668252253575716L,
+        1331668252253575716L,
+        1331668252253592491L,
+        1331668252253581852L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668252472449352L,
+        1331668252472449352L,
+        1331668252472474547L,
+        1331668252472458163L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668252487295286L,
+        1331668252487295286L,
+        1331668252487300925L,
+        1331668252487297683L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668252495759849L,
+        1331668252495759849L,
+        1331668252495766026L,
+        1331668252495762178L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668252496219924L,
+        1331668252496219924L,
+        1331668252496245837L,
+        1331668252496228816L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668252523291829L,
+        1331668252523291829L,
+        1331668252523482082L,
+        1331668252523469395L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668252764810964L,
+        1331668252764810964L,
+        1331668252764829827L,
+        1331668252764814570L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668252765021775L,
+        1331668252765021775L,
+        1331668252765026623L,
+        1331668252765023841L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668252769399706L,
+        1331668252769399706L,
+        1331668259054285979L,
+        1331668252769401404L,
+        1331668252769401404L,
+        1331668259054285979L,
+        1331668252769446847L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668252769456141L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668252784988923L,
+        1331668252784988923L,
+        1331668259054285979L,
+        1331668252785262589L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668252795062126L,
+        1331668252795062126L,
+        1331668259054285979L,
+        1331668252795122600L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668252828832090L,
+        1331668252828832090L,
+        1331668259054285979L,
+        1331668252828859292L,
+        1331668252828859292L,
+        1331668252828904216L,
+        1331668252828866041L,
+        1331668259054285979L,
+        1331668252829060434L,
+        1331668252828992804L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668252829505108L,
+        1331668252829505108L,
+        1331668259054285979L,
+        1331668252829527974L,
+        1331668252829527974L,
+        1331668252829719292L,
+        1331668252829638887L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668252829643060L,
+        1331668252829643060L,
+        1331668259054285979L,
+        1331668252829660274L,
+        1331668252829660274L,
+        1331668259054285979L,
+        1331668252829683896L,
+        1331668252829683896L,
+        1331668259054285979L,
+        1331668252829799248L,
+        1331668252829799248L,
+        1331668259054285979L,
+        1331668252829802278L,
+        1331668252829802278L,
+        1331668259054285979L,
+        1331668252829821642L,
+        1331668252829821642L,
+        1331668259054285979L,
+        1331668252829840961L,
+        1331668252829840961L,
+        1331668259054285979L,
+        1331668252829859256L,
+        1331668252829859256L,
+        1331668259054285979L,
+        1331668252829976501L,
+        1331668252829976501L,
+        1331668252830107659L,
+        1331668252830085595L,
+        1331668259054285979L,
+        1331668252830154848L,
+        1331668252830139534L,
+        1331668259054285979L,
+        1331668252830212497L,
+        1331668252830194969L,
+        1331668259054285979L,
+        1331668252830382459L,
+        1331668252830368625L,
+        1331668259054285979L,
+        1331668252830526491L,
+        1331668252830499169L,
+        1331668259054285979L,
+        1331668252830576634L,
+        1331668252830564658L,
+        1331668259054285979L,
+        1331668252831112505L,
+        1331668252831083126L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668252831228714L,
+        1331668252831228714L,
+        1331668252831318123L,
+        1331668252831301843L,
+        1331668259054285979L,
+        1331668252831543926L,
+        1331668252831527998L,
+        1331668259054285979L,
+        1331668252831834393L,
+        1331668252831817197L,
+        1331668259054285979L,
+        1331668252832056760L,
+        1331668252832046333L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668252883172744L,
+        1331668252883172744L,
+        1331668252883172744L,
+        1331668252883172744L,
+        1331668252883178472L,
+        1331668259054285979L,
+        1331668252885827603L,
+        1331668252885827603L,
+        1331668252885827603L,
+        1331668252885827603L,
+        1331668252885834716L,
+        1331668259054285979L,
+        1331668252889337098L,
+        1331668252889337098L,
+        1331668259054285979L,
+        1331668252889396688L,
+        1331668252889396688L,
+        1331668252889396688L,
+        1331668252889396688L,
+        1331668252889399649L,
+        1331668252901232798L,
+        1331668252901118256L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668252901540914L,
+        1331668252901540914L,
+        1331668252901540914L,
+        1331668252901540914L,
+        1331668252901545242L,
+        1331668259054285979L,
+        1331668252901573889L,
+        1331668252901573889L,
+        1331668252901586635L,
+        1331668252901577276L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668252906764880L,
+        1331668252906764880L,
+        1331668252906764880L,
+        1331668252906764880L,
+        1331668252906769816L,
+        1331668259054285979L,
+        1331668252912042743L,
+        1331668252912042743L,
+        1331668259054285979L,
+        1331668252912048618L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668252927449371L,
+        1331668252927449371L,
+        1331668252927449371L,
+        1331668252927449371L,
+        1331668252927454567L,
+        1331668259054285979L,
+        1331668252947156908L,
+        1331668252947156908L,
+        1331668252947156908L,
+        1331668252947156908L,
+        1331668252947162086L,
+        1331668259054285979L,
+        1331668252947197386L,
+        1331668252947197386L,
+        1331668252947197386L,
+        1331668252947197386L,
+        1331668252947200470L,
+        1331668259054285979L,
+        1331668253035499713L,
+        1331668253035499713L,
+        1331668253035499713L,
+        1331668253035499713L,
+        1331668253035505047L,
+        1331668259054285979L,
+        1331668253036766769L,
+        1331668253036766769L,
+        1331668253036766769L,
+        1331668253036766769L,
+        1331668253036770602L,
+        1331668259054285979L,
+        1331668253037890651L,
+        1331668253037890651L,
+        1331668253037890651L,
+        1331668253037890651L,
+        1331668253037894147L,
+        1331668259054285979L,
+        1331668253051945128L,
+        1331668253051945128L,
+        1331668253051945128L,
+        1331668253051945128L,
+        1331668253051948233L,
+        1331668259054285979L,
+        1331668253054627961L,
+        1331668253054627961L,
+        1331668253054627961L,
+        1331668253054627961L,
+        1331668253054630786L,
+        1331668259054285979L,
+        1331668253057609433L,
+        1331668253057609433L,
+        1331668253057609433L,
+        1331668253057609433L,
+        1331668253057612341L,
+        1331668259054285979L,
+        1331668253062222314L,
+        1331668253062222314L,
+        1331668253062222314L,
+        1331668253062222314L,
+        1331668253062227485L,
+        1331668259054285979L,
+        1331668253097239708L,
+        1331668253097239708L,
+        1331668253097239708L,
+        1331668253097239708L,
+        1331668253097246792L,
+        1331668259054285979L,
+        1331668253097518746L,
+        1331668253097518746L,
+        1331668253097518746L,
+        1331668253097518746L,
+        1331668253097521994L,
+        1331668259054285979L,
+        1331668253267104284L,
+        1331668253267104284L,
+        1331668253267117055L,
+        1331668253267107624L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668253267342015L,
+        1331668253267342015L,
+        1331668253267378405L,
+        1331668253267367303L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668253278218713L,
+        1331668253278218713L,
+        1331668253278218713L,
+        1331668253278218713L,
+        1331668253278223105L,
+        1331668259054285979L,
+        1331668253324119756L,
+        1331668253324119756L,
+        1331668253324119756L,
+        1331668253324119756L,
+        1331668253324123194L,
+        1331668259054285979L,
+        1331668253614347227L,
+        1331668253614347227L,
+        1331668253614347227L,
+        1331668253614347227L,
+        1331668253614351910L,
+        1331668259054285979L,
+        1331668253619459320L,
+        1331668253619459320L,
+        1331668253619459320L,
+        1331668253619459320L,
+        1331668253619462745L,
+        1331668259054285979L,
+        1331668253619867625L,
+        1331668253619867625L,
+        1331668253619867625L,
+        1331668253619867625L,
+        1331668253619870183L,
+        1331668259054285979L,
+        1331668253621486721L,
+        1331668253621486721L,
+        1331668253621508851L,
+        1331668253621491536L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668253622429608L,
+        1331668253622429608L,
+        1331668253622429608L,
+        1331668253622429608L,
+        1331668253622432889L,
+        1331668259054285979L,
+        1331668253857465365L,
+        1331668253857465365L,
+        1331668253857465365L,
+        1331668253857465365L,
+        1331668253857469629L,
+        1331668259054285979L,
+        1331668253858125091L,
+        1331668253858125091L,
+        1331668253858125091L,
+        1331668253858125091L,
+        1331668253858128274L,
+        1331668259054285979L,
+        1331668253910194540L,
+        1331668253910194540L,
+        1331668253910194540L,
+        1331668253910194540L,
+        1331668253910198633L,
+        1331668259054285979L,
+        1331668253910329721L,
+        1331668253910329721L,
+        1331668253910329721L,
+        1331668253910329721L,
+        1331668253910333029L,
+        1331668259054285979L,
+        1331668253984922308L,
+        1331668253984922308L,
+        1331668253984922308L,
+        1331668253984922308L,
+        1331668253984926366L,
+        1331668259054285979L,
+        1331668254004098152L,
+        1331668254004098152L,
+        1331668254004098152L,
+        1331668254004098152L,
+        1331668254004102129L,
+        1331668259054285979L,
+        1331668254047839900L,
+        1331668254047839900L,
+        1331668254047839900L,
+        1331668254047839900L,
+        1331668254047843621L,
+        1331668259054285979L,
+        1331668254093066195L,
+        1331668254093066195L,
+        1331668254093066195L,
+        1331668254093066195L,
+        1331668254093071603L,
+        1331668259054285979L,
+        1331668254106326339L,
+        1331668254106326339L,
+        1331668254106326339L,
+        1331668254106326339L,
+        1331668254106330527L,
+        1331668259054285979L,
+        1331668255052411647L,
+        1331668255052411647L,
+        1331668255052411647L,
+        1331668255052411647L,
+        1331668255052417904L,
+        1331668259054285979L,
+        1331668255157088064L,
+        1331668255157088064L,
+        1331668255157101973L,
+        1331668255157091812L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668256244508635L,
+        1331668256244508635L,
+        1331668256244508635L,
+        1331668256244508635L,
+        1331668256244513337L,
+        1331668259054285979L,
+        1331668257246987050L,
+        1331668257246987050L,
+        1331668257247036372L,
+        1331668257247027684L,
+        1331668259054285979L,
+        1331668259054285979L,
+        1331668259045096840L,
+        1331668259045096840L,
+        1331668259045096840L,
+        1331668259045096840L,
+        1331668259045103189L,
+        1331668259054285979L,
+        1331668259052126585L,
+        1331668259052126585L,
+        1331668259052126585L,
+        1331668259052126585L,
+        1331668259052129986L,
+        1331668259054285979L,
+        1331668259053345550L,
+        1331668259053345550L,
+        1331668259054285979L,
+        1331668259053349544L,
+        1331668259054285979L,
+    };
+
+    ITmfStateValue[] values = {
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueInt(1397),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueInt(1),
+        TmfStateValue.newValueString("sys_poll"),
+        TmfStateValue.newValueInt(1),
+        TmfStateValue.newValueString("lttng-consumerd"),
+        TmfStateValue.newValueInt(20),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueInt(1),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueInt(5),
+        TmfStateValue.newValueString("swapper/1"),
+        TmfStateValue.newValueInt(20),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueInt(1432),
+        TmfStateValue.newValueInt(2),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueInt(1),
+        TmfStateValue.newValueInt(20),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueString("sys_poll"),
+        TmfStateValue.newValueString("lttng-consumerd"),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueInt(1),
+        TmfStateValue.newValueInt(-6),
+        TmfStateValue.newValueString("sys_ppoll"),
+        TmfStateValue.newValueString("alsa-sink"),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueInt(20),
+        TmfStateValue.newValueString("sys_epoll_wait"),
+        TmfStateValue.newValueString("lttng-sessiond"),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueInt(1),
+        TmfStateValue.newValueInt(20),
+        TmfStateValue.newValueString("sys_futex"),
+        TmfStateValue.newValueString("firefox"),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueInt(1),
+        TmfStateValue.newValueInt(20),
+        TmfStateValue.newValueString("sys_poll"),
+        TmfStateValue.newValueString("firefox"),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueInt(1),
+        TmfStateValue.newValueInt(20),
+        TmfStateValue.newValueString("sys_poll"),
+        TmfStateValue.newValueString("gnome-terminal"),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueInt(1),
+        TmfStateValue.newValueInt(20),
+        TmfStateValue.newValueString("sys_select"),
+        TmfStateValue.newValueString("Xorg"),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueInt(1),
+        TmfStateValue.newValueInt(20),
+        TmfStateValue.newValueString("sys_poll"),
+        TmfStateValue.newValueString("metacity"),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueInt(1),
+        TmfStateValue.newValueInt(20),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueString("kworker/0:1"),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueInt(1),
+        TmfStateValue.newValueInt(20),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueString("ksoftirqd/0"),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueInt(1),
+        TmfStateValue.newValueInt(20),
+        TmfStateValue.newValueString("sys_read"),
+        TmfStateValue.newValueString("rsyslogd"),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueInt(1),
+        TmfStateValue.newValueInt(20),
+        TmfStateValue.newValueString("sys_futex"),
+        TmfStateValue.newValueString("rs:main Q:Reg"),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueInt(1),
+        TmfStateValue.newValueInt(20),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueString("kworker/1:1"),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueInt(1),
+        TmfStateValue.newValueInt(20),
+        TmfStateValue.newValueString("sys_select"),
+        TmfStateValue.newValueString("rsyslogd"),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueInt(1),
+        TmfStateValue.newValueInt(20),
+        TmfStateValue.newValueString("sys_read"),
+        TmfStateValue.newValueString("bash"),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueInt(1),
+        TmfStateValue.newValueInt(20),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueInt(1),
+        TmfStateValue.newValueInt(20),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueInt(1),
+        TmfStateValue.newValueInt(20),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueInt(1),
+        TmfStateValue.newValueInt(20),
+        TmfStateValue.newValueString("sys_poll"),
+        TmfStateValue.newValueString("bamfdaemon"),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueString("sys_poll"),
+        TmfStateValue.newValueString("gnome-settings-"),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueString("sys_poll"),
+        TmfStateValue.newValueString("unity-2d-shell"),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueString("sys_poll"),
+        TmfStateValue.newValueString("unity-2d-panel"),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueInt(1),
+        TmfStateValue.newValueInt(20),
+        TmfStateValue.newValueString("sys_poll"),
+        TmfStateValue.newValueString("indicator-multi"),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueInt(1),
+        TmfStateValue.newValueInt(20),
+        TmfStateValue.newValueString("sys_poll"),
+        TmfStateValue.newValueString("gdbus"),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueInt(1),
+        TmfStateValue.newValueInt(20),
+        TmfStateValue.newValueString("sys_poll"),
+        TmfStateValue.newValueString("dbus-daemon"),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueInt(1),
+        TmfStateValue.newValueInt(20),
+        TmfStateValue.newValueString("sys_poll"),
+        TmfStateValue.newValueString("gdbus"),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueInt(1),
+        TmfStateValue.newValueInt(20),
+        TmfStateValue.newValueString("sys_poll"),
+        TmfStateValue.newValueString("indicator-appli"),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueInt(1),
+        TmfStateValue.newValueInt(20),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueInt(3),
+        TmfStateValue.newValueInt(20),
+        TmfStateValue.newValueString("sys_poll"),
+        TmfStateValue.newValueString("gdbus"),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueString("sys_poll"),
+        TmfStateValue.newValueString("gdbus"),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueInt(5),
+        TmfStateValue.newValueInt(20),
+        TmfStateValue.newValueString("sys_futex"),
+        TmfStateValue.newValueString("unity-panel-ser"),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueInt(1),
+        TmfStateValue.newValueInt(20),
+        TmfStateValue.newValueString("sys_poll"),
+        TmfStateValue.newValueString("hud-service"),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueInt(1),
+        TmfStateValue.newValueInt(20),
+        TmfStateValue.newValueString("sys_poll"),
+        TmfStateValue.newValueString("gdbus"),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueInt(1),
+        TmfStateValue.newValueInt(20),
+        TmfStateValue.newValueString("sys_poll"),
+        TmfStateValue.newValueString("openvpn"),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueInt(1),
+        TmfStateValue.newValueInt(20),
+        TmfStateValue.newValueString("sys_poll"),
+        TmfStateValue.newValueString("firefox"),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueInt(1),
+        TmfStateValue.newValueInt(20),
+        TmfStateValue.newValueString("sys_futex"),
+        TmfStateValue.newValueString("thunderbird-bin"),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueInt(1),
+        TmfStateValue.newValueInt(20),
+        TmfStateValue.newValueString("sys_poll"),
+        TmfStateValue.newValueString("thunderbird-bin"),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueInt(1),
+        TmfStateValue.newValueInt(20),
+        TmfStateValue.newValueString("sys_poll"),
+        TmfStateValue.newValueString("thunderbird-bin"),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueInt(1),
+        TmfStateValue.newValueInt(20),
+        TmfStateValue.newValueString("sys_futex"),
+        TmfStateValue.newValueString("thunderbird-bin"),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueInt(2),
+        TmfStateValue.newValueInt(20),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueString("gdbus"),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueInt(1),
+        TmfStateValue.newValueInt(20),
+        TmfStateValue.newValueString("sys_nanosleep"),
+        TmfStateValue.newValueString("gvfs-afc-volume"),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueInt(1),
+        TmfStateValue.newValueInt(20),
+        TmfStateValue.newValueString("sys_poll"),
+        TmfStateValue.newValueString("rtkit-daemon"),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueInt(1),
+        TmfStateValue.newValueInt(-100),
+        TmfStateValue.newValueString("sys_poll"),
+        TmfStateValue.newValueString("rtkit-daemon"),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueInt(1),
+        TmfStateValue.newValueInt(20),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueInt(1),
+        TmfStateValue.newValueInt(20),
+        TmfStateValue.newValueString("sys_poll"),
+        TmfStateValue.newValueString("thunderbird-bin"),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueString("sys_poll"),
+        TmfStateValue.newValueString("thunderbird-bin"),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueInt(1),
+        TmfStateValue.newValueInt(20),
+        TmfStateValue.newValueString("sys_futex"),
+        TmfStateValue.newValueString("thunderbird-bin"),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.newValueInt(1),
+        TmfStateValue.newValueInt(20),
+        TmfStateValue.newValueString("sys_futex"),
+        TmfStateValue.newValueString("firefox"),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+        TmfStateValue.nullValue(),
+    };
+}
+
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/vm/AllTests.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/vm/AllTests.java
new file mode 100644 (file)
index 0000000..2223160
--- /dev/null
@@ -0,0 +1,26 @@
+/*******************************************************************************
+ * Copyright (c) 2014 École Polytechnique de Montréal
+ *
+ * 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:
+ *   Geneviève Bastien - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.kernel.core.tests.analysis.vm;
+
+import org.junit.runner.RunWith;
+import org.junit.runners.Suite;
+
+/**
+ * Test suite
+ */
+@RunWith(Suite.class)
+@Suite.SuiteClasses({
+        VirtualMachineAnalysisTest.class
+})
+public class AllTests {
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/vm/VirtualMachineAnalysisTest.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/vm/VirtualMachineAnalysisTest.java
new file mode 100644 (file)
index 0000000..e5cd79b
--- /dev/null
@@ -0,0 +1,196 @@
+/*******************************************************************************
+ * Copyright (c) 2014, 2015 École Polytechnique de Montréal
+ *
+ * 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:
+ *   Geneviève Bastien - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.kernel.core.tests.analysis.vm;
+
+import static org.eclipse.tracecompass.common.core.NonNullUtils.checkNotNull;
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertNotNull;
+import static org.junit.Assert.fail;
+import static org.junit.Assume.assumeTrue;
+
+import java.util.Collection;
+import java.util.List;
+
+import org.eclipse.core.runtime.NullProgressMonitor;
+import org.eclipse.tracecompass.analysis.os.linux.core.kernelanalysis.KernelAnalysisModule;
+import org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.VcpuStateValues;
+import org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.VmAttributes;
+import org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.module.VirtualMachineCpuAnalysis;
+import org.eclipse.tracecompass.lttng2.lttng.kernel.core.tests.shared.vm.VmTestExperiment;
+import org.eclipse.tracecompass.statesystem.core.ITmfStateSystem;
+import org.eclipse.tracecompass.statesystem.core.StateSystemUtils;
+import org.eclipse.tracecompass.statesystem.core.exceptions.AttributeNotFoundException;
+import org.eclipse.tracecompass.statesystem.core.exceptions.StateSystemDisposedException;
+import org.eclipse.tracecompass.statesystem.core.interval.ITmfStateInterval;
+import org.eclipse.tracecompass.statesystem.core.statevalue.ITmfStateValue;
+import org.eclipse.tracecompass.statesystem.core.statevalue.TmfStateValue;
+import org.eclipse.tracecompass.tmf.core.signal.TmfTraceOpenedSignal;
+import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace;
+import org.eclipse.tracecompass.tmf.core.trace.TmfTrace;
+import org.eclipse.tracecompass.tmf.core.trace.TmfTraceUtils;
+import org.eclipse.tracecompass.tmf.core.trace.experiment.TmfExperiment;
+import org.junit.Test;
+
+import com.google.common.collect.Multimap;
+
+/**
+ * Test suite for the {@link VirtualMachineCpuAnalysis} class
+ *
+ * @author Geneviève Bastien
+ */
+public class VirtualMachineAnalysisTest {
+
+    private static void verifyStateIntervals(String testId, List<ITmfStateInterval> intervals, int[] expectedStarts, ITmfStateValue[] expectedValues) {
+        int expectedCount = expectedStarts.length - 1;
+
+        assertEquals(testId + ": Interval count", expectedCount, intervals.size());
+        for (int i = 0; i < expectedCount; i++) {
+            ITmfStateInterval interval = intervals.get(i);
+            assertEquals(testId + ": Start time of interval " + i, expectedStarts[i], interval.getStartTime());
+            long actualEnd = (i == expectedCount - 1) ? (expectedStarts[i + 1]) : (expectedStarts[i + 1]) - 1;
+            assertEquals(testId + ": End time of interval " + i, actualEnd, interval.getEndTime());
+            assertEquals(testId + ": Expected value of interval " + i, expectedValues[i], interval.getStateValue());
+        }
+    }
+
+    private static void verifyIntervalsWithMask(String testId, Collection<ITmfStateInterval> intervals, int[] expectedStarts, int[] expectedEnds, ITmfStateValue[] expectedValues, int mask) {
+        int expectedCount = expectedStarts.length - 1;
+
+        assertEquals(testId + ": Interval count", expectedCount, intervals.size());
+        int i = 0;
+        for (ITmfStateInterval interval : intervals) {
+            assertEquals(testId + ": Start time of interval " + i, expectedStarts[i], interval.getStartTime());
+            assertEquals(testId + ": End time of interval " + i, expectedEnds[i], interval.getEndTime());
+            assertEquals(testId + ": Expected value of interval " + i, expectedValues[i].unboxInt() & mask, interval.getStateValue().unboxInt() & mask);
+            i++;
+        }
+    }
+
+    /**
+     * Test the analysis execution with stub traces of a virtual machine with
+     * one virtual machine and one CPU
+     */
+    @Test
+    public void testStubTracesOneQemuKvm() {
+
+        assumeTrue(VmTestExperiment.ONE_QEMUKVM.exists());
+        TmfExperiment experiment = VmTestExperiment.ONE_QEMUKVM.getExperiment(true);
+
+        /* Open the traces */
+        for (ITmfTrace trace : experiment.getTraces()) {
+            ((TmfTrace) trace).traceOpened(new TmfTraceOpenedSignal(this, trace, null));
+        }
+
+        /*
+         * TODO For now, make sure the LttngKernelAnalysis have been run for
+         * each trace before running the analysis. When event request precedence
+         * is implemented, we can remove this
+         */
+        for (ITmfTrace trace : experiment.getTraces()) {
+            trace = checkNotNull(trace);
+            for (KernelAnalysisModule module : TmfTraceUtils.getAnalysisModulesOfClass(trace, KernelAnalysisModule.class)) {
+                module.schedule();
+                module.waitForCompletion();
+            }
+        }
+        /* End of TODO block */
+
+        experiment.traceOpened(new TmfTraceOpenedSignal(this, experiment, null));
+        VirtualMachineCpuAnalysis module = null;
+        for (VirtualMachineCpuAnalysis mod : TmfTraceUtils.getAnalysisModulesOfClass(experiment, VirtualMachineCpuAnalysis.class)) {
+            module = mod;
+            break;
+        }
+        assertNotNull(module);
+        module.schedule();
+        if (!module.waitForCompletion()) {
+            fail("Module did not complete properly");
+        }
+
+        try {
+            /* Check the state system */
+            ITmfStateSystem ss = module.getStateSystem();
+            assertNotNull(ss);
+            int vmQuark;
+
+            vmQuark = ss.getQuarkAbsolute(VmAttributes.VIRTUAL_MACHINES);
+
+            List<Integer> guestQuarks = ss.getSubAttributes(vmQuark, false);
+            assertEquals("Number of guests", 1, guestQuarks.size());
+            List<Integer> vcpuQuarks = ss.getSubAttributes(guestQuarks.get(0), false);
+            assertEquals("Number of virtual CPUs", 1, vcpuQuarks.size());
+            Integer statusQuark = ss.getQuarkRelative(vcpuQuarks.get(0), VmAttributes.STATUS);
+
+            /* Check the intervals for the virtual CPU */
+            List<ITmfStateInterval> intervals = StateSystemUtils.queryHistoryRange(ss, statusQuark, ss.getStartTime(), ss.getCurrentEndTime());
+
+            /* Expected interval values for the virtual CPU */
+            int[] expectedStarts = { 1, 60, 75, 95, 100, 150, 155, 195, 210, 245, 260, 295, 300, 350, 355, 375 };
+            ITmfStateValue[] expectedValues = { TmfStateValue.nullValue(),
+                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_UNKNOWN),
+                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_RUNNING),
+                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_RUNNING | VcpuStateValues.VCPU_VMM),
+                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_RUNNING | VcpuStateValues.VCPU_VMM | VcpuStateValues.VCPU_PREEMPT),
+                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_RUNNING | VcpuStateValues.VCPU_VMM),
+                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_RUNNING),
+                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_RUNNING | VcpuStateValues.VCPU_VMM),
+                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_RUNNING),
+                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_RUNNING | VcpuStateValues.VCPU_VMM),
+                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_RUNNING),
+                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_RUNNING | VcpuStateValues.VCPU_VMM),
+                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_RUNNING | VcpuStateValues.VCPU_VMM | VcpuStateValues.VCPU_PREEMPT),
+                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_RUNNING | VcpuStateValues.VCPU_VMM),
+                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_RUNNING) };
+            verifyStateIntervals("Virtual CPU", intervals, expectedStarts, expectedValues);
+
+            /* Check the status of the guest's threads */
+            int[] expectedStartsT130 = { 10, 35, 75, 175, 195, 225, 275, 295, 300, 350, 375 };
+            int[] expectedEndsT130 = { 34, 74, 174, 224, 209, 274, 374, 299, 349, 354, 375 };
+            ITmfStateValue[] expectedValuesT30 = { TmfStateValue.newValueInt(VcpuStateValues.VCPU_IDLE),
+                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_RUNNING),
+                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_IDLE),
+                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_RUNNING),
+                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_PREEMPT),
+                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_IDLE),
+                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_RUNNING),
+                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_PREEMPT),
+                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_PREEMPT),
+                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_PREEMPT),
+                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_RUNNING) };
+
+            int[] expectedStartsT131 = { 10, 35, 75, 95, 100, 150, 175, 225, 245, 275, 375 };
+            int[] expectedEndsT131 = { 34, 74, 174, 99, 149, 154, 224, 274, 259, 374, 375 };
+            ITmfStateValue[] expectedValuesT31 = { TmfStateValue.newValueInt(VcpuStateValues.VCPU_RUNNING),
+                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_IDLE),
+                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_RUNNING),
+                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_PREEMPT),
+                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_PREEMPT),
+                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_PREEMPT),
+                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_IDLE),
+                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_RUNNING),
+                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_PREEMPT),
+                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_IDLE),
+                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_RUNNING) };
+
+            Multimap<Integer, ITmfStateInterval> threadIntervals = module.getUpdatedThreadIntervals(guestQuarks.get(0), ss.getStartTime(), ss.getCurrentEndTime(), 1, new NullProgressMonitor());
+            verifyIntervalsWithMask("Thread 130", threadIntervals.get(130), expectedStartsT130, expectedEndsT130, expectedValuesT30, VcpuStateValues.VCPU_PREEMPT);
+            verifyIntervalsWithMask("Thread 131", threadIntervals.get(131), expectedStartsT131, expectedEndsT131, expectedValuesT31, VcpuStateValues.VCPU_PREEMPT);
+
+        } catch (AttributeNotFoundException | StateSystemDisposedException e) {
+            fail(e.getMessage());
+        } finally {
+            experiment.dispose();
+        }
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/event/matchandsync/AllTests.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/event/matchandsync/AllTests.java
new file mode 100644 (file)
index 0000000..2402a4b
--- /dev/null
@@ -0,0 +1,28 @@
+/*******************************************************************************
+ * Copyright (c) 2013, 2014 École Polytechnique de Montréal
+ *
+ * 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:
+ *   Geneviève Bastien - Initial implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.kernel.core.tests.event.matchandsync;
+
+import org.junit.runner.RunWith;
+import org.junit.runners.Suite;
+
+/**
+ * Test suite for org.eclipse.linuxtools.lttng2.kernel.core.tests.event.matching
+ */
+@RunWith(Suite.class)
+@Suite.SuiteClasses({
+    ExperimentSyncTest.class,
+    MatchAndSyncTest.class
+})
+public class AllTests {
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/event/matchandsync/ExperimentSyncTest.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/event/matchandsync/ExperimentSyncTest.java
new file mode 100644 (file)
index 0000000..4a65cf0
--- /dev/null
@@ -0,0 +1,112 @@
+/*******************************************************************************
+ * Copyright (c) 2013, 2014 École Polytechnique de Montréal
+ *
+ * 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:
+ *   Geneviève Bastien - Initial implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.kernel.core.tests.event.matchandsync;
+
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assume.assumeTrue;
+
+import org.eclipse.tracecompass.internal.lttng2.kernel.core.event.matching.TcpEventMatching;
+import org.eclipse.tracecompass.internal.lttng2.kernel.core.event.matching.TcpLttngEventMatching;
+import org.eclipse.tracecompass.tmf.core.event.matching.TmfEventMatching;
+import org.eclipse.tracecompass.tmf.core.synchronization.ITmfTimestampTransform;
+import org.eclipse.tracecompass.tmf.core.synchronization.SynchronizationAlgorithm;
+import org.eclipse.tracecompass.tmf.core.synchronization.TimestampTransformFactory;
+import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace;
+import org.eclipse.tracecompass.tmf.core.trace.experiment.TmfExperiment;
+import org.eclipse.tracecompass.tmf.ctf.core.tests.shared.CtfTmfTestTrace;
+import org.eclipse.tracecompass.tmf.ctf.core.trace.CtfTmfTrace;
+import org.junit.BeforeClass;
+import org.junit.Test;
+
+/**
+ * Tests for experiment syncing
+ *
+ * @author Geneviève Bastien
+ */
+@SuppressWarnings("nls")
+public class ExperimentSyncTest {
+
+    private static final String EXPERIMENT = "MyExperiment";
+    private static int BLOCK_SIZE = 1000;
+
+    /**
+     * Initialize some data
+     */
+    @BeforeClass
+    public static void setUp() {
+        TmfEventMatching.registerMatchObject(new TcpEventMatching());
+        TmfEventMatching.registerMatchObject(new TcpLttngEventMatching());
+    }
+
+    /**
+     * Testing experiment synchronization
+     */
+    @Test
+    public void testExperimentSync() {
+        assumeTrue(CtfTmfTestTrace.SYNC_SRC.exists());
+        assumeTrue(CtfTmfTestTrace.SYNC_DEST.exists());
+        try (CtfTmfTrace trace1 = CtfTmfTestTrace.SYNC_SRC.getTrace();
+                CtfTmfTrace trace2 = CtfTmfTestTrace.SYNC_DEST.getTrace();) {
+
+            ITmfTrace[] traces = { trace1, trace2 };
+            TmfExperiment experiment = new TmfExperiment(traces[0].getEventType(), EXPERIMENT, traces, BLOCK_SIZE, null);
+
+            SynchronizationAlgorithm syncAlgo = experiment.synchronizeTraces(true);
+
+            ITmfTimestampTransform tt1 = syncAlgo.getTimestampTransform(trace1);
+            ITmfTimestampTransform tt2 = syncAlgo.getTimestampTransform(trace2);
+
+            trace1.setTimestampTransform(tt1);
+            trace2.setTimestampTransform(tt2);
+
+            assertEquals("TmfTimestampTransformLinearFast [ slope = 0.9999413783703139011056845831168394, offset = 79796507913179.33347660124688298171 ]", tt1.toString());
+            assertEquals(TimestampTransformFactory.getDefaultTransform(), tt2);
+
+            assertEquals(syncAlgo.getTimestampTransform(trace1.getHostId()), trace1.getTimestampTransform());
+            assertEquals(syncAlgo.getTimestampTransform(trace2.getHostId()), trace2.getTimestampTransform());
+
+        }
+    }
+
+    /**
+     * Testing synchronization with 3 traces, one of which synchronizes with
+     * both other
+     */
+    @Test
+    public void testDjangoExperimentSync() {
+        assumeTrue(CtfTmfTestTrace.DJANGO_CLIENT.exists());
+        assumeTrue(CtfTmfTestTrace.DJANGO_DB.exists());
+        assumeTrue(CtfTmfTestTrace.DJANGO_HTTPD.exists());
+        try (CtfTmfTrace trace1 = CtfTmfTestTrace.DJANGO_CLIENT.getTrace();
+                CtfTmfTrace trace2 = CtfTmfTestTrace.DJANGO_DB.getTrace();
+                CtfTmfTrace trace3 = CtfTmfTestTrace.DJANGO_HTTPD.getTrace();) {
+            ITmfTrace[] traces = { trace1, trace2, trace3 };
+            TmfExperiment experiment = new TmfExperiment(traces[0].getEventType(), EXPERIMENT, traces, BLOCK_SIZE, null);
+
+            SynchronizationAlgorithm syncAlgo = experiment.synchronizeTraces(true);
+
+            ITmfTimestampTransform tt1 = syncAlgo.getTimestampTransform(trace1);
+            ITmfTimestampTransform tt2 = syncAlgo.getTimestampTransform(trace2);
+            ITmfTimestampTransform tt3 = syncAlgo.getTimestampTransform(trace3);
+
+            trace1.setTimestampTransform(tt1);
+            trace2.setTimestampTransform(tt2);
+            trace3.setTimestampTransform(tt3);
+
+            assertEquals(TimestampTransformFactory.getDefaultTransform(), tt1);
+            assertEquals("TmfTimestampTransformLinearFast [ slope = 0.9999996313017589597204633828681240, offset = 498490309972.0038068817738527724192 ]", tt2.toString());
+            assertEquals("TmfTimestampTransformLinearFast [ slope = 1.000000119014882262265342419815932, offset = -166652893534.6189900382736187431134 ]", tt3.toString());
+
+        }
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/event/matchandsync/MatchAndSyncTest.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/event/matchandsync/MatchAndSyncTest.java
new file mode 100644 (file)
index 0000000..29aa3ad
--- /dev/null
@@ -0,0 +1,77 @@
+/*******************************************************************************
+ * Copyright (c) 2013, 2014 École Polytechnique de Montréal
+ *
+ * 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:
+ *   Geneviève Bastien - Initial implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.kernel.core.tests.event.matchandsync;
+
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertTrue;
+import static org.junit.Assert.fail;
+import static org.junit.Assume.assumeTrue;
+
+import java.lang.reflect.InvocationTargetException;
+import java.lang.reflect.Method;
+import java.util.LinkedList;
+import java.util.List;
+
+import org.eclipse.tracecompass.internal.lttng2.kernel.core.event.matching.TcpEventMatching;
+import org.eclipse.tracecompass.internal.lttng2.kernel.core.event.matching.TcpLttngEventMatching;
+import org.eclipse.tracecompass.tmf.core.event.matching.IMatchProcessingUnit;
+import org.eclipse.tracecompass.tmf.core.event.matching.TmfEventMatching;
+import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace;
+import org.eclipse.tracecompass.tmf.ctf.core.tests.shared.CtfTmfTestTrace;
+import org.eclipse.tracecompass.tmf.ctf.core.trace.CtfTmfTrace;
+import org.junit.Test;
+
+/**
+ * Tests for {@link TcpEventMatching}
+ *
+ * @author Geneviève Bastien
+ */
+@SuppressWarnings("nls")
+public class MatchAndSyncTest {
+
+    /**
+     * Testing the packet matching
+     */
+    @Test
+    public void testMatching() {
+        assumeTrue(CtfTmfTestTrace.SYNC_SRC.exists());
+        assumeTrue(CtfTmfTestTrace.SYNC_DEST.exists());
+        try (CtfTmfTrace trace1 = CtfTmfTestTrace.SYNC_SRC.getTrace();
+                CtfTmfTrace trace2 = CtfTmfTestTrace.SYNC_DEST.getTrace();) {
+
+            List<ITmfTrace> tracearr = new LinkedList<>();
+            tracearr.add(trace1);
+            tracearr.add(trace2);
+
+            TmfEventMatching.registerMatchObject(new TcpEventMatching());
+            TmfEventMatching.registerMatchObject(new TcpLttngEventMatching());
+
+            TmfEventMatching twoTraceMatch = new TmfEventMatching(tracearr);
+            assertTrue(twoTraceMatch.matchEvents());
+
+            /* Set method and fields accessible to make sure the counts are ok */
+            try {
+                /* Verify number of matches */
+                Method method = TmfEventMatching.class.getDeclaredMethod("getProcessingUnit");
+                method.setAccessible(true);
+                IMatchProcessingUnit procUnit = (IMatchProcessingUnit) method.invoke(twoTraceMatch);
+                assertEquals(46, procUnit.countMatches());
+
+            } catch (NoSuchMethodException | SecurityException | IllegalAccessException | IllegalArgumentException | InvocationTargetException e) {
+                fail(e.getMessage());
+            }
+
+        }
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/testfiles/vm/OneQemuKvm/guest.xml b/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/testfiles/vm/OneQemuKvm/guest.xml
new file mode 100644 (file)
index 0000000..fc973d3
--- /dev/null
@@ -0,0 +1,105 @@
+<trace>
+<event timestamp="0" name="set_aspects">
+<field name="cpu" value="1" type="int" />
+</event>
+<event timestamp="10" name="sched_switch">
+<field name="cpu" value="0" type="int" />
+<field name="prev_comm" value="any" type="string" />
+<field name="prev_tid" value="130" type="long" />
+<field name="prev_prio" value="20" type="long" />
+<field name="prev_state" value="0" type="long" />
+<field name="next_comm" value="any2" type="string" />
+<field name="next_tid" value="131" type="long" />
+<field name="next_prio" value="20" type="long" />
+</event>
+<event timestamp="35" name="sched_switch">
+<field name="cpu" value="0" type="int" />
+<field name="prev_comm" value="any2" type="string" />
+<field name="prev_tid" value="131" type="long" />
+<field name="prev_prio" value="20" type="long" />
+<field name="prev_state" value="0" type="long" />
+<field name="next_comm" value="any" type="string" />
+<field name="next_tid" value="130" type="long" />
+<field name="next_prio" value="20" type="long" />
+</event>
+<event timestamp="40" name="vmsync_gh_guest">
+<field name="cpu" value="0" type="int" />
+<field name="cnt" value="1" type="int" />
+<field name="vm_uid" value="123456" type="long" />
+</event>
+<event timestamp="65" name="vmsync_hg_guest">
+<field name="cpu" value="0" type="int" />
+<field name="cnt" value="2" type="int" />
+<field name="vm_uid" value="123456" type="long" />
+</event>
+<event timestamp="75" name="sched_switch">
+<field name="cpu" value="0" type="int" />
+<field name="prev_comm" value="any" type="string" />
+<field name="prev_tid" value="130" type="long" />
+<field name="prev_prio" value="20" type="long" />
+<field name="prev_state" value="0" type="long" />
+<field name="next_comm" value="any2" type="string" />
+<field name="next_tid" value="131" type="long" />
+<field name="next_prio" value="20" type="long" />
+</event>
+<event timestamp="175" name="sched_switch">
+<field name="cpu" value="0" type="int" />
+<field name="prev_comm" value="any2" type="string" />
+<field name="prev_tid" value="131" type="long" />
+<field name="prev_prio" value="20" type="long" />
+<field name="prev_state" value="0" type="long" />
+<field name="next_comm" value="any" type="string" />
+<field name="next_tid" value="130" type="long" />
+<field name="next_prio" value="20" type="long" />
+</event>
+<event timestamp="190" name="vmsync_gh_guest">
+<field name="cpu" value="0" type="int" />
+<field name="cnt" value="3" type="int" />
+<field name="vm_uid" value="123456" type="long" />
+</event>
+<event timestamp="215" name="vmsync_hg_guest">
+<field name="cpu" value="0" type="int" />
+<field name="cnt" value="4" type="int" />
+<field name="vm_uid" value="123456" type="long" />
+</event>
+<event timestamp="225" name="sched_switch">
+<field name="cpu" value="0" type="int" />
+<field name="prev_comm" value="any" type="string" />
+<field name="prev_tid" value="130" type="long" />
+<field name="prev_prio" value="20" type="long" />
+<field name="prev_state" value="0" type="long" />
+<field name="next_comm" value="any2" type="string" />
+<field name="next_tid" value="131" type="long" />
+<field name="next_prio" value="20" type="long" />
+</event>
+<event timestamp="240" name="vmsync_gh_guest">
+<field name="cpu" value="0" type="int" />
+<field name="cnt" value="5" type="int" />
+<field name="vm_uid" value="123456" type="long" />
+</event>
+<event timestamp="265" name="vmsync_hg_guest">
+<field name="cpu" value="0" type="int" />
+<field name="cnt" value="6" type="int" />
+<field name="vm_uid" value="123456" type="long" />
+</event>
+<event timestamp="275" name="sched_switch">
+<field name="cpu" value="0" type="int" />
+<field name="prev_comm" value="any2" type="string" />
+<field name="prev_tid" value="131" type="long" />
+<field name="prev_prio" value="20" type="long" />
+<field name="prev_state" value="0" type="long" />
+<field name="next_comm" value="any" type="string" />
+<field name="next_tid" value="130" type="long" />
+<field name="next_prio" value="20" type="long" />
+</event>
+<event timestamp="375" name="sched_switch">
+<field name="cpu" value="0" type="int" />
+<field name="prev_comm" value="any" type="string" />
+<field name="prev_tid" value="130" type="long" />
+<field name="prev_prio" value="20" type="long" />
+<field name="prev_state" value="0" type="long" />
+<field name="next_comm" value="any2" type="string" />
+<field name="next_tid" value="131" type="long" />
+<field name="next_prio" value="20" type="long" />
+</event>
+</trace>
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/testfiles/vm/OneQemuKvm/host.xml b/lttng/org.eclipse.tracecompass.lttng2.kernel.core.tests/testfiles/vm/OneQemuKvm/host.xml
new file mode 100644 (file)
index 0000000..c26e836
--- /dev/null
@@ -0,0 +1,149 @@
+<trace>
+<event timestamp="0" name="set_aspects">
+<field name="cpu" value="1" type="int" />
+</event>
+<event timestamp="1" name="sched_switch">
+<field name="cpu" value="0" type="int" />
+<field name="prev_comm" value="any" type="string" />
+<field name="prev_tid" value="30" type="long" />
+<field name="prev_prio" value="20" type="long" />
+<field name="prev_state" value="0" type="long" />
+<field name="next_comm" value="qemucpu1" type="string" />
+<field name="next_tid" value="31" type="long" />
+<field name="next_prio" value="20" type="long" />
+</event>
+<event timestamp="5" name="kvm_entry">
+<field name="cpu" value="0" type="int" />
+<field name="vcpu_id" value="0" type="long" />
+</event>
+<event timestamp="45" name="kvm_exit">
+<field name="cpu" value="0" type="int" />
+<field name="exit_reason" value="32" type="int" />
+<field name="guest_rip" value="123456" type="long" />
+<field name="isa" value="1" type="int" />
+<field name="info1" value="654654" type="long" />
+<field name="info2" value="456789" type="long" />
+</event>
+<event timestamp="50" name="vmsync_gh_host">
+<field name="cpu" value="0" type="int" />
+<field name="cnt" value="1" type="int" />
+<field name="vm_uid" value="123456" type="long" />
+</event>
+<event timestamp="55" name="vmsync_hg_host">
+<field name="cpu" value="0" type="int" />
+<field name="cnt" value="2" type="int" />
+<field name="vm_uid" value="123456" type="long" />
+</event>
+<event timestamp="60" name="kvm_entry">
+<field name="cpu" value="0" type="int" />
+<field name="vcpu_id" value="0" type="long" />
+</event>
+<event timestamp="95" name="kvm_exit">
+<field name="cpu" value="0" type="int" />
+<field name="exit_reason" value="32" type="int" />
+<field name="guest_rip" value="123456" type="long" />
+<field name="isa" value="1" type="int" />
+<field name="info1" value="654654" type="long" />
+<field name="info2" value="456789" type="long" />
+</event>
+<event timestamp="100" name="sched_switch">
+<field name="cpu" value="0" type="int" />
+<field name="prev_comm" value="qemucpu1" type="string" />
+<field name="prev_tid" value="31" type="long" />
+<field name="prev_prio" value="20" type="long" />
+<field name="prev_state" value="0" type="long" />
+<field name="next_comm" value="any" type="string" />
+<field name="next_tid" value="30" type="long" />
+<field name="next_prio" value="20" type="long" />
+</event>
+<event timestamp="150" name="sched_switch">
+<field name="cpu" value="0" type="int" />
+<field name="prev_comm" value="any" type="string" />
+<field name="prev_tid" value="30" type="long" />
+<field name="prev_prio" value="20" type="long" />
+<field name="prev_state" value="0" type="long" />
+<field name="next_comm" value="qemucpu1" type="string" />
+<field name="next_tid" value="31" type="long" />
+<field name="next_prio" value="20" type="long" />
+</event>
+<event timestamp="155" name="kvm_entry">
+<field name="cpu" value="0" type="int" />
+<field name="vcpu_id" value="0" type="long" />
+</event>
+<event timestamp="195" name="kvm_exit">
+<field name="cpu" value="0" type="int" />
+<field name="exit_reason" value="32" type="int" />
+<field name="guest_rip" value="123456" type="long" />
+<field name="isa" value="1" type="int" />
+<field name="info1" value="654654" type="long" />
+<field name="info2" value="456789" type="long" />
+</event>
+<event timestamp="200" name="vmsync_gh_host">
+<field name="cpu" value="0" type="int" />
+<field name="cnt" value="3" type="int" />
+<field name="vm_uid" value="123456" type="long" />
+</event>
+<event timestamp="205" name="vmsync_hg_host">
+<field name="cpu" value="0" type="int" />
+<field name="cnt" value="4" type="int" />
+<field name="vm_uid" value="123456" type="long" />
+</event>
+<event timestamp="210" name="kvm_entry">
+<field name="cpu" value="0" type="int" />
+<field name="vcpu_id" value="0" type="long" />
+</event>
+<event timestamp="245" name="kvm_exit">
+<field name="cpu" value="0" type="int" />
+<field name="exit_reason" value="32" type="int" />
+<field name="guest_rip" value="123456" type="long" />
+<field name="isa" value="1" type="int" />
+<field name="info1" value="654654" type="long" />
+<field name="info2" value="456789" type="long" />
+</event>
+<event timestamp="250" name="vmsync_gh_host">
+<field name="cpu" value="0" type="int" />
+<field name="cnt" value="5" type="int" />
+<field name="vm_uid" value="123456" type="long" />
+</event>
+<event timestamp="255" name="vmsync_hg_host">
+<field name="cpu" value="0" type="int" />
+<field name="cnt" value="6" type="int" />
+<field name="vm_uid" value="123456" type="long" />
+</event>
+<event timestamp="260" name="kvm_entry">
+<field name="cpu" value="0" type="int" />
+<field name="vcpu_id" value="0" type="long" />
+</event>
+<event timestamp="295" name="kvm_exit">
+<field name="cpu" value="0" type="int" />
+<field name="exit_reason" value="32" type="int" />
+<field name="guest_rip" value="123456" type="long" />
+<field name="isa" value="1" type="int" />
+<field name="info1" value="654654" type="long" />
+<field name="info2" value="456789" type="long" />
+</event>
+<event timestamp="300" name="sched_switch">
+<field name="cpu" value="0" type="int" />
+<field name="prev_comm" value="qemucpu1" type="string" />
+<field name="prev_tid" value="31" type="long" />
+<field name="prev_prio" value="20" type="long" />
+<field name="prev_state" value="0" type="long" />
+<field name="next_comm" value="any" type="string" />
+<field name="next_tid" value="30" type="long" />
+<field name="next_prio" value="20" type="long" />
+</event>
+<event timestamp="350" name="sched_switch">
+<field name="cpu" value="0" type="int" />
+<field name="prev_comm" value="any" type="string" />
+<field name="prev_tid" value="30" type="long" />
+<field name="prev_prio" value="20" type="long" />
+<field name="prev_state" value="0" type="long" />
+<field name="next_comm" value="qemucpu1" type="string" />
+<field name="next_tid" value="31" type="long" />
+<field name="next_prio" value="20" type="long" />
+</event>
+<event timestamp="355" name="kvm_entry">
+<field name="cpu" value="0" type="int" />
+<field name="vcpu_id" value="0" type="long" />
+</event>
+</trace>
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core/.classpath b/lttng/org.eclipse.tracecompass.lttng2.kernel.core/.classpath
new file mode 100644 (file)
index 0000000..098194c
--- /dev/null
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+       <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7"/>
+       <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
+       <classpathentry kind="src" path="src"/>
+       <classpathentry kind="output" path="bin"/>
+</classpath>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core/.project b/lttng/org.eclipse.tracecompass.lttng2.kernel.core/.project
new file mode 100644 (file)
index 0000000..6883fd5
--- /dev/null
@@ -0,0 +1,34 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+       <name>org.eclipse.tracecompass.lttng2.kernel.core</name>
+       <comment></comment>
+       <projects>
+       </projects>
+       <buildSpec>
+               <buildCommand>
+                       <name>org.eclipse.jdt.core.javabuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+               <buildCommand>
+                       <name>org.eclipse.pde.ManifestBuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+               <buildCommand>
+                       <name>org.eclipse.pde.SchemaBuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+               <buildCommand>
+                       <name>org.eclipse.pde.api.tools.apiAnalysisBuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+       </buildSpec>
+       <natures>
+               <nature>org.eclipse.pde.PluginNature</nature>
+               <nature>org.eclipse.jdt.core.javanature</nature>
+               <nature>org.eclipse.pde.api.tools.apiAnalysisNature</nature>
+       </natures>
+</projectDescription>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core/.settings/org.eclipse.core.resources.prefs b/lttng/org.eclipse.tracecompass.lttng2.kernel.core/.settings/org.eclipse.core.resources.prefs
new file mode 100644 (file)
index 0000000..99f26c0
--- /dev/null
@@ -0,0 +1,2 @@
+eclipse.preferences.version=1
+encoding/<project>=UTF-8
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core/.settings/org.eclipse.core.runtime.prefs b/lttng/org.eclipse.tracecompass.lttng2.kernel.core/.settings/org.eclipse.core.runtime.prefs
new file mode 100644 (file)
index 0000000..5a0ad22
--- /dev/null
@@ -0,0 +1,2 @@
+eclipse.preferences.version=1
+line.separator=\n
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core/.settings/org.eclipse.jdt.core.prefs b/lttng/org.eclipse.tracecompass.lttng2.kernel.core/.settings/org.eclipse.jdt.core.prefs
new file mode 100644 (file)
index 0000000..a2b5e6b
--- /dev/null
@@ -0,0 +1,405 @@
+eclipse.preferences.version=1
+org.eclipse.jdt.core.codeComplete.argumentPrefixes=
+org.eclipse.jdt.core.codeComplete.argumentSuffixes=
+org.eclipse.jdt.core.codeComplete.fieldPrefixes=f
+org.eclipse.jdt.core.codeComplete.fieldSuffixes=
+org.eclipse.jdt.core.codeComplete.localPrefixes=
+org.eclipse.jdt.core.codeComplete.localSuffixes=
+org.eclipse.jdt.core.codeComplete.staticFieldPrefixes=
+org.eclipse.jdt.core.codeComplete.staticFieldSuffixes=
+org.eclipse.jdt.core.codeComplete.staticFinalFieldPrefixes=
+org.eclipse.jdt.core.codeComplete.staticFinalFieldSuffixes=
+org.eclipse.jdt.core.compiler.annotation.inheritNullAnnotations=enabled
+org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore
+org.eclipse.jdt.core.compiler.annotation.nonnull=org.eclipse.jdt.annotation.NonNull
+org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=org.eclipse.jdt.annotation.NonNullByDefault
+org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nullable
+org.eclipse.jdt.core.compiler.annotation.nullanalysis=enabled
+org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
+org.eclipse.jdt.core.compiler.codegen.methodParameters=do not generate
+org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
+org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
+org.eclipse.jdt.core.compiler.compliance=1.7
+org.eclipse.jdt.core.compiler.debug.lineNumber=generate
+org.eclipse.jdt.core.compiler.debug.localVariable=generate
+org.eclipse.jdt.core.compiler.debug.sourceFile=generate
+org.eclipse.jdt.core.compiler.doc.comment.support=enabled
+org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=error
+org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
+org.eclipse.jdt.core.compiler.problem.autoboxing=ignore
+org.eclipse.jdt.core.compiler.problem.comparingIdentical=error
+org.eclipse.jdt.core.compiler.problem.deadCode=error
+org.eclipse.jdt.core.compiler.problem.deprecation=error
+org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled
+org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=enabled
+org.eclipse.jdt.core.compiler.problem.discouragedReference=warning
+org.eclipse.jdt.core.compiler.problem.emptyStatement=error
+org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
+org.eclipse.jdt.core.compiler.problem.explicitlyClosedAutoCloseable=error
+org.eclipse.jdt.core.compiler.problem.fallthroughCase=error
+org.eclipse.jdt.core.compiler.problem.fatalOptionalError=disabled
+org.eclipse.jdt.core.compiler.problem.fieldHiding=error
+org.eclipse.jdt.core.compiler.problem.finalParameterBound=error
+org.eclipse.jdt.core.compiler.problem.finallyBlockNotCompletingNormally=error
+org.eclipse.jdt.core.compiler.problem.forbiddenReference=error
+org.eclipse.jdt.core.compiler.problem.hiddenCatchBlock=error
+org.eclipse.jdt.core.compiler.problem.includeNullInfoFromAsserts=disabled
+org.eclipse.jdt.core.compiler.problem.incompatibleNonInheritedInterfaceMethod=error
+org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch=error
+org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=error
+org.eclipse.jdt.core.compiler.problem.invalidJavadoc=warning
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTags=enabled
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsDeprecatedRef=enabled
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsNotVisibleRef=enabled
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsVisibility=protected
+org.eclipse.jdt.core.compiler.problem.localVariableHiding=error
+org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=error
+org.eclipse.jdt.core.compiler.problem.missingDefaultCase=error
+org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=error
+org.eclipse.jdt.core.compiler.problem.missingEnumCaseDespiteDefault=enabled
+org.eclipse.jdt.core.compiler.problem.missingHashCodeMethod=error
+org.eclipse.jdt.core.compiler.problem.missingJavadocComments=warning
+org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsOverriding=disabled
+org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsVisibility=protected
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagDescription=all_standard_tags
+org.eclipse.jdt.core.compiler.problem.missingJavadocTags=warning
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagsMethodTypeParameters=disabled
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagsOverriding=disabled
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagsVisibility=protected
+org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotation=error
+org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotationForInterfaceMethodImplementation=enabled
+org.eclipse.jdt.core.compiler.problem.missingSerialVersion=error
+org.eclipse.jdt.core.compiler.problem.missingSynchronizedOnInheritedMethod=error
+org.eclipse.jdt.core.compiler.problem.noEffectAssignment=error
+org.eclipse.jdt.core.compiler.problem.noImplicitStringConversion=error
+org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=warning
+org.eclipse.jdt.core.compiler.problem.nonnullParameterAnnotationDropped=warning
+org.eclipse.jdt.core.compiler.problem.nullAnnotationInferenceConflict=warning
+org.eclipse.jdt.core.compiler.problem.nullReference=error
+org.eclipse.jdt.core.compiler.problem.nullSpecViolation=error
+org.eclipse.jdt.core.compiler.problem.nullUncheckedConversion=warning
+org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=error
+org.eclipse.jdt.core.compiler.problem.parameterAssignment=error
+org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=error
+org.eclipse.jdt.core.compiler.problem.potentialNullReference=error
+org.eclipse.jdt.core.compiler.problem.potentiallyUnclosedCloseable=warning
+org.eclipse.jdt.core.compiler.problem.rawTypeReference=warning
+org.eclipse.jdt.core.compiler.problem.redundantNullAnnotation=warning
+org.eclipse.jdt.core.compiler.problem.redundantNullCheck=error
+org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=error
+org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=error
+org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore
+org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=error
+org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled
+org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=error
+org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=disabled
+org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled
+org.eclipse.jdt.core.compiler.problem.syntacticNullAnalysisForFields=enabled
+org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=ignore
+org.eclipse.jdt.core.compiler.problem.typeParameterHiding=error
+org.eclipse.jdt.core.compiler.problem.unavoidableGenericTypeProblems=disabled
+org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=warning
+org.eclipse.jdt.core.compiler.problem.unclosedCloseable=error
+org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=ignore
+org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=error
+org.eclipse.jdt.core.compiler.problem.unnecessaryElse=error
+org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=error
+org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=warning
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionExemptExceptionAndThrowable=disabled
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionIncludeDocCommentReference=disabled
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverriding=disabled
+org.eclipse.jdt.core.compiler.problem.unusedExceptionParameter=ignore
+org.eclipse.jdt.core.compiler.problem.unusedImport=error
+org.eclipse.jdt.core.compiler.problem.unusedLabel=error
+org.eclipse.jdt.core.compiler.problem.unusedLocal=error
+org.eclipse.jdt.core.compiler.problem.unusedObjectAllocation=ignore
+org.eclipse.jdt.core.compiler.problem.unusedParameter=error
+org.eclipse.jdt.core.compiler.problem.unusedParameterIncludeDocCommentReference=enabled
+org.eclipse.jdt.core.compiler.problem.unusedParameterWhenImplementingAbstract=disabled
+org.eclipse.jdt.core.compiler.problem.unusedParameterWhenOverridingConcrete=disabled
+org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=error
+org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=error
+org.eclipse.jdt.core.compiler.problem.unusedWarningToken=error
+org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=error
+org.eclipse.jdt.core.compiler.source=1.7
+org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=16
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_call=16
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation=16
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression=16
+org.eclipse.jdt.core.formatter.alignment_for_assignment=0
+org.eclipse.jdt.core.formatter.alignment_for_binary_expression=16
+org.eclipse.jdt.core.formatter.alignment_for_compact_if=16
+org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=80
+org.eclipse.jdt.core.formatter.alignment_for_enum_constants=0
+org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=16
+org.eclipse.jdt.core.formatter.alignment_for_method_declaration=0
+org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16
+org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=80
+org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation=0
+org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_constructor_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_method_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_union_type_in_multicatch=16
+org.eclipse.jdt.core.formatter.blank_lines_after_imports=1
+org.eclipse.jdt.core.formatter.blank_lines_after_package=1
+org.eclipse.jdt.core.formatter.blank_lines_before_field=0
+org.eclipse.jdt.core.formatter.blank_lines_before_first_class_body_declaration=0
+org.eclipse.jdt.core.formatter.blank_lines_before_imports=1
+org.eclipse.jdt.core.formatter.blank_lines_before_member_type=1
+org.eclipse.jdt.core.formatter.blank_lines_before_method=1
+org.eclipse.jdt.core.formatter.blank_lines_before_new_chunk=1
+org.eclipse.jdt.core.formatter.blank_lines_before_package=0
+org.eclipse.jdt.core.formatter.blank_lines_between_import_groups=1
+org.eclipse.jdt.core.formatter.blank_lines_between_type_declarations=1
+org.eclipse.jdt.core.formatter.brace_position_for_annotation_type_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_array_initializer=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_block=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_block_in_case=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_constructor_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_enum_constant=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_enum_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_method_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_switch=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_type_declaration=end_of_line
+org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_block_comment=false
+org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_javadoc_comment=false
+org.eclipse.jdt.core.formatter.comment.format_block_comments=true
+org.eclipse.jdt.core.formatter.comment.format_header=false
+org.eclipse.jdt.core.formatter.comment.format_html=true
+org.eclipse.jdt.core.formatter.comment.format_javadoc_comments=true
+org.eclipse.jdt.core.formatter.comment.format_line_comments=true
+org.eclipse.jdt.core.formatter.comment.format_source_code=true
+org.eclipse.jdt.core.formatter.comment.indent_parameter_description=true
+org.eclipse.jdt.core.formatter.comment.indent_root_tags=true
+org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags=insert
+org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter=insert
+org.eclipse.jdt.core.formatter.comment.line_length=80
+org.eclipse.jdt.core.formatter.comment.new_lines_at_block_boundaries=true
+org.eclipse.jdt.core.formatter.comment.new_lines_at_javadoc_boundaries=true
+org.eclipse.jdt.core.formatter.comment.preserve_white_space_between_code_and_line_comments=false
+org.eclipse.jdt.core.formatter.compact_else_if=true
+org.eclipse.jdt.core.formatter.continuation_indentation=2
+org.eclipse.jdt.core.formatter.continuation_indentation_for_array_initializer=2
+org.eclipse.jdt.core.formatter.disabling_tag=@formatter\:off
+org.eclipse.jdt.core.formatter.enabling_tag=@formatter\:on
+org.eclipse.jdt.core.formatter.format_guardian_clause_on_one_line=false
+org.eclipse.jdt.core.formatter.format_line_comment_starting_on_first_column=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_annotation_declaration_header=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_constant_header=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_declaration_header=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_type_header=true
+org.eclipse.jdt.core.formatter.indent_breaks_compare_to_cases=true
+org.eclipse.jdt.core.formatter.indent_empty_lines=false
+org.eclipse.jdt.core.formatter.indent_statements_compare_to_block=true
+org.eclipse.jdt.core.formatter.indent_statements_compare_to_body=true
+org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_cases=true
+org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_switch=false
+org.eclipse.jdt.core.formatter.indentation.size=4
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_field=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_local_variable=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_method=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_package=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_parameter=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_type=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_label=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_opening_brace_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_at_end_of_file_if_missing=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_finally_in_try_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_while_in_do_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_annotation_declaration=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_anonymous_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_block=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter=insert
+org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_binary_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_paren_in_cast=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_assert=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_case=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_labeled_statement=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_allocation_expression=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_annotation=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_throws=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_constant_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_declarations=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_explicitconstructorcall_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_increments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_inits=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_throws=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_invocation_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_field_declarations=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_local_declarations=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_parameterized_type_reference=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_superinterfaces=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_ellipsis=insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_brace_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_cast=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_catch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_for=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_if=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_parenthesized_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_switch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_synchronized=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_try=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_while=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_try_resources=insert
+org.eclipse.jdt.core.formatter.insert_space_after_unary_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter=insert
+org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_binary_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_brace_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_cast=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_catch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_for=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_if=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_parenthesized_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_switch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_synchronized=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_try=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_while=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_assert=insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_case=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_default=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_labeled_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_throws=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_constant_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_declarations=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_explicitconstructorcall_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_increments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_inits=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_throws=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_invocation_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_field_declarations=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_local_declarations=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_superinterfaces=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_ellipsis=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_annotation_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_anonymous_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_block=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_constructor_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_constant=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_method_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_switch=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation_type_member_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_catch=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_if=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_parenthesized_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_switch=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_synchronized=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_try=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_while=insert
+org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_return=insert
+org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_throw=insert
+org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_semicolon=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_try_resources=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_unary_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_brackets_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_annotation_type_member_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.join_lines_in_comments=true
+org.eclipse.jdt.core.formatter.join_wrapped_lines=false
+org.eclipse.jdt.core.formatter.keep_else_statement_on_same_line=false
+org.eclipse.jdt.core.formatter.keep_empty_array_initializer_on_one_line=false
+org.eclipse.jdt.core.formatter.keep_imple_if_on_one_line=false
+org.eclipse.jdt.core.formatter.keep_then_statement_on_same_line=false
+org.eclipse.jdt.core.formatter.lineSplit=250
+org.eclipse.jdt.core.formatter.never_indent_block_comments_on_first_column=false
+org.eclipse.jdt.core.formatter.never_indent_line_comments_on_first_column=false
+org.eclipse.jdt.core.formatter.number_of_blank_lines_at_beginning_of_method_body=0
+org.eclipse.jdt.core.formatter.number_of_empty_lines_to_preserve=1
+org.eclipse.jdt.core.formatter.put_empty_statement_on_new_line=true
+org.eclipse.jdt.core.formatter.tabulation.char=space
+org.eclipse.jdt.core.formatter.tabulation.size=4
+org.eclipse.jdt.core.formatter.use_on_off_tags=false
+org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false
+org.eclipse.jdt.core.formatter.wrap_before_binary_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_or_operator_multicatch=true
+org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core/.settings/org.eclipse.jdt.ui.prefs b/lttng/org.eclipse.tracecompass.lttng2.kernel.core/.settings/org.eclipse.jdt.ui.prefs
new file mode 100644 (file)
index 0000000..232a3fd
--- /dev/null
@@ -0,0 +1,60 @@
+eclipse.preferences.version=1
+editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true
+formatter_profile=_tmf-style
+formatter_settings_version=12
+org.eclipse.jdt.ui.exception.name=e
+org.eclipse.jdt.ui.gettersetter.use.is=true
+org.eclipse.jdt.ui.keywordthis=false
+org.eclipse.jdt.ui.overrideannotation=true
+sp_cleanup.add_default_serial_version_id=true
+sp_cleanup.add_generated_serial_version_id=false
+sp_cleanup.add_missing_annotations=false
+sp_cleanup.add_missing_deprecated_annotations=true
+sp_cleanup.add_missing_methods=false
+sp_cleanup.add_missing_nls_tags=false
+sp_cleanup.add_missing_override_annotations=true
+sp_cleanup.add_missing_override_annotations_interface_methods=true
+sp_cleanup.add_serial_version_id=false
+sp_cleanup.always_use_blocks=true
+sp_cleanup.always_use_parentheses_in_expressions=false
+sp_cleanup.always_use_this_for_non_static_field_access=false
+sp_cleanup.always_use_this_for_non_static_method_access=false
+sp_cleanup.convert_to_enhanced_for_loop=false
+sp_cleanup.correct_indentation=false
+sp_cleanup.format_source_code=false
+sp_cleanup.format_source_code_changes_only=false
+sp_cleanup.make_local_variable_final=false
+sp_cleanup.make_parameters_final=false
+sp_cleanup.make_private_fields_final=true
+sp_cleanup.make_type_abstract_if_missing_method=false
+sp_cleanup.make_variable_declarations_final=false
+sp_cleanup.never_use_blocks=false
+sp_cleanup.never_use_parentheses_in_expressions=true
+sp_cleanup.on_save_use_additional_actions=true
+sp_cleanup.organize_imports=false
+sp_cleanup.qualify_static_field_accesses_with_declaring_class=false
+sp_cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=true
+sp_cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=true
+sp_cleanup.qualify_static_member_accesses_with_declaring_class=false
+sp_cleanup.qualify_static_method_accesses_with_declaring_class=false
+sp_cleanup.remove_private_constructors=true
+sp_cleanup.remove_trailing_whitespaces=true
+sp_cleanup.remove_trailing_whitespaces_all=true
+sp_cleanup.remove_trailing_whitespaces_ignore_empty=false
+sp_cleanup.remove_unnecessary_casts=false
+sp_cleanup.remove_unnecessary_nls_tags=false
+sp_cleanup.remove_unused_imports=false
+sp_cleanup.remove_unused_local_variables=false
+sp_cleanup.remove_unused_private_fields=true
+sp_cleanup.remove_unused_private_members=false
+sp_cleanup.remove_unused_private_methods=true
+sp_cleanup.remove_unused_private_types=true
+sp_cleanup.sort_members=false
+sp_cleanup.sort_members_all=false
+sp_cleanup.use_blocks=true
+sp_cleanup.use_blocks_only_for_return_and_throw=false
+sp_cleanup.use_parentheses_in_expressions=false
+sp_cleanup.use_this_for_non_static_field_access=false
+sp_cleanup.use_this_for_non_static_field_access_only_if_necessary=true
+sp_cleanup.use_this_for_non_static_method_access=false
+sp_cleanup.use_this_for_non_static_method_access_only_if_necessary=true
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core/.settings/org.eclipse.pde.api.tools.prefs b/lttng/org.eclipse.tracecompass.lttng2.kernel.core/.settings/org.eclipse.pde.api.tools.prefs
new file mode 100644 (file)
index 0000000..acc3abd
--- /dev/null
@@ -0,0 +1,97 @@
+ANNOTATION_ELEMENT_TYPE_ADDED_METHOD_WITHOUT_DEFAULT_VALUE=Error
+ANNOTATION_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+ANNOTATION_ELEMENT_TYPE_REMOVED_FIELD=Error
+ANNOTATION_ELEMENT_TYPE_REMOVED_METHOD=Error
+ANNOTATION_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_API_TYPE=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_API_TYPE=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_TYPE=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_TYPE=Error
+API_USE_SCAN_FIELD_SEVERITY=Error
+API_USE_SCAN_METHOD_SEVERITY=Error
+API_USE_SCAN_TYPE_SEVERITY=Error
+CLASS_ELEMENT_TYPE_ADDED_METHOD=Error
+CLASS_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
+CLASS_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+CLASS_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
+CLASS_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+CLASS_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
+CLASS_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
+CLASS_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+CLASS_ELEMENT_TYPE_REMOVED_CONSTRUCTOR=Error
+CLASS_ELEMENT_TYPE_REMOVED_FIELD=Error
+CLASS_ELEMENT_TYPE_REMOVED_METHOD=Error
+CLASS_ELEMENT_TYPE_REMOVED_SUPERCLASS=Error
+CLASS_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+CLASS_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+CONSTRUCTOR_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+CONSTRUCTOR_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+CONSTRUCTOR_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
+CONSTRUCTOR_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+ENUM_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
+ENUM_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+ENUM_ELEMENT_TYPE_REMOVED_ENUM_CONSTANT=Error
+ENUM_ELEMENT_TYPE_REMOVED_FIELD=Error
+ENUM_ELEMENT_TYPE_REMOVED_METHOD=Error
+ENUM_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+FIELD_ELEMENT_TYPE_ADDED_VALUE=Error
+FIELD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+FIELD_ELEMENT_TYPE_CHANGED_FINAL_TO_NON_FINAL_STATIC_CONSTANT=Error
+FIELD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
+FIELD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
+FIELD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
+FIELD_ELEMENT_TYPE_CHANGED_TYPE=Error
+FIELD_ELEMENT_TYPE_CHANGED_VALUE=Error
+FIELD_ELEMENT_TYPE_REMOVED_TYPE_ARGUMENT=Error
+FIELD_ELEMENT_TYPE_REMOVED_VALUE=Error
+ILLEGAL_EXTEND=Warning
+ILLEGAL_IMPLEMENT=Warning
+ILLEGAL_INSTANTIATE=Warning
+ILLEGAL_OVERRIDE=Warning
+ILLEGAL_REFERENCE=Warning
+INTERFACE_ELEMENT_TYPE_ADDED_FIELD=Error
+INTERFACE_ELEMENT_TYPE_ADDED_METHOD=Error
+INTERFACE_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
+INTERFACE_ELEMENT_TYPE_ADDED_SUPER_INTERFACE_WITH_METHODS=Error
+INTERFACE_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+INTERFACE_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
+INTERFACE_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_FIELD=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_METHOD=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+INVALID_JAVADOC_TAG=Warning
+INVALID_REFERENCE_IN_SYSTEM_LIBRARIES=Warning
+LEAK_EXTEND=Warning
+LEAK_FIELD_DECL=Warning
+LEAK_IMPLEMENT=Warning
+LEAK_METHOD_PARAM=Warning
+LEAK_METHOD_RETURN_TYPE=Warning
+METHOD_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
+METHOD_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+METHOD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+METHOD_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
+METHOD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
+METHOD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
+METHOD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
+METHOD_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
+METHOD_ELEMENT_TYPE_REMOVED_ANNOTATION_DEFAULT_VALUE=Error
+METHOD_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+MISSING_EE_DESCRIPTIONS=Ignore
+TYPE_PARAMETER_ELEMENT_TYPE_ADDED_CLASS_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_ADDED_INTERFACE_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_CLASS_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_INTERFACE_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_CLASS_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_INTERFACE_BOUND=Error
+UNUSED_PROBLEM_FILTERS=Warning
+automatically_removed_unused_problem_filters=false
+eclipse.preferences.version=1
+incompatible_api_component_version=Error
+incompatible_api_component_version_include_major_without_breaking_change=Disabled
+incompatible_api_component_version_include_minor_without_api_change=Disabled
+invalid_since_tag_version=Error
+malformed_since_tag=Error
+missing_since_tag=Error
+report_api_breakage_when_major_version_incremented=Disabled
+report_resolution_errors_api_component=Warning
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core/.settings/org.eclipse.pde.prefs b/lttng/org.eclipse.tracecompass.lttng2.kernel.core/.settings/org.eclipse.pde.prefs
new file mode 100644 (file)
index 0000000..d92b94f
--- /dev/null
@@ -0,0 +1,32 @@
+compilers.f.unresolved-features=1
+compilers.f.unresolved-plugins=1
+compilers.incompatible-environment=1
+compilers.p.build=1
+compilers.p.build.bin.includes=1
+compilers.p.build.encodings=2
+compilers.p.build.java.compiler=2
+compilers.p.build.java.compliance=1
+compilers.p.build.missing.output=2
+compilers.p.build.output.library=1
+compilers.p.build.source.library=1
+compilers.p.build.src.includes=1
+compilers.p.deprecated=1
+compilers.p.discouraged-class=1
+compilers.p.internal=1
+compilers.p.missing-packages=1
+compilers.p.missing-version-export-package=2
+compilers.p.missing-version-import-package=2
+compilers.p.missing-version-require-bundle=2
+compilers.p.no-required-att=0
+compilers.p.not-externalized-att=1
+compilers.p.unknown-attribute=1
+compilers.p.unknown-class=1
+compilers.p.unknown-element=1
+compilers.p.unknown-identifier=1
+compilers.p.unknown-resource=1
+compilers.p.unresolved-ex-points=0
+compilers.p.unresolved-import=0
+compilers.s.create-docs=false
+compilers.s.doc-folder=doc
+compilers.s.open-tags=1
+eclipse.preferences.version=1
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core/META-INF/MANIFEST.MF b/lttng/org.eclipse.tracecompass.lttng2.kernel.core/META-INF/MANIFEST.MF
new file mode 100644 (file)
index 0000000..1ca10fe
--- /dev/null
@@ -0,0 +1,28 @@
+Manifest-Version: 1.0
+Bundle-ManifestVersion: 2
+Bundle-Name: %Bundle-Name
+Bundle-Vendor: %Bundle-Vendor
+Bundle-Version: 1.0.0.qualifier
+Bundle-Localization: plugin
+Bundle-SymbolicName: org.eclipse.tracecompass.lttng2.kernel.core;singleton:=true
+Bundle-Activator: org.eclipse.tracecompass.internal.lttng2.kernel.core.Activator
+Bundle-ActivationPolicy: lazy
+Bundle-RequiredExecutionEnvironment: JavaSE-1.7
+Require-Bundle: org.eclipse.core.runtime,
+ org.eclipse.core.resources,
+ org.eclipse.tracecompass.common.core,
+ org.eclipse.tracecompass.tmf.core,
+ org.eclipse.tracecompass.tmf.ctf.core,
+ org.eclipse.tracecompass.lttng2.control.core,
+ org.eclipse.tracecompass.analysis.os.linux.core
+Export-Package: org.eclipse.tracecompass.internal.lttng2.kernel.core;x-friends:="org.eclipse.tracecompass.lttng2.kernel.ui,org.eclipse.tracecompass.lttng2.kernel.core.tests",
+ org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm;x-friends:="org.eclipse.tracecompass.lttng2.kernel.core.tests,org.eclipse.tracecompass.lttng2.kernel.ui",
+ org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.model;x-friends:="org.eclipse.tracecompass.lttng2.kernel.core.tests,org.eclipse.tracecompass.lttng2.kernel.ui",
+ org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.model.qemukvm;x-friends:="org.eclipse.tracecompass.lttng2.kernel.core.tests,org.eclipse.tracecompass.lttng2.kernel.ui",
+ org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.module;x-friends:="org.eclipse.tracecompass.lttng2.kernel.core.tests,org.eclipse.tracecompass.lttng2.kernel.ui",
+ org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.trace;x-friends:="org.eclipse.tracecompass.lttng2.kernel.ui,org.eclipse.tracecompass.lttng2.kernel.core.tests",
+ org.eclipse.tracecompass.internal.lttng2.kernel.core.event.matching,
+ org.eclipse.tracecompass.internal.lttng2.kernel.core.trace.layout;x-friends:="org.eclipse.tracecompass.lttng2.kernel.core.tests,org.eclipse.tracecompass.lttng2.kernel.ui",
+ org.eclipse.tracecompass.lttng2.kernel.core.trace
+Import-Package: com.google.common.collect,
+ com.google.common.hash;version="15.0.0"
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core/about.html b/lttng/org.eclipse.tracecompass.lttng2.kernel.core/about.html
new file mode 100644 (file)
index 0000000..c258ef5
--- /dev/null
@@ -0,0 +1,28 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"/>
+<title>About</title>
+</head>
+<body lang="EN-US">
+<h2>About This Content</h2>
+<p>June 5, 2006</p>    
+<h3>License</h3>
+
+<p>The Eclipse Foundation makes available all content in this plug-in (&quot;Content&quot;).  Unless otherwise 
+indicated below, the Content is provided to you under the terms and conditions of the
+Eclipse Public License Version 1.0 (&quot;EPL&quot;).  A copy of the EPL is available 
+at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>.
+For purposes of the EPL, &quot;Program&quot; will mean the Content.</p>
+
+<p>If you did not receive this Content directly from the Eclipse Foundation, the Content is 
+being redistributed by another party (&quot;Redistributor&quot;) and different terms and conditions may
+apply to your use of any object code in the Content.  Check the Redistributor's license that was 
+provided with the Content.  If no such license exists, contact the Redistributor.  Unless otherwise
+indicated below, the terms and conditions of the EPL still apply to any source code in the Content
+and such source code may be obtained at <a href="http://www.eclipse.org/">http://www.eclipse.org</a>.</p>
+
+</body>
+</html>
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core/build.properties b/lttng/org.eclipse.tracecompass.lttng2.kernel.core/build.properties
new file mode 100644 (file)
index 0000000..244c9d8
--- /dev/null
@@ -0,0 +1,22 @@
+###############################################################################
+# Copyright (c) 2013, 2014 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:
+#     Ericsson - Initial API and implementation
+###############################################################################
+
+source.. = src/
+output.. = bin/
+bin.includes = META-INF/,\
+               .,\
+               about.html,\
+               plugin.properties,\
+               plugin.xml
+src.includes = about.html
+additional.bundles = org.eclipse.jdt.annotation
+jars.extra.classpath = platform:/plugin/org.eclipse.jdt.annotation
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core/plugin.properties b/lttng/org.eclipse.tracecompass.lttng2.kernel.core/plugin.properties
new file mode 100644 (file)
index 0000000..b5bafe2
--- /dev/null
@@ -0,0 +1,20 @@
+###############################################################################
+# Copyright (c) 2013, 2014 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:
+#     Ericsson - Initial API and implementation
+###############################################################################
+
+Bundle-Vendor = Eclipse Trace Compass
+Bundle-Name = Trace Compass LTTng Kernel Analysis Core Plug-in
+
+tracetype.type.kernel = Linux Kernel Trace
+analysis.lttngkernel = Linux Kernel Analysis
+
+cpuusage.lttng.kernel = CPU usage
+
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core/plugin.xml b/lttng/org.eclipse.tracecompass.lttng2.kernel.core/plugin.xml
new file mode 100644 (file)
index 0000000..5271045
--- /dev/null
@@ -0,0 +1,33 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<?eclipse version="3.4"?>
+<plugin>
+   <extension
+         point="org.eclipse.linuxtools.tmf.core.tracetype">
+      <type
+            category="org.eclipse.linuxtools.tmf.ctf.core.category.ctf"
+            event_type="org.eclipse.tracecompass.tmf.ctf.core.event.CtfTmfEvent"
+            id="org.eclipse.linuxtools.lttng2.kernel.tracetype"
+            isDirectory="true"
+            name="%tracetype.type.kernel"
+            trace_type="org.eclipse.tracecompass.lttng2.kernel.core.trace.LttngKernelTrace">
+      </type>
+      <experiment
+            experiment_type="org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.trace.VirtualMachineExperiment"
+            id="lttng2.analysis.vm.VirtualMachineExperiment"
+            name="Virtual Machine Experiment">
+      </experiment>
+   </extension>
+   <extension
+         point="org.eclipse.linuxtools.tmf.core.analysis">
+      <module
+            analysis_module="org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.module.VirtualMachineCpuAnalysis"
+            automatic="false"
+            id="lttng2.analysis.vm.core.VirtualMachineAnalysisModule"
+            name="Virtual Machine Analysis">
+            <tracetype
+                  applies="true"
+                  class="org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.trace.VirtualMachineExperiment">
+            </tracetype>
+      </module>
+   </extension>
+</plugin>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core/pom.xml b/lttng/org.eclipse.tracecompass.lttng2.kernel.core/pom.xml
new file mode 100644 (file)
index 0000000..896dc89
--- /dev/null
@@ -0,0 +1,36 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+   Copyright (C) 2011, Red Hat, Inc.
+
+   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
+-->
+<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>
+    <artifactId>org.eclipse.tracecompass.lttng-parent</artifactId>
+    <groupId>org.eclipse.tracecompass</groupId>
+    <version>1.0.0-SNAPSHOT</version>
+  </parent>
+
+  <artifactId>org.eclipse.tracecompass.lttng2.kernel.core</artifactId>
+  <version>1.0.0-SNAPSHOT</version>
+  <packaging>eclipse-plugin</packaging>
+
+  <name>Trace Compass LTTng Kernel Analysis Core Plug-in</name>
+
+ <build>
+    <plugins>
+      <plugin>
+        <groupId>org.eclipse.tycho</groupId>
+        <artifactId>tycho-source-plugin</artifactId>
+      </plugin>
+    </plugins>
+  </build>
+
+ <groupId>org.eclipse.tracecompass</groupId>
+</project>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/Activator.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/Activator.java
new file mode 100644 (file)
index 0000000..e7f7765
--- /dev/null
@@ -0,0 +1,142 @@
+/*******************************************************************************
+ * Copyright (c) 2012, 2015 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:
+ *   Francois Chouinard - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.kernel.core;
+
+import org.eclipse.core.runtime.IStatus;
+import org.eclipse.core.runtime.Plugin;
+import org.eclipse.core.runtime.Status;
+import org.eclipse.tracecompass.internal.lttng2.kernel.core.event.matching.TcpEventMatching;
+import org.eclipse.tracecompass.internal.lttng2.kernel.core.event.matching.TcpLttngEventMatching;
+import org.eclipse.tracecompass.tmf.core.event.matching.TmfEventMatching;
+import org.osgi.framework.BundleContext;
+
+/**
+ * <b><u>Activator</u></b>
+ * <p>
+ * The activator class controls the plug-in life cycle
+ */
+public class Activator extends Plugin {
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+
+    /**
+     * The plug-in ID
+     */
+    public static final String PLUGIN_ID = "org.eclipse.tracecompass.lttng2.kernel.core"; //$NON-NLS-1$
+
+    /**
+     * The shared instance
+     */
+    private static Activator plugin;
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+
+    /**
+     * The constructor
+     */
+    public Activator() {
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    /**
+     * Returns the shared instance
+     *
+     * @return the shared instance
+     */
+    public static Activator getDefault() {
+        return plugin;
+    }
+
+    // ------------------------------------------------------------------------
+    // Operators
+    // ------------------------------------------------------------------------
+
+    @Override
+    public void start(BundleContext context) throws Exception {
+        super.start(context);
+        plugin = this;
+        TmfEventMatching.registerMatchObject(new TcpEventMatching());
+        TmfEventMatching.registerMatchObject(new TcpLttngEventMatching());
+    }
+
+    @Override
+    public void stop(BundleContext context) throws Exception {
+        plugin = null;
+        super.stop(context);
+    }
+
+    /**
+     * Logs a message with severity INFO in the runtime log of the plug-in.
+     *
+     * @param message A message to log
+     */
+    public void logInfo(String message) {
+        getLog().log(new Status(IStatus.INFO, PLUGIN_ID, message));
+    }
+
+    /**
+     * Logs a message and exception with severity INFO in the runtime log of the plug-in.
+     *
+     * @param message A message to log
+     * @param exception A exception to log
+     */
+    public void logInfo(String message, Throwable exception) {
+        getLog().log(new Status(IStatus.INFO, PLUGIN_ID, message, exception));
+    }
+
+    /**
+     * Logs a message and exception with severity WARNING in the runtime log of the plug-in.
+     *
+     * @param message A message to log
+     */
+    public void logWarning(String message) {
+        getLog().log(new Status(IStatus.WARNING, PLUGIN_ID, message));
+    }
+
+    /**
+     * Logs a message and exception with severity WARNING in the runtime log of the plug-in.
+     *
+     * @param message A message to log
+     * @param exception A exception to log
+     */
+    public void logWarning(String message, Throwable exception) {
+        getLog().log(new Status(IStatus.WARNING, PLUGIN_ID, message, exception));
+    }
+
+    /**
+     * Logs a message and exception with severity ERROR in the runtime log of the plug-in.
+     *
+     * @param message A message to log
+     */
+    public void logError(String message) {
+        getLog().log(new Status(IStatus.ERROR, PLUGIN_ID, message));
+    }
+
+    /**
+     * Logs a message and exception with severity ERROR in the runtime log of the plug-in.
+     *
+     * @param message A message to log
+     * @param exception A exception to log
+     */
+    public void logError(String message, Throwable exception) {
+        getLog().log(new Status(IStatus.ERROR, PLUGIN_ID, message, exception));
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/TcpEventStrings.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/TcpEventStrings.java
new file mode 100644 (file)
index 0000000..dd9fd3c
--- /dev/null
@@ -0,0 +1,60 @@
+/*******************************************************************************
+ * Copyright (c) 2013, 2014 École Polytechnique de Montréal
+ *
+ * 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:
+ *   Geneviève Bastien - Initial API and implementation
+ ******************************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.kernel.core;
+
+/**
+ * This file defines all the known event and field names used to trace socket
+ * connection for both the addons module method (
+ * {@link org.eclipse.tracecompass.internal.lttng2.kernel.core.event.matching.TcpEventMatching}
+ * ) and the net_data_experimental branch (
+ * {@link org.eclipse.tracecompass.internal.lttng2.kernel.core.event.matching.TcpLttngEventMatching}
+ * ).
+ *
+ * These events should be eventually mainlined and when this happens, this class
+ * won't be necessary anymore and they should be moved to {@link LttngStrings}
+ * class
+ *
+ *
+ * @author Geneviève Bastien
+ */
+@SuppressWarnings({ "javadoc", "nls" })
+public interface TcpEventStrings {
+
+    /* Event names */
+    public static final String INET_CONNECT = "inet_connect";
+    public static final String INET_SOCK_CREATE = "inet_sock_create";
+    public static final String INET_SOCK_LOCAL_OUT = "inet_sock_local_out";
+    public static final String INET_SOCK_LOCAL_IN = "inet_sock_local_in";
+    public static final String INET_SOCK_CLONE = "inet_sock_clone";
+    public static final String INET_ACCEPT = "inet_accept";
+    public static final String INET_SOCK_DELETE = "inet_sock_delete";
+    public static final String NETIF_RECEIVE_SKB = "netif_receive_skb";
+    public static final String NET_DEV_QUEUE = "net_dev_queue";
+
+    /* Field names */
+    public static final String SEQ = "seq";
+    public static final String SK = "sk";
+    public static final String OSK = "osk";
+    public static final String NSK = "nsk";
+    public static final String SPORT = "sport";
+    public static final String DPORT = "dport";
+    public static final String SADDR = "saddr";
+    public static final String DADDR = "daddr";
+    public static final String ACKSEQ = "ack_seq";
+    public static final String CHECK = "check";
+    public static final String WINDOW = "window";
+    public static final String FLAGS = "flags";
+    public static final String TRANSPORT_FIELDS = "transport_fields";
+    public static final String TYPE_TCP = "thtype_tcp";
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/VcpuStateValues.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/VcpuStateValues.java
new file mode 100644 (file)
index 0000000..445b3b7
--- /dev/null
@@ -0,0 +1,35 @@
+/*******************************************************************************
+ * Copyright (c) 2014 École Polytechnique de Montréal
+ *
+ * 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:
+ *   Mohamad Gebai - Initial API and implementation
+ *   Geneviève Bastien - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm;
+
+/**
+ * State system values used by the VM analysis
+ *
+ * @author Mohamad Gebai
+ */
+public interface VcpuStateValues {
+
+    /* VCPU Status */
+    /** The virtual CPU state is unknown */
+    int VCPU_UNKNOWN = 0;
+    /** The virtual CPU is idle */
+    int VCPU_IDLE = 1;
+    /** The virtual CPU is running */
+    int VCPU_RUNNING = 2;
+    /** Flag for when the virtual CPU is in hypervisor mode */
+    int VCPU_VMM = 128;
+    /** Flag for when the virtual CPU is preempted */
+    int VCPU_PREEMPT = 256;
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/VmAttributes.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/VmAttributes.java
new file mode 100644 (file)
index 0000000..6e18a0b
--- /dev/null
@@ -0,0 +1,30 @@
+/*******************************************************************************
+ * Copyright (c) 2014 École Polytechnique de Montréal
+ *
+ * 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:
+ *   Mohamad Gebai - Initial API and implementation
+ *   Geneviève Bastien - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm;
+
+/**
+ * Attributes used by the VM Analysis
+ *
+ * @author Mohamad Gebai
+ */
+@SuppressWarnings({"nls"})
+public interface VmAttributes {
+
+    /** First-level attributes */
+    String VIRTUAL_MACHINES = "Virtual Machines";
+
+    /** Sub-attributes for virtual CPUs */
+    String STATUS = "Status";
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/model/IVirtualMachineModel.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/model/IVirtualMachineModel.java
new file mode 100644 (file)
index 0000000..4b226c5
--- /dev/null
@@ -0,0 +1,119 @@
+/*******************************************************************************
+ * Copyright (c) 2014 École Polytechnique de Montréal
+ *
+ * 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:
+ *   Geneviève Bastien - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.model;
+
+import java.util.Set;
+
+import org.eclipse.jdt.annotation.Nullable;
+import org.eclipse.tracecompass.analysis.os.linux.core.model.HostThread;
+import org.eclipse.tracecompass.tmf.core.event.ITmfEvent;
+
+/**
+ * Interface that represents the model of an hypervisor. Each hypervisor (or
+ * tracing method for an hypervisor) should implement this.
+ *
+ * @author Geneviève Bastien
+ */
+public interface IVirtualMachineModel {
+
+    /**
+     * Get the machine that ran this event
+     *
+     * @param event
+     *            The trace event
+     * @return The machine this event was run on or {@code null} if the machine
+     *         is not one belonging to this model.
+     */
+    @Nullable
+    VirtualMachine getCurrentMachine(ITmfEvent event);
+
+    /**
+     * Get a the set of events required for this model to apply.
+     *
+     * TODO: This should be updated to something else to fit the event layout
+     * generic linux model
+     *
+     * @return The set of required events for this model
+     */
+    Set<String> getRequiredEvents();
+
+    /**
+     * Get the virtual CPU that is entering hypervisor mode with this event.
+     *
+     * "Hypervisor mode" means the virtual CPU of the guest is running on the
+     * host, but it is not running code from the guest, but rather other tasks
+     * from the hypervisor. When hypervisor mode is entered, the process on the
+     * host stops running guest code, so from the guest point of view, the
+     * thread running on this CPU is preempted.
+     *
+     * @param event
+     *            The event being handled
+     * @param ht
+     *            The current thread this event belongs to
+     * @return The virtual CPU entering hypervisor mode or {@code null} if the
+     *         hypervisor is not being entered with this event.
+     */
+    @Nullable
+    VirtualCPU getVCpuEnteringHypervisorMode(ITmfEvent event, HostThread ht);
+
+    /**
+     * Get the virtual CPU that is exiting hypervisor mode with this event.
+     *
+     * "Hypervisor mode" means the virtual CPU of the guest is running on the
+     * host, but it is not running code from the guest, but rather other tasks
+     * from the hypervisor. When hypervisor mode is exited, the process on the
+     * host runs guest code, so from the guest point of view, the thread running
+     * on this CPU is actively running.
+     *
+     * @param event
+     *            The event being handled
+     * @param ht
+     *            The current thread this event belongs to
+     * @return The virutal CPU exiting hypervisor mode or {@code null} if the
+     *         hypervisor is not exiting with this event.
+     */
+    @Nullable
+    VirtualCPU getVCpuExitingHypervisorMode(ITmfEvent event, HostThread ht);
+
+    /**
+     * Get the virtual CPU from a guest that corresponds to a specific thread
+     * from the host
+     *
+     * @param event
+     *            The event being handled
+     * @param ht
+     *            The current thread this event belongs to. This thread should
+     *            be running on the host.
+     * @return The virtual CPU corresponding to this thread or {@code null} if
+     *         no virtual CPU corresponds to the thread
+     */
+    @Nullable
+    VirtualCPU getVirtualCpu(HostThread ht);
+
+    /**
+     * Handles the event. This method will be called for each event required or
+     * optional by the analysis, before any other handling is done on this
+     * event.
+     *
+     * This is where each implementation of the model will build itself,
+     * determine which guests are running on which hosts and get the necessary
+     * information to be able to return the virtual CPUs requested by the other
+     * methods of this interface.
+     *
+     * @param event
+     *            The event being handled. It can come from any trace in the
+     *            experiment
+     */
+    void handleEvent(ITmfEvent event);
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/model/VirtualCPU.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/model/VirtualCPU.java
new file mode 100644 (file)
index 0000000..bb5f974
--- /dev/null
@@ -0,0 +1,79 @@
+/*******************************************************************************
+ * Copyright (c) 2014 École Polytechnique de Montréal
+ *
+ * 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:
+ *   Geneviève Bastien - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.model;
+
+import org.eclipse.tracecompass.common.core.NonNullUtils;
+
+import com.google.common.collect.HashBasedTable;
+import com.google.common.collect.Table;
+
+/**
+ * This class represents a virtual CPU, which is a CPU running on a guest. It
+ * associates the guest CPU ID to a virtual machine of the model.
+ *
+ * @author Geneviève Bastien
+ */
+public class VirtualCPU {
+
+    private static final Table<VirtualMachine, Long, VirtualCPU> VIRTUAL_CPU_TABLE = NonNullUtils.checkNotNull(HashBasedTable.<VirtualMachine, Long, VirtualCPU> create());
+
+    private final VirtualMachine fVm;
+    private final Long fCpuId;
+
+    /**
+     * Return the virtual CPU for to the virtual machine and requested CPU ID
+     *
+     * @param vm
+     *            The virtual machine
+     * @param cpu
+     *            the CPU number
+     * @return the virtual CPU
+     */
+    public static synchronized VirtualCPU getVirtualCPU(VirtualMachine vm, Long cpu) {
+        VirtualCPU ht = VIRTUAL_CPU_TABLE.get(vm, cpu);
+        if (ht == null) {
+            ht = new VirtualCPU(vm, cpu);
+            VIRTUAL_CPU_TABLE.put(vm, cpu, ht);
+        }
+        return ht;
+    }
+
+    private VirtualCPU(VirtualMachine vm, Long cpu) {
+        fVm = vm;
+        fCpuId = cpu;
+    }
+
+    /**
+     * Get the CPU ID of this virtual CPU
+     *
+     * @return The zero-based CPU ID
+     */
+    public Long getCpuId() {
+        return fCpuId;
+    }
+
+    /**
+     * Get the virtual machine object this virtual CPU belongs to
+     *
+     * @return The guest Virtual Machine
+     */
+    public VirtualMachine getVm() {
+        return fVm;
+    }
+
+    @Override
+    public String toString() {
+        return "VirtualCPU: [" + fVm + ',' + fCpuId + ']'; //$NON-NLS-1$
+    }
+
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/model/VirtualMachine.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/model/VirtualMachine.java
new file mode 100644 (file)
index 0000000..bf5d54e
--- /dev/null
@@ -0,0 +1,99 @@
+/*******************************************************************************
+ * Copyright (c) 2014 École Polytechnique de Montréal
+ *
+ * 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:
+ *   Geneviève Bastien - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.model;
+
+/**
+ * This class represents a machine, host or guest, in a virtual machine model. A
+ * machine is identified by a trace's host ID.
+ *
+ * @author Geneviève Bastien
+ */
+public class VirtualMachine {
+
+    private static enum MachineType {
+        HOST,
+        GUEST
+    }
+
+    private final long fVmUid;
+    private final String fHostId;
+    private final MachineType fType;
+
+    /**
+     * Create a new host machine. A host is a physical machine that may contain
+     * virtual guest machines.
+     *
+     * @param hostId
+     *            The host ID of the trace(s) this machine represents
+     * @return A {@link VirtualMachine} of type host
+     */
+    public static VirtualMachine newHostMachine(String hostId) {
+        return new VirtualMachine(MachineType.HOST, hostId, -1);
+    }
+
+    /**
+     * Create a new guest machine. A guest is a virtual machine with virtual
+     * CPUs running on a host.
+     *
+     * @param uid
+     *            Some unique identifier of this guest machine that can be used
+     *            in both the guest and the host to match both machines.
+     * @param hostId
+     *            The host ID of the trace(s) this machine represents
+     * @return A {@link VirtualMachine} of type guest.
+     */
+    public static VirtualMachine newGuestMachine(long uid, String hostId) {
+        return new VirtualMachine(MachineType.GUEST, hostId, uid);
+    }
+
+    private VirtualMachine(MachineType type, String hostId, long uid) {
+        fType = type;
+        fVmUid = uid;
+        fHostId = hostId;
+    }
+
+    /**
+     * Return whether this machine is a guest or a host
+     *
+     * @return {@code true} if the machine is a guest, or {@code false} if it is
+     *         a host
+     */
+    public boolean isGuest() {
+        return fType == MachineType.GUEST;
+    }
+
+    /**
+     * Get the unique identifier that is used between the host and the guest to
+     * identify this machine.
+     *
+     * @return The Virtual Machine unique ID.
+     */
+    public long getVmUid() {
+        return fVmUid;
+    }
+
+    /**
+     * Get the host ID of this machine
+     *
+     * @return The host ID of this machine
+     */
+    public String getHostId() {
+        return fHostId;
+    }
+
+    @Override
+    public String toString() {
+        return "VirtualMachine: " + fHostId; //$NON-NLS-1$
+    }
+
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/model/package-info.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/model/package-info.java
new file mode 100644 (file)
index 0000000..b30f2be
--- /dev/null
@@ -0,0 +1,14 @@
+/*******************************************************************************
+ * Copyright (c) 2014 École Polytechnique de Montréal
+ *
+ * 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:
+ *    École Polytechnique de Montréal - Initial API and implementation
+ *******************************************************************************/
+
+@org.eclipse.jdt.annotation.NonNullByDefault
+package org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.model;
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/model/qemukvm/QemuKvmStrings.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/model/qemukvm/QemuKvmStrings.java
new file mode 100644 (file)
index 0000000..e7adb1d
--- /dev/null
@@ -0,0 +1,75 @@
+/*******************************************************************************
+ * Copyright (c) 2014 École Polytechnique de Montréal
+ *
+ * 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:
+ *   Mohamad Gebai - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.model.qemukvm;
+
+/**
+ * Lttng specific strings for the events used by the Qemu/KVM virtual machine
+ * model
+ *
+ * TODO: The whole model should be updated to use the linux event layout. These
+ * event names are LTTng-specific
+ *
+ * @author Mohamad Gebai
+ */
+@SuppressWarnings({ "nls" })
+public interface QemuKvmStrings {
+
+    /* vmsync events */
+
+    /**
+     * Event produced by the host, for a message sent from the guest, received
+     * by the host
+     */
+    String VMSYNC_GH_HOST = "vmsync_gh_host";
+    /**
+     * Event produced by the host, for a message sent from the host, received by
+     * the guest
+     */
+    String VMSYNC_HG_HOST = "vmsync_hg_host";
+    /**
+     * Event produced by the guest, for a message sent from the guest, received
+     * by the host
+     */
+    String VMSYNC_GH_GUEST = "vmsync_gh_guest";
+    /**
+     * Event produced by the guest, for a message sent from the host, received
+     * by the guest
+     */
+    String VMSYNC_HG_GUEST = "vmsync_hg_guest";
+    /**
+     * Event field of previous events, containing a message counter, updated at
+     * each message
+     */
+    String COUNTER_PAYLOAD = "cnt";
+    /**
+     * Event field of previous events, with a unique UID to identify a single
+     * guest on a host
+     */
+    String VM_UID_PAYLOAD = "vm_uid";
+
+    /* kvm entry/exit events */
+    /**
+     * KVM kernel event indicating that virtual machine code is being run
+     */
+    String KVM_ENTRY = "kvm_entry";
+    /**
+     * KVM kernel event indicating that virtual machine code is not run anymore,
+     * but rather hypervisor-specific code
+     */
+    String KVM_EXIT = "kvm_exit";
+    /**
+     * Field from kvm_entry event indicating which virtual CPU is being run
+     */
+    String VCPU_ID = "vcpu_id";
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/model/qemukvm/QemuKvmVmModel.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/model/qemukvm/QemuKvmVmModel.java
new file mode 100644 (file)
index 0000000..c39cd65
--- /dev/null
@@ -0,0 +1,263 @@
+/*******************************************************************************
+ * Copyright (c) 2014, 2015 École Polytechnique de Montréal
+ *
+ * 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:
+ *   Mohamad Gebai - Initial API and implementation
+ *   Geneviève Bastien - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.model.qemukvm;
+
+import java.util.HashMap;
+import java.util.Map;
+import java.util.Map.Entry;
+import java.util.Set;
+
+import org.eclipse.jdt.annotation.Nullable;
+import org.eclipse.tracecompass.analysis.os.linux.core.kernelanalysis.KernelAnalysisModule;
+import org.eclipse.tracecompass.analysis.os.linux.core.kernelanalysis.KernelThreadInformationProvider;
+import org.eclipse.tracecompass.analysis.os.linux.core.model.HostThread;
+import org.eclipse.tracecompass.common.core.NonNullUtils;
+import org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.model.IVirtualMachineModel;
+import org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.model.VirtualCPU;
+import org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.model.VirtualMachine;
+import org.eclipse.tracecompass.tmf.core.event.ITmfEvent;
+import org.eclipse.tracecompass.tmf.core.event.ITmfEventField;
+import org.eclipse.tracecompass.tmf.core.event.TmfEventField;
+import org.eclipse.tracecompass.tmf.core.event.aspect.TmfCpuAspect;
+import org.eclipse.tracecompass.tmf.core.trace.TmfTraceUtils;
+import org.eclipse.tracecompass.tmf.core.trace.experiment.TmfExperiment;
+import org.eclipse.tracecompass.tmf.core.trace.experiment.TmfExperimentUtils;
+
+import com.google.common.collect.ImmutableSet;
+
+/**
+ * The virtual machine model corresponding to the Qemu/KVM hypervisor. It uses
+ * the kvm_exit/kvm_entry events to identify entry to and exit from the
+ * hypervisor. It also requires vmsync_* events from both guests and hosts to
+ * identify which thread from a host belongs to which machine.
+ *
+ * @author Mohamad Gebai
+ */
+public class QemuKvmVmModel implements IVirtualMachineModel {
+
+    private static final String KVM = "kvm_"; //$NON-NLS-1$
+
+    /* Associate a host's thread to a virtual CPU */
+    private final Map<HostThread, VirtualCPU> fTidToVcpu = new HashMap<>();
+    /* Associate a host's thread to a virtual machine */
+    private final Map<HostThread, VirtualMachine> fTidToVm = new HashMap<>();
+    /* Maps a virtual machine name to a virtual machine */
+    private final Map<String, VirtualMachine> fKnownMachines = new HashMap<>();
+
+    private final TmfExperiment fExperiment;
+
+    static final ImmutableSet<String> REQUIRED_EVENTS = NonNullUtils.checkNotNull(ImmutableSet.of(
+            QemuKvmStrings.KVM_ENTRY,
+            QemuKvmStrings.KVM_EXIT,
+            QemuKvmStrings.VMSYNC_GH_GUEST,
+            QemuKvmStrings.VMSYNC_GH_HOST,
+            QemuKvmStrings.VMSYNC_HG_GUEST,
+            QemuKvmStrings.VMSYNC_HG_HOST
+            ));
+
+    /**
+     * Constructor
+     *
+     * @param exp
+     *            The experiment this model applies to
+     */
+    public QemuKvmVmModel(TmfExperiment exp) {
+        fExperiment = exp;
+    }
+
+    @Override
+    public @Nullable VirtualMachine getCurrentMachine(ITmfEvent event) {
+        final String hostId = event.getTrace().getHostId();
+        VirtualMachine machine = fKnownMachines.get(hostId);
+        if (machine != null) {
+            return machine;
+        }
+
+        /*
+         * TODO: This model wouldn't support a machine (same hostId) being both
+         * a guest and a host
+         */
+
+        /*
+         * This code path would be used only at the beginning of the analysis.
+         * Once all the hostIds have been associated with a virtual machine, the
+         * machines are all cached and the method returns earlier
+         */
+        /* Try to get the virtual machine from the event */
+        String eventName = event.getName();
+        if (eventName.startsWith(KVM)) {
+            /* Only the host machine has kvm_* events, so this is a host */
+            machine = VirtualMachine.newHostMachine(hostId);
+        } else if (eventName.equals(QemuKvmStrings.VMSYNC_GH_GUEST) || eventName.equals(QemuKvmStrings.VMSYNC_HG_GUEST)) {
+            /* Those events are only present in the guests */
+            TmfEventField field = (TmfEventField) event.getContent();
+            ITmfEventField data = field.getField(QemuKvmStrings.VM_UID_PAYLOAD);
+            if (data != null) {
+                machine = VirtualMachine.newGuestMachine((Long) data.getValue(), hostId);
+            }
+        }
+        if (machine != null) {
+            /* Associate the machine to the hostID here, for cached access later */
+            fKnownMachines.put(hostId, machine);
+        }
+        return machine;
+    }
+
+    @Override
+    public Set<String> getRequiredEvents() {
+        return REQUIRED_EVENTS;
+    }
+
+    private @Nullable VirtualMachine findVmFromParent(ITmfEvent event, HostThread ht) {
+        /*
+         * Maybe the parent of the current thread has a VM associated, see if we
+         * can infer the VM for this thread
+         */
+        KernelAnalysisModule module = getLttngKernelModuleFor(ht.getHost());
+        if (module == null) {
+            return null;
+        }
+
+        Integer ppid = KernelThreadInformationProvider.getParentPid(module, ht.getTid(), event.getTimestamp().getValue());
+        if (ppid == null) {
+            return null;
+        }
+
+        HostThread parentHt = new HostThread(ht.getHost(), ppid);
+        VirtualMachine vm = fTidToVm.get(parentHt);
+        if (vm == null) {
+            return null;
+        }
+        fTidToVm.put(ht, vm);
+
+        return vm;
+    }
+
+    @Override
+    public @Nullable VirtualCPU getVCpuExitingHypervisorMode(ITmfEvent event, HostThread ht) {
+        final String eventName = event.getName();
+
+        /* TODO: Use event layouts for this part also */
+        /*
+         * The KVM_ENTRY event means we are entering a virtual CPU, so exiting
+         * hypervisor mode
+         */
+        if (!eventName.equals(QemuKvmStrings.KVM_ENTRY)) {
+            return null;
+        }
+
+        /*
+         * Are we entering the hypervisor and if so, which virtual CPU is
+         * concerned?
+         */
+        VirtualMachine vm = fTidToVm.get(ht);
+        if (vm == null) {
+            vm = findVmFromParent(event, ht);
+            if (vm == null) {
+                return null;
+            }
+        }
+        /* Associate this thread with the virtual CPU that is going to be run */
+        final ITmfEventField content = event.getContent();
+        long vcpu_id = (Long) content.getField(QemuKvmStrings.VCPU_ID).getValue();
+
+        VirtualCPU virtualCPU = VirtualCPU.getVirtualCPU(vm, vcpu_id);
+        fTidToVcpu.put(ht, virtualCPU);
+
+        return virtualCPU;
+    }
+
+    @Override
+    public @Nullable VirtualCPU getVCpuEnteringHypervisorMode(ITmfEvent event, HostThread ht) {
+        final String eventName = event.getName();
+        /*
+         * The KVM_EXIT event means we are exiting a virtual CPU, so entering
+         * hypervisor mode
+         */
+        if (!eventName.equals(QemuKvmStrings.KVM_EXIT)) {
+            return null;
+        }
+
+        return getVirtualCpu(ht);
+    }
+
+    @Override
+    public @Nullable VirtualCPU getVirtualCpu(HostThread ht) {
+        return fTidToVcpu.get(ht);
+    }
+
+    @Override
+    public void handleEvent(ITmfEvent event) {
+        /* Is the event handled by this model */
+        final String eventName = event.getName();
+        if (!eventName.equals(QemuKvmStrings.VMSYNC_GH_HOST)) {
+            return;
+        }
+
+        final ITmfEventField content = event.getContent();
+        final long ts = event.getTimestamp().getValue();
+        final String hostId = event.getTrace().getHostId();
+
+        Object cpuObj = TmfTraceUtils.resolveEventAspectOfClassForEvent(event.getTrace(), TmfCpuAspect.class, event);
+        if (cpuObj == null) {
+            /* We couldn't find any CPU information, ignore this event */
+            return;
+        }
+        Integer cpu = (Integer) cpuObj;
+
+        /* Find a virtual machine with the vm uid payload value */
+        ITmfEventField data = content.getField(QemuKvmStrings.VM_UID_PAYLOAD);
+        if (data == null) {
+            return;
+        }
+        long vmUid = (Long) data.getValue();
+        for (Entry<String, VirtualMachine> entry : fKnownMachines.entrySet()) {
+            if (entry.getValue().getVmUid() == vmUid) {
+                /*
+                 * We found the VM being run, let's associate it with the thread
+                 * ID
+                 */
+                KernelAnalysisModule module = getLttngKernelModuleFor(hostId);
+                if (module == null) {
+                    break;
+                }
+                Integer tid = KernelThreadInformationProvider.getThreadOnCpu(module, cpu, ts);
+                if (tid == null) {
+                    /*
+                     * We do not know which process is running at this point. It
+                     * may happen at the beginning of the trace.
+                     */
+                    break;
+                }
+                HostThread ht = new HostThread(hostId, tid);
+                fTidToVm.put(ht, entry.getValue());
+
+                /*
+                 * To make sure siblings are also associated with this VM, also
+                 * add an entry for the parent TID
+                 */
+                Integer ppid = KernelThreadInformationProvider.getParentPid(module, tid, ts);
+                if (ppid != null) {
+                    HostThread parentHt = new HostThread(hostId, ppid);
+                    fTidToVm.put(parentHt, entry.getValue());
+                }
+            }
+        }
+    }
+
+    private @Nullable KernelAnalysisModule getLttngKernelModuleFor(String hostId) {
+        return TmfExperimentUtils.getAnalysisModuleOfClassForHost(fExperiment, hostId, KernelAnalysisModule.class);
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/model/qemukvm/package-info.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/model/qemukvm/package-info.java
new file mode 100644 (file)
index 0000000..7f6debb
--- /dev/null
@@ -0,0 +1,14 @@
+/*******************************************************************************
+ * Copyright (c) 2014 École Polytechnique de Montréal
+ *
+ * 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:
+ *    École Polytechnique de Montréal - Initial API and implementation
+ *******************************************************************************/
+
+@org.eclipse.jdt.annotation.NonNullByDefault
+package org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.model.qemukvm;
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/module/Messages.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/module/Messages.java
new file mode 100644 (file)
index 0000000..b68f7b5
--- /dev/null
@@ -0,0 +1,46 @@
+/*******************************************************************************
+ * Copyright (c) 2014 École Polytechnique de Montréal
+ *
+ * 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:
+ *   Geneviève Bastien - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.module;
+
+import org.eclipse.jdt.annotation.Nullable;
+import org.eclipse.osgi.util.NLS;
+
+/**
+ * Externalized message strings from the LTTng Kernel Analysis
+ *
+ * @author Geneviève Bastien
+ */
+@SuppressWarnings("javadoc")
+public class Messages extends NLS {
+    private static final String BUNDLE_NAME = "org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.module.messages"; //$NON-NLS-1$
+
+    public static @Nullable String VirtualMachineCPUAnalysis_Help;
+
+    static {
+        // initialize resource bundle
+        NLS.initializeMessages(BUNDLE_NAME, Messages.class);
+    }
+
+    private Messages() {
+    }
+
+    /**
+     * Helper method to expose externalized strings as non-null objects.
+     */
+    public static String getMessage(@Nullable String msg) {
+        if (msg == null) {
+            return ""; //$NON-NLS-1$
+        }
+        return msg;
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/module/VirtualMachineCpuAnalysis.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/module/VirtualMachineCpuAnalysis.java
new file mode 100644 (file)
index 0000000..6cc1155
--- /dev/null
@@ -0,0 +1,246 @@
+/*******************************************************************************
+ * Copyright (c) 2014, 2015 École Polytechnique de Montréal
+ *
+ * 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:
+ *   Mohamad Gebai - Initial API and implementation
+ *   Geneviève Bastien - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.module;
+
+import static org.eclipse.tracecompass.common.core.NonNullUtils.checkNotNull;
+
+import java.util.Comparator;
+import java.util.HashSet;
+import java.util.Set;
+
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.jdt.annotation.NonNull;
+import org.eclipse.jdt.annotation.Nullable;
+import org.eclipse.tracecompass.analysis.os.linux.core.kernelanalysis.KernelAnalysisModule;
+import org.eclipse.tracecompass.analysis.os.linux.core.kernelanalysis.KernelThreadInformationProvider;
+import org.eclipse.tracecompass.common.core.NonNullUtils;
+import org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.VcpuStateValues;
+import org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.VmAttributes;
+import org.eclipse.tracecompass.statesystem.core.ITmfStateSystem;
+import org.eclipse.tracecompass.statesystem.core.StateSystemUtils;
+import org.eclipse.tracecompass.statesystem.core.exceptions.AttributeNotFoundException;
+import org.eclipse.tracecompass.statesystem.core.exceptions.StateSystemDisposedException;
+import org.eclipse.tracecompass.statesystem.core.interval.ITmfStateInterval;
+import org.eclipse.tracecompass.statesystem.core.interval.TmfStateInterval;
+import org.eclipse.tracecompass.statesystem.core.statevalue.ITmfStateValue;
+import org.eclipse.tracecompass.statesystem.core.statevalue.TmfStateValue;
+import org.eclipse.tracecompass.tmf.core.analysis.IAnalysisModule;
+import org.eclipse.tracecompass.tmf.core.statesystem.ITmfStateProvider;
+import org.eclipse.tracecompass.tmf.core.statesystem.TmfStateSystemAnalysisModule;
+import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace;
+import org.eclipse.tracecompass.tmf.core.trace.TmfTraceManager;
+import org.eclipse.tracecompass.tmf.core.trace.TmfTraceUtils;
+import org.eclipse.tracecompass.tmf.core.trace.experiment.TmfExperiment;
+import org.eclipse.tracecompass.tmf.core.trace.experiment.TmfExperimentUtils;
+
+import com.google.common.collect.ImmutableSet;
+import com.google.common.collect.Multimap;
+import com.google.common.collect.TreeMultimap;
+
+/**
+ * Module for the virtual machine CPU analysis. It tracks the status of the
+ * virtual CPUs for each guest of the experiment.
+ *
+ * @author Mohamad Gebai
+ * @author Geneviève Bastien
+ */
+public class VirtualMachineCpuAnalysis extends TmfStateSystemAnalysisModule {
+
+    // TODO: Update with event layout when requirements are back */
+    static final Set<String> REQUIRED_EVENTS = NonNullUtils.checkNotNull(ImmutableSet.<String> of(
+            // LttngStrings.SCHED_SWITCH
+            ));
+
+    /* State value for a preempted virtual CPU */
+    private static final ITmfStateValue VCPU_PREEMPT_VALUE = TmfStateValue.newValueInt(VcpuStateValues.VCPU_PREEMPT);
+
+    /**
+     * Constructor
+     */
+    public VirtualMachineCpuAnalysis() {
+        super();
+    }
+
+    @Override
+    protected ITmfStateProvider createStateProvider() {
+        ITmfTrace trace = getTrace();
+        if (!(trace instanceof TmfExperiment)) {
+            throw new IllegalStateException();
+        }
+        return new VirtualMachineStateProvider((TmfExperiment) trace);
+    }
+
+    @Override
+    protected @NonNull StateSystemBackendType getBackendType() {
+        return StateSystemBackendType.FULL;
+    }
+
+    @Override
+    public String getHelpText() {
+        return Messages.getMessage(Messages.VirtualMachineCPUAnalysis_Help);
+    }
+
+    @Override
+    protected Iterable<IAnalysisModule> getDependentAnalyses() {
+        Set<IAnalysisModule> modules = new HashSet<>();
+        /* Depends on the LTTng Kernel analysis modules */
+        for (ITmfTrace trace : TmfTraceManager.getTraceSet(getTrace())) {
+            trace = checkNotNull(trace);
+            for (KernelAnalysisModule module : TmfTraceUtils.getAnalysisModulesOfClass(trace, KernelAnalysisModule.class)) {
+                modules.add(module);
+            }
+        }
+        return modules;
+    }
+
+    private static Multimap<Integer, ITmfStateInterval> createThreadMultimap() {
+
+        /*
+         * Create the multimap for threads with the appropriate comparator
+         * objects for keys and values
+         */
+        final Multimap<Integer, ITmfStateInterval> map = NonNullUtils.checkNotNull(TreeMultimap.<Integer, ITmfStateInterval> create(
+                new Comparator<Integer>() {
+                    @Override
+                    public int compare(@Nullable Integer arg0, @Nullable Integer arg1) {
+                        /*
+                         * Keys do not have to be sorted, just use natural
+                         * sorting
+                         */
+                        if (arg0 == null || arg1 == null) {
+                            return -1;
+                        }
+                        return arg0.compareTo(arg1);
+                    }
+                }, new Comparator<ITmfStateInterval>() {
+                    @Override
+                    public int compare(@Nullable ITmfStateInterval arg0, @Nullable ITmfStateInterval arg1) {
+                        if (arg0 == null || arg1 == null) {
+                            return 0;
+                        }
+                        if (arg1.getStateValue() == VCPU_PREEMPT_VALUE && arg0.getStateValue() != VCPU_PREEMPT_VALUE) {
+                            /*
+                             * For VCPU_PREEMPT state values, the state has to
+                             * be after any other state that it overlaps,
+                             * because those intervals usually decorate the
+                             * other intervals.
+                             */
+                            if (((Long) arg0.getEndTime()).compareTo(arg1.getStartTime()) < 0) {
+                                return -1;
+                            }
+                            return ((Long) arg0.getStartTime()).compareTo(arg1.getEndTime());
+                        }
+                        /* Otherwise, we use ordering by start time */
+                        return (((Long) arg0.getStartTime()).compareTo(arg1.getStartTime()));
+                    }
+                }));
+        return map;
+    }
+
+    /**
+     * Get the status intervals for the threads from a virtual machine. Those
+     * intervals are correlated with the data from the virtual CPU's preemption
+     * status.
+     *
+     * This method uses the Linux Kernel Analysis data for the thread's status
+     * intervals.
+     *
+     * @param vmQuark
+     *            The quark of the virtual machine
+     * @param start
+     *            The start time of the period to get the intervals from
+     * @param end
+     *            The end time of the period to get the intervals from
+     * @param resolution
+     *            The resolution
+     * @param monitor
+     *            A progress monitor for this task
+     * @return A map of status intervals for the machine's threads, including
+     *         preempted intervals. Intervals from the thread status and the CPU
+     *         preemption status overlap and are ordered such that CPU
+     *         preemption intervals are after any interval they overlap with
+     */
+    public Multimap<Integer, ITmfStateInterval> getUpdatedThreadIntervals(int vmQuark, long start, long end, long resolution, IProgressMonitor monitor) {
+
+        final Multimap<Integer, ITmfStateInterval> map = createThreadMultimap();
+
+        ITmfStateSystem ss = getStateSystem();
+        if (ss == null) {
+            return map;
+        }
+        ITmfTrace trace = getTrace();
+        if (!(trace instanceof TmfExperiment)) {
+            return map;
+        }
+
+        String vmHostId = NonNullUtils.checkNotNull(ss.getAttributeName(vmQuark));
+        KernelAnalysisModule kernelModule = TmfExperimentUtils.getAnalysisModuleOfClassForHost((TmfExperiment) trace, vmHostId, KernelAnalysisModule.class);
+        if (kernelModule == null) {
+            return map;
+        }
+
+        /*
+         * Initialize the map with the original status intervals from the kernel
+         * module
+         */
+        for (Integer tid : KernelThreadInformationProvider.getThreadIds(kernelModule)) {
+            if (tid == null) {
+                throw new IllegalStateException();
+            }
+            map.putAll(tid, KernelThreadInformationProvider.getStatusIntervalsForThread(kernelModule, tid, start, end, resolution, monitor));
+            if (monitor.isCanceled()) {
+                return map;
+            }
+        }
+
+        try {
+            /* Correlate thread information with virtual CPU information */
+            for (Integer vcpuQuark : ss.getSubAttributes(vmQuark, false)) {
+                Long virtualCPU = Long.parseLong(ss.getAttributeName(vcpuQuark));
+                Integer statusQuark = ss.getQuarkRelative(vcpuQuark, VmAttributes.STATUS);
+
+                for (ITmfStateInterval cpuInterval : StateSystemUtils.queryHistoryRange(ss, statusQuark, start, end - 1, resolution, monitor)) {
+                    ITmfStateValue stateValue = cpuInterval.getStateValue();
+                    switch (stateValue.getType()) {
+                    case INTEGER:
+                        int value = stateValue.unboxInt();
+                        /*
+                         * If the current CPU is either preempted or in
+                         * hypervisor mode, add preempted intervals to running
+                         * processes
+                         */
+                        if ((value & (VcpuStateValues.VCPU_PREEMPT | VcpuStateValues.VCPU_VMM)) == 0) {
+                            break;
+                        }
+                        Integer threadOnCpu = KernelThreadInformationProvider.getThreadOnCpu(kernelModule, virtualCPU, cpuInterval.getStartTime());
+                        if (threadOnCpu != null) {
+                            map.put(threadOnCpu, new TmfStateInterval(cpuInterval.getStartTime(), cpuInterval.getEndTime(), threadOnCpu, VCPU_PREEMPT_VALUE));
+                        }
+                        break;
+                    case DOUBLE:
+                    case LONG:
+                    case NULL:
+                    case STRING:
+                    default:
+                        break;
+                    }
+
+                }
+            }
+        } catch (AttributeNotFoundException | StateSystemDisposedException e) {
+        }
+        return NonNullUtils.checkNotNull(map);
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/module/VirtualMachineStateProvider.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/module/VirtualMachineStateProvider.java
new file mode 100644 (file)
index 0000000..a39b71c
--- /dev/null
@@ -0,0 +1,365 @@
+/*******************************************************************************
+ * Copyright (c) 2014, 2015 École Polytechnique de Montréal
+ *
+ * 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:
+ *   Mohamad Gebai - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.module;
+
+import static org.eclipse.tracecompass.common.core.NonNullUtils.checkNotNull;
+
+import java.util.HashMap;
+import java.util.Map;
+
+import org.eclipse.jdt.annotation.Nullable;
+import org.eclipse.tracecompass.analysis.os.linux.core.kernelanalysis.KernelAnalysisModule;
+import org.eclipse.tracecompass.analysis.os.linux.core.kernelanalysis.KernelThreadInformationProvider;
+import org.eclipse.tracecompass.analysis.os.linux.core.model.HostThread;
+import org.eclipse.tracecompass.analysis.os.linux.core.trace.IKernelAnalysisEventLayout;
+import org.eclipse.tracecompass.common.core.NonNullUtils;
+import org.eclipse.tracecompass.internal.lttng2.kernel.core.Activator;
+import org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.VcpuStateValues;
+import org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.VmAttributes;
+import org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.model.IVirtualMachineModel;
+import org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.model.VirtualCPU;
+import org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.model.VirtualMachine;
+import org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.model.qemukvm.QemuKvmVmModel;
+import org.eclipse.tracecompass.internal.lttng2.kernel.core.trace.layout.LttngEventLayout;
+import org.eclipse.tracecompass.lttng2.kernel.core.trace.LttngKernelTrace;
+import org.eclipse.tracecompass.statesystem.core.ITmfStateSystemBuilder;
+import org.eclipse.tracecompass.statesystem.core.exceptions.AttributeNotFoundException;
+import org.eclipse.tracecompass.statesystem.core.exceptions.StateValueTypeException;
+import org.eclipse.tracecompass.statesystem.core.exceptions.TimeRangeException;
+import org.eclipse.tracecompass.statesystem.core.statevalue.ITmfStateValue;
+import org.eclipse.tracecompass.statesystem.core.statevalue.TmfStateValue;
+import org.eclipse.tracecompass.tmf.core.event.ITmfEvent;
+import org.eclipse.tracecompass.tmf.core.event.ITmfEventField;
+import org.eclipse.tracecompass.tmf.core.event.aspect.TmfCpuAspect;
+import org.eclipse.tracecompass.tmf.core.statesystem.AbstractTmfStateProvider;
+import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace;
+import org.eclipse.tracecompass.tmf.core.trace.TmfTraceUtils;
+import org.eclipse.tracecompass.tmf.core.trace.experiment.TmfExperiment;
+import org.eclipse.tracecompass.tmf.core.trace.experiment.TmfExperimentUtils;
+
+import com.google.common.collect.HashBasedTable;
+import com.google.common.collect.Table;
+
+/**
+ * This is the state provider which translates the virtual machine experiment
+ * events to a state system.
+ *
+ * Attribute tree:
+ *
+ * <pre>
+ * |- Virtual Machines
+ * |  |- <Guest Host ID> -> Friendly name (trace name)
+ * |  |  |- <VCPU number>
+ * |  |  |  |- Status -> <Status value>
+ * </pre>
+ *
+ * The status value of the VCPUs are either {@link VcpuStateValues#VCPU_IDLE},
+ * {@link VcpuStateValues#VCPU_UNKNOWN} or {@link VcpuStateValues#VCPU_RUNNING}.
+ * Those three values are ORed with flags {@link VcpuStateValues#VCPU_VMM}
+ * and/or {@link VcpuStateValues#VCPU_PREEMPT} to indicate respectively whether
+ * they are in hypervisor mode or preempted on the host.
+ *
+ * @author Mohamad Gebai
+ */
+public class VirtualMachineStateProvider extends AbstractTmfStateProvider {
+
+    /**
+     * Version number of this state provider. Please bump this if you modify the
+     * contents of the generated state history in some way.
+     */
+    private static final int VERSION = 1;
+
+    private static final int SCHED_SWITCH_INDEX = 0;
+
+    /* TODO: An analysis should support many hypervisor models */
+    private IVirtualMachineModel fModel;
+    private final Table<ITmfTrace, String, Integer> fEventNames;
+    private final Map<ITmfTrace, IKernelAnalysisEventLayout> fLayouts;
+
+    // ------------------------------------------------------------------------
+    // Constructor
+    // ------------------------------------------------------------------------
+
+    /**
+     * Constructor
+     *
+     * @param experiment
+     *            The virtual machine experiment
+     */
+    public VirtualMachineStateProvider(TmfExperiment experiment) {
+        super(experiment, "Virtual Machine State Provider"); //$NON-NLS-1$
+
+        fModel = new QemuKvmVmModel(experiment);
+        Table<ITmfTrace, String, Integer> table = NonNullUtils.checkNotNull(HashBasedTable.<ITmfTrace, String, Integer> create());
+        fEventNames = table;
+        fLayouts = new HashMap<>();
+    }
+
+    // ------------------------------------------------------------------------
+    // Event names management
+    // ------------------------------------------------------------------------
+
+    private void buildEventNames(ITmfTrace trace) {
+        IKernelAnalysisEventLayout layout;
+        if (trace instanceof LttngKernelTrace) {
+            layout = ((LttngKernelTrace) trace).getKernelEventLayout();
+        } else {
+            /* Fall-back to the base LttngEventLayout */
+            layout = LttngEventLayout.getInstance();
+        }
+        fLayouts.put(trace, layout);
+        fEventNames.put(trace, layout.eventSchedSwitch(), SCHED_SWITCH_INDEX);
+    }
+
+    // ------------------------------------------------------------------------
+    // IStateChangeInput
+    // ------------------------------------------------------------------------
+
+    @Override
+    public TmfExperiment getTrace() {
+        ITmfTrace trace = super.getTrace();
+        if (trace instanceof TmfExperiment) {
+            return (TmfExperiment) trace;
+        }
+        throw new IllegalStateException("VirtualMachineStateProvider: The associated trace should be an experiment"); //$NON-NLS-1$
+    }
+
+    @Override
+    public int getVersion() {
+        return VERSION;
+    }
+
+    @Override
+    public VirtualMachineStateProvider getNewInstance() {
+        TmfExperiment trace = getTrace();
+        return new VirtualMachineStateProvider(trace);
+    }
+
+    @Override
+    protected void eventHandle(@Nullable ITmfEvent event) {
+        if (event == null) {
+            return;
+        }
+
+        /* Is the event managed by this analysis */
+        final String eventName = event.getName();
+
+        /* TODO When requirements work again, don't hardcode this */
+        if (!eventName.equals("sched_switch") && //$NON-NLS-1$
+                !fModel.getRequiredEvents().contains(eventName)) {
+            return;
+        }
+
+        ITmfStateSystemBuilder ss = checkNotNull(getStateSystemBuilder());
+        ITmfStateValue value;
+
+        final ITmfEventField content = event.getContent();
+        final long ts = event.getTimestamp().getValue();
+        final String hostId = event.getTrace().getHostId();
+        try {
+            /* Do we know this trace's role yet? */
+            VirtualMachine host = fModel.getCurrentMachine(event);
+            if (host == null) {
+                return;
+            }
+
+            /* Make sure guest traces are added to the state system */
+            if (host.isGuest()) {
+                /*
+                 * If event from a guest OS, make sure the guest exists in the
+                 * state system
+                 */
+                int vmQuark = -1;
+                try {
+                    vmQuark = ss.getQuarkRelative(getNodeVirtualMachines(), host.getHostId());
+                } catch (AttributeNotFoundException e) {
+                    /*
+                     * We should enter this catch only once per machine, so it
+                     * is not so costly to do compared with adding the trace's
+                     * name for each guest event
+                     */
+                    vmQuark = ss.getQuarkRelativeAndAdd(getNodeVirtualMachines(), host.getHostId());
+                    TmfStateValue machineName = TmfStateValue.newValueString(event.getTrace().getName());
+                    ss.modifyAttribute(ts, machineName, vmQuark);
+                }
+            }
+
+            /* Have the hypervisor models handle the event first */
+            fModel.handleEvent(event);
+
+            /* Handle the event here */
+            if (!fEventNames.containsRow(event.getTrace())) {
+                buildEventNames(event.getTrace());
+            }
+            Integer idx = fEventNames.get(event.getTrace(), eventName);
+            int intval = (idx == null ? -1 : idx.intValue());
+            switch (intval) {
+            case SCHED_SWITCH_INDEX: // "sched_switch":
+            /*
+             * Fields: string prev_comm, int32 prev_tid, int32 prev_prio, int64
+             * prev_state, string next_comm, int32 next_tid, int32 next_prio
+             */
+            {
+                int prevTid = ((Long) content.getField(fLayouts.get(event.getTrace()).fieldPrevTid()).getValue()).intValue();
+                int nextTid = ((Long) content.getField(fLayouts.get(event.getTrace()).fieldNextTid()).getValue()).intValue();
+
+                if (host.isGuest()) {
+                    /* Get the event's CPU */
+                    Object cpuObj = TmfTraceUtils.resolveEventAspectOfClassForEvent(event.getTrace(), TmfCpuAspect.class, event);
+                    if (cpuObj == null) {
+                        /* We couldn't find any CPU information, ignore this event */
+                        break;
+                    }
+                    Integer cpu = (Integer) cpuObj;
+
+                    /*
+                     * If sched switch is from a guest, just update the status
+                     * of the virtual CPU to either idle or running
+                     */
+                    int curStatusQuark = ss.getQuarkRelativeAndAdd(getNodeVirtualMachines(), host.getHostId(),
+                            cpu.toString(), VmAttributes.STATUS);
+                    value = TmfStateValue.newValueInt(VcpuStateValues.VCPU_IDLE);
+                    if (nextTid > 0) {
+                        value = TmfStateValue.newValueInt(VcpuStateValues.VCPU_RUNNING);
+                    }
+                    ss.modifyAttribute(ts, value, curStatusQuark);
+                    break;
+                }
+
+                /* Event is not from a guest */
+                /* Verify if the previous thread corresponds to a virtual CPU */
+                HostThread ht = new HostThread(hostId, prevTid);
+                VirtualCPU vcpu = fModel.getVirtualCpu(ht);
+
+                /*
+                 * If previous thread is virtual CPU, update status of the
+                 * virtual CPU to preempted
+                 */
+                if (vcpu != null) {
+                    VirtualMachine vm = vcpu.getVm();
+
+                    int curStatusQuark = ss.getQuarkRelativeAndAdd(getNodeVirtualMachines(), vm.getHostId(),
+                            vcpu.getCpuId().toString(), VmAttributes.STATUS);
+
+                    /* Add the preempted flag to the status */
+                    value = ss.queryOngoingState(curStatusQuark);
+                    int newVal = Math.max(VcpuStateValues.VCPU_UNKNOWN, value.unboxInt());
+                    value = TmfStateValue.newValueInt(newVal | VcpuStateValues.VCPU_PREEMPT);
+                    ss.modifyAttribute(ts, value, curStatusQuark);
+                }
+
+                /* Verify if the next thread corresponds to a virtual CPU */
+                ht = new HostThread(hostId, nextTid);
+                vcpu = fModel.getVirtualCpu(ht);
+
+                /*
+                 * If next thread is virtual CPU, update status of the virtual
+                 * CPU the previous status
+                 */
+                if (vcpu != null) {
+                    VirtualMachine vm = vcpu.getVm();
+                    int curStatusQuark = ss.getQuarkRelativeAndAdd(getNodeVirtualMachines(), vm.getHostId(),
+                            vcpu.getCpuId().toString(), VmAttributes.STATUS);
+
+                    /* Remove the preempted flag from the status */
+                    value = ss.queryOngoingState(curStatusQuark);
+                    int newVal = Math.max(VcpuStateValues.VCPU_UNKNOWN, value.unboxInt());
+                    value = TmfStateValue.newValueInt(newVal & ~VcpuStateValues.VCPU_PREEMPT);
+                    ss.modifyAttribute(ts, value, curStatusQuark);
+
+                }
+
+            }
+                break;
+
+            default:
+            /* Other events not covered by the main switch */
+            {
+                HostThread ht = getCurrentHostThread(event, ts);
+                if (ht == null) {
+                    break;
+                }
+
+                /*
+                 * Are we entering the hypervisor mode and if so, which virtual
+                 * CPU is concerned?
+                 */
+                VirtualCPU virtualCpu = fModel.getVCpuEnteringHypervisorMode(event, ht);
+                if (virtualCpu != null) {
+                    /* Add the hypervisor flag to the status */
+                    VirtualMachine vm = virtualCpu.getVm();
+                    int curStatusQuark = ss.getQuarkRelativeAndAdd(getNodeVirtualMachines(), vm.getHostId(),
+                            Long.toString(virtualCpu.getCpuId()), VmAttributes.STATUS);
+                    value = ss.queryOngoingState(curStatusQuark);
+                    int newVal = Math.max(VcpuStateValues.VCPU_UNKNOWN, value.unboxInt());
+                    value = TmfStateValue.newValueInt(newVal | VcpuStateValues.VCPU_VMM);
+                    ss.modifyAttribute(ts, value, curStatusQuark);
+                }
+
+                /*
+                 * Are we exiting the hypervisor mode and if so, which virtual
+                 * CPU is concerned?
+                 */
+                virtualCpu = fModel.getVCpuExitingHypervisorMode(event, ht);
+                if (virtualCpu != null) {
+                    /* Remove the hypervisor flag from the status */
+                    VirtualMachine vm = virtualCpu.getVm();
+                    int curStatusQuark = ss.getQuarkRelativeAndAdd(getNodeVirtualMachines(), vm.getHostId(),
+                            Long.toString(virtualCpu.getCpuId()), VmAttributes.STATUS);
+                    value = ss.queryOngoingState(curStatusQuark);
+                    int newVal = Math.max(VcpuStateValues.VCPU_UNKNOWN, value.unboxInt());
+                    value = TmfStateValue.newValueInt(newVal & ~VcpuStateValues.VCPU_VMM);
+                    ss.modifyAttribute(ts, value, curStatusQuark);
+                }
+
+            }
+                break;
+            }
+
+        } catch (AttributeNotFoundException | TimeRangeException | StateValueTypeException e) {
+            Activator.getDefault().logError("Error handling event in VirtualMachineStateProvider", e); //$NON-NLS-1$
+        }
+    }
+
+    // ------------------------------------------------------------------------
+    // Convenience methods for commonly-used attribute tree locations
+    // ------------------------------------------------------------------------
+
+    private int getNodeVirtualMachines() {
+        return checkNotNull(getStateSystemBuilder()).getQuarkAbsoluteAndAdd(VmAttributes.VIRTUAL_MACHINES);
+    }
+
+    private @Nullable HostThread getCurrentHostThread(ITmfEvent event, long ts) {
+        /* Get the LTTng kernel analysis for the host */
+        String hostId = event.getTrace().getHostId();
+        KernelAnalysisModule module = TmfExperimentUtils.getAnalysisModuleOfClassForHost(getTrace(), hostId, KernelAnalysisModule.class);
+        if (module == null) {
+            return null;
+        }
+
+        /* Get the CPU the event is running on */
+        Object cpuObj = TmfTraceUtils.resolveEventAspectOfClassForEvent(event.getTrace(), TmfCpuAspect.class, event);
+        if (cpuObj == null) {
+            /* We couldn't find any CPU information, ignore this event */
+            return null;
+        }
+        Integer cpu = (Integer) cpuObj;
+
+        Integer currentTid = KernelThreadInformationProvider.getThreadOnCpu(module, cpu, ts);
+        if (currentTid == null) {
+            return null;
+        }
+        return new HostThread(hostId, currentTid);
+    }
+
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/module/messages.properties b/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/module/messages.properties
new file mode 100644 (file)
index 0000000..7f89d62
--- /dev/null
@@ -0,0 +1,13 @@
+###############################################################################
+# Copyright (c) 2014 École Polytechnique de Montréal
+#
+# 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:
+#     Geneviève Bastien - Initial API and implementation
+###############################################################################
+
+VirtualMachineCPUAnalysis_Help=Tracks the state of the virtual CPUs of the guest virtual machine in an experiment. It also interrelate the CPU information with the information from thread status of each guest.
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/module/package-info.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/module/package-info.java
new file mode 100644 (file)
index 0000000..ef9c73e
--- /dev/null
@@ -0,0 +1,14 @@
+/*******************************************************************************
+ * Copyright (c) 2014 École Polytechnique de Montréal
+ *
+ * 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:
+ *    École Polytechnique de Montréal - Initial API and implementation
+ *******************************************************************************/
+
+@org.eclipse.jdt.annotation.NonNullByDefault
+package org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.module;
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/package-info.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/package-info.java
new file mode 100644 (file)
index 0000000..2efb6c7
--- /dev/null
@@ -0,0 +1,14 @@
+/*******************************************************************************
+ * Copyright (c) 2014 École Polytechnique de Montréal
+ *
+ * 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:
+ *    École Polytechnique de Montréal - Initial API and implementation
+ *******************************************************************************/
+
+@org.eclipse.jdt.annotation.NonNullByDefault
+package org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm;
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/trace/VirtualMachineExperiment.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/trace/VirtualMachineExperiment.java
new file mode 100644 (file)
index 0000000..4eef98c
--- /dev/null
@@ -0,0 +1,52 @@
+/*******************************************************************************
+ * Copyright (c) 2014, 2015 École Polytechnique de Montréal
+ *
+ * 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:
+ *   Mohamad Gebai - Initial API and implementation
+ *   Patrick Tasse - Fix experiment name
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.trace;
+
+import static org.eclipse.tracecompass.common.core.NonNullUtils.checkNotNull;
+
+import java.util.Collections;
+import java.util.Set;
+
+import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace;
+import org.eclipse.tracecompass.tmf.core.trace.experiment.TmfExperiment;
+import org.eclipse.tracecompass.tmf.ctf.core.event.CtfTmfEvent;
+
+/**
+ * Experiment class containing traces from physical machine and the virtual
+ * guests running on them.
+ *
+ * @author Mohamad Gebai
+ */
+public class VirtualMachineExperiment extends TmfExperiment {
+
+    /**
+     * Default constructor. Needed by the extension point.
+     */
+    public VirtualMachineExperiment() {
+        this("", checkNotNull(Collections.EMPTY_SET)); //$NON-NLS-1$
+    }
+
+    /**
+     * Constructor with traces and id
+     *
+     * @param id
+     *            The ID of this experiment
+     * @param traces
+     *            The set of traces that are part of this experiment
+     */
+    public VirtualMachineExperiment(String id, Set<ITmfTrace> traces) {
+        super(CtfTmfEvent.class, id, traces.toArray(new ITmfTrace[traces.size()]), TmfExperiment.DEFAULT_INDEX_PAGE_SIZE, null);
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/trace/package-info.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/trace/package-info.java
new file mode 100644 (file)
index 0000000..0bcb5e3
--- /dev/null
@@ -0,0 +1,14 @@
+/*******************************************************************************
+ * Copyright (c) 2014 École Polytechnique de Montréal
+ *
+ * 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:
+ *    École Polytechnique de Montréal - Initial API and implementation
+ *******************************************************************************/
+
+@org.eclipse.jdt.annotation.NonNullByDefault
+package org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.trace;
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/event/matching/TcpEventMatching.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/event/matching/TcpEventMatching.java
new file mode 100644 (file)
index 0000000..2feeb23
--- /dev/null
@@ -0,0 +1,97 @@
+/*******************************************************************************
+ * Copyright (c) 2013, 2014 École Polytechnique de Montréal
+ *
+ * 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:
+ *   Geneviève Bastien - Initial implementation and API
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.kernel.core.event.matching;
+
+import java.util.Set;
+
+import org.eclipse.tracecompass.internal.lttng2.kernel.core.TcpEventStrings;
+import org.eclipse.tracecompass.tmf.core.event.ITmfEvent;
+import org.eclipse.tracecompass.tmf.core.event.ITmfEventField;
+import org.eclipse.tracecompass.tmf.core.event.matching.IEventMatchingKey;
+import org.eclipse.tracecompass.tmf.core.event.matching.ITmfMatchEventDefinition;
+import org.eclipse.tracecompass.tmf.core.event.matching.TcpEventKey;
+import org.eclipse.tracecompass.tmf.core.event.matching.TmfEventMatching.Direction;
+import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace;
+import org.eclipse.tracecompass.tmf.core.trace.ITmfTraceWithPreDefinedEvents;
+import org.eclipse.tracecompass.tmf.core.trace.TmfEventTypeCollectionHelper;
+
+import com.google.common.collect.ImmutableSet;
+
+/**
+ * Class to match tcp type events. This matching class applies to traces
+ * obtained with the 'addons' lttng module. This module can be obtained with
+ * lttng-modules to generate traces at
+ * https://github.com/giraldeau/lttng-modules/tree/addons
+ *
+ * Note: this module only allows to generate traces to be read and analyzed by
+ * TMF, no code from this module is being used here
+ *
+ * @author Geneviève Bastien
+ */
+public class TcpEventMatching implements ITmfMatchEventDefinition {
+
+    private static final ImmutableSet<String> REQUIRED_EVENTS = ImmutableSet.of(
+            TcpEventStrings.INET_SOCK_LOCAL_IN,
+            TcpEventStrings.INET_SOCK_LOCAL_OUT);
+
+    private static boolean canMatchPacket(final ITmfEvent event) {
+        /* Make sure all required fields are present to match with this event */
+        ITmfEventField content = event.getContent();
+        if ((content.getField(TcpEventStrings.SEQ) != null) &&
+                (content.getField(TcpEventStrings.ACKSEQ) != null) && (content.getField(TcpEventStrings.FLAGS) != null)) {
+            return true;
+        }
+        return false;
+    }
+
+    /**
+     * @since 1.0
+     */
+    @Override
+    public Direction getDirection(ITmfEvent event) {
+        String evname = event.getName();
+
+        if (!canMatchPacket(event)) {
+            return null;
+        }
+
+        /* Is the event a tcp socket in or out event */
+        if (evname.equals(TcpEventStrings.INET_SOCK_LOCAL_IN)) {
+            return Direction.CAUSE;
+        } else if (evname.equals(TcpEventStrings.INET_SOCK_LOCAL_OUT)) {
+            return Direction.EFFECT;
+        }
+        return null;
+    }
+
+    @Override
+    public IEventMatchingKey getEventKey(ITmfEvent event) {
+        IEventMatchingKey key = new TcpEventKey((long) event.getContent().getField(TcpEventStrings.SEQ).getValue(),
+                (long) event.getContent().getField(TcpEventStrings.ACKSEQ).getValue(),
+                (long) event.getContent().getField(TcpEventStrings.FLAGS).getValue());
+        return key;
+    }
+
+    @Override
+    public boolean canMatchTrace(ITmfTrace trace) {
+        if (!(trace instanceof ITmfTraceWithPreDefinedEvents)) {
+            return true;
+        }
+        ITmfTraceWithPreDefinedEvents ktrace = (ITmfTraceWithPreDefinedEvents) trace;
+
+        Set<String> traceEvents = TmfEventTypeCollectionHelper.getEventNames(ktrace.getContainedEventTypes());
+        traceEvents.retainAll(REQUIRED_EVENTS);
+        return !traceEvents.isEmpty();
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/event/matching/TcpLttngEventMatching.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/event/matching/TcpLttngEventMatching.java
new file mode 100644 (file)
index 0000000..89ff699
--- /dev/null
@@ -0,0 +1,122 @@
+/*******************************************************************************
+ * Copyright (c) 2013, 2015 École Polytechnique de Montréal
+ *
+ * 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:
+ *   Geneviève Bastien - Initial implementation and API
+ *   Patrick Tasse - Remove getSubField
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.kernel.core.event.matching;
+
+import java.util.Set;
+
+import org.eclipse.jdt.annotation.NonNull;
+import org.eclipse.tracecompass.internal.lttng2.kernel.core.TcpEventStrings;
+import org.eclipse.tracecompass.tmf.core.event.ITmfEvent;
+import org.eclipse.tracecompass.tmf.core.event.ITmfEventField;
+import org.eclipse.tracecompass.tmf.core.event.TmfEventField;
+import org.eclipse.tracecompass.tmf.core.event.matching.IEventMatchingKey;
+import org.eclipse.tracecompass.tmf.core.event.matching.ITmfMatchEventDefinition;
+import org.eclipse.tracecompass.tmf.core.event.matching.TcpEventKey;
+import org.eclipse.tracecompass.tmf.core.event.matching.TmfEventMatching.Direction;
+import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace;
+import org.eclipse.tracecompass.tmf.core.trace.ITmfTraceWithPreDefinedEvents;
+import org.eclipse.tracecompass.tmf.core.trace.TmfEventTypeCollectionHelper;
+
+import com.google.common.collect.ImmutableSet;
+
+/**
+ * Class to match tcp type events. This class applies to traces obtained with
+ * the full network tracepoint data available from an experimental branch of
+ * lttng-modules. This branch is often rebased on lttng-modules master and is
+ * available at
+ * http://git.dorsal.polymtl.ca/~gbastien?p=lttng-modules.git;a=summary
+ * net_data_experimental branch.
+ *
+ * @author Geneviève Bastien
+ */
+public class TcpLttngEventMatching implements ITmfMatchEventDefinition {
+
+    private static final @NonNull String[] KEY_SEQ = { TcpEventStrings.TRANSPORT_FIELDS, TcpEventStrings.TYPE_TCP, TcpEventStrings.SEQ };
+    private static final @NonNull String[] KEY_ACKSEQ = { TcpEventStrings.TRANSPORT_FIELDS, TcpEventStrings.TYPE_TCP, TcpEventStrings.ACKSEQ };
+    private static final @NonNull String[] KEY_FLAGS = { TcpEventStrings.TRANSPORT_FIELDS, TcpEventStrings.TYPE_TCP, TcpEventStrings.FLAGS };
+
+    private static final ImmutableSet<String> REQUIRED_EVENTS = ImmutableSet.of(
+            TcpEventStrings.NET_DEV_QUEUE,
+            TcpEventStrings.NETIF_RECEIVE_SKB);
+
+    private static boolean canMatchPacket(final ITmfEvent event) {
+        TmfEventField field = (TmfEventField) event.getContent();
+
+        String[] tcp_data = { TcpEventStrings.TRANSPORT_FIELDS, TcpEventStrings.TYPE_TCP };
+        ITmfEventField data = field.getField(tcp_data);
+        if (data != null) {
+            return (data.getValue() != null);
+        }
+        return false;
+    }
+
+    @Override
+    public boolean canMatchTrace(ITmfTrace trace) {
+        if (!(trace instanceof ITmfTraceWithPreDefinedEvents)) {
+            return true;
+        }
+        ITmfTraceWithPreDefinedEvents ktrace = (ITmfTraceWithPreDefinedEvents) trace;
+
+        Set<String> traceEvents = TmfEventTypeCollectionHelper.getEventNames(ktrace.getContainedEventTypes());
+        traceEvents.retainAll(REQUIRED_EVENTS);
+        return !traceEvents.isEmpty();
+    }
+
+    /**
+     * @since 1.0
+     */
+    @Override
+    public Direction getDirection(ITmfEvent event) {
+        String evname = event.getName();
+
+        /* Is the event a tcp socket in or out event */
+        if (evname.equals(TcpEventStrings.NETIF_RECEIVE_SKB) && canMatchPacket(event)) {
+            return Direction.CAUSE;
+        } else if (evname.equals(TcpEventStrings.NET_DEV_QUEUE) && canMatchPacket(event)) {
+            return Direction.EFFECT;
+        }
+        return null;
+    }
+
+    @Override
+    public IEventMatchingKey getEventKey(ITmfEvent event) {
+        TmfEventField field = (TmfEventField) event.getContent();
+        ITmfEventField data;
+
+        long seq = -1, ackseq = -1, flags = -1;
+        data = field.getField(KEY_SEQ);
+        if (data != null) {
+            seq = (long) data.getValue();
+        } else {
+            return null;
+        }
+        data = field.getField(KEY_ACKSEQ);
+        if (data != null) {
+            ackseq = (long) data.getValue();
+        } else {
+            return null;
+        }
+        data = field.getField(KEY_FLAGS);
+        if (data != null) {
+            flags = (long) data.getValue();
+        } else {
+            return null;
+        }
+
+        IEventMatchingKey key = new TcpEventKey(seq, ackseq, flags);
+
+        return key;
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/trace/layout/Lttng26EventLayout.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/trace/layout/Lttng26EventLayout.java
new file mode 100644 (file)
index 0000000..34284ce
--- /dev/null
@@ -0,0 +1,52 @@
+/*******************************************************************************
+ * Copyright (c) 2014 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:
+ *   Alexandre Montplaisir - Initial API and implementation
+ ******************************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.kernel.core.trace.layout;
+
+/**
+ * This file defines all the known event and field names for LTTng kernel
+ * traces, for versions of lttng-modules 2.6 and above.
+ *
+ * @author Alexandre Montplaisir
+ */
+public class Lttng26EventLayout extends LttngEventLayout {
+
+    /**
+     * Constructor
+     */
+    protected Lttng26EventLayout() {}
+
+    private static final Lttng26EventLayout INSTANCE = new Lttng26EventLayout();
+
+    public static Lttng26EventLayout getInstance() {
+        return INSTANCE;
+    }
+
+    // ------------------------------------------------------------------------
+    // New event names in these versions
+    // ------------------------------------------------------------------------
+
+    @Override
+    public String eventSyscallEntryPrefix() {
+        return "syscall_entry_"; //$NON-NLS-1$
+    }
+
+    @Override
+    public String eventCompatSyscallEntryPrefix() {
+        return "compat_syscall_entry_"; //$NON-NLS-1$
+    }
+
+    @Override
+    public String eventSyscallExitPrefix() {
+        return "syscall_exit_"; //$NON-NLS-1$
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/trace/layout/Lttng27EventLayout.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/trace/layout/Lttng27EventLayout.java
new file mode 100644 (file)
index 0000000..edfb35d
--- /dev/null
@@ -0,0 +1,66 @@
+/*******************************************************************************
+ * Copyright (c) 2015 Ericsson, École Polytechnique de Montréal
+ *
+ * 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:
+ *   Sebastien Lorrain - Initial API and implementation
+ ******************************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.kernel.core.trace.layout;
+
+/**
+ * This file defines all the known event and field names for LTTng kernel
+ * traces, for versions of lttng-modules 2.7 and above.
+ *
+ * @author Sebastien Lorrain
+ */
+@SuppressWarnings("javadoc")
+public class Lttng27EventLayout extends Lttng26EventLayout {
+
+    /**
+     * Constructor
+     */
+    protected Lttng27EventLayout() {}
+
+    public static final Lttng27EventLayout INSTANCE = new Lttng27EventLayout();
+
+    // ------------------------------------------------------------------------
+    // New definitions in LTTng 2.7
+    // ------------------------------------------------------------------------
+
+    public String fieldParentNSInum() {
+        return "parent_ns_inum"; //$NON-NLS-1$
+    }
+
+    public String fieldChildNSInum() {
+        return "child_ns_inum"; //$NON-NLS-1$
+    }
+
+    public String fieldChildVTids() {
+        return "vtids"; //$NON-NLS-1$
+    }
+
+    public String fieldNSInum() {
+        return "ns_inum"; //$NON-NLS-1$
+    }
+
+    public String fieldVTid() {
+        return "vtid"; //$NON-NLS-1$
+    }
+
+    public String fieldPPid() {
+        return "ppid"; //$NON-NLS-1$
+    }
+
+    public String fieldNSLevel() {
+        return "ns_level"; //$NON-NLS-1$
+    }
+
+    public String fieldStatus() {
+        return "status"; //$NON-NLS-1$
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/trace/layout/LttngEventLayout.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/trace/layout/LttngEventLayout.java
new file mode 100644 (file)
index 0000000..13a9fbf
--- /dev/null
@@ -0,0 +1,239 @@
+/*******************************************************************************
+ * Copyright (c) 2012, 2015 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:
+ *   Alexandre Montplaisir - Initial API and implementation
+ ******************************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.kernel.core.trace.layout;
+
+import static org.eclipse.tracecompass.common.core.NonNullUtils.checkNotNull;
+
+import java.util.Collection;
+
+import org.eclipse.jdt.annotation.NonNull;
+import org.eclipse.tracecompass.analysis.os.linux.core.trace.IKernelAnalysisEventLayout;
+
+import com.google.common.collect.ImmutableList;
+
+/**
+ * This file defines all the known event and field names for LTTng kernel
+ * traces, for versions of lttng-modules up to 2.5.
+ *
+ * These should not be externalized, since they need to match exactly what the
+ * tracer outputs. If you want to localize them in a view, you should do a
+ * mapping in the view itself.
+ *
+ * @author Alexandre Montplaisir
+ */
+@SuppressWarnings("nls")
+public class LttngEventLayout implements IKernelAnalysisEventLayout {
+
+    /* Event names */
+    private static final String IRQ_HANDLER_ENTRY = "irq_handler_entry";
+    private static final String IRQ_HANDLER_EXIT = "irq_handler_exit";
+    private static final String SOFTIRQ_ENTRY = "softirq_entry";
+    private static final String SOFTIRQ_EXIT = "softirq_exit";
+    private static final String SOFTIRQ_RAISE = "softirq_raise";
+    private static final String SCHED_SWITCH = "sched_switch";
+    private static final String SCHED_PI_SETPRIO = "sched_pi_setprio";
+
+    private static final Collection<String> SCHED_WAKEUP_EVENTS =
+            checkNotNull(ImmutableList.of("sched_wakeup", "sched_wakeup_new"));
+
+    private static final String SCHED_PROCESS_FORK = "sched_process_fork";
+    private static final String SCHED_PROCESS_EXIT = "sched_process_exit";
+    private static final String SCHED_PROCESS_FREE = "sched_process_free";
+    private static final String STATEDUMP_PROCESS_STATE = "lttng_statedump_process_state";
+
+    private static final String SYSCALL_ENTRY_PREFIX = "sys_";
+    private static final String COMPAT_SYSCALL_ENTRY_PREFIX = "compat_sys_";
+    private static final String SYSCALL_EXIT_PREFIX = "exit_syscall";
+
+    /* Field names */
+    private static final String IRQ = "irq";
+    private static final String TID = "tid";
+    private static final String VEC = "vec";
+    private static final String PREV_TID = "prev_tid";
+    private static final String PREV_STATE = "prev_state";
+    private static final String NEXT_COMM = "next_comm";
+    private static final String NEXT_TID = "next_tid";
+    private static final String PARENT_TID = "parent_tid";
+    private static final String CHILD_COMM = "child_comm";
+    private static final String CHILD_TID = "child_tid";
+    private static final String PRIO = "prio";
+    private static final String NEXT_PRIO = "next_prio";
+    private static final String NEW_PRIO = "newprio";
+
+    /** All instances are the same. Only provide a static instance getter */
+    protected LttngEventLayout() {
+    }
+
+    private static final IKernelAnalysisEventLayout INSTANCE = new LttngEventLayout();
+
+    /**
+     * Get an instance of this event layout
+     *
+     * This object is completely immutable, so no need to create additional
+     * instances via the constructor.
+     *
+     * @return The instance
+     */
+    public static IKernelAnalysisEventLayout getInstance() {
+        return INSTANCE;
+    }
+
+    // ------------------------------------------------------------------------
+    // Event names
+    // ------------------------------------------------------------------------
+
+    @Override
+    public String eventIrqHandlerEntry() {
+        return IRQ_HANDLER_ENTRY;
+    }
+
+    @Override
+    public String eventIrqHandlerExit() {
+        return IRQ_HANDLER_EXIT;
+    }
+
+    @Override
+    public String eventSoftIrqEntry() {
+        return SOFTIRQ_ENTRY;
+    }
+
+    @Override
+    public String eventSoftIrqExit() {
+        return SOFTIRQ_EXIT;
+    }
+
+    @Override
+    public String eventSoftIrqRaise() {
+        return SOFTIRQ_RAISE;
+    }
+
+    @Override
+    public String eventSchedSwitch() {
+        return SCHED_SWITCH;
+    }
+
+    @Override
+    public String eventSchedPiSetprio() {
+        return SCHED_PI_SETPRIO;
+    }
+
+    @Override
+    public Collection<String> eventsSchedWakeup() {
+        return SCHED_WAKEUP_EVENTS;
+    }
+
+    @Override
+    public String eventSchedProcessFork() {
+        return SCHED_PROCESS_FORK;
+    }
+
+    @Override
+    public String eventSchedProcessExit() {
+        return SCHED_PROCESS_EXIT;
+    }
+
+    @Override
+    public String eventSchedProcessFree() {
+        return SCHED_PROCESS_FREE;
+    }
+
+    @Override
+    public @NonNull String eventStatedumpProcessState() {
+        return STATEDUMP_PROCESS_STATE;
+    }
+
+    @Override
+    public String eventSyscallEntryPrefix() {
+        return SYSCALL_ENTRY_PREFIX;
+    }
+
+    @Override
+    public String eventCompatSyscallEntryPrefix() {
+        return COMPAT_SYSCALL_ENTRY_PREFIX;
+    }
+
+    @Override
+    public String eventSyscallExitPrefix() {
+        return SYSCALL_EXIT_PREFIX;
+    }
+
+    // ------------------------------------------------------------------------
+    // Event field names
+    // ------------------------------------------------------------------------
+
+    @Override
+    public String fieldIrq() {
+        return IRQ;
+    }
+
+    @Override
+    public String fieldVec() {
+        return VEC;
+    }
+
+    @Override
+    public String fieldTid() {
+        return TID;
+    }
+
+    @Override
+    public String fieldPrevTid() {
+        return PREV_TID;
+    }
+
+    @Override
+    public String fieldPrevState() {
+        return PREV_STATE;
+    }
+
+    @Override
+    public String fieldNextComm() {
+        return NEXT_COMM;
+    }
+
+    @Override
+    public String fieldNextTid() {
+        return NEXT_TID;
+    }
+
+    @Override
+    public String fieldChildComm() {
+        return CHILD_COMM;
+    }
+
+    @Override
+    public String fieldParentTid() {
+        return PARENT_TID;
+    }
+
+    @Override
+    public String fieldChildTid() {
+        return CHILD_TID;
+    }
+
+    @Override
+    public String fieldPrio() {
+        return PRIO;
+    }
+
+    @Override
+    public String fieldNewPrio() {
+        return NEW_PRIO;
+    }
+
+    @Override
+    public String fieldNextPrio() {
+        return NEXT_PRIO;
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/trace/layout/PerfEventLayout.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/trace/layout/PerfEventLayout.java
new file mode 100644 (file)
index 0000000..03512c2
--- /dev/null
@@ -0,0 +1,196 @@
+/*******************************************************************************
+ * Copyright (c) 2012, 2015 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:
+ *   Alexandre Montplaisir - Initial API and implementation
+ ******************************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.kernel.core.trace.layout;
+
+import static org.eclipse.tracecompass.common.core.NonNullUtils.checkNotNull;
+
+import java.util.Collection;
+
+import org.eclipse.jdt.annotation.Nullable;
+import org.eclipse.tracecompass.analysis.os.linux.core.trace.IKernelAnalysisEventLayout;
+
+import com.google.common.collect.ImmutableList;
+
+/**
+ * Event and field definitions for perf traces in CTF format.
+ *
+ * @author Alexandre Montplaisir
+ */
+public class PerfEventLayout implements IKernelAnalysisEventLayout {
+
+    private PerfEventLayout() {}
+
+    private static final PerfEventLayout INSTANCE = new PerfEventLayout();
+
+    /**
+     * Get the singleton instance of this event layout object.
+     *
+     * @return The instance
+     */
+    public static PerfEventLayout getInstance() {
+        return INSTANCE;
+    }
+
+    // ------------------------------------------------------------------------
+    // Event names
+    // ------------------------------------------------------------------------
+
+    @Override
+    public String eventIrqHandlerEntry() {
+        return "irq:irq_handler_exit"; //$NON-NLS-1$
+    }
+
+    @Override
+    public String eventIrqHandlerExit() {
+        return "irq:irq_handler_entry"; //$NON-NLS-1$
+    }
+
+    @Override
+    public String eventSoftIrqEntry() {
+        return "irq:softirq_entry"; //$NON-NLS-1$
+    }
+
+    @Override
+    public String eventSoftIrqExit() {
+        return "irq:softirq_exit"; //$NON-NLS-1$
+    }
+
+    @Override
+    public String eventSoftIrqRaise() {
+        return "irq:softirq_raise"; //$NON-NLS-1$
+    }
+
+    @Override
+    public String eventSchedSwitch() {
+        return "sched:sched_switch"; //$NON-NLS-1$
+    }
+
+    @Override
+    public String eventSchedPiSetprio() {
+        return "sched:sched_pi_setprio"; //$NON-NLS-1$
+    }
+
+    private static final Collection<String> WAKEUP_EVENTS =
+            checkNotNull(ImmutableList.of("sched:sched_wakeup", "sched:sched_wakeup_new")); //$NON-NLS-1$ //$NON-NLS-2$
+
+    @Override
+    public Collection<String> eventsSchedWakeup() {
+        return WAKEUP_EVENTS;
+    }
+
+    @Override
+    public String eventSchedProcessFork() {
+        return "sched:sched_process_fork"; //$NON-NLS-1$
+    }
+
+    @Override
+    public String eventSchedProcessExit() {
+        return "sched:sched_process_exit"; //$NON-NLS-1$
+    }
+
+    @Override
+    public String eventSchedProcessFree() {
+        return "sched:sched_process_free"; //$NON-NLS-1$
+    }
+
+    @Override
+    public @Nullable String eventStatedumpProcessState() {
+        /* Not present in perf traces */
+        return null;
+    }
+
+    @Override
+    public String eventSyscallEntryPrefix() {
+        return "raw_syscalls:sys_enter"; //$NON-NLS-1$
+    }
+
+    @Override
+    public String eventCompatSyscallEntryPrefix() {
+        return eventSyscallEntryPrefix();
+    }
+
+    @Override
+    public String eventSyscallExitPrefix() {
+        return "raw_syscalls:sys_exit"; //$NON-NLS-1$
+    }
+
+    // ------------------------------------------------------------------------
+    // Field names
+    // ------------------------------------------------------------------------
+
+    @Override
+    public String fieldIrq() {
+        return "irq"; //$NON-NLS-1$
+    }
+
+    @Override
+    public String fieldVec() {
+        return "vec"; //$NON-NLS-1$
+    }
+
+    @Override
+    public String fieldTid() {
+        return "pid"; //$NON-NLS-1$
+    }
+
+    @Override
+    public String fieldPrevTid() {
+        return "prev_pid"; //$NON-NLS-1$
+    }
+
+    @Override
+    public String fieldPrevState() {
+        return "prev_state"; //$NON-NLS-1$
+    }
+
+    @Override
+    public String fieldNextComm() {
+        return "next_comm"; //$NON-NLS-1$
+    }
+
+    @Override
+    public String fieldNextTid() {
+        return "next_pid"; //$NON-NLS-1$
+    }
+
+    @Override
+    public String fieldChildComm() {
+        return "child_comm"; //$NON-NLS-1$
+    }
+
+    @Override
+    public String fieldParentTid() {
+        return "parent_pid"; //$NON-NLS-1$
+    }
+
+    @Override
+    public String fieldChildTid() {
+        return "child_pid"; //$NON-NLS-1$
+    }
+
+    @Override
+    public String fieldPrio() {
+        return "prio"; //$NON-NLS-1$
+    }
+
+    @Override
+    public String fieldNewPrio() {
+        return "newprio"; //$NON-NLS-1$
+    }
+
+    @Override
+    public String fieldNextPrio() {
+        return "next_prio"; //$NON-NLS-1$
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/trace/layout/package-info.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/trace/layout/package-info.java
new file mode 100644 (file)
index 0000000..d74f33f
--- /dev/null
@@ -0,0 +1,14 @@
+/*******************************************************************************
+ * Copyright (c) 2014 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:
+ *    Ericsson - Initial API and implementation
+ *******************************************************************************/
+
+@org.eclipse.jdt.annotation.NonNullByDefault
+package org.eclipse.tracecompass.internal.lttng2.kernel.core.trace.layout;
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/lttng2/kernel/core/trace/LttngKernelTrace.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/lttng2/kernel/core/trace/LttngKernelTrace.java
new file mode 100644 (file)
index 0000000..b3e3c70
--- /dev/null
@@ -0,0 +1,164 @@
+/*******************************************************************************
+ * Copyright (c) 2012, 2015 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:
+ *   Alexandre Montplaisir - Initial API and implementation
+ *   Matthew Khouzam - Improved validation
+ ******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.kernel.core.trace;
+
+import java.util.Collection;
+import java.util.Map;
+
+import org.eclipse.core.resources.IProject;
+import org.eclipse.core.resources.IResource;
+import org.eclipse.core.runtime.IStatus;
+import org.eclipse.core.runtime.Status;
+import org.eclipse.jdt.annotation.NonNull;
+import org.eclipse.tracecompass.analysis.os.linux.core.kernelanalysis.KernelTidAspect;
+import org.eclipse.tracecompass.analysis.os.linux.core.kernelanalysis.ThreadPriorityAspect;
+import org.eclipse.tracecompass.analysis.os.linux.core.trace.IKernelAnalysisEventLayout;
+import org.eclipse.tracecompass.analysis.os.linux.core.trace.IKernelTrace;
+import org.eclipse.tracecompass.common.core.NonNullUtils;
+import org.eclipse.tracecompass.internal.lttng2.kernel.core.Activator;
+import org.eclipse.tracecompass.internal.lttng2.kernel.core.trace.layout.Lttng26EventLayout;
+import org.eclipse.tracecompass.internal.lttng2.kernel.core.trace.layout.Lttng27EventLayout;
+import org.eclipse.tracecompass.internal.lttng2.kernel.core.trace.layout.LttngEventLayout;
+import org.eclipse.tracecompass.internal.lttng2.kernel.core.trace.layout.PerfEventLayout;
+import org.eclipse.tracecompass.tmf.core.event.ITmfEvent;
+import org.eclipse.tracecompass.tmf.core.event.aspect.ITmfEventAspect;
+import org.eclipse.tracecompass.tmf.core.exceptions.TmfTraceException;
+import org.eclipse.tracecompass.tmf.core.trace.TraceValidationStatus;
+import org.eclipse.tracecompass.tmf.ctf.core.trace.CtfTmfTrace;
+import org.eclipse.tracecompass.tmf.ctf.core.trace.CtfTraceValidationStatus;
+
+import com.google.common.collect.ImmutableSet;
+
+/**
+ * This is the specification of CtfTmfTrace for use with LTTng 2.x kernel
+ * traces.
+ *
+ * @author Alexandre Montplaisir
+ */
+public class LttngKernelTrace extends CtfTmfTrace implements IKernelTrace {
+
+    /**
+     * Supported Linux kernel tracers
+     */
+    private enum OriginTracer {
+        LTTNG(LttngEventLayout.getInstance()),
+        LTTNG26(Lttng26EventLayout.getInstance()),
+        LTTNG27(Lttng27EventLayout.INSTANCE),
+        PERF(PerfEventLayout.getInstance());
+
+        private final @NonNull IKernelAnalysisEventLayout fLayout;
+
+        private OriginTracer(@NonNull IKernelAnalysisEventLayout layout) {
+            fLayout = layout;
+        }
+    }
+
+    /**
+     * Event aspects available for all Lttng Kernel traces
+     */
+    private static final @NonNull Collection<ITmfEventAspect> LTTNG_KERNEL_ASPECTS;
+
+    static {
+        ImmutableSet.Builder<ITmfEventAspect> builder = ImmutableSet.builder();
+        builder.addAll(CtfTmfTrace.CTF_ASPECTS);
+        builder.add(KernelTidAspect.INSTANCE);
+        builder.add(ThreadPriorityAspect.INSTANCE);
+        LTTNG_KERNEL_ASPECTS = NonNullUtils.checkNotNull(builder.build());
+    }
+
+    /**
+     * CTF metadata identifies trace type and tracer version pretty well, we are
+     * quite confident in the inferred trace type.
+     */
+    private static final int CONFIDENCE = 100;
+
+    /** The tracer which originated this trace */
+    private OriginTracer fOriginTracer = null;
+
+    /**
+     * Default constructor
+     */
+    public LttngKernelTrace() {
+        super();
+    }
+
+    @Override
+    public @NonNull IKernelAnalysisEventLayout getKernelEventLayout() {
+        OriginTracer tracer = fOriginTracer;
+        if (tracer == null) {
+            throw new IllegalStateException("Cannot get the layout of a non-initialized trace!"); //$NON-NLS-1$
+        }
+        return tracer.fLayout;
+    }
+
+    @Override
+    public void initTrace(IResource resource, String path,
+            Class<? extends ITmfEvent> eventType) throws TmfTraceException {
+        super.initTrace(resource, path, eventType);
+        fOriginTracer = getTracerFromEnv(this.getEnvironment());
+    }
+
+    /**
+     * Identify which tracer generated a trace from its metadata.
+     */
+    private static OriginTracer getTracerFromEnv(Map<String, String> traceEnv) {
+        String tracerName = traceEnv.get("tracer_name"); //$NON-NLS-1$
+        String tracerMajor = traceEnv.get("tracer_major"); //$NON-NLS-1$
+        String tracerMinor = traceEnv.get("tracer_minor"); //$NON-NLS-1$
+
+        if ("\"perf\"".equals(tracerName)) { //$NON-NLS-1$
+            return OriginTracer.PERF;
+
+        } else if ("\"lttng-modules\"".equals(tracerName) && tracerMajor != null && tracerMinor != null) { //$NON-NLS-1$
+            /* Look for specific versions of LTTng */
+            if (Integer.valueOf(tracerMajor) >= 2) {
+                if (Integer.valueOf(tracerMinor) >= 7) {
+                    return OriginTracer.LTTNG27;
+                } else if (Integer.valueOf(tracerMinor) >= 6) {
+                    return OriginTracer.LTTNG26;
+                }
+            }
+        }
+
+        /* Use base LTTng layout as default */
+        return OriginTracer.LTTNG;
+    }
+
+    /**
+     * {@inheritDoc}
+     * <p>
+     * This implementation sets the confidence to 100 if the trace is a valid
+     * CTF trace in the "kernel" domain.
+     */
+    @Override
+    public IStatus validate(final IProject project, final String path) {
+        IStatus status = super.validate(project, path);
+        if (status instanceof CtfTraceValidationStatus) {
+            Map<String, String> environment = ((CtfTraceValidationStatus) status).getEnvironment();
+            /* Make sure the domain is "kernel" in the trace's env vars */
+            String domain = environment.get("domain"); //$NON-NLS-1$
+            if (domain == null || !domain.equals("\"kernel\"")) { //$NON-NLS-1$
+                return new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.LttngKernelTrace_DomainError);
+            }
+            return new TraceValidationStatus(CONFIDENCE, Activator.PLUGIN_ID);
+        }
+        return status;
+    }
+
+    @Override
+    public Iterable<ITmfEventAspect> getEventAspects() {
+         return LTTNG_KERNEL_ASPECTS;
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/lttng2/kernel/core/trace/Messages.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/lttng2/kernel/core/trace/Messages.java
new file mode 100644 (file)
index 0000000..e5751fd
--- /dev/null
@@ -0,0 +1,45 @@
+/*******************************************************************************
+ * Copyright (c) 2013, 2014 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:
+ *     Matthew Khouzam - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.kernel.core.trace;
+
+import org.eclipse.osgi.util.NLS;
+
+/**
+ * Message bundle for lttng2.kernel.core.trace
+ *
+ * @author Matthew Khouzam
+ */
+public class Messages extends NLS {
+
+    private static final String BUNDLE_NAME = "org.eclipse.tracecompass.lttng2.kernel.core.trace.messages"; //$NON-NLS-1$
+
+    /**
+     * The domain is not "kernel"
+     */
+    public static String LttngKernelTrace_DomainError;
+    /**
+     * Malformed trace (buffer overflow maybe?)
+     */
+    public static String LttngKernelTrace_MalformedTrace;
+    /**
+     * Trace read error
+     */
+    public static String LttngKernelTrace_TraceReadError;
+
+    static {
+        // initialize resource bundle
+        NLS.initializeMessages(BUNDLE_NAME, Messages.class);
+    }
+
+    private Messages() {
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/lttng2/kernel/core/trace/messages.properties b/lttng/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/lttng2/kernel/core/trace/messages.properties
new file mode 100644 (file)
index 0000000..290c225
--- /dev/null
@@ -0,0 +1,15 @@
+###############################################################################
+# Copyright (c) 2013, 2014 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:
+#     Ericsson - Initial API and implementation
+###############################################################################
+
+LttngKernelTrace_DomainError=Domain mismatch, the environment should be 'kernel'.
+LttngKernelTrace_MalformedTrace=Buffer overflow exception, trace is malformed
+LttngKernelTrace_TraceReadError=Lttng trace read error
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.classpath b/lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.classpath
new file mode 100644 (file)
index 0000000..3bc2475
--- /dev/null
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+       <classpathentry kind="src" path="src"/>
+       <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7"/>
+       <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
+       <classpathentry kind="output" path="bin"/>
+</classpath>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.gitignore b/lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.gitignore
new file mode 100644 (file)
index 0000000..750e145
--- /dev/null
@@ -0,0 +1 @@
+screenshots/
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.project b/lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.project
new file mode 100644 (file)
index 0000000..2955b91
--- /dev/null
@@ -0,0 +1,34 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+       <name>org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests</name>
+       <comment></comment>
+       <projects>
+       </projects>
+       <buildSpec>
+               <buildCommand>
+                       <name>org.eclipse.jdt.core.javabuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+               <buildCommand>
+                       <name>org.eclipse.pde.ManifestBuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+               <buildCommand>
+                       <name>org.eclipse.pde.SchemaBuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+               <buildCommand>
+                       <name>org.eclipse.pde.api.tools.apiAnalysisBuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+       </buildSpec>
+       <natures>
+               <nature>org.eclipse.jdt.core.javanature</nature>
+               <nature>org.eclipse.pde.PluginNature</nature>
+               <nature>org.eclipse.pde.api.tools.apiAnalysisNature</nature>
+       </natures>
+</projectDescription>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.settings/org.eclipse.core.resources.prefs b/lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.settings/org.eclipse.core.resources.prefs
new file mode 100644 (file)
index 0000000..99f26c0
--- /dev/null
@@ -0,0 +1,2 @@
+eclipse.preferences.version=1
+encoding/<project>=UTF-8
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.settings/org.eclipse.core.runtime.prefs b/lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.settings/org.eclipse.core.runtime.prefs
new file mode 100644 (file)
index 0000000..5a0ad22
--- /dev/null
@@ -0,0 +1,2 @@
+eclipse.preferences.version=1
+line.separator=\n
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.settings/org.eclipse.jdt.core.prefs b/lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.settings/org.eclipse.jdt.core.prefs
new file mode 100644 (file)
index 0000000..0409c61
--- /dev/null
@@ -0,0 +1,403 @@
+eclipse.preferences.version=1
+org.eclipse.jdt.core.codeComplete.argumentPrefixes=
+org.eclipse.jdt.core.codeComplete.argumentSuffixes=
+org.eclipse.jdt.core.codeComplete.fieldPrefixes=f
+org.eclipse.jdt.core.codeComplete.fieldSuffixes=
+org.eclipse.jdt.core.codeComplete.localPrefixes=
+org.eclipse.jdt.core.codeComplete.localSuffixes=
+org.eclipse.jdt.core.codeComplete.staticFieldPrefixes=
+org.eclipse.jdt.core.codeComplete.staticFieldSuffixes=
+org.eclipse.jdt.core.codeComplete.staticFinalFieldPrefixes=
+org.eclipse.jdt.core.codeComplete.staticFinalFieldSuffixes=
+org.eclipse.jdt.core.compiler.annotation.inheritNullAnnotations=enabled
+org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore
+org.eclipse.jdt.core.compiler.annotation.nonnull=org.eclipse.jdt.annotation.NonNull
+org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=org.eclipse.jdt.annotation.NonNullByDefault
+org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nullable
+org.eclipse.jdt.core.compiler.annotation.nullanalysis=enabled
+org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
+org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
+org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
+org.eclipse.jdt.core.compiler.compliance=1.7
+org.eclipse.jdt.core.compiler.debug.lineNumber=generate
+org.eclipse.jdt.core.compiler.debug.localVariable=generate
+org.eclipse.jdt.core.compiler.debug.sourceFile=generate
+org.eclipse.jdt.core.compiler.doc.comment.support=enabled
+org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=error
+org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
+org.eclipse.jdt.core.compiler.problem.autoboxing=ignore
+org.eclipse.jdt.core.compiler.problem.comparingIdentical=error
+org.eclipse.jdt.core.compiler.problem.deadCode=error
+org.eclipse.jdt.core.compiler.problem.deprecation=error
+org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled
+org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=enabled
+org.eclipse.jdt.core.compiler.problem.discouragedReference=error
+org.eclipse.jdt.core.compiler.problem.emptyStatement=error
+org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
+org.eclipse.jdt.core.compiler.problem.explicitlyClosedAutoCloseable=error
+org.eclipse.jdt.core.compiler.problem.fallthroughCase=error
+org.eclipse.jdt.core.compiler.problem.fatalOptionalError=disabled
+org.eclipse.jdt.core.compiler.problem.fieldHiding=error
+org.eclipse.jdt.core.compiler.problem.finalParameterBound=error
+org.eclipse.jdt.core.compiler.problem.finallyBlockNotCompletingNormally=error
+org.eclipse.jdt.core.compiler.problem.forbiddenReference=error
+org.eclipse.jdt.core.compiler.problem.hiddenCatchBlock=error
+org.eclipse.jdt.core.compiler.problem.includeNullInfoFromAsserts=disabled
+org.eclipse.jdt.core.compiler.problem.incompatibleNonInheritedInterfaceMethod=error
+org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch=error
+org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=error
+org.eclipse.jdt.core.compiler.problem.invalidJavadoc=warning
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTags=enabled
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsDeprecatedRef=enabled
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsNotVisibleRef=enabled
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsVisibility=protected
+org.eclipse.jdt.core.compiler.problem.localVariableHiding=error
+org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=error
+org.eclipse.jdt.core.compiler.problem.missingDefaultCase=error
+org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=error
+org.eclipse.jdt.core.compiler.problem.missingEnumCaseDespiteDefault=enabled
+org.eclipse.jdt.core.compiler.problem.missingHashCodeMethod=error
+org.eclipse.jdt.core.compiler.problem.missingJavadocComments=warning
+org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsOverriding=disabled
+org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsVisibility=protected
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagDescription=all_standard_tags
+org.eclipse.jdt.core.compiler.problem.missingJavadocTags=warning
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagsMethodTypeParameters=disabled
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagsOverriding=disabled
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagsVisibility=protected
+org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotation=error
+org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotationForInterfaceMethodImplementation=enabled
+org.eclipse.jdt.core.compiler.problem.missingSerialVersion=error
+org.eclipse.jdt.core.compiler.problem.missingSynchronizedOnInheritedMethod=error
+org.eclipse.jdt.core.compiler.problem.noEffectAssignment=error
+org.eclipse.jdt.core.compiler.problem.noImplicitStringConversion=error
+org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=ignore
+org.eclipse.jdt.core.compiler.problem.nonnullParameterAnnotationDropped=warning
+org.eclipse.jdt.core.compiler.problem.nullAnnotationInferenceConflict=warning
+org.eclipse.jdt.core.compiler.problem.nullReference=error
+org.eclipse.jdt.core.compiler.problem.nullSpecViolation=error
+org.eclipse.jdt.core.compiler.problem.nullUncheckedConversion=warning
+org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=error
+org.eclipse.jdt.core.compiler.problem.parameterAssignment=error
+org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=error
+org.eclipse.jdt.core.compiler.problem.potentialNullReference=error
+org.eclipse.jdt.core.compiler.problem.potentiallyUnclosedCloseable=warning
+org.eclipse.jdt.core.compiler.problem.rawTypeReference=error
+org.eclipse.jdt.core.compiler.problem.redundantNullAnnotation=warning
+org.eclipse.jdt.core.compiler.problem.redundantNullCheck=error
+org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=error
+org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=error
+org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore
+org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=error
+org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled
+org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=error
+org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=disabled
+org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled
+org.eclipse.jdt.core.compiler.problem.syntacticNullAnalysisForFields=enabled
+org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=ignore
+org.eclipse.jdt.core.compiler.problem.typeParameterHiding=error
+org.eclipse.jdt.core.compiler.problem.unavoidableGenericTypeProblems=disabled
+org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=error
+org.eclipse.jdt.core.compiler.problem.unclosedCloseable=error
+org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=ignore
+org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=error
+org.eclipse.jdt.core.compiler.problem.unnecessaryElse=error
+org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=error
+org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=error
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionExemptExceptionAndThrowable=disabled
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionIncludeDocCommentReference=disabled
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverriding=disabled
+org.eclipse.jdt.core.compiler.problem.unusedImport=error
+org.eclipse.jdt.core.compiler.problem.unusedLabel=error
+org.eclipse.jdt.core.compiler.problem.unusedLocal=error
+org.eclipse.jdt.core.compiler.problem.unusedObjectAllocation=ignore
+org.eclipse.jdt.core.compiler.problem.unusedParameter=ignore
+org.eclipse.jdt.core.compiler.problem.unusedParameterIncludeDocCommentReference=enabled
+org.eclipse.jdt.core.compiler.problem.unusedParameterWhenImplementingAbstract=disabled
+org.eclipse.jdt.core.compiler.problem.unusedParameterWhenOverridingConcrete=disabled
+org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=error
+org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=ignore
+org.eclipse.jdt.core.compiler.problem.unusedWarningToken=error
+org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=error
+org.eclipse.jdt.core.compiler.source=1.7
+org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=16
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_call=16
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation=16
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression=16
+org.eclipse.jdt.core.formatter.alignment_for_assignment=0
+org.eclipse.jdt.core.formatter.alignment_for_binary_expression=16
+org.eclipse.jdt.core.formatter.alignment_for_compact_if=16
+org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=80
+org.eclipse.jdt.core.formatter.alignment_for_enum_constants=0
+org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=16
+org.eclipse.jdt.core.formatter.alignment_for_method_declaration=0
+org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16
+org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=80
+org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation=0
+org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_constructor_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_method_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_union_type_in_multicatch=16
+org.eclipse.jdt.core.formatter.blank_lines_after_imports=1
+org.eclipse.jdt.core.formatter.blank_lines_after_package=1
+org.eclipse.jdt.core.formatter.blank_lines_before_field=0
+org.eclipse.jdt.core.formatter.blank_lines_before_first_class_body_declaration=0
+org.eclipse.jdt.core.formatter.blank_lines_before_imports=1
+org.eclipse.jdt.core.formatter.blank_lines_before_member_type=1
+org.eclipse.jdt.core.formatter.blank_lines_before_method=1
+org.eclipse.jdt.core.formatter.blank_lines_before_new_chunk=1
+org.eclipse.jdt.core.formatter.blank_lines_before_package=0
+org.eclipse.jdt.core.formatter.blank_lines_between_import_groups=1
+org.eclipse.jdt.core.formatter.blank_lines_between_type_declarations=1
+org.eclipse.jdt.core.formatter.brace_position_for_annotation_type_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_array_initializer=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_block=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_block_in_case=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_constructor_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_enum_constant=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_enum_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_method_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_switch=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_type_declaration=end_of_line
+org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_block_comment=false
+org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_javadoc_comment=false
+org.eclipse.jdt.core.formatter.comment.format_block_comments=true
+org.eclipse.jdt.core.formatter.comment.format_header=false
+org.eclipse.jdt.core.formatter.comment.format_html=true
+org.eclipse.jdt.core.formatter.comment.format_javadoc_comments=true
+org.eclipse.jdt.core.formatter.comment.format_line_comments=true
+org.eclipse.jdt.core.formatter.comment.format_source_code=true
+org.eclipse.jdt.core.formatter.comment.indent_parameter_description=true
+org.eclipse.jdt.core.formatter.comment.indent_root_tags=true
+org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags=insert
+org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter=insert
+org.eclipse.jdt.core.formatter.comment.line_length=80
+org.eclipse.jdt.core.formatter.comment.new_lines_at_block_boundaries=true
+org.eclipse.jdt.core.formatter.comment.new_lines_at_javadoc_boundaries=true
+org.eclipse.jdt.core.formatter.comment.preserve_white_space_between_code_and_line_comments=false
+org.eclipse.jdt.core.formatter.compact_else_if=true
+org.eclipse.jdt.core.formatter.continuation_indentation=2
+org.eclipse.jdt.core.formatter.continuation_indentation_for_array_initializer=2
+org.eclipse.jdt.core.formatter.disabling_tag=@formatter\:off
+org.eclipse.jdt.core.formatter.enabling_tag=@formatter\:on
+org.eclipse.jdt.core.formatter.format_guardian_clause_on_one_line=false
+org.eclipse.jdt.core.formatter.format_line_comment_starting_on_first_column=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_annotation_declaration_header=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_constant_header=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_declaration_header=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_type_header=true
+org.eclipse.jdt.core.formatter.indent_breaks_compare_to_cases=true
+org.eclipse.jdt.core.formatter.indent_empty_lines=false
+org.eclipse.jdt.core.formatter.indent_statements_compare_to_block=true
+org.eclipse.jdt.core.formatter.indent_statements_compare_to_body=true
+org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_cases=true
+org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_switch=false
+org.eclipse.jdt.core.formatter.indentation.size=4
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_field=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_local_variable=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_method=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_package=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_parameter=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_type=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_label=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_opening_brace_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_at_end_of_file_if_missing=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_finally_in_try_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_while_in_do_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_annotation_declaration=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_anonymous_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_block=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter=insert
+org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_binary_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_paren_in_cast=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_assert=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_case=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_labeled_statement=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_allocation_expression=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_annotation=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_throws=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_constant_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_declarations=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_explicitconstructorcall_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_increments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_inits=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_throws=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_invocation_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_field_declarations=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_local_declarations=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_parameterized_type_reference=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_superinterfaces=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_ellipsis=insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_brace_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_cast=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_catch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_for=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_if=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_parenthesized_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_switch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_synchronized=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_try=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_while=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_try_resources=insert
+org.eclipse.jdt.core.formatter.insert_space_after_unary_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter=insert
+org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_binary_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_brace_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_cast=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_catch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_for=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_if=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_parenthesized_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_switch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_synchronized=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_try=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_while=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_assert=insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_case=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_default=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_labeled_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_throws=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_constant_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_declarations=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_explicitconstructorcall_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_increments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_inits=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_throws=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_invocation_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_field_declarations=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_local_declarations=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_superinterfaces=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_ellipsis=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_annotation_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_anonymous_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_block=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_constructor_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_constant=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_method_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_switch=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation_type_member_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_catch=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_if=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_parenthesized_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_switch=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_synchronized=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_try=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_while=insert
+org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_return=insert
+org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_throw=insert
+org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_semicolon=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_try_resources=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_unary_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_brackets_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_annotation_type_member_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.join_lines_in_comments=true
+org.eclipse.jdt.core.formatter.join_wrapped_lines=false
+org.eclipse.jdt.core.formatter.keep_else_statement_on_same_line=false
+org.eclipse.jdt.core.formatter.keep_empty_array_initializer_on_one_line=false
+org.eclipse.jdt.core.formatter.keep_imple_if_on_one_line=false
+org.eclipse.jdt.core.formatter.keep_then_statement_on_same_line=false
+org.eclipse.jdt.core.formatter.lineSplit=250
+org.eclipse.jdt.core.formatter.never_indent_block_comments_on_first_column=false
+org.eclipse.jdt.core.formatter.never_indent_line_comments_on_first_column=false
+org.eclipse.jdt.core.formatter.number_of_blank_lines_at_beginning_of_method_body=0
+org.eclipse.jdt.core.formatter.number_of_empty_lines_to_preserve=1
+org.eclipse.jdt.core.formatter.put_empty_statement_on_new_line=true
+org.eclipse.jdt.core.formatter.tabulation.char=space
+org.eclipse.jdt.core.formatter.tabulation.size=4
+org.eclipse.jdt.core.formatter.use_on_off_tags=false
+org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false
+org.eclipse.jdt.core.formatter.wrap_before_binary_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_or_operator_multicatch=true
+org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.settings/org.eclipse.jdt.ui.prefs b/lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.settings/org.eclipse.jdt.ui.prefs
new file mode 100644 (file)
index 0000000..232a3fd
--- /dev/null
@@ -0,0 +1,60 @@
+eclipse.preferences.version=1
+editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true
+formatter_profile=_tmf-style
+formatter_settings_version=12
+org.eclipse.jdt.ui.exception.name=e
+org.eclipse.jdt.ui.gettersetter.use.is=true
+org.eclipse.jdt.ui.keywordthis=false
+org.eclipse.jdt.ui.overrideannotation=true
+sp_cleanup.add_default_serial_version_id=true
+sp_cleanup.add_generated_serial_version_id=false
+sp_cleanup.add_missing_annotations=false
+sp_cleanup.add_missing_deprecated_annotations=true
+sp_cleanup.add_missing_methods=false
+sp_cleanup.add_missing_nls_tags=false
+sp_cleanup.add_missing_override_annotations=true
+sp_cleanup.add_missing_override_annotations_interface_methods=true
+sp_cleanup.add_serial_version_id=false
+sp_cleanup.always_use_blocks=true
+sp_cleanup.always_use_parentheses_in_expressions=false
+sp_cleanup.always_use_this_for_non_static_field_access=false
+sp_cleanup.always_use_this_for_non_static_method_access=false
+sp_cleanup.convert_to_enhanced_for_loop=false
+sp_cleanup.correct_indentation=false
+sp_cleanup.format_source_code=false
+sp_cleanup.format_source_code_changes_only=false
+sp_cleanup.make_local_variable_final=false
+sp_cleanup.make_parameters_final=false
+sp_cleanup.make_private_fields_final=true
+sp_cleanup.make_type_abstract_if_missing_method=false
+sp_cleanup.make_variable_declarations_final=false
+sp_cleanup.never_use_blocks=false
+sp_cleanup.never_use_parentheses_in_expressions=true
+sp_cleanup.on_save_use_additional_actions=true
+sp_cleanup.organize_imports=false
+sp_cleanup.qualify_static_field_accesses_with_declaring_class=false
+sp_cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=true
+sp_cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=true
+sp_cleanup.qualify_static_member_accesses_with_declaring_class=false
+sp_cleanup.qualify_static_method_accesses_with_declaring_class=false
+sp_cleanup.remove_private_constructors=true
+sp_cleanup.remove_trailing_whitespaces=true
+sp_cleanup.remove_trailing_whitespaces_all=true
+sp_cleanup.remove_trailing_whitespaces_ignore_empty=false
+sp_cleanup.remove_unnecessary_casts=false
+sp_cleanup.remove_unnecessary_nls_tags=false
+sp_cleanup.remove_unused_imports=false
+sp_cleanup.remove_unused_local_variables=false
+sp_cleanup.remove_unused_private_fields=true
+sp_cleanup.remove_unused_private_members=false
+sp_cleanup.remove_unused_private_methods=true
+sp_cleanup.remove_unused_private_types=true
+sp_cleanup.sort_members=false
+sp_cleanup.sort_members_all=false
+sp_cleanup.use_blocks=true
+sp_cleanup.use_blocks_only_for_return_and_throw=false
+sp_cleanup.use_parentheses_in_expressions=false
+sp_cleanup.use_this_for_non_static_field_access=false
+sp_cleanup.use_this_for_non_static_field_access_only_if_necessary=true
+sp_cleanup.use_this_for_non_static_method_access=false
+sp_cleanup.use_this_for_non_static_method_access_only_if_necessary=true
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.settings/org.eclipse.pde.api.tools.prefs b/lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.settings/org.eclipse.pde.api.tools.prefs
new file mode 100644 (file)
index 0000000..acc3abd
--- /dev/null
@@ -0,0 +1,97 @@
+ANNOTATION_ELEMENT_TYPE_ADDED_METHOD_WITHOUT_DEFAULT_VALUE=Error
+ANNOTATION_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+ANNOTATION_ELEMENT_TYPE_REMOVED_FIELD=Error
+ANNOTATION_ELEMENT_TYPE_REMOVED_METHOD=Error
+ANNOTATION_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_API_TYPE=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_API_TYPE=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_TYPE=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_TYPE=Error
+API_USE_SCAN_FIELD_SEVERITY=Error
+API_USE_SCAN_METHOD_SEVERITY=Error
+API_USE_SCAN_TYPE_SEVERITY=Error
+CLASS_ELEMENT_TYPE_ADDED_METHOD=Error
+CLASS_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
+CLASS_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+CLASS_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
+CLASS_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+CLASS_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
+CLASS_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
+CLASS_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+CLASS_ELEMENT_TYPE_REMOVED_CONSTRUCTOR=Error
+CLASS_ELEMENT_TYPE_REMOVED_FIELD=Error
+CLASS_ELEMENT_TYPE_REMOVED_METHOD=Error
+CLASS_ELEMENT_TYPE_REMOVED_SUPERCLASS=Error
+CLASS_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+CLASS_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+CONSTRUCTOR_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+CONSTRUCTOR_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+CONSTRUCTOR_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
+CONSTRUCTOR_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+ENUM_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
+ENUM_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+ENUM_ELEMENT_TYPE_REMOVED_ENUM_CONSTANT=Error
+ENUM_ELEMENT_TYPE_REMOVED_FIELD=Error
+ENUM_ELEMENT_TYPE_REMOVED_METHOD=Error
+ENUM_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+FIELD_ELEMENT_TYPE_ADDED_VALUE=Error
+FIELD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+FIELD_ELEMENT_TYPE_CHANGED_FINAL_TO_NON_FINAL_STATIC_CONSTANT=Error
+FIELD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
+FIELD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
+FIELD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
+FIELD_ELEMENT_TYPE_CHANGED_TYPE=Error
+FIELD_ELEMENT_TYPE_CHANGED_VALUE=Error
+FIELD_ELEMENT_TYPE_REMOVED_TYPE_ARGUMENT=Error
+FIELD_ELEMENT_TYPE_REMOVED_VALUE=Error
+ILLEGAL_EXTEND=Warning
+ILLEGAL_IMPLEMENT=Warning
+ILLEGAL_INSTANTIATE=Warning
+ILLEGAL_OVERRIDE=Warning
+ILLEGAL_REFERENCE=Warning
+INTERFACE_ELEMENT_TYPE_ADDED_FIELD=Error
+INTERFACE_ELEMENT_TYPE_ADDED_METHOD=Error
+INTERFACE_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
+INTERFACE_ELEMENT_TYPE_ADDED_SUPER_INTERFACE_WITH_METHODS=Error
+INTERFACE_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+INTERFACE_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
+INTERFACE_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_FIELD=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_METHOD=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+INVALID_JAVADOC_TAG=Warning
+INVALID_REFERENCE_IN_SYSTEM_LIBRARIES=Warning
+LEAK_EXTEND=Warning
+LEAK_FIELD_DECL=Warning
+LEAK_IMPLEMENT=Warning
+LEAK_METHOD_PARAM=Warning
+LEAK_METHOD_RETURN_TYPE=Warning
+METHOD_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
+METHOD_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+METHOD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+METHOD_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
+METHOD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
+METHOD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
+METHOD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
+METHOD_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
+METHOD_ELEMENT_TYPE_REMOVED_ANNOTATION_DEFAULT_VALUE=Error
+METHOD_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+MISSING_EE_DESCRIPTIONS=Ignore
+TYPE_PARAMETER_ELEMENT_TYPE_ADDED_CLASS_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_ADDED_INTERFACE_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_CLASS_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_INTERFACE_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_CLASS_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_INTERFACE_BOUND=Error
+UNUSED_PROBLEM_FILTERS=Warning
+automatically_removed_unused_problem_filters=false
+eclipse.preferences.version=1
+incompatible_api_component_version=Error
+incompatible_api_component_version_include_major_without_breaking_change=Disabled
+incompatible_api_component_version_include_minor_without_api_change=Disabled
+invalid_since_tag_version=Error
+malformed_since_tag=Error
+missing_since_tag=Error
+report_api_breakage_when_major_version_incremented=Disabled
+report_resolution_errors_api_component=Warning
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.settings/org.eclipse.pde.prefs b/lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.settings/org.eclipse.pde.prefs
new file mode 100644 (file)
index 0000000..62cfa90
--- /dev/null
@@ -0,0 +1,32 @@
+compilers.f.unresolved-features=1
+compilers.f.unresolved-plugins=1
+compilers.incompatible-environment=1
+compilers.p.build=1
+compilers.p.build.bin.includes=1
+compilers.p.build.encodings=2
+compilers.p.build.java.compiler=2
+compilers.p.build.java.compliance=1
+compilers.p.build.missing.output=2
+compilers.p.build.output.library=1
+compilers.p.build.source.library=1
+compilers.p.build.src.includes=1
+compilers.p.deprecated=1
+compilers.p.discouraged-class=1
+compilers.p.internal=1
+compilers.p.missing-packages=2
+compilers.p.missing-version-export-package=2
+compilers.p.missing-version-import-package=2
+compilers.p.missing-version-require-bundle=2
+compilers.p.no-required-att=0
+compilers.p.not-externalized-att=2
+compilers.p.unknown-attribute=1
+compilers.p.unknown-class=1
+compilers.p.unknown-element=1
+compilers.p.unknown-identifier=1
+compilers.p.unknown-resource=1
+compilers.p.unresolved-ex-points=0
+compilers.p.unresolved-import=0
+compilers.s.create-docs=false
+compilers.s.doc-folder=doc
+compilers.s.open-tags=1
+eclipse.preferences.version=1
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/META-INF/MANIFEST.MF b/lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/META-INF/MANIFEST.MF
new file mode 100644 (file)
index 0000000..69db396
--- /dev/null
@@ -0,0 +1,29 @@
+Manifest-Version: 1.0
+Bundle-ManifestVersion: 2
+Bundle-Name: %Bundle-Name
+Bundle-Vendor: %Bundle-Vendor
+Bundle-Version: 1.0.0.qualifier
+Bundle-Localization: plugin
+Bundle-SymbolicName: org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests;singleton:=true
+Bundle-ActivationPolicy: lazy
+Bundle-RequiredExecutionEnvironment: JavaSE-1.7
+Export-Package: org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests
+Require-Bundle: org.apache.log4j,
+ org.eclipse.core.resources,
+ org.eclipse.core.runtime,
+ org.eclipse.tracecompass.lttng2.kernel.core,
+ org.eclipse.tracecompass.lttng2.kernel.ui,
+ org.eclipse.tracecompass.lttng2.control.ui,
+ org.eclipse.tracecompass.analysis.os.linux.ui,
+ org.eclipse.tracecompass.tmf.core,
+ org.eclipse.tracecompass.tmf.core.tests,
+ org.eclipse.tracecompass.tmf.ctf.core,
+ org.eclipse.tracecompass.tmf.ctf.core.tests,
+ org.eclipse.tracecompass.tmf.ui,
+ org.eclipse.tracecompass.tmf.ui.swtbot.tests,
+ org.eclipse.swtbot.eclipse.finder,
+ org.eclipse.swtbot.junit4_x,
+ org.eclipse.ui,
+ org.eclipse.ui.ide,
+ org.eclipse.ui.views,
+ org.junit
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/about.html b/lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/about.html
new file mode 100644 (file)
index 0000000..c258ef5
--- /dev/null
@@ -0,0 +1,28 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"/>
+<title>About</title>
+</head>
+<body lang="EN-US">
+<h2>About This Content</h2>
+<p>June 5, 2006</p>    
+<h3>License</h3>
+
+<p>The Eclipse Foundation makes available all content in this plug-in (&quot;Content&quot;).  Unless otherwise 
+indicated below, the Content is provided to you under the terms and conditions of the
+Eclipse Public License Version 1.0 (&quot;EPL&quot;).  A copy of the EPL is available 
+at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>.
+For purposes of the EPL, &quot;Program&quot; will mean the Content.</p>
+
+<p>If you did not receive this Content directly from the Eclipse Foundation, the Content is 
+being redistributed by another party (&quot;Redistributor&quot;) and different terms and conditions may
+apply to your use of any object code in the Content.  Check the Redistributor's license that was 
+provided with the Content.  If no such license exists, contact the Redistributor.  Unless otherwise
+indicated below, the terms and conditions of the EPL still apply to any source code in the Content
+and such source code may be obtained at <a href="http://www.eclipse.org/">http://www.eclipse.org</a>.</p>
+
+</body>
+</html>
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/build.properties b/lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/build.properties
new file mode 100644 (file)
index 0000000..cee367f
--- /dev/null
@@ -0,0 +1,19 @@
+###############################################################################
+# Copyright (c) 2014, 2015 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:
+#    Ericsson - Initial API and implementation
+###############################################################################
+
+source.. = src/
+bin.includes = META-INF/,\
+               .,\
+               plugin.properties,\
+               about.html
+additional.bundles = org.eclipse.jdt.annotation
+jars.extra.classpath = platform:/plugin/org.eclipse.jdt.annotation
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/plugin.properties b/lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/plugin.properties
new file mode 100644 (file)
index 0000000..2e8033d
--- /dev/null
@@ -0,0 +1,14 @@
+###############################################################################
+# Copyright (c) 2013, 2014 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:
+#     Ericsson - Initial API and implementation
+###############################################################################
+
+Bundle-Vendor = Eclipse Trace Compass
+Bundle-Name = Trace Compass LTTng Kernel UI SWTBot Tests Plug-in
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/pom.xml b/lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/pom.xml
new file mode 100644 (file)
index 0000000..58f4e34
--- /dev/null
@@ -0,0 +1,50 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+   Copyright (C) 2013 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
+-->
+
+<project xmlns="http://maven.apache.org/POM/4.0.0"
+    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+    xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+  <modelVersion>4.0.0</modelVersion>
+
+  <parent>
+    <artifactId>org.eclipse.tracecompass.lttng-parent</artifactId>
+    <groupId>org.eclipse.tracecompass</groupId>
+    <version>1.0.0-SNAPSHOT</version>
+  </parent>
+
+  <artifactId>org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests</artifactId>
+  <version>1.0.0-SNAPSHOT</version>
+  <packaging>eclipse-test-plugin</packaging>
+
+  <name>Trace Compass LTTng Kernel UI SWTBot Tests Plug-in</name>
+
+  <build>
+    <plugins>
+      <plugin>
+        <groupId>org.eclipse.tycho</groupId>
+        <artifactId>tycho-surefire-plugin</artifactId>
+        <version>${tycho-version}</version>
+        <configuration>
+          <testSuite>org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests</testSuite>
+          <testClass>org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests.AllTests</testClass>
+          <useUIHarness>true</useUIHarness>
+          <useUIThread>false</useUIThread>
+          <argLine>${tycho.testArgLine} ${base.ui.test.vmargs}</argLine>
+          <product>org.eclipse.platform.ide</product>
+          <environmentVariables>
+            <SWT_GTK3>${SWT_GTK3}</SWT_GTK3>
+          </environmentVariables>
+        </configuration>
+      </plugin>
+    </plugins>
+  </build>
+
+ <groupId>org.eclipse.tracecompass</groupId>
+</project>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/src/org/eclipse/tracecompass/lttng2/kernel/ui/swtbot/tests/AllTests.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/src/org/eclipse/tracecompass/lttng2/kernel/ui/swtbot/tests/AllTests.java
new file mode 100644 (file)
index 0000000..8a78de8
--- /dev/null
@@ -0,0 +1,30 @@
+/*******************************************************************************
+ * Copyright (c) 2013, 2015 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:
+ *   Matthew Khouzam - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests;
+
+import org.junit.runner.RunWith;
+import org.junit.runners.Suite;
+
+/**
+ * Test suite for UI on the lttng kernel perspective
+ */
+@RunWith(Suite.class)
+@Suite.SuiteClasses({
+    KernelPerspectiveChecker.class,
+    ImportAndReadKernelSmokeTest.class,
+    ControlFlowViewTest.class,
+    OpenTraceStressTest.class
+})
+public class AllTests {
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/src/org/eclipse/tracecompass/lttng2/kernel/ui/swtbot/tests/ControlFlowViewTest.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/src/org/eclipse/tracecompass/lttng2/kernel/ui/swtbot/tests/ControlFlowViewTest.java
new file mode 100644 (file)
index 0000000..a84ad87
--- /dev/null
@@ -0,0 +1,341 @@
+/*******************************************************************************
+ * Copyright (c) 2015 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:
+ *   Patrick Tasse - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests;
+
+import static org.junit.Assert.assertTrue;
+
+import java.util.List;
+
+import org.eclipse.jdt.annotation.NonNull;
+import org.eclipse.swt.SWT;
+import org.eclipse.swtbot.eclipse.finder.widgets.SWTBotView;
+import org.eclipse.swtbot.swt.finder.finders.UIThreadRunnable;
+import org.eclipse.swtbot.swt.finder.keyboard.Keyboard;
+import org.eclipse.swtbot.swt.finder.keyboard.KeyboardFactory;
+import org.eclipse.swtbot.swt.finder.keyboard.Keystrokes;
+import org.eclipse.swtbot.swt.finder.matchers.WidgetOfType;
+import org.eclipse.swtbot.swt.finder.results.VoidResult;
+import org.eclipse.swtbot.swt.finder.waits.DefaultCondition;
+import org.eclipse.swtbot.swt.finder.widgets.SWTBotTree;
+import org.eclipse.tracecompass.tmf.core.signal.TmfSelectionRangeUpdatedSignal;
+import org.eclipse.tracecompass.tmf.core.signal.TmfSignalManager;
+import org.eclipse.tracecompass.tmf.core.signal.TmfWindowRangeUpdatedSignal;
+import org.eclipse.tracecompass.tmf.core.timestamp.ITmfTimestamp;
+import org.eclipse.tracecompass.tmf.core.timestamp.TmfNanoTimestamp;
+import org.eclipse.tracecompass.tmf.core.timestamp.TmfTimeRange;
+import org.eclipse.tracecompass.tmf.core.trace.TmfTraceManager;
+import org.eclipse.tracecompass.tmf.ui.swtbot.tests.shared.ConditionHelpers;
+import org.eclipse.tracecompass.tmf.ui.widgets.timegraph.model.ILinkEvent;
+import org.eclipse.tracecompass.tmf.ui.widgets.timegraph.widgets.TimeGraphControl;
+import org.junit.Before;
+import org.junit.Test;
+
+/**
+ * SWTBot tests for Control Flow view
+ *
+ * @author Patrick Tasse
+ */
+public class ControlFlowViewTest extends KernelTest {
+
+    private static final String FOLLOW_CPU_BACKWARD = "Follow CPU Backward";
+    private static final String FOLLOW_CPU_FORWARD = "Follow CPU Forward";
+    private static final String SELECT_PREVIOUS_EVENT = "Select Previous Event";
+    private static final String SELECT_NEXT_EVENT = "Select Next Event";
+    private static final Keyboard KEYBOARD = KeyboardFactory.getSWTKeyboard();
+    private static final @NonNull ITmfTimestamp START_TIME = new TmfNanoTimestamp(1368000272650993664L);
+    private static final @NonNull ITmfTimestamp TID1_TIME1 = new TmfNanoTimestamp(1368000272651208412L);
+    private static final @NonNull ITmfTimestamp TID1_TIME2 = new TmfNanoTimestamp(1368000272656147616L);
+    private static final @NonNull ITmfTimestamp TID1_TIME3 = new TmfNanoTimestamp(1368000272656362364L);
+    private static final @NonNull ITmfTimestamp TID1_TIME4 = new TmfNanoTimestamp(1368000272663234300L);
+    private static final @NonNull ITmfTimestamp TID1_TIME5 = new TmfNanoTimestamp(1368000272663449048L);
+    private static final @NonNull ITmfTimestamp TID1_TIME6 = new TmfNanoTimestamp(1368000272665596528L);
+    private static final @NonNull ITmfTimestamp TID2_TIME1 = new TmfNanoTimestamp(1368000272651852656L);
+    private static final @NonNull ITmfTimestamp TID2_TIME2 = new TmfNanoTimestamp(1368000272652067404L);
+    private static final @NonNull ITmfTimestamp TID2_TIME3 = new TmfNanoTimestamp(1368000272652282152L);
+    private static final @NonNull ITmfTimestamp TID2_TIME4 = new TmfNanoTimestamp(1368000272652496900L);
+    private static final @NonNull ITmfTimestamp TID5_TIME1 = new TmfNanoTimestamp(1368000272652496900L);
+
+    private SWTBotView fViewBot;
+
+    /**
+     * Before Test
+     */
+    @Override
+    @Before
+    public void before() {
+        super.before();
+        fViewBot = fBot.viewByTitle("Control Flow");
+    }
+
+    /**
+     * Test keyboard navigation using ARROW_RIGHT and ARROW_LEFT
+     */
+    @Test
+    public void testKeyboardLeftRight() {
+        /* change window range to 10 ms */
+        TmfTimeRange range = new TmfTimeRange(START_TIME, START_TIME.normalize(10000000L, ITmfTimestamp.NANOSECOND_SCALE));
+        TmfSignalManager.dispatchSignal(new TmfWindowRangeUpdatedSignal(this, range));
+        fBot.waitUntil(ConditionHelpers.windowRange(range));
+
+        /* set selection to trace start time */
+        TmfSignalManager.dispatchSignal(new TmfSelectionRangeUpdatedSignal(this, START_TIME));
+        fBot.waitUntil(ConditionHelpers.selectionRange(new TmfTimeRange(START_TIME, START_TIME)));
+
+        /* select first item */
+        final SWTBotTree tree = fViewBot.bot().tree();
+        tree.pressShortcut(Keystrokes.HOME);
+
+        /* set focus on time graph */
+        final TimeGraphControl timegraph = fViewBot.bot().widget(WidgetOfType.widgetOfType(TimeGraphControl.class));
+        UIThreadRunnable.syncExec(new VoidResult() {
+            @Override
+            public void run() {
+                timegraph.setFocus();
+            }
+        });
+
+        /* press ARROW_RIGHT 3 times */
+        KEYBOARD.pressShortcut(Keystrokes.RIGHT);
+        KEYBOARD.pressShortcut(Keystrokes.RIGHT);
+        KEYBOARD.pressShortcut(Keystrokes.RIGHT);
+        fBot.waitUntil(ConditionHelpers.selectionRange(new TmfTimeRange(TID1_TIME3, TID1_TIME3)));
+        assertTrue(TmfTraceManager.getInstance().getCurrentTraceContext().getWindowRange().contains(TID1_TIME3));
+
+        /* press Shift-ARROW_RIGHT 3 times */
+        KEYBOARD.pressShortcut(Keystrokes.SHIFT, Keystrokes.RIGHT);
+        KEYBOARD.pressShortcut(Keystrokes.SHIFT, Keystrokes.RIGHT);
+        KEYBOARD.pressShortcut(Keystrokes.SHIFT, Keystrokes.RIGHT);
+        fBot.waitUntil(ConditionHelpers.selectionRange(new TmfTimeRange(TID1_TIME3, TID1_TIME6)));
+        assertTrue(TmfTraceManager.getInstance().getCurrentTraceContext().getWindowRange().contains(TID1_TIME6));
+
+        /* press Shift-ARROW_LEFT 4 times */
+        KEYBOARD.pressShortcut(Keystrokes.SHIFT, Keystrokes.LEFT);
+        KEYBOARD.pressShortcut(Keystrokes.SHIFT, Keystrokes.LEFT);
+        KEYBOARD.pressShortcut(Keystrokes.SHIFT, Keystrokes.LEFT);
+        KEYBOARD.pressShortcut(Keystrokes.SHIFT, Keystrokes.LEFT);
+        fBot.waitUntil(ConditionHelpers.selectionRange(new TmfTimeRange(TID1_TIME3, TID1_TIME2)));
+        assertTrue(TmfTraceManager.getInstance().getCurrentTraceContext().getWindowRange().contains(TID1_TIME2));
+
+        /* press ARROW_RIGHT 2 times */
+        KEYBOARD.pressShortcut(Keystrokes.RIGHT);
+        KEYBOARD.pressShortcut(Keystrokes.RIGHT);
+        fBot.waitUntil(ConditionHelpers.selectionRange(new TmfTimeRange(TID1_TIME4, TID1_TIME4)));
+        assertTrue(TmfTraceManager.getInstance().getCurrentTraceContext().getWindowRange().contains(TID1_TIME4));
+
+        /* press Shift-ARROW_LEFT 3 times */
+        KEYBOARD.pressShortcut(Keystrokes.SHIFT, Keystrokes.LEFT);
+        KEYBOARD.pressShortcut(Keystrokes.SHIFT, Keystrokes.LEFT);
+        KEYBOARD.pressShortcut(Keystrokes.SHIFT, Keystrokes.LEFT);
+        fBot.waitUntil(ConditionHelpers.selectionRange(new TmfTimeRange(TID1_TIME4, TID1_TIME1)));
+        assertTrue(TmfTraceManager.getInstance().getCurrentTraceContext().getWindowRange().contains(TID1_TIME1));
+
+        /* press Shift-ARROW_RIGHT 4 times */
+        KEYBOARD.pressShortcut(Keystrokes.SHIFT, Keystrokes.RIGHT);
+        KEYBOARD.pressShortcut(Keystrokes.SHIFT, Keystrokes.RIGHT);
+        KEYBOARD.pressShortcut(Keystrokes.SHIFT, Keystrokes.RIGHT);
+        KEYBOARD.pressShortcut(Keystrokes.SHIFT, Keystrokes.RIGHT);
+        fBot.waitUntil(ConditionHelpers.selectionRange(new TmfTimeRange(TID1_TIME4, TID1_TIME5)));
+        assertTrue(TmfTraceManager.getInstance().getCurrentTraceContext().getWindowRange().contains(TID1_TIME5));
+
+        /* press ARROW_LEFT 5 times */
+        KEYBOARD.pressShortcut(Keystrokes.LEFT);
+        KEYBOARD.pressShortcut(Keystrokes.LEFT);
+        KEYBOARD.pressShortcut(Keystrokes.LEFT);
+        KEYBOARD.pressShortcut(Keystrokes.LEFT);
+        KEYBOARD.pressShortcut(Keystrokes.LEFT);
+        fBot.waitUntil(ConditionHelpers.selectionRange(new TmfTimeRange(START_TIME, START_TIME)));
+        assertTrue(TmfTraceManager.getInstance().getCurrentTraceContext().getWindowRange().contains(START_TIME));
+    }
+
+    /**
+     * Test tool bar buttons "Select Next Event" and "Select Previous Event"
+     */
+    @Test
+    public void testToolBarSelectNextPreviousEvent() {
+        /* change window range to 10 ms */
+        TmfTimeRange range = new TmfTimeRange(START_TIME, START_TIME.normalize(10000000L, ITmfTimestamp.NANOSECOND_SCALE));
+        TmfSignalManager.dispatchSignal(new TmfWindowRangeUpdatedSignal(this, range));
+        fBot.waitUntil(ConditionHelpers.windowRange(range));
+
+        /* set selection to trace start time */
+        TmfSignalManager.dispatchSignal(new TmfSelectionRangeUpdatedSignal(this, START_TIME));
+        fBot.waitUntil(ConditionHelpers.selectionRange(new TmfTimeRange(START_TIME, START_TIME)));
+
+        /* select first item */
+        final SWTBotTree tree = fViewBot.bot().tree();
+        tree.pressShortcut(Keystrokes.HOME);
+
+        /* set focus on time graph */
+        final TimeGraphControl timegraph = fViewBot.bot().widget(WidgetOfType.widgetOfType(TimeGraphControl.class));
+        UIThreadRunnable.syncExec(new VoidResult() {
+            @Override
+            public void run() {
+                timegraph.setFocus();
+            }
+        });
+
+        /* click "Select Next Event" 3 times */
+        fViewBot.toolbarButton(SELECT_NEXT_EVENT).click();
+        fViewBot.toolbarButton(SELECT_NEXT_EVENT).click();
+        fViewBot.toolbarButton(SELECT_NEXT_EVENT).click();
+        fBot.waitUntil(ConditionHelpers.selectionRange(new TmfTimeRange(TID1_TIME3, TID1_TIME3)));
+        assertTrue(TmfTraceManager.getInstance().getCurrentTraceContext().getWindowRange().contains(TID1_TIME3));
+
+        /* shift-click "Select Next Event" 3 times */
+        fViewBot.toolbarButton(SELECT_NEXT_EVENT).click(SWT.SHIFT);
+        fViewBot.toolbarButton(SELECT_NEXT_EVENT).click(SWT.SHIFT);
+        fViewBot.toolbarButton(SELECT_NEXT_EVENT).click(SWT.SHIFT);
+        fBot.waitUntil(ConditionHelpers.selectionRange(new TmfTimeRange(TID1_TIME3, TID1_TIME6)));
+        assertTrue(TmfTraceManager.getInstance().getCurrentTraceContext().getWindowRange().contains(TID1_TIME6));
+
+        /* shift-click "Select Previous Event" 4 times */
+        fViewBot.toolbarButton(SELECT_PREVIOUS_EVENT).click(SWT.SHIFT);
+        fViewBot.toolbarButton(SELECT_PREVIOUS_EVENT).click(SWT.SHIFT);
+        fViewBot.toolbarButton(SELECT_PREVIOUS_EVENT).click(SWT.SHIFT);
+        fViewBot.toolbarButton(SELECT_PREVIOUS_EVENT).click(SWT.SHIFT);
+        fBot.waitUntil(ConditionHelpers.selectionRange(new TmfTimeRange(TID1_TIME3, TID1_TIME2)));
+        assertTrue(TmfTraceManager.getInstance().getCurrentTraceContext().getWindowRange().contains(TID1_TIME2));
+
+        /* click "Select Next Event" 2 times */
+        fViewBot.toolbarButton(SELECT_NEXT_EVENT).click();
+        fViewBot.toolbarButton(SELECT_NEXT_EVENT).click();
+        fBot.waitUntil(ConditionHelpers.selectionRange(new TmfTimeRange(TID1_TIME4, TID1_TIME4)));
+        assertTrue(TmfTraceManager.getInstance().getCurrentTraceContext().getWindowRange().contains(TID1_TIME4));
+
+        /* shift-click "Select Previous Event" 3 times */
+        fViewBot.toolbarButton(SELECT_PREVIOUS_EVENT).click(SWT.SHIFT);
+        fViewBot.toolbarButton(SELECT_PREVIOUS_EVENT).click(SWT.SHIFT);
+        fViewBot.toolbarButton(SELECT_PREVIOUS_EVENT).click(SWT.SHIFT);
+        fBot.waitUntil(ConditionHelpers.selectionRange(new TmfTimeRange(TID1_TIME4, TID1_TIME1)));
+        assertTrue(TmfTraceManager.getInstance().getCurrentTraceContext().getWindowRange().contains(TID1_TIME1));
+
+        /* shift-click "Select Next Event" 4 times */
+        fViewBot.toolbarButton(SELECT_NEXT_EVENT).click(SWT.SHIFT);
+        fViewBot.toolbarButton(SELECT_NEXT_EVENT).click(SWT.SHIFT);
+        fViewBot.toolbarButton(SELECT_NEXT_EVENT).click(SWT.SHIFT);
+        fViewBot.toolbarButton(SELECT_NEXT_EVENT).click(SWT.SHIFT);
+        fBot.waitUntil(ConditionHelpers.selectionRange(new TmfTimeRange(TID1_TIME4, TID1_TIME5)));
+        assertTrue(TmfTraceManager.getInstance().getCurrentTraceContext().getWindowRange().contains(TID1_TIME5));
+
+        /* click "Select Previous Event" 5 times */
+        fViewBot.toolbarButton(SELECT_PREVIOUS_EVENT).click();
+        fViewBot.toolbarButton(SELECT_PREVIOUS_EVENT).click();
+        fViewBot.toolbarButton(SELECT_PREVIOUS_EVENT).click();
+        fViewBot.toolbarButton(SELECT_PREVIOUS_EVENT).click();
+        fViewBot.toolbarButton(SELECT_PREVIOUS_EVENT).click();
+        fBot.waitUntil(ConditionHelpers.selectionRange(new TmfTimeRange(START_TIME, START_TIME)));
+        assertTrue(TmfTraceManager.getInstance().getCurrentTraceContext().getWindowRange().contains(START_TIME));
+    }
+
+    /**
+     * Test tool bar buttons "Follow CPU Forward" and "Follow CPU Backward"
+     */
+    @Test
+    public void testToolBarFollowCPUForwardBackward() {
+        /* change window range to 10 ms */
+        TmfTimeRange range = new TmfTimeRange(START_TIME, START_TIME.normalize(10000000L, ITmfTimestamp.NANOSECOND_SCALE));
+        TmfSignalManager.dispatchSignal(new TmfWindowRangeUpdatedSignal(this, range));
+        fBot.waitUntil(ConditionHelpers.windowRange(range));
+
+        /* set selection to trace start time */
+        TmfSignalManager.dispatchSignal(new TmfSelectionRangeUpdatedSignal(this, START_TIME));
+        fBot.waitUntil(ConditionHelpers.selectionRange(new TmfTimeRange(START_TIME, START_TIME)));
+
+        /* select first item */
+        final SWTBotTree tree = fViewBot.bot().tree();
+        tree.pressShortcut(Keystrokes.HOME);
+
+        /* set focus on time graph */
+        final TimeGraphControl timegraph = fViewBot.bot().widget(WidgetOfType.widgetOfType(TimeGraphControl.class));
+        UIThreadRunnable.syncExec(new VoidResult() {
+            @Override
+            public void run() {
+                timegraph.setFocus();
+            }
+        });
+
+        /* make sure arrows have been computed */
+        fBot.waitUntil(new DefaultCondition() {
+            @Override
+            public boolean test() throws Exception {
+                List<ILinkEvent> arrows = timegraph.getArrows();
+                return arrows.size() >= 3 &&
+                        arrows.get(0).getTime() == TID1_TIME1.getValue() &&
+                        arrows.get(1).getTime() == TID2_TIME2.getValue() &&
+                        arrows.get(2).getTime() == TID2_TIME4.getValue();
+            }
+            @Override
+            public String getFailureMessage() {
+                return "Arrows not found";
+            }
+        });
+
+        /* click "Follow CPU Forward" 3 times */
+        fViewBot.toolbarButton(FOLLOW_CPU_FORWARD).click();
+        fViewBot.toolbarButton(FOLLOW_CPU_FORWARD).click();
+        fViewBot.toolbarButton(FOLLOW_CPU_FORWARD).click();
+        fBot.waitUntil(ConditionHelpers.selectionRange(new TmfTimeRange(TID2_TIME2, TID2_TIME2)));
+        fBot.waitUntil(ConditionHelpers.treeSelectionContains(tree, 1, "2"));
+        assertTrue(TmfTraceManager.getInstance().getCurrentTraceContext().getWindowRange().contains(TID2_TIME2));
+
+        /* shift-click "Follow CPU Forward" 3 times */
+        fViewBot.toolbarButton(FOLLOW_CPU_FORWARD).click(SWT.SHIFT);
+        fViewBot.toolbarButton(FOLLOW_CPU_FORWARD).click(SWT.SHIFT);
+        fViewBot.toolbarButton(FOLLOW_CPU_FORWARD).click(SWT.SHIFT);
+        fBot.waitUntil(ConditionHelpers.selectionRange(new TmfTimeRange(TID2_TIME2, TID5_TIME1)));
+        fBot.waitUntil(ConditionHelpers.treeSelectionContains(tree, 1, "5"));
+        assertTrue(TmfTraceManager.getInstance().getCurrentTraceContext().getWindowRange().contains(TID5_TIME1));
+
+        /* shift-click "Follow CPU Backward" 4 times */
+        fViewBot.toolbarButton(FOLLOW_CPU_BACKWARD).click(SWT.SHIFT);
+        fViewBot.toolbarButton(FOLLOW_CPU_BACKWARD).click(SWT.SHIFT);
+        fViewBot.toolbarButton(FOLLOW_CPU_BACKWARD).click(SWT.SHIFT);
+        fViewBot.toolbarButton(FOLLOW_CPU_BACKWARD).click(SWT.SHIFT);
+        fBot.waitUntil(ConditionHelpers.selectionRange(new TmfTimeRange(TID2_TIME2, TID2_TIME1)));
+        fBot.waitUntil(ConditionHelpers.treeSelectionContains(tree, 1, "2"));
+        assertTrue(TmfTraceManager.getInstance().getCurrentTraceContext().getWindowRange().contains(TID2_TIME1));
+
+        /* click "Follow CPU Forward" 2 times */
+        fViewBot.toolbarButton(FOLLOW_CPU_FORWARD).click();
+        fViewBot.toolbarButton(FOLLOW_CPU_FORWARD).click();
+        fBot.waitUntil(ConditionHelpers.selectionRange(new TmfTimeRange(TID2_TIME3, TID2_TIME3)));
+        fBot.waitUntil(ConditionHelpers.treeSelectionContains(tree, 1, "2"));
+        assertTrue(TmfTraceManager.getInstance().getCurrentTraceContext().getWindowRange().contains(TID2_TIME3));
+
+        /* shift-click "Follow CPU Backward" 3 times */
+        fViewBot.toolbarButton(FOLLOW_CPU_BACKWARD).click(SWT.SHIFT);
+        fViewBot.toolbarButton(FOLLOW_CPU_BACKWARD).click(SWT.SHIFT);
+        fViewBot.toolbarButton(FOLLOW_CPU_BACKWARD).click(SWT.SHIFT);
+        fBot.waitUntil(ConditionHelpers.selectionRange(new TmfTimeRange(TID2_TIME3, TID1_TIME1)));
+        fBot.waitUntil(ConditionHelpers.treeSelectionContains(tree, 1, "1"));
+        assertTrue(TmfTraceManager.getInstance().getCurrentTraceContext().getWindowRange().contains(TID1_TIME1));
+
+        /* shift-click "Follow CPU Forward" 4 times */
+        fViewBot.toolbarButton(FOLLOW_CPU_FORWARD).click(SWT.SHIFT);
+        fViewBot.toolbarButton(FOLLOW_CPU_FORWARD).click(SWT.SHIFT);
+        fViewBot.toolbarButton(FOLLOW_CPU_FORWARD).click(SWT.SHIFT);
+        fViewBot.toolbarButton(FOLLOW_CPU_FORWARD).click(SWT.SHIFT);
+        fBot.waitUntil(ConditionHelpers.selectionRange(new TmfTimeRange(TID2_TIME3, TID2_TIME4)));
+        fBot.waitUntil(ConditionHelpers.treeSelectionContains(tree, 1, "2"));
+        assertTrue(TmfTraceManager.getInstance().getCurrentTraceContext().getWindowRange().contains(TID2_TIME4));
+
+        /* click "Follow CPU Backward" 5 times */
+        fViewBot.toolbarButton(FOLLOW_CPU_BACKWARD).click();
+        fViewBot.toolbarButton(FOLLOW_CPU_BACKWARD).click();
+        fViewBot.toolbarButton(FOLLOW_CPU_BACKWARD).click();
+        fViewBot.toolbarButton(FOLLOW_CPU_BACKWARD).click();
+        fViewBot.toolbarButton(FOLLOW_CPU_BACKWARD).click();
+        fBot.waitUntil(ConditionHelpers.selectionRange(new TmfTimeRange(START_TIME, START_TIME)));
+        assertTrue(TmfTraceManager.getInstance().getCurrentTraceContext().getWindowRange().contains(START_TIME));
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/src/org/eclipse/tracecompass/lttng2/kernel/ui/swtbot/tests/ImportAndReadKernelSmokeTest.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/src/org/eclipse/tracecompass/lttng2/kernel/ui/swtbot/tests/ImportAndReadKernelSmokeTest.java
new file mode 100644 (file)
index 0000000..c71f7a0
--- /dev/null
@@ -0,0 +1,149 @@
+/*******************************************************************************
+ * Copyright (c) 2013, 2015 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:
+ *   Matthew Khouzam - Initial API and implementation
+ *   Marc-Andre Laperle
+ *   Patrick Tasse - Extract base class from ImportAndReadKernelSmokeTest
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests;
+
+import static org.junit.Assert.assertNotNull;
+
+import java.util.List;
+
+import org.eclipse.jface.viewers.SelectionChangedEvent;
+import org.eclipse.jface.viewers.StructuredSelection;
+import org.eclipse.swtbot.eclipse.finder.SWTWorkbenchBot;
+import org.eclipse.swtbot.eclipse.finder.matchers.WidgetMatcherFactory;
+import org.eclipse.swtbot.eclipse.finder.widgets.SWTBotView;
+import org.eclipse.swtbot.swt.finder.finders.UIThreadRunnable;
+import org.eclipse.swtbot.swt.finder.junit.SWTBotJunit4ClassRunner;
+import org.eclipse.swtbot.swt.finder.results.VoidResult;
+import org.eclipse.swtbot.swt.finder.widgets.SWTBotToolbarButton;
+import org.eclipse.tracecompass.analysis.os.linux.ui.views.controlflow.ControlFlowView;
+import org.eclipse.tracecompass.analysis.os.linux.ui.views.resources.ResourcesView;
+import org.eclipse.tracecompass.tmf.core.event.ITmfEvent;
+import org.eclipse.tracecompass.tmf.core.signal.TmfSelectionRangeUpdatedSignal;
+import org.eclipse.tracecompass.tmf.core.trace.ITmfContext;
+import org.eclipse.tracecompass.tmf.ctf.core.event.CtfTmfEvent;
+import org.eclipse.tracecompass.tmf.ctf.core.tests.shared.CtfTmfTestTrace;
+import org.eclipse.tracecompass.tmf.ctf.core.trace.CtfTmfTrace;
+import org.eclipse.tracecompass.tmf.ui.editors.TmfEventsEditor;
+import org.eclipse.tracecompass.tmf.ui.swtbot.tests.shared.SWTBotUtils;
+import org.eclipse.tracecompass.tmf.ui.views.histogram.HistogramView;
+import org.eclipse.ui.IEditorPart;
+import org.eclipse.ui.IEditorReference;
+import org.eclipse.ui.IViewPart;
+import org.eclipse.ui.IViewReference;
+import org.eclipse.ui.PlatformUI;
+import org.hamcrest.Matcher;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+
+/**
+ * SWTBot Smoke test for LTTng Kernel UI.
+ *
+ * @author Matthew Khouzam
+ */
+@RunWith(SWTBotJunit4ClassRunner.class)
+public class ImportAndReadKernelSmokeTest extends KernelTest {
+
+    private static final CtfTmfTestTrace CTT = CtfTmfTestTrace.SYNTHETIC_TRACE;
+
+    private ITmfEvent fDesired1;
+    private ITmfEvent fDesired2;
+
+    /**
+     * Main test case
+     */
+    @Test
+    public void test() {
+        Matcher<IEditorReference> matcher = WidgetMatcherFactory.withPartName(CTT.getTrace().getName());
+        IEditorPart iep = fBot.editor(matcher).getReference().getEditor(true);
+        final TmfEventsEditor tmfEd = (TmfEventsEditor) iep;
+        fDesired1 = getEvent(100);
+        fDesired2 = getEvent(10000);
+        UIThreadRunnable.syncExec(new VoidResult() {
+            @Override
+            public void run() {
+                tmfEd.setFocus();
+                tmfEd.selectionChanged(new SelectionChangedEvent(tmfEd, new StructuredSelection(fDesired1)));
+            }
+        });
+        testHV(getViewPart("Histogram"));
+        testCFV((ControlFlowView) getViewPart("Control Flow"));
+        testRV((ResourcesView) getViewPart("Resources"));
+    }
+
+    private static void testCFV(ControlFlowView vp) {
+        assertNotNull(vp);
+    }
+
+    private void testHV(IViewPart vp) {
+        SWTBotView hvBot = (new SWTWorkbenchBot()).viewById(HistogramView.ID);
+        List<SWTBotToolbarButton> hvTools = hvBot.getToolbarButtons();
+        for (SWTBotToolbarButton hvTool : hvTools) {
+            if (hvTool.getToolTipText().toLowerCase().contains("lost")) {
+                hvTool.click();
+            }
+        }
+        HistogramView hv = (HistogramView) vp;
+        final TmfSelectionRangeUpdatedSignal signal = new TmfSelectionRangeUpdatedSignal(hv, fDesired1.getTimestamp());
+        final TmfSelectionRangeUpdatedSignal signal2 = new TmfSelectionRangeUpdatedSignal(hv, fDesired2.getTimestamp());
+        hv.updateTimeRange(100000);
+        SWTBotUtils.waitForJobs();
+        hv.selectionRangeUpdated(signal);
+        hv.broadcast(signal);
+        SWTBotUtils.waitForJobs();
+        SWTBotUtils.delay(1000);
+
+        hv.updateTimeRange(1000000000);
+        SWTBotUtils.waitForJobs();
+        hv.selectionRangeUpdated(signal2);
+        hv.broadcast(signal2);
+        SWTBotUtils.waitForJobs();
+        SWTBotUtils.delay(1000);
+        assertNotNull(hv);
+    }
+
+    private static void testRV(ResourcesView vp) {
+        assertNotNull(vp);
+    }
+
+    private static CtfTmfEvent getEvent(int rank) {
+        try (CtfTmfTrace trace = CtfTmfTestTrace.SYNTHETIC_TRACE.getTrace()) {
+            ITmfContext ctx = trace.seekEvent(0);
+            for (int i = 0; i < rank; i++) {
+                trace.getNext(ctx);
+            }
+            return trace.getNext(ctx);
+        }
+
+    }
+
+    private static IViewPart getViewPart(final String viewTile) {
+        final IViewPart[] vps = new IViewPart[1];
+        UIThreadRunnable.syncExec(new VoidResult() {
+            @Override
+            public void run() {
+                IViewReference[] viewRefs = PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActivePage().getViewReferences();
+                for (IViewReference viewRef : viewRefs) {
+                    IViewPart vp = viewRef.getView(true);
+                    if (vp.getTitle().equals(viewTile)) {
+                        vps[0] = vp;
+                        return;
+                    }
+                }
+            }
+        });
+
+        return vps[0];
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/src/org/eclipse/tracecompass/lttng2/kernel/ui/swtbot/tests/KernelPerspectiveChecker.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/src/org/eclipse/tracecompass/lttng2/kernel/ui/swtbot/tests/KernelPerspectiveChecker.java
new file mode 100644 (file)
index 0000000..192c1b9
--- /dev/null
@@ -0,0 +1,55 @@
+/*******************************************************************************
+ * Copyright (c) 2014, 2015 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:
+ *   Matthew Khouzam - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests;
+
+import java.util.ArrayList;
+import java.util.Arrays;
+
+import org.eclipse.tracecompass.analysis.os.linux.ui.views.controlflow.ControlFlowView;
+import org.eclipse.tracecompass.analysis.os.linux.ui.views.resources.ResourcesView;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
+import org.eclipse.tracecompass.internal.lttng2.kernel.ui.views.PerspectiveFactory;
+import org.eclipse.tracecompass.tmf.ui.swtbot.tests.shared.AbstractPerspectiveChecker;
+import org.eclipse.tracecompass.tmf.ui.views.histogram.HistogramView;
+import org.eclipse.tracecompass.tmf.ui.views.statistics.TmfStatisticsView;
+import org.eclipse.ui.IPageLayout;
+import org.junit.Before;
+
+/**
+ * Tracing perspective view checker
+ *
+ * @author Matthew Khouzam
+ */
+public class KernelPerspectiveChecker extends AbstractPerspectiveChecker {
+
+    /**
+     * Set up arrays for test
+     */
+    @Before
+    public void init() {
+        fPerspectiveId = PerspectiveFactory.ID;
+        fViewIds = new ArrayList<>();
+        fViewIds.addAll(Arrays.asList(new String[] {
+                // LTTng views
+                HistogramView.ID,
+                ControlView.ID,
+                ControlFlowView.ID,
+                ResourcesView.ID,
+                TmfStatisticsView.ID,
+                // Standard Eclipse views
+                IPageLayout.ID_PROJECT_EXPLORER,
+                IPageLayout.ID_PROP_SHEET,
+                IPageLayout.ID_BOOKMARKS
+        }));
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/src/org/eclipse/tracecompass/lttng2/kernel/ui/swtbot/tests/KernelTest.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/src/org/eclipse/tracecompass/lttng2/kernel/ui/swtbot/tests/KernelTest.java
new file mode 100644 (file)
index 0000000..ef19434
--- /dev/null
@@ -0,0 +1,132 @@
+/*******************************************************************************
+ * Copyright (c) 2013, 2015 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:
+ *   Matthew Khouzam - Initial API and implementation
+ *   Marc-Andre Laperle
+ *   Patrick Tasse - Extract base class from ImportAndReadKernelSmokeTest
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests;
+
+import static org.junit.Assert.fail;
+
+import java.util.List;
+
+import org.apache.log4j.ConsoleAppender;
+import org.apache.log4j.Logger;
+import org.apache.log4j.SimpleLayout;
+import org.eclipse.swtbot.eclipse.finder.SWTWorkbenchBot;
+import org.eclipse.swtbot.eclipse.finder.widgets.SWTBotView;
+import org.eclipse.swtbot.swt.finder.finders.UIThreadRunnable;
+import org.eclipse.swtbot.swt.finder.junit.SWTBotJunit4ClassRunner;
+import org.eclipse.swtbot.swt.finder.results.BoolResult;
+import org.eclipse.swtbot.swt.finder.utils.SWTBotPreferences;
+import org.eclipse.tracecompass.tmf.ctf.core.tests.shared.CtfTmfTestTrace;
+import org.eclipse.tracecompass.tmf.ui.swtbot.tests.shared.ConditionHelpers;
+import org.eclipse.tracecompass.tmf.ui.swtbot.tests.shared.SWTBotUtils;
+import org.eclipse.ui.PlatformUI;
+import org.eclipse.ui.WorkbenchException;
+import org.junit.After;
+import org.junit.AfterClass;
+import org.junit.Before;
+import org.junit.BeforeClass;
+import org.junit.runner.RunWith;
+
+/**
+ * Base SWTBot test for LTTng Kernel UI.
+ *
+ * @author Matthew Khouzam
+ */
+@RunWith(SWTBotJunit4ClassRunner.class)
+public class KernelTest {
+
+    private static final String TRACE_TYPE = "org.eclipse.linuxtools.lttng2.kernel.tracetype";
+    private static final String KERNEL_PERSPECTIVE_ID = "org.eclipse.linuxtools.lttng2.kernel.ui.perspective";
+    private static final String TRACE_PROJECT_NAME = "test";
+    private static final CtfTmfTestTrace CTT = CtfTmfTestTrace.SYNTHETIC_TRACE;
+
+    /** The workbench bot */
+    protected static SWTWorkbenchBot fBot;
+
+    /** The Log4j logger instance. */
+    private static final Logger fLogger = Logger.getRootLogger();
+
+    /**
+     * Before Class
+     */
+    @BeforeClass
+    public static void beforeClass() {
+        SWTBotUtils.failIfUIThread();
+
+        /* set up for swtbot */
+        SWTBotPreferences.TIMEOUT = 20000; /* 20 second timeout */
+        fLogger.removeAllAppenders();
+        fLogger.addAppender(new ConsoleAppender(new SimpleLayout(), ConsoleAppender.SYSTEM_OUT));
+        fBot = new SWTWorkbenchBot();
+
+        final List<SWTBotView> openViews = fBot.views();
+        for (SWTBotView view : openViews) {
+            if (view.getTitle().equals("Welcome")) {
+                view.close();
+                fBot.waitUntil(ConditionHelpers.ViewIsClosed(view));
+            }
+        }
+        /* Switch perspectives */
+        switchKernelPerspective();
+        /* Finish waiting for eclipse to load */
+        SWTBotUtils.waitForJobs();
+        SWTBotUtils.createProject(TRACE_PROJECT_NAME);
+    }
+
+    /**
+     * After Class
+     */
+    @AfterClass
+    public static void afterClass() {
+        SWTBotUtils.deleteProject(TRACE_PROJECT_NAME, fBot);
+        fLogger.removeAllAppenders();
+    }
+
+    private static void switchKernelPerspective() {
+        final Exception retE[] = new Exception[1];
+        if (!UIThreadRunnable.syncExec(new BoolResult() {
+            @Override
+            public Boolean run() {
+                try {
+                    PlatformUI.getWorkbench().showPerspective(KERNEL_PERSPECTIVE_ID,
+                            PlatformUI.getWorkbench().getActiveWorkbenchWindow());
+                } catch (WorkbenchException e) {
+                    retE[0] = e;
+                    return false;
+                }
+                return true;
+            }
+        })) {
+            fail(retE[0].getMessage());
+        }
+
+    }
+
+    /**
+     * Before Test
+     */
+    @Before
+    public void before() {
+        SWTBotUtils.openTrace(TRACE_PROJECT_NAME, CTT.getPath(), TRACE_TYPE);
+        SWTBotUtils.activateEditor(fBot, CTT.getTrace().getName());
+    }
+
+    /**
+     * After Test
+     */
+    @After
+    public void after() {
+        fBot.closeAllEditors();
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/src/org/eclipse/tracecompass/lttng2/kernel/ui/swtbot/tests/OpenTraceStressTest.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/src/org/eclipse/tracecompass/lttng2/kernel/ui/swtbot/tests/OpenTraceStressTest.java
new file mode 100644 (file)
index 0000000..015779d
--- /dev/null
@@ -0,0 +1,181 @@
+/*******************************************************************************
+ * Copyright (c) 2014, 2015 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests;
+
+import static org.junit.Assert.assertNotNull;
+import static org.junit.Assert.fail;
+import static org.junit.Assume.assumeTrue;
+
+import java.io.ByteArrayOutputStream;
+import java.io.File;
+import java.io.IOException;
+import java.io.PrintStream;
+
+import org.eclipse.core.runtime.IStatus;
+import org.eclipse.core.runtime.MultiStatus;
+import org.eclipse.core.runtime.jobs.IJobChangeEvent;
+import org.eclipse.core.runtime.jobs.IJobManager;
+import org.eclipse.core.runtime.jobs.Job;
+import org.eclipse.core.runtime.jobs.JobChangeAdapter;
+import org.eclipse.osgi.util.NLS;
+import org.eclipse.swtbot.eclipse.finder.SWTWorkbenchBot;
+import org.eclipse.swtbot.swt.finder.junit.SWTBotJunit4ClassRunner;
+import org.eclipse.swtbot.swt.finder.utils.SWTBotPreferences;
+import org.eclipse.tracecompass.tmf.core.analysis.Messages;
+import org.eclipse.tracecompass.tmf.ctf.core.tests.shared.CtfTmfTestTrace;
+import org.eclipse.tracecompass.tmf.ui.swtbot.tests.shared.SWTBotUtils;
+import org.junit.BeforeClass;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+
+/**
+ * SWTBot stress test for opening and closing of traces.
+ *
+ * @author Bernd Hufmann
+ */
+@RunWith(SWTBotJunit4ClassRunner.class)
+public class OpenTraceStressTest {
+
+    private static final String TRACE_TYPE = "org.eclipse.linuxtools.lttng2.kernel.tracetype";
+    private static final String KERNEL_PERSPECTIVE_ID = "org.eclipse.linuxtools.lttng2.kernel.ui.perspective";
+    private static final CtfTmfTestTrace CTF_TRACE = CtfTmfTestTrace.SYNC_DEST;
+    private static final String TRACE_PROJECT_NAME = "test";
+
+    private static SWTWorkbenchBot workbenchbot;
+
+    /**
+     * Test Class setup
+     */
+    @BeforeClass
+    public static void init() {
+        SWTBotUtils.failIfUIThread();
+
+        /* Set up for swtbot */
+        SWTBotPreferences.TIMEOUT = 20000; /* 20 second timeout */
+
+        workbenchbot = new SWTWorkbenchBot();
+
+        /* Close welcome view */
+        SWTBotUtils.closeView("Welcome", workbenchbot);
+
+        /* Switch perspectives */
+        SWTBotUtils.switchToPerspective(KERNEL_PERSPECTIVE_ID);
+
+        /* Finish waiting for eclipse to load */
+        SWTBotUtils.waitForJobs();
+    }
+
+    /**
+     * Main test case to test opening and closing of traces concurrently.
+     */
+    @Test
+    public void testOpenAndCloseConcurrency() {
+        SWTBotUtils.createProject(TRACE_PROJECT_NAME);
+
+        File fTestFile = new File(CTF_TRACE.getPath());
+
+        String path = fTestFile.getAbsolutePath();
+
+        assertNotNull(fTestFile);
+        assumeTrue(fTestFile.exists());
+
+        /*
+         *  This opening and closing of traces will trigger several threads for analysis which
+         *  will be closed concurrently. There used to be a concurrency bug (447434) which should
+         *  be fixed by now and this test should run without any exceptions.
+         *
+         *  Since the failure depends on timing it only happened sometimes before the bug fix
+         *  using this test.
+         */
+        final MultiStatus status = new MultiStatus("lttn2.kernel.ui.swtbot.tests", IStatus.OK, null, null);
+        IJobManager mgr = Job.getJobManager();
+        JobChangeAdapter changeListener = new JobChangeAdapter() {
+            @Override
+            public void done(IJobChangeEvent event) {
+                Job job = event.getJob();
+                // Check for analysis failure
+                String jobNamePrefix = NLS.bind(Messages.TmfAbstractAnalysisModule_RunningAnalysis, "");
+                if ((job.getName().startsWith(jobNamePrefix)) && (job.getResult().getSeverity() == IStatus.ERROR)) {
+                    status.add(job.getResult());
+                }
+            }
+        };
+        mgr.addJobChangeListener(changeListener);
+        for (int i = 0; i < 10; i++) {
+            SWTBotUtils.openTrace(TRACE_PROJECT_NAME, path, TRACE_TYPE, false);
+            SWTBotUtils.openTrace(TRACE_PROJECT_NAME, path, TRACE_TYPE, false);
+            SWTBotUtils.openTrace(TRACE_PROJECT_NAME, path, TRACE_TYPE, false);
+            SWTBotUtils.openTrace(TRACE_PROJECT_NAME, path, TRACE_TYPE, false);
+            SWTBotUtils.openTrace(TRACE_PROJECT_NAME, path, TRACE_TYPE, false);
+            // Add little delay so that treads have a chance to start
+            SWTBotUtils.delay(1000);
+            workbenchbot.closeAllEditors();
+
+            if (!status.isOK()) {
+                SWTBotUtils.deleteProject(TRACE_PROJECT_NAME, workbenchbot);
+                fail(handleErrorStatus(status));
+            }
+        }
+        SWTBotUtils.deleteProject(TRACE_PROJECT_NAME, workbenchbot);
+    }
+
+    private static String handleErrorStatus(MultiStatus status) {
+
+        // Build a string with all the children status messages, exception
+        // messages and stack traces
+        StringBuilder sb = new StringBuilder();
+        for (IStatus childStatus : status.getChildren()) {
+            StringBuilder childSb = new StringBuilder();
+            if (!childStatus.getMessage().isEmpty()) {
+                childSb.append(childStatus.getMessage() + '\n');
+            }
+
+            Throwable childException = childStatus.getException();
+            if (childException != null) {
+                String reason = childException.getMessage();
+                // Some system exceptions have no message
+                if (reason == null) {
+                    reason = childException.toString();
+                }
+
+                String stackMessage = getExceptionStackMessage(childException);
+                if (stackMessage == null) {
+                    stackMessage = reason;
+                }
+
+                childSb.append(stackMessage);
+            }
+
+            if (childSb.length() > 0) {
+                childSb.insert(0, '\n');
+                sb.append(childSb.toString());
+            }
+        }
+        return sb.toString();
+    }
+
+    private static String getExceptionStackMessage(Throwable exception) {
+        String stackMessage = null;
+        ByteArrayOutputStream baos = new ByteArrayOutputStream();
+        PrintStream ps = new PrintStream(baos);
+        exception.printStackTrace(ps);
+        ps.flush();
+        try {
+            baos.flush();
+            stackMessage = baos.toString();
+        } catch (IOException e) {
+        }
+
+        return stackMessage;
+    }
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.ui/.classpath b/lttng/org.eclipse.tracecompass.lttng2.kernel.ui/.classpath
new file mode 100644 (file)
index 0000000..098194c
--- /dev/null
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+       <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7"/>
+       <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
+       <classpathentry kind="src" path="src"/>
+       <classpathentry kind="output" path="bin"/>
+</classpath>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.ui/.project b/lttng/org.eclipse.tracecompass.lttng2.kernel.ui/.project
new file mode 100644 (file)
index 0000000..9206b86
--- /dev/null
@@ -0,0 +1,34 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+       <name>org.eclipse.tracecompass.lttng2.kernel.ui</name>
+       <comment></comment>
+       <projects>
+       </projects>
+       <buildSpec>
+               <buildCommand>
+                       <name>org.eclipse.jdt.core.javabuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+               <buildCommand>
+                       <name>org.eclipse.pde.ManifestBuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+               <buildCommand>
+                       <name>org.eclipse.pde.SchemaBuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+               <buildCommand>
+                       <name>org.eclipse.pde.api.tools.apiAnalysisBuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+       </buildSpec>
+       <natures>
+               <nature>org.eclipse.pde.PluginNature</nature>
+               <nature>org.eclipse.jdt.core.javanature</nature>
+               <nature>org.eclipse.pde.api.tools.apiAnalysisNature</nature>
+       </natures>
+</projectDescription>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.ui/.settings/org.eclipse.core.resources.prefs b/lttng/org.eclipse.tracecompass.lttng2.kernel.ui/.settings/org.eclipse.core.resources.prefs
new file mode 100644 (file)
index 0000000..99f26c0
--- /dev/null
@@ -0,0 +1,2 @@
+eclipse.preferences.version=1
+encoding/<project>=UTF-8
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.ui/.settings/org.eclipse.core.runtime.prefs b/lttng/org.eclipse.tracecompass.lttng2.kernel.ui/.settings/org.eclipse.core.runtime.prefs
new file mode 100644 (file)
index 0000000..5a0ad22
--- /dev/null
@@ -0,0 +1,2 @@
+eclipse.preferences.version=1
+line.separator=\n
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.ui/.settings/org.eclipse.jdt.core.prefs b/lttng/org.eclipse.tracecompass.lttng2.kernel.ui/.settings/org.eclipse.jdt.core.prefs
new file mode 100644 (file)
index 0000000..a2b5e6b
--- /dev/null
@@ -0,0 +1,405 @@
+eclipse.preferences.version=1
+org.eclipse.jdt.core.codeComplete.argumentPrefixes=
+org.eclipse.jdt.core.codeComplete.argumentSuffixes=
+org.eclipse.jdt.core.codeComplete.fieldPrefixes=f
+org.eclipse.jdt.core.codeComplete.fieldSuffixes=
+org.eclipse.jdt.core.codeComplete.localPrefixes=
+org.eclipse.jdt.core.codeComplete.localSuffixes=
+org.eclipse.jdt.core.codeComplete.staticFieldPrefixes=
+org.eclipse.jdt.core.codeComplete.staticFieldSuffixes=
+org.eclipse.jdt.core.codeComplete.staticFinalFieldPrefixes=
+org.eclipse.jdt.core.codeComplete.staticFinalFieldSuffixes=
+org.eclipse.jdt.core.compiler.annotation.inheritNullAnnotations=enabled
+org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore
+org.eclipse.jdt.core.compiler.annotation.nonnull=org.eclipse.jdt.annotation.NonNull
+org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=org.eclipse.jdt.annotation.NonNullByDefault
+org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nullable
+org.eclipse.jdt.core.compiler.annotation.nullanalysis=enabled
+org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
+org.eclipse.jdt.core.compiler.codegen.methodParameters=do not generate
+org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
+org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
+org.eclipse.jdt.core.compiler.compliance=1.7
+org.eclipse.jdt.core.compiler.debug.lineNumber=generate
+org.eclipse.jdt.core.compiler.debug.localVariable=generate
+org.eclipse.jdt.core.compiler.debug.sourceFile=generate
+org.eclipse.jdt.core.compiler.doc.comment.support=enabled
+org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=error
+org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
+org.eclipse.jdt.core.compiler.problem.autoboxing=ignore
+org.eclipse.jdt.core.compiler.problem.comparingIdentical=error
+org.eclipse.jdt.core.compiler.problem.deadCode=error
+org.eclipse.jdt.core.compiler.problem.deprecation=error
+org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled
+org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=enabled
+org.eclipse.jdt.core.compiler.problem.discouragedReference=warning
+org.eclipse.jdt.core.compiler.problem.emptyStatement=error
+org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
+org.eclipse.jdt.core.compiler.problem.explicitlyClosedAutoCloseable=error
+org.eclipse.jdt.core.compiler.problem.fallthroughCase=error
+org.eclipse.jdt.core.compiler.problem.fatalOptionalError=disabled
+org.eclipse.jdt.core.compiler.problem.fieldHiding=error
+org.eclipse.jdt.core.compiler.problem.finalParameterBound=error
+org.eclipse.jdt.core.compiler.problem.finallyBlockNotCompletingNormally=error
+org.eclipse.jdt.core.compiler.problem.forbiddenReference=error
+org.eclipse.jdt.core.compiler.problem.hiddenCatchBlock=error
+org.eclipse.jdt.core.compiler.problem.includeNullInfoFromAsserts=disabled
+org.eclipse.jdt.core.compiler.problem.incompatibleNonInheritedInterfaceMethod=error
+org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch=error
+org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=error
+org.eclipse.jdt.core.compiler.problem.invalidJavadoc=warning
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTags=enabled
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsDeprecatedRef=enabled
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsNotVisibleRef=enabled
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsVisibility=protected
+org.eclipse.jdt.core.compiler.problem.localVariableHiding=error
+org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=error
+org.eclipse.jdt.core.compiler.problem.missingDefaultCase=error
+org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=error
+org.eclipse.jdt.core.compiler.problem.missingEnumCaseDespiteDefault=enabled
+org.eclipse.jdt.core.compiler.problem.missingHashCodeMethod=error
+org.eclipse.jdt.core.compiler.problem.missingJavadocComments=warning
+org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsOverriding=disabled
+org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsVisibility=protected
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagDescription=all_standard_tags
+org.eclipse.jdt.core.compiler.problem.missingJavadocTags=warning
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagsMethodTypeParameters=disabled
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagsOverriding=disabled
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagsVisibility=protected
+org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotation=error
+org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotationForInterfaceMethodImplementation=enabled
+org.eclipse.jdt.core.compiler.problem.missingSerialVersion=error
+org.eclipse.jdt.core.compiler.problem.missingSynchronizedOnInheritedMethod=error
+org.eclipse.jdt.core.compiler.problem.noEffectAssignment=error
+org.eclipse.jdt.core.compiler.problem.noImplicitStringConversion=error
+org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=warning
+org.eclipse.jdt.core.compiler.problem.nonnullParameterAnnotationDropped=warning
+org.eclipse.jdt.core.compiler.problem.nullAnnotationInferenceConflict=warning
+org.eclipse.jdt.core.compiler.problem.nullReference=error
+org.eclipse.jdt.core.compiler.problem.nullSpecViolation=error
+org.eclipse.jdt.core.compiler.problem.nullUncheckedConversion=warning
+org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=error
+org.eclipse.jdt.core.compiler.problem.parameterAssignment=error
+org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=error
+org.eclipse.jdt.core.compiler.problem.potentialNullReference=error
+org.eclipse.jdt.core.compiler.problem.potentiallyUnclosedCloseable=warning
+org.eclipse.jdt.core.compiler.problem.rawTypeReference=warning
+org.eclipse.jdt.core.compiler.problem.redundantNullAnnotation=warning
+org.eclipse.jdt.core.compiler.problem.redundantNullCheck=error
+org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=error
+org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=error
+org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore
+org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=error
+org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled
+org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=error
+org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=disabled
+org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled
+org.eclipse.jdt.core.compiler.problem.syntacticNullAnalysisForFields=enabled
+org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=ignore
+org.eclipse.jdt.core.compiler.problem.typeParameterHiding=error
+org.eclipse.jdt.core.compiler.problem.unavoidableGenericTypeProblems=disabled
+org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=warning
+org.eclipse.jdt.core.compiler.problem.unclosedCloseable=error
+org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=ignore
+org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=error
+org.eclipse.jdt.core.compiler.problem.unnecessaryElse=error
+org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=error
+org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=warning
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionExemptExceptionAndThrowable=disabled
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionIncludeDocCommentReference=disabled
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverriding=disabled
+org.eclipse.jdt.core.compiler.problem.unusedExceptionParameter=ignore
+org.eclipse.jdt.core.compiler.problem.unusedImport=error
+org.eclipse.jdt.core.compiler.problem.unusedLabel=error
+org.eclipse.jdt.core.compiler.problem.unusedLocal=error
+org.eclipse.jdt.core.compiler.problem.unusedObjectAllocation=ignore
+org.eclipse.jdt.core.compiler.problem.unusedParameter=error
+org.eclipse.jdt.core.compiler.problem.unusedParameterIncludeDocCommentReference=enabled
+org.eclipse.jdt.core.compiler.problem.unusedParameterWhenImplementingAbstract=disabled
+org.eclipse.jdt.core.compiler.problem.unusedParameterWhenOverridingConcrete=disabled
+org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=error
+org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=error
+org.eclipse.jdt.core.compiler.problem.unusedWarningToken=error
+org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=error
+org.eclipse.jdt.core.compiler.source=1.7
+org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=16
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_call=16
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation=16
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression=16
+org.eclipse.jdt.core.formatter.alignment_for_assignment=0
+org.eclipse.jdt.core.formatter.alignment_for_binary_expression=16
+org.eclipse.jdt.core.formatter.alignment_for_compact_if=16
+org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=80
+org.eclipse.jdt.core.formatter.alignment_for_enum_constants=0
+org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=16
+org.eclipse.jdt.core.formatter.alignment_for_method_declaration=0
+org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16
+org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=80
+org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation=0
+org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_constructor_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_method_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_union_type_in_multicatch=16
+org.eclipse.jdt.core.formatter.blank_lines_after_imports=1
+org.eclipse.jdt.core.formatter.blank_lines_after_package=1
+org.eclipse.jdt.core.formatter.blank_lines_before_field=0
+org.eclipse.jdt.core.formatter.blank_lines_before_first_class_body_declaration=0
+org.eclipse.jdt.core.formatter.blank_lines_before_imports=1
+org.eclipse.jdt.core.formatter.blank_lines_before_member_type=1
+org.eclipse.jdt.core.formatter.blank_lines_before_method=1
+org.eclipse.jdt.core.formatter.blank_lines_before_new_chunk=1
+org.eclipse.jdt.core.formatter.blank_lines_before_package=0
+org.eclipse.jdt.core.formatter.blank_lines_between_import_groups=1
+org.eclipse.jdt.core.formatter.blank_lines_between_type_declarations=1
+org.eclipse.jdt.core.formatter.brace_position_for_annotation_type_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_array_initializer=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_block=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_block_in_case=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_constructor_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_enum_constant=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_enum_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_method_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_switch=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_type_declaration=end_of_line
+org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_block_comment=false
+org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_javadoc_comment=false
+org.eclipse.jdt.core.formatter.comment.format_block_comments=true
+org.eclipse.jdt.core.formatter.comment.format_header=false
+org.eclipse.jdt.core.formatter.comment.format_html=true
+org.eclipse.jdt.core.formatter.comment.format_javadoc_comments=true
+org.eclipse.jdt.core.formatter.comment.format_line_comments=true
+org.eclipse.jdt.core.formatter.comment.format_source_code=true
+org.eclipse.jdt.core.formatter.comment.indent_parameter_description=true
+org.eclipse.jdt.core.formatter.comment.indent_root_tags=true
+org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags=insert
+org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter=insert
+org.eclipse.jdt.core.formatter.comment.line_length=80
+org.eclipse.jdt.core.formatter.comment.new_lines_at_block_boundaries=true
+org.eclipse.jdt.core.formatter.comment.new_lines_at_javadoc_boundaries=true
+org.eclipse.jdt.core.formatter.comment.preserve_white_space_between_code_and_line_comments=false
+org.eclipse.jdt.core.formatter.compact_else_if=true
+org.eclipse.jdt.core.formatter.continuation_indentation=2
+org.eclipse.jdt.core.formatter.continuation_indentation_for_array_initializer=2
+org.eclipse.jdt.core.formatter.disabling_tag=@formatter\:off
+org.eclipse.jdt.core.formatter.enabling_tag=@formatter\:on
+org.eclipse.jdt.core.formatter.format_guardian_clause_on_one_line=false
+org.eclipse.jdt.core.formatter.format_line_comment_starting_on_first_column=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_annotation_declaration_header=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_constant_header=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_declaration_header=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_type_header=true
+org.eclipse.jdt.core.formatter.indent_breaks_compare_to_cases=true
+org.eclipse.jdt.core.formatter.indent_empty_lines=false
+org.eclipse.jdt.core.formatter.indent_statements_compare_to_block=true
+org.eclipse.jdt.core.formatter.indent_statements_compare_to_body=true
+org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_cases=true
+org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_switch=false
+org.eclipse.jdt.core.formatter.indentation.size=4
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_field=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_local_variable=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_method=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_package=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_parameter=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_type=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_label=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_opening_brace_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_at_end_of_file_if_missing=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_finally_in_try_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_while_in_do_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_annotation_declaration=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_anonymous_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_block=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter=insert
+org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_binary_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_paren_in_cast=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_assert=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_case=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_labeled_statement=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_allocation_expression=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_annotation=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_throws=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_constant_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_declarations=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_explicitconstructorcall_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_increments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_inits=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_throws=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_invocation_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_field_declarations=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_local_declarations=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_parameterized_type_reference=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_superinterfaces=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_ellipsis=insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_brace_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_cast=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_catch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_for=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_if=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_parenthesized_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_switch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_synchronized=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_try=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_while=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_try_resources=insert
+org.eclipse.jdt.core.formatter.insert_space_after_unary_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter=insert
+org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_binary_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_brace_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_cast=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_catch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_for=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_if=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_parenthesized_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_switch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_synchronized=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_try=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_while=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_assert=insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_case=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_default=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_labeled_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_throws=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_constant_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_declarations=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_explicitconstructorcall_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_increments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_inits=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_throws=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_invocation_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_field_declarations=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_local_declarations=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_superinterfaces=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_ellipsis=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_annotation_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_anonymous_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_block=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_constructor_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_constant=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_method_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_switch=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation_type_member_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_catch=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_if=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_parenthesized_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_switch=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_synchronized=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_try=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_while=insert
+org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_return=insert
+org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_throw=insert
+org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_semicolon=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_try_resources=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_unary_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_brackets_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_annotation_type_member_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.join_lines_in_comments=true
+org.eclipse.jdt.core.formatter.join_wrapped_lines=false
+org.eclipse.jdt.core.formatter.keep_else_statement_on_same_line=false
+org.eclipse.jdt.core.formatter.keep_empty_array_initializer_on_one_line=false
+org.eclipse.jdt.core.formatter.keep_imple_if_on_one_line=false
+org.eclipse.jdt.core.formatter.keep_then_statement_on_same_line=false
+org.eclipse.jdt.core.formatter.lineSplit=250
+org.eclipse.jdt.core.formatter.never_indent_block_comments_on_first_column=false
+org.eclipse.jdt.core.formatter.never_indent_line_comments_on_first_column=false
+org.eclipse.jdt.core.formatter.number_of_blank_lines_at_beginning_of_method_body=0
+org.eclipse.jdt.core.formatter.number_of_empty_lines_to_preserve=1
+org.eclipse.jdt.core.formatter.put_empty_statement_on_new_line=true
+org.eclipse.jdt.core.formatter.tabulation.char=space
+org.eclipse.jdt.core.formatter.tabulation.size=4
+org.eclipse.jdt.core.formatter.use_on_off_tags=false
+org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false
+org.eclipse.jdt.core.formatter.wrap_before_binary_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_or_operator_multicatch=true
+org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.ui/.settings/org.eclipse.jdt.ui.prefs b/lttng/org.eclipse.tracecompass.lttng2.kernel.ui/.settings/org.eclipse.jdt.ui.prefs
new file mode 100644 (file)
index 0000000..232a3fd
--- /dev/null
@@ -0,0 +1,60 @@
+eclipse.preferences.version=1
+editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true
+formatter_profile=_tmf-style
+formatter_settings_version=12
+org.eclipse.jdt.ui.exception.name=e
+org.eclipse.jdt.ui.gettersetter.use.is=true
+org.eclipse.jdt.ui.keywordthis=false
+org.eclipse.jdt.ui.overrideannotation=true
+sp_cleanup.add_default_serial_version_id=true
+sp_cleanup.add_generated_serial_version_id=false
+sp_cleanup.add_missing_annotations=false
+sp_cleanup.add_missing_deprecated_annotations=true
+sp_cleanup.add_missing_methods=false
+sp_cleanup.add_missing_nls_tags=false
+sp_cleanup.add_missing_override_annotations=true
+sp_cleanup.add_missing_override_annotations_interface_methods=true
+sp_cleanup.add_serial_version_id=false
+sp_cleanup.always_use_blocks=true
+sp_cleanup.always_use_parentheses_in_expressions=false
+sp_cleanup.always_use_this_for_non_static_field_access=false
+sp_cleanup.always_use_this_for_non_static_method_access=false
+sp_cleanup.convert_to_enhanced_for_loop=false
+sp_cleanup.correct_indentation=false
+sp_cleanup.format_source_code=false
+sp_cleanup.format_source_code_changes_only=false
+sp_cleanup.make_local_variable_final=false
+sp_cleanup.make_parameters_final=false
+sp_cleanup.make_private_fields_final=true
+sp_cleanup.make_type_abstract_if_missing_method=false
+sp_cleanup.make_variable_declarations_final=false
+sp_cleanup.never_use_blocks=false
+sp_cleanup.never_use_parentheses_in_expressions=true
+sp_cleanup.on_save_use_additional_actions=true
+sp_cleanup.organize_imports=false
+sp_cleanup.qualify_static_field_accesses_with_declaring_class=false
+sp_cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=true
+sp_cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=true
+sp_cleanup.qualify_static_member_accesses_with_declaring_class=false
+sp_cleanup.qualify_static_method_accesses_with_declaring_class=false
+sp_cleanup.remove_private_constructors=true
+sp_cleanup.remove_trailing_whitespaces=true
+sp_cleanup.remove_trailing_whitespaces_all=true
+sp_cleanup.remove_trailing_whitespaces_ignore_empty=false
+sp_cleanup.remove_unnecessary_casts=false
+sp_cleanup.remove_unnecessary_nls_tags=false
+sp_cleanup.remove_unused_imports=false
+sp_cleanup.remove_unused_local_variables=false
+sp_cleanup.remove_unused_private_fields=true
+sp_cleanup.remove_unused_private_members=false
+sp_cleanup.remove_unused_private_methods=true
+sp_cleanup.remove_unused_private_types=true
+sp_cleanup.sort_members=false
+sp_cleanup.sort_members_all=false
+sp_cleanup.use_blocks=true
+sp_cleanup.use_blocks_only_for_return_and_throw=false
+sp_cleanup.use_parentheses_in_expressions=false
+sp_cleanup.use_this_for_non_static_field_access=false
+sp_cleanup.use_this_for_non_static_field_access_only_if_necessary=true
+sp_cleanup.use_this_for_non_static_method_access=false
+sp_cleanup.use_this_for_non_static_method_access_only_if_necessary=true
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.ui/.settings/org.eclipse.pde.api.tools.prefs b/lttng/org.eclipse.tracecompass.lttng2.kernel.ui/.settings/org.eclipse.pde.api.tools.prefs
new file mode 100644 (file)
index 0000000..acc3abd
--- /dev/null
@@ -0,0 +1,97 @@
+ANNOTATION_ELEMENT_TYPE_ADDED_METHOD_WITHOUT_DEFAULT_VALUE=Error
+ANNOTATION_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+ANNOTATION_ELEMENT_TYPE_REMOVED_FIELD=Error
+ANNOTATION_ELEMENT_TYPE_REMOVED_METHOD=Error
+ANNOTATION_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_API_TYPE=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_API_TYPE=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_TYPE=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_TYPE=Error
+API_USE_SCAN_FIELD_SEVERITY=Error
+API_USE_SCAN_METHOD_SEVERITY=Error
+API_USE_SCAN_TYPE_SEVERITY=Error
+CLASS_ELEMENT_TYPE_ADDED_METHOD=Error
+CLASS_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
+CLASS_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+CLASS_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
+CLASS_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+CLASS_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
+CLASS_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
+CLASS_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+CLASS_ELEMENT_TYPE_REMOVED_CONSTRUCTOR=Error
+CLASS_ELEMENT_TYPE_REMOVED_FIELD=Error
+CLASS_ELEMENT_TYPE_REMOVED_METHOD=Error
+CLASS_ELEMENT_TYPE_REMOVED_SUPERCLASS=Error
+CLASS_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+CLASS_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+CONSTRUCTOR_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+CONSTRUCTOR_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+CONSTRUCTOR_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
+CONSTRUCTOR_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+ENUM_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
+ENUM_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+ENUM_ELEMENT_TYPE_REMOVED_ENUM_CONSTANT=Error
+ENUM_ELEMENT_TYPE_REMOVED_FIELD=Error
+ENUM_ELEMENT_TYPE_REMOVED_METHOD=Error
+ENUM_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+FIELD_ELEMENT_TYPE_ADDED_VALUE=Error
+FIELD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+FIELD_ELEMENT_TYPE_CHANGED_FINAL_TO_NON_FINAL_STATIC_CONSTANT=Error
+FIELD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
+FIELD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
+FIELD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
+FIELD_ELEMENT_TYPE_CHANGED_TYPE=Error
+FIELD_ELEMENT_TYPE_CHANGED_VALUE=Error
+FIELD_ELEMENT_TYPE_REMOVED_TYPE_ARGUMENT=Error
+FIELD_ELEMENT_TYPE_REMOVED_VALUE=Error
+ILLEGAL_EXTEND=Warning
+ILLEGAL_IMPLEMENT=Warning
+ILLEGAL_INSTANTIATE=Warning
+ILLEGAL_OVERRIDE=Warning
+ILLEGAL_REFERENCE=Warning
+INTERFACE_ELEMENT_TYPE_ADDED_FIELD=Error
+INTERFACE_ELEMENT_TYPE_ADDED_METHOD=Error
+INTERFACE_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
+INTERFACE_ELEMENT_TYPE_ADDED_SUPER_INTERFACE_WITH_METHODS=Error
+INTERFACE_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+INTERFACE_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
+INTERFACE_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_FIELD=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_METHOD=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+INVALID_JAVADOC_TAG=Warning
+INVALID_REFERENCE_IN_SYSTEM_LIBRARIES=Warning
+LEAK_EXTEND=Warning
+LEAK_FIELD_DECL=Warning
+LEAK_IMPLEMENT=Warning
+LEAK_METHOD_PARAM=Warning
+LEAK_METHOD_RETURN_TYPE=Warning
+METHOD_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
+METHOD_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+METHOD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+METHOD_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
+METHOD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
+METHOD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
+METHOD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
+METHOD_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
+METHOD_ELEMENT_TYPE_REMOVED_ANNOTATION_DEFAULT_VALUE=Error
+METHOD_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+MISSING_EE_DESCRIPTIONS=Ignore
+TYPE_PARAMETER_ELEMENT_TYPE_ADDED_CLASS_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_ADDED_INTERFACE_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_CLASS_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_INTERFACE_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_CLASS_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_INTERFACE_BOUND=Error
+UNUSED_PROBLEM_FILTERS=Warning
+automatically_removed_unused_problem_filters=false
+eclipse.preferences.version=1
+incompatible_api_component_version=Error
+incompatible_api_component_version_include_major_without_breaking_change=Disabled
+incompatible_api_component_version_include_minor_without_api_change=Disabled
+invalid_since_tag_version=Error
+malformed_since_tag=Error
+missing_since_tag=Error
+report_api_breakage_when_major_version_incremented=Disabled
+report_resolution_errors_api_component=Warning
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.ui/.settings/org.eclipse.pde.prefs b/lttng/org.eclipse.tracecompass.lttng2.kernel.ui/.settings/org.eclipse.pde.prefs
new file mode 100644 (file)
index 0000000..d92b94f
--- /dev/null
@@ -0,0 +1,32 @@
+compilers.f.unresolved-features=1
+compilers.f.unresolved-plugins=1
+compilers.incompatible-environment=1
+compilers.p.build=1
+compilers.p.build.bin.includes=1
+compilers.p.build.encodings=2
+compilers.p.build.java.compiler=2
+compilers.p.build.java.compliance=1
+compilers.p.build.missing.output=2
+compilers.p.build.output.library=1
+compilers.p.build.source.library=1
+compilers.p.build.src.includes=1
+compilers.p.deprecated=1
+compilers.p.discouraged-class=1
+compilers.p.internal=1
+compilers.p.missing-packages=1
+compilers.p.missing-version-export-package=2
+compilers.p.missing-version-import-package=2
+compilers.p.missing-version-require-bundle=2
+compilers.p.no-required-att=0
+compilers.p.not-externalized-att=1
+compilers.p.unknown-attribute=1
+compilers.p.unknown-class=1
+compilers.p.unknown-element=1
+compilers.p.unknown-identifier=1
+compilers.p.unknown-resource=1
+compilers.p.unresolved-ex-points=0
+compilers.p.unresolved-import=0
+compilers.s.create-docs=false
+compilers.s.doc-folder=doc
+compilers.s.open-tags=1
+eclipse.preferences.version=1
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.ui/META-INF/MANIFEST.MF b/lttng/org.eclipse.tracecompass.lttng2.kernel.ui/META-INF/MANIFEST.MF
new file mode 100644 (file)
index 0000000..43eb8b1
--- /dev/null
@@ -0,0 +1,26 @@
+Manifest-Version: 1.0
+Bundle-ManifestVersion: 2
+Bundle-Name: %Bundle-Name
+Bundle-Vendor: %Bundle-Vendor
+Bundle-Version: 1.0.0.qualifier
+Bundle-Localization: plugin
+Bundle-SymbolicName: org.eclipse.tracecompass.lttng2.kernel.ui;singleton:=true
+Bundle-Activator: org.eclipse.tracecompass.internal.lttng2.kernel.ui.Activator
+Bundle-ActivationPolicy: lazy
+Bundle-RequiredExecutionEnvironment: JavaSE-1.7
+Require-Bundle: org.eclipse.ui,
+ org.eclipse.ui.ide,
+ org.eclipse.core.resources,
+ org.eclipse.core.runtime,
+ org.eclipse.tracecompass.common.core,
+ org.eclipse.tracecompass.tmf.core,
+ org.eclipse.tracecompass.tmf.ui,
+ org.eclipse.tracecompass.analysis.os.linux.ui,
+ org.eclipse.tracecompass.tmf.ctf.core,
+ org.eclipse.tracecompass.lttng2.control.core,
+ org.eclipse.tracecompass.lttng2.control.ui,
+ org.eclipse.tracecompass.lttng2.kernel.core,
+ org.eclipse.tracecompass.lttng2.kernel.ui
+Import-Package: com.google.common.collect
+Export-Package: org.eclipse.tracecompass.internal.lttng2.kernel.ui;x-internal:=true,
+ org.eclipse.tracecompass.internal.lttng2.kernel.ui.views;x-friends:="org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests"
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.ui/about.html b/lttng/org.eclipse.tracecompass.lttng2.kernel.ui/about.html
new file mode 100644 (file)
index 0000000..c258ef5
--- /dev/null
@@ -0,0 +1,28 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"/>
+<title>About</title>
+</head>
+<body lang="EN-US">
+<h2>About This Content</h2>
+<p>June 5, 2006</p>    
+<h3>License</h3>
+
+<p>The Eclipse Foundation makes available all content in this plug-in (&quot;Content&quot;).  Unless otherwise 
+indicated below, the Content is provided to you under the terms and conditions of the
+Eclipse Public License Version 1.0 (&quot;EPL&quot;).  A copy of the EPL is available 
+at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>.
+For purposes of the EPL, &quot;Program&quot; will mean the Content.</p>
+
+<p>If you did not receive this Content directly from the Eclipse Foundation, the Content is 
+being redistributed by another party (&quot;Redistributor&quot;) and different terms and conditions may
+apply to your use of any object code in the Content.  Check the Redistributor's license that was 
+provided with the Content.  If no such license exists, contact the Redistributor.  Unless otherwise
+indicated below, the terms and conditions of the EPL still apply to any source code in the Content
+and such source code may be obtained at <a href="http://www.eclipse.org/">http://www.eclipse.org</a>.</p>
+
+</body>
+</html>
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.ui/build.properties b/lttng/org.eclipse.tracecompass.lttng2.kernel.ui/build.properties
new file mode 100644 (file)
index 0000000..9775951
--- /dev/null
@@ -0,0 +1,23 @@
+###############################################################################
+# Copyright (c) 2013, 2014 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:
+#     Ericsson - Initial API and implementation
+###############################################################################
+
+source.. = src/
+output.. = bin/
+bin.includes = META-INF/,\
+               .,\
+               plugin.xml,\
+               icons/,\
+               about.html,\
+               plugin.properties
+src.includes = about.html
+additional.bundles = org.eclipse.jdt.annotation
+jars.extra.classpath = platform:/plugin/org.eclipse.jdt.annotation
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.ui/icons/eview16/control_flow_view.gif b/lttng/org.eclipse.tracecompass.lttng2.kernel.ui/icons/eview16/control_flow_view.gif
new file mode 100644 (file)
index 0000000..3971b50
Binary files /dev/null and b/lttng/org.eclipse.tracecompass.lttng2.kernel.ui/icons/eview16/control_flow_view.gif differ
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.ui/icons/eview16/resources_view.gif b/lttng/org.eclipse.tracecompass.lttng2.kernel.ui/icons/eview16/resources_view.gif
new file mode 100644 (file)
index 0000000..2344861
Binary files /dev/null and b/lttng/org.eclipse.tracecompass.lttng2.kernel.ui/icons/eview16/resources_view.gif differ
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.ui/icons/obj16/garland16.png b/lttng/org.eclipse.tracecompass.lttng2.kernel.ui/icons/obj16/garland16.png
new file mode 100644 (file)
index 0000000..74f9751
Binary files /dev/null and b/lttng/org.eclipse.tracecompass.lttng2.kernel.ui/icons/obj16/garland16.png differ
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.ui/plugin.properties b/lttng/org.eclipse.tracecompass.lttng2.kernel.ui/plugin.properties
new file mode 100644 (file)
index 0000000..96a73ce
--- /dev/null
@@ -0,0 +1,23 @@
+###############################################################################
+# Copyright (c) 2013, 2014 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:
+#     Ericsson - Initial API and implementation
+###############################################################################
+
+Bundle-Vendor = Eclipse Trace Compass
+Bundle-Name = Trace Compass LTTng Kernel Analysis UI Plug-in
+
+kernel.perspective.name = LTTng Kernel
+
+controlflow.view.name = Control Flow
+resources.view.name = Resources
+cpuusage.view.name = CPU Usage
+
+tracetype.type.kernel = LTTng Kernel Trace
+analysis.lttngkernel = LTTng Kernel Analysis
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.ui/plugin.xml b/lttng/org.eclipse.tracecompass.lttng2.kernel.ui/plugin.xml
new file mode 100644 (file)
index 0000000..0bba560
--- /dev/null
@@ -0,0 +1,36 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<?eclipse version="3.4"?>
+<plugin>
+   <extension
+         point="org.eclipse.ui.perspectives">
+      <perspective
+            class="org.eclipse.tracecompass.internal.lttng2.kernel.ui.views.PerspectiveFactory"
+            icon="icons/obj16/garland16.png"
+            id="org.eclipse.linuxtools.lttng2.kernel.ui.perspective"
+            name="%kernel.perspective.name">
+      </perspective>
+   </extension>
+   <extension
+         point="org.eclipse.ui.navigator.navigatorContent">
+      <commonWizard
+            associatedExtensionId="org.eclipse.linuxtools.tmf.ui.navigator.content"
+            menuGroupId="org.eclipse.linuxtools.tmf.ui.views.ui.wizards.menuGroupId"
+            type="new"
+            wizardId="org.eclipse.linuxtools.tmf.ui.views.ui.wizards.newProject">
+         <enablement>
+            <with variable="activeWorkbenchWindow.activePerspective">
+               <equals
+                     value="org.eclipse.linuxtools.lttng2.kernel.ui.perspective">
+               </equals>
+            </with>
+         </enablement>
+      </commonWizard>
+   </extension>
+   <extension
+         point="org.eclipse.linuxtools.tmf.ui.tracetypeui">
+      <type
+            icon="icons/obj16/garland16.png"
+            tracetype="org.eclipse.linuxtools.lttng2.kernel.tracetype">
+      </type>
+   </extension>
+</plugin>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.ui/pom.xml b/lttng/org.eclipse.tracecompass.lttng2.kernel.ui/pom.xml
new file mode 100644 (file)
index 0000000..9b75d45
--- /dev/null
@@ -0,0 +1,36 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+   Copyright (C) 2011, Red Hat, Inc.
+
+   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
+-->
+<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>
+    <artifactId>org.eclipse.tracecompass.lttng-parent</artifactId>
+    <groupId>org.eclipse.tracecompass</groupId>
+    <version>1.0.0-SNAPSHOT</version>
+  </parent>
+
+  <artifactId>org.eclipse.tracecompass.lttng2.kernel.ui</artifactId>
+  <version>1.0.0-SNAPSHOT</version>
+  <packaging>eclipse-plugin</packaging>
+
+  <name>Trace Compass LTTng Kernel Analysis UI Plug-in</name>
+
+ <build>
+    <plugins>
+      <plugin>
+        <groupId>org.eclipse.tycho</groupId>
+        <artifactId>tycho-source-plugin</artifactId>
+      </plugin>
+    </plugins>
+  </build>
+
+ <groupId>org.eclipse.tracecompass</groupId>
+</project>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.ui/src/org/eclipse/tracecompass/internal/lttng2/kernel/ui/Activator.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.ui/src/org/eclipse/tracecompass/internal/lttng2/kernel/ui/Activator.java
new file mode 100644 (file)
index 0000000..f9e1350
--- /dev/null
@@ -0,0 +1,184 @@
+/*******************************************************************************
+ * Copyright (c) 2012, 2015 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:
+ *   Francois Chouinard - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.kernel.ui;
+
+import org.eclipse.core.runtime.IStatus;
+import org.eclipse.core.runtime.Status;
+import org.eclipse.jface.resource.ImageDescriptor;
+import org.eclipse.jface.resource.ImageRegistry;
+import org.eclipse.swt.graphics.Image;
+import org.eclipse.ui.plugin.AbstractUIPlugin;
+import org.osgi.framework.BundleContext;
+
+/**
+ * The activator class controls the plug-in life cycle
+ */
+public class Activator extends AbstractUIPlugin {
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+
+    /**
+     *  The plug-in ID
+     */
+    public static final String PLUGIN_ID = "org.eclipse.tracecompass.lttng2.kernel.ui"; //$NON-NLS-1$
+
+    /**
+     *  The shared instance
+     */
+    private static Activator plugin;
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+
+    /**
+     * The constructor
+     */
+    public Activator() {
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    /**
+     * Returns the shared instance
+     *
+     * @return the shared instance
+     */
+    public static Activator getDefault() {
+        return plugin;
+    }
+
+    // ------------------------------------------------------------------------
+    // AbstractUIPlugin
+    // ------------------------------------------------------------------------
+
+    @Override
+    public void start(BundleContext context) throws Exception {
+        super.start(context);
+        plugin = this;
+    }
+
+    @Override
+    public void stop(BundleContext context) throws Exception {
+        plugin = null;
+        super.stop(context);
+    }
+
+    @Override
+    protected void initializeImageRegistry(ImageRegistry reg) {
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    /**
+     * Get the image object from a given path
+     *
+     * @param path
+     *            The path to the image file
+     * @return The Image object
+     */
+    public Image getImageFromPath(String path) {
+        return getImageDescripterFromPath(path).createImage();
+    }
+
+    /**
+     * Get the ImageDescriptor from a given path
+     *
+     * @param path
+     *            The path to the image file
+     * @return The ImageDescriptor object
+     */
+    public ImageDescriptor getImageDescripterFromPath(String path) {
+        return AbstractUIPlugin.imageDescriptorFromPlugin(PLUGIN_ID, path);
+    }
+
+    /**
+     * Get the Image from a registry
+     *
+     * @param path
+     *            The path to the image registry
+     * @return The Image object
+     */
+    public Image getImageFromImageRegistry(String path) {
+        Image icon = getImageRegistry().get(path);
+        if (icon == null) {
+            icon = getImageDescripterFromPath(path).createImage();
+            plugin.getImageRegistry().put(path, icon);
+        }
+        return icon;
+    }
+
+    /**
+     * Logs a message with severity INFO in the runtime log of the plug-in.
+     *
+     * @param message A message to log
+     */
+    public void logInfo(String message) {
+        getLog().log(new Status(IStatus.INFO, PLUGIN_ID, message));
+    }
+
+    /**
+     * Logs a message and exception with severity INFO in the runtime log of the plug-in.
+     *
+     * @param message A message to log
+     * @param exception A exception to log
+     */
+    public void logInfo(String message, Throwable exception) {
+        getLog().log(new Status(IStatus.INFO, PLUGIN_ID, message, exception));
+    }
+
+    /**
+     * Logs a message and exception with severity WARNING in the runtime log of the plug-in.
+     *
+     * @param message A message to log
+     */
+    public void logWarning(String message) {
+        getLog().log(new Status(IStatus.WARNING, PLUGIN_ID, message));
+    }
+
+    /**
+     * Logs a message and exception with severity WARNING in the runtime log of the plug-in.
+     *
+     * @param message A message to log
+     * @param exception A exception to log
+     */
+    public void logWarning(String message, Throwable exception) {
+        getLog().log(new Status(IStatus.WARNING, PLUGIN_ID, message, exception));
+    }
+
+    /**
+     * Logs a message and exception with severity ERROR in the runtime log of the plug-in.
+     *
+     * @param message A message to log
+     */
+    public void logError(String message) {
+        getLog().log(new Status(IStatus.ERROR, PLUGIN_ID, message));
+    }
+
+    /**
+     * Logs a message and exception with severity ERROR in the runtime log of the plug-in.
+     *
+     * @param message A message to log
+     * @param exception A exception to log
+     */
+    public void logError(String message, Throwable exception) {
+        getLog().log(new Status(IStatus.ERROR, PLUGIN_ID, message, exception));
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel.ui/src/org/eclipse/tracecompass/internal/lttng2/kernel/ui/views/PerspectiveFactory.java b/lttng/org.eclipse.tracecompass.lttng2.kernel.ui/src/org/eclipse/tracecompass/internal/lttng2/kernel/ui/views/PerspectiveFactory.java
new file mode 100644 (file)
index 0000000..92688af
--- /dev/null
@@ -0,0 +1,105 @@
+/*******************************************************************************
+ * Copyright (c) 2012, 2015 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:
+ *   Francois Chouinard - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.kernel.ui.views;
+
+import org.eclipse.tracecompass.analysis.os.linux.ui.views.controlflow.ControlFlowView;
+import org.eclipse.tracecompass.analysis.os.linux.ui.views.resources.ResourcesView;
+import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
+import org.eclipse.tracecompass.tmf.ui.project.wizards.NewTmfProjectWizard;
+import org.eclipse.tracecompass.tmf.ui.views.histogram.HistogramView;
+import org.eclipse.tracecompass.tmf.ui.views.statistics.TmfStatisticsView;
+import org.eclipse.ui.IFolderLayout;
+import org.eclipse.ui.IPageLayout;
+import org.eclipse.ui.IPerspectiveFactory;
+
+/**
+ * The default LTTng perspective.
+ */
+public class PerspectiveFactory implements IPerspectiveFactory {
+
+    /** Perspective ID */
+    public static final String ID = "org.eclipse.linuxtools.lttng2.kernel.ui.perspective"; //$NON-NLS-1$
+
+    // LTTng views
+    private static final String HISTOGRAM_VIEW_ID = HistogramView.ID;
+    private static final String CONTROL_VIEW_ID = ControlView.ID;
+    private static final String CONTROLFLOW_VIEW_ID = ControlFlowView.ID;
+    private static final String RESOURCES_VIEW_ID = ResourcesView.ID;
+    private static final String STATISTICS_VIEW_ID = TmfStatisticsView.ID;
+
+    // Standard Eclipse views
+    private static final String PROJECT_VIEW_ID = IPageLayout.ID_PROJECT_EXPLORER;
+    private static final String PROPERTIES_VIEW_ID = IPageLayout.ID_PROP_SHEET;
+    private static final String BOOKMARKS_VIEW_ID = IPageLayout.ID_BOOKMARKS;
+
+    @Override
+    public void createInitialLayout(IPageLayout layout) {
+
+        layout.setEditorAreaVisible(true);
+
+        addFastViews(layout);
+        addViewShortcuts(layout);
+        addPerspectiveShortcuts(layout);
+
+        // Create the top left folder
+        IFolderLayout topLeftFolder = layout.createFolder(
+                "topLeftFolder", IPageLayout.LEFT, 0.15f, IPageLayout.ID_EDITOR_AREA); //$NON-NLS-1$
+        topLeftFolder.addView(PROJECT_VIEW_ID);
+
+        // Create the bottom left folder
+        IFolderLayout bottomLeftFolder = layout.createFolder(
+                "bottomLeftFolder", IPageLayout.BOTTOM, 0.70f, "topLeftFolder"); //$NON-NLS-1$ //$NON-NLS-2$
+        bottomLeftFolder.addView(CONTROL_VIEW_ID);
+
+        // Create the top right folder
+        IFolderLayout topRightFolder = layout.createFolder(
+                "topRightFolder", IPageLayout.TOP, 0.40f, IPageLayout.ID_EDITOR_AREA); //$NON-NLS-1$
+        topRightFolder.addView(CONTROLFLOW_VIEW_ID);
+        topRightFolder.addView(RESOURCES_VIEW_ID);
+        topRightFolder.addView(STATISTICS_VIEW_ID);
+
+        // Create the bottom right folder
+        IFolderLayout bottomRightFolder = layout.createFolder(
+                "bottomRightFolder", IPageLayout.BOTTOM, 0.50f, IPageLayout.ID_EDITOR_AREA); //$NON-NLS-1$
+        bottomRightFolder.addView(HISTOGRAM_VIEW_ID);
+        bottomRightFolder.addView(PROPERTIES_VIEW_ID);
+        bottomRightFolder.addView(BOOKMARKS_VIEW_ID);
+
+        layout.addNewWizardShortcut(NewTmfProjectWizard.ID);
+    }
+
+    /**
+     * Add fast views to the perspective
+     *
+     * @param layout
+     */
+    private void addFastViews(IPageLayout layout) {
+    }
+
+    /**
+     * Add view shortcuts to the perspective
+     *
+     * @param layout
+     */
+    private void addViewShortcuts(IPageLayout layout) {
+    }
+
+    /**
+     * Add perspective shortcuts to the perspective
+     *
+     * @param layout
+     */
+    private void addPerspectiveShortcuts(IPageLayout layout) {
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel/.project b/lttng/org.eclipse.tracecompass.lttng2.kernel/.project
new file mode 100644 (file)
index 0000000..2c8611b
--- /dev/null
@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+       <name>org.eclipse.tracecompass.lttng2.kernel</name>
+       <comment></comment>
+       <projects>
+       </projects>
+       <buildSpec>
+               <buildCommand>
+                       <name>org.eclipse.pde.FeatureBuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+       </buildSpec>
+       <natures>
+               <nature>org.eclipse.pde.FeatureNature</nature>
+       </natures>
+</projectDescription>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel/.settings/org.eclipse.core.resources.prefs b/lttng/org.eclipse.tracecompass.lttng2.kernel/.settings/org.eclipse.core.resources.prefs
new file mode 100644 (file)
index 0000000..99f26c0
--- /dev/null
@@ -0,0 +1,2 @@
+eclipse.preferences.version=1
+encoding/<project>=UTF-8
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel/.settings/org.eclipse.core.runtime.prefs b/lttng/org.eclipse.tracecompass.lttng2.kernel/.settings/org.eclipse.core.runtime.prefs
new file mode 100644 (file)
index 0000000..5a0ad22
--- /dev/null
@@ -0,0 +1,2 @@
+eclipse.preferences.version=1
+line.separator=\n
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel/build.properties b/lttng/org.eclipse.tracecompass.lttng2.kernel/build.properties
new file mode 100644 (file)
index 0000000..475ce21
--- /dev/null
@@ -0,0 +1,16 @@
+###############################################################################
+# Copyright (c) 2013, 2015 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:
+#     Ericsson - Initial API and implementation
+###############################################################################
+
+bin.includes = feature.xml,\
+               feature.properties,\
+               p2.inf
+src.includes = sourceTemplateFeature/p2.inf
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel/feature.properties b/lttng/org.eclipse.tracecompass.lttng2.kernel/feature.properties
new file mode 100644 (file)
index 0000000..39f25b4
--- /dev/null
@@ -0,0 +1,22 @@
+###############################################################################
+# Copyright (c) 2009, 2015 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:
+#     Ericsson - Initial API and implementation
+###############################################################################
+
+featureName=LTTng Kernel Analysis
+
+description=Plug-ins to integrate LTTng Kernel analysis tools into the workbench. \
+Includes the LTTng (Linux Tracing Toolkit), TMF (Tracing and Monitoring Framework) \
+and CTF (Common Trace Format) features.
+
+featureProvider=Eclipse Trace Compass
+
+copyright=Copyright 2015 Ericsson
+
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel/feature.xml b/lttng/org.eclipse.tracecompass.lttng2.kernel/feature.xml
new file mode 100644 (file)
index 0000000..1579e2f
--- /dev/null
@@ -0,0 +1,81 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- For PDE build, remove "ws" and "arch" -->
+<feature
+      id="org.eclipse.tracecompass.lttng2.kernel"
+      label="%featureName"
+      version="1.0.0.qualifier"
+      provider-name="%featureProvider"
+      license-feature="org.eclipse.license"
+      license-feature-version="0.0.0">
+
+   <description>
+      %description
+   </description>
+
+   <copyright>
+      %copyright
+   </copyright>
+
+   <license url="%licenseURL">
+      %license
+   </license>
+
+   <includes
+         id="org.eclipse.tracecompass.lttng2.control"
+         version="0.0.0"
+         name="Linux Tracing Toolkit next generation (LTTng)"/>
+
+   <includes
+         id="org.eclipse.tracecompass.tmf.ctf"
+         version="0.0.0"
+         name="CTF Support for TMF"/>
+
+   <requires>
+      <import plugin="org.eclipse.core.runtime"/>
+      <import plugin="org.eclipse.core.resources"/>
+      <import plugin="org.eclipse.tracecompass.ctf.core" version="1.0.0" match="greaterOrEqual"/>
+      <import plugin="org.eclipse.tracecompass.tmf.core" version="1.0.0" match="greaterOrEqual"/>
+      <import plugin="org.eclipse.ui"/>
+      <import plugin="org.eclipse.ui.ide"/>
+      <import plugin="org.eclipse.tracecompass.tmf.ui" version="1.0.0" match="greaterOrEqual"/>
+      <import plugin="org.eclipse.tracecompass.lttng2.control.core" version="1.0.0" match="greaterOrEqual"/>
+      <import plugin="org.eclipse.tracecompass.lttng2.control.ui" version="1.0.0" match="greaterOrEqual"/>
+      <import plugin="org.eclipse.tracecompass.lttng2.kernel.core" version="1.0.0" match="greaterOrEqual"/>
+      <import plugin="org.eclipse.help"/>
+   </requires>
+
+   <plugin
+         id="org.eclipse.tracecompass.analysis.os.linux.core"
+         download-size="0"
+         install-size="0"
+         version="0.0.0"
+         unpack="false"/>
+
+   <plugin
+         id="org.eclipse.tracecompass.analysis.os.linux.ui"
+         download-size="0"
+         install-size="0"
+         version="0.0.0"
+         unpack="false"/>
+
+   <plugin
+         id="org.eclipse.tracecompass.lttng2.kernel.core"
+         download-size="0"
+         install-size="0"
+         version="0.0.0"
+         unpack="false"/>
+
+   <plugin
+         id="org.eclipse.tracecompass.lttng2.kernel.ui"
+         download-size="0"
+         install-size="0"
+         version="0.0.0"
+         unpack="false"/>
+
+   <plugin
+         id="org.eclipse.tracecompass.doc.user"
+         download-size="0"
+         install-size="0"
+         version="0.0.0"/>
+
+</feature>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel/p2.inf b/lttng/org.eclipse.tracecompass.lttng2.kernel/p2.inf
new file mode 100644 (file)
index 0000000..575b43d
--- /dev/null
@@ -0,0 +1 @@
+update.matchExp=providedCapabilities.exists(pc | pc.namespace == 'org.eclipse.equinox.p2.iu' && (pc.name == 'org.eclipse.linuxtools.lttng2.kernel.feature.group' || pc.name == 'org.eclipse.tracecompass.lttng2.kernel.feature.group'))
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel/pom.xml b/lttng/org.eclipse.tracecompass.lttng2.kernel/pom.xml
new file mode 100644 (file)
index 0000000..928acb5
--- /dev/null
@@ -0,0 +1,64 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+   Copyright (C) 2011, Red Hat, Inc.
+
+   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
+-->
+<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>
+    <artifactId>org.eclipse.tracecompass.lttng-parent</artifactId>
+    <groupId>org.eclipse.tracecompass</groupId>
+    <version>1.0.0-SNAPSHOT</version>
+  </parent>
+
+  <artifactId>org.eclipse.tracecompass.lttng2.kernel</artifactId>
+  <version>1.0.0-SNAPSHOT</version>
+  <packaging>eclipse-feature</packaging>
+
+  <name>Trace Compass LTTng Kernel Analysis Feature</name>
+
+  <groupId>org.eclipse.tracecompass</groupId>
+
+  <build>
+    <plugins>
+      <plugin>
+        <groupId>org.eclipse.tycho.extras</groupId>
+        <artifactId>tycho-source-feature-plugin</artifactId>
+        <executions>
+          <execution>
+            <id>source-feature</id>
+            <phase>package</phase>
+            <goals>
+              <goal>source-feature</goal>
+            </goals>
+            <configuration>
+              <excludes>
+                <plugin id="org.eclipse.tracecompass.doc.user"/>
+              </excludes>
+            </configuration>
+          </execution>
+        </executions>
+      </plugin>
+      <plugin>
+        <groupId>org.eclipse.tycho</groupId>
+        <artifactId>tycho-p2-plugin</artifactId>
+        <version>${tycho-version}</version>
+        <executions>
+          <execution>
+            <id>attached-p2-metadata</id>
+            <phase>package</phase>
+            <goals>
+              <goal>p2-metadata</goal>
+            </goals>
+          </execution>
+        </executions>
+      </plugin>
+    </plugins>
+  </build>
+</project>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.kernel/sourceTemplateFeature/p2.inf b/lttng/org.eclipse.tracecompass.lttng2.kernel/sourceTemplateFeature/p2.inf
new file mode 100644 (file)
index 0000000..bc608b9
--- /dev/null
@@ -0,0 +1 @@
+update.matchExp=providedCapabilities.exists(pc | pc.namespace == 'org.eclipse.equinox.p2.iu' && (pc.name == 'org.eclipse.linuxtools.lttng2.kernel.source.feature.group' || pc.name == 'org.eclipse.tracecompass.lttng2.kernel.source.feature.group'))
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/.classpath b/lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/.classpath
new file mode 100644 (file)
index 0000000..098194c
--- /dev/null
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+       <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7"/>
+       <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
+       <classpathentry kind="src" path="src"/>
+       <classpathentry kind="output" path="bin"/>
+</classpath>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/.project b/lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/.project
new file mode 100644 (file)
index 0000000..1ebf5c3
--- /dev/null
@@ -0,0 +1,34 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+       <name>org.eclipse.tracecompass.lttng2.ust.core.tests</name>
+       <comment></comment>
+       <projects>
+       </projects>
+       <buildSpec>
+               <buildCommand>
+                       <name>org.eclipse.jdt.core.javabuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+               <buildCommand>
+                       <name>org.eclipse.pde.ManifestBuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+               <buildCommand>
+                       <name>org.eclipse.pde.SchemaBuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+               <buildCommand>
+                       <name>org.eclipse.pde.api.tools.apiAnalysisBuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+       </buildSpec>
+       <natures>
+               <nature>org.eclipse.pde.PluginNature</nature>
+               <nature>org.eclipse.jdt.core.javanature</nature>
+               <nature>org.eclipse.pde.api.tools.apiAnalysisNature</nature>
+       </natures>
+</projectDescription>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/.settings/org.eclipse.core.resources.prefs b/lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/.settings/org.eclipse.core.resources.prefs
new file mode 100644 (file)
index 0000000..99f26c0
--- /dev/null
@@ -0,0 +1,2 @@
+eclipse.preferences.version=1
+encoding/<project>=UTF-8
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/.settings/org.eclipse.core.runtime.prefs b/lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/.settings/org.eclipse.core.runtime.prefs
new file mode 100644 (file)
index 0000000..5a0ad22
--- /dev/null
@@ -0,0 +1,2 @@
+eclipse.preferences.version=1
+line.separator=\n
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/.settings/org.eclipse.jdt.core.prefs b/lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/.settings/org.eclipse.jdt.core.prefs
new file mode 100644 (file)
index 0000000..0409c61
--- /dev/null
@@ -0,0 +1,403 @@
+eclipse.preferences.version=1
+org.eclipse.jdt.core.codeComplete.argumentPrefixes=
+org.eclipse.jdt.core.codeComplete.argumentSuffixes=
+org.eclipse.jdt.core.codeComplete.fieldPrefixes=f
+org.eclipse.jdt.core.codeComplete.fieldSuffixes=
+org.eclipse.jdt.core.codeComplete.localPrefixes=
+org.eclipse.jdt.core.codeComplete.localSuffixes=
+org.eclipse.jdt.core.codeComplete.staticFieldPrefixes=
+org.eclipse.jdt.core.codeComplete.staticFieldSuffixes=
+org.eclipse.jdt.core.codeComplete.staticFinalFieldPrefixes=
+org.eclipse.jdt.core.codeComplete.staticFinalFieldSuffixes=
+org.eclipse.jdt.core.compiler.annotation.inheritNullAnnotations=enabled
+org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore
+org.eclipse.jdt.core.compiler.annotation.nonnull=org.eclipse.jdt.annotation.NonNull
+org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=org.eclipse.jdt.annotation.NonNullByDefault
+org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nullable
+org.eclipse.jdt.core.compiler.annotation.nullanalysis=enabled
+org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
+org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
+org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
+org.eclipse.jdt.core.compiler.compliance=1.7
+org.eclipse.jdt.core.compiler.debug.lineNumber=generate
+org.eclipse.jdt.core.compiler.debug.localVariable=generate
+org.eclipse.jdt.core.compiler.debug.sourceFile=generate
+org.eclipse.jdt.core.compiler.doc.comment.support=enabled
+org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=error
+org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
+org.eclipse.jdt.core.compiler.problem.autoboxing=ignore
+org.eclipse.jdt.core.compiler.problem.comparingIdentical=error
+org.eclipse.jdt.core.compiler.problem.deadCode=error
+org.eclipse.jdt.core.compiler.problem.deprecation=error
+org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled
+org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=enabled
+org.eclipse.jdt.core.compiler.problem.discouragedReference=error
+org.eclipse.jdt.core.compiler.problem.emptyStatement=error
+org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
+org.eclipse.jdt.core.compiler.problem.explicitlyClosedAutoCloseable=error
+org.eclipse.jdt.core.compiler.problem.fallthroughCase=error
+org.eclipse.jdt.core.compiler.problem.fatalOptionalError=disabled
+org.eclipse.jdt.core.compiler.problem.fieldHiding=error
+org.eclipse.jdt.core.compiler.problem.finalParameterBound=error
+org.eclipse.jdt.core.compiler.problem.finallyBlockNotCompletingNormally=error
+org.eclipse.jdt.core.compiler.problem.forbiddenReference=error
+org.eclipse.jdt.core.compiler.problem.hiddenCatchBlock=error
+org.eclipse.jdt.core.compiler.problem.includeNullInfoFromAsserts=disabled
+org.eclipse.jdt.core.compiler.problem.incompatibleNonInheritedInterfaceMethod=error
+org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch=error
+org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=error
+org.eclipse.jdt.core.compiler.problem.invalidJavadoc=warning
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTags=enabled
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsDeprecatedRef=enabled
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsNotVisibleRef=enabled
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsVisibility=protected
+org.eclipse.jdt.core.compiler.problem.localVariableHiding=error
+org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=error
+org.eclipse.jdt.core.compiler.problem.missingDefaultCase=error
+org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=error
+org.eclipse.jdt.core.compiler.problem.missingEnumCaseDespiteDefault=enabled
+org.eclipse.jdt.core.compiler.problem.missingHashCodeMethod=error
+org.eclipse.jdt.core.compiler.problem.missingJavadocComments=warning
+org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsOverriding=disabled
+org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsVisibility=protected
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagDescription=all_standard_tags
+org.eclipse.jdt.core.compiler.problem.missingJavadocTags=warning
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagsMethodTypeParameters=disabled
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagsOverriding=disabled
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagsVisibility=protected
+org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotation=error
+org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotationForInterfaceMethodImplementation=enabled
+org.eclipse.jdt.core.compiler.problem.missingSerialVersion=error
+org.eclipse.jdt.core.compiler.problem.missingSynchronizedOnInheritedMethod=error
+org.eclipse.jdt.core.compiler.problem.noEffectAssignment=error
+org.eclipse.jdt.core.compiler.problem.noImplicitStringConversion=error
+org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=ignore
+org.eclipse.jdt.core.compiler.problem.nonnullParameterAnnotationDropped=warning
+org.eclipse.jdt.core.compiler.problem.nullAnnotationInferenceConflict=warning
+org.eclipse.jdt.core.compiler.problem.nullReference=error
+org.eclipse.jdt.core.compiler.problem.nullSpecViolation=error
+org.eclipse.jdt.core.compiler.problem.nullUncheckedConversion=warning
+org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=error
+org.eclipse.jdt.core.compiler.problem.parameterAssignment=error
+org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=error
+org.eclipse.jdt.core.compiler.problem.potentialNullReference=error
+org.eclipse.jdt.core.compiler.problem.potentiallyUnclosedCloseable=warning
+org.eclipse.jdt.core.compiler.problem.rawTypeReference=error
+org.eclipse.jdt.core.compiler.problem.redundantNullAnnotation=warning
+org.eclipse.jdt.core.compiler.problem.redundantNullCheck=error
+org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=error
+org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=error
+org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore
+org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=error
+org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled
+org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=error
+org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=disabled
+org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled
+org.eclipse.jdt.core.compiler.problem.syntacticNullAnalysisForFields=enabled
+org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=ignore
+org.eclipse.jdt.core.compiler.problem.typeParameterHiding=error
+org.eclipse.jdt.core.compiler.problem.unavoidableGenericTypeProblems=disabled
+org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=error
+org.eclipse.jdt.core.compiler.problem.unclosedCloseable=error
+org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=ignore
+org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=error
+org.eclipse.jdt.core.compiler.problem.unnecessaryElse=error
+org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=error
+org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=error
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionExemptExceptionAndThrowable=disabled
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionIncludeDocCommentReference=disabled
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverriding=disabled
+org.eclipse.jdt.core.compiler.problem.unusedImport=error
+org.eclipse.jdt.core.compiler.problem.unusedLabel=error
+org.eclipse.jdt.core.compiler.problem.unusedLocal=error
+org.eclipse.jdt.core.compiler.problem.unusedObjectAllocation=ignore
+org.eclipse.jdt.core.compiler.problem.unusedParameter=ignore
+org.eclipse.jdt.core.compiler.problem.unusedParameterIncludeDocCommentReference=enabled
+org.eclipse.jdt.core.compiler.problem.unusedParameterWhenImplementingAbstract=disabled
+org.eclipse.jdt.core.compiler.problem.unusedParameterWhenOverridingConcrete=disabled
+org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=error
+org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=ignore
+org.eclipse.jdt.core.compiler.problem.unusedWarningToken=error
+org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=error
+org.eclipse.jdt.core.compiler.source=1.7
+org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=16
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_call=16
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation=16
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression=16
+org.eclipse.jdt.core.formatter.alignment_for_assignment=0
+org.eclipse.jdt.core.formatter.alignment_for_binary_expression=16
+org.eclipse.jdt.core.formatter.alignment_for_compact_if=16
+org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=80
+org.eclipse.jdt.core.formatter.alignment_for_enum_constants=0
+org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=16
+org.eclipse.jdt.core.formatter.alignment_for_method_declaration=0
+org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16
+org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=80
+org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation=0
+org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_constructor_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_method_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_union_type_in_multicatch=16
+org.eclipse.jdt.core.formatter.blank_lines_after_imports=1
+org.eclipse.jdt.core.formatter.blank_lines_after_package=1
+org.eclipse.jdt.core.formatter.blank_lines_before_field=0
+org.eclipse.jdt.core.formatter.blank_lines_before_first_class_body_declaration=0
+org.eclipse.jdt.core.formatter.blank_lines_before_imports=1
+org.eclipse.jdt.core.formatter.blank_lines_before_member_type=1
+org.eclipse.jdt.core.formatter.blank_lines_before_method=1
+org.eclipse.jdt.core.formatter.blank_lines_before_new_chunk=1
+org.eclipse.jdt.core.formatter.blank_lines_before_package=0
+org.eclipse.jdt.core.formatter.blank_lines_between_import_groups=1
+org.eclipse.jdt.core.formatter.blank_lines_between_type_declarations=1
+org.eclipse.jdt.core.formatter.brace_position_for_annotation_type_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_array_initializer=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_block=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_block_in_case=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_constructor_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_enum_constant=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_enum_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_method_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_switch=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_type_declaration=end_of_line
+org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_block_comment=false
+org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_javadoc_comment=false
+org.eclipse.jdt.core.formatter.comment.format_block_comments=true
+org.eclipse.jdt.core.formatter.comment.format_header=false
+org.eclipse.jdt.core.formatter.comment.format_html=true
+org.eclipse.jdt.core.formatter.comment.format_javadoc_comments=true
+org.eclipse.jdt.core.formatter.comment.format_line_comments=true
+org.eclipse.jdt.core.formatter.comment.format_source_code=true
+org.eclipse.jdt.core.formatter.comment.indent_parameter_description=true
+org.eclipse.jdt.core.formatter.comment.indent_root_tags=true
+org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags=insert
+org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter=insert
+org.eclipse.jdt.core.formatter.comment.line_length=80
+org.eclipse.jdt.core.formatter.comment.new_lines_at_block_boundaries=true
+org.eclipse.jdt.core.formatter.comment.new_lines_at_javadoc_boundaries=true
+org.eclipse.jdt.core.formatter.comment.preserve_white_space_between_code_and_line_comments=false
+org.eclipse.jdt.core.formatter.compact_else_if=true
+org.eclipse.jdt.core.formatter.continuation_indentation=2
+org.eclipse.jdt.core.formatter.continuation_indentation_for_array_initializer=2
+org.eclipse.jdt.core.formatter.disabling_tag=@formatter\:off
+org.eclipse.jdt.core.formatter.enabling_tag=@formatter\:on
+org.eclipse.jdt.core.formatter.format_guardian_clause_on_one_line=false
+org.eclipse.jdt.core.formatter.format_line_comment_starting_on_first_column=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_annotation_declaration_header=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_constant_header=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_declaration_header=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_type_header=true
+org.eclipse.jdt.core.formatter.indent_breaks_compare_to_cases=true
+org.eclipse.jdt.core.formatter.indent_empty_lines=false
+org.eclipse.jdt.core.formatter.indent_statements_compare_to_block=true
+org.eclipse.jdt.core.formatter.indent_statements_compare_to_body=true
+org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_cases=true
+org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_switch=false
+org.eclipse.jdt.core.formatter.indentation.size=4
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_field=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_local_variable=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_method=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_package=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_parameter=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_type=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_label=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_opening_brace_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_at_end_of_file_if_missing=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_finally_in_try_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_while_in_do_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_annotation_declaration=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_anonymous_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_block=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter=insert
+org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_binary_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_paren_in_cast=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_assert=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_case=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_labeled_statement=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_allocation_expression=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_annotation=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_throws=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_constant_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_declarations=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_explicitconstructorcall_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_increments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_inits=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_throws=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_invocation_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_field_declarations=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_local_declarations=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_parameterized_type_reference=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_superinterfaces=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_ellipsis=insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_brace_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_cast=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_catch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_for=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_if=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_parenthesized_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_switch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_synchronized=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_try=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_while=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_try_resources=insert
+org.eclipse.jdt.core.formatter.insert_space_after_unary_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter=insert
+org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_binary_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_brace_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_cast=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_catch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_for=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_if=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_parenthesized_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_switch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_synchronized=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_try=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_while=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_assert=insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_case=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_default=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_labeled_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_throws=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_constant_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_declarations=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_explicitconstructorcall_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_increments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_inits=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_throws=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_invocation_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_field_declarations=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_local_declarations=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_superinterfaces=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_ellipsis=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_annotation_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_anonymous_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_block=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_constructor_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_constant=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_method_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_switch=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation_type_member_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_catch=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_if=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_parenthesized_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_switch=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_synchronized=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_try=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_while=insert
+org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_return=insert
+org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_throw=insert
+org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_semicolon=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_try_resources=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_unary_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_brackets_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_annotation_type_member_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.join_lines_in_comments=true
+org.eclipse.jdt.core.formatter.join_wrapped_lines=false
+org.eclipse.jdt.core.formatter.keep_else_statement_on_same_line=false
+org.eclipse.jdt.core.formatter.keep_empty_array_initializer_on_one_line=false
+org.eclipse.jdt.core.formatter.keep_imple_if_on_one_line=false
+org.eclipse.jdt.core.formatter.keep_then_statement_on_same_line=false
+org.eclipse.jdt.core.formatter.lineSplit=250
+org.eclipse.jdt.core.formatter.never_indent_block_comments_on_first_column=false
+org.eclipse.jdt.core.formatter.never_indent_line_comments_on_first_column=false
+org.eclipse.jdt.core.formatter.number_of_blank_lines_at_beginning_of_method_body=0
+org.eclipse.jdt.core.formatter.number_of_empty_lines_to_preserve=1
+org.eclipse.jdt.core.formatter.put_empty_statement_on_new_line=true
+org.eclipse.jdt.core.formatter.tabulation.char=space
+org.eclipse.jdt.core.formatter.tabulation.size=4
+org.eclipse.jdt.core.formatter.use_on_off_tags=false
+org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false
+org.eclipse.jdt.core.formatter.wrap_before_binary_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_or_operator_multicatch=true
+org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/.settings/org.eclipse.jdt.ui.prefs b/lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/.settings/org.eclipse.jdt.ui.prefs
new file mode 100644 (file)
index 0000000..232a3fd
--- /dev/null
@@ -0,0 +1,60 @@
+eclipse.preferences.version=1
+editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true
+formatter_profile=_tmf-style
+formatter_settings_version=12
+org.eclipse.jdt.ui.exception.name=e
+org.eclipse.jdt.ui.gettersetter.use.is=true
+org.eclipse.jdt.ui.keywordthis=false
+org.eclipse.jdt.ui.overrideannotation=true
+sp_cleanup.add_default_serial_version_id=true
+sp_cleanup.add_generated_serial_version_id=false
+sp_cleanup.add_missing_annotations=false
+sp_cleanup.add_missing_deprecated_annotations=true
+sp_cleanup.add_missing_methods=false
+sp_cleanup.add_missing_nls_tags=false
+sp_cleanup.add_missing_override_annotations=true
+sp_cleanup.add_missing_override_annotations_interface_methods=true
+sp_cleanup.add_serial_version_id=false
+sp_cleanup.always_use_blocks=true
+sp_cleanup.always_use_parentheses_in_expressions=false
+sp_cleanup.always_use_this_for_non_static_field_access=false
+sp_cleanup.always_use_this_for_non_static_method_access=false
+sp_cleanup.convert_to_enhanced_for_loop=false
+sp_cleanup.correct_indentation=false
+sp_cleanup.format_source_code=false
+sp_cleanup.format_source_code_changes_only=false
+sp_cleanup.make_local_variable_final=false
+sp_cleanup.make_parameters_final=false
+sp_cleanup.make_private_fields_final=true
+sp_cleanup.make_type_abstract_if_missing_method=false
+sp_cleanup.make_variable_declarations_final=false
+sp_cleanup.never_use_blocks=false
+sp_cleanup.never_use_parentheses_in_expressions=true
+sp_cleanup.on_save_use_additional_actions=true
+sp_cleanup.organize_imports=false
+sp_cleanup.qualify_static_field_accesses_with_declaring_class=false
+sp_cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=true
+sp_cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=true
+sp_cleanup.qualify_static_member_accesses_with_declaring_class=false
+sp_cleanup.qualify_static_method_accesses_with_declaring_class=false
+sp_cleanup.remove_private_constructors=true
+sp_cleanup.remove_trailing_whitespaces=true
+sp_cleanup.remove_trailing_whitespaces_all=true
+sp_cleanup.remove_trailing_whitespaces_ignore_empty=false
+sp_cleanup.remove_unnecessary_casts=false
+sp_cleanup.remove_unnecessary_nls_tags=false
+sp_cleanup.remove_unused_imports=false
+sp_cleanup.remove_unused_local_variables=false
+sp_cleanup.remove_unused_private_fields=true
+sp_cleanup.remove_unused_private_members=false
+sp_cleanup.remove_unused_private_methods=true
+sp_cleanup.remove_unused_private_types=true
+sp_cleanup.sort_members=false
+sp_cleanup.sort_members_all=false
+sp_cleanup.use_blocks=true
+sp_cleanup.use_blocks_only_for_return_and_throw=false
+sp_cleanup.use_parentheses_in_expressions=false
+sp_cleanup.use_this_for_non_static_field_access=false
+sp_cleanup.use_this_for_non_static_field_access_only_if_necessary=true
+sp_cleanup.use_this_for_non_static_method_access=false
+sp_cleanup.use_this_for_non_static_method_access_only_if_necessary=true
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/.settings/org.eclipse.pde.api.tools.prefs b/lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/.settings/org.eclipse.pde.api.tools.prefs
new file mode 100644 (file)
index 0000000..acc3abd
--- /dev/null
@@ -0,0 +1,97 @@
+ANNOTATION_ELEMENT_TYPE_ADDED_METHOD_WITHOUT_DEFAULT_VALUE=Error
+ANNOTATION_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+ANNOTATION_ELEMENT_TYPE_REMOVED_FIELD=Error
+ANNOTATION_ELEMENT_TYPE_REMOVED_METHOD=Error
+ANNOTATION_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_API_TYPE=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_API_TYPE=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_TYPE=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_TYPE=Error
+API_USE_SCAN_FIELD_SEVERITY=Error
+API_USE_SCAN_METHOD_SEVERITY=Error
+API_USE_SCAN_TYPE_SEVERITY=Error
+CLASS_ELEMENT_TYPE_ADDED_METHOD=Error
+CLASS_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
+CLASS_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+CLASS_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
+CLASS_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+CLASS_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
+CLASS_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
+CLASS_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+CLASS_ELEMENT_TYPE_REMOVED_CONSTRUCTOR=Error
+CLASS_ELEMENT_TYPE_REMOVED_FIELD=Error
+CLASS_ELEMENT_TYPE_REMOVED_METHOD=Error
+CLASS_ELEMENT_TYPE_REMOVED_SUPERCLASS=Error
+CLASS_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+CLASS_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+CONSTRUCTOR_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+CONSTRUCTOR_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+CONSTRUCTOR_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
+CONSTRUCTOR_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+ENUM_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
+ENUM_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+ENUM_ELEMENT_TYPE_REMOVED_ENUM_CONSTANT=Error
+ENUM_ELEMENT_TYPE_REMOVED_FIELD=Error
+ENUM_ELEMENT_TYPE_REMOVED_METHOD=Error
+ENUM_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+FIELD_ELEMENT_TYPE_ADDED_VALUE=Error
+FIELD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+FIELD_ELEMENT_TYPE_CHANGED_FINAL_TO_NON_FINAL_STATIC_CONSTANT=Error
+FIELD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
+FIELD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
+FIELD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
+FIELD_ELEMENT_TYPE_CHANGED_TYPE=Error
+FIELD_ELEMENT_TYPE_CHANGED_VALUE=Error
+FIELD_ELEMENT_TYPE_REMOVED_TYPE_ARGUMENT=Error
+FIELD_ELEMENT_TYPE_REMOVED_VALUE=Error
+ILLEGAL_EXTEND=Warning
+ILLEGAL_IMPLEMENT=Warning
+ILLEGAL_INSTANTIATE=Warning
+ILLEGAL_OVERRIDE=Warning
+ILLEGAL_REFERENCE=Warning
+INTERFACE_ELEMENT_TYPE_ADDED_FIELD=Error
+INTERFACE_ELEMENT_TYPE_ADDED_METHOD=Error
+INTERFACE_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
+INTERFACE_ELEMENT_TYPE_ADDED_SUPER_INTERFACE_WITH_METHODS=Error
+INTERFACE_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+INTERFACE_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
+INTERFACE_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_FIELD=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_METHOD=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+INVALID_JAVADOC_TAG=Warning
+INVALID_REFERENCE_IN_SYSTEM_LIBRARIES=Warning
+LEAK_EXTEND=Warning
+LEAK_FIELD_DECL=Warning
+LEAK_IMPLEMENT=Warning
+LEAK_METHOD_PARAM=Warning
+LEAK_METHOD_RETURN_TYPE=Warning
+METHOD_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
+METHOD_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+METHOD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+METHOD_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
+METHOD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
+METHOD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
+METHOD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
+METHOD_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
+METHOD_ELEMENT_TYPE_REMOVED_ANNOTATION_DEFAULT_VALUE=Error
+METHOD_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+MISSING_EE_DESCRIPTIONS=Ignore
+TYPE_PARAMETER_ELEMENT_TYPE_ADDED_CLASS_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_ADDED_INTERFACE_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_CLASS_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_INTERFACE_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_CLASS_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_INTERFACE_BOUND=Error
+UNUSED_PROBLEM_FILTERS=Warning
+automatically_removed_unused_problem_filters=false
+eclipse.preferences.version=1
+incompatible_api_component_version=Error
+incompatible_api_component_version_include_major_without_breaking_change=Disabled
+incompatible_api_component_version_include_minor_without_api_change=Disabled
+invalid_since_tag_version=Error
+malformed_since_tag=Error
+missing_since_tag=Error
+report_api_breakage_when_major_version_incremented=Disabled
+report_resolution_errors_api_component=Warning
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/.settings/org.eclipse.pde.prefs b/lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/.settings/org.eclipse.pde.prefs
new file mode 100644 (file)
index 0000000..62cfa90
--- /dev/null
@@ -0,0 +1,32 @@
+compilers.f.unresolved-features=1
+compilers.f.unresolved-plugins=1
+compilers.incompatible-environment=1
+compilers.p.build=1
+compilers.p.build.bin.includes=1
+compilers.p.build.encodings=2
+compilers.p.build.java.compiler=2
+compilers.p.build.java.compliance=1
+compilers.p.build.missing.output=2
+compilers.p.build.output.library=1
+compilers.p.build.source.library=1
+compilers.p.build.src.includes=1
+compilers.p.deprecated=1
+compilers.p.discouraged-class=1
+compilers.p.internal=1
+compilers.p.missing-packages=2
+compilers.p.missing-version-export-package=2
+compilers.p.missing-version-import-package=2
+compilers.p.missing-version-require-bundle=2
+compilers.p.no-required-att=0
+compilers.p.not-externalized-att=2
+compilers.p.unknown-attribute=1
+compilers.p.unknown-class=1
+compilers.p.unknown-element=1
+compilers.p.unknown-identifier=1
+compilers.p.unknown-resource=1
+compilers.p.unresolved-ex-points=0
+compilers.p.unresolved-import=0
+compilers.s.create-docs=false
+compilers.s.doc-folder=doc
+compilers.s.open-tags=1
+eclipse.preferences.version=1
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/META-INF/MANIFEST.MF b/lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/META-INF/MANIFEST.MF
new file mode 100644 (file)
index 0000000..16eade2
--- /dev/null
@@ -0,0 +1,22 @@
+Manifest-Version: 1.0
+Bundle-ManifestVersion: 2
+Bundle-Name: %Bundle-Name
+Bundle-Vendor: %Bundle-Vendor
+Bundle-Version: 1.0.0.qualifier
+Bundle-Localization: plugin
+Bundle-SymbolicName: org.eclipse.tracecompass.lttng2.ust.core.tests;singleton:=true
+Bundle-ActivationPolicy: lazy
+Bundle-RequiredExecutionEnvironment: JavaSE-1.7
+Require-Bundle: org.junit;bundle-version="4.0.0",
+ org.eclipse.core.resources,
+ org.eclipse.core.runtime,
+ org.eclipse.tracecompass.common.core,
+ org.eclipse.tracecompass.tmf.core,
+ org.eclipse.tracecompass.tmf.core.tests,
+ org.eclipse.tracecompass.tmf.ctf.core,
+ org.eclipse.tracecompass.tmf.ctf.core.tests,
+ org.eclipse.tracecompass.lttng2.ust.core,
+ org.eclipse.tracecompass.lttng2.control.core
+Export-Package: org.eclipse.tracecompass.lttng2.ust.core.tests,
+ org.eclipse.tracecompass.lttng2.ust.core.tests.callstack
+Import-Package: com.google.common.collect
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/about.html b/lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/about.html
new file mode 100644 (file)
index 0000000..c258ef5
--- /dev/null
@@ -0,0 +1,28 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"/>
+<title>About</title>
+</head>
+<body lang="EN-US">
+<h2>About This Content</h2>
+<p>June 5, 2006</p>    
+<h3>License</h3>
+
+<p>The Eclipse Foundation makes available all content in this plug-in (&quot;Content&quot;).  Unless otherwise 
+indicated below, the Content is provided to you under the terms and conditions of the
+Eclipse Public License Version 1.0 (&quot;EPL&quot;).  A copy of the EPL is available 
+at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>.
+For purposes of the EPL, &quot;Program&quot; will mean the Content.</p>
+
+<p>If you did not receive this Content directly from the Eclipse Foundation, the Content is 
+being redistributed by another party (&quot;Redistributor&quot;) and different terms and conditions may
+apply to your use of any object code in the Content.  Check the Redistributor's license that was 
+provided with the Content.  If no such license exists, contact the Redistributor.  Unless otherwise
+indicated below, the terms and conditions of the EPL still apply to any source code in the Content
+and such source code may be obtained at <a href="http://www.eclipse.org/">http://www.eclipse.org</a>.</p>
+
+</body>
+</html>
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/build.properties b/lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/build.properties
new file mode 100644 (file)
index 0000000..64c09cd
--- /dev/null
@@ -0,0 +1,21 @@
+###############################################################################
+# Copyright (c) 2013, 2014 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:
+#     Ericsson - Initial API and implementation
+###############################################################################
+
+source.. = src/
+output.. = bin/
+bin.includes = META-INF/,\
+               .,\
+               about.html,\
+               plugin.properties
+src.includes = about.html
+additional.bundles = org.eclipse.jdt.annotation
+jars.extra.classpath = platform:/plugin/org.eclipse.jdt.annotation
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/plugin.properties b/lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/plugin.properties
new file mode 100644 (file)
index 0000000..9bd944f
--- /dev/null
@@ -0,0 +1,14 @@
+###############################################################################
+# Copyright (c) 2013, 2014 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:
+#     Ericsson - Initial API and implementation
+###############################################################################
+
+Bundle-Vendor = Eclipse Trace Compass
+Bundle-Name = Trace Compass LTTng Userspace Tracer Analysis Core Tests Plug-in
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/pom.xml b/lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/pom.xml
new file mode 100644 (file)
index 0000000..da1501b
--- /dev/null
@@ -0,0 +1,42 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+   Copyright (C) 2011, 2013 Red Hat Inc., 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
+-->
+<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>
+    <artifactId>org.eclipse.tracecompass.lttng-parent</artifactId>
+    <groupId>org.eclipse.tracecompass</groupId>
+    <version>1.0.0-SNAPSHOT</version>
+  </parent>
+
+  <artifactId>org.eclipse.tracecompass.lttng2.ust.core.tests</artifactId>
+  <version>1.0.0-SNAPSHOT</version>
+  <packaging>eclipse-test-plugin</packaging>
+
+  <name>Trace Compass LTTng Userspace Tracer Analysis Core Test Plug-in</name>
+
+  <build>
+    <plugins>
+      <plugin>
+        <groupId>org.eclipse.tycho</groupId>
+        <artifactId>tycho-surefire-plugin</artifactId>
+        <version>${tycho-version}</version>
+        <configuration>
+          <useUIHarness>false</useUIHarness>
+          <useUIThread>false</useUIThread>
+          <product>org.eclipse.platform.ide</product>
+        </configuration>
+      </plugin>
+    </plugins>
+  </build>
+
+  <groupId>org.eclipse.tracecompass</groupId>
+</project>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/src/org/eclipse/tracecompass/lttng2/ust/core/tests/ActivatorTest.java b/lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/src/org/eclipse/tracecompass/lttng2/ust/core/tests/ActivatorTest.java
new file mode 100644 (file)
index 0000000..53dbe91
--- /dev/null
@@ -0,0 +1,96 @@
+/*******************************************************************************
+ * Copyright (c) 2013, 2015 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:
+ *   Alexandre Montplaisir - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.ust.core.tests;
+
+import junit.framework.TestCase;
+
+import org.junit.After;
+import org.junit.AfterClass;
+import org.junit.Before;
+import org.junit.BeforeClass;
+import org.junit.Test;
+
+/**
+ * <b><u>ActivatorTest</u></b>
+ * <p>
+ * Test suite for the Activator class
+ * <p>
+ */
+@SuppressWarnings("javadoc")
+public class ActivatorTest extends TestCase {
+
+    // ------------------------------------------------------------------------
+    // JUnit
+    // ------------------------------------------------------------------------
+
+    @BeforeClass
+    public static void setUpBeforeClass() {
+    }
+
+    @AfterClass
+    public static void tearDownAfterClass() {
+    }
+
+    /**
+     * @throws java.lang.Exception
+     */
+    @Before
+    @Override
+    public void setUp() throws Exception {
+    }
+
+    /**
+     * @throws java.lang.Exception
+     */
+    @After
+    @Override
+    public void tearDown() throws Exception {
+    }
+
+    // ------------------------------------------------------------------------
+    // Tests
+    // ------------------------------------------------------------------------
+
+    /**
+     * Test method for {@link org.eclipse.tracecompass.internal.lttng2.ust.core.Activator#Activator()}.
+     */
+    @Test
+    public void testActivator() {
+        assertTrue(true);
+    }
+
+    /**
+     * Test method for {@link org.eclipse.tracecompass.internal.lttng2.ust.core.Activator#getDefault()}.
+     */
+    @Test
+    public void testGetDefault() {
+        assertTrue(true);
+    }
+
+    /**
+     * Test method for {@link org.eclipse.tracecompass.internal.lttng2.ust.core.Activator#start(org.osgi.framework.BundleContext)}.
+     */
+    @Test
+    public void testStartBundleContext() {
+        assertTrue(true);
+    }
+
+    /**
+     * Test method for {@link org.eclipse.tracecompass.internal.lttng2.ust.core.Activator#stop(org.osgi.framework.BundleContext)}.
+     */
+    @Test
+    public void testStopBundleContext() {
+        assertTrue(true);
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/src/org/eclipse/tracecompass/lttng2/ust/core/tests/AllTests.java b/lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/src/org/eclipse/tracecompass/lttng2/ust/core/tests/AllTests.java
new file mode 100644 (file)
index 0000000..36ed9f1
--- /dev/null
@@ -0,0 +1,29 @@
+/*******************************************************************************
+ * Copyright (c) 2013, 2014 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:
+ *   Alexandre Montplaisir - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.ust.core.tests;
+
+import org.eclipse.tracecompass.tmf.core.tests.shared.DebugSuite;
+import org.junit.runner.RunWith;
+
+/**
+ * Runner for the lttng2.kernel unit tests.
+ */
+@RunWith(DebugSuite.class)
+@DebugSuite.SuiteClasses({
+    ActivatorTest.class,
+    org.eclipse.tracecompass.lttng2.ust.core.tests.analysis.memory.AllTests.class,
+    org.eclipse.tracecompass.lttng2.ust.core.tests.callstack.AllTests.class
+})
+public class AllTests {
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/src/org/eclipse/tracecompass/lttng2/ust/core/tests/analysis/memory/AllTests.java b/lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/src/org/eclipse/tracecompass/lttng2/ust/core/tests/analysis/memory/AllTests.java
new file mode 100644 (file)
index 0000000..495af20
--- /dev/null
@@ -0,0 +1,27 @@
+/*******************************************************************************
+ * Copyright (c) 2014 École Polytechnique de Montréal
+ *
+ * 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:
+ *   Guilliano Molaire - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.ust.core.tests.analysis.memory;
+
+import org.junit.runner.RunWith;
+import org.junit.runners.Suite;
+
+/**
+ * Test suite.
+ */
+@RunWith(Suite.class)
+@Suite.SuiteClasses({
+    UstMemoryAnalysisModuleTest.class
+})
+public class AllTests {
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/src/org/eclipse/tracecompass/lttng2/ust/core/tests/analysis/memory/UstMemoryAnalysisModuleTest.java b/lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/src/org/eclipse/tracecompass/lttng2/ust/core/tests/analysis/memory/UstMemoryAnalysisModuleTest.java
new file mode 100644 (file)
index 0000000..0ec8f10
--- /dev/null
@@ -0,0 +1,101 @@
+/*******************************************************************************
+ * Copyright (c) 2014 École Polytechnique de Montréal
+ *
+ * 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:
+ *   Guilliano Molaire - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.ust.core.tests.analysis.memory;
+
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertNotNull;
+import static org.junit.Assert.assertTrue;
+
+import java.util.Set;
+
+import org.eclipse.tracecompass.internal.lttng2.ust.core.analysis.memory.UstMemoryStrings;
+import org.eclipse.tracecompass.lttng2.control.core.session.SessionConfigStrings;
+import org.eclipse.tracecompass.lttng2.ust.core.analysis.memory.UstMemoryAnalysisModule;
+import org.eclipse.tracecompass.tmf.core.analysis.TmfAnalysisRequirement;
+import org.junit.Before;
+import org.junit.Test;
+
+import com.google.common.collect.ImmutableSet;
+
+/**
+ * Tests for the {@link UstMemoryAnalysisModule}
+ *
+ * @author Guilliano Molaire
+ */
+public class UstMemoryAnalysisModuleTest {
+
+    /** The analysis module */
+    private UstMemoryAnalysisModule fUstAnalysisModule;
+
+    /**
+     * Set-up the test
+     */
+    @Before
+    public void setup() {
+        fUstAnalysisModule = new UstMemoryAnalysisModule();
+    }
+
+    /**
+     * Test for {@link UstMemoryAnalysisModule#getAnalysisRequirements()}
+     */
+    @Test
+    public void testGetAnalysisRequirements() {
+        Iterable<TmfAnalysisRequirement> requirements = fUstAnalysisModule.getAnalysisRequirements();
+        assertNotNull(requirements);
+        assertTrue(requirements.iterator().hasNext());
+
+        /* There should be the event and domain type */
+        TmfAnalysisRequirement eventReq = null;
+        TmfAnalysisRequirement domainReq = null;
+        int numberOfRequirement = 0;
+        for (TmfAnalysisRequirement requirement : requirements) {
+            ++numberOfRequirement;
+            if (requirement.getType().equals(SessionConfigStrings.CONFIG_ELEMENT_EVENT)) {
+                eventReq = requirement;
+            } else if (requirement.getType().equals(SessionConfigStrings.CONFIG_ELEMENT_DOMAIN)) {
+                domainReq = requirement;
+            }
+        }
+        assertNotNull(eventReq);
+        assertNotNull(domainReq);
+
+        /* There should be two requirements */
+        assertEquals(2, numberOfRequirement);
+
+        /* Verify the content of the requirements themselves */
+        /* Domain should be kernel */
+        assertEquals(1, domainReq.getValues().size());
+        for (String domain : domainReq.getValues()) {
+            assertEquals(SessionConfigStrings.CONFIG_DOMAIN_TYPE_UST, domain);
+        }
+
+        /* Events */
+        Set<String> expectedEvents = ImmutableSet.of(
+                UstMemoryStrings.MALLOC,
+                UstMemoryStrings.FREE,
+                UstMemoryStrings.CALLOC,
+                UstMemoryStrings.REALLOC,
+                UstMemoryStrings.MEMALIGN,
+                UstMemoryStrings.POSIX_MEMALIGN
+                );
+
+        assertEquals(6, eventReq.getValues().size());
+        for (String event : eventReq.getValues()) {
+            assertTrue("Unexpected event " + event, expectedEvents.contains(event));
+        }
+
+        Set<String> infos = eventReq.getInformation();
+        assertEquals(2, infos.size());
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/src/org/eclipse/tracecompass/lttng2/ust/core/tests/callstack/AbstractProviderTest.java b/lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/src/org/eclipse/tracecompass/lttng2/ust/core/tests/callstack/AbstractProviderTest.java
new file mode 100644 (file)
index 0000000..d5b979b
--- /dev/null
@@ -0,0 +1,292 @@
+/*******************************************************************************
+ * Copyright (c) 2014, 2015 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:
+ *   Alexandre Montplaisir - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.ust.core.tests.callstack;
+
+import static org.eclipse.tracecompass.common.core.NonNullUtils.checkNotNull;
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertFalse;
+import static org.junit.Assert.assertNotNull;
+import static org.junit.Assert.assertTrue;
+import static org.junit.Assert.fail;
+
+import java.io.File;
+import java.util.List;
+
+import org.eclipse.tracecompass.internal.lttng2.ust.core.callstack.LttngUstCallStackProvider;
+import org.eclipse.tracecompass.statesystem.core.ITmfStateSystem;
+import org.eclipse.tracecompass.statesystem.core.StateSystemUtils;
+import org.eclipse.tracecompass.statesystem.core.exceptions.AttributeNotFoundException;
+import org.eclipse.tracecompass.statesystem.core.exceptions.StateSystemDisposedException;
+import org.eclipse.tracecompass.statesystem.core.interval.ITmfStateInterval;
+import org.eclipse.tracecompass.statesystem.core.statevalue.ITmfStateValue;
+import org.eclipse.tracecompass.tmf.core.exceptions.TmfAnalysisException;
+import org.eclipse.tracecompass.tmf.core.statesystem.ITmfStateProvider;
+import org.eclipse.tracecompass.tmf.core.statesystem.TmfStateSystemAnalysisModule;
+import org.eclipse.tracecompass.tmf.core.timestamp.ITmfTimestamp;
+import org.eclipse.tracecompass.tmf.core.trace.TmfTraceManager;
+import org.eclipse.tracecompass.tmf.ctf.core.tests.shared.CtfTmfTestTrace;
+import org.eclipse.tracecompass.tmf.ctf.core.trace.CtfTmfTrace;
+import org.junit.After;
+import org.junit.Before;
+import org.junit.Rule;
+import org.junit.Test;
+import org.junit.rules.TestRule;
+import org.junit.rules.Timeout;
+
+/**
+ * Base class for the UST callstack state provider tests.
+ *
+ * @author Alexandre Montplaisir
+ */
+public abstract class AbstractProviderTest {
+
+    /** Time-out tests after 20 seconds */
+    @Rule public TestRule globalTimeout= new Timeout(20000);
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+
+    private static final CtfTmfTestTrace otherUstTrace = CtfTmfTestTrace.HELLO_LOST;
+
+    private CtfTmfTrace fTrace = null;
+    private ITmfStateSystem fSS = null;
+    private TestLttngCallStackModule fModule;
+
+
+    // ------------------------------------------------------------------------
+    // Abstract methods
+    // ------------------------------------------------------------------------
+
+    /**
+     * @return The test trace to use for this test
+     */
+    protected abstract CtfTmfTestTrace getTestTrace();
+
+    /**
+     * @return The name of the executable process in that particular trace
+     */
+    protected abstract String getProcName();
+
+    /**
+     * Get the list of timestamps to query in that trace.
+     *
+     * @param index
+     *            Which of the test timestamps?
+     * @return That particular timestamp
+     */
+    protected abstract long getTestTimestamp(int index);
+
+    // ------------------------------------------------------------------------
+    // Maintenance
+    // ------------------------------------------------------------------------
+
+    /**
+     * Perform pre-class initialization.
+     */
+    @Before
+    public void setUp() {
+        CtfTmfTestTrace testTrace = getTestTrace();
+
+        CtfTmfTrace trace = testTrace.getTrace();
+        fTrace = trace;
+        fModule = new TestLttngCallStackModule();
+        try {
+            assertTrue(fModule.setTrace(trace));
+        } catch (TmfAnalysisException e) {
+            fail();
+        }
+        fModule.schedule();
+        assertTrue(fModule.waitForCompletion());
+
+        fSS = fModule.getStateSystem();
+        assertNotNull(fSS);
+    }
+
+    /**
+     * Perform post-class clean-up.
+     */
+    @After
+    public void tearDown() {
+        fModule.dispose();
+        if (fTrace != null) {
+            fTrace.dispose();
+            File suppDir = new File(TmfTraceManager.getSupplementaryFileDir(fTrace));
+            deleteDirectory(suppDir);
+        }
+    }
+
+    // ------------------------------------------------------------------------
+    // Test methods
+    // ------------------------------------------------------------------------
+
+    /**
+     * Test the handling of generic UST traces who do not contain the required
+     * information.
+     */
+    @Test
+    public void testOtherUstTrace() {
+        /* Initialize the trace and analysis module */
+        File suppDir;
+        try (CtfTmfTrace ustTrace = otherUstTrace.getTrace();) {
+            TestLttngCallStackModule module = null;
+            try {
+                module = new TestLttngCallStackModule();
+                try {
+                    assertTrue(module.setTrace(ustTrace));
+                } catch (TmfAnalysisException e) {
+                    fail();
+                }
+                module.schedule();
+                assertTrue(module.waitForCompletion());
+
+                /* Make sure the generated state system exists, but is empty */
+                ITmfStateSystem ss = module.getStateSystem();
+                assertNotNull(ss);
+                assertTrue(ss.getStartTime() >= ustTrace.getStartTime().normalize(0, ITmfTimestamp.NANOSECOND_SCALE).getValue());
+                assertEquals(0, ss.getNbAttributes());
+            } finally {
+                if (module != null) {
+                    module.dispose();
+                }
+            }
+            suppDir = new File(TmfTraceManager.getSupplementaryFileDir(ustTrace));
+        }
+        deleteDirectory(suppDir);
+        assertFalse(suppDir.exists());
+    }
+
+    /**
+     * Test that the callstack state system is there and contains data.
+     */
+    @Test
+    public void testConstruction() {
+        assertNotNull(fSS);
+        assertTrue(fSS.getNbAttributes() > 0);
+    }
+
+    /**
+     * Test the callstack at the beginning of the state system.
+     */
+    @Test
+    public void testCallStackBegin() {
+        long start = fSS.getStartTime();
+        String[] cs = getCallStack(fSS, getProcName(), start);
+        assertEquals(1, cs.length);
+
+        assertEquals("40472b", cs[0]);
+    }
+
+    /**
+     * Test the callstack somewhere in the trace.
+     */
+    @Test
+    public void testCallStack1() {
+        String[] cs = getCallStack(fSS, getProcName(), getTestTimestamp(0));
+        assertEquals(2, cs.length);
+
+        assertEquals("40472b", cs[0]);
+        assertEquals("403d60", cs[1]);
+    }
+
+    /**
+     * Test the callstack somewhere in the trace.
+     */
+    @Test
+    public void testCallStack2() {
+        String[] cs = getCallStack(fSS, getProcName(), getTestTimestamp(1));
+        assertEquals(3, cs.length);
+
+        assertEquals("40472b", cs[0]);
+        assertEquals("403b14", cs[1]);
+        assertEquals("401b23", cs[2]);
+    }
+
+    /**
+     * Test the callstack somewhere in the trace.
+     */
+    @Test
+    public void testCallStack3() {
+        String[] cs = getCallStack(fSS, getProcName(), getTestTimestamp(2));
+        assertEquals(4, cs.length);
+
+        assertEquals("40472b", cs[0]);
+        assertEquals("4045c8", cs[1]);
+        assertEquals("403760", cs[2]);
+        assertEquals("401aac", cs[3]);
+    }
+
+    /**
+     * Test the callstack at the end of the trace/state system.
+     */
+    @Test
+    public void testCallStackEnd() {
+        long end = fSS.getCurrentEndTime();
+        String[] cs = getCallStack(fSS, getProcName(), end);
+        assertEquals(3, cs.length);
+
+        assertEquals("40472b", cs[0]);
+        assertEquals("4045c8", cs[1]);
+        assertEquals("403760", cs[2]);
+    }
+
+    // ------------------------------------------------------------------------
+    // Utility methods
+    // ------------------------------------------------------------------------
+
+    /** Empty and delete a directory */
+    private static void deleteDirectory(File dir) {
+        /* Assuming the dir only contains file or empty directories */
+        for (File file : dir.listFiles()) {
+            file.delete();
+        }
+        dir.delete();
+    }
+
+    /** Get the callstack for the given timestamp, for this particular trace */
+    private static String[] getCallStack(ITmfStateSystem ss, String processName, long timestamp) {
+        try {
+            int stackAttribute = ss.getQuarkAbsolute("Threads", processName, "CallStack");
+            List<ITmfStateInterval> state = ss.queryFullState(timestamp);
+            int depth = state.get(stackAttribute).getStateValue().unboxInt();
+
+            int stackTop = ss.getQuarkRelative(stackAttribute, String.valueOf(depth));
+            ITmfStateValue expectedValue = state.get(stackTop).getStateValue();
+            ITmfStateInterval interval = StateSystemUtils.querySingleStackTop(ss, timestamp, stackAttribute);
+            assertNotNull(interval);
+            assertEquals(expectedValue, interval.getStateValue());
+
+            String[] ret = new String[depth];
+            for (int i = 0; i < depth; i++) {
+                int quark = ss.getQuarkRelative(stackAttribute, String.valueOf(i + 1));
+                ret[i] = state.get(quark).getStateValue().unboxStr();
+            }
+            return ret;
+
+        } catch (AttributeNotFoundException e) {
+            fail(e.getMessage());
+        } catch (StateSystemDisposedException e) {
+            fail(e.getMessage());
+        }
+        fail();
+        return null;
+    }
+
+    private class TestLttngCallStackModule extends TmfStateSystemAnalysisModule {
+
+        @Override
+        protected ITmfStateProvider createStateProvider() {
+            return new LttngUstCallStackProvider(checkNotNull(getTrace()));
+        }
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/src/org/eclipse/tracecompass/lttng2/ust/core/tests/callstack/AllTests.java b/lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/src/org/eclipse/tracecompass/lttng2/ust/core/tests/callstack/AllTests.java
new file mode 100644 (file)
index 0000000..70b2807
--- /dev/null
@@ -0,0 +1,28 @@
+/*******************************************************************************
+ * Copyright (c) 2013, 2015 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:
+ *   Alexandre Montplaisir - Initial implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.ust.core.tests.callstack;
+
+import org.junit.runner.RunWith;
+import org.junit.runners.Suite;
+
+/**
+ * Test suite for org.eclipse.tracecompass.lttng2.ust.core.tests.trace.callstack
+ */
+@RunWith(Suite.class)
+@Suite.SuiteClasses({
+    LttngUstCallStackProviderFastTest.class,
+    LttngUstCallStackProviderTest.class
+})
+public class AllTests {
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/src/org/eclipse/tracecompass/lttng2/ust/core/tests/callstack/LttngUstCallStackProviderFastTest.java b/lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/src/org/eclipse/tracecompass/lttng2/ust/core/tests/callstack/LttngUstCallStackProviderFastTest.java
new file mode 100644 (file)
index 0000000..56935ac
--- /dev/null
@@ -0,0 +1,56 @@
+/*******************************************************************************
+ * Copyright (c) 2013, 2014 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:
+ *   Alexandre Montplaisir - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.ust.core.tests.callstack;
+
+import static org.junit.Assume.assumeTrue;
+
+import org.eclipse.tracecompass.tmf.ctf.core.tests.shared.CtfTmfTestTrace;
+import org.junit.BeforeClass;
+
+/**
+ * Test suite for the UST callstack state provider, using the trace of a program
+ * instrumented with lttng-ust-cyg-profile-fast.so tracepoints. These do not
+ * contain the function addresses in the func_exit events.
+ *
+ * @author Alexandre Montplaisir
+ */
+public class LttngUstCallStackProviderFastTest extends AbstractProviderTest {
+
+    private static final long[] timestamps = { 1379361250310000000L,
+                                               1379361250498400000L,
+                                               1379361250499759000L };
+
+    /**
+     * Class setup
+     */
+    @BeforeClass
+    public static void setUpClass() {
+        assumeTrue(CtfTmfTestTrace.CYG_PROFILE_FAST.exists());
+    }
+
+    @Override
+    protected CtfTmfTestTrace getTestTrace() {
+        return CtfTmfTestTrace.CYG_PROFILE_FAST;
+    }
+
+    @Override
+    protected String getProcName() {
+        return "glxgears-29822";
+    }
+
+    @Override
+    protected long getTestTimestamp(int index) {
+        return timestamps[index];
+    }
+
+}
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/src/org/eclipse/tracecompass/lttng2/ust/core/tests/callstack/LttngUstCallStackProviderTest.java b/lttng/org.eclipse.tracecompass.lttng2.ust.core.tests/src/org/eclipse/tracecompass/lttng2/ust/core/tests/callstack/LttngUstCallStackProviderTest.java
new file mode 100644 (file)
index 0000000..b5d2792
--- /dev/null
@@ -0,0 +1,55 @@
+/*******************************************************************************
+ * Copyright (c) 2013, 2014 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:
+ *   Alexandre Montplaisir - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.ust.core.tests.callstack;
+
+import static org.junit.Assume.assumeTrue;
+
+import org.eclipse.tracecompass.tmf.ctf.core.tests.shared.CtfTmfTestTrace;
+import org.junit.BeforeClass;
+
+/**
+ * Test suite for the UST callstack state provider, using the trace of a program
+ * instrumented with lttng-ust-cyg-profile.so tracepoints.
+ *
+ * @author Alexandre Montplaisir
+ */
+public class LttngUstCallStackProviderTest extends AbstractProviderTest {
+
+    private static final long[] timestamps = { 1378850463600000000L,
+                                               1378850463770000000L,
+                                               1378850463868753000L };
+
+    /**
+     * Class setup
+     */
+    @BeforeClass
+    public static void setUpClass() {
+        assumeTrue(CtfTmfTestTrace.CYG_PROFILE.exists());
+    }
+
+    @Override
+    protected CtfTmfTestTrace getTestTrace() {
+        return CtfTmfTestTrace.CYG_PROFILE;
+    }
+
+    @Override
+    protected String getProcName() {
+        return "glxgears-16073";
+    }
+
+    @Override
+    protected long getTestTimestamp(int index) {
+        return timestamps[index];
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.core/.classpath b/lttng/org.eclipse.tracecompass.lttng2.ust.core/.classpath
new file mode 100644 (file)
index 0000000..098194c
--- /dev/null
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+       <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7"/>
+       <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
+       <classpathentry kind="src" path="src"/>
+       <classpathentry kind="output" path="bin"/>
+</classpath>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.core/.project b/lttng/org.eclipse.tracecompass.lttng2.ust.core/.project
new file mode 100644 (file)
index 0000000..4293adb
--- /dev/null
@@ -0,0 +1,34 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+       <name>org.eclipse.tracecompass.lttng2.ust.core</name>
+       <comment></comment>
+       <projects>
+       </projects>
+       <buildSpec>
+               <buildCommand>
+                       <name>org.eclipse.jdt.core.javabuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+               <buildCommand>
+                       <name>org.eclipse.pde.ManifestBuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+               <buildCommand>
+                       <name>org.eclipse.pde.SchemaBuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+               <buildCommand>
+                       <name>org.eclipse.pde.api.tools.apiAnalysisBuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+       </buildSpec>
+       <natures>
+               <nature>org.eclipse.pde.PluginNature</nature>
+               <nature>org.eclipse.jdt.core.javanature</nature>
+               <nature>org.eclipse.pde.api.tools.apiAnalysisNature</nature>
+       </natures>
+</projectDescription>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.core/.settings/org.eclipse.core.resources.prefs b/lttng/org.eclipse.tracecompass.lttng2.ust.core/.settings/org.eclipse.core.resources.prefs
new file mode 100644 (file)
index 0000000..99f26c0
--- /dev/null
@@ -0,0 +1,2 @@
+eclipse.preferences.version=1
+encoding/<project>=UTF-8
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.core/.settings/org.eclipse.core.runtime.prefs b/lttng/org.eclipse.tracecompass.lttng2.ust.core/.settings/org.eclipse.core.runtime.prefs
new file mode 100644 (file)
index 0000000..5a0ad22
--- /dev/null
@@ -0,0 +1,2 @@
+eclipse.preferences.version=1
+line.separator=\n
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.core/.settings/org.eclipse.jdt.core.prefs b/lttng/org.eclipse.tracecompass.lttng2.ust.core/.settings/org.eclipse.jdt.core.prefs
new file mode 100644 (file)
index 0000000..a2b5e6b
--- /dev/null
@@ -0,0 +1,405 @@
+eclipse.preferences.version=1
+org.eclipse.jdt.core.codeComplete.argumentPrefixes=
+org.eclipse.jdt.core.codeComplete.argumentSuffixes=
+org.eclipse.jdt.core.codeComplete.fieldPrefixes=f
+org.eclipse.jdt.core.codeComplete.fieldSuffixes=
+org.eclipse.jdt.core.codeComplete.localPrefixes=
+org.eclipse.jdt.core.codeComplete.localSuffixes=
+org.eclipse.jdt.core.codeComplete.staticFieldPrefixes=
+org.eclipse.jdt.core.codeComplete.staticFieldSuffixes=
+org.eclipse.jdt.core.codeComplete.staticFinalFieldPrefixes=
+org.eclipse.jdt.core.codeComplete.staticFinalFieldSuffixes=
+org.eclipse.jdt.core.compiler.annotation.inheritNullAnnotations=enabled
+org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore
+org.eclipse.jdt.core.compiler.annotation.nonnull=org.eclipse.jdt.annotation.NonNull
+org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=org.eclipse.jdt.annotation.NonNullByDefault
+org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nullable
+org.eclipse.jdt.core.compiler.annotation.nullanalysis=enabled
+org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
+org.eclipse.jdt.core.compiler.codegen.methodParameters=do not generate
+org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
+org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
+org.eclipse.jdt.core.compiler.compliance=1.7
+org.eclipse.jdt.core.compiler.debug.lineNumber=generate
+org.eclipse.jdt.core.compiler.debug.localVariable=generate
+org.eclipse.jdt.core.compiler.debug.sourceFile=generate
+org.eclipse.jdt.core.compiler.doc.comment.support=enabled
+org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=error
+org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
+org.eclipse.jdt.core.compiler.problem.autoboxing=ignore
+org.eclipse.jdt.core.compiler.problem.comparingIdentical=error
+org.eclipse.jdt.core.compiler.problem.deadCode=error
+org.eclipse.jdt.core.compiler.problem.deprecation=error
+org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled
+org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=enabled
+org.eclipse.jdt.core.compiler.problem.discouragedReference=warning
+org.eclipse.jdt.core.compiler.problem.emptyStatement=error
+org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
+org.eclipse.jdt.core.compiler.problem.explicitlyClosedAutoCloseable=error
+org.eclipse.jdt.core.compiler.problem.fallthroughCase=error
+org.eclipse.jdt.core.compiler.problem.fatalOptionalError=disabled
+org.eclipse.jdt.core.compiler.problem.fieldHiding=error
+org.eclipse.jdt.core.compiler.problem.finalParameterBound=error
+org.eclipse.jdt.core.compiler.problem.finallyBlockNotCompletingNormally=error
+org.eclipse.jdt.core.compiler.problem.forbiddenReference=error
+org.eclipse.jdt.core.compiler.problem.hiddenCatchBlock=error
+org.eclipse.jdt.core.compiler.problem.includeNullInfoFromAsserts=disabled
+org.eclipse.jdt.core.compiler.problem.incompatibleNonInheritedInterfaceMethod=error
+org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch=error
+org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=error
+org.eclipse.jdt.core.compiler.problem.invalidJavadoc=warning
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTags=enabled
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsDeprecatedRef=enabled
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsNotVisibleRef=enabled
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsVisibility=protected
+org.eclipse.jdt.core.compiler.problem.localVariableHiding=error
+org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=error
+org.eclipse.jdt.core.compiler.problem.missingDefaultCase=error
+org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=error
+org.eclipse.jdt.core.compiler.problem.missingEnumCaseDespiteDefault=enabled
+org.eclipse.jdt.core.compiler.problem.missingHashCodeMethod=error
+org.eclipse.jdt.core.compiler.problem.missingJavadocComments=warning
+org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsOverriding=disabled
+org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsVisibility=protected
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagDescription=all_standard_tags
+org.eclipse.jdt.core.compiler.problem.missingJavadocTags=warning
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagsMethodTypeParameters=disabled
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagsOverriding=disabled
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagsVisibility=protected
+org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotation=error
+org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotationForInterfaceMethodImplementation=enabled
+org.eclipse.jdt.core.compiler.problem.missingSerialVersion=error
+org.eclipse.jdt.core.compiler.problem.missingSynchronizedOnInheritedMethod=error
+org.eclipse.jdt.core.compiler.problem.noEffectAssignment=error
+org.eclipse.jdt.core.compiler.problem.noImplicitStringConversion=error
+org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=warning
+org.eclipse.jdt.core.compiler.problem.nonnullParameterAnnotationDropped=warning
+org.eclipse.jdt.core.compiler.problem.nullAnnotationInferenceConflict=warning
+org.eclipse.jdt.core.compiler.problem.nullReference=error
+org.eclipse.jdt.core.compiler.problem.nullSpecViolation=error
+org.eclipse.jdt.core.compiler.problem.nullUncheckedConversion=warning
+org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=error
+org.eclipse.jdt.core.compiler.problem.parameterAssignment=error
+org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=error
+org.eclipse.jdt.core.compiler.problem.potentialNullReference=error
+org.eclipse.jdt.core.compiler.problem.potentiallyUnclosedCloseable=warning
+org.eclipse.jdt.core.compiler.problem.rawTypeReference=warning
+org.eclipse.jdt.core.compiler.problem.redundantNullAnnotation=warning
+org.eclipse.jdt.core.compiler.problem.redundantNullCheck=error
+org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=error
+org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=error
+org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore
+org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=error
+org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled
+org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=error
+org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=disabled
+org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled
+org.eclipse.jdt.core.compiler.problem.syntacticNullAnalysisForFields=enabled
+org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=ignore
+org.eclipse.jdt.core.compiler.problem.typeParameterHiding=error
+org.eclipse.jdt.core.compiler.problem.unavoidableGenericTypeProblems=disabled
+org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=warning
+org.eclipse.jdt.core.compiler.problem.unclosedCloseable=error
+org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=ignore
+org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=error
+org.eclipse.jdt.core.compiler.problem.unnecessaryElse=error
+org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=error
+org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=warning
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionExemptExceptionAndThrowable=disabled
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionIncludeDocCommentReference=disabled
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverriding=disabled
+org.eclipse.jdt.core.compiler.problem.unusedExceptionParameter=ignore
+org.eclipse.jdt.core.compiler.problem.unusedImport=error
+org.eclipse.jdt.core.compiler.problem.unusedLabel=error
+org.eclipse.jdt.core.compiler.problem.unusedLocal=error
+org.eclipse.jdt.core.compiler.problem.unusedObjectAllocation=ignore
+org.eclipse.jdt.core.compiler.problem.unusedParameter=error
+org.eclipse.jdt.core.compiler.problem.unusedParameterIncludeDocCommentReference=enabled
+org.eclipse.jdt.core.compiler.problem.unusedParameterWhenImplementingAbstract=disabled
+org.eclipse.jdt.core.compiler.problem.unusedParameterWhenOverridingConcrete=disabled
+org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=error
+org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=error
+org.eclipse.jdt.core.compiler.problem.unusedWarningToken=error
+org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=error
+org.eclipse.jdt.core.compiler.source=1.7
+org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=16
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_call=16
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation=16
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression=16
+org.eclipse.jdt.core.formatter.alignment_for_assignment=0
+org.eclipse.jdt.core.formatter.alignment_for_binary_expression=16
+org.eclipse.jdt.core.formatter.alignment_for_compact_if=16
+org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=80
+org.eclipse.jdt.core.formatter.alignment_for_enum_constants=0
+org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=16
+org.eclipse.jdt.core.formatter.alignment_for_method_declaration=0
+org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16
+org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=80
+org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation=0
+org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_constructor_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_method_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_union_type_in_multicatch=16
+org.eclipse.jdt.core.formatter.blank_lines_after_imports=1
+org.eclipse.jdt.core.formatter.blank_lines_after_package=1
+org.eclipse.jdt.core.formatter.blank_lines_before_field=0
+org.eclipse.jdt.core.formatter.blank_lines_before_first_class_body_declaration=0
+org.eclipse.jdt.core.formatter.blank_lines_before_imports=1
+org.eclipse.jdt.core.formatter.blank_lines_before_member_type=1
+org.eclipse.jdt.core.formatter.blank_lines_before_method=1
+org.eclipse.jdt.core.formatter.blank_lines_before_new_chunk=1
+org.eclipse.jdt.core.formatter.blank_lines_before_package=0
+org.eclipse.jdt.core.formatter.blank_lines_between_import_groups=1
+org.eclipse.jdt.core.formatter.blank_lines_between_type_declarations=1
+org.eclipse.jdt.core.formatter.brace_position_for_annotation_type_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_array_initializer=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_block=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_block_in_case=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_constructor_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_enum_constant=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_enum_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_method_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_switch=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_type_declaration=end_of_line
+org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_block_comment=false
+org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_javadoc_comment=false
+org.eclipse.jdt.core.formatter.comment.format_block_comments=true
+org.eclipse.jdt.core.formatter.comment.format_header=false
+org.eclipse.jdt.core.formatter.comment.format_html=true
+org.eclipse.jdt.core.formatter.comment.format_javadoc_comments=true
+org.eclipse.jdt.core.formatter.comment.format_line_comments=true
+org.eclipse.jdt.core.formatter.comment.format_source_code=true
+org.eclipse.jdt.core.formatter.comment.indent_parameter_description=true
+org.eclipse.jdt.core.formatter.comment.indent_root_tags=true
+org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags=insert
+org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter=insert
+org.eclipse.jdt.core.formatter.comment.line_length=80
+org.eclipse.jdt.core.formatter.comment.new_lines_at_block_boundaries=true
+org.eclipse.jdt.core.formatter.comment.new_lines_at_javadoc_boundaries=true
+org.eclipse.jdt.core.formatter.comment.preserve_white_space_between_code_and_line_comments=false
+org.eclipse.jdt.core.formatter.compact_else_if=true
+org.eclipse.jdt.core.formatter.continuation_indentation=2
+org.eclipse.jdt.core.formatter.continuation_indentation_for_array_initializer=2
+org.eclipse.jdt.core.formatter.disabling_tag=@formatter\:off
+org.eclipse.jdt.core.formatter.enabling_tag=@formatter\:on
+org.eclipse.jdt.core.formatter.format_guardian_clause_on_one_line=false
+org.eclipse.jdt.core.formatter.format_line_comment_starting_on_first_column=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_annotation_declaration_header=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_constant_header=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_declaration_header=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_type_header=true
+org.eclipse.jdt.core.formatter.indent_breaks_compare_to_cases=true
+org.eclipse.jdt.core.formatter.indent_empty_lines=false
+org.eclipse.jdt.core.formatter.indent_statements_compare_to_block=true
+org.eclipse.jdt.core.formatter.indent_statements_compare_to_body=true
+org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_cases=true
+org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_switch=false
+org.eclipse.jdt.core.formatter.indentation.size=4
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_field=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_local_variable=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_method=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_package=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_parameter=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_type=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_label=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_opening_brace_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_at_end_of_file_if_missing=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_finally_in_try_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_while_in_do_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_annotation_declaration=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_anonymous_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_block=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter=insert
+org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_binary_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_paren_in_cast=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_assert=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_case=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_labeled_statement=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_allocation_expression=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_annotation=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_throws=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_constant_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_declarations=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_explicitconstructorcall_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_increments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_inits=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_throws=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_invocation_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_field_declarations=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_local_declarations=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_parameterized_type_reference=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_superinterfaces=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_ellipsis=insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_brace_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_cast=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_catch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_for=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_if=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_parenthesized_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_switch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_synchronized=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_try=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_while=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_try_resources=insert
+org.eclipse.jdt.core.formatter.insert_space_after_unary_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter=insert
+org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_binary_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_brace_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_cast=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_catch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_for=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_if=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_parenthesized_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_switch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_synchronized=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_try=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_while=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_assert=insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_case=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_default=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_labeled_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_throws=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_constant_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_declarations=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_explicitconstructorcall_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_increments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_inits=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_throws=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_invocation_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_field_declarations=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_local_declarations=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_superinterfaces=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_ellipsis=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_annotation_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_anonymous_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_block=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_constructor_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_constant=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_method_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_switch=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation_type_member_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_catch=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_if=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_parenthesized_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_switch=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_synchronized=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_try=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_while=insert
+org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_return=insert
+org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_throw=insert
+org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_semicolon=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_try_resources=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_unary_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_brackets_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_annotation_type_member_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.join_lines_in_comments=true
+org.eclipse.jdt.core.formatter.join_wrapped_lines=false
+org.eclipse.jdt.core.formatter.keep_else_statement_on_same_line=false
+org.eclipse.jdt.core.formatter.keep_empty_array_initializer_on_one_line=false
+org.eclipse.jdt.core.formatter.keep_imple_if_on_one_line=false
+org.eclipse.jdt.core.formatter.keep_then_statement_on_same_line=false
+org.eclipse.jdt.core.formatter.lineSplit=250
+org.eclipse.jdt.core.formatter.never_indent_block_comments_on_first_column=false
+org.eclipse.jdt.core.formatter.never_indent_line_comments_on_first_column=false
+org.eclipse.jdt.core.formatter.number_of_blank_lines_at_beginning_of_method_body=0
+org.eclipse.jdt.core.formatter.number_of_empty_lines_to_preserve=1
+org.eclipse.jdt.core.formatter.put_empty_statement_on_new_line=true
+org.eclipse.jdt.core.formatter.tabulation.char=space
+org.eclipse.jdt.core.formatter.tabulation.size=4
+org.eclipse.jdt.core.formatter.use_on_off_tags=false
+org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false
+org.eclipse.jdt.core.formatter.wrap_before_binary_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_or_operator_multicatch=true
+org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.core/.settings/org.eclipse.jdt.ui.prefs b/lttng/org.eclipse.tracecompass.lttng2.ust.core/.settings/org.eclipse.jdt.ui.prefs
new file mode 100644 (file)
index 0000000..232a3fd
--- /dev/null
@@ -0,0 +1,60 @@
+eclipse.preferences.version=1
+editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true
+formatter_profile=_tmf-style
+formatter_settings_version=12
+org.eclipse.jdt.ui.exception.name=e
+org.eclipse.jdt.ui.gettersetter.use.is=true
+org.eclipse.jdt.ui.keywordthis=false
+org.eclipse.jdt.ui.overrideannotation=true
+sp_cleanup.add_default_serial_version_id=true
+sp_cleanup.add_generated_serial_version_id=false
+sp_cleanup.add_missing_annotations=false
+sp_cleanup.add_missing_deprecated_annotations=true
+sp_cleanup.add_missing_methods=false
+sp_cleanup.add_missing_nls_tags=false
+sp_cleanup.add_missing_override_annotations=true
+sp_cleanup.add_missing_override_annotations_interface_methods=true
+sp_cleanup.add_serial_version_id=false
+sp_cleanup.always_use_blocks=true
+sp_cleanup.always_use_parentheses_in_expressions=false
+sp_cleanup.always_use_this_for_non_static_field_access=false
+sp_cleanup.always_use_this_for_non_static_method_access=false
+sp_cleanup.convert_to_enhanced_for_loop=false
+sp_cleanup.correct_indentation=false
+sp_cleanup.format_source_code=false
+sp_cleanup.format_source_code_changes_only=false
+sp_cleanup.make_local_variable_final=false
+sp_cleanup.make_parameters_final=false
+sp_cleanup.make_private_fields_final=true
+sp_cleanup.make_type_abstract_if_missing_method=false
+sp_cleanup.make_variable_declarations_final=false
+sp_cleanup.never_use_blocks=false
+sp_cleanup.never_use_parentheses_in_expressions=true
+sp_cleanup.on_save_use_additional_actions=true
+sp_cleanup.organize_imports=false
+sp_cleanup.qualify_static_field_accesses_with_declaring_class=false
+sp_cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=true
+sp_cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=true
+sp_cleanup.qualify_static_member_accesses_with_declaring_class=false
+sp_cleanup.qualify_static_method_accesses_with_declaring_class=false
+sp_cleanup.remove_private_constructors=true
+sp_cleanup.remove_trailing_whitespaces=true
+sp_cleanup.remove_trailing_whitespaces_all=true
+sp_cleanup.remove_trailing_whitespaces_ignore_empty=false
+sp_cleanup.remove_unnecessary_casts=false
+sp_cleanup.remove_unnecessary_nls_tags=false
+sp_cleanup.remove_unused_imports=false
+sp_cleanup.remove_unused_local_variables=false
+sp_cleanup.remove_unused_private_fields=true
+sp_cleanup.remove_unused_private_members=false
+sp_cleanup.remove_unused_private_methods=true
+sp_cleanup.remove_unused_private_types=true
+sp_cleanup.sort_members=false
+sp_cleanup.sort_members_all=false
+sp_cleanup.use_blocks=true
+sp_cleanup.use_blocks_only_for_return_and_throw=false
+sp_cleanup.use_parentheses_in_expressions=false
+sp_cleanup.use_this_for_non_static_field_access=false
+sp_cleanup.use_this_for_non_static_field_access_only_if_necessary=true
+sp_cleanup.use_this_for_non_static_method_access=false
+sp_cleanup.use_this_for_non_static_method_access_only_if_necessary=true
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.core/.settings/org.eclipse.pde.api.tools.prefs b/lttng/org.eclipse.tracecompass.lttng2.ust.core/.settings/org.eclipse.pde.api.tools.prefs
new file mode 100644 (file)
index 0000000..acc3abd
--- /dev/null
@@ -0,0 +1,97 @@
+ANNOTATION_ELEMENT_TYPE_ADDED_METHOD_WITHOUT_DEFAULT_VALUE=Error
+ANNOTATION_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+ANNOTATION_ELEMENT_TYPE_REMOVED_FIELD=Error
+ANNOTATION_ELEMENT_TYPE_REMOVED_METHOD=Error
+ANNOTATION_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_API_TYPE=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_API_TYPE=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_TYPE=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_TYPE=Error
+API_USE_SCAN_FIELD_SEVERITY=Error
+API_USE_SCAN_METHOD_SEVERITY=Error
+API_USE_SCAN_TYPE_SEVERITY=Error
+CLASS_ELEMENT_TYPE_ADDED_METHOD=Error
+CLASS_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
+CLASS_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+CLASS_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
+CLASS_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+CLASS_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
+CLASS_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
+CLASS_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+CLASS_ELEMENT_TYPE_REMOVED_CONSTRUCTOR=Error
+CLASS_ELEMENT_TYPE_REMOVED_FIELD=Error
+CLASS_ELEMENT_TYPE_REMOVED_METHOD=Error
+CLASS_ELEMENT_TYPE_REMOVED_SUPERCLASS=Error
+CLASS_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+CLASS_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+CONSTRUCTOR_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+CONSTRUCTOR_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+CONSTRUCTOR_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
+CONSTRUCTOR_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+ENUM_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
+ENUM_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+ENUM_ELEMENT_TYPE_REMOVED_ENUM_CONSTANT=Error
+ENUM_ELEMENT_TYPE_REMOVED_FIELD=Error
+ENUM_ELEMENT_TYPE_REMOVED_METHOD=Error
+ENUM_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+FIELD_ELEMENT_TYPE_ADDED_VALUE=Error
+FIELD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+FIELD_ELEMENT_TYPE_CHANGED_FINAL_TO_NON_FINAL_STATIC_CONSTANT=Error
+FIELD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
+FIELD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
+FIELD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
+FIELD_ELEMENT_TYPE_CHANGED_TYPE=Error
+FIELD_ELEMENT_TYPE_CHANGED_VALUE=Error
+FIELD_ELEMENT_TYPE_REMOVED_TYPE_ARGUMENT=Error
+FIELD_ELEMENT_TYPE_REMOVED_VALUE=Error
+ILLEGAL_EXTEND=Warning
+ILLEGAL_IMPLEMENT=Warning
+ILLEGAL_INSTANTIATE=Warning
+ILLEGAL_OVERRIDE=Warning
+ILLEGAL_REFERENCE=Warning
+INTERFACE_ELEMENT_TYPE_ADDED_FIELD=Error
+INTERFACE_ELEMENT_TYPE_ADDED_METHOD=Error
+INTERFACE_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
+INTERFACE_ELEMENT_TYPE_ADDED_SUPER_INTERFACE_WITH_METHODS=Error
+INTERFACE_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+INTERFACE_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
+INTERFACE_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_FIELD=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_METHOD=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+INVALID_JAVADOC_TAG=Warning
+INVALID_REFERENCE_IN_SYSTEM_LIBRARIES=Warning
+LEAK_EXTEND=Warning
+LEAK_FIELD_DECL=Warning
+LEAK_IMPLEMENT=Warning
+LEAK_METHOD_PARAM=Warning
+LEAK_METHOD_RETURN_TYPE=Warning
+METHOD_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
+METHOD_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+METHOD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+METHOD_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
+METHOD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
+METHOD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
+METHOD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
+METHOD_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
+METHOD_ELEMENT_TYPE_REMOVED_ANNOTATION_DEFAULT_VALUE=Error
+METHOD_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+MISSING_EE_DESCRIPTIONS=Ignore
+TYPE_PARAMETER_ELEMENT_TYPE_ADDED_CLASS_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_ADDED_INTERFACE_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_CLASS_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_INTERFACE_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_CLASS_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_INTERFACE_BOUND=Error
+UNUSED_PROBLEM_FILTERS=Warning
+automatically_removed_unused_problem_filters=false
+eclipse.preferences.version=1
+incompatible_api_component_version=Error
+incompatible_api_component_version_include_major_without_breaking_change=Disabled
+incompatible_api_component_version_include_minor_without_api_change=Disabled
+invalid_since_tag_version=Error
+malformed_since_tag=Error
+missing_since_tag=Error
+report_api_breakage_when_major_version_incremented=Disabled
+report_resolution_errors_api_component=Warning
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.core/.settings/org.eclipse.pde.prefs b/lttng/org.eclipse.tracecompass.lttng2.ust.core/.settings/org.eclipse.pde.prefs
new file mode 100644 (file)
index 0000000..d92b94f
--- /dev/null
@@ -0,0 +1,32 @@
+compilers.f.unresolved-features=1
+compilers.f.unresolved-plugins=1
+compilers.incompatible-environment=1
+compilers.p.build=1
+compilers.p.build.bin.includes=1
+compilers.p.build.encodings=2
+compilers.p.build.java.compiler=2
+compilers.p.build.java.compliance=1
+compilers.p.build.missing.output=2
+compilers.p.build.output.library=1
+compilers.p.build.source.library=1
+compilers.p.build.src.includes=1
+compilers.p.deprecated=1
+compilers.p.discouraged-class=1
+compilers.p.internal=1
+compilers.p.missing-packages=1
+compilers.p.missing-version-export-package=2
+compilers.p.missing-version-import-package=2
+compilers.p.missing-version-require-bundle=2
+compilers.p.no-required-att=0
+compilers.p.not-externalized-att=1
+compilers.p.unknown-attribute=1
+compilers.p.unknown-class=1
+compilers.p.unknown-element=1
+compilers.p.unknown-identifier=1
+compilers.p.unknown-resource=1
+compilers.p.unresolved-ex-points=0
+compilers.p.unresolved-import=0
+compilers.s.create-docs=false
+compilers.s.doc-folder=doc
+compilers.s.open-tags=1
+eclipse.preferences.version=1
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.core/META-INF/MANIFEST.MF b/lttng/org.eclipse.tracecompass.lttng2.ust.core/META-INF/MANIFEST.MF
new file mode 100644 (file)
index 0000000..abc60e7
--- /dev/null
@@ -0,0 +1,22 @@
+Manifest-Version: 1.0
+Bundle-ManifestVersion: 2
+Bundle-Name: %Bundle-Name
+Bundle-Vendor: %Bundle-Vendor
+Bundle-Version: 1.0.0.qualifier
+Bundle-Localization: plugin
+Bundle-SymbolicName: org.eclipse.tracecompass.lttng2.ust.core;singleton:=true
+Bundle-Activator: org.eclipse.tracecompass.internal.lttng2.ust.core.Activator
+Bundle-ActivationPolicy: lazy
+Bundle-RequiredExecutionEnvironment: JavaSE-1.7
+Export-Package: org.eclipse.tracecompass.internal.lttng2.ust.core;x-friends:="org.eclipse.tracecompass.lttng2.ust.core.tests,org.eclipse.tracecompass.lttng2.ust.ui",
+ org.eclipse.tracecompass.internal.lttng2.ust.core.analysis.memory;x-friends:="org.eclipse.tracecompass.lttng2.ust.ui,org.eclipse.tracecompass.lttng2.ust.core.tests",
+ org.eclipse.tracecompass.internal.lttng2.ust.core.callstack;x-friends:="org.eclipse.tracecompass.lttng2.ust.ui,org.eclipse.tracecompass.lttng2.ust.core.tests",
+ org.eclipse.tracecompass.lttng2.ust.core.analysis.memory,
+ org.eclipse.tracecompass.lttng2.ust.core.trace
+Require-Bundle: org.eclipse.core.runtime,
+ org.eclipse.core.resources,
+ org.eclipse.tracecompass.common.core,
+ org.eclipse.tracecompass.tmf.core,
+ org.eclipse.tracecompass.tmf.ctf.core,
+ org.eclipse.tracecompass.lttng2.control.core
+Import-Package: com.google.common.collect
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.core/about.html b/lttng/org.eclipse.tracecompass.lttng2.ust.core/about.html
new file mode 100644 (file)
index 0000000..c258ef5
--- /dev/null
@@ -0,0 +1,28 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"/>
+<title>About</title>
+</head>
+<body lang="EN-US">
+<h2>About This Content</h2>
+<p>June 5, 2006</p>    
+<h3>License</h3>
+
+<p>The Eclipse Foundation makes available all content in this plug-in (&quot;Content&quot;).  Unless otherwise 
+indicated below, the Content is provided to you under the terms and conditions of the
+Eclipse Public License Version 1.0 (&quot;EPL&quot;).  A copy of the EPL is available 
+at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>.
+For purposes of the EPL, &quot;Program&quot; will mean the Content.</p>
+
+<p>If you did not receive this Content directly from the Eclipse Foundation, the Content is 
+being redistributed by another party (&quot;Redistributor&quot;) and different terms and conditions may
+apply to your use of any object code in the Content.  Check the Redistributor's license that was 
+provided with the Content.  If no such license exists, contact the Redistributor.  Unless otherwise
+indicated below, the terms and conditions of the EPL still apply to any source code in the Content
+and such source code may be obtained at <a href="http://www.eclipse.org/">http://www.eclipse.org</a>.</p>
+
+</body>
+</html>
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.core/build.properties b/lttng/org.eclipse.tracecompass.lttng2.ust.core/build.properties
new file mode 100644 (file)
index 0000000..244c9d8
--- /dev/null
@@ -0,0 +1,22 @@
+###############################################################################
+# Copyright (c) 2013, 2014 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:
+#     Ericsson - Initial API and implementation
+###############################################################################
+
+source.. = src/
+output.. = bin/
+bin.includes = META-INF/,\
+               .,\
+               about.html,\
+               plugin.properties,\
+               plugin.xml
+src.includes = about.html
+additional.bundles = org.eclipse.jdt.annotation
+jars.extra.classpath = platform:/plugin/org.eclipse.jdt.annotation
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.core/plugin.properties b/lttng/org.eclipse.tracecompass.lttng2.ust.core/plugin.properties
new file mode 100644 (file)
index 0000000..db7013a
--- /dev/null
@@ -0,0 +1,16 @@
+###############################################################################
+# Copyright (c) 2013, 2014 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:
+#     Ericsson - Initial API and implementation
+###############################################################################
+
+Bundle-Vendor = Eclipse Trace Compass
+Bundle-Name = Trace Compass LTTng Userspace Tracer Analysis Core Plug-in
+
+tracetype.type.ust = LTTng UST Trace
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.core/plugin.xml b/lttng/org.eclipse.tracecompass.lttng2.ust.core/plugin.xml
new file mode 100644 (file)
index 0000000..963f4f3
--- /dev/null
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<?eclipse version="3.4"?>
+<plugin>
+   <extension
+         point="org.eclipse.linuxtools.tmf.core.tracetype">
+      <type
+            category="org.eclipse.linuxtools.tmf.ctf.core.category.ctf"
+            event_type="org.eclipse.tracecompass.tmf.ctf.core.event.CtfTmfEvent"
+            id="org.eclipse.linuxtools.lttng2.ust.tracetype"
+            isDirectory="true"
+            name="%tracetype.type.ust"
+            trace_type="org.eclipse.tracecompass.lttng2.ust.core.trace.LttngUstTrace">
+      </type>
+   </extension>
+   <extension
+         point="org.eclipse.linuxtools.tmf.core.analysis">
+      <module
+            analysis_module="org.eclipse.tracecompass.lttng2.ust.core.analysis.memory.UstMemoryAnalysisModule"
+            id="org.eclipse.linuxtools.lttng2.ust.analysis.memory"
+            name="Ust Memory">
+         <tracetype
+               class="org.eclipse.tracecompass.lttng2.ust.core.trace.LttngUstTrace">
+         </tracetype>
+      </module>
+   </extension>
+</plugin>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.core/pom.xml b/lttng/org.eclipse.tracecompass.lttng2.ust.core/pom.xml
new file mode 100644 (file)
index 0000000..e26c91c
--- /dev/null
@@ -0,0 +1,36 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+   Copyright (C) 2011, 2013 Red Hat Inc., 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
+-->
+<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>
+    <artifactId>org.eclipse.tracecompass.lttng-parent</artifactId>
+    <groupId>org.eclipse.tracecompass</groupId>
+    <version>1.0.0-SNAPSHOT</version>
+  </parent>
+
+  <artifactId>org.eclipse.tracecompass.lttng2.ust.core</artifactId>
+  <version>1.0.0-SNAPSHOT</version>
+  <packaging>eclipse-plugin</packaging>
+
+  <name>Trace Compass LTTng Userspace Tracer Analysis Core Plug-in</name>
+
+ <build>
+    <plugins>
+      <plugin>
+        <groupId>org.eclipse.tycho</groupId>
+        <artifactId>tycho-source-plugin</artifactId>
+      </plugin>
+    </plugins>
+  </build>
+
+  <groupId>org.eclipse.tracecompass</groupId>
+</project>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/internal/lttng2/ust/core/Activator.java b/lttng/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/internal/lttng2/ust/core/Activator.java
new file mode 100644 (file)
index 0000000..9fc434c
--- /dev/null
@@ -0,0 +1,137 @@
+/*******************************************************************************
+ * Copyright (c) 2013, 2015 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:
+ *   Alexandre Montplaisir - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.ust.core;
+
+import org.eclipse.core.runtime.IStatus;
+import org.eclipse.core.runtime.Plugin;
+import org.eclipse.core.runtime.Status;
+import org.osgi.framework.BundleContext;
+
+/**
+ * <b><u>Activator</u></b>
+ * <p>
+ * The activator class controls the plug-in life cycle
+ */
+public class Activator extends Plugin {
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+
+    /**
+     * The plug-in ID
+     */
+    public static final String PLUGIN_ID = "org.eclipse.tracecompass.lttng2.ust.core"; //$NON-NLS-1$
+
+    /**
+     * The shared instance
+     */
+    private static Activator plugin;
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+
+    /**
+     * The constructor
+     */
+    public Activator() {
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    /**
+     * Returns the shared instance
+     *
+     * @return the shared instance
+     */
+    public static Activator getDefault() {
+        return plugin;
+    }
+
+    // ------------------------------------------------------------------------
+    // Operators
+    // ------------------------------------------------------------------------
+
+    @Override
+    public void start(BundleContext context) throws Exception {
+        super.start(context);
+        plugin = this;
+    }
+
+    @Override
+    public void stop(BundleContext context) throws Exception {
+        plugin = null;
+        super.stop(context);
+    }
+
+    /**
+     * Logs a message with severity INFO in the runtime log of the plug-in.
+     *
+     * @param message A message to log
+     */
+    public void logInfo(String message) {
+        getLog().log(new Status(IStatus.INFO, PLUGIN_ID, message));
+    }
+
+    /**
+     * Logs a message and exception with severity INFO in the runtime log of the plug-in.
+     *
+     * @param message A message to log
+     * @param exception A exception to log
+     */
+    public void logInfo(String message, Throwable exception) {
+        getLog().log(new Status(IStatus.INFO, PLUGIN_ID, message, exception));
+    }
+
+    /**
+     * Logs a message and exception with severity WARNING in the runtime log of the plug-in.
+     *
+     * @param message A message to log
+     */
+    public void logWarning(String message) {
+        getLog().log(new Status(IStatus.WARNING, PLUGIN_ID, message));
+    }
+
+    /**
+     * Logs a message and exception with severity WARNING in the runtime log of the plug-in.
+     *
+     * @param message A message to log
+     * @param exception A exception to log
+     */
+    public void logWarning(String message, Throwable exception) {
+        getLog().log(new Status(IStatus.WARNING, PLUGIN_ID, message, exception));
+    }
+
+    /**
+     * Logs a message and exception with severity ERROR in the runtime log of the plug-in.
+     *
+     * @param message A message to log
+     */
+    public void logError(String message) {
+        getLog().log(new Status(IStatus.ERROR, PLUGIN_ID, message));
+    }
+
+    /**
+     * Logs a message and exception with severity ERROR in the runtime log of the plug-in.
+     *
+     * @param message A message to log
+     * @param exception A exception to log
+     */
+    public void logError(String message, Throwable exception) {
+        getLog().log(new Status(IStatus.ERROR, PLUGIN_ID, message, exception));
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/internal/lttng2/ust/core/analysis/memory/UstMemoryStateProvider.java b/lttng/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/internal/lttng2/ust/core/analysis/memory/UstMemoryStateProvider.java
new file mode 100644 (file)
index 0000000..3175711
--- /dev/null
@@ -0,0 +1,204 @@
+/**********************************************************************
+ * Copyright (c) 2014, 2015 Ericsson, École Polytechnique de Montréal
+ *
+ * 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:
+ *   Matthew Khouzam - Initial API and implementation
+ *   Geneviève Bastien - Memory is per thread and only total is kept
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.ust.core.analysis.memory;
+
+import static org.eclipse.tracecompass.common.core.NonNullUtils.checkNotNull;
+
+import java.util.HashMap;
+import java.util.Map;
+
+import org.eclipse.jdt.annotation.NonNull;
+import org.eclipse.tracecompass.lttng2.ust.core.trace.LttngUstTrace;
+import org.eclipse.tracecompass.statesystem.core.ITmfStateSystemBuilder;
+import org.eclipse.tracecompass.statesystem.core.exceptions.AttributeNotFoundException;
+import org.eclipse.tracecompass.statesystem.core.exceptions.StateValueTypeException;
+import org.eclipse.tracecompass.statesystem.core.exceptions.TimeRangeException;
+import org.eclipse.tracecompass.statesystem.core.statevalue.ITmfStateValue;
+import org.eclipse.tracecompass.statesystem.core.statevalue.TmfStateValue;
+import org.eclipse.tracecompass.tmf.core.event.ITmfEvent;
+import org.eclipse.tracecompass.tmf.core.event.ITmfEventField;
+import org.eclipse.tracecompass.tmf.core.statesystem.AbstractTmfStateProvider;
+import org.eclipse.tracecompass.tmf.core.statesystem.ITmfStateProvider;
+
+/**
+ * State provider to track the memory of the threads using the UST libc wrapper
+ * memory events.
+ *
+ * @author Matthew Khouzam
+ * @author Geneviève Bastien
+ */
+public class UstMemoryStateProvider extends AbstractTmfStateProvider {
+
+    /* Version of this state provider */
+    private static final int VERSION = 1;
+
+    /* Maps a pointer to a memory zone to the size of the memory */
+    private final Map<Long, Long> fMemory = new HashMap<>();
+
+    private static final Long MINUS_ONE = Long.valueOf(-1);
+    private static final Long ZERO = Long.valueOf(0);
+    private static final String EMPTY_STRING = ""; //$NON-NLS-1$
+
+    /**
+     * Constructor
+     *
+     * @param trace
+     *            trace
+     */
+    public UstMemoryStateProvider(@NonNull LttngUstTrace trace) {
+        super(trace, "Ust:Memory"); //$NON-NLS-1$
+    }
+
+    @Override
+    protected void eventHandle(ITmfEvent event) {
+        String name = event.getName();
+        switch (name) {
+        case UstMemoryStrings.MALLOC: {
+            Long ptr = (Long) event.getContent().getField(UstMemoryStrings.FIELD_PTR).getValue();
+            if (ZERO.equals(ptr)) {
+                return;
+            }
+            Long size = (Long) event.getContent().getField(UstMemoryStrings.FIELD_SIZE).getValue();
+            setMem(event, ptr, size);
+        }
+            break;
+        case UstMemoryStrings.FREE: {
+            Long ptr = (Long) event.getContent().getField(UstMemoryStrings.FIELD_PTR).getValue();
+            if (ZERO.equals(ptr)) {
+                return;
+            }
+            setMem(event, ptr, ZERO);
+        }
+            break;
+        case UstMemoryStrings.CALLOC: {
+            Long ptr = (Long) event.getContent().getField(UstMemoryStrings.FIELD_PTR).getValue();
+            if (ZERO.equals(ptr)) {
+                return;
+            }
+            Long nmemb = (Long) event.getContent().getField(UstMemoryStrings.FIELD_NMEMB).getValue();
+            Long size = (Long) event.getContent().getField(UstMemoryStrings.FIELD_SIZE).getValue();
+            setMem(event, ptr, size * nmemb);
+        }
+            break;
+        case UstMemoryStrings.REALLOC: {
+            Long ptr = (Long) event.getContent().getField(UstMemoryStrings.FIELD_PTR).getValue();
+            if (ZERO.equals(ptr)) {
+                return;
+            }
+            Long newPtr = (Long) event.getContent().getField(UstMemoryStrings.FIELD_INPTR).getValue();
+            Long size = (Long) event.getContent().getField(UstMemoryStrings.FIELD_SIZE).getValue();
+            setMem(event, ptr, ZERO);
+            setMem(event, newPtr, size);
+        }
+            break;
+        case UstMemoryStrings.MEMALIGN: {
+            Long ptr = (Long) event.getContent().getField(UstMemoryStrings.FIELD_PTR).getValue();
+            if (ZERO.equals(ptr)) {
+                return;
+            }
+            Long size = (Long) event.getContent().getField(UstMemoryStrings.FIELD_SIZE).getValue();
+            setMem(event, ptr, size);
+        }
+            break;
+        case UstMemoryStrings.POSIX_MEMALIGN: {
+            Long ptr = (Long) event.getContent().getField(UstMemoryStrings.FIELD_OUTPTR).getValue();
+            if (ZERO.equals(ptr)) {
+                return;
+            }
+            Long size = (Long) event.getContent().getField(UstMemoryStrings.FIELD_SIZE).getValue();
+            setMem(event, ptr, size);
+        }
+            break;
+        default:
+            break;
+        }
+
+    }
+
+    @Override
+    public ITmfStateProvider getNewInstance() {
+        return new UstMemoryStateProvider(getTrace());
+    }
+
+    @Override
+    public LttngUstTrace getTrace() {
+        return (LttngUstTrace) super.getTrace();
+    }
+
+    @Override
+    public int getVersion() {
+        return VERSION;
+    }
+
+    private static Long getVtid(ITmfEvent event) {
+        ITmfEventField field = event.getContent().getField(UstMemoryStrings.CONTEXT_VTID);
+        if (field == null) {
+            return MINUS_ONE;
+        }
+        return (Long) field.getValue();
+    }
+
+    private static String getProcname(ITmfEvent event) {
+        ITmfEventField field = event.getContent().getField(UstMemoryStrings.CONTEXT_PROCNAME);
+        if (field == null) {
+            return EMPTY_STRING;
+        }
+        return (String) field.getValue();
+    }
+
+    private void setMem(ITmfEvent event, Long ptr, Long size) {
+        ITmfStateSystemBuilder ss = checkNotNull(getStateSystemBuilder());
+        long ts = event.getTimestamp().getValue();
+        Long tid = getVtid(event);
+
+        Long memoryDiff = size;
+        /* Size is 0, it means it was deleted */
+        if (ZERO.equals(size)) {
+            Long memSize = fMemory.remove(ptr);
+            if (memSize == null) {
+                return;
+            }
+            memoryDiff = -memSize;
+        } else {
+            fMemory.put(ptr, size);
+        }
+        try {
+            int tidQuark = ss.getQuarkAbsoluteAndAdd(tid.toString());
+            int tidMemQuark = ss.getQuarkRelativeAndAdd(tidQuark, UstMemoryStrings.UST_MEMORY_MEMORY_ATTRIBUTE);
+
+            ITmfStateValue prevMem = ss.queryOngoingState(tidMemQuark);
+            /* First time we set this value */
+            if (prevMem.isNull()) {
+                int procNameQuark = ss.getQuarkRelativeAndAdd(tidQuark, UstMemoryStrings.UST_MEMORY_PROCNAME_ATTRIBUTE);
+                String procName = getProcname(event);
+                /*
+                 * No tid/procname for the event for the event, added to a
+                 * 'others' thread
+                 */
+                if (tid.equals(MINUS_ONE)) {
+                    procName = UstMemoryStrings.OTHERS;
+                }
+                ss.modifyAttribute(ts, TmfStateValue.newValueString(procName), procNameQuark);
+                prevMem = TmfStateValue.newValueLong(0);
+            }
+
+            long prevMemValue = prevMem.unboxLong();
+            prevMemValue += memoryDiff.longValue();
+            ss.modifyAttribute(ts, TmfStateValue.newValueLong(prevMemValue), tidMemQuark);
+        } catch (AttributeNotFoundException | TimeRangeException | StateValueTypeException e) {
+            throw new IllegalStateException(e);
+        }
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/internal/lttng2/ust/core/analysis/memory/UstMemoryStrings.java b/lttng/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/internal/lttng2/ust/core/analysis/memory/UstMemoryStrings.java
new file mode 100644 (file)
index 0000000..b573a3f
--- /dev/null
@@ -0,0 +1,51 @@
+/*******************************************************************************
+ * Copyright (c) 2014 Ericsson, École Polytechnique de Montréal
+ *
+ * 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:
+ *   Matthew Khouzam, Geneviève Bastien - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.ust.core.analysis.memory;
+
+/**
+ * Strings for the memory usage state system using the LTTng UST libc
+ * instrumentation
+ *
+ * @author Matthew Khouzam
+ * @author Geneviève Bastien
+ */
+@SuppressWarnings({ "nls", "javadoc" })
+public interface UstMemoryStrings {
+
+    /** Memory state system attribute name */
+    static final String UST_MEMORY_MEMORY_ATTRIBUTE = "Memory"; //$NON-NLS-1$
+    /** Procname state system attribute name */
+    static final String UST_MEMORY_PROCNAME_ATTRIBUTE = "Procname"; //$NON-NLS-1$
+    /** Name of the attribute to store memory usage of events with no context */
+    static final String OTHERS = "Others";
+
+    /* UST_libc event names */
+    static final String MALLOC = "ust_libc:malloc";
+    static final String CALLOC = "ust_libc:calloc";
+    static final String REALLOC = "ust_libc:realloc";
+    static final String FREE = "ust_libc:free";
+    static final String MEMALIGN = "ust_libc:memalign";
+    static final String POSIX_MEMALIGN = "ust_libc:posix_memalign";
+
+    /* Possible contexts */
+    static final String CONTEXT_VTID = "context._vtid";
+    static final String CONTEXT_PROCNAME = "context._procname";
+
+    /* Event fields */
+    static final String FIELD_PTR = "ptr";
+    static final String FIELD_NMEMB = "nmemb";
+    static final String FIELD_SIZE = "size";
+    static final String FIELD_OUTPTR = "out_ptr";
+    static final String FIELD_INPTR = "in_ptr";
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/internal/lttng2/ust/core/callstack/LttngUstCallStackProvider.java b/lttng/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/internal/lttng2/ust/core/callstack/LttngUstCallStackProvider.java
new file mode 100644 (file)
index 0000000..6d14911
--- /dev/null
@@ -0,0 +1,172 @@
+/*******************************************************************************
+ * Copyright (c) 2013, 2015 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:
+ *   Alexandre Montplaisir - Initial API and implementation
+ *   Patrick Tasse - Add support for thread id
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.ust.core.callstack;
+
+import java.util.HashSet;
+import java.util.Set;
+
+import org.eclipse.jdt.annotation.NonNull;
+import org.eclipse.tracecompass.tmf.core.callstack.CallStackStateProvider;
+import org.eclipse.tracecompass.tmf.core.event.ITmfEvent;
+import org.eclipse.tracecompass.tmf.core.event.ITmfEventField;
+import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace;
+import org.eclipse.tracecompass.tmf.ctf.core.event.CtfTmfEvent;
+
+/**
+ * Callstack provider for LTTng-UST traces.
+ *
+ * If the traces contains 'func_entry' and 'func_exit' event (see the
+ * lttng-ust-cyg-profile manpage), AND contains vtid and procname contexts, we
+ * can use this information to populate the TMF Callstack View.
+ *
+ * Granted, most UST traces will not contain this information. In this case,
+ * this will simply build an empty state system, and the view will remain
+ * unavailable.
+ *
+ * @author Alexandre Montplaisir
+ */
+public class LttngUstCallStackProvider extends CallStackStateProvider {
+
+    // ------------------------------------------------------------------------
+    // Event strings
+    // ------------------------------------------------------------------------
+
+    /** Name of the fake field for the vtid contexts */
+    private static final String CONTEXT_VTID = "context._vtid"; //$NON-NLS-1$
+
+    /** Name of the fake field for the procname context */
+    private static final String CONTEXT_PROCNAME = "context._procname"; //$NON-NLS-1$
+
+    /** Field name for the target function address */
+    private static final String FIELD_ADDR = "addr"; //$NON-NLS-1$
+
+    /** Event names indicating function entry */
+    private static final Set<String> FUNC_ENTRY_EVENTS = new HashSet<>();
+
+    /** Event names indicating function exit */
+    private static final Set<String> FUNC_EXIT_EVENTS = new HashSet<>();
+
+    static {
+        /* This seems overkill, but it will be checked every event. Gotta go FAST! */
+        FUNC_ENTRY_EVENTS.add("lttng_ust_cyg_profile:func_entry"); //$NON-NLS-1$
+        FUNC_ENTRY_EVENTS.add("lttng_ust_cyg_profile_fast:func_entry"); //$NON-NLS-1$
+
+        FUNC_EXIT_EVENTS.add("lttng_ust_cyg_profile:func_exit"); //$NON-NLS-1$
+        FUNC_EXIT_EVENTS.add("lttng_ust_cyg_profile_fast:func_exit"); //$NON-NLS-1$
+    }
+
+    /**
+     * Version number of this state provider. Please bump this if you modify
+     * the contents of the generated state history in some way.
+     */
+    private static final int VERSION = 2;
+
+    // ------------------------------------------------------------------------
+    // Constructor
+    // ------------------------------------------------------------------------
+
+    /**
+     * Constructor
+     *
+     * @param trace
+     *            The UST trace
+     */
+    public LttngUstCallStackProvider(@NonNull ITmfTrace trace) {
+        super(trace);
+    }
+
+    // ------------------------------------------------------------------------
+    // Methods from AbstractTmfStateProvider
+    // ------------------------------------------------------------------------
+
+    @Override
+    public LttngUstCallStackProvider getNewInstance() {
+        return new LttngUstCallStackProvider(getTrace());
+    }
+
+    @Override
+    public int getVersion() {
+        return VERSION;
+    }
+
+    // ------------------------------------------------------------------------
+    // Methods from CallStackStateProvider
+    // ------------------------------------------------------------------------
+
+    /**
+     * Check that this event contains the required information we need to be
+     * used in the call stack view. We need at least the "procname" and "vtid"
+     * contexts.
+     */
+    @Override
+    protected boolean considerEvent(ITmfEvent event) {
+        if (!(event instanceof CtfTmfEvent)) {
+            return false;
+        }
+        ITmfEventField content = ((CtfTmfEvent) event).getContent();
+        if (content.getField(CONTEXT_VTID) == null ||
+                content.getField(CONTEXT_PROCNAME) == null) {
+            return false;
+        }
+        return true;
+    }
+
+    @Override
+    public String functionEntry(ITmfEvent event) {
+        String eventName = event.getName();
+        if (!FUNC_ENTRY_EVENTS.contains(eventName)) {
+            return null;
+        }
+        Long address = (Long) event.getContent().getField(FIELD_ADDR).getValue();
+        return Long.toHexString(address);
+    }
+
+    @Override
+    public String functionExit(ITmfEvent event) {
+        String eventName = event.getName();
+        if (!FUNC_EXIT_EVENTS.contains(eventName)) {
+            return null;
+        }
+        /*
+         * The 'addr' field may or may not be present in func_exit events,
+         * depending on if cyg-profile.so or cyg-profile-fast.so was used.
+         */
+        ITmfEventField field = event.getContent().getField(FIELD_ADDR);
+        if (field == null) {
+            return CallStackStateProvider.UNDEFINED;
+        }
+        Long address = (Long) field.getValue();
+        return Long.toHexString(address);
+    }
+
+    @Override
+    public String getThreadName(ITmfEvent event) {
+        /* Class type and content was already checked if we get called here */
+        ITmfEventField content = ((CtfTmfEvent) event).getContent();
+        String procName = (String) content.getField(CONTEXT_PROCNAME).getValue();
+        Long vtid = (Long) content.getField(CONTEXT_VTID).getValue();
+
+        if (procName == null || vtid == null) {
+            throw new IllegalStateException();
+        }
+
+        return new String(procName + '-' + vtid.toString());
+    }
+
+    @Override
+    protected Long getThreadId(ITmfEvent event) {
+        ITmfEventField content = ((CtfTmfEvent) event).getContent();
+        return (Long) content.getField(CONTEXT_VTID).getValue();
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/lttng2/ust/core/analysis/memory/Messages.java b/lttng/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/lttng2/ust/core/analysis/memory/Messages.java
new file mode 100644 (file)
index 0000000..41cdf3c
--- /dev/null
@@ -0,0 +1,37 @@
+/*******************************************************************************
+ * Copyright (c) 2014 École Polytechnique de Montréal
+ *
+ * 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:
+ *   Guilliano Molaire - Initial API and implementation
+ *******************************************************************************/
+package org.eclipse.tracecompass.lttng2.ust.core.analysis.memory;
+
+import org.eclipse.osgi.util.NLS;
+
+/**
+ * Message bundle for the ust memory analysis module
+ *
+ * @author Guilliano Molaire
+ */
+public class Messages extends NLS {
+    private static final String BUNDLE_NAME = "org.eclipse.tracecompass.lttng2.ust.core.analysis.memory.messages"; //$NON-NLS-1$
+
+    /** Information regarding events loading prior to the analysis execution */
+    public static String UstMemoryAnalysisModule_EventsLoadingInformation;
+
+    /** Example of how to execute the application with the libc wrapper */
+    public static String UstMemoryAnalysisModule_EventsLoadingExampleInformation;
+
+    static {
+        // initialize resource bundle
+        NLS.initializeMessages(BUNDLE_NAME, Messages.class);
+    }
+
+    private Messages() {
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/lttng2/ust/core/analysis/memory/UstMemoryAnalysisModule.java b/lttng/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/lttng2/ust/core/analysis/memory/UstMemoryAnalysisModule.java
new file mode 100644 (file)
index 0000000..43bea13
--- /dev/null
@@ -0,0 +1,101 @@
+/*******************************************************************************
+ * Copyright (c) 2014, 2015 École Polytechnique de Montréal
+ *
+ * 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:
+ *   Geneviève Bastien - Initial API and implementation
+ *   Guilliano Molaire - Provide the requirements of the analysis
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.ust.core.analysis.memory;
+
+import static org.eclipse.tracecompass.common.core.NonNullUtils.checkNotNull;
+
+import java.util.Set;
+
+import org.eclipse.jdt.annotation.NonNull;
+import org.eclipse.tracecompass.internal.lttng2.ust.core.analysis.memory.UstMemoryStateProvider;
+import org.eclipse.tracecompass.internal.lttng2.ust.core.analysis.memory.UstMemoryStrings;
+import org.eclipse.tracecompass.lttng2.control.core.session.SessionConfigStrings;
+import org.eclipse.tracecompass.lttng2.ust.core.trace.LttngUstTrace;
+import org.eclipse.tracecompass.tmf.core.analysis.TmfAnalysisRequirement;
+import org.eclipse.tracecompass.tmf.core.analysis.TmfAnalysisRequirement.ValuePriorityLevel;
+import org.eclipse.tracecompass.tmf.core.exceptions.TmfAnalysisException;
+import org.eclipse.tracecompass.tmf.core.statesystem.ITmfStateProvider;
+import org.eclipse.tracecompass.tmf.core.statesystem.TmfStateSystemAnalysisModule;
+import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace;
+
+import com.google.common.collect.ImmutableSet;
+
+/**
+ * This analysis build a state system from the libc memory instrumentation on a
+ * UST trace
+ *
+ * @author Geneviève Bastien
+ */
+public class UstMemoryAnalysisModule extends TmfStateSystemAnalysisModule {
+
+    /**
+     * Analysis ID, it should match that in the plugin.xml file
+     */
+    public static final @NonNull String ID = "org.eclipse.linuxtools.lttng2.ust.analysis.memory"; //$NON-NLS-1$
+
+    private static final ImmutableSet<String> REQUIRED_EVENTS = ImmutableSet.of(
+            UstMemoryStrings.MALLOC,
+            UstMemoryStrings.FREE,
+            UstMemoryStrings.CALLOC,
+            UstMemoryStrings.REALLOC,
+            UstMemoryStrings.MEMALIGN,
+            UstMemoryStrings.POSIX_MEMALIGN
+            );
+
+    /** The requirements as an immutable set */
+    private static final @NonNull Set<TmfAnalysisRequirement> REQUIREMENTS;
+
+    static {
+        /* Initialize the requirements for the analysis: domain and events */
+        TmfAnalysisRequirement eventsReq = new TmfAnalysisRequirement(SessionConfigStrings.CONFIG_ELEMENT_EVENT, REQUIRED_EVENTS, ValuePriorityLevel.MANDATORY);
+        /*
+         * In order to have these events, the libc wrapper with probes should be
+         * loaded
+         */
+        eventsReq.addInformation(Messages.UstMemoryAnalysisModule_EventsLoadingInformation);
+        eventsReq.addInformation(Messages.UstMemoryAnalysisModule_EventsLoadingExampleInformation);
+
+        /* The domain type of the analysis */
+        TmfAnalysisRequirement domainReq = new TmfAnalysisRequirement(SessionConfigStrings.CONFIG_ELEMENT_DOMAIN);
+        domainReq.addValue(SessionConfigStrings.CONFIG_DOMAIN_TYPE_UST, ValuePriorityLevel.MANDATORY);
+
+        REQUIREMENTS = checkNotNull(ImmutableSet.of(domainReq, eventsReq));
+    }
+
+    @Override
+    protected ITmfStateProvider createStateProvider() {
+        return new UstMemoryStateProvider(checkNotNull(getTrace()));
+    }
+
+    /**
+     * @since 1.0
+     */
+    @Override
+    public boolean setTrace(ITmfTrace trace) throws TmfAnalysisException {
+        if (!(trace instanceof LttngUstTrace)) {
+            return false;
+        }
+        return super.setTrace(trace);
+    }
+
+    @Override
+    protected LttngUstTrace getTrace() {
+        return (LttngUstTrace) super.getTrace();
+    }
+
+    @Override
+    public Iterable<TmfAnalysisRequirement> getAnalysisRequirements() {
+        return REQUIREMENTS;
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/lttng2/ust/core/analysis/memory/messages.properties b/lttng/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/lttng2/ust/core/analysis/memory/messages.properties
new file mode 100644 (file)
index 0000000..e271aaa
--- /dev/null
@@ -0,0 +1,13 @@
+###############################################################################
+# Copyright (c) 2015 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:
+#     Ericsson - Initial API and implementation
+###############################################################################
+UstMemoryAnalysisModule_EventsLoadingInformation=The libc wrapper should be loaded in order to get the events in the trace output.
+UstMemoryAnalysisModule_EventsLoadingExampleInformation=Start the application to trace with: LD_PRELOAD=/path/to/liblttng-ust-libc-wrapper.so ./myProgram.
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/lttng2/ust/core/trace/LttngUstTrace.java b/lttng/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/lttng2/ust/core/trace/LttngUstTrace.java
new file mode 100644 (file)
index 0000000..fd56bf0
--- /dev/null
@@ -0,0 +1,63 @@
+/**********************************************************************
+ * Copyright (c) 2013, 2014 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:
+ *   Matthew Khouzam - Initial API and implementation
+ *   Alexandre Montplaisir - Add UST callstack state system
+ *   Marc-Andre Laperle - Handle BufferOverflowException (Bug 420203)
+ **********************************************************************/
+
+package org.eclipse.tracecompass.lttng2.ust.core.trace;
+
+import java.util.Map;
+
+import org.eclipse.core.resources.IProject;
+import org.eclipse.core.runtime.IStatus;
+import org.eclipse.core.runtime.Status;
+import org.eclipse.tracecompass.internal.lttng2.ust.core.Activator;
+import org.eclipse.tracecompass.tmf.core.trace.TraceValidationStatus;
+import org.eclipse.tracecompass.tmf.ctf.core.trace.CtfTmfTrace;
+import org.eclipse.tracecompass.tmf.ctf.core.trace.CtfTraceValidationStatus;
+
+/**
+ * Class to contain LTTng-UST traces
+ *
+ * @author Matthew Khouzam
+ */
+public class LttngUstTrace extends CtfTmfTrace {
+
+    private static final int CONFIDENCE = 100;
+
+    /**
+     * Default constructor
+     */
+    public LttngUstTrace() {
+        super();
+    }
+
+    /**
+     * {@inheritDoc}
+     * <p>
+     * This implementation sets the confidence to 100 if the trace is a valid
+     * CTF trace in the "ust" domain.
+     */
+    @Override
+    public IStatus validate(final IProject project, final String path) {
+        IStatus status = super.validate(project, path);
+        if (status instanceof CtfTraceValidationStatus) {
+            Map<String, String> environment = ((CtfTraceValidationStatus) status).getEnvironment();
+            /* Make sure the domain is "ust" in the trace's env vars */
+            String domain = environment.get("domain"); //$NON-NLS-1$
+            if (domain == null || !domain.equals("\"ust\"")) { //$NON-NLS-1$
+                return new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.LttngUstTrace_DomainError);
+            }
+            return new TraceValidationStatus(CONFIDENCE, Activator.PLUGIN_ID);
+        }
+        return status;
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/lttng2/ust/core/trace/Messages.java b/lttng/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/lttng2/ust/core/trace/Messages.java
new file mode 100644 (file)
index 0000000..a2e3ea5
--- /dev/null
@@ -0,0 +1,47 @@
+/*******************************************************************************
+ * Copyright (c) 2013, 2014 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:
+ *     Matthew Khouzam - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.ust.core.trace;
+
+import org.eclipse.osgi.util.NLS;
+
+/**
+ * Message bundle for lttng2.kernel.core.trace
+ *
+ * @author Matthew Khouzam
+ */
+public class Messages extends NLS {
+
+    private static final String BUNDLE_NAME = "org.eclipse.tracecompass.lttng2.ust.core.trace.messages"; //$NON-NLS-1$
+
+    /**
+     * The domain is not "ust"
+     */
+    public static String LttngUstTrace_DomainError;
+
+    /**
+     * Malformed trace (buffer overflow maybe?)
+     */
+    public static String LttngUstTrace_MalformedTrace;
+
+    /**
+     * Trace read error
+     */
+    public static String LttngUstTrace_TraceReadError;
+
+    static {
+        // initialize resource bundle
+        NLS.initializeMessages(BUNDLE_NAME, Messages.class);
+    }
+
+    private Messages() {
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/lttng2/ust/core/trace/messages.properties b/lttng/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/lttng2/ust/core/trace/messages.properties
new file mode 100644 (file)
index 0000000..1d44d7d
--- /dev/null
@@ -0,0 +1,15 @@
+###############################################################################
+# Copyright (c) 2013, 2014 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:
+#     Ericsson - Initial API and implementation
+###############################################################################
+
+LttngUstTrace_DomainError=Domain mismatch, the environment should be 'ust'.
+LttngUstTrace_MalformedTrace=Buffer overflow exception, trace is malformed
+LttngUstTrace_TraceReadError=Lttng UST trace read error
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.ui.tests/.classpath b/lttng/org.eclipse.tracecompass.lttng2.ust.ui.tests/.classpath
new file mode 100644 (file)
index 0000000..098194c
--- /dev/null
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+       <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7"/>
+       <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
+       <classpathentry kind="src" path="src"/>
+       <classpathentry kind="output" path="bin"/>
+</classpath>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.ui.tests/.project b/lttng/org.eclipse.tracecompass.lttng2.ust.ui.tests/.project
new file mode 100644 (file)
index 0000000..bbd5f4d
--- /dev/null
@@ -0,0 +1,34 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+       <name>org.eclipse.tracecompass.lttng2.ust.ui.tests</name>
+       <comment></comment>
+       <projects>
+       </projects>
+       <buildSpec>
+               <buildCommand>
+                       <name>org.eclipse.jdt.core.javabuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+               <buildCommand>
+                       <name>org.eclipse.pde.ManifestBuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+               <buildCommand>
+                       <name>org.eclipse.pde.SchemaBuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+               <buildCommand>
+                       <name>org.eclipse.pde.api.tools.apiAnalysisBuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+       </buildSpec>
+       <natures>
+               <nature>org.eclipse.pde.PluginNature</nature>
+               <nature>org.eclipse.jdt.core.javanature</nature>
+               <nature>org.eclipse.pde.api.tools.apiAnalysisNature</nature>
+       </natures>
+</projectDescription>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.ui.tests/.settings/org.eclipse.core.resources.prefs b/lttng/org.eclipse.tracecompass.lttng2.ust.ui.tests/.settings/org.eclipse.core.resources.prefs
new file mode 100644 (file)
index 0000000..99f26c0
--- /dev/null
@@ -0,0 +1,2 @@
+eclipse.preferences.version=1
+encoding/<project>=UTF-8
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.ui.tests/.settings/org.eclipse.core.runtime.prefs b/lttng/org.eclipse.tracecompass.lttng2.ust.ui.tests/.settings/org.eclipse.core.runtime.prefs
new file mode 100644 (file)
index 0000000..5a0ad22
--- /dev/null
@@ -0,0 +1,2 @@
+eclipse.preferences.version=1
+line.separator=\n
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.ui.tests/.settings/org.eclipse.jdt.core.prefs b/lttng/org.eclipse.tracecompass.lttng2.ust.ui.tests/.settings/org.eclipse.jdt.core.prefs
new file mode 100644 (file)
index 0000000..0409c61
--- /dev/null
@@ -0,0 +1,403 @@
+eclipse.preferences.version=1
+org.eclipse.jdt.core.codeComplete.argumentPrefixes=
+org.eclipse.jdt.core.codeComplete.argumentSuffixes=
+org.eclipse.jdt.core.codeComplete.fieldPrefixes=f
+org.eclipse.jdt.core.codeComplete.fieldSuffixes=
+org.eclipse.jdt.core.codeComplete.localPrefixes=
+org.eclipse.jdt.core.codeComplete.localSuffixes=
+org.eclipse.jdt.core.codeComplete.staticFieldPrefixes=
+org.eclipse.jdt.core.codeComplete.staticFieldSuffixes=
+org.eclipse.jdt.core.codeComplete.staticFinalFieldPrefixes=
+org.eclipse.jdt.core.codeComplete.staticFinalFieldSuffixes=
+org.eclipse.jdt.core.compiler.annotation.inheritNullAnnotations=enabled
+org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore
+org.eclipse.jdt.core.compiler.annotation.nonnull=org.eclipse.jdt.annotation.NonNull
+org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=org.eclipse.jdt.annotation.NonNullByDefault
+org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nullable
+org.eclipse.jdt.core.compiler.annotation.nullanalysis=enabled
+org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
+org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
+org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
+org.eclipse.jdt.core.compiler.compliance=1.7
+org.eclipse.jdt.core.compiler.debug.lineNumber=generate
+org.eclipse.jdt.core.compiler.debug.localVariable=generate
+org.eclipse.jdt.core.compiler.debug.sourceFile=generate
+org.eclipse.jdt.core.compiler.doc.comment.support=enabled
+org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=error
+org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
+org.eclipse.jdt.core.compiler.problem.autoboxing=ignore
+org.eclipse.jdt.core.compiler.problem.comparingIdentical=error
+org.eclipse.jdt.core.compiler.problem.deadCode=error
+org.eclipse.jdt.core.compiler.problem.deprecation=error
+org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled
+org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=enabled
+org.eclipse.jdt.core.compiler.problem.discouragedReference=error
+org.eclipse.jdt.core.compiler.problem.emptyStatement=error
+org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
+org.eclipse.jdt.core.compiler.problem.explicitlyClosedAutoCloseable=error
+org.eclipse.jdt.core.compiler.problem.fallthroughCase=error
+org.eclipse.jdt.core.compiler.problem.fatalOptionalError=disabled
+org.eclipse.jdt.core.compiler.problem.fieldHiding=error
+org.eclipse.jdt.core.compiler.problem.finalParameterBound=error
+org.eclipse.jdt.core.compiler.problem.finallyBlockNotCompletingNormally=error
+org.eclipse.jdt.core.compiler.problem.forbiddenReference=error
+org.eclipse.jdt.core.compiler.problem.hiddenCatchBlock=error
+org.eclipse.jdt.core.compiler.problem.includeNullInfoFromAsserts=disabled
+org.eclipse.jdt.core.compiler.problem.incompatibleNonInheritedInterfaceMethod=error
+org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch=error
+org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=error
+org.eclipse.jdt.core.compiler.problem.invalidJavadoc=warning
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTags=enabled
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsDeprecatedRef=enabled
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsNotVisibleRef=enabled
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsVisibility=protected
+org.eclipse.jdt.core.compiler.problem.localVariableHiding=error
+org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=error
+org.eclipse.jdt.core.compiler.problem.missingDefaultCase=error
+org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=error
+org.eclipse.jdt.core.compiler.problem.missingEnumCaseDespiteDefault=enabled
+org.eclipse.jdt.core.compiler.problem.missingHashCodeMethod=error
+org.eclipse.jdt.core.compiler.problem.missingJavadocComments=warning
+org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsOverriding=disabled
+org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsVisibility=protected
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagDescription=all_standard_tags
+org.eclipse.jdt.core.compiler.problem.missingJavadocTags=warning
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagsMethodTypeParameters=disabled
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagsOverriding=disabled
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagsVisibility=protected
+org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotation=error
+org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotationForInterfaceMethodImplementation=enabled
+org.eclipse.jdt.core.compiler.problem.missingSerialVersion=error
+org.eclipse.jdt.core.compiler.problem.missingSynchronizedOnInheritedMethod=error
+org.eclipse.jdt.core.compiler.problem.noEffectAssignment=error
+org.eclipse.jdt.core.compiler.problem.noImplicitStringConversion=error
+org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=ignore
+org.eclipse.jdt.core.compiler.problem.nonnullParameterAnnotationDropped=warning
+org.eclipse.jdt.core.compiler.problem.nullAnnotationInferenceConflict=warning
+org.eclipse.jdt.core.compiler.problem.nullReference=error
+org.eclipse.jdt.core.compiler.problem.nullSpecViolation=error
+org.eclipse.jdt.core.compiler.problem.nullUncheckedConversion=warning
+org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=error
+org.eclipse.jdt.core.compiler.problem.parameterAssignment=error
+org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=error
+org.eclipse.jdt.core.compiler.problem.potentialNullReference=error
+org.eclipse.jdt.core.compiler.problem.potentiallyUnclosedCloseable=warning
+org.eclipse.jdt.core.compiler.problem.rawTypeReference=error
+org.eclipse.jdt.core.compiler.problem.redundantNullAnnotation=warning
+org.eclipse.jdt.core.compiler.problem.redundantNullCheck=error
+org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=error
+org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=error
+org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore
+org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=error
+org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled
+org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=error
+org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=disabled
+org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled
+org.eclipse.jdt.core.compiler.problem.syntacticNullAnalysisForFields=enabled
+org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=ignore
+org.eclipse.jdt.core.compiler.problem.typeParameterHiding=error
+org.eclipse.jdt.core.compiler.problem.unavoidableGenericTypeProblems=disabled
+org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=error
+org.eclipse.jdt.core.compiler.problem.unclosedCloseable=error
+org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=ignore
+org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=error
+org.eclipse.jdt.core.compiler.problem.unnecessaryElse=error
+org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=error
+org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=error
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionExemptExceptionAndThrowable=disabled
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionIncludeDocCommentReference=disabled
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverriding=disabled
+org.eclipse.jdt.core.compiler.problem.unusedImport=error
+org.eclipse.jdt.core.compiler.problem.unusedLabel=error
+org.eclipse.jdt.core.compiler.problem.unusedLocal=error
+org.eclipse.jdt.core.compiler.problem.unusedObjectAllocation=ignore
+org.eclipse.jdt.core.compiler.problem.unusedParameter=ignore
+org.eclipse.jdt.core.compiler.problem.unusedParameterIncludeDocCommentReference=enabled
+org.eclipse.jdt.core.compiler.problem.unusedParameterWhenImplementingAbstract=disabled
+org.eclipse.jdt.core.compiler.problem.unusedParameterWhenOverridingConcrete=disabled
+org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=error
+org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=ignore
+org.eclipse.jdt.core.compiler.problem.unusedWarningToken=error
+org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=error
+org.eclipse.jdt.core.compiler.source=1.7
+org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=16
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_call=16
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation=16
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression=16
+org.eclipse.jdt.core.formatter.alignment_for_assignment=0
+org.eclipse.jdt.core.formatter.alignment_for_binary_expression=16
+org.eclipse.jdt.core.formatter.alignment_for_compact_if=16
+org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=80
+org.eclipse.jdt.core.formatter.alignment_for_enum_constants=0
+org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=16
+org.eclipse.jdt.core.formatter.alignment_for_method_declaration=0
+org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16
+org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=80
+org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation=0
+org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_constructor_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_method_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_union_type_in_multicatch=16
+org.eclipse.jdt.core.formatter.blank_lines_after_imports=1
+org.eclipse.jdt.core.formatter.blank_lines_after_package=1
+org.eclipse.jdt.core.formatter.blank_lines_before_field=0
+org.eclipse.jdt.core.formatter.blank_lines_before_first_class_body_declaration=0
+org.eclipse.jdt.core.formatter.blank_lines_before_imports=1
+org.eclipse.jdt.core.formatter.blank_lines_before_member_type=1
+org.eclipse.jdt.core.formatter.blank_lines_before_method=1
+org.eclipse.jdt.core.formatter.blank_lines_before_new_chunk=1
+org.eclipse.jdt.core.formatter.blank_lines_before_package=0
+org.eclipse.jdt.core.formatter.blank_lines_between_import_groups=1
+org.eclipse.jdt.core.formatter.blank_lines_between_type_declarations=1
+org.eclipse.jdt.core.formatter.brace_position_for_annotation_type_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_array_initializer=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_block=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_block_in_case=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_constructor_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_enum_constant=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_enum_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_method_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_switch=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_type_declaration=end_of_line
+org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_block_comment=false
+org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_javadoc_comment=false
+org.eclipse.jdt.core.formatter.comment.format_block_comments=true
+org.eclipse.jdt.core.formatter.comment.format_header=false
+org.eclipse.jdt.core.formatter.comment.format_html=true
+org.eclipse.jdt.core.formatter.comment.format_javadoc_comments=true
+org.eclipse.jdt.core.formatter.comment.format_line_comments=true
+org.eclipse.jdt.core.formatter.comment.format_source_code=true
+org.eclipse.jdt.core.formatter.comment.indent_parameter_description=true
+org.eclipse.jdt.core.formatter.comment.indent_root_tags=true
+org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags=insert
+org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter=insert
+org.eclipse.jdt.core.formatter.comment.line_length=80
+org.eclipse.jdt.core.formatter.comment.new_lines_at_block_boundaries=true
+org.eclipse.jdt.core.formatter.comment.new_lines_at_javadoc_boundaries=true
+org.eclipse.jdt.core.formatter.comment.preserve_white_space_between_code_and_line_comments=false
+org.eclipse.jdt.core.formatter.compact_else_if=true
+org.eclipse.jdt.core.formatter.continuation_indentation=2
+org.eclipse.jdt.core.formatter.continuation_indentation_for_array_initializer=2
+org.eclipse.jdt.core.formatter.disabling_tag=@formatter\:off
+org.eclipse.jdt.core.formatter.enabling_tag=@formatter\:on
+org.eclipse.jdt.core.formatter.format_guardian_clause_on_one_line=false
+org.eclipse.jdt.core.formatter.format_line_comment_starting_on_first_column=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_annotation_declaration_header=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_constant_header=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_declaration_header=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_type_header=true
+org.eclipse.jdt.core.formatter.indent_breaks_compare_to_cases=true
+org.eclipse.jdt.core.formatter.indent_empty_lines=false
+org.eclipse.jdt.core.formatter.indent_statements_compare_to_block=true
+org.eclipse.jdt.core.formatter.indent_statements_compare_to_body=true
+org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_cases=true
+org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_switch=false
+org.eclipse.jdt.core.formatter.indentation.size=4
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_field=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_local_variable=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_method=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_package=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_parameter=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_type=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_label=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_opening_brace_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_at_end_of_file_if_missing=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_finally_in_try_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_while_in_do_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_annotation_declaration=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_anonymous_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_block=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter=insert
+org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_binary_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_paren_in_cast=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_assert=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_case=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_labeled_statement=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_allocation_expression=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_annotation=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_throws=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_constant_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_declarations=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_explicitconstructorcall_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_increments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_inits=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_throws=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_invocation_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_field_declarations=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_local_declarations=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_parameterized_type_reference=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_superinterfaces=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_ellipsis=insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_brace_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_cast=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_catch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_for=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_if=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_parenthesized_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_switch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_synchronized=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_try=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_while=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_try_resources=insert
+org.eclipse.jdt.core.formatter.insert_space_after_unary_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter=insert
+org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_binary_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_brace_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_cast=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_catch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_for=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_if=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_parenthesized_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_switch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_synchronized=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_try=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_while=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_assert=insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_case=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_default=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_labeled_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_throws=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_constant_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_declarations=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_explicitconstructorcall_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_increments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_inits=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_throws=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_invocation_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_field_declarations=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_local_declarations=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_superinterfaces=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_ellipsis=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_annotation_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_anonymous_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_block=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_constructor_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_constant=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_method_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_switch=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation_type_member_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_catch=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_if=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_parenthesized_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_switch=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_synchronized=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_try=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_while=insert
+org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_return=insert
+org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_throw=insert
+org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_semicolon=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_try_resources=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_unary_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_brackets_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_annotation_type_member_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.join_lines_in_comments=true
+org.eclipse.jdt.core.formatter.join_wrapped_lines=false
+org.eclipse.jdt.core.formatter.keep_else_statement_on_same_line=false
+org.eclipse.jdt.core.formatter.keep_empty_array_initializer_on_one_line=false
+org.eclipse.jdt.core.formatter.keep_imple_if_on_one_line=false
+org.eclipse.jdt.core.formatter.keep_then_statement_on_same_line=false
+org.eclipse.jdt.core.formatter.lineSplit=250
+org.eclipse.jdt.core.formatter.never_indent_block_comments_on_first_column=false
+org.eclipse.jdt.core.formatter.never_indent_line_comments_on_first_column=false
+org.eclipse.jdt.core.formatter.number_of_blank_lines_at_beginning_of_method_body=0
+org.eclipse.jdt.core.formatter.number_of_empty_lines_to_preserve=1
+org.eclipse.jdt.core.formatter.put_empty_statement_on_new_line=true
+org.eclipse.jdt.core.formatter.tabulation.char=space
+org.eclipse.jdt.core.formatter.tabulation.size=4
+org.eclipse.jdt.core.formatter.use_on_off_tags=false
+org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false
+org.eclipse.jdt.core.formatter.wrap_before_binary_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_or_operator_multicatch=true
+org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.ui.tests/.settings/org.eclipse.jdt.ui.prefs b/lttng/org.eclipse.tracecompass.lttng2.ust.ui.tests/.settings/org.eclipse.jdt.ui.prefs
new file mode 100644 (file)
index 0000000..232a3fd
--- /dev/null
@@ -0,0 +1,60 @@
+eclipse.preferences.version=1
+editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true
+formatter_profile=_tmf-style
+formatter_settings_version=12
+org.eclipse.jdt.ui.exception.name=e
+org.eclipse.jdt.ui.gettersetter.use.is=true
+org.eclipse.jdt.ui.keywordthis=false
+org.eclipse.jdt.ui.overrideannotation=true
+sp_cleanup.add_default_serial_version_id=true
+sp_cleanup.add_generated_serial_version_id=false
+sp_cleanup.add_missing_annotations=false
+sp_cleanup.add_missing_deprecated_annotations=true
+sp_cleanup.add_missing_methods=false
+sp_cleanup.add_missing_nls_tags=false
+sp_cleanup.add_missing_override_annotations=true
+sp_cleanup.add_missing_override_annotations_interface_methods=true
+sp_cleanup.add_serial_version_id=false
+sp_cleanup.always_use_blocks=true
+sp_cleanup.always_use_parentheses_in_expressions=false
+sp_cleanup.always_use_this_for_non_static_field_access=false
+sp_cleanup.always_use_this_for_non_static_method_access=false
+sp_cleanup.convert_to_enhanced_for_loop=false
+sp_cleanup.correct_indentation=false
+sp_cleanup.format_source_code=false
+sp_cleanup.format_source_code_changes_only=false
+sp_cleanup.make_local_variable_final=false
+sp_cleanup.make_parameters_final=false
+sp_cleanup.make_private_fields_final=true
+sp_cleanup.make_type_abstract_if_missing_method=false
+sp_cleanup.make_variable_declarations_final=false
+sp_cleanup.never_use_blocks=false
+sp_cleanup.never_use_parentheses_in_expressions=true
+sp_cleanup.on_save_use_additional_actions=true
+sp_cleanup.organize_imports=false
+sp_cleanup.qualify_static_field_accesses_with_declaring_class=false
+sp_cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=true
+sp_cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=true
+sp_cleanup.qualify_static_member_accesses_with_declaring_class=false
+sp_cleanup.qualify_static_method_accesses_with_declaring_class=false
+sp_cleanup.remove_private_constructors=true
+sp_cleanup.remove_trailing_whitespaces=true
+sp_cleanup.remove_trailing_whitespaces_all=true
+sp_cleanup.remove_trailing_whitespaces_ignore_empty=false
+sp_cleanup.remove_unnecessary_casts=false
+sp_cleanup.remove_unnecessary_nls_tags=false
+sp_cleanup.remove_unused_imports=false
+sp_cleanup.remove_unused_local_variables=false
+sp_cleanup.remove_unused_private_fields=true
+sp_cleanup.remove_unused_private_members=false
+sp_cleanup.remove_unused_private_methods=true
+sp_cleanup.remove_unused_private_types=true
+sp_cleanup.sort_members=false
+sp_cleanup.sort_members_all=false
+sp_cleanup.use_blocks=true
+sp_cleanup.use_blocks_only_for_return_and_throw=false
+sp_cleanup.use_parentheses_in_expressions=false
+sp_cleanup.use_this_for_non_static_field_access=false
+sp_cleanup.use_this_for_non_static_field_access_only_if_necessary=true
+sp_cleanup.use_this_for_non_static_method_access=false
+sp_cleanup.use_this_for_non_static_method_access_only_if_necessary=true
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.ui.tests/.settings/org.eclipse.pde.api.tools.prefs b/lttng/org.eclipse.tracecompass.lttng2.ust.ui.tests/.settings/org.eclipse.pde.api.tools.prefs
new file mode 100644 (file)
index 0000000..acc3abd
--- /dev/null
@@ -0,0 +1,97 @@
+ANNOTATION_ELEMENT_TYPE_ADDED_METHOD_WITHOUT_DEFAULT_VALUE=Error
+ANNOTATION_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+ANNOTATION_ELEMENT_TYPE_REMOVED_FIELD=Error
+ANNOTATION_ELEMENT_TYPE_REMOVED_METHOD=Error
+ANNOTATION_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_API_TYPE=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_API_TYPE=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_TYPE=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_TYPE=Error
+API_USE_SCAN_FIELD_SEVERITY=Error
+API_USE_SCAN_METHOD_SEVERITY=Error
+API_USE_SCAN_TYPE_SEVERITY=Error
+CLASS_ELEMENT_TYPE_ADDED_METHOD=Error
+CLASS_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
+CLASS_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+CLASS_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
+CLASS_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+CLASS_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
+CLASS_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
+CLASS_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+CLASS_ELEMENT_TYPE_REMOVED_CONSTRUCTOR=Error
+CLASS_ELEMENT_TYPE_REMOVED_FIELD=Error
+CLASS_ELEMENT_TYPE_REMOVED_METHOD=Error
+CLASS_ELEMENT_TYPE_REMOVED_SUPERCLASS=Error
+CLASS_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+CLASS_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+CONSTRUCTOR_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+CONSTRUCTOR_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+CONSTRUCTOR_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
+CONSTRUCTOR_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+ENUM_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
+ENUM_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+ENUM_ELEMENT_TYPE_REMOVED_ENUM_CONSTANT=Error
+ENUM_ELEMENT_TYPE_REMOVED_FIELD=Error
+ENUM_ELEMENT_TYPE_REMOVED_METHOD=Error
+ENUM_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+FIELD_ELEMENT_TYPE_ADDED_VALUE=Error
+FIELD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+FIELD_ELEMENT_TYPE_CHANGED_FINAL_TO_NON_FINAL_STATIC_CONSTANT=Error
+FIELD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
+FIELD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
+FIELD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
+FIELD_ELEMENT_TYPE_CHANGED_TYPE=Error
+FIELD_ELEMENT_TYPE_CHANGED_VALUE=Error
+FIELD_ELEMENT_TYPE_REMOVED_TYPE_ARGUMENT=Error
+FIELD_ELEMENT_TYPE_REMOVED_VALUE=Error
+ILLEGAL_EXTEND=Warning
+ILLEGAL_IMPLEMENT=Warning
+ILLEGAL_INSTANTIATE=Warning
+ILLEGAL_OVERRIDE=Warning
+ILLEGAL_REFERENCE=Warning
+INTERFACE_ELEMENT_TYPE_ADDED_FIELD=Error
+INTERFACE_ELEMENT_TYPE_ADDED_METHOD=Error
+INTERFACE_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
+INTERFACE_ELEMENT_TYPE_ADDED_SUPER_INTERFACE_WITH_METHODS=Error
+INTERFACE_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+INTERFACE_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
+INTERFACE_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_FIELD=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_METHOD=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+INVALID_JAVADOC_TAG=Warning
+INVALID_REFERENCE_IN_SYSTEM_LIBRARIES=Warning
+LEAK_EXTEND=Warning
+LEAK_FIELD_DECL=Warning
+LEAK_IMPLEMENT=Warning
+LEAK_METHOD_PARAM=Warning
+LEAK_METHOD_RETURN_TYPE=Warning
+METHOD_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
+METHOD_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+METHOD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+METHOD_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
+METHOD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
+METHOD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
+METHOD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
+METHOD_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
+METHOD_ELEMENT_TYPE_REMOVED_ANNOTATION_DEFAULT_VALUE=Error
+METHOD_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+MISSING_EE_DESCRIPTIONS=Ignore
+TYPE_PARAMETER_ELEMENT_TYPE_ADDED_CLASS_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_ADDED_INTERFACE_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_CLASS_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_INTERFACE_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_CLASS_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_INTERFACE_BOUND=Error
+UNUSED_PROBLEM_FILTERS=Warning
+automatically_removed_unused_problem_filters=false
+eclipse.preferences.version=1
+incompatible_api_component_version=Error
+incompatible_api_component_version_include_major_without_breaking_change=Disabled
+incompatible_api_component_version_include_minor_without_api_change=Disabled
+invalid_since_tag_version=Error
+malformed_since_tag=Error
+missing_since_tag=Error
+report_api_breakage_when_major_version_incremented=Disabled
+report_resolution_errors_api_component=Warning
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.ui.tests/.settings/org.eclipse.pde.prefs b/lttng/org.eclipse.tracecompass.lttng2.ust.ui.tests/.settings/org.eclipse.pde.prefs
new file mode 100644 (file)
index 0000000..62cfa90
--- /dev/null
@@ -0,0 +1,32 @@
+compilers.f.unresolved-features=1
+compilers.f.unresolved-plugins=1
+compilers.incompatible-environment=1
+compilers.p.build=1
+compilers.p.build.bin.includes=1
+compilers.p.build.encodings=2
+compilers.p.build.java.compiler=2
+compilers.p.build.java.compliance=1
+compilers.p.build.missing.output=2
+compilers.p.build.output.library=1
+compilers.p.build.source.library=1
+compilers.p.build.src.includes=1
+compilers.p.deprecated=1
+compilers.p.discouraged-class=1
+compilers.p.internal=1
+compilers.p.missing-packages=2
+compilers.p.missing-version-export-package=2
+compilers.p.missing-version-import-package=2
+compilers.p.missing-version-require-bundle=2
+compilers.p.no-required-att=0
+compilers.p.not-externalized-att=2
+compilers.p.unknown-attribute=1
+compilers.p.unknown-class=1
+compilers.p.unknown-element=1
+compilers.p.unknown-identifier=1
+compilers.p.unknown-resource=1
+compilers.p.unresolved-ex-points=0
+compilers.p.unresolved-import=0
+compilers.s.create-docs=false
+compilers.s.doc-folder=doc
+compilers.s.open-tags=1
+eclipse.preferences.version=1
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.ui.tests/META-INF/MANIFEST.MF b/lttng/org.eclipse.tracecompass.lttng2.ust.ui.tests/META-INF/MANIFEST.MF
new file mode 100644 (file)
index 0000000..f107679
--- /dev/null
@@ -0,0 +1,15 @@
+Manifest-Version: 1.0
+Bundle-ManifestVersion: 2
+Bundle-Name: %Bundle-Name
+Bundle-Vendor: %Bundle-Vendor
+Bundle-Version: 1.0.0.qualifier
+Bundle-Localization: plugin
+Bundle-SymbolicName: org.eclipse.tracecompass.lttng2.ust.ui.tests;singleton:=true
+Bundle-ActivationPolicy: lazy
+Bundle-RequiredExecutionEnvironment: JavaSE-1.7
+Require-Bundle: org.junit;bundle-version="4.0.0",
+ org.eclipse.ui,
+ org.eclipse.core.resources,
+ org.eclipse.core.runtime,
+ org.eclipse.tracecompass.lttng2.ust.ui
+Export-Package: org.eclipse.tracecompass.lttng2.ust.ui.tests
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.ui.tests/about.html b/lttng/org.eclipse.tracecompass.lttng2.ust.ui.tests/about.html
new file mode 100644 (file)
index 0000000..c258ef5
--- /dev/null
@@ -0,0 +1,28 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"/>
+<title>About</title>
+</head>
+<body lang="EN-US">
+<h2>About This Content</h2>
+<p>June 5, 2006</p>    
+<h3>License</h3>
+
+<p>The Eclipse Foundation makes available all content in this plug-in (&quot;Content&quot;).  Unless otherwise 
+indicated below, the Content is provided to you under the terms and conditions of the
+Eclipse Public License Version 1.0 (&quot;EPL&quot;).  A copy of the EPL is available 
+at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>.
+For purposes of the EPL, &quot;Program&quot; will mean the Content.</p>
+
+<p>If you did not receive this Content directly from the Eclipse Foundation, the Content is 
+being redistributed by another party (&quot;Redistributor&quot;) and different terms and conditions may
+apply to your use of any object code in the Content.  Check the Redistributor's license that was 
+provided with the Content.  If no such license exists, contact the Redistributor.  Unless otherwise
+indicated below, the terms and conditions of the EPL still apply to any source code in the Content
+and such source code may be obtained at <a href="http://www.eclipse.org/">http://www.eclipse.org</a>.</p>
+
+</body>
+</html>
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.ui.tests/build.properties b/lttng/org.eclipse.tracecompass.lttng2.ust.ui.tests/build.properties
new file mode 100644 (file)
index 0000000..978a8de
--- /dev/null
@@ -0,0 +1,19 @@
+###############################################################################
+# Copyright (c) 2013, 2015 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:
+#     Ericsson - Initial API and implementation
+###############################################################################
+
+source.. = src/
+output.. = bin/
+bin.includes = META-INF/,\
+               .,\
+               plugin.properties,\
+               about.html
+src.includes = about.html
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.ui.tests/plugin.properties b/lttng/org.eclipse.tracecompass.lttng2.ust.ui.tests/plugin.properties
new file mode 100644 (file)
index 0000000..bd43942
--- /dev/null
@@ -0,0 +1,14 @@
+###############################################################################
+# Copyright (c) 2013, 2014 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:
+#     Ericsson - Initial API and implementation
+###############################################################################
+
+Bundle-Vendor = Eclipse Trace Compass
+Bundle-Name = Trace Compass LTTng Userspace Tracer Analysis UI Tests Plug-in
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.ui.tests/pom.xml b/lttng/org.eclipse.tracecompass.lttng2.ust.ui.tests/pom.xml
new file mode 100644 (file)
index 0000000..f7f8941
--- /dev/null
@@ -0,0 +1,45 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+   Copyright (C) 2011, 2013 Red Hat Inc., 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
+-->
+<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>
+    <artifactId>org.eclipse.tracecompass.lttng-parent</artifactId>
+    <groupId>org.eclipse.tracecompass</groupId>
+    <version>1.0.0-SNAPSHOT</version>
+  </parent>
+
+  <artifactId>org.eclipse.tracecompass.lttng2.ust.ui.tests</artifactId>
+  <version>1.0.0-SNAPSHOT</version>
+  <packaging>eclipse-test-plugin</packaging>
+
+  <name>Trace Compass LTTng Userspace Tracer Analysis UI Tests Plug-in</name>
+
+  <build>
+    <plugins>
+      <plugin>
+        <groupId>org.eclipse.tycho</groupId>
+        <artifactId>tycho-surefire-plugin</artifactId>
+        <version>${tycho-version}</version>
+        <configuration>
+          <testSuite>org.eclipse.tracecompass.lttng2.ust.ui.tests</testSuite>
+          <testClass>org.eclipse.tracecompass.lttng2.ust.ui.tests.AllTests</testClass>
+          <useUIHarness>true</useUIHarness>
+          <useUIThread>true</useUIThread>
+          <argLine>${tycho.testArgLine} ${base.ui.test.vmargs}</argLine>
+          <product>org.eclipse.platform.ide</product>
+        </configuration>
+      </plugin>
+    </plugins>
+  </build>
+
+  <groupId>org.eclipse.tracecompass</groupId>
+</project>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.ui.tests/src/org/eclipse/tracecompass/lttng2/ust/ui/tests/ActivatorTest.java b/lttng/org.eclipse.tracecompass.lttng2.ust.ui.tests/src/org/eclipse/tracecompass/lttng2/ust/ui/tests/ActivatorTest.java
new file mode 100644 (file)
index 0000000..eb6eba1
--- /dev/null
@@ -0,0 +1,60 @@
+/*******************************************************************************
+ * Copyright (c) 2013, 2014 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:
+ *   Alexandre Montplaisir - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.ust.ui.tests;
+
+import static org.junit.Assert.assertTrue;
+
+import org.junit.Test;
+
+/**
+ * Test suite for the Activator class
+ */
+public class ActivatorTest {
+
+    // ------------------------------------------------------------------------
+    // Tests
+    // ------------------------------------------------------------------------
+
+    /**
+     * Test method for {@link org.eclipse.tracecompass.internal.lttng2.ust.ui.Activator#Activator()}.
+     */
+    @Test
+    public void testActivator() {
+        assertTrue(true);
+    }
+
+    /**
+     * Test method for {@link org.eclipse.tracecompass.internal.lttng2.ust.ui.Activator#getDefault()}.
+     */
+    @Test
+    public void testGetDefault() {
+        assertTrue(true);
+    }
+
+    /**
+     * Test method for {@link org.eclipse.tracecompass.internal.lttng2.ust.ui.Activator#start}.
+     */
+    @Test
+    public void testStartBundleContext() {
+        assertTrue(true);
+    }
+
+    /**
+     * Test method for {@link org.eclipse.tracecompass.internal.lttng2.ust.ui.Activator#stop}.
+     */
+    @Test
+    public void testStopBundleContext() {
+        assertTrue(true);
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.ui.tests/src/org/eclipse/tracecompass/lttng2/ust/ui/tests/AllTests.java b/lttng/org.eclipse.tracecompass.lttng2.ust.ui.tests/src/org/eclipse/tracecompass/lttng2/ust/ui/tests/AllTests.java
new file mode 100644 (file)
index 0000000..11575ec
--- /dev/null
@@ -0,0 +1,27 @@
+/*******************************************************************************
+ * Copyright (c) 2013, 2014 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:
+ *   Alexandre Montplaisir - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.ust.ui.tests;
+
+import org.junit.runner.RunWith;
+import org.junit.runners.Suite;
+
+/**
+ * Run the lttng2.ust.ui unit tests.
+ */
+@RunWith(Suite.class)
+@Suite.SuiteClasses({
+    ActivatorTest.class,
+})
+public class AllTests {
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.ui/.classpath b/lttng/org.eclipse.tracecompass.lttng2.ust.ui/.classpath
new file mode 100644 (file)
index 0000000..098194c
--- /dev/null
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+       <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7"/>
+       <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
+       <classpathentry kind="src" path="src"/>
+       <classpathentry kind="output" path="bin"/>
+</classpath>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.ui/.project b/lttng/org.eclipse.tracecompass.lttng2.ust.ui/.project
new file mode 100644 (file)
index 0000000..9dc8aa4
--- /dev/null
@@ -0,0 +1,34 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+       <name>org.eclipse.tracecompass.lttng2.ust.ui</name>
+       <comment></comment>
+       <projects>
+       </projects>
+       <buildSpec>
+               <buildCommand>
+                       <name>org.eclipse.jdt.core.javabuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+               <buildCommand>
+                       <name>org.eclipse.pde.ManifestBuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+               <buildCommand>
+                       <name>org.eclipse.pde.SchemaBuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+               <buildCommand>
+                       <name>org.eclipse.pde.api.tools.apiAnalysisBuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+       </buildSpec>
+       <natures>
+               <nature>org.eclipse.pde.PluginNature</nature>
+               <nature>org.eclipse.jdt.core.javanature</nature>
+               <nature>org.eclipse.pde.api.tools.apiAnalysisNature</nature>
+       </natures>
+</projectDescription>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.ui/.settings/org.eclipse.core.resources.prefs b/lttng/org.eclipse.tracecompass.lttng2.ust.ui/.settings/org.eclipse.core.resources.prefs
new file mode 100644 (file)
index 0000000..99f26c0
--- /dev/null
@@ -0,0 +1,2 @@
+eclipse.preferences.version=1
+encoding/<project>=UTF-8
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.ui/.settings/org.eclipse.core.runtime.prefs b/lttng/org.eclipse.tracecompass.lttng2.ust.ui/.settings/org.eclipse.core.runtime.prefs
new file mode 100644 (file)
index 0000000..5a0ad22
--- /dev/null
@@ -0,0 +1,2 @@
+eclipse.preferences.version=1
+line.separator=\n
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.ui/.settings/org.eclipse.jdt.core.prefs b/lttng/org.eclipse.tracecompass.lttng2.ust.ui/.settings/org.eclipse.jdt.core.prefs
new file mode 100644 (file)
index 0000000..a2b5e6b
--- /dev/null
@@ -0,0 +1,405 @@
+eclipse.preferences.version=1
+org.eclipse.jdt.core.codeComplete.argumentPrefixes=
+org.eclipse.jdt.core.codeComplete.argumentSuffixes=
+org.eclipse.jdt.core.codeComplete.fieldPrefixes=f
+org.eclipse.jdt.core.codeComplete.fieldSuffixes=
+org.eclipse.jdt.core.codeComplete.localPrefixes=
+org.eclipse.jdt.core.codeComplete.localSuffixes=
+org.eclipse.jdt.core.codeComplete.staticFieldPrefixes=
+org.eclipse.jdt.core.codeComplete.staticFieldSuffixes=
+org.eclipse.jdt.core.codeComplete.staticFinalFieldPrefixes=
+org.eclipse.jdt.core.codeComplete.staticFinalFieldSuffixes=
+org.eclipse.jdt.core.compiler.annotation.inheritNullAnnotations=enabled
+org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore
+org.eclipse.jdt.core.compiler.annotation.nonnull=org.eclipse.jdt.annotation.NonNull
+org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=org.eclipse.jdt.annotation.NonNullByDefault
+org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nullable
+org.eclipse.jdt.core.compiler.annotation.nullanalysis=enabled
+org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
+org.eclipse.jdt.core.compiler.codegen.methodParameters=do not generate
+org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
+org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
+org.eclipse.jdt.core.compiler.compliance=1.7
+org.eclipse.jdt.core.compiler.debug.lineNumber=generate
+org.eclipse.jdt.core.compiler.debug.localVariable=generate
+org.eclipse.jdt.core.compiler.debug.sourceFile=generate
+org.eclipse.jdt.core.compiler.doc.comment.support=enabled
+org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=error
+org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
+org.eclipse.jdt.core.compiler.problem.autoboxing=ignore
+org.eclipse.jdt.core.compiler.problem.comparingIdentical=error
+org.eclipse.jdt.core.compiler.problem.deadCode=error
+org.eclipse.jdt.core.compiler.problem.deprecation=error
+org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled
+org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=enabled
+org.eclipse.jdt.core.compiler.problem.discouragedReference=warning
+org.eclipse.jdt.core.compiler.problem.emptyStatement=error
+org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
+org.eclipse.jdt.core.compiler.problem.explicitlyClosedAutoCloseable=error
+org.eclipse.jdt.core.compiler.problem.fallthroughCase=error
+org.eclipse.jdt.core.compiler.problem.fatalOptionalError=disabled
+org.eclipse.jdt.core.compiler.problem.fieldHiding=error
+org.eclipse.jdt.core.compiler.problem.finalParameterBound=error
+org.eclipse.jdt.core.compiler.problem.finallyBlockNotCompletingNormally=error
+org.eclipse.jdt.core.compiler.problem.forbiddenReference=error
+org.eclipse.jdt.core.compiler.problem.hiddenCatchBlock=error
+org.eclipse.jdt.core.compiler.problem.includeNullInfoFromAsserts=disabled
+org.eclipse.jdt.core.compiler.problem.incompatibleNonInheritedInterfaceMethod=error
+org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch=error
+org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=error
+org.eclipse.jdt.core.compiler.problem.invalidJavadoc=warning
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTags=enabled
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsDeprecatedRef=enabled
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsNotVisibleRef=enabled
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsVisibility=protected
+org.eclipse.jdt.core.compiler.problem.localVariableHiding=error
+org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=error
+org.eclipse.jdt.core.compiler.problem.missingDefaultCase=error
+org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=error
+org.eclipse.jdt.core.compiler.problem.missingEnumCaseDespiteDefault=enabled
+org.eclipse.jdt.core.compiler.problem.missingHashCodeMethod=error
+org.eclipse.jdt.core.compiler.problem.missingJavadocComments=warning
+org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsOverriding=disabled
+org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsVisibility=protected
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagDescription=all_standard_tags
+org.eclipse.jdt.core.compiler.problem.missingJavadocTags=warning
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagsMethodTypeParameters=disabled
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagsOverriding=disabled
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagsVisibility=protected
+org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotation=error
+org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotationForInterfaceMethodImplementation=enabled
+org.eclipse.jdt.core.compiler.problem.missingSerialVersion=error
+org.eclipse.jdt.core.compiler.problem.missingSynchronizedOnInheritedMethod=error
+org.eclipse.jdt.core.compiler.problem.noEffectAssignment=error
+org.eclipse.jdt.core.compiler.problem.noImplicitStringConversion=error
+org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=warning
+org.eclipse.jdt.core.compiler.problem.nonnullParameterAnnotationDropped=warning
+org.eclipse.jdt.core.compiler.problem.nullAnnotationInferenceConflict=warning
+org.eclipse.jdt.core.compiler.problem.nullReference=error
+org.eclipse.jdt.core.compiler.problem.nullSpecViolation=error
+org.eclipse.jdt.core.compiler.problem.nullUncheckedConversion=warning
+org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=error
+org.eclipse.jdt.core.compiler.problem.parameterAssignment=error
+org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=error
+org.eclipse.jdt.core.compiler.problem.potentialNullReference=error
+org.eclipse.jdt.core.compiler.problem.potentiallyUnclosedCloseable=warning
+org.eclipse.jdt.core.compiler.problem.rawTypeReference=warning
+org.eclipse.jdt.core.compiler.problem.redundantNullAnnotation=warning
+org.eclipse.jdt.core.compiler.problem.redundantNullCheck=error
+org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=error
+org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=error
+org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore
+org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=error
+org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled
+org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=error
+org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=disabled
+org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled
+org.eclipse.jdt.core.compiler.problem.syntacticNullAnalysisForFields=enabled
+org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=ignore
+org.eclipse.jdt.core.compiler.problem.typeParameterHiding=error
+org.eclipse.jdt.core.compiler.problem.unavoidableGenericTypeProblems=disabled
+org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=warning
+org.eclipse.jdt.core.compiler.problem.unclosedCloseable=error
+org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=ignore
+org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=error
+org.eclipse.jdt.core.compiler.problem.unnecessaryElse=error
+org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=error
+org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=warning
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionExemptExceptionAndThrowable=disabled
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionIncludeDocCommentReference=disabled
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverriding=disabled
+org.eclipse.jdt.core.compiler.problem.unusedExceptionParameter=ignore
+org.eclipse.jdt.core.compiler.problem.unusedImport=error
+org.eclipse.jdt.core.compiler.problem.unusedLabel=error
+org.eclipse.jdt.core.compiler.problem.unusedLocal=error
+org.eclipse.jdt.core.compiler.problem.unusedObjectAllocation=ignore
+org.eclipse.jdt.core.compiler.problem.unusedParameter=error
+org.eclipse.jdt.core.compiler.problem.unusedParameterIncludeDocCommentReference=enabled
+org.eclipse.jdt.core.compiler.problem.unusedParameterWhenImplementingAbstract=disabled
+org.eclipse.jdt.core.compiler.problem.unusedParameterWhenOverridingConcrete=disabled
+org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=error
+org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=error
+org.eclipse.jdt.core.compiler.problem.unusedWarningToken=error
+org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=error
+org.eclipse.jdt.core.compiler.source=1.7
+org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=16
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_call=16
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation=16
+org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression=16
+org.eclipse.jdt.core.formatter.alignment_for_assignment=0
+org.eclipse.jdt.core.formatter.alignment_for_binary_expression=16
+org.eclipse.jdt.core.formatter.alignment_for_compact_if=16
+org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=80
+org.eclipse.jdt.core.formatter.alignment_for_enum_constants=0
+org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=16
+org.eclipse.jdt.core.formatter.alignment_for_method_declaration=0
+org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16
+org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=80
+org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation=0
+org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_constructor_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_method_declaration=16
+org.eclipse.jdt.core.formatter.alignment_for_union_type_in_multicatch=16
+org.eclipse.jdt.core.formatter.blank_lines_after_imports=1
+org.eclipse.jdt.core.formatter.blank_lines_after_package=1
+org.eclipse.jdt.core.formatter.blank_lines_before_field=0
+org.eclipse.jdt.core.formatter.blank_lines_before_first_class_body_declaration=0
+org.eclipse.jdt.core.formatter.blank_lines_before_imports=1
+org.eclipse.jdt.core.formatter.blank_lines_before_member_type=1
+org.eclipse.jdt.core.formatter.blank_lines_before_method=1
+org.eclipse.jdt.core.formatter.blank_lines_before_new_chunk=1
+org.eclipse.jdt.core.formatter.blank_lines_before_package=0
+org.eclipse.jdt.core.formatter.blank_lines_between_import_groups=1
+org.eclipse.jdt.core.formatter.blank_lines_between_type_declarations=1
+org.eclipse.jdt.core.formatter.brace_position_for_annotation_type_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_array_initializer=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_block=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_block_in_case=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_constructor_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_enum_constant=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_enum_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_method_declaration=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_switch=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_type_declaration=end_of_line
+org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_block_comment=false
+org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_javadoc_comment=false
+org.eclipse.jdt.core.formatter.comment.format_block_comments=true
+org.eclipse.jdt.core.formatter.comment.format_header=false
+org.eclipse.jdt.core.formatter.comment.format_html=true
+org.eclipse.jdt.core.formatter.comment.format_javadoc_comments=true
+org.eclipse.jdt.core.formatter.comment.format_line_comments=true
+org.eclipse.jdt.core.formatter.comment.format_source_code=true
+org.eclipse.jdt.core.formatter.comment.indent_parameter_description=true
+org.eclipse.jdt.core.formatter.comment.indent_root_tags=true
+org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags=insert
+org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter=insert
+org.eclipse.jdt.core.formatter.comment.line_length=80
+org.eclipse.jdt.core.formatter.comment.new_lines_at_block_boundaries=true
+org.eclipse.jdt.core.formatter.comment.new_lines_at_javadoc_boundaries=true
+org.eclipse.jdt.core.formatter.comment.preserve_white_space_between_code_and_line_comments=false
+org.eclipse.jdt.core.formatter.compact_else_if=true
+org.eclipse.jdt.core.formatter.continuation_indentation=2
+org.eclipse.jdt.core.formatter.continuation_indentation_for_array_initializer=2
+org.eclipse.jdt.core.formatter.disabling_tag=@formatter\:off
+org.eclipse.jdt.core.formatter.enabling_tag=@formatter\:on
+org.eclipse.jdt.core.formatter.format_guardian_clause_on_one_line=false
+org.eclipse.jdt.core.formatter.format_line_comment_starting_on_first_column=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_annotation_declaration_header=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_constant_header=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_declaration_header=true
+org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_type_header=true
+org.eclipse.jdt.core.formatter.indent_breaks_compare_to_cases=true
+org.eclipse.jdt.core.formatter.indent_empty_lines=false
+org.eclipse.jdt.core.formatter.indent_statements_compare_to_block=true
+org.eclipse.jdt.core.formatter.indent_statements_compare_to_body=true
+org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_cases=true
+org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_switch=false
+org.eclipse.jdt.core.formatter.indentation.size=4
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_field=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_local_variable=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_method=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_package=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_parameter=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_type=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_label=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_opening_brace_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_at_end_of_file_if_missing=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_finally_in_try_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_while_in_do_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_annotation_declaration=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_anonymous_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_block=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=insert
+org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter=insert
+org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_binary_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block=insert
+org.eclipse.jdt.core.formatter.insert_space_after_closing_paren_in_cast=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_assert=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_case=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_after_colon_in_labeled_statement=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_allocation_expression=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_annotation=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_throws=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_constant_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_declarations=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_explicitconstructorcall_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_increments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_inits=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_throws=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_invocation_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_field_declarations=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_local_declarations=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_parameterized_type_reference=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_superinterfaces=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments=insert
+org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters=insert
+org.eclipse.jdt.core.formatter.insert_space_after_ellipsis=insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_brace_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_cast=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_catch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_for=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_if=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_parenthesized_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_switch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_synchronized=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_try=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_while=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard=do not insert
+org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_try_resources=insert
+org.eclipse.jdt.core.formatter.insert_space_after_unary_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter=insert
+org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_binary_operator=insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_brace_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_cast=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_catch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_for=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_if=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_parenthesized_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_switch=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_synchronized=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_try=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_while=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_assert=insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_case=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_default=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_labeled_statement=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_throws=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_constant_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_declarations=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_explicitconstructorcall_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_increments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_inits=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_throws=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_invocation_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_field_declarations=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_local_declarations=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_superinterfaces=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_ellipsis=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_annotation_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_anonymous_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_array_initializer=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_block=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_constructor_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_constant=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_method_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_switch=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_type_declaration=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation_type_member_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_catch=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_for=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_if=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_parenthesized_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_switch=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_synchronized=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_try=insert
+org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_while=insert
+org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_return=insert
+org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_throw=insert
+org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_semicolon=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_try_resources=do not insert
+org.eclipse.jdt.core.formatter.insert_space_before_unary_operator=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_brackets_in_array_allocation_expression=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_annotation_type_member_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_enum_constant=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_declaration=do not insert
+org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_invocation=do not insert
+org.eclipse.jdt.core.formatter.join_lines_in_comments=true
+org.eclipse.jdt.core.formatter.join_wrapped_lines=false
+org.eclipse.jdt.core.formatter.keep_else_statement_on_same_line=false
+org.eclipse.jdt.core.formatter.keep_empty_array_initializer_on_one_line=false
+org.eclipse.jdt.core.formatter.keep_imple_if_on_one_line=false
+org.eclipse.jdt.core.formatter.keep_then_statement_on_same_line=false
+org.eclipse.jdt.core.formatter.lineSplit=250
+org.eclipse.jdt.core.formatter.never_indent_block_comments_on_first_column=false
+org.eclipse.jdt.core.formatter.never_indent_line_comments_on_first_column=false
+org.eclipse.jdt.core.formatter.number_of_blank_lines_at_beginning_of_method_body=0
+org.eclipse.jdt.core.formatter.number_of_empty_lines_to_preserve=1
+org.eclipse.jdt.core.formatter.put_empty_statement_on_new_line=true
+org.eclipse.jdt.core.formatter.tabulation.char=space
+org.eclipse.jdt.core.formatter.tabulation.size=4
+org.eclipse.jdt.core.formatter.use_on_off_tags=false
+org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false
+org.eclipse.jdt.core.formatter.wrap_before_binary_operator=true
+org.eclipse.jdt.core.formatter.wrap_before_or_operator_multicatch=true
+org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.ui/.settings/org.eclipse.jdt.ui.prefs b/lttng/org.eclipse.tracecompass.lttng2.ust.ui/.settings/org.eclipse.jdt.ui.prefs
new file mode 100644 (file)
index 0000000..232a3fd
--- /dev/null
@@ -0,0 +1,60 @@
+eclipse.preferences.version=1
+editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true
+formatter_profile=_tmf-style
+formatter_settings_version=12
+org.eclipse.jdt.ui.exception.name=e
+org.eclipse.jdt.ui.gettersetter.use.is=true
+org.eclipse.jdt.ui.keywordthis=false
+org.eclipse.jdt.ui.overrideannotation=true
+sp_cleanup.add_default_serial_version_id=true
+sp_cleanup.add_generated_serial_version_id=false
+sp_cleanup.add_missing_annotations=false
+sp_cleanup.add_missing_deprecated_annotations=true
+sp_cleanup.add_missing_methods=false
+sp_cleanup.add_missing_nls_tags=false
+sp_cleanup.add_missing_override_annotations=true
+sp_cleanup.add_missing_override_annotations_interface_methods=true
+sp_cleanup.add_serial_version_id=false
+sp_cleanup.always_use_blocks=true
+sp_cleanup.always_use_parentheses_in_expressions=false
+sp_cleanup.always_use_this_for_non_static_field_access=false
+sp_cleanup.always_use_this_for_non_static_method_access=false
+sp_cleanup.convert_to_enhanced_for_loop=false
+sp_cleanup.correct_indentation=false
+sp_cleanup.format_source_code=false
+sp_cleanup.format_source_code_changes_only=false
+sp_cleanup.make_local_variable_final=false
+sp_cleanup.make_parameters_final=false
+sp_cleanup.make_private_fields_final=true
+sp_cleanup.make_type_abstract_if_missing_method=false
+sp_cleanup.make_variable_declarations_final=false
+sp_cleanup.never_use_blocks=false
+sp_cleanup.never_use_parentheses_in_expressions=true
+sp_cleanup.on_save_use_additional_actions=true
+sp_cleanup.organize_imports=false
+sp_cleanup.qualify_static_field_accesses_with_declaring_class=false
+sp_cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=true
+sp_cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=true
+sp_cleanup.qualify_static_member_accesses_with_declaring_class=false
+sp_cleanup.qualify_static_method_accesses_with_declaring_class=false
+sp_cleanup.remove_private_constructors=true
+sp_cleanup.remove_trailing_whitespaces=true
+sp_cleanup.remove_trailing_whitespaces_all=true
+sp_cleanup.remove_trailing_whitespaces_ignore_empty=false
+sp_cleanup.remove_unnecessary_casts=false
+sp_cleanup.remove_unnecessary_nls_tags=false
+sp_cleanup.remove_unused_imports=false
+sp_cleanup.remove_unused_local_variables=false
+sp_cleanup.remove_unused_private_fields=true
+sp_cleanup.remove_unused_private_members=false
+sp_cleanup.remove_unused_private_methods=true
+sp_cleanup.remove_unused_private_types=true
+sp_cleanup.sort_members=false
+sp_cleanup.sort_members_all=false
+sp_cleanup.use_blocks=true
+sp_cleanup.use_blocks_only_for_return_and_throw=false
+sp_cleanup.use_parentheses_in_expressions=false
+sp_cleanup.use_this_for_non_static_field_access=false
+sp_cleanup.use_this_for_non_static_field_access_only_if_necessary=true
+sp_cleanup.use_this_for_non_static_method_access=false
+sp_cleanup.use_this_for_non_static_method_access_only_if_necessary=true
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.ui/.settings/org.eclipse.pde.api.tools.prefs b/lttng/org.eclipse.tracecompass.lttng2.ust.ui/.settings/org.eclipse.pde.api.tools.prefs
new file mode 100644 (file)
index 0000000..acc3abd
--- /dev/null
@@ -0,0 +1,97 @@
+ANNOTATION_ELEMENT_TYPE_ADDED_METHOD_WITHOUT_DEFAULT_VALUE=Error
+ANNOTATION_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+ANNOTATION_ELEMENT_TYPE_REMOVED_FIELD=Error
+ANNOTATION_ELEMENT_TYPE_REMOVED_METHOD=Error
+ANNOTATION_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_API_TYPE=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_API_TYPE=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_TYPE=Error
+API_COMPONENT_ELEMENT_TYPE_REMOVED_TYPE=Error
+API_USE_SCAN_FIELD_SEVERITY=Error
+API_USE_SCAN_METHOD_SEVERITY=Error
+API_USE_SCAN_TYPE_SEVERITY=Error
+CLASS_ELEMENT_TYPE_ADDED_METHOD=Error
+CLASS_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
+CLASS_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+CLASS_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
+CLASS_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+CLASS_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
+CLASS_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
+CLASS_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+CLASS_ELEMENT_TYPE_REMOVED_CONSTRUCTOR=Error
+CLASS_ELEMENT_TYPE_REMOVED_FIELD=Error
+CLASS_ELEMENT_TYPE_REMOVED_METHOD=Error
+CLASS_ELEMENT_TYPE_REMOVED_SUPERCLASS=Error
+CLASS_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+CLASS_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+CONSTRUCTOR_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+CONSTRUCTOR_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+CONSTRUCTOR_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
+CONSTRUCTOR_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+ENUM_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
+ENUM_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+ENUM_ELEMENT_TYPE_REMOVED_ENUM_CONSTANT=Error
+ENUM_ELEMENT_TYPE_REMOVED_FIELD=Error
+ENUM_ELEMENT_TYPE_REMOVED_METHOD=Error
+ENUM_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+FIELD_ELEMENT_TYPE_ADDED_VALUE=Error
+FIELD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+FIELD_ELEMENT_TYPE_CHANGED_FINAL_TO_NON_FINAL_STATIC_CONSTANT=Error
+FIELD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
+FIELD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
+FIELD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
+FIELD_ELEMENT_TYPE_CHANGED_TYPE=Error
+FIELD_ELEMENT_TYPE_CHANGED_VALUE=Error
+FIELD_ELEMENT_TYPE_REMOVED_TYPE_ARGUMENT=Error
+FIELD_ELEMENT_TYPE_REMOVED_VALUE=Error
+ILLEGAL_EXTEND=Warning
+ILLEGAL_IMPLEMENT=Warning
+ILLEGAL_INSTANTIATE=Warning
+ILLEGAL_OVERRIDE=Warning
+ILLEGAL_REFERENCE=Warning
+INTERFACE_ELEMENT_TYPE_ADDED_FIELD=Error
+INTERFACE_ELEMENT_TYPE_ADDED_METHOD=Error
+INTERFACE_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
+INTERFACE_ELEMENT_TYPE_ADDED_SUPER_INTERFACE_WITH_METHODS=Error
+INTERFACE_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+INTERFACE_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
+INTERFACE_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_FIELD=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_METHOD=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
+INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+INVALID_JAVADOC_TAG=Warning
+INVALID_REFERENCE_IN_SYSTEM_LIBRARIES=Warning
+LEAK_EXTEND=Warning
+LEAK_FIELD_DECL=Warning
+LEAK_IMPLEMENT=Warning
+LEAK_METHOD_PARAM=Warning
+LEAK_METHOD_RETURN_TYPE=Warning
+METHOD_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
+METHOD_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
+METHOD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
+METHOD_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
+METHOD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
+METHOD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
+METHOD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
+METHOD_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
+METHOD_ELEMENT_TYPE_REMOVED_ANNOTATION_DEFAULT_VALUE=Error
+METHOD_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
+MISSING_EE_DESCRIPTIONS=Ignore
+TYPE_PARAMETER_ELEMENT_TYPE_ADDED_CLASS_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_ADDED_INTERFACE_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_CLASS_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_INTERFACE_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_CLASS_BOUND=Error
+TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_INTERFACE_BOUND=Error
+UNUSED_PROBLEM_FILTERS=Warning
+automatically_removed_unused_problem_filters=false
+eclipse.preferences.version=1
+incompatible_api_component_version=Error
+incompatible_api_component_version_include_major_without_breaking_change=Disabled
+incompatible_api_component_version_include_minor_without_api_change=Disabled
+invalid_since_tag_version=Error
+malformed_since_tag=Error
+missing_since_tag=Error
+report_api_breakage_when_major_version_incremented=Disabled
+report_resolution_errors_api_component=Warning
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.ui/.settings/org.eclipse.pde.prefs b/lttng/org.eclipse.tracecompass.lttng2.ust.ui/.settings/org.eclipse.pde.prefs
new file mode 100644 (file)
index 0000000..d92b94f
--- /dev/null
@@ -0,0 +1,32 @@
+compilers.f.unresolved-features=1
+compilers.f.unresolved-plugins=1
+compilers.incompatible-environment=1
+compilers.p.build=1
+compilers.p.build.bin.includes=1
+compilers.p.build.encodings=2
+compilers.p.build.java.compiler=2
+compilers.p.build.java.compliance=1
+compilers.p.build.missing.output=2
+compilers.p.build.output.library=1
+compilers.p.build.source.library=1
+compilers.p.build.src.includes=1
+compilers.p.deprecated=1
+compilers.p.discouraged-class=1
+compilers.p.internal=1
+compilers.p.missing-packages=1
+compilers.p.missing-version-export-package=2
+compilers.p.missing-version-import-package=2
+compilers.p.missing-version-require-bundle=2
+compilers.p.no-required-att=0
+compilers.p.not-externalized-att=1
+compilers.p.unknown-attribute=1
+compilers.p.unknown-class=1
+compilers.p.unknown-element=1
+compilers.p.unknown-identifier=1
+compilers.p.unknown-resource=1
+compilers.p.unresolved-ex-points=0
+compilers.p.unresolved-import=0
+compilers.s.create-docs=false
+compilers.s.doc-folder=doc
+compilers.s.open-tags=1
+eclipse.preferences.version=1
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.ui/META-INF/MANIFEST.MF b/lttng/org.eclipse.tracecompass.lttng2.ust.ui/META-INF/MANIFEST.MF
new file mode 100644 (file)
index 0000000..5a12739
--- /dev/null
@@ -0,0 +1,21 @@
+Manifest-Version: 1.0
+Bundle-ManifestVersion: 2
+Bundle-Name: %Bundle-Name
+Bundle-Vendor: %Bundle-Vendor
+Bundle-Version: 1.0.0.qualifier
+Bundle-Localization: plugin
+Bundle-SymbolicName: org.eclipse.tracecompass.lttng2.ust.ui;singleton:=true
+Bundle-Activator: org.eclipse.tracecompass.internal.lttng2.ust.ui.Activator
+Bundle-ActivationPolicy: lazy
+Bundle-RequiredExecutionEnvironment: JavaSE-1.7
+Require-Bundle: org.eclipse.core.resources,
+ org.eclipse.core.runtime,
+ org.eclipse.ui,
+ org.eclipse.tracecompass.common.core,
+ org.eclipse.tracecompass.lttng2.ust.core,
+ org.eclipse.tracecompass.tmf.core,
+ org.eclipse.tracecompass.tmf.ui,
+ org.eclipse.tracecompass.tmf.ctf.core
+Export-Package: org.eclipse.tracecompass.internal.lttng2.ust.ui;x-friends:="org.eclipse.tracecompass.lttng2.ust.ui.tests",
+ org.eclipse.tracecompass.internal.lttng2.ust.ui.views.memusage;x-friends:="org.eclipse.tracecompass.lttng2.ust.ui.tests",
+ org.eclipse.tracecompass.lttng2.ust.ui.analysis.callstack
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.ui/about.html b/lttng/org.eclipse.tracecompass.lttng2.ust.ui/about.html
new file mode 100644 (file)
index 0000000..c258ef5
--- /dev/null
@@ -0,0 +1,28 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"/>
+<title>About</title>
+</head>
+<body lang="EN-US">
+<h2>About This Content</h2>
+<p>June 5, 2006</p>    
+<h3>License</h3>
+
+<p>The Eclipse Foundation makes available all content in this plug-in (&quot;Content&quot;).  Unless otherwise 
+indicated below, the Content is provided to you under the terms and conditions of the
+Eclipse Public License Version 1.0 (&quot;EPL&quot;).  A copy of the EPL is available 
+at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>.
+For purposes of the EPL, &quot;Program&quot; will mean the Content.</p>
+
+<p>If you did not receive this Content directly from the Eclipse Foundation, the Content is 
+being redistributed by another party (&quot;Redistributor&quot;) and different terms and conditions may
+apply to your use of any object code in the Content.  Check the Redistributor's license that was 
+provided with the Content.  If no such license exists, contact the Redistributor.  Unless otherwise
+indicated below, the terms and conditions of the EPL still apply to any source code in the Content
+and such source code may be obtained at <a href="http://www.eclipse.org/">http://www.eclipse.org</a>.</p>
+
+</body>
+</html>
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.ui/build.properties b/lttng/org.eclipse.tracecompass.lttng2.ust.ui/build.properties
new file mode 100644 (file)
index 0000000..1046daa
--- /dev/null
@@ -0,0 +1,23 @@
+###############################################################################
+# Copyright (c) 2013, 2014 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:
+#     Ericsson - Initial API and implementation
+###############################################################################
+
+source.. = src/
+output.. = bin/
+bin.includes = META-INF/,\
+               icons/,\
+               .,\
+               plugin.xml,\
+               about.html,\
+               plugin.properties
+src.includes = about.html
+additional.bundles = org.eclipse.jdt.annotation
+jars.extra.classpath = platform:/plugin/org.eclipse.jdt.annotation
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.ui/icons/obj16/garland16.png b/lttng/org.eclipse.tracecompass.lttng2.ust.ui/icons/obj16/garland16.png
new file mode 100644 (file)
index 0000000..74f9751
Binary files /dev/null and b/lttng/org.eclipse.tracecompass.lttng2.ust.ui/icons/obj16/garland16.png differ
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.ui/plugin.properties b/lttng/org.eclipse.tracecompass.lttng2.ust.ui/plugin.properties
new file mode 100644 (file)
index 0000000..3884ade
--- /dev/null
@@ -0,0 +1,19 @@
+###############################################################################
+# Copyright (c) 2013, 2014 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:
+#     Ericsson - Initial API and implementation
+###############################################################################
+
+Bundle-Vendor = Eclipse Trace Compass
+Bundle-Name = Trace Compass LTTng Userspace Tracer Analysis UI Plug-in
+
+tracetype.type.ust = LTTng UST Trace
+memoryusage.view.name = UST Memory Usage
+
+analysis.callstack = LTTng-UST CallStack Analysis
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.ui/plugin.xml b/lttng/org.eclipse.tracecompass.lttng2.ust.ui/plugin.xml
new file mode 100644 (file)
index 0000000..af716b7
--- /dev/null
@@ -0,0 +1,41 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<?eclipse version="3.4"?>
+<plugin>
+   <extension
+         point="org.eclipse.linuxtools.tmf.ui.tracetypeui">
+      <type
+            icon="icons/obj16/garland16.png"
+            tracetype="org.eclipse.linuxtools.lttng2.ust.tracetype">
+      </type>
+   </extension>
+   <extension
+         point="org.eclipse.ui.views">
+      <view
+            category="org.eclipse.linuxtools.lttng2.ui.views.category"
+            class="org.eclipse.tracecompass.internal.lttng2.ust.ui.views.memusage.MemoryUsageView"
+            id="org.eclipse.linuxtools.lttng2.ust.memoryusage"
+            name="%memoryusage.view.name"
+            restorable="true">
+      </view>
+   </extension>
+   <extension
+         point="org.eclipse.linuxtools.tmf.core.analysis">
+      <module
+            analysis_module="org.eclipse.tracecompass.lttng2.ust.ui.analysis.callstack.LttngUstCallStackAnalysis"
+            automatic="false"
+            id="org.eclipse.linuxtools.lttng2.ust.analysis.callstack"
+            name="%analysis.callstack">
+         <tracetype
+               applies="true"
+               class="org.eclipse.tracecompass.lttng2.ust.core.trace.LttngUstTrace">
+         </tracetype>
+      </module>
+      <output
+            class="org.eclipse.tracecompass.tmf.ui.analysis.TmfAnalysisViewOutput"
+            id="org.eclipse.linuxtools.lttng2.ust.memoryusage">
+         <analysisId
+               id="org.eclipse.linuxtools.lttng2.ust.analysis.memory">
+         </analysisId>
+      </output>
+   </extension>
+</plugin>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.ui/pom.xml b/lttng/org.eclipse.tracecompass.lttng2.ust.ui/pom.xml
new file mode 100644 (file)
index 0000000..89a51d5
--- /dev/null
@@ -0,0 +1,36 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+   Copyright (C) 2011, 2013 Red Hat Inc., 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
+-->
+<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>
+    <artifactId>org.eclipse.tracecompass.lttng-parent</artifactId>
+    <groupId>org.eclipse.tracecompass</groupId>
+    <version>1.0.0-SNAPSHOT</version>
+  </parent>
+
+  <artifactId>org.eclipse.tracecompass.lttng2.ust.ui</artifactId>
+  <version>1.0.0-SNAPSHOT</version>
+  <packaging>eclipse-plugin</packaging>
+
+  <name>Trace Compass LTTng Userspace Tracer Analysis UI Plug-in</name>
+
+ <build>
+    <plugins>
+      <plugin>
+        <groupId>org.eclipse.tycho</groupId>
+        <artifactId>tycho-source-plugin</artifactId>
+      </plugin>
+    </plugins>
+  </build>
+
+  <groupId>org.eclipse.tracecompass</groupId>
+</project>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.ui/src/org/eclipse/tracecompass/internal/lttng2/ust/ui/Activator.java b/lttng/org.eclipse.tracecompass.lttng2.ust.ui/src/org/eclipse/tracecompass/internal/lttng2/ust/ui/Activator.java
new file mode 100644 (file)
index 0000000..ba48a04
--- /dev/null
@@ -0,0 +1,184 @@
+/*******************************************************************************
+ * Copyright (c) 2013, 2015 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:
+ *   Alexandre Montplaisir - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.ust.ui;
+
+import org.eclipse.core.runtime.IStatus;
+import org.eclipse.core.runtime.Status;
+import org.eclipse.jface.resource.ImageDescriptor;
+import org.eclipse.jface.resource.ImageRegistry;
+import org.eclipse.swt.graphics.Image;
+import org.eclipse.ui.plugin.AbstractUIPlugin;
+import org.osgi.framework.BundleContext;
+
+/**
+ * The activator class controls the plug-in life cycle
+ */
+public class Activator extends AbstractUIPlugin {
+
+    // ------------------------------------------------------------------------
+    // Attributes
+    // ------------------------------------------------------------------------
+
+    /**
+     *  The plug-in ID
+     */
+    public static final String PLUGIN_ID = "org.eclipse.tracecompass.lttng2.ust.ui"; //$NON-NLS-1$
+
+    /**
+     *  The shared instance
+     */
+    private static Activator plugin;
+
+    // ------------------------------------------------------------------------
+    // Constructors
+    // ------------------------------------------------------------------------
+
+    /**
+     * The constructor
+     */
+    public Activator() {
+    }
+
+    // ------------------------------------------------------------------------
+    // Accessors
+    // ------------------------------------------------------------------------
+
+    /**
+     * Returns the shared instance
+     *
+     * @return the shared instance
+     */
+    public static Activator getDefault() {
+        return plugin;
+    }
+
+    // ------------------------------------------------------------------------
+    // AbstractUIPlugin
+    // ------------------------------------------------------------------------
+
+    @Override
+    public void start(BundleContext context) throws Exception {
+        super.start(context);
+        plugin = this;
+    }
+
+    @Override
+    public void stop(BundleContext context) throws Exception {
+        plugin = null;
+        super.stop(context);
+    }
+
+    @Override
+    protected void initializeImageRegistry(ImageRegistry reg) {
+    }
+
+    // ------------------------------------------------------------------------
+    // Operations
+    // ------------------------------------------------------------------------
+
+    /**
+     * Get the image object from a given path
+     *
+     * @param path
+     *            The path to the image file
+     * @return The Image object
+     */
+    public Image getImageFromPath(String path) {
+        return getImageDescripterFromPath(path).createImage();
+    }
+
+    /**
+     * Get the ImageDescriptor from a given path
+     *
+     * @param path
+     *            The path to the image file
+     * @return The ImageDescriptor object
+     */
+    public ImageDescriptor getImageDescripterFromPath(String path) {
+        return AbstractUIPlugin.imageDescriptorFromPlugin(PLUGIN_ID, path);
+    }
+
+    /**
+     * Get the Image from a registry
+     *
+     * @param path
+     *            The path to the image registry
+     * @return The Image object
+     */
+    public Image getImageFromImageRegistry(String path) {
+        Image icon = getImageRegistry().get(path);
+        if (icon == null) {
+            icon = getImageDescripterFromPath(path).createImage();
+            plugin.getImageRegistry().put(path, icon);
+        }
+        return icon;
+    }
+
+    /**
+     * Logs a message with severity INFO in the runtime log of the plug-in.
+     *
+     * @param message A message to log
+     */
+    public void logInfo(String message) {
+        getLog().log(new Status(IStatus.INFO, PLUGIN_ID, message));
+    }
+
+    /**
+     * Logs a message and exception with severity INFO in the runtime log of the plug-in.
+     *
+     * @param message A message to log
+     * @param exception A exception to log
+     */
+    public void logInfo(String message, Throwable exception) {
+        getLog().log(new Status(IStatus.INFO, PLUGIN_ID, message, exception));
+    }
+
+    /**
+     * Logs a message and exception with severity WARNING in the runtime log of the plug-in.
+     *
+     * @param message A message to log
+     */
+    public void logWarning(String message) {
+        getLog().log(new Status(IStatus.WARNING, PLUGIN_ID, message));
+    }
+
+    /**
+     * Logs a message and exception with severity WARNING in the runtime log of the plug-in.
+     *
+     * @param message A message to log
+     * @param exception A exception to log
+     */
+    public void logWarning(String message, Throwable exception) {
+        getLog().log(new Status(IStatus.WARNING, PLUGIN_ID, message, exception));
+    }
+
+    /**
+     * Logs a message and exception with severity ERROR in the runtime log of the plug-in.
+     *
+     * @param message A message to log
+     */
+    public void logError(String message) {
+        getLog().log(new Status(IStatus.ERROR, PLUGIN_ID, message));
+    }
+
+    /**
+     * Logs a message and exception with severity ERROR in the runtime log of the plug-in.
+     *
+     * @param message A message to log
+     * @param exception A exception to log
+     */
+    public void logError(String message, Throwable exception) {
+        getLog().log(new Status(IStatus.ERROR, PLUGIN_ID, message, exception));
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.ui/src/org/eclipse/tracecompass/internal/lttng2/ust/ui/views/memusage/MemoryUsageView.java b/lttng/org.eclipse.tracecompass.lttng2.ust.ui/src/org/eclipse/tracecompass/internal/lttng2/ust/ui/views/memusage/MemoryUsageView.java
new file mode 100644 (file)
index 0000000..5f52380
--- /dev/null
@@ -0,0 +1,40 @@
+/**********************************************************************
+ * Copyright (c) 2014, 2015 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:
+ *   Matthew Khouzam - Initial API and implementation
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.ust.ui.views.memusage;
+
+import org.eclipse.swt.widgets.Composite;
+import org.eclipse.tracecompass.tmf.ui.viewers.xycharts.TmfXYChartViewer;
+import org.eclipse.tracecompass.tmf.ui.views.TmfChartView;
+
+/**
+ * Memory Usage View
+ *
+ * @author Matthew Khouzam
+ */
+public class MemoryUsageView extends TmfChartView {
+
+    /** ID string */
+    public static final String ID = "org.eclipse.linuxtools.lttng2.ust.memoryusage"; //$NON-NLS-1$
+
+    /**
+     * Constructor
+     */
+    public MemoryUsageView() {
+        super(Messages.MemoryUsageView_Title);
+    }
+
+    @Override
+    protected TmfXYChartViewer createChartViewer(Composite parent) {
+        return new MemoryUsageViewer(parent);
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.ui/src/org/eclipse/tracecompass/internal/lttng2/ust/ui/views/memusage/MemoryUsageViewer.java b/lttng/org.eclipse.tracecompass.lttng2.ust.ui/src/org/eclipse/tracecompass/internal/lttng2/ust/ui/views/memusage/MemoryUsageViewer.java
new file mode 100644 (file)
index 0000000..a1694bb
--- /dev/null
@@ -0,0 +1,163 @@
+/**********************************************************************
+ * Copyright (c) 2014 Ericsson, École Polytechnique de Montréal
+ *
+ * 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:
+ *   Bernd Hufmann - Initial API and implementation
+ *   Geneviève Bastien - Create and use base class for XY plots
+ **********************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.ust.ui.views.memusage;
+
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.swt.widgets.Composite;
+import org.eclipse.tracecompass.internal.lttng2.ust.core.analysis.memory.UstMemoryStrings;
+import org.eclipse.tracecompass.internal.tmf.core.Activator;
+import org.eclipse.tracecompass.lttng2.ust.core.analysis.memory.UstMemoryAnalysisModule;
+import org.eclipse.tracecompass.statesystem.core.ITmfStateSystem;
+import org.eclipse.tracecompass.statesystem.core.exceptions.AttributeNotFoundException;
+import org.eclipse.tracecompass.statesystem.core.exceptions.StateSystemDisposedException;
+import org.eclipse.tracecompass.statesystem.core.exceptions.StateValueTypeException;
+import org.eclipse.tracecompass.statesystem.core.exceptions.TimeRangeException;
+import org.eclipse.tracecompass.statesystem.core.statevalue.ITmfStateValue;
+import org.eclipse.tracecompass.tmf.core.statesystem.TmfStateSystemAnalysisModule;
+import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace;
+import org.eclipse.tracecompass.tmf.core.trace.TmfTraceUtils;
+import org.eclipse.tracecompass.tmf.ui.viewers.xycharts.linecharts.TmfCommonXLineChartViewer;
+
+/**
+ * Memory usage view
+ *
+ * @author Matthew Khouzam
+ */
+@SuppressWarnings("restriction")
+public class MemoryUsageViewer extends TmfCommonXLineChartViewer {
+
+    private TmfStateSystemAnalysisModule fModule = null;
+
+    private final Map<Integer, double[]> fYValues = new HashMap<>();
+    private final Map<Integer, Integer> fMemoryQuarks = new HashMap<>();
+    private final Map<Integer, String> fSeriesName = new HashMap<>();
+
+    private static final int BYTES_TO_KB = 1024;
+
+    // Timeout between updates in the updateData thread
+    private static final long BUILD_UPDATE_TIMEOUT = 500;
+
+    /**
+     * Constructor
+     *
+     * @param parent
+     *            parent view
+     */
+    public MemoryUsageViewer(Composite parent) {
+        super(parent, Messages.MemoryUsageViewer_Title, Messages.MemoryUsageViewer_XAxis, Messages.MemoryUsageViewer_YAxis);
+    }
+
+    @Override
+    protected void initializeDataSource() {
+        ITmfTrace trace = getTrace();
+        if (trace != null) {
+            fModule = TmfTraceUtils.getAnalysisModuleOfClass(trace, TmfStateSystemAnalysisModule.class, UstMemoryAnalysisModule.ID);
+            if (fModule == null) {
+                return;
+            }
+            fModule.schedule();
+        }
+    }
+
+    @Override
+    protected void updateData(long start, long end, int nb, IProgressMonitor monitor) {
+        try {
+            if (getTrace() == null || fModule == null) {
+                return;
+            }
+            fModule.waitForInitialization();
+            ITmfStateSystem ss = fModule.getStateSystem();
+            /* Don't wait for the module completion, when it's ready, we'll know */
+            if (ss == null) {
+                return;
+            }
+
+            double[] xvalues = getXAxis(start, end, nb);
+            setXAxis(xvalues);
+
+            boolean complete = false;
+            long currentEnd = start;
+
+            while (!complete && currentEnd < end) {
+                if (monitor.isCanceled()) {
+                    return;
+                }
+                complete = ss.waitUntilBuilt(BUILD_UPDATE_TIMEOUT);
+                currentEnd = ss.getCurrentEndTime();
+                List<Integer> tidQuarks = ss.getSubAttributes(-1, false);
+                long traceStart = getStartTime();
+                long traceEnd = getEndTime();
+                long offset = this.getTimeOffset();
+
+                /* Initialize quarks and series names */
+                for (int quark : tidQuarks) {
+                    fYValues.put(quark, new double[xvalues.length]);
+                    fMemoryQuarks.put(quark, ss.getQuarkRelative(quark, UstMemoryStrings.UST_MEMORY_MEMORY_ATTRIBUTE));
+                    int procNameQuark = ss.getQuarkRelative(quark, UstMemoryStrings.UST_MEMORY_PROCNAME_ATTRIBUTE);
+                    try {
+                        ITmfStateValue procnameValue = ss.querySingleState(start, procNameQuark).getStateValue();
+                        String procname = ""; //$NON-NLS-1$
+                        if (!procnameValue.isNull()) {
+                            procname = procnameValue.unboxStr();
+                        }
+                        fSeriesName.put(quark, new String(procname + ' ' + '(' + ss.getAttributeName(quark) + ')').trim());
+                    } catch (TimeRangeException e) {
+                        fSeriesName.put(quark, '(' + ss.getAttributeName(quark) + ')');
+                    }
+                }
+
+                /*
+                 * TODO: It should only show active threads in the time range.
+                 * If a tid does not have any memory value (only 1 interval in
+                 * the time range with value null or 0), then its series should
+                 * not be displayed.
+                 */
+                double yvalue = 0.0;
+                for (int i = 0; i < xvalues.length; i++) {
+                    if (monitor.isCanceled()) {
+                        return;
+                    }
+                    double x = xvalues[i];
+                    long time = (long) x + offset;
+                    // make sure that time is in the trace range after double to
+                    // long conversion
+                    time = time < traceStart ? traceStart : time;
+                    time = time > traceEnd ? traceEnd : time;
+
+                    for (int quark : tidQuarks) {
+                        try {
+                            yvalue = ss.querySingleState(time, fMemoryQuarks.get(quark)).getStateValue().unboxLong() / BYTES_TO_KB;
+                            fYValues.get(quark)[i] = yvalue;
+                        } catch (TimeRangeException e) {
+                            fYValues.get(quark)[i] = 0;
+                        }
+                    }
+                }
+                for (int quark : tidQuarks) {
+                    setSeries(fSeriesName.get(quark), fYValues.get(quark));
+                }
+                updateDisplay();
+            }
+        } catch (AttributeNotFoundException | StateValueTypeException e) {
+            Activator.logError("Error updating the data of the Memory usage view", e); //$NON-NLS-1$
+        } catch (StateSystemDisposedException e) {
+            /* State system is closing down, no point continuing */
+        }
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.ui/src/org/eclipse/tracecompass/internal/lttng2/ust/ui/views/memusage/Messages.java b/lttng/org.eclipse.tracecompass.lttng2.ust.ui/src/org/eclipse/tracecompass/internal/lttng2/ust/ui/views/memusage/Messages.java
new file mode 100644 (file)
index 0000000..3e3c56d
--- /dev/null
@@ -0,0 +1,40 @@
+/*******************************************************************************
+ * Copyright (c) 2014 École Polytechnique de Montréal
+ *
+ * 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:
+ *   Geneviève Bastien - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.internal.lttng2.ust.ui.views.memusage;
+
+import org.eclipse.osgi.util.NLS;
+
+/**
+ * Translatable strings for the ust memory usage view
+ *
+ * @author Geneviève Bastien
+ */
+public class Messages extends NLS {
+    private static final String BUNDLE_NAME = "org.eclipse.tracecompass.internal.lttng2.ust.ui.views.memusage.messages"; //$NON-NLS-1$
+    /** Title of the memory usage xy view */
+    public static String MemoryUsageView_Title;
+
+    /** Title of the memory viewer */
+    public static String MemoryUsageViewer_Title;
+    /** X axis caption */
+    public static String MemoryUsageViewer_XAxis;
+    /** Y axis caption */
+    public static String MemoryUsageViewer_YAxis;
+    static {
+        // initialize resource bundle
+        NLS.initializeMessages(BUNDLE_NAME, Messages.class);
+    }
+
+    private Messages() {
+    }
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.ui/src/org/eclipse/tracecompass/internal/lttng2/ust/ui/views/memusage/messages.properties b/lttng/org.eclipse.tracecompass.lttng2.ust.ui/src/org/eclipse/tracecompass/internal/lttng2/ust/ui/views/memusage/messages.properties
new file mode 100644 (file)
index 0000000..2de2271
--- /dev/null
@@ -0,0 +1,15 @@
+###############################################################################
+# Copyright (c) 2014 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:
+#    Ericsson - Initial API and implementation
+###############################################################################
+MemoryUsageView_Title=Memory Usage
+MemoryUsageViewer_Title=Memory Allocation vs Time
+MemoryUsageViewer_XAxis=Time
+MemoryUsageViewer_YAxis=Usage (KB)
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.ui/src/org/eclipse/tracecompass/lttng2/ust/ui/analysis/callstack/LttngUstCallStackAnalysis.java b/lttng/org.eclipse.tracecompass.lttng2.ust.ui/src/org/eclipse/tracecompass/lttng2/ust/ui/analysis/callstack/LttngUstCallStackAnalysis.java
new file mode 100644 (file)
index 0000000..6078caa
--- /dev/null
@@ -0,0 +1,53 @@
+/*******************************************************************************
+ * Copyright (c) 2014, 2015 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:
+ *   Alexandre Montplaisir - Initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.lttng2.ust.ui.analysis.callstack;
+
+import static org.eclipse.tracecompass.common.core.NonNullUtils.checkNotNull;
+
+import org.eclipse.tracecompass.internal.lttng2.ust.core.callstack.LttngUstCallStackProvider;
+import org.eclipse.tracecompass.lttng2.ust.core.trace.LttngUstTrace;
+import org.eclipse.tracecompass.tmf.core.exceptions.TmfAnalysisException;
+import org.eclipse.tracecompass.tmf.core.statesystem.ITmfStateProvider;
+import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace;
+import org.eclipse.tracecompass.tmf.ui.views.callstack.AbstractCallStackAnalysis;
+
+/**
+ * Call-stack analysis to populate the TMF CallStack View from UST cyg-profile
+ * events.
+ *
+ * @author Alexandre Montplaisir
+ */
+public class LttngUstCallStackAnalysis extends AbstractCallStackAnalysis {
+
+    /**
+     * @since 1.0
+     */
+    @Override
+    public boolean setTrace(ITmfTrace trace) throws TmfAnalysisException {
+        if (!(trace instanceof LttngUstTrace)) {
+            return false;
+        }
+        return super.setTrace(trace);
+    }
+
+    @Override
+    protected LttngUstTrace getTrace() {
+        return (LttngUstTrace) super.getTrace();
+    }
+
+    @Override
+    protected ITmfStateProvider createStateProvider() {
+        return new LttngUstCallStackProvider(checkNotNull(getTrace()));
+    }
+
+}
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust/.project b/lttng/org.eclipse.tracecompass.lttng2.ust/.project
new file mode 100644 (file)
index 0000000..d13cfd5
--- /dev/null
@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+       <name>org.eclipse.tracecompass.lttng2.ust</name>
+       <comment></comment>
+       <projects>
+       </projects>
+       <buildSpec>
+               <buildCommand>
+                       <name>org.eclipse.pde.FeatureBuilder</name>
+                       <arguments>
+                       </arguments>
+               </buildCommand>
+       </buildSpec>
+       <natures>
+               <nature>org.eclipse.pde.FeatureNature</nature>
+       </natures>
+</projectDescription>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust/.settings/org.eclipse.core.resources.prefs b/lttng/org.eclipse.tracecompass.lttng2.ust/.settings/org.eclipse.core.resources.prefs
new file mode 100644 (file)
index 0000000..99f26c0
--- /dev/null
@@ -0,0 +1,2 @@
+eclipse.preferences.version=1
+encoding/<project>=UTF-8
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust/.settings/org.eclipse.core.runtime.prefs b/lttng/org.eclipse.tracecompass.lttng2.ust/.settings/org.eclipse.core.runtime.prefs
new file mode 100644 (file)
index 0000000..5a0ad22
--- /dev/null
@@ -0,0 +1,2 @@
+eclipse.preferences.version=1
+line.separator=\n
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust/build.properties b/lttng/org.eclipse.tracecompass.lttng2.ust/build.properties
new file mode 100644 (file)
index 0000000..475ce21
--- /dev/null
@@ -0,0 +1,16 @@
+###############################################################################
+# Copyright (c) 2013, 2015 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:
+#     Ericsson - Initial API and implementation
+###############################################################################
+
+bin.includes = feature.xml,\
+               feature.properties,\
+               p2.inf
+src.includes = sourceTemplateFeature/p2.inf
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust/feature.properties b/lttng/org.eclipse.tracecompass.lttng2.ust/feature.properties
new file mode 100644 (file)
index 0000000..6d02a5e
--- /dev/null
@@ -0,0 +1,22 @@
+###############################################################################
+# Copyright (c) 2009, 2014 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:
+#     Ericsson - Initial API and implementation
+###############################################################################
+
+featureName=LTTng Userspace Analysis
+
+description=Plug-ins to integrate LTTng-UST analysis tools into the workbench. \
+Includes the LTTng (Linux Tracing Toolkit), TMF (Tracing and Monitoring Framework) \
+and CTF (Common Trace Format) features.
+
+featureProvider=Eclipse Trace Compass
+
+copyright=Copyright 2013 Ericsson
+
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust/feature.xml b/lttng/org.eclipse.tracecompass.lttng2.ust/feature.xml
new file mode 100644 (file)
index 0000000..ebc4015
--- /dev/null
@@ -0,0 +1,64 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- For PDE build, remove "ws" and "arch" -->
+<feature
+      id="org.eclipse.tracecompass.lttng2.ust"
+      label="%featureName"
+      version="1.0.0.qualifier"
+      provider-name="%featureProvider"
+      license-feature="org.eclipse.license"
+      license-feature-version="0.0.0">
+
+   <description>
+      %description
+   </description>
+
+   <copyright>
+      %copyright
+   </copyright>
+
+   <license url="%licenseURL">
+      %license
+   </license>
+
+   <includes
+         id="org.eclipse.tracecompass.lttng2.control"
+         version="0.0.0"
+         name="Linux Tracing Toolkit next generation (LTTng)"/>
+
+   <includes
+         id="org.eclipse.tracecompass.tmf.ctf"
+         version="0.0.0"
+         name="CTF Support for TMF"/>
+
+   <requires>
+      <import plugin="org.eclipse.core.runtime"/>
+      <import plugin="org.eclipse.core.resources"/>
+      <import plugin="org.eclipse.tracecompass.ctf.core" version="1.0.0" match="greaterOrEqual"/>
+      <import plugin="org.eclipse.tracecompass.tmf.core" version="1.0.0" match="greaterOrEqual"/>
+      <import plugin="org.eclipse.ui"/>
+      <import plugin="org.eclipse.ui.ide"/>
+      <import plugin="org.eclipse.tracecompass.tmf.ui" version="1.0.0" match="greaterOrEqual"/>
+      <import plugin="org.eclipse.help"/>
+   </requires>
+
+   <plugin
+         id="org.eclipse.tracecompass.lttng2.ust.core"
+         download-size="0"
+         install-size="0"
+         version="0.0.0"
+         unpack="false"/>
+
+   <plugin
+         id="org.eclipse.tracecompass.lttng2.ust.ui"
+         download-size="0"
+         install-size="0"
+         version="0.0.0"
+         unpack="false"/>
+
+   <plugin
+         id="org.eclipse.tracecompass.doc.user"
+         download-size="0"
+         install-size="0"
+         version="0.0.0"/>
+
+</feature>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust/p2.inf b/lttng/org.eclipse.tracecompass.lttng2.ust/p2.inf
new file mode 100644 (file)
index 0000000..cdae743
--- /dev/null
@@ -0,0 +1 @@
+update.matchExp=providedCapabilities.exists(pc | pc.namespace == 'org.eclipse.equinox.p2.iu' && (pc.name == 'org.eclipse.linuxtools.lttng2.ust.feature.group' || pc.name == 'org.eclipse.tracecompass.lttng2.ust.feature.group'))
\ No newline at end of file
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust/pom.xml b/lttng/org.eclipse.tracecompass.lttng2.ust/pom.xml
new file mode 100644 (file)
index 0000000..8bab38b
--- /dev/null
@@ -0,0 +1,63 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+   Copyright (C) 2011, 2013 Red Hat Inc., 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
+-->
+<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>
+    <artifactId>org.eclipse.tracecompass.lttng-parent</artifactId>
+    <groupId>org.eclipse.tracecompass</groupId>
+    <version>1.0.0-SNAPSHOT</version>
+  </parent>
+
+  <artifactId>org.eclipse.tracecompass.lttng2.ust</artifactId>
+  <groupId>org.eclipse.tracecompass</groupId>
+  <version>1.0.0-SNAPSHOT</version>
+  <packaging>eclipse-feature</packaging>
+
+  <name>Trace Compass LTTng Userspace Tracer Analysis Feature</name>
+
+  <build>
+    <plugins>
+      <plugin>
+        <groupId>org.eclipse.tycho.extras</groupId>
+        <artifactId>tycho-source-feature-plugin</artifactId>
+        <executions>
+          <execution>
+            <id>source-feature</id>
+            <phase>package</phase>
+            <goals>
+              <goal>source-feature</goal>
+            </goals>
+            <configuration>
+              <excludes>
+                <plugin id="org.eclipse.tracecompass.doc.user"/>
+              </excludes>
+            </configuration>
+          </execution>
+        </executions>
+      </plugin>
+      <plugin>
+        <groupId>org.eclipse.tycho</groupId>
+        <artifactId>tycho-p2-plugin</artifactId>
+        <version>${tycho-version}</version>
+        <executions>
+          <execution>
+            <id>attached-p2-metadata</id>
+            <phase>package</phase>
+            <goals>
+              <goal>p2-metadata</goal>
+            </goals>
+          </execution>
+        </executions>
+      </plugin>
+    </plugins>
+  </build>
+</project>
diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust/sourceTemplateFeature/p2.inf b/lttng/org.eclipse.tracecompass.lttng2.ust/sourceTemplateFeature/p2.inf
new file mode 100644 (file)
index 0000000..6deed6f
--- /dev/null
@@ -0,0 +1 @@
+update.matchExp=providedCapabilities.exists(pc | pc.namespace == 'org.eclipse.equinox.p2.iu' && (pc.name == 'org.eclipse.linuxtools.lttng2.ust.source.feature.group' || pc.name == 'org.eclipse.tracecompass.lttng2.ust.source.feature.group'))
\ No newline at end of file
diff --git a/lttng/pom.xml b/lttng/pom.xml
new file mode 100644 (file)
index 0000000..75e1ae7
--- /dev/null
@@ -0,0 +1,53 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+   Copyright (C) 2015, Ericsson, EfficiOS Inc. and others
+
+   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
+-->
+
+<project xmlns="http://maven.apache.org/POM/4.0.0"
+    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+    xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+  <modelVersion>4.0.0</modelVersion>
+
+  <prerequisites>
+    <maven>3.0</maven>
+  </prerequisites>
+
+  <parent>
+    <artifactId>org.eclipse.tracecompass</artifactId>
+    <groupId>org.eclipse.tracecompass</groupId>
+    <version>1.0.0-SNAPSHOT</version>
+  </parent>
+
+  <artifactId>org.eclipse.tracecompass.lttng-parent</artifactId>
+  <groupId>org.eclipse.tracecompass</groupId>
+  <version>1.0.0-SNAPSHOT</version>
+  <packaging>pom</packaging>
+
+  <name>Trace Compass LTTng Support Parent</name>
+
+  <modules>
+    <module>org.eclipse.tracecompass.lttng2.control</module>
+    <module>org.eclipse.tracecompass.lttng2.control.core</module>
+    <module>org.eclipse.tracecompass.lttng2.control.core.tests</module>
+    <module>org.eclipse.tracecompass.lttng2.control.ui</module>
+    <module>org.eclipse.tracecompass.lttng2.control.ui.tests</module>
+
+    <module>org.eclipse.tracecompass.lttng2.kernel</module>
+    <module>org.eclipse.tracecompass.lttng2.kernel.core</module>
+    <module>org.eclipse.tracecompass.lttng2.kernel.core.tests</module>
+    <module>org.eclipse.tracecompass.lttng2.kernel.ui</module>
+    <module>org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests</module>
+
+    <module>org.eclipse.tracecompass.lttng2.ust</module>
+    <module>org.eclipse.tracecompass.lttng2.ust.core</module>
+    <module>org.eclipse.tracecompass.lttng2.ust.core.tests</module>
+    <module>org.eclipse.tracecompass.lttng2.ust.ui</module>
+    <module>org.eclipse.tracecompass.lttng2.ust.ui.tests</module>
+  </modules>
+
+</project>
diff --git a/org.eclipse.tracecompass.lttng2.control.core.tests/.classpath b/org.eclipse.tracecompass.lttng2.control.core.tests/.classpath
deleted file mode 100644 (file)
index 098194c..0000000
+++ /dev/null
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
-       <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7"/>
-       <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
-       <classpathentry kind="src" path="src"/>
-       <classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/org.eclipse.tracecompass.lttng2.control.core.tests/.project b/org.eclipse.tracecompass.lttng2.control.core.tests/.project
deleted file mode 100644 (file)
index 96d73f6..0000000
+++ /dev/null
@@ -1,34 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
-       <name>org.eclipse.tracecompass.lttng2.control.core.tests</name>
-       <comment></comment>
-       <projects>
-       </projects>
-       <buildSpec>
-               <buildCommand>
-                       <name>org.eclipse.jdt.core.javabuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-               <buildCommand>
-                       <name>org.eclipse.pde.ManifestBuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-               <buildCommand>
-                       <name>org.eclipse.pde.SchemaBuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-               <buildCommand>
-                       <name>org.eclipse.pde.api.tools.apiAnalysisBuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-       </buildSpec>
-       <natures>
-               <nature>org.eclipse.pde.PluginNature</nature>
-               <nature>org.eclipse.jdt.core.javanature</nature>
-               <nature>org.eclipse.pde.api.tools.apiAnalysisNature</nature>
-       </natures>
-</projectDescription>
diff --git a/org.eclipse.tracecompass.lttng2.control.core.tests/.settings/org.eclipse.core.resources.prefs b/org.eclipse.tracecompass.lttng2.control.core.tests/.settings/org.eclipse.core.resources.prefs
deleted file mode 100644 (file)
index 99f26c0..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-eclipse.preferences.version=1
-encoding/<project>=UTF-8
diff --git a/org.eclipse.tracecompass.lttng2.control.core.tests/.settings/org.eclipse.core.runtime.prefs b/org.eclipse.tracecompass.lttng2.control.core.tests/.settings/org.eclipse.core.runtime.prefs
deleted file mode 100644 (file)
index 5a0ad22..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-eclipse.preferences.version=1
-line.separator=\n
diff --git a/org.eclipse.tracecompass.lttng2.control.core.tests/.settings/org.eclipse.jdt.core.prefs b/org.eclipse.tracecompass.lttng2.control.core.tests/.settings/org.eclipse.jdt.core.prefs
deleted file mode 100644 (file)
index 0409c61..0000000
+++ /dev/null
@@ -1,403 +0,0 @@
-eclipse.preferences.version=1
-org.eclipse.jdt.core.codeComplete.argumentPrefixes=
-org.eclipse.jdt.core.codeComplete.argumentSuffixes=
-org.eclipse.jdt.core.codeComplete.fieldPrefixes=f
-org.eclipse.jdt.core.codeComplete.fieldSuffixes=
-org.eclipse.jdt.core.codeComplete.localPrefixes=
-org.eclipse.jdt.core.codeComplete.localSuffixes=
-org.eclipse.jdt.core.codeComplete.staticFieldPrefixes=
-org.eclipse.jdt.core.codeComplete.staticFieldSuffixes=
-org.eclipse.jdt.core.codeComplete.staticFinalFieldPrefixes=
-org.eclipse.jdt.core.codeComplete.staticFinalFieldSuffixes=
-org.eclipse.jdt.core.compiler.annotation.inheritNullAnnotations=enabled
-org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore
-org.eclipse.jdt.core.compiler.annotation.nonnull=org.eclipse.jdt.annotation.NonNull
-org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=org.eclipse.jdt.annotation.NonNullByDefault
-org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nullable
-org.eclipse.jdt.core.compiler.annotation.nullanalysis=enabled
-org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
-org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
-org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
-org.eclipse.jdt.core.compiler.compliance=1.7
-org.eclipse.jdt.core.compiler.debug.lineNumber=generate
-org.eclipse.jdt.core.compiler.debug.localVariable=generate
-org.eclipse.jdt.core.compiler.debug.sourceFile=generate
-org.eclipse.jdt.core.compiler.doc.comment.support=enabled
-org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=error
-org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
-org.eclipse.jdt.core.compiler.problem.autoboxing=ignore
-org.eclipse.jdt.core.compiler.problem.comparingIdentical=error
-org.eclipse.jdt.core.compiler.problem.deadCode=error
-org.eclipse.jdt.core.compiler.problem.deprecation=error
-org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled
-org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=enabled
-org.eclipse.jdt.core.compiler.problem.discouragedReference=error
-org.eclipse.jdt.core.compiler.problem.emptyStatement=error
-org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
-org.eclipse.jdt.core.compiler.problem.explicitlyClosedAutoCloseable=error
-org.eclipse.jdt.core.compiler.problem.fallthroughCase=error
-org.eclipse.jdt.core.compiler.problem.fatalOptionalError=disabled
-org.eclipse.jdt.core.compiler.problem.fieldHiding=error
-org.eclipse.jdt.core.compiler.problem.finalParameterBound=error
-org.eclipse.jdt.core.compiler.problem.finallyBlockNotCompletingNormally=error
-org.eclipse.jdt.core.compiler.problem.forbiddenReference=error
-org.eclipse.jdt.core.compiler.problem.hiddenCatchBlock=error
-org.eclipse.jdt.core.compiler.problem.includeNullInfoFromAsserts=disabled
-org.eclipse.jdt.core.compiler.problem.incompatibleNonInheritedInterfaceMethod=error
-org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch=error
-org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=error
-org.eclipse.jdt.core.compiler.problem.invalidJavadoc=warning
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTags=enabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsDeprecatedRef=enabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsNotVisibleRef=enabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsVisibility=protected
-org.eclipse.jdt.core.compiler.problem.localVariableHiding=error
-org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=error
-org.eclipse.jdt.core.compiler.problem.missingDefaultCase=error
-org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=error
-org.eclipse.jdt.core.compiler.problem.missingEnumCaseDespiteDefault=enabled
-org.eclipse.jdt.core.compiler.problem.missingHashCodeMethod=error
-org.eclipse.jdt.core.compiler.problem.missingJavadocComments=warning
-org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsOverriding=disabled
-org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsVisibility=protected
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagDescription=all_standard_tags
-org.eclipse.jdt.core.compiler.problem.missingJavadocTags=warning
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagsMethodTypeParameters=disabled
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagsOverriding=disabled
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagsVisibility=protected
-org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotation=error
-org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotationForInterfaceMethodImplementation=enabled
-org.eclipse.jdt.core.compiler.problem.missingSerialVersion=error
-org.eclipse.jdt.core.compiler.problem.missingSynchronizedOnInheritedMethod=error
-org.eclipse.jdt.core.compiler.problem.noEffectAssignment=error
-org.eclipse.jdt.core.compiler.problem.noImplicitStringConversion=error
-org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=ignore
-org.eclipse.jdt.core.compiler.problem.nonnullParameterAnnotationDropped=warning
-org.eclipse.jdt.core.compiler.problem.nullAnnotationInferenceConflict=warning
-org.eclipse.jdt.core.compiler.problem.nullReference=error
-org.eclipse.jdt.core.compiler.problem.nullSpecViolation=error
-org.eclipse.jdt.core.compiler.problem.nullUncheckedConversion=warning
-org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=error
-org.eclipse.jdt.core.compiler.problem.parameterAssignment=error
-org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=error
-org.eclipse.jdt.core.compiler.problem.potentialNullReference=error
-org.eclipse.jdt.core.compiler.problem.potentiallyUnclosedCloseable=warning
-org.eclipse.jdt.core.compiler.problem.rawTypeReference=error
-org.eclipse.jdt.core.compiler.problem.redundantNullAnnotation=warning
-org.eclipse.jdt.core.compiler.problem.redundantNullCheck=error
-org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=error
-org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=error
-org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore
-org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=error
-org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled
-org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=error
-org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=disabled
-org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled
-org.eclipse.jdt.core.compiler.problem.syntacticNullAnalysisForFields=enabled
-org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=ignore
-org.eclipse.jdt.core.compiler.problem.typeParameterHiding=error
-org.eclipse.jdt.core.compiler.problem.unavoidableGenericTypeProblems=disabled
-org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=error
-org.eclipse.jdt.core.compiler.problem.unclosedCloseable=error
-org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=ignore
-org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=error
-org.eclipse.jdt.core.compiler.problem.unnecessaryElse=error
-org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=error
-org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=error
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionExemptExceptionAndThrowable=disabled
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionIncludeDocCommentReference=disabled
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverriding=disabled
-org.eclipse.jdt.core.compiler.problem.unusedImport=error
-org.eclipse.jdt.core.compiler.problem.unusedLabel=error
-org.eclipse.jdt.core.compiler.problem.unusedLocal=error
-org.eclipse.jdt.core.compiler.problem.unusedObjectAllocation=ignore
-org.eclipse.jdt.core.compiler.problem.unusedParameter=ignore
-org.eclipse.jdt.core.compiler.problem.unusedParameterIncludeDocCommentReference=enabled
-org.eclipse.jdt.core.compiler.problem.unusedParameterWhenImplementingAbstract=disabled
-org.eclipse.jdt.core.compiler.problem.unusedParameterWhenOverridingConcrete=disabled
-org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=error
-org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=ignore
-org.eclipse.jdt.core.compiler.problem.unusedWarningToken=error
-org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=error
-org.eclipse.jdt.core.compiler.source=1.7
-org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_call=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression=16
-org.eclipse.jdt.core.formatter.alignment_for_assignment=0
-org.eclipse.jdt.core.formatter.alignment_for_binary_expression=16
-org.eclipse.jdt.core.formatter.alignment_for_compact_if=16
-org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=80
-org.eclipse.jdt.core.formatter.alignment_for_enum_constants=0
-org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=16
-org.eclipse.jdt.core.formatter.alignment_for_method_declaration=0
-org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16
-org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=80
-org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation=0
-org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_constructor_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_method_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_union_type_in_multicatch=16
-org.eclipse.jdt.core.formatter.blank_lines_after_imports=1
-org.eclipse.jdt.core.formatter.blank_lines_after_package=1
-org.eclipse.jdt.core.formatter.blank_lines_before_field=0
-org.eclipse.jdt.core.formatter.blank_lines_before_first_class_body_declaration=0
-org.eclipse.jdt.core.formatter.blank_lines_before_imports=1
-org.eclipse.jdt.core.formatter.blank_lines_before_member_type=1
-org.eclipse.jdt.core.formatter.blank_lines_before_method=1
-org.eclipse.jdt.core.formatter.blank_lines_before_new_chunk=1
-org.eclipse.jdt.core.formatter.blank_lines_before_package=0
-org.eclipse.jdt.core.formatter.blank_lines_between_import_groups=1
-org.eclipse.jdt.core.formatter.blank_lines_between_type_declarations=1
-org.eclipse.jdt.core.formatter.brace_position_for_annotation_type_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_array_initializer=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_block=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_block_in_case=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_constructor_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_enum_constant=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_enum_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_method_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_switch=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_type_declaration=end_of_line
-org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_block_comment=false
-org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_javadoc_comment=false
-org.eclipse.jdt.core.formatter.comment.format_block_comments=true
-org.eclipse.jdt.core.formatter.comment.format_header=false
-org.eclipse.jdt.core.formatter.comment.format_html=true
-org.eclipse.jdt.core.formatter.comment.format_javadoc_comments=true
-org.eclipse.jdt.core.formatter.comment.format_line_comments=true
-org.eclipse.jdt.core.formatter.comment.format_source_code=true
-org.eclipse.jdt.core.formatter.comment.indent_parameter_description=true
-org.eclipse.jdt.core.formatter.comment.indent_root_tags=true
-org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags=insert
-org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter=insert
-org.eclipse.jdt.core.formatter.comment.line_length=80
-org.eclipse.jdt.core.formatter.comment.new_lines_at_block_boundaries=true
-org.eclipse.jdt.core.formatter.comment.new_lines_at_javadoc_boundaries=true
-org.eclipse.jdt.core.formatter.comment.preserve_white_space_between_code_and_line_comments=false
-org.eclipse.jdt.core.formatter.compact_else_if=true
-org.eclipse.jdt.core.formatter.continuation_indentation=2
-org.eclipse.jdt.core.formatter.continuation_indentation_for_array_initializer=2
-org.eclipse.jdt.core.formatter.disabling_tag=@formatter\:off
-org.eclipse.jdt.core.formatter.enabling_tag=@formatter\:on
-org.eclipse.jdt.core.formatter.format_guardian_clause_on_one_line=false
-org.eclipse.jdt.core.formatter.format_line_comment_starting_on_first_column=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_annotation_declaration_header=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_constant_header=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_declaration_header=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_type_header=true
-org.eclipse.jdt.core.formatter.indent_breaks_compare_to_cases=true
-org.eclipse.jdt.core.formatter.indent_empty_lines=false
-org.eclipse.jdt.core.formatter.indent_statements_compare_to_block=true
-org.eclipse.jdt.core.formatter.indent_statements_compare_to_body=true
-org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_cases=true
-org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_switch=false
-org.eclipse.jdt.core.formatter.indentation.size=4
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_field=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_local_variable=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_method=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_package=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_parameter=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_type=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_label=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_opening_brace_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_at_end_of_file_if_missing=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_finally_in_try_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_while_in_do_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_annotation_declaration=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_anonymous_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_block=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter=insert
-org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_binary_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_paren_in_cast=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_assert=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_case=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_labeled_statement=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_allocation_expression=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_annotation=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_throws=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_constant_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_declarations=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_explicitconstructorcall_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_increments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_inits=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_throws=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_invocation_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_field_declarations=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_local_declarations=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_parameterized_type_reference=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_superinterfaces=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_ellipsis=insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_brace_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_cast=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_catch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_for=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_if=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_parenthesized_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_switch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_synchronized=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_try=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_while=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_try_resources=insert
-org.eclipse.jdt.core.formatter.insert_space_after_unary_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter=insert
-org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_binary_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_brace_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_cast=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_catch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_for=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_if=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_parenthesized_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_switch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_synchronized=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_try=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_while=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_assert=insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_case=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_default=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_labeled_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_throws=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_constant_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_declarations=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_explicitconstructorcall_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_increments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_inits=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_throws=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_invocation_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_field_declarations=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_local_declarations=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_superinterfaces=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_ellipsis=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_annotation_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_anonymous_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_block=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_constructor_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_constant=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_method_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_switch=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation_type_member_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_catch=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_if=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_parenthesized_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_switch=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_synchronized=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_try=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_while=insert
-org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_return=insert
-org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_throw=insert
-org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_semicolon=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_try_resources=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_unary_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_brackets_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_annotation_type_member_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.join_lines_in_comments=true
-org.eclipse.jdt.core.formatter.join_wrapped_lines=false
-org.eclipse.jdt.core.formatter.keep_else_statement_on_same_line=false
-org.eclipse.jdt.core.formatter.keep_empty_array_initializer_on_one_line=false
-org.eclipse.jdt.core.formatter.keep_imple_if_on_one_line=false
-org.eclipse.jdt.core.formatter.keep_then_statement_on_same_line=false
-org.eclipse.jdt.core.formatter.lineSplit=250
-org.eclipse.jdt.core.formatter.never_indent_block_comments_on_first_column=false
-org.eclipse.jdt.core.formatter.never_indent_line_comments_on_first_column=false
-org.eclipse.jdt.core.formatter.number_of_blank_lines_at_beginning_of_method_body=0
-org.eclipse.jdt.core.formatter.number_of_empty_lines_to_preserve=1
-org.eclipse.jdt.core.formatter.put_empty_statement_on_new_line=true
-org.eclipse.jdt.core.formatter.tabulation.char=space
-org.eclipse.jdt.core.formatter.tabulation.size=4
-org.eclipse.jdt.core.formatter.use_on_off_tags=false
-org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false
-org.eclipse.jdt.core.formatter.wrap_before_binary_operator=true
-org.eclipse.jdt.core.formatter.wrap_before_or_operator_multicatch=true
-org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true
diff --git a/org.eclipse.tracecompass.lttng2.control.core.tests/.settings/org.eclipse.jdt.ui.prefs b/org.eclipse.tracecompass.lttng2.control.core.tests/.settings/org.eclipse.jdt.ui.prefs
deleted file mode 100644 (file)
index 232a3fd..0000000
+++ /dev/null
@@ -1,60 +0,0 @@
-eclipse.preferences.version=1
-editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true
-formatter_profile=_tmf-style
-formatter_settings_version=12
-org.eclipse.jdt.ui.exception.name=e
-org.eclipse.jdt.ui.gettersetter.use.is=true
-org.eclipse.jdt.ui.keywordthis=false
-org.eclipse.jdt.ui.overrideannotation=true
-sp_cleanup.add_default_serial_version_id=true
-sp_cleanup.add_generated_serial_version_id=false
-sp_cleanup.add_missing_annotations=false
-sp_cleanup.add_missing_deprecated_annotations=true
-sp_cleanup.add_missing_methods=false
-sp_cleanup.add_missing_nls_tags=false
-sp_cleanup.add_missing_override_annotations=true
-sp_cleanup.add_missing_override_annotations_interface_methods=true
-sp_cleanup.add_serial_version_id=false
-sp_cleanup.always_use_blocks=true
-sp_cleanup.always_use_parentheses_in_expressions=false
-sp_cleanup.always_use_this_for_non_static_field_access=false
-sp_cleanup.always_use_this_for_non_static_method_access=false
-sp_cleanup.convert_to_enhanced_for_loop=false
-sp_cleanup.correct_indentation=false
-sp_cleanup.format_source_code=false
-sp_cleanup.format_source_code_changes_only=false
-sp_cleanup.make_local_variable_final=false
-sp_cleanup.make_parameters_final=false
-sp_cleanup.make_private_fields_final=true
-sp_cleanup.make_type_abstract_if_missing_method=false
-sp_cleanup.make_variable_declarations_final=false
-sp_cleanup.never_use_blocks=false
-sp_cleanup.never_use_parentheses_in_expressions=true
-sp_cleanup.on_save_use_additional_actions=true
-sp_cleanup.organize_imports=false
-sp_cleanup.qualify_static_field_accesses_with_declaring_class=false
-sp_cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=true
-sp_cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=true
-sp_cleanup.qualify_static_member_accesses_with_declaring_class=false
-sp_cleanup.qualify_static_method_accesses_with_declaring_class=false
-sp_cleanup.remove_private_constructors=true
-sp_cleanup.remove_trailing_whitespaces=true
-sp_cleanup.remove_trailing_whitespaces_all=true
-sp_cleanup.remove_trailing_whitespaces_ignore_empty=false
-sp_cleanup.remove_unnecessary_casts=false
-sp_cleanup.remove_unnecessary_nls_tags=false
-sp_cleanup.remove_unused_imports=false
-sp_cleanup.remove_unused_local_variables=false
-sp_cleanup.remove_unused_private_fields=true
-sp_cleanup.remove_unused_private_members=false
-sp_cleanup.remove_unused_private_methods=true
-sp_cleanup.remove_unused_private_types=true
-sp_cleanup.sort_members=false
-sp_cleanup.sort_members_all=false
-sp_cleanup.use_blocks=true
-sp_cleanup.use_blocks_only_for_return_and_throw=false
-sp_cleanup.use_parentheses_in_expressions=false
-sp_cleanup.use_this_for_non_static_field_access=false
-sp_cleanup.use_this_for_non_static_field_access_only_if_necessary=true
-sp_cleanup.use_this_for_non_static_method_access=false
-sp_cleanup.use_this_for_non_static_method_access_only_if_necessary=true
diff --git a/org.eclipse.tracecompass.lttng2.control.core.tests/.settings/org.eclipse.pde.api.tools.prefs b/org.eclipse.tracecompass.lttng2.control.core.tests/.settings/org.eclipse.pde.api.tools.prefs
deleted file mode 100644 (file)
index acc3abd..0000000
+++ /dev/null
@@ -1,97 +0,0 @@
-ANNOTATION_ELEMENT_TYPE_ADDED_METHOD_WITHOUT_DEFAULT_VALUE=Error
-ANNOTATION_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-ANNOTATION_ELEMENT_TYPE_REMOVED_FIELD=Error
-ANNOTATION_ELEMENT_TYPE_REMOVED_METHOD=Error
-ANNOTATION_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_API_TYPE=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_API_TYPE=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_TYPE=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_TYPE=Error
-API_USE_SCAN_FIELD_SEVERITY=Error
-API_USE_SCAN_METHOD_SEVERITY=Error
-API_USE_SCAN_TYPE_SEVERITY=Error
-CLASS_ELEMENT_TYPE_ADDED_METHOD=Error
-CLASS_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
-CLASS_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-CLASS_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
-CLASS_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-CLASS_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
-CLASS_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
-CLASS_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-CLASS_ELEMENT_TYPE_REMOVED_CONSTRUCTOR=Error
-CLASS_ELEMENT_TYPE_REMOVED_FIELD=Error
-CLASS_ELEMENT_TYPE_REMOVED_METHOD=Error
-CLASS_ELEMENT_TYPE_REMOVED_SUPERCLASS=Error
-CLASS_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-CLASS_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-CONSTRUCTOR_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-CONSTRUCTOR_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-CONSTRUCTOR_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
-CONSTRUCTOR_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-ENUM_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
-ENUM_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-ENUM_ELEMENT_TYPE_REMOVED_ENUM_CONSTANT=Error
-ENUM_ELEMENT_TYPE_REMOVED_FIELD=Error
-ENUM_ELEMENT_TYPE_REMOVED_METHOD=Error
-ENUM_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-FIELD_ELEMENT_TYPE_ADDED_VALUE=Error
-FIELD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-FIELD_ELEMENT_TYPE_CHANGED_FINAL_TO_NON_FINAL_STATIC_CONSTANT=Error
-FIELD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
-FIELD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
-FIELD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
-FIELD_ELEMENT_TYPE_CHANGED_TYPE=Error
-FIELD_ELEMENT_TYPE_CHANGED_VALUE=Error
-FIELD_ELEMENT_TYPE_REMOVED_TYPE_ARGUMENT=Error
-FIELD_ELEMENT_TYPE_REMOVED_VALUE=Error
-ILLEGAL_EXTEND=Warning
-ILLEGAL_IMPLEMENT=Warning
-ILLEGAL_INSTANTIATE=Warning
-ILLEGAL_OVERRIDE=Warning
-ILLEGAL_REFERENCE=Warning
-INTERFACE_ELEMENT_TYPE_ADDED_FIELD=Error
-INTERFACE_ELEMENT_TYPE_ADDED_METHOD=Error
-INTERFACE_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
-INTERFACE_ELEMENT_TYPE_ADDED_SUPER_INTERFACE_WITH_METHODS=Error
-INTERFACE_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-INTERFACE_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
-INTERFACE_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_FIELD=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_METHOD=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-INVALID_JAVADOC_TAG=Warning
-INVALID_REFERENCE_IN_SYSTEM_LIBRARIES=Warning
-LEAK_EXTEND=Warning
-LEAK_FIELD_DECL=Warning
-LEAK_IMPLEMENT=Warning
-LEAK_METHOD_PARAM=Warning
-LEAK_METHOD_RETURN_TYPE=Warning
-METHOD_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
-METHOD_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-METHOD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-METHOD_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
-METHOD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
-METHOD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
-METHOD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
-METHOD_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
-METHOD_ELEMENT_TYPE_REMOVED_ANNOTATION_DEFAULT_VALUE=Error
-METHOD_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-MISSING_EE_DESCRIPTIONS=Ignore
-TYPE_PARAMETER_ELEMENT_TYPE_ADDED_CLASS_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_ADDED_INTERFACE_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_CLASS_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_INTERFACE_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_CLASS_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_INTERFACE_BOUND=Error
-UNUSED_PROBLEM_FILTERS=Warning
-automatically_removed_unused_problem_filters=false
-eclipse.preferences.version=1
-incompatible_api_component_version=Error
-incompatible_api_component_version_include_major_without_breaking_change=Disabled
-incompatible_api_component_version_include_minor_without_api_change=Disabled
-invalid_since_tag_version=Error
-malformed_since_tag=Error
-missing_since_tag=Error
-report_api_breakage_when_major_version_incremented=Disabled
-report_resolution_errors_api_component=Warning
diff --git a/org.eclipse.tracecompass.lttng2.control.core.tests/.settings/org.eclipse.pde.prefs b/org.eclipse.tracecompass.lttng2.control.core.tests/.settings/org.eclipse.pde.prefs
deleted file mode 100644 (file)
index 62cfa90..0000000
+++ /dev/null
@@ -1,32 +0,0 @@
-compilers.f.unresolved-features=1
-compilers.f.unresolved-plugins=1
-compilers.incompatible-environment=1
-compilers.p.build=1
-compilers.p.build.bin.includes=1
-compilers.p.build.encodings=2
-compilers.p.build.java.compiler=2
-compilers.p.build.java.compliance=1
-compilers.p.build.missing.output=2
-compilers.p.build.output.library=1
-compilers.p.build.source.library=1
-compilers.p.build.src.includes=1
-compilers.p.deprecated=1
-compilers.p.discouraged-class=1
-compilers.p.internal=1
-compilers.p.missing-packages=2
-compilers.p.missing-version-export-package=2
-compilers.p.missing-version-import-package=2
-compilers.p.missing-version-require-bundle=2
-compilers.p.no-required-att=0
-compilers.p.not-externalized-att=2
-compilers.p.unknown-attribute=1
-compilers.p.unknown-class=1
-compilers.p.unknown-element=1
-compilers.p.unknown-identifier=1
-compilers.p.unknown-resource=1
-compilers.p.unresolved-ex-points=0
-compilers.p.unresolved-import=0
-compilers.s.create-docs=false
-compilers.s.doc-folder=doc
-compilers.s.open-tags=1
-eclipse.preferences.version=1
diff --git a/org.eclipse.tracecompass.lttng2.control.core.tests/META-INF/MANIFEST.MF b/org.eclipse.tracecompass.lttng2.control.core.tests/META-INF/MANIFEST.MF
deleted file mode 100644 (file)
index d7fbfb1..0000000
+++ /dev/null
@@ -1,16 +0,0 @@
-Manifest-Version: 1.0
-Bundle-ManifestVersion: 2
-Bundle-Name: %Bundle-Name
-Bundle-Vendor: %Bundle-Vendor
-Bundle-Version: 1.0.0.qualifier
-Bundle-Localization: plugin
-Bundle-SymbolicName: org.eclipse.tracecompass.lttng2.control.core.tests;singleton:=true
-Bundle-ActivationPolicy: lazy
-Bundle-RequiredExecutionEnvironment: JavaSE-1.7
-Require-Bundle: org.junit;bundle-version="4.0.0",
- org.eclipse.core.runtime,
- org.eclipse.tracecompass.lttng2.control.core
-Export-Package: org.eclipse.tracecompass.lttng2.control.core.tests;x-friends:="org.eclipse.tracecompass.alltests",
- org.eclipse.tracecompass.lttng2.control.core.tests.model.impl;x-internal:=true,
- org.eclipse.tracecompass.lttng2.control.core.tests.relayd,
- org.eclipse.tracecompass.lttng2.control.core.tests.session
diff --git a/org.eclipse.tracecompass.lttng2.control.core.tests/about.html b/org.eclipse.tracecompass.lttng2.control.core.tests/about.html
deleted file mode 100644 (file)
index c258ef5..0000000
+++ /dev/null
@@ -1,28 +0,0 @@
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
-    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml">
-<head>
-<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"/>
-<title>About</title>
-</head>
-<body lang="EN-US">
-<h2>About This Content</h2>
-<p>June 5, 2006</p>    
-<h3>License</h3>
-
-<p>The Eclipse Foundation makes available all content in this plug-in (&quot;Content&quot;).  Unless otherwise 
-indicated below, the Content is provided to you under the terms and conditions of the
-Eclipse Public License Version 1.0 (&quot;EPL&quot;).  A copy of the EPL is available 
-at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>.
-For purposes of the EPL, &quot;Program&quot; will mean the Content.</p>
-
-<p>If you did not receive this Content directly from the Eclipse Foundation, the Content is 
-being redistributed by another party (&quot;Redistributor&quot;) and different terms and conditions may
-apply to your use of any object code in the Content.  Check the Redistributor's license that was 
-provided with the Content.  If no such license exists, contact the Redistributor.  Unless otherwise
-indicated below, the terms and conditions of the EPL still apply to any source code in the Content
-and such source code may be obtained at <a href="http://www.eclipse.org/">http://www.eclipse.org</a>.</p>
-
-</body>
-</html>
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.core.tests/build.properties b/org.eclipse.tracecompass.lttng2.control.core.tests/build.properties
deleted file mode 100644 (file)
index 978a8de..0000000
+++ /dev/null
@@ -1,19 +0,0 @@
-###############################################################################
-# Copyright (c) 2013, 2015 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:
-#     Ericsson - Initial API and implementation
-###############################################################################
-
-source.. = src/
-output.. = bin/
-bin.includes = META-INF/,\
-               .,\
-               plugin.properties,\
-               about.html
-src.includes = about.html
diff --git a/org.eclipse.tracecompass.lttng2.control.core.tests/plugin.properties b/org.eclipse.tracecompass.lttng2.control.core.tests/plugin.properties
deleted file mode 100644 (file)
index 0558e68..0000000
+++ /dev/null
@@ -1,14 +0,0 @@
-###############################################################################
-# Copyright (c) 2013, 2014 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:
-#     Ericsson - Initial API and implementation
-###############################################################################
-
-Bundle-Vendor = Eclipse Trace Compass
-Bundle-Name = Trace Compass LTTng Control Core Tests Plug-in
diff --git a/org.eclipse.tracecompass.lttng2.control.core.tests/pom.xml b/org.eclipse.tracecompass.lttng2.control.core.tests/pom.xml
deleted file mode 100644 (file)
index 16754c1..0000000
+++ /dev/null
@@ -1,44 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-   Copyright (C) 2011, Red Hat, Inc.
-
-   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
--->
-<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>
-    <artifactId>org.eclipse.tracecompass</artifactId>
-    <groupId>org.eclipse.tracecompass</groupId>
-    <version>1.0.0-SNAPSHOT</version>
-  </parent>
-
-  <artifactId>org.eclipse.tracecompass.lttng2.control.core.tests</artifactId>
-  <version>1.0.0-SNAPSHOT</version>
-  <packaging>eclipse-test-plugin</packaging>
-
-  <name>Trace Compass LTTng Control Core Tests Plug-in</name>
-
- <build>
-    <plugins>
-        <plugin>
-            <groupId>org.eclipse.tycho</groupId>
-            <artifactId>tycho-surefire-plugin</artifactId>
-            <version>${tycho-version}</version>
-            <configuration>
-                <testSuite>org.eclipse.tracecompass.lttng2.control.core.tests</testSuite>
-                <testClass>org.eclipse.tracecompass.lttng2.control.core.tests.AllTests</testClass>
-                <useUIHarness>false</useUIHarness>
-                <useUIThread>false</useUIThread>
-                <product>org.eclipse.platform.ide</product>
-            </configuration>
-        </plugin>
-    </plugins>
-  </build>
-
- <groupId>org.eclipse.tracecompass</groupId>
-</project>
diff --git a/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/ActivatorTest.java b/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/ActivatorTest.java
deleted file mode 100644 (file)
index ee375b7..0000000
+++ /dev/null
@@ -1,61 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Francois Chouinard - Initial API and implementation
- *   Alexandre Montplaisir - Port to JUnit4
- *******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.control.core.tests;
-
-import static org.junit.Assert.assertTrue;
-
-import org.junit.Test;
-
-/**
- * Test stubs for the Activator.
- */
-public class ActivatorTest {
-
-    // ------------------------------------------------------------------------
-    // Tests
-    // ------------------------------------------------------------------------
-
-    /**
-     * Test method for {@link org.eclipse.tracecompass.internal.lttng2.control.core.Activator#Activator()}.
-     */
-    @Test
-    public void testActivator() {
-        assertTrue(true);
-    }
-
-    /**
-     * Test method for {@link org.eclipse.tracecompass.internal.lttng2.control.core.Activator#getDefault()}.
-     */
-    @Test
-    public void testGetDefault() {
-        assertTrue(true);
-    }
-
-    /**
-     * Test method for {@link org.eclipse.tracecompass.internal.lttng2.control.core.Activator#start(org.osgi.framework.BundleContext)}.
-     */
-    @Test
-    public void testStartBundleContext() {
-        assertTrue(true);
-    }
-
-    /**
-     * Test method for {@link org.eclipse.tracecompass.internal.lttng2.control.core.Activator#stop(org.osgi.framework.BundleContext)}.
-     */
-    @Test
-    public void testStopBundleContext() {
-        assertTrue(true);
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/AllTests.java b/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/AllTests.java
deleted file mode 100644 (file)
index e4544e2..0000000
+++ /dev/null
@@ -1,31 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Francois Chouinard - Initial API and implementation
- *   Alexandre Montplaisir - Port to JUnit4
- *******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.control.core.tests;
-
-import org.junit.runner.RunWith;
-import org.junit.runners.Suite;
-
-/**
- * Run all the tests in the test suite
- */
-@RunWith(Suite.class)
-@Suite.SuiteClasses({
-    ActivatorTest.class,
-    org.eclipse.tracecompass.lttng2.control.core.tests.model.impl.AllTests.class,
-    org.eclipse.tracecompass.lttng2.control.core.tests.session.AllTests.class,
-    org.eclipse.tracecompass.lttng2.control.core.tests.model.impl.AllTests.class
-})
-public class AllTests {
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/AllTests.java b/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/AllTests.java
deleted file mode 100644 (file)
index 9b5538d..0000000
+++ /dev/null
@@ -1,37 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2011, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Alexandre Montplaisir - Port to JUnit4
- *******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.control.core.tests.model.impl;
-
-import org.junit.runner.RunWith;
-import org.junit.runners.Suite;
-
-/**
- * Runner for the test suite
- */
-@RunWith(Suite.class)
-@Suite.SuiteClasses({
-    BaseEventInfoTest.class,
-    ChannelInfoTest.class,
-    DomainInfoTest.class,
-    EventInfoTest.class,
-    FieldInfoTest.class,
-    ProbeEventInfoTest.class,
-    SessionInfoTest.class,
-    TraceInfoTest.class,
-    UstProviderInfoTest.class,
-    SnapshotInfoTest.class
-})
-public class AllTests {
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/BaseEventInfoTest.java b/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/BaseEventInfoTest.java
deleted file mode 100644 (file)
index 8199b31..0000000
+++ /dev/null
@@ -1,567 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Alexandre Montplaisir - Port to JUnit4
- **********************************************************************/
-
-package org.eclipse.tracecompass.lttng2.control.core.tests.model.impl;
-
-import static org.junit.Assert.*;
-
-import java.util.LinkedList;
-import java.util.List;
-
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IBaseEventInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IFieldInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEventType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.BaseEventInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.FieldInfo;
-import org.junit.Before;
-import org.junit.Test;
-
-/**
- * The class <code>BaseEventInfoTest</code> contains test for the class
- * <code>{@link BaseEventInfo}</code>.
- */
-public class BaseEventInfoTest {
-
-    // ------------------------------------------------------------------------
-    // Test data
-    // ------------------------------------------------------------------------
-
-    private IBaseEventInfo fEventInfo1 = null;
-    private IBaseEventInfo fEventInfo2 = null;
-
-    // ------------------------------------------------------------------------
-    // Housekeeping
-    // ------------------------------------------------------------------------
-    /**
-     * Perform pre-test initialization.
-     */
-    @Before
-    public void setUp() {
-        ModelImplFactory factory = new ModelImplFactory();
-        fEventInfo1 = factory.getBaseEventInfo1();
-        fEventInfo2 = factory.getBaseEventInfo2();
-    }
-
-    // ------------------------------------------------------------------------
-    // Tests
-    // ------------------------------------------------------------------------
-
-    /**
-     * Run the BaseEventInfo() constructor test.
-     */
-    @Test
-    public void testBaseEventInfo() {
-        BaseEventInfo fixture = new BaseEventInfo("event");
-        assertNotNull(fixture);
-
-        TraceEventType result = fixture.getEventType();
-
-        assertEquals("event", fixture.getName());
-        assertEquals("unknown", result.getInName());
-        assertEquals("UNKNOWN", result.name());
-        assertEquals("UNKNOWN", result.toString());
-        assertEquals(4, result.ordinal());
-
-        TraceLogLevel level = fixture.getLogLevel();
-        assertEquals("TRACE_DEBUG", level.getInName());
-        assertEquals("TRACE_DEBUG", level.name());
-        assertEquals("TRACE_DEBUG", level.toString());
-        assertEquals(14, level.ordinal());
-    }
-
-    /**
-     * Test Copy Constructor
-     */
-    @Test
-    public void testEventInfoCopy() {
-        BaseEventInfo info = new BaseEventInfo((BaseEventInfo)fEventInfo1);
-
-        assertEquals(fEventInfo1.getName(), info.getName());
-        assertEquals(fEventInfo1.getEventType(), info.getEventType());
-        assertEquals(fEventInfo1.getLogLevel(), info.getLogLevel());
-        assertEquals(fEventInfo1.getFilterExpression(), info.getFilterExpression());
-
-        IFieldInfo[] orignalFields = fEventInfo1.getFields();
-        IFieldInfo[] copiedFields = info.getFields();
-        assertEquals(orignalFields.length, copiedFields.length);
-
-        for (int i = 0; i < copiedFields.length; i++) {
-            assertEquals(orignalFields[i], copiedFields[i]);
-        }
-    }
-
-    /**
-     * Test Copy Constructor
-     */
-    @Test
-    public void testEventCopy2() {
-        try {
-            BaseEventInfo info = null;
-            new BaseEventInfo(info);
-            fail("null copy");
-        }
-        catch (IllegalArgumentException e) {
-            // Success
-        }
-    }
-
-    /**
-     * Run the TraceEventType getEventType() method test.
-     */
-    @Test
-    public void testGetEventType_1() {
-        BaseEventInfo fixture = new BaseEventInfo("event");
-        fixture.setEventType("unknown");
-
-        TraceEventType result = fixture.getEventType();
-
-        assertNotNull(result);
-        assertEquals("unknown", result.getInName());
-        assertEquals("UNKNOWN", result.name());
-        assertEquals("UNKNOWN", result.toString());
-        assertEquals(4, result.ordinal());
-
-        fixture.setEventType("");
-        result = fixture.getEventType();
-        assertEquals("unknown", result.getInName());
-        assertEquals("UNKNOWN", result.name());
-        assertEquals("UNKNOWN", result.toString());
-        assertEquals(4, result.ordinal());
-
-        fixture.setEventType("tracepoint");
-        result = fixture.getEventType();
-        assertNotNull(result);
-        assertEquals("tracepoint", result.getInName());
-        assertEquals("TRACEPOINT", result.name());
-        assertEquals("TRACEPOINT", result.toString());
-        assertEquals(0, result.ordinal());
-
-        fixture.setEventType("syscall");
-        result = fixture.getEventType();
-        assertNotNull(result);
-        assertEquals("syscall", result.getInName());
-        assertEquals("SYSCALL", result.name());
-        assertEquals("SYSCALL", result.toString());
-        assertEquals(1, result.ordinal());
-
-        fixture.setEventType("probe");
-        result = fixture.getEventType();
-        assertNotNull(result);
-        assertEquals("probe", result.getInName());
-        assertEquals("PROBE", result.name());
-        assertEquals("PROBE", result.toString());
-        assertEquals(2, result.ordinal());
-
-        fixture.setEventType("function");
-        result = fixture.getEventType();
-        assertNotNull(result);
-        assertEquals("function", result.getInName());
-        assertEquals("FUNCTION", result.name());
-        assertEquals("FUNCTION", result.toString());
-        assertEquals(3, result.ordinal());
-
-
-    }
-
-    /**
-     * Run the void setEventType(TraceEventType) method test.
-     */
-    @Test
-    public void testSetEventType_2() {
-        BaseEventInfo fixture = new BaseEventInfo("event");
-        fixture.setEventType(TraceEventType.TRACEPOINT);
-
-        TraceEventType result = fixture.getEventType();
-
-        assertNotNull(result);
-        assertEquals("tracepoint", result.getInName());
-        assertEquals("TRACEPOINT", result.name());
-        assertEquals("TRACEPOINT", result.toString());
-        assertEquals(0, result.ordinal());
-
-        fixture.setEventType(TraceEventType.UNKNOWN);
-        result = fixture.getEventType();
-
-        assertNotNull(result);
-        assertEquals("unknown", result.getInName());
-        assertEquals("UNKNOWN", result.name());
-        assertEquals("UNKNOWN", result.toString());
-        assertEquals(4, result.ordinal());
-
-        fixture.setEventType(TraceEventType.SYSCALL);
-        result = fixture.getEventType();
-        assertNotNull(result);
-        assertEquals("syscall", result.getInName());
-        assertEquals("SYSCALL", result.name());
-        assertEquals("SYSCALL", result.toString());
-        assertEquals(1, result.ordinal());
-
-        fixture.setEventType(TraceEventType.PROBE);
-        result = fixture.getEventType();
-        assertNotNull(result);
-        assertEquals("probe", result.getInName());
-        assertEquals("PROBE", result.name());
-        assertEquals("PROBE", result.toString());
-        assertEquals(2, result.ordinal());
-
-        fixture.setEventType(TraceEventType.FUNCTION);
-        result = fixture.getEventType();
-        assertNotNull(result);
-        assertEquals("function", result.getInName());
-        assertEquals("FUNCTION", result.name());
-        assertEquals("FUNCTION", result.toString());
-        assertEquals(3, result.ordinal());
-
-
-    }
-
-    /**
-     * Run the void setLogLevel(TraceLogLevel) method test.
-     * Run the TraceLogLevel getLogLevel() method test
-     */
-    @Test
-    public void testSetLogLevel1() {
-        BaseEventInfo fixture = new BaseEventInfo("event");
-        fixture.setEventType(TraceEventType.TRACEPOINT);
-        fixture.setLogLevel(TraceLogLevel.TRACE_CRIT);
-
-        // 2 set/get-operations are enough to test the method
-        TraceLogLevel result = fixture.getLogLevel();
-        assertNotNull(result);
-        assertEquals("TRACE_CRIT", result.getInName());
-        assertEquals("TRACE_CRIT", result.name());
-        assertEquals("TRACE_CRIT", result.toString());
-        assertEquals(2, result.ordinal());
-
-        fixture.setLogLevel(TraceLogLevel.TRACE_DEBUG_FUNCTION);
-
-        result = fixture.getLogLevel();
-        assertNotNull(result);
-        assertEquals("TRACE_DEBUG_FUNCTION", result.getInName());
-        assertEquals("TRACE_DEBUG_FUNCTION", result.name());
-        assertEquals("TRACE_DEBUG_FUNCTION", result.toString());
-        assertEquals(12, result.ordinal());
-    }
-
-    /**
-     * Run the void setLogLevel(String) method test.
-     * Run the TraceLogLevel getLogLevel() method test
-     */
-    @Test
-    public void testSetLogLevel2() {
-        BaseEventInfo fixture = new BaseEventInfo("event");
-        fixture.setEventType(TraceEventType.TRACEPOINT);
-        fixture.setLogLevel("TRACE_EMERG");
-
-        TraceLogLevel result = fixture.getLogLevel();
-        assertNotNull(result);
-        assertEquals("TRACE_EMERG", result.getInName());
-        assertEquals("TRACE_EMERG", result.name());
-        assertEquals(0, result.ordinal());
-
-        //------------------------
-        fixture.setLogLevel("TRACE_ALERT");
-
-        result = fixture.getLogLevel();
-        assertNotNull(result);
-        assertEquals("TRACE_ALERT", result.getInName());
-        assertEquals("TRACE_ALERT", result.name());
-        assertEquals(1, result.ordinal());
-
-        //------------------------
-        fixture.setLogLevel("TRACE_CRIT");
-
-        result = fixture.getLogLevel();
-        assertNotNull(result);
-        assertEquals("TRACE_CRIT", result.getInName());
-        assertEquals("TRACE_CRIT", result.name());
-        assertEquals(2, result.ordinal());
-
-        //------------------------
-        fixture.setLogLevel("TRACE_ERR");
-
-        result = fixture.getLogLevel();
-        assertNotNull(result);
-        assertEquals("TRACE_ERR", result.getInName());
-        assertEquals("TRACE_ERR", result.name());
-        assertEquals(3, result.ordinal());
-
-        //------------------------
-        fixture.setLogLevel("TRACE_WARNING");
-
-        result = fixture.getLogLevel();
-        assertNotNull(result);
-        assertEquals("TRACE_WARNING", result.getInName());
-        assertEquals("TRACE_WARNING", result.name());
-        assertEquals(4, result.ordinal());
-
-        //------------------------
-        fixture.setLogLevel("TRACE_NOTICE");
-
-        result = fixture.getLogLevel();
-        assertNotNull(result);
-        assertEquals("TRACE_NOTICE", result.getInName());
-        assertEquals("TRACE_NOTICE", result.name());
-        assertEquals(5, result.ordinal());
-
-        //------------------------
-        fixture.setLogLevel("TRACE_INFO");
-
-        result = fixture.getLogLevel();
-        assertNotNull(result);
-        assertEquals("TRACE_INFO", result.getInName());
-        assertEquals("TRACE_INFO", result.name());
-        assertEquals(6, result.ordinal());
-
-        //------------------------
-        fixture.setLogLevel("TRACE_DEBUG_SYSTEM");
-
-        result = fixture.getLogLevel();
-        assertNotNull(result);
-        assertEquals("TRACE_DEBUG_SYSTEM", result.getInName());
-        assertEquals("TRACE_DEBUG_SYSTEM", result.name());
-        assertEquals(7, result.ordinal());
-
-        //------------------------
-        fixture.setLogLevel("TRACE_DEBUG_PROGRAM");
-
-        result = fixture.getLogLevel();
-        assertNotNull(result);
-        assertEquals("TRACE_DEBUG_PROGRAM", result.getInName());
-        assertEquals("TRACE_DEBUG_PROGRAM", result.name());
-        assertEquals(8, result.ordinal());
-
-        //------------------------
-        fixture.setLogLevel("TRACE_DEBUG_PROCESS");
-
-        result = fixture.getLogLevel();
-        assertNotNull(result);
-        assertEquals("TRACE_DEBUG_PROCESS", result.getInName());
-        assertEquals("TRACE_DEBUG_PROCESS", result.name());
-        assertEquals(9, result.ordinal());
-
-        //------------------------
-        fixture.setLogLevel("TRACE_DEBUG_MODULE");
-
-        result = fixture.getLogLevel();
-        assertNotNull(result);
-        assertEquals("TRACE_DEBUG_MODULE", result.getInName());
-        assertEquals("TRACE_DEBUG_MODULE", result.name());
-        assertEquals(10, result.ordinal());
-
-        //------------------------
-        fixture.setLogLevel("TRACE_DEBUG_UNIT");
-
-        result = fixture.getLogLevel();
-        assertNotNull(result);
-        assertEquals("TRACE_DEBUG_UNIT", result.getInName());
-        assertEquals("TRACE_DEBUG_UNIT", result.name());
-        assertEquals(11, result.ordinal());
-
-        //------------------------
-        fixture.setLogLevel("TRACE_DEBUG_FUNCTION");
-
-        result = fixture.getLogLevel();
-        assertNotNull(result);
-        assertEquals("TRACE_DEBUG_FUNCTION", result.getInName());
-        assertEquals("TRACE_DEBUG_FUNCTION", result.name());
-        assertEquals(12, result.ordinal());
-
-        //------------------------
-        fixture.setLogLevel("TRACE_DEBUG_LINE");
-
-        result = fixture.getLogLevel();
-        assertNotNull(result);
-        assertEquals("TRACE_DEBUG_LINE", result.getInName());
-        assertEquals("TRACE_DEBUG_LINE", result.name());
-        assertEquals(13, result.ordinal());
-
-        //------------------------
-        fixture.setLogLevel("TRACE_DEBUG");
-
-        result = fixture.getLogLevel();
-        assertNotNull(result);
-        assertEquals("TRACE_DEBUG", result.getInName());
-        assertEquals("TRACE_DEBUG", result.name());
-        assertEquals(14, result.ordinal());
-
-        //-------------------------
-        fixture.setLogLevel("LEVEL_UNKNOWN");
-
-        result = fixture.getLogLevel();
-        assertNotNull(result);
-        assertEquals("LEVEL_UNKNOWN", result.getInName());
-        assertEquals("LEVEL_UNKNOWN", result.name());
-        assertEquals(15, result.ordinal());
-
-        fixture.setLogLevel("garbage");
-
-        result = fixture.getLogLevel();
-        assertNotNull(result);
-        assertEquals("LEVEL_UNKNOWN", result.getInName());
-        assertEquals("LEVEL_UNKNOWN", result.name());
-        assertEquals(15, result.ordinal());
-    }
-
-    /**
-     * test filter expression
-     */
-    @Test
-     public void testSetFields() {
-         BaseEventInfo info = new BaseEventInfo((BaseEventInfo)fEventInfo2);
-         info.setFilterExpression("stringfield==test");
-         assertEquals("stringfield==test", info.getFilterExpression());
-     }
-
-
-   /**
-    * test add field
-    */
-    @Test
-    public void testAddField() {
-        BaseEventInfo info = new BaseEventInfo((BaseEventInfo)fEventInfo2);
-
-        IFieldInfo field =  new FieldInfo("intfield");
-        field.setFieldType("int");
-
-        info.addField(field);
-
-        // Verify the stored events
-        IFieldInfo[] result = info.getFields();
-
-        assertNotNull(result);
-        assertEquals(1, result.length);
-        assertNotNull(result[0]);
-        assertTrue(field.equals(result[0]));
-    }
-
-    /**
-     * test set fields
-     */
-    @Test
-    public void testFields() {
-        BaseEventInfo info = new BaseEventInfo((BaseEventInfo)fEventInfo2);
-
-        IFieldInfo field1 =  new FieldInfo("intfield");
-        field1.setFieldType("int");
-
-        IFieldInfo field2 =  new FieldInfo("stringfield");
-        field2.setFieldType("string");
-
-        List<IFieldInfo> fields = new LinkedList<>();
-        fields.add(field1);
-        fields.add(field2);
-        info.setFields(fields);
-
-        // Verify the stored events
-        IFieldInfo[] result = info.getFields();
-
-        assertNotNull(result);
-        assertEquals(2, result.length);
-
-        for (int i = 0; i < result.length; i++) {
-            assertNotNull(result[i]);
-            assertTrue(fields.get(i).equals(result[i]));
-        }
-    }
-
-    /**
-     * Run the String toString() method test.
-     */
-    @Test
-    public void testToString_1() {
-        BaseEventInfo fixture = new BaseEventInfo("event");
-        fixture.setName("testName");
-        fixture.setEventType(TraceEventType.TRACEPOINT);
-        fixture.setLogLevel(TraceLogLevel.TRACE_ERR);
-
-        String result = fixture.toString();
-
-        // add additional test code here
-        assertEquals("[BaseEventInfo([TraceInfo(Name=testName)],type=TRACEPOINT,level=TRACE_ERR)]", result);
-    }
-
-    // ------------------------------------------------------------------------
-    // equals
-    // ------------------------------------------------------------------------
-
-    /**
-     * Test the .equals() method.
-     */
-    @Test
-    public void testEqualsReflexivity() {
-        assertTrue("equals", fEventInfo1.equals(fEventInfo1));
-        assertTrue("equals", fEventInfo2.equals(fEventInfo2));
-
-        assertTrue("equals", !fEventInfo1.equals(fEventInfo2));
-        assertTrue("equals", !fEventInfo2.equals(fEventInfo1));
-    }
-
-    /**
-     * Test the .equals() method.
-     */
-    @Test
-    public void testEqualsSymmetry() {
-        BaseEventInfo info1 = new BaseEventInfo((BaseEventInfo)fEventInfo1);
-        BaseEventInfo info2 = new BaseEventInfo((BaseEventInfo)fEventInfo2);
-
-        assertTrue("equals", info1.equals(fEventInfo1));
-        assertTrue("equals", fEventInfo1.equals(info1));
-
-        assertTrue("equals", info2.equals(fEventInfo2));
-        assertTrue("equals", fEventInfo2.equals(info2));
-    }
-
-    /**
-     * Test the .equals() method.
-     */
-    @Test
-    public void testEqualsTransivity() {
-        BaseEventInfo info1 = new BaseEventInfo((BaseEventInfo)fEventInfo1);
-        BaseEventInfo info2 = new BaseEventInfo((BaseEventInfo)fEventInfo1);
-        BaseEventInfo info3 = new BaseEventInfo((BaseEventInfo)fEventInfo1);
-
-        assertTrue("equals", info1.equals(info2));
-        assertTrue("equals", info2.equals(info3));
-        assertTrue("equals", info1.equals(info3));
-    }
-
-    /**
-     * Test the .equals() method.
-     */
-    @Test
-    public void testEqualsNull() {
-        assertTrue("equals", !fEventInfo1.equals(null));
-        assertTrue("equals", !fEventInfo2.equals(null));
-    }
-
-    // ------------------------------------------------------------------------
-    // hashCode
-    // ------------------------------------------------------------------------
-
-    /**
-     * Test the hashCode() method.
-     */
-    @Test
-    public void testHashCode() {
-        BaseEventInfo info1 = new BaseEventInfo((BaseEventInfo)fEventInfo1);
-        BaseEventInfo info2 = new BaseEventInfo((BaseEventInfo)fEventInfo2);
-
-        assertTrue("hashCode", fEventInfo1.hashCode() == info1.hashCode());
-        assertTrue("hashCode", fEventInfo2.hashCode() == info2.hashCode());
-
-        assertTrue("hashCode", fEventInfo1.hashCode() != info2.hashCode());
-        assertTrue("hashCode", fEventInfo2.hashCode() != info1.hashCode());
-    }
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/ChannelInfoTest.java b/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/ChannelInfoTest.java
deleted file mode 100644 (file)
index 0e3b247..0000000
+++ /dev/null
@@ -1,382 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2015 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Alexandre Montplaisir - Port to JUnit4
- **********************************************************************/
-
-package org.eclipse.tracecompass.lttng2.control.core.tests.model.impl;
-
-import static org.junit.Assert.*;
-
-import java.util.LinkedList;
-import java.util.List;
-
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IChannelInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IEventInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceChannelOutputType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEnablement;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.BufferType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.ChannelInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.EventInfo;
-import org.junit.Before;
-import org.junit.Test;
-
-/**
- * The class <code>ChannelInfoTest</code> contains tests for the class
- * <code>{@link ChannelInfo}</code>.
- */
-public class ChannelInfoTest {
-
-    // ------------------------------------------------------------------------
-    // Test data
-    // ------------------------------------------------------------------------
-
-    private IChannelInfo fChannelInfo1 = null;
-    private IChannelInfo fChannelInfo2 = null;
-
-    // ------------------------------------------------------------------------
-    // Housekeeping
-    // ------------------------------------------------------------------------
-
-    /**
-     * Perform pre-test initialization.
-     */
-    @Before
-    public void setUp() {
-        ModelImplFactory factory = new ModelImplFactory();
-        fChannelInfo1 = factory.getChannel1();
-        fChannelInfo2 = factory.getChannel2();
-    }
-
-    // ------------------------------------------------------------------------
-    // Tests
-    // ------------------------------------------------------------------------
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-
-    /**
-     * Run the ChannelInfo() constructor test.
-     */
-    @Test
-    public void testChannelInfo() {
-        ChannelInfo result = new ChannelInfo("test");
-        assertNotNull(result);
-
-        assertEquals("test", result.getName());
-        assertEquals(0, result.getNumberOfSubBuffers());
-        assertEquals("unknown", result.getOutputType().getInName());
-        assertEquals(TraceChannelOutputType.UNKNOWN, result.getOutputType());
-        assertEquals(false, result.isOverwriteMode());
-        assertEquals(0, result.getReadTimer());
-        assertEquals("disabled", result.getState().getInName());
-        assertEquals(0, result.getSubBufferSize());
-        assertEquals(0, result.getSwitchTimer());
-        assertEquals(0, result.getMaxSizeTraceFiles());
-        assertEquals(0, result.getMaxNumberTraceFiles());
-        assertEquals(BufferType.BUFFER_TYPE_UNKNOWN, result.getBufferType());
-    }
-
-    /**
-     * Test copy constructor.
-     */
-    @Test
-    public void testChannelInfoCopy() {
-        ChannelInfo channelInfo = new ChannelInfo((ChannelInfo)fChannelInfo1);
-
-        assertEquals(fChannelInfo1.getName(), channelInfo.getName());
-        assertEquals(fChannelInfo1.getNumberOfSubBuffers(), channelInfo.getNumberOfSubBuffers());
-        assertEquals(fChannelInfo1.getOutputType(), channelInfo.getOutputType());
-        assertEquals(fChannelInfo1.isOverwriteMode(), channelInfo.isOverwriteMode());
-        assertEquals(fChannelInfo1.getReadTimer(), channelInfo.getReadTimer());
-        assertEquals(fChannelInfo1.getState(), channelInfo.getState());
-        assertEquals(fChannelInfo1.getSwitchTimer(), channelInfo.getSwitchTimer());
-        assertEquals(fChannelInfo1.getEvents().length, channelInfo.getEvents().length);
-        assertEquals(fChannelInfo1.getMaxSizeTraceFiles(), channelInfo.getMaxSizeTraceFiles());
-        assertEquals(fChannelInfo1.getMaxNumberTraceFiles(), channelInfo.getMaxNumberTraceFiles());
-        assertEquals(fChannelInfo1.getBufferType(), channelInfo.getBufferType());
-
-        IEventInfo[] orignalEvents = fChannelInfo1.getEvents();
-        IEventInfo[] resultEvents = channelInfo.getEvents();
-        for (int i = 0; i < orignalEvents.length; i++) {
-            assertEquals(orignalEvents[i], resultEvents[i]);
-        }
-    }
-
-    /**
-     * Test copy constructor with a null value.
-     */
-    @Test
-    public void testChannelCopy2() {
-        try {
-            ChannelInfo channel = null;
-            new ChannelInfo(channel);
-            fail("null copy");
-        }
-        catch (IllegalArgumentException e) {
-            // Success
-        }
-    }
-
-    /**
-     * Run the IEventInfo[] getEvents() method test.
-     */
-    @Test
-    public void testAddAndGetEvents_1() {
-        ChannelInfo fixture = new ChannelInfo("test");
-        fixture.setSwitchTimer(1L);
-        fixture.setOverwriteMode(true);
-        fixture.setReadTimer(1L);
-        fixture.setState(TraceEnablement.DISABLED);
-        fixture.setNumberOfSubBuffers(1);
-        fixture.setOutputType("");
-        fixture.setSubBufferSize(1L);
-
-        // add an event
-        IEventInfo event = new EventInfo("event");
-        fixture.addEvent(event);
-
-        // Verify the stored events
-        IEventInfo[] result = fixture.getEvents();
-
-        assertNotNull(result);
-        assertEquals(1, result.length);
-        assertNotNull(result[0]);
-        assertTrue(event.equals(result[0]));
-    }
-
-    /**
-     * Run the long getNumberOfSubBuffers() method test.
-     */
-    @Test
-    public void testGetAndSetters() {
-        ChannelInfo fixture = new ChannelInfo("test");
-        fixture.setSwitchTimer(2L);
-        fixture.setOverwriteMode(true);
-        fixture.setReadTimer(3L);
-        fixture.setState(TraceEnablement.DISABLED);
-        fixture.setNumberOfSubBuffers(4);
-        fixture.setOutputType("splice()");
-        fixture.setSubBufferSize(1L);
-        fixture.setMaxSizeTraceFiles(1024);
-        fixture.setMaxNumberTraceFiles(20);
-        fixture.setBufferType(BufferType.BUFFER_PER_UID);
-        fixture.addEvent(new EventInfo("event"));
-
-        long switchTimer = fixture.getSwitchTimer();
-        assertEquals(2L, switchTimer);
-
-        boolean mode = fixture.isOverwriteMode();
-        assertTrue(mode);
-
-        long readTimer = fixture.getReadTimer();
-        assertEquals(3L, readTimer);
-
-        TraceEnablement state = fixture.getState();
-        assertEquals("disabled", state.getInName());
-
-        long numSubBuffers = fixture.getNumberOfSubBuffers();
-        assertEquals(4, numSubBuffers);
-
-        String outputType = fixture.getOutputType().getInName();
-        assertEquals("splice()", outputType);
-
-        long subBufferSize = fixture.getSubBufferSize();
-        assertEquals(1L, subBufferSize);
-
-        long maxSizeTraceFiles = fixture.getMaxSizeTraceFiles();
-        assertEquals(1024, maxSizeTraceFiles);
-
-        int maxNumberTraceFiles = fixture.getMaxNumberTraceFiles();
-        assertEquals(20, maxNumberTraceFiles);
-
-        BufferType bufferType = fixture.getBufferType();
-        assertTrue(bufferType == BufferType.BUFFER_PER_UID);
-
-        fixture.setSwitchTimer(5L);
-        fixture.setOverwriteMode(false);
-        fixture.setReadTimer(6L);
-        fixture.setState(TraceEnablement.ENABLED);
-        fixture.setNumberOfSubBuffers(7);
-        fixture.setOutputType("mmap()");
-        fixture.setSubBufferSize(8L);
-        fixture.setMaxSizeTraceFiles(4096);
-        fixture.setMaxNumberTraceFiles(10);
-        fixture.setBufferType(BufferType.BUFFER_PER_PID);
-
-        switchTimer = fixture.getSwitchTimer();
-        assertEquals(5L, switchTimer);
-
-        mode = fixture.isOverwriteMode();
-        assertFalse(mode);
-
-        readTimer = fixture.getReadTimer();
-        assertEquals(6L, readTimer);
-
-        state = fixture.getState();
-        assertEquals("enabled", state.getInName());
-
-        numSubBuffers = fixture.getNumberOfSubBuffers();
-        assertEquals(7, numSubBuffers);
-
-        outputType = fixture.getOutputType().getInName();
-        assertEquals("mmap()", outputType);
-
-        subBufferSize = fixture.getSubBufferSize();
-        assertEquals(8L, subBufferSize);
-
-        maxSizeTraceFiles = fixture.getMaxSizeTraceFiles();
-        assertEquals(4096, maxSizeTraceFiles);
-
-        maxNumberTraceFiles = fixture.getMaxNumberTraceFiles();
-        assertEquals(10, maxNumberTraceFiles);
-
-        bufferType = fixture.getBufferType();
-        assertTrue(bufferType == BufferType.BUFFER_PER_PID);
-    }
-
-    /**
-     * Run the void setEvents(List<IEventInfo>) method test.
-     */
-    @Test
-    public void testSetEvents_1() {
-        ChannelInfo fixture = new ChannelInfo("test");
-        fixture.setSwitchTimer(1L);
-        fixture.setOverwriteMode(true);
-        fixture.setReadTimer(1L);
-        fixture.setState(TraceEnablement.DISABLED);
-        fixture.setNumberOfSubBuffers(1);
-        fixture.setOutputType("");
-        fixture.setSubBufferSize(1L);
-        List<IEventInfo> events = new LinkedList<>();
-
-        for (int i = 0; i < 2; i++) {
-            IEventInfo info = new EventInfo("event" + i);
-            info.setEventType("tracepoint");
-            info.setState((i % 2 == 0 ? "enabled" : "disabled"));
-            events.add(info);
-        }
-
-        fixture.setEvents(events);
-
-        IEventInfo[] infos = fixture.getEvents();
-
-        assertEquals(events.size(), infos.length);
-
-        for (int i = 0; i < infos.length; i++) {
-            assertEquals(events.get(i), infos[i]);
-        }
-    }
-
-    /**
-     * Run the String toString() method test.
-     */
-    @Test
-    public void testToString_1() {
-        ChannelInfo fixture = new ChannelInfo("channel");
-        fixture.setSwitchTimer(1L);
-        fixture.setOverwriteMode(true);
-        fixture.setReadTimer(1L);
-        fixture.setState(TraceEnablement.DISABLED);
-        fixture.setNumberOfSubBuffers(1);
-        fixture.setOutputType("splice()");
-        fixture.setSubBufferSize(1L);
-
-        String result = fixture.toString();
-
-        // add additional test code here
-        assertEquals("[ChannelInfo([TraceInfo(Name=channel)],State=DISABLED,OverwriteMode=true,SubBuffersSize=1,NumberOfSubBuffers=1,SwitchTimer=1,ReadTimer=1,output=splice(),Events=None)]", result);
-    }
-
-    /**
-     * Run another String toString() method test.
-     */
-    @Test
-    public void testToString_2() {
-        String result = fChannelInfo1.toString();
-
-        // add additional test code here
-        assertEquals("[ChannelInfo([TraceInfo(Name=channel1)],State=DISABLED,OverwriteMode=true,SubBuffersSize=13,NumberOfSubBuffers=12,SwitchTimer=10,ReadTimer=11,output=splice(),Events=[EventInfo([BaseEventInfo([TraceInfo(Name=event1)],type=TRACEPOINT,level=TRACE_DEBUG)],State=ENABLED,levelType=LOGLEVEL_ONLY)])]", result);
-    }
-
-    // ------------------------------------------------------------------------
-    // equals
-    // ------------------------------------------------------------------------
-
-    /**
-     * Run the equals() method test.
-     */
-    @Test
-    public void testEqualsReflexivity() {
-        assertTrue("equals", fChannelInfo1.equals(fChannelInfo1));
-        assertTrue("equals", fChannelInfo2.equals(fChannelInfo2));
-
-        assertTrue("equals", !fChannelInfo1.equals(fChannelInfo2));
-        assertTrue("equals", !fChannelInfo2.equals(fChannelInfo1));
-    }
-
-    /**
-     * Run the equals() method test.
-     */
-    @Test
-    public void testEqualsSymmetry() {
-        ChannelInfo event1 = new ChannelInfo((ChannelInfo)fChannelInfo1);
-        ChannelInfo event2 = new ChannelInfo((ChannelInfo)fChannelInfo2);
-
-        assertTrue("equals", event1.equals(fChannelInfo1));
-        assertTrue("equals", fChannelInfo1.equals(event1));
-
-        assertTrue("equals", event2.equals(fChannelInfo2));
-        assertTrue("equals", fChannelInfo2.equals(event2));
-    }
-
-    /**
-     * Run the equals() method test.
-     */
-    @Test
-    public void testEqualsTransivity() {
-        ChannelInfo channel1 = new ChannelInfo((ChannelInfo)fChannelInfo1);
-        ChannelInfo channel2 = new ChannelInfo((ChannelInfo)fChannelInfo1);
-        ChannelInfo channel3 = new ChannelInfo((ChannelInfo)fChannelInfo1);
-
-        assertTrue("equals", channel1.equals(channel2));
-        assertTrue("equals", channel2.equals(channel3));
-        assertTrue("equals", channel1.equals(channel3));
-    }
-
-    /**
-     * Run the equals() method test.
-     */
-    @Test
-    public void testEqualsNull() {
-        assertTrue("equals", !fChannelInfo1.equals(null));
-        assertTrue("equals", !fChannelInfo2.equals(null));
-    }
-
-    // ------------------------------------------------------------------------
-    // hashCode
-    // ------------------------------------------------------------------------
-
-    /**
-     * Run the hashCode() method test.
-     */
-    @Test
-    public void testHashCode() {
-        ChannelInfo channel1 = new ChannelInfo((ChannelInfo)fChannelInfo1);
-        ChannelInfo channel2 = new ChannelInfo((ChannelInfo)fChannelInfo2);
-
-        assertTrue("hashCode", fChannelInfo1.hashCode() == channel1.hashCode());
-        assertTrue("hashCode", fChannelInfo2.hashCode() == channel2.hashCode());
-
-        assertTrue("hashCode", fChannelInfo1.hashCode() != channel2.hashCode());
-        assertTrue("hashCode", fChannelInfo2.hashCode() != channel1.hashCode());
-    }
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/DomainInfoTest.java b/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/DomainInfoTest.java
deleted file mode 100644 (file)
index 13ddb54..0000000
+++ /dev/null
@@ -1,225 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Alexandre Montplaisir - Port to JUnit4
- **********************************************************************/
-
-package org.eclipse.tracecompass.lttng2.control.core.tests.model.impl;
-
-import static org.junit.Assert.*;
-
-import java.util.LinkedList;
-import java.util.List;
-
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IChannelInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IDomainInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.DomainInfo;
-import org.junit.Before;
-import org.junit.Test;
-
-/**
- * The class <code>ChannelInfoTest</code> contains tests for the class
- * <code>{@link DomainInfo}</code>.
- */
-public class DomainInfoTest {
-
-    // ------------------------------------------------------------------------
-    // Test data
-    // ------------------------------------------------------------------------
-
-    private IDomainInfo fDomainInfo1 = null;
-    private IDomainInfo fDomainInfo2 = null;
-    private IChannelInfo fChannelInfo1 = null;
-    private IChannelInfo fChannelInfo2 = null;
-
-    // ------------------------------------------------------------------------
-    // Housekeeping
-    // ------------------------------------------------------------------------
-
-    /**
-     * Perform pre-test initialization.
-     */
-    @Before
-    public void setUp() {
-        // Get test instances from the factory
-        ModelImplFactory factory = new ModelImplFactory();
-        fChannelInfo1 = factory.getChannel1();
-        fChannelInfo2 = factory.getChannel2();
-        fDomainInfo1 =  factory.getDomainInfo1();
-        fDomainInfo2 =  factory.getDomainInfo2();
-    }
-
-    // ------------------------------------------------------------------------
-    // Tests
-    // ------------------------------------------------------------------------
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-
-    /**
-     * Run the ChannelInfo() constructor test.
-     */
-    @Test
-    public void testDomainInfo() {
-        DomainInfo result = new DomainInfo("test");
-        assertNotNull(result);
-
-        assertEquals("test", result.getName());
-        assertEquals(0, result.getChannels().length);
-    }
-
-    /**
-     * Test the copy constructor.
-     */
-    @Test
-    public void testDomainInfoCopy() {
-        DomainInfo channelInfo = new DomainInfo((DomainInfo)fDomainInfo1);
-        IChannelInfo[] orignalEvents = fDomainInfo1.getChannels();
-        IChannelInfo[] resultEvents = channelInfo.getChannels();
-        for (int i = 0; i < orignalEvents.length; i++) {
-            assertEquals(orignalEvents[i], resultEvents[i]);
-        }
-    }
-
-    /**
-     * Test the copy constructor.
-     */
-    @Test
-    public void testDomainlCopy2() {
-        try {
-            DomainInfo domain = null;
-            new DomainInfo(domain);
-            fail("null copy");
-        }
-        catch (IllegalArgumentException e) {
-            // Success
-        }
-    }
-
-    /**
-     * Run the long getNumberOfSubBuffers() method test.
-     */
-    @Test
-    public void testGetAndSetters() {
-
-        // Note that addChannel() has been executed in setUp()
-        // check get method here
-        assertEquals(1, fDomainInfo1.getChannels().length);
-        assertNotNull(fDomainInfo1.getChannels()[0]);
-        assertEquals(fChannelInfo1, fDomainInfo1.getChannels()[0]);
-
-        IDomainInfo domain = new DomainInfo("domain");
-        List<IChannelInfo> list = new LinkedList<>();
-        list.add(fChannelInfo1);
-        list.add(fChannelInfo2);
-        domain.setChannels(list);
-
-        IChannelInfo[] result = domain.getChannels();
-        assertEquals(2, result.length);
-        assertEquals(fChannelInfo1, result[0]);
-        assertEquals(fChannelInfo2, result[1]);
-    }
-
-    /**
-     * Run the String toString() method test.
-     */
-    @Test
-    public void testToString_1() {
-        DomainInfo fixture = new DomainInfo("domain");
-
-        String result = fixture.toString();
-
-        assertEquals("[DomainInfo([TraceInfo(Name=domain)],Channels=None,isKernel=false)]", result);
-    }
-
-    /**
-     * Run the String toString() method test.
-     */
-    @Test
-    public void testToString_2() {
-        String result = fDomainInfo1.toString();
-
-        assertEquals("[DomainInfo([TraceInfo(Name=test1)],Channels=[ChannelInfo([TraceInfo(Name=channel1)],State=DISABLED,OverwriteMode=true,SubBuffersSize=13,NumberOfSubBuffers=12,SwitchTimer=10,ReadTimer=11,output=splice(),Events=[EventInfo([BaseEventInfo([TraceInfo(Name=event1)],type=TRACEPOINT,level=TRACE_DEBUG)],State=ENABLED,levelType=LOGLEVEL_ONLY)])],isKernel=false)]", result);
-    }
-
-    // ------------------------------------------------------------------------
-    // equals
-    // ------------------------------------------------------------------------
-
-    /**
-     * Run the equals() method test.
-     */
-    @Test
-    public void testEqualsReflexivity() {
-        assertTrue("equals", fDomainInfo1.equals(fDomainInfo1));
-        assertTrue("equals", fDomainInfo2.equals(fDomainInfo2));
-
-        assertTrue("equals", !fDomainInfo1.equals(fDomainInfo2));
-        assertTrue("equals", !fDomainInfo2.equals(fDomainInfo1));
-    }
-
-    /**
-     * Run the equals() method test.
-     */
-    @Test
-    public void testEqualsSymmetry() {
-        DomainInfo event1 = new DomainInfo((DomainInfo)fDomainInfo1);
-        DomainInfo event2 = new DomainInfo((DomainInfo)fDomainInfo2);
-
-        assertTrue("equals", event1.equals(fDomainInfo1));
-        assertTrue("equals", fDomainInfo1.equals(event1));
-
-        assertTrue("equals", event2.equals(fDomainInfo2));
-        assertTrue("equals", fDomainInfo2.equals(event2));
-    }
-
-    /**
-     * Run the equals() method test.
-     */
-    @Test
-    public void testEqualsTransivity() {
-        DomainInfo channel1 = new DomainInfo((DomainInfo)fDomainInfo1);
-        DomainInfo channel2 = new DomainInfo((DomainInfo)fDomainInfo1);
-        DomainInfo channel3 = new DomainInfo((DomainInfo)fDomainInfo1);
-
-        assertTrue("equals", channel1.equals(channel2));
-        assertTrue("equals", channel2.equals(channel3));
-        assertTrue("equals", channel1.equals(channel3));
-    }
-
-    /**
-     * Run the equals() method test.
-     */
-    @Test
-    public void testEqualsNull() {
-        assertTrue("equals", !fDomainInfo1.equals(null));
-        assertTrue("equals", !fDomainInfo2.equals(null));
-    }
-
-    // ------------------------------------------------------------------------
-    // hashCode
-    // ------------------------------------------------------------------------
-
-    /**
-     * Run the hashCode() method test.
-     */
-    @Test
-    public void testHashCode() {
-        DomainInfo channel1 = new DomainInfo((DomainInfo)fDomainInfo1);
-        DomainInfo channel2 = new DomainInfo((DomainInfo)fDomainInfo2);
-
-        assertTrue("hashCode", fDomainInfo1.hashCode() == channel1.hashCode());
-        assertTrue("hashCode", fDomainInfo2.hashCode() == channel2.hashCode());
-
-        assertTrue("hashCode", fDomainInfo1.hashCode() != channel2.hashCode());
-        assertTrue("hashCode", fDomainInfo2.hashCode() != channel1.hashCode());
-    }
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/EventInfoTest.java b/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/EventInfoTest.java
deleted file mode 100644 (file)
index 4adb740..0000000
+++ /dev/null
@@ -1,366 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Alexandre Montplaisir - Port to JUnit4
- **********************************************************************/
-
-package org.eclipse.tracecompass.lttng2.control.core.tests.model.impl;
-
-import static org.junit.Assert.assertEquals;
-import static org.junit.Assert.assertNotNull;
-import static org.junit.Assert.assertTrue;
-import static org.junit.Assert.fail;
-
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IEventInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.LogLevelType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEnablement;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEventType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.EventInfo;
-import org.junit.Before;
-import org.junit.Test;
-
-/**
- * The class <code>EventInfoTest</code> contains test for the class
- * <code>{@link EventInfo}</code>.
- */
-public class EventInfoTest {
-
-    // ------------------------------------------------------------------------
-    // Test data
-    // ------------------------------------------------------------------------
-
-    private IEventInfo fEventInfo1 = null;
-    private IEventInfo fEventInfo2 = null;
-
-    // ------------------------------------------------------------------------
-    // Housekeeping
-    // ------------------------------------------------------------------------
-
-    /**
-     * Perform pre-test initialization.
-     */
-    @Before
-    public void setUp() {
-        ModelImplFactory factory = new ModelImplFactory();
-        fEventInfo1 = factory.getEventInfo1();
-        fEventInfo2 = factory.getEventInfo2();
-    }
-
-    // ------------------------------------------------------------------------
-    // Tests
-    // ------------------------------------------------------------------------
-
-    /**
-     * Run the EventInfo() constructor test.
-     */
-    @Test
-    public void testBaseEventInfo() {
-        EventInfo fixture = new EventInfo("event");
-        assertNotNull(fixture);
-
-        TraceEventType result = fixture.getEventType();
-
-        assertEquals("event", fixture.getName());
-        assertEquals("unknown", result.getInName());
-        assertEquals("UNKNOWN", result.name());
-        assertEquals("UNKNOWN", result.toString());
-        assertEquals(4, result.ordinal());
-
-        TraceEnablement state = fixture.getState();
-        assertEquals("disabled", state.getInName());
-        assertEquals("DISABLED", state.name());
-        assertEquals("DISABLED", state.toString());
-        assertEquals(0, state.ordinal());
-
-        LogLevelType logType = fixture.getLogLevelType();
-        assertEquals("", logType.getShortName());
-        assertEquals("LOGLEVEL_NONE", logType.name());
-        assertEquals("LOGLEVEL_NONE", logType.toString());
-        assertEquals(0, state.ordinal());
-
-
-    }
-
-    /**
-     * Test Copy Constructor
-     */
-    @Test
-    public void testEventInfoCopy() {
-        EventInfo info = new EventInfo((EventInfo)fEventInfo1);
-
-        assertEquals(fEventInfo1.getName(), info.getName());
-        assertEquals(fEventInfo1.getEventType(), info.getEventType());
-        assertEquals(fEventInfo1.getState(), info.getState());
-        assertEquals(fEventInfo1.getLogLevelType(), info.getLogLevelType());
-    }
-
-    /**
-     * Test Copy Constructor
-     */
-    @Test
-    public void testEventCopy2() {
-        try {
-            EventInfo info = null;
-            new EventInfo(info);
-            fail("null copy");
-        }
-        catch (IllegalArgumentException e) {
-            // Success
-        }
-    }
-
-    /**
-     *  Getter/Setter tests
-     */
-    @Test
-    public void testGetAndSetter() {
-        EventInfo fixture = new EventInfo("event");
-
-        fixture.setEventType(TraceEventType.TRACEPOINT);
-        TraceEventType result = fixture.getEventType();
-
-        // setEventType(TraceEventType type)
-        assertNotNull(result);
-        assertEquals("tracepoint", result.getInName());
-        assertEquals("TRACEPOINT", result.name());
-        assertEquals("TRACEPOINT", result.toString());
-        assertEquals(0, result.ordinal());
-
-        fixture.setEventType(TraceEventType.UNKNOWN);
-        result = fixture.getEventType();
-        assertEquals("unknown", result.getInName());
-        assertEquals("UNKNOWN", result.name());
-        assertEquals("UNKNOWN", result.toString());
-        assertEquals(4, result.ordinal());
-
-        // setEventType(String typeName)
-        String typeName = "";
-        fixture.setEventType(typeName);
-        result = fixture.getEventType();
-
-        assertEquals("unknown", result.getInName());
-        assertEquals("UNKNOWN", result.name());
-        assertEquals("UNKNOWN", result.toString());
-        assertEquals(4, result.ordinal());
-
-        typeName = "unknown";
-
-        fixture.setEventType(typeName);
-        result = fixture.getEventType();
-
-        assertEquals("unknown", result.getInName());
-        assertEquals("UNKNOWN", result.name());
-        assertEquals("UNKNOWN", result.toString());
-        assertEquals(4, result.ordinal());
-
-        // setState(String stateName)
-        fixture.setState("disabled");
-        TraceEnablement state = fixture.getState();
-        assertEquals("disabled", state.getInName());
-        assertEquals("DISABLED", state.name());
-        assertEquals("DISABLED", state.toString());
-        assertEquals(0, state.ordinal());
-
-        fixture.setState("false");
-        state = fixture.getState();
-        assertEquals("false", state.getInMiName());
-        assertEquals("DISABLED", state.name());
-        assertEquals("DISABLED", state.toString());
-        assertEquals(0, state.ordinal());
-
-        fixture.setState("bla");
-        state = fixture.getState();
-        assertEquals("disabled", state.getInName());
-        assertEquals("DISABLED", state.name());
-        assertEquals("DISABLED", state.toString());
-        assertEquals(0, state.ordinal());
-
-        fixture.setState("enabled");
-        state = fixture.getState();
-        assertEquals("enabled", state.getInName());
-        assertEquals("ENABLED", state.name());
-        assertEquals("ENABLED", state.toString());
-        assertEquals(1, state.ordinal());
-
-        fixture.setState("true");
-        state = fixture.getState();
-        assertEquals("true", state.getInMiName());
-        assertEquals("ENABLED", state.name());
-        assertEquals("ENABLED", state.toString());
-        assertEquals(1, state.ordinal());
-
-        // setState(TraceEnablement state)
-        fixture.setState(TraceEnablement.DISABLED);
-        state = fixture.getState();
-        assertEquals("disabled", state.getInName());
-        assertEquals("DISABLED", state.name());
-        assertEquals("DISABLED", state.toString());
-        assertEquals(0, state.ordinal());
-
-        fixture.setState(TraceEnablement.ENABLED);
-        state = fixture.getState();
-        assertEquals("enabled", state.getInName());
-        assertEquals("ENABLED", state.name());
-        assertEquals("ENABLED", state.toString());
-        assertEquals(1, state.ordinal());
-
-        // setLogLevelType(String name)
-        fixture.setLogLevelType("==");
-        assertEquals("LOGLEVEL_ONLY", fixture.getLogLevelType().name());
-        assertEquals("==", fixture.getLogLevelType().getShortName());
-
-        fixture.setLogLevelType("<=");
-        assertEquals("LOGLEVEL", fixture.getLogLevelType().name());
-        assertEquals("<=", fixture.getLogLevelType().getShortName());
-
-        fixture.setLogLevelType("");
-        assertEquals("LOGLEVEL_ALL", fixture.getLogLevelType().name());
-        assertEquals("", fixture.getLogLevelType().getShortName());
-
-        fixture.setLogLevelType(LogLevelType.LOGLEVEL_ONLY);
-        assertEquals("LOGLEVEL_ONLY", fixture.getLogLevelType().name());
-        assertEquals("==", fixture.getLogLevelType().getShortName());
-
-        fixture.setLogLevelType(LogLevelType.LOGLEVEL);
-        assertEquals("LOGLEVEL", fixture.getLogLevelType().name());
-        assertEquals("<=", fixture.getLogLevelType().getShortName());
-
-        fixture.setLogLevelType(LogLevelType.LOGLEVEL_ALL);
-        assertEquals("LOGLEVEL_ALL", fixture.getLogLevelType().name());
-        assertEquals("", fixture.getLogLevelType().getShortName());
-
-        fixture.setLogLevelType(LogLevelType.LOGLEVEL_NONE);
-        assertEquals("LOGLEVEL_NONE", fixture.getLogLevelType().name());
-        assertEquals("", fixture.getLogLevelType().getShortName());
-
-        // setLogLevelType(String name)
-        // machine interface
-        fixture.setLogLevelType("SINGLE");
-        assertEquals("LOGLEVEL_ONLY", fixture.getLogLevelType().name());
-        assertEquals("SINGLE", fixture.getLogLevelType().getMiName());
-
-        fixture.setLogLevelType("RANGE");
-        assertEquals("LOGLEVEL", fixture.getLogLevelType().name());
-        assertEquals("RANGE", fixture.getLogLevelType().getMiName());
-
-        fixture.setLogLevelType("ALL");
-        assertEquals("LOGLEVEL_ALL", fixture.getLogLevelType().name());
-        assertEquals("ALL", fixture.getLogLevelType().getMiName());
-
-        fixture.setLogLevelType("UNKNOWN");
-        assertEquals("LOGLEVEL_NONE", fixture.getLogLevelType().name());
-        assertEquals("UNKNOWN", fixture.getLogLevelType().getMiName());
-
-    }
-
-    /**
-     * Run the String toString() method test.
-     */
-    @Test
-    public void testToString_1() {
-        EventInfo fixture = new EventInfo("event");
-        fixture.setName("testName");
-        fixture.setEventType(TraceEventType.TRACEPOINT);
-
-        String result = fixture.toString();
-
-        // add additional test code here
-        assertEquals("[EventInfo([BaseEventInfo([TraceInfo(Name=testName)],type=TRACEPOINT,level=TRACE_DEBUG)],State=DISABLED,levelType=LOGLEVEL_NONE)]", result);
-    }
-
-    /**
-     * Run the String toString() method test.
-     */
-    @Test
-    public void testToString_2() {
-        EventInfo fixture = new EventInfo("event");
-        fixture.setName("testName");
-        fixture.setEventType(TraceEventType.TRACEPOINT);
-        fixture.setLogLevelType(LogLevelType.LOGLEVEL_ONLY);
-
-        String result = fixture.toString();
-
-        // add additional test code here
-        assertEquals("[EventInfo([BaseEventInfo([TraceInfo(Name=testName)],type=TRACEPOINT,level=TRACE_DEBUG)],State=DISABLED,levelType=LOGLEVEL_ONLY)]", result);
-    }
-
-    // ------------------------------------------------------------------------
-    // equals
-    // ------------------------------------------------------------------------
-
-    /**
-     * Run the equals() method test.
-     */
-    @Test
-    public void testEqualsReflexivity() {
-        assertTrue("equals", fEventInfo1.equals(fEventInfo1));
-        assertTrue("equals", fEventInfo2.equals(fEventInfo2));
-
-        assertTrue("equals", !fEventInfo1.equals(fEventInfo2));
-        assertTrue("equals", !fEventInfo2.equals(fEventInfo1));
-    }
-
-    /**
-     * Run the equals() method test.
-     */
-    @Test
-    public void testEqualsSymmetry() {
-        EventInfo info1 = new EventInfo((EventInfo)fEventInfo1);
-        EventInfo info2 = new EventInfo((EventInfo)fEventInfo2);
-
-        assertTrue("equals", info1.equals(fEventInfo1));
-        assertTrue("equals", fEventInfo1.equals(info1));
-
-        assertTrue("equals", info2.equals(fEventInfo2));
-        assertTrue("equals", fEventInfo2.equals(info2));
-    }
-
-    /**
-     * Run the equals() method test.
-     */
-    @Test
-    public void testEqualsTransivity() {
-        EventInfo info1 = new EventInfo((EventInfo)fEventInfo1);
-        EventInfo info2 = new EventInfo((EventInfo)fEventInfo1);
-        EventInfo info3 = new EventInfo((EventInfo)fEventInfo1);
-
-        assertTrue("equals", info1.equals(info2));
-        assertTrue("equals", info2.equals(info3));
-        assertTrue("equals", info1.equals(info3));
-    }
-
-    /**
-     * Run the equals() method test.
-     */
-    @Test
-    public void testEqualsNull() {
-        assertTrue("equals", !fEventInfo1.equals(null));
-        assertTrue("equals", !fEventInfo2.equals(null));
-    }
-
-    // ------------------------------------------------------------------------
-    // hashCode
-    // ------------------------------------------------------------------------
-
-    /**
-     * Run the hashCode() method test.
-     */
-    @Test
-    public void testHashCode() {
-        EventInfo info1 = new EventInfo((EventInfo)fEventInfo1);
-        EventInfo info2 = new EventInfo((EventInfo)fEventInfo2);
-
-        assertTrue("hashCode", fEventInfo1.hashCode() == info1.hashCode());
-        assertTrue("hashCode", fEventInfo2.hashCode() == info2.hashCode());
-
-        assertTrue("hashCode", fEventInfo1.hashCode() != info2.hashCode());
-        assertTrue("hashCode", fEventInfo2.hashCode() != info1.hashCode());
-    }
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/FieldInfoTest.java b/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/FieldInfoTest.java
deleted file mode 100644 (file)
index 22f37ec..0000000
+++ /dev/null
@@ -1,186 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Alexandre Montplaisir - Port to JUnit4
- **********************************************************************/
-
-package org.eclipse.tracecompass.lttng2.control.core.tests.model.impl;
-
-import static org.junit.Assert.*;
-
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IFieldInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.FieldInfo;
-import org.junit.Before;
-import org.junit.Test;
-
-/**
- * The class <code>FieldInfoTest</code> contains test for the class
- * <code>{@link FieldInfo}</code>.
- */
-public class FieldInfoTest {
-
-    // ------------------------------------------------------------------------
-    // Test data
-    // ------------------------------------------------------------------------
-
-    private IFieldInfo fFieldInfo1 = null;
-    private IFieldInfo fFieldInfo2 = null;
-
-    // ------------------------------------------------------------------------
-    // Housekeeping
-    // ------------------------------------------------------------------------
-
-    /**
-     * Perform pre-test initialization.
-     */
-    @Before
-    public void setUp() {
-        ModelImplFactory factory = new ModelImplFactory();
-        fFieldInfo1 = factory.getFieldInfo1();
-        fFieldInfo2 = factory.getFieldInfo2();
-    }
-
-    // ------------------------------------------------------------------------
-    // Tests
-    // ------------------------------------------------------------------------
-
-    /**
-     * Run the BaseEventInfo() constructor test.
-     */
-    @Test
-    public void testFiledInfo() {
-        FieldInfo fixture = new FieldInfo("field");
-        assertNotNull(fixture);
-
-        assertEquals("field", fixture.getName());
-        assertNull(fixture.getFieldType());
-    }
-
-    /**
-     * Test Copy Constructor
-     */
-    @Test
-    public void testEventInfoCopy() {
-        FieldInfo info = new FieldInfo((FieldInfo)fFieldInfo1);
-
-        assertEquals(fFieldInfo1.getName(), info.getName());
-        assertEquals(fFieldInfo1.getFieldType(), info.getFieldType());
-    }
-
-    /**
-     * Test Copy Constructor
-     */
-    @Test
-    public void testEventCopy2() {
-        try {
-            FieldInfo info = null;
-            new FieldInfo(info);
-            fail("null copy");
-        }
-        catch (IllegalArgumentException e) {
-            // Success
-        }
-    }
-
-    /**
-     * Run the TraceEventType getEventType() method test.
-     */
-    @Test
-    public void testSetFieldType() {
-        FieldInfo info = new FieldInfo((FieldInfo)fFieldInfo1);
-
-        info.setFieldType("string");
-        assertEquals("string", info.getFieldType());
-    }
-
-    /**
-     * Run the toString() method test.
-     */
-    @Test
-    public void testToString() {
-        String result = fFieldInfo1.toString();
-
-        // add additional test code here
-        assertEquals("[FieldInfo([TraceInfo(Name=intfield)],type=int", result);
-    }
-
-    // ------------------------------------------------------------------------
-    // equals
-    // ------------------------------------------------------------------------
-
-    /**
-     * Run the equals() method test.
-     */
-    @Test
-    public void testEqualsReflexivity() {
-        assertTrue("equals", fFieldInfo1.equals(fFieldInfo1));
-        assertTrue("equals", fFieldInfo2.equals(fFieldInfo2));
-
-        assertTrue("equals", !fFieldInfo1.equals(fFieldInfo2));
-        assertTrue("equals", !fFieldInfo2.equals(fFieldInfo1));
-    }
-
-    /**
-     * Run the equals() method test.
-     */
-    @Test
-    public void testEqualsSymmetry() {
-        FieldInfo info1 = new FieldInfo((FieldInfo)fFieldInfo1);
-        FieldInfo info2 = new FieldInfo((FieldInfo)fFieldInfo2);
-
-        assertTrue("equals", info1.equals(fFieldInfo1));
-        assertTrue("equals", fFieldInfo1.equals(info1));
-
-        assertTrue("equals", info2.equals(fFieldInfo2));
-        assertTrue("equals", fFieldInfo2.equals(info2));
-    }
-
-    /**
-     * Run the equals() method test.
-     */
-    @Test
-    public void testEqualsTransivity() {
-        FieldInfo info1 = new FieldInfo((FieldInfo)fFieldInfo1);
-        FieldInfo info2 = new FieldInfo((FieldInfo)fFieldInfo1);
-        FieldInfo info3 = new FieldInfo((FieldInfo)fFieldInfo1);
-
-        assertTrue("equals", info1.equals(info2));
-        assertTrue("equals", info2.equals(info3));
-        assertTrue("equals", info1.equals(info3));
-    }
-
-    /**
-     * Run the equals() method test.
-     */
-    @Test
-    public void testEqualsNull() {
-        assertTrue("equals", !fFieldInfo1.equals(null));
-        assertTrue("equals", !fFieldInfo2.equals(null));
-    }
-
-    // ------------------------------------------------------------------------
-    // hashCode
-    // ------------------------------------------------------------------------
-
-    /**
-     * Run the equals() method test.
-     */
-    @Test
-    public void testHashCode() {
-        FieldInfo info1 = new FieldInfo((FieldInfo)fFieldInfo1);
-        FieldInfo info2 = new FieldInfo((FieldInfo)fFieldInfo2);
-
-        assertTrue("hashCode", fFieldInfo1.hashCode() == info1.hashCode());
-        assertTrue("hashCode", fFieldInfo2.hashCode() == info2.hashCode());
-
-        assertTrue("hashCode", fFieldInfo1.hashCode() != info2.hashCode());
-        assertTrue("hashCode", fFieldInfo2.hashCode() != info1.hashCode());
-    }
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/ModelImplFactory.java b/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/ModelImplFactory.java
deleted file mode 100644 (file)
index 1177772..0000000
+++ /dev/null
@@ -1,244 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.control.core.tests.model.impl;
-
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IBaseEventInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IChannelInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IDomainInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IEventInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IFieldInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IProbeEventInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISessionInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISnapshotInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IUstProviderInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEnablement;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEventType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.BaseEventInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.ChannelInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.DomainInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.EventInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.FieldInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.ProbeEventInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.SessionInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.SnapshotInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.UstProviderInfo;
-
-/**
- *  Test facility to constants across test case
- */
-@SuppressWarnings("javadoc")
-public class ModelImplFactory {
-
-    private ISessionInfo fSessionInfo1 = null;
-    private ISessionInfo fSessionInfo2 = null;
-    private IDomainInfo fDomainInfo1 = null;
-    private IDomainInfo fDomainInfo2 = null;
-    private IChannelInfo fChannelInfo1 = null;
-    private IChannelInfo fChannelInfo2 = null;
-    private IEventInfo fEventInfo1 = null;
-    private IEventInfo fEventInfo2 = null;
-    private IEventInfo fEventInfo3 = null;
-    private IFieldInfo fFieldInfo1 = null;
-    private IFieldInfo fFieldInfo2 = null;
-    private IBaseEventInfo fBaseEventInfo1 = null;
-    private IBaseEventInfo fBaseEventInfo2 = null;
-    private IUstProviderInfo fUstProviderInfo1 = null;
-    private IUstProviderInfo fUstProviderInfo2 = null;
-    private IProbeEventInfo fProbeEventInfo1 = null;
-    private IProbeEventInfo fProbeEventInfo2 = null;
-    private ISnapshotInfo fSnapshotInfo1 = null;
-    private ISnapshotInfo fSnapshotInfo2 = null;
-
-    public ModelImplFactory() {
-
-        fFieldInfo1 = new FieldInfo("intfield");
-        fFieldInfo1.setFieldType("int");
-        fFieldInfo2 = new FieldInfo("stringfield");
-        fFieldInfo2.setFieldType("string");
-
-        fBaseEventInfo1 = new BaseEventInfo("event1");
-        fBaseEventInfo1.setEventType(TraceEventType.UNKNOWN);
-        fBaseEventInfo1.setLogLevel(TraceLogLevel.TRACE_ERR);
-        fBaseEventInfo1.addField(fFieldInfo1);
-        fBaseEventInfo1.addField(fFieldInfo2);
-        fBaseEventInfo1.setFilterExpression("intField==10");
-
-        fBaseEventInfo2 = new BaseEventInfo("event2");
-        fBaseEventInfo2.setEventType(TraceEventType.TRACEPOINT);
-        fBaseEventInfo1.setLogLevel(TraceLogLevel.TRACE_DEBUG);
-
-        fEventInfo1 = new EventInfo("event1");
-        fEventInfo1.setEventType(TraceEventType.TRACEPOINT);
-        fEventInfo1.setLogLevelType("==");
-        fEventInfo1.setLogLevel(TraceLogLevel.TRACE_DEBUG);
-        fEventInfo1.setState(TraceEnablement.ENABLED);
-
-        fEventInfo2 = new EventInfo("event2");
-        fEventInfo2.setLogLevelType("<=");
-        fEventInfo2.setLogLevel(TraceLogLevel.TRACE_INFO);
-        fEventInfo2.setEventType(TraceEventType.UNKNOWN);
-        fEventInfo2.setState(TraceEnablement.DISABLED);
-
-        fEventInfo3 = new EventInfo("event3");
-        fEventInfo3.setEventType(TraceEventType.TRACEPOINT);
-        fEventInfo3.setState(TraceEnablement.DISABLED);
-
-        fUstProviderInfo1 = new UstProviderInfo("myUST1");
-        fUstProviderInfo1.setPid(1234);
-        fUstProviderInfo1.addEvent(fBaseEventInfo1);
-
-        fUstProviderInfo2 = new UstProviderInfo("myUST2");
-        fUstProviderInfo2.setPid(2345);
-        fUstProviderInfo2.addEvent(fBaseEventInfo1);
-        fUstProviderInfo2.addEvent(fBaseEventInfo2);
-
-        fChannelInfo1 = new ChannelInfo("channel1");
-        fChannelInfo1.setSwitchTimer(10L);
-        fChannelInfo1.setOverwriteMode(true);
-        fChannelInfo1.setReadTimer(11L);
-        fChannelInfo1.setState(TraceEnablement.DISABLED);
-        fChannelInfo1.setNumberOfSubBuffers(12);
-        fChannelInfo1.setOutputType("splice()");
-        fChannelInfo1.setSubBufferSize(13L);
-        fChannelInfo1.addEvent(fEventInfo1);
-
-        fChannelInfo2 = new ChannelInfo("channel2");
-        fChannelInfo2.setSwitchTimer(1L);
-        fChannelInfo2.setOverwriteMode(false);
-        fChannelInfo2.setReadTimer(2L);
-        fChannelInfo2.setState(TraceEnablement.ENABLED);
-        fChannelInfo2.setNumberOfSubBuffers(3);
-        fChannelInfo2.setOutputType("mmap()");
-        fChannelInfo2.setSubBufferSize(4L);
-        fChannelInfo2.addEvent(fEventInfo2);
-        fChannelInfo2.addEvent(fEventInfo3);
-
-        fDomainInfo1 = new DomainInfo("test1");
-        fDomainInfo1.addChannel(fChannelInfo1);
-
-        fDomainInfo2 = new DomainInfo("test2");
-        fDomainInfo2.addChannel(fChannelInfo1);
-        fDomainInfo2.addChannel(fChannelInfo2);
-
-        fSessionInfo1 = new SessionInfo("session1");
-        fSessionInfo1.setSessionPath("/home/user");
-        fSessionInfo1.setSessionState(TraceSessionState.ACTIVE);
-        fSessionInfo1.addDomain(fDomainInfo1);
-
-        fSessionInfo2 = new SessionInfo("session2");
-        fSessionInfo2.setSessionPath("/home/user1");
-        fSessionInfo2.setSessionState(TraceSessionState.INACTIVE);
-        fSessionInfo2.addDomain(fDomainInfo1);
-        fSessionInfo2.addDomain(fDomainInfo2);
-        fSessionInfo2.setStreamedTrace(true);
-
-        fProbeEventInfo1 = new ProbeEventInfo("probeEvent1");
-        fProbeEventInfo1.setEventType(TraceEventType.TRACEPOINT);
-        fProbeEventInfo1.setState(TraceEnablement.ENABLED);
-        fProbeEventInfo1.setAddress("0xc1231234");
-
-        fProbeEventInfo2 = new ProbeEventInfo("probeEvent2");
-        fProbeEventInfo2.setEventType(TraceEventType.FUNCTION);
-        fProbeEventInfo2.setState(TraceEnablement.DISABLED);
-        fProbeEventInfo2.setOffset("0x100");
-        fProbeEventInfo2.setSymbol("init_post");
-
-        fSnapshotInfo1 = new SnapshotInfo("snapshot-1");
-        fSnapshotInfo1.setId(1);
-        fSnapshotInfo1.setSnapshotPath("/home/user/lttng-trace/mysession/");
-        fSnapshotInfo2 = new SnapshotInfo("other-snapshot");
-        fSnapshotInfo2.setId(1);
-        fSnapshotInfo2.setSnapshotPath("net4://172.0.0.1:1234/");
-        fSnapshotInfo2.setStreamedSnapshot(true);
-
-        fSessionInfo1.setSnapshotInfo(fSnapshotInfo1);
-    }
-
-    public ISessionInfo getSessionInfo1() {
-        return fSessionInfo1;
-    }
-
-    public ISessionInfo getSessionInfo2() {
-        return fSessionInfo2;
-    }
-
-    public IDomainInfo getDomainInfo1() {
-        return fDomainInfo1;
-    }
-
-    public IDomainInfo getDomainInfo2() {
-        return fDomainInfo2;
-    }
-
-    public IChannelInfo getChannel1() {
-        return fChannelInfo1;
-    }
-
-    public IChannelInfo getChannel2() {
-        return fChannelInfo2;
-    }
-
-    public IEventInfo getEventInfo1() {
-        return fEventInfo1;
-    }
-
-    public IEventInfo getEventInfo2() {
-        return fEventInfo2;
-    }
-
-    public IEventInfo getEventInfo3() {
-        return fEventInfo3;
-    }
-
-    public IBaseEventInfo getBaseEventInfo1() {
-        return fBaseEventInfo1;
-    }
-
-    public IBaseEventInfo getBaseEventInfo2() {
-        return fBaseEventInfo2;
-    }
-
-    public IUstProviderInfo getUstProviderInfo1() {
-        return fUstProviderInfo1;
-    }
-
-    public IUstProviderInfo getUstProviderInfo2() {
-        return fUstProviderInfo2;
-    }
-
-    public IProbeEventInfo getProbeEventInfo1() {
-        return fProbeEventInfo1;
-    }
-
-    public IProbeEventInfo getProbeEventInfo2() {
-        return fProbeEventInfo2;
-    }
-
-    public IFieldInfo getFieldInfo1() {
-        return fFieldInfo1;
-    }
-
-    public IFieldInfo getFieldInfo2() {
-        return fFieldInfo2;
-    }
-
-    public ISnapshotInfo getSnapshotInfo1() {
-        return fSnapshotInfo1;
-    }
-
-    public ISnapshotInfo getSnapshotInfo2() {
-        return fSnapshotInfo2;
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/ProbeEventInfoTest.java b/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/ProbeEventInfoTest.java
deleted file mode 100644 (file)
index caa8d51..0000000
+++ /dev/null
@@ -1,219 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Alexandre Montplaisir - Port to JUnit4
- **********************************************************************/
-
-package org.eclipse.tracecompass.lttng2.control.core.tests.model.impl;
-
-import static org.junit.Assert.*;
-
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IProbeEventInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEnablement;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEventType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.ProbeEventInfo;
-import org.junit.Before;
-import org.junit.Test;
-
-/**
- * The class <code>ProbEventInfoTest</code> contains test for the class
- * <code>{@link ProbeEventInfo}</code>.
- */
-public class ProbeEventInfoTest {
-
-    // ------------------------------------------------------------------------
-    // Test data
-    // ------------------------------------------------------------------------
-
-    private IProbeEventInfo fEventInfo1 = null;
-    private IProbeEventInfo fEventInfo2 = null;
-
-    // ------------------------------------------------------------------------
-    // Housekeeping
-    // ------------------------------------------------------------------------
-    /**
-     * Perform pre-test initialization.
-     */
-    @Before
-    public void setUp() {
-        ModelImplFactory factory = new ModelImplFactory();
-        fEventInfo1 = factory.getProbeEventInfo1();
-        fEventInfo2 = factory.getProbeEventInfo2();
-    }
-
-    // ------------------------------------------------------------------------
-    // Tests
-    // ------------------------------------------------------------------------
-
-    /**
-     * Run the BaseEventInfo() constructor test.
-     */
-    @Test
-    public void testBaseEventInfo() {
-        ProbeEventInfo fixture = new ProbeEventInfo("event");
-        assertNotNull(fixture);
-
-        TraceEventType result = fixture.getEventType();
-
-        assertEquals("event", fixture.getName());
-        assertEquals("unknown", result.getInName());
-        assertEquals("UNKNOWN", result.name());
-        assertEquals("UNKNOWN", result.toString());
-        assertEquals(4, result.ordinal());
-
-        TraceEnablement state = fixture.getState();
-        assertEquals("disabled", state.getInName());
-        assertEquals("DISABLED", state.name());
-        assertEquals("DISABLED", state.toString());
-        assertEquals(0, state.ordinal());
-
-        assertNull(fixture.getAddress());
-        assertNull(fixture.getOffset());
-        assertNull(fixture.getSymbol());
-    }
-
-    /**
-     * Test Copy Constructor
-     */
-    @Test
-    public void testEventInfoCopy() {
-        ProbeEventInfo info = new ProbeEventInfo((ProbeEventInfo)fEventInfo1);
-
-        assertEquals(fEventInfo1.getName(), info.getName());
-        assertEquals(fEventInfo1.getEventType(), info.getEventType());
-        assertEquals(fEventInfo1.getState(), info.getState());
-        assertEquals(fEventInfo1.getAddress(), info.getAddress());
-        assertEquals(fEventInfo1.getOffset(), info.getOffset());
-        assertEquals(fEventInfo1.getSymbol(), info.getSymbol());
-    }
-
-    /**
-     * Test Copy Constructor
-     */
-    @Test
-    public void testEventCopy2() {
-        try {
-            ProbeEventInfo info = null;
-            new ProbeEventInfo(info);
-            fail("null copy");
-        }
-        catch (IllegalArgumentException e) {
-            // Success
-        }
-    }
-
-    /**
-     *  Getter/Setter tests
-     */
-    @Test
-    public void testGetAndSetter() {
-        ProbeEventInfo fixture = new ProbeEventInfo("event");
-
-        fixture.setAddress("0xc12344321");
-        String result = fixture.getAddress();
-
-        assertNotNull(result);
-        assertEquals("0xc12344321", result);
-
-        fixture.setOffset("0x1000");
-        result = fixture.getOffset();
-
-        assertNotNull(result);
-        assertEquals("0x1000", result);
-
-        fixture.setSymbol("cpu_idle");
-        result = fixture.getSymbol();
-
-        assertNotNull(result);
-        assertEquals("cpu_idle", result);
-    }
-
-    /**
-     * Run the String toString() method test.
-     */
-    @Test
-    public void testToString_1() {
-        assertEquals("[ProbeEventInfo([EventInfo([BaseEventInfo([TraceInfo(Name=probeEvent1)],type=TRACEPOINT,level=TRACE_DEBUG)],State=ENABLED,levelType=LOGLEVEL_NONE)],fAddress=0xc1231234)]", fEventInfo1.toString());
-        assertEquals("[ProbeEventInfo([EventInfo([BaseEventInfo([TraceInfo(Name=probeEvent2)],type=FUNCTION,level=TRACE_DEBUG)],State=DISABLED,levelType=LOGLEVEL_NONE)],fOffset=0x100,fSymbol=init_post)]", fEventInfo2.toString());
-    }
-
-    // ------------------------------------------------------------------------
-    // equals
-    // ------------------------------------------------------------------------
-
-    /**
-     * Run the equals() method test.
-     */
-    @Test
-    public void testEqualsReflexivity() {
-        assertTrue("equals", fEventInfo1.equals(fEventInfo1));
-        assertTrue("equals", fEventInfo2.equals(fEventInfo2));
-
-        assertTrue("equals", !fEventInfo1.equals(fEventInfo2));
-        assertTrue("equals", !fEventInfo2.equals(fEventInfo1));
-    }
-
-    /**
-     * Run the equals() method test.
-     */
-    @Test
-    public void testEqualsSymmetry() {
-        ProbeEventInfo info1 = new ProbeEventInfo((ProbeEventInfo)fEventInfo1);
-        ProbeEventInfo info2 = new ProbeEventInfo((ProbeEventInfo)fEventInfo2);
-
-        assertTrue("equals", info1.equals(fEventInfo1));
-        assertTrue("equals", fEventInfo1.equals(info1));
-
-        assertTrue("equals", info2.equals(fEventInfo2));
-        assertTrue("equals", fEventInfo2.equals(info2));
-    }
-
-    /**
-     * Run the equals() method test.
-     */
-    @Test
-    public void testEqualsTransivity() {
-        ProbeEventInfo info1 = new ProbeEventInfo((ProbeEventInfo)fEventInfo1);
-        ProbeEventInfo info2 = new ProbeEventInfo((ProbeEventInfo)fEventInfo1);
-        ProbeEventInfo info3 = new ProbeEventInfo((ProbeEventInfo)fEventInfo1);
-
-        assertTrue("equals", info1.equals(info2));
-        assertTrue("equals", info2.equals(info3));
-        assertTrue("equals", info1.equals(info3));
-    }
-
-    /**
-     * Run the equals() method test.
-     */
-    @Test
-    public void testEqualsNull() {
-        assertTrue("equals", !fEventInfo1.equals(null));
-        assertTrue("equals", !fEventInfo2.equals(null));
-    }
-
-    // ------------------------------------------------------------------------
-    // hashCode
-    // ------------------------------------------------------------------------
-
-    /**
-     * Run the hashCode() method test.
-     */
-    @Test
-    public void testHashCode() {
-        ProbeEventInfo info1 = new ProbeEventInfo((ProbeEventInfo)fEventInfo1);
-        ProbeEventInfo info2 = new ProbeEventInfo((ProbeEventInfo)fEventInfo2);
-
-        assertTrue("hashCode", fEventInfo1.hashCode() == info1.hashCode());
-        assertTrue("hashCode", fEventInfo2.hashCode() == info2.hashCode());
-
-        assertTrue("hashCode", fEventInfo1.hashCode() != info2.hashCode());
-        assertTrue("hashCode", fEventInfo2.hashCode() != info1.hashCode());
-    }
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/SessionInfoTest.java b/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/SessionInfoTest.java
deleted file mode 100644 (file)
index 3d50aa5..0000000
+++ /dev/null
@@ -1,311 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Alexandre Montplaisir - Port to JUnit4
- **********************************************************************/
-
-package org.eclipse.tracecompass.lttng2.control.core.tests.model.impl;
-
-import static org.junit.Assert.*;
-
-import java.util.LinkedList;
-import java.util.List;
-
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IDomainInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISessionInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.SessionInfo;
-import org.junit.Before;
-import org.junit.Test;
-
-/**
- * The class <code>ChannelInfoTest</code> contains tests for the class
- * <code>{@link SessionInfo}</code>.
- */
-public class SessionInfoTest {
-
-    // ------------------------------------------------------------------------
-    // Test data
-    // ------------------------------------------------------------------------
-
-    private ISessionInfo fSessionInfo1 = null;
-    private ISessionInfo fSessionInfo2 = null;
-
-    private IDomainInfo fDomainInfo1 = null;
-    private IDomainInfo fDomainInfo2 = null;
-
-    // ------------------------------------------------------------------------
-    // Housekeeping
-    // ------------------------------------------------------------------------
-
-    /**
-     * Perform pre-test initialization.
-     */
-    @Before
-    public void setUp() {
-        ModelImplFactory factory = new ModelImplFactory();
-        fSessionInfo1 = factory.getSessionInfo1();
-        fDomainInfo1 = factory.getDomainInfo1();
-        fSessionInfo2 = factory.getSessionInfo2();
-        fDomainInfo2 = factory.getDomainInfo2();
-    }
-
-    // ------------------------------------------------------------------------
-    // Tests
-    // ------------------------------------------------------------------------
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-
-    /**
-     * Run the ChannelInfo() constructor test.
-     */
-    @Test
-    public void testSessionInfo() {
-        ISessionInfo result = new SessionInfo("test");
-        assertNotNull(result);
-
-        assertEquals("test", result.getName());
-        assertEquals("", result.getSessionPath());
-        TraceSessionState state = result.getSessionState();
-        assertEquals("inactive", state.getInName());
-        assertEquals("INACTIVE", state.name());
-        assertEquals("INACTIVE", state.toString());
-        assertEquals(0, state.ordinal());
-        assertEquals(0, result.getDomains().length);
-        assertFalse(result.isSnapshotSession());
-        assertNull(result.getNetworkUrl());
-        assertNull(result.getControlUrl());
-        assertNull(result.getDataUrl());
-    }
-
-    /**
-     * Test copy constructor.
-     */
-    @Test
-    public void testSessionInfoCopy() {
-        SessionInfo sessionInfo = new SessionInfo((SessionInfo)fSessionInfo1);
-
-        assertEquals(sessionInfo.getName(), fSessionInfo1.getName());
-        assertEquals(sessionInfo.getSessionPath(), fSessionInfo1.getSessionPath());
-        assertEquals(sessionInfo.getSessionState(), fSessionInfo1.getSessionState());
-
-        IDomainInfo[] orignalDomains = fSessionInfo1.getDomains();
-        IDomainInfo[] resultDomains = sessionInfo.getDomains();
-        for (int i = 0; i < orignalDomains.length; i++) {
-            assertEquals(orignalDomains[i], resultDomains[i]);
-        }
-
-        assertEquals(sessionInfo.getNetworkUrl(), fSessionInfo1.getNetworkUrl());
-        assertEquals(sessionInfo.getControlUrl(), fSessionInfo1.getControlUrl());
-        assertEquals(sessionInfo.getDataUrl(), fSessionInfo1.getDataUrl());
-    }
-
-    /**
-     * Test copy constructor.
-     */
-    @Test
-    public void testSessionCopy2() {
-        try {
-            SessionInfo session = null;
-            new SessionInfo(session);
-            fail("null copy");
-        }
-        catch (IllegalArgumentException e) {
-            // Success
-        }
-    }
-
-    /**
-     * Run the long getNumberOfSubBuffers() method test.
-     */
-    @Test
-    public void testGetAndSetters() {
-
-        // Note that addDomain() has been executed in setUp()
-        // check get method here
-        assertEquals(1, fSessionInfo1.getDomains().length);
-        assertNotNull(fSessionInfo1.getDomains()[0]);
-        assertEquals(fDomainInfo1, fSessionInfo1.getDomains()[0]);
-
-        ISessionInfo session = new SessionInfo("session");
-        List<IDomainInfo> list = new LinkedList<>();
-        list.add(fDomainInfo1);
-        list.add(fDomainInfo2);
-        session.setDomains(list);
-
-        IDomainInfo[] result = session.getDomains();
-        assertEquals(2, result.length);
-        assertEquals(fDomainInfo1, result[0]);
-        assertEquals(fDomainInfo2, result[1]);
-
-        session.setSessionPath("/home/user");
-        assertEquals("/home/user", session.getSessionPath());
-
-        session.setSessionState("active");
-        TraceSessionState state = session.getSessionState();
-        state = session.getSessionState();
-        assertEquals("active", state.getInName());
-        assertEquals("ACTIVE", state.name());
-        assertEquals("ACTIVE", state.toString());
-        assertEquals(1, state.ordinal());
-
-        session.setSessionState("inactive");
-        state = session.getSessionState();
-        assertEquals("inactive", state.getInName());
-        assertEquals("INACTIVE", state.name());
-        assertEquals("INACTIVE", state.toString());
-        assertEquals(0, state.ordinal());
-
-        session.setSessionState("test");
-        state = session.getSessionState();
-        assertEquals("inactive", state.getInName());
-        assertEquals("INACTIVE", state.name());
-        assertEquals("INACTIVE", state.toString());
-        assertEquals(0, state.ordinal());
-
-        session.setSessionState(TraceSessionState.ACTIVE);
-        state = session.getSessionState();
-        assertEquals("active", state.getInName());
-        assertEquals("ACTIVE", state.name());
-        assertEquals("ACTIVE", state.toString());
-        assertEquals(1, state.ordinal());
-
-        session.setSessionState(TraceSessionState.INACTIVE);
-        state = session.getSessionState();
-        assertEquals("inactive", state.getInName());
-        assertEquals("INACTIVE", state.name());
-        assertEquals("INACTIVE", state.toString());
-        assertEquals(0, state.ordinal());
-    }
-
-    /**
-     * Run the String toString() method test.
-     */
-    @Test
-    public void testToString_1() {
-        ISessionInfo fixture = new SessionInfo("sessionName");
-
-        String result = fixture.toString();
-
-        // add additional test code here
-        assertEquals("[SessionInfo([TraceInfo(Name=sessionName)],Path=,State=INACTIVE,isStreamedTrace=false,isSnapshot=false,Domains=,NetworkUrl=null,ControlUrl=null,DataUrl=null)]", result);
-    }
-
-    /**
-     * Run the String toString() method test.
-     */
-    @Test
-    public void testToString_2() {
-        String result = fSessionInfo1.toString();
-
-        // add additional test code here
-        assertEquals("[SessionInfo([TraceInfo(Name=session1)],Path=/home/user/lttng-trace/mysession/,State=ACTIVE,isStreamedTrace=false,isSnapshot=false,snapshotInfo="
-                + "[SnapshotInfo([TraceInfo(Name=snapshot-1)],snapshotPath=/home/user/lttng-trace/mysession/,ID=1,isStreamedSnapshot=false)],"
-                    + "Domains=[DomainInfo([TraceInfo(Name=test1)],"
-                        + "Channels=[ChannelInfo([TraceInfo(Name=channel1)],State=DISABLED,OverwriteMode=true,SubBuffersSize=13,NumberOfSubBuffers=12,SwitchTimer=10,ReadTimer=11,output=splice(),"
-                            + "Events=[EventInfo([BaseEventInfo([TraceInfo(Name=event1)],type=TRACEPOINT,level=TRACE_DEBUG)],State=ENABLED,levelType=LOGLEVEL_ONLY)])],"
-                + "isKernel=false)],NetworkUrl=null,ControlUrl=null,DataUrl=null)]", result);
-    }
-
-    /**
-     * Run the String toString() method test.
-     */
-    @Test
-    public void testToString_3() {
-        SessionInfo info = new SessionInfo((SessionInfo)fSessionInfo1);
-        info.setSnapshot(false);
-        info.setSnapshotInfo(null);
-        info.setSessionPath("/home/user/lttng-trace/mysession/");
-
-        String result = info.toString();
-
-        // add additional test code here
-        assertEquals("[SessionInfo([TraceInfo(Name=session1)],Path=/home/user/lttng-trace/mysession/,State=ACTIVE,isStreamedTrace=false,isSnapshot=false,"
-                    + "Domains=[DomainInfo([TraceInfo(Name=test1)],"
-                        + "Channels=[ChannelInfo([TraceInfo(Name=channel1)],State=DISABLED,OverwriteMode=true,SubBuffersSize=13,NumberOfSubBuffers=12,SwitchTimer=10,ReadTimer=11,output=splice(),"
-                            + "Events=[EventInfo([BaseEventInfo([TraceInfo(Name=event1)],type=TRACEPOINT,level=TRACE_DEBUG)],State=ENABLED,levelType=LOGLEVEL_ONLY)])],"
-                + "isKernel=false)],NetworkUrl=null,ControlUrl=null,DataUrl=null)]", result);
-    }
-
-    // ------------------------------------------------------------------------
-    // equals
-    // ------------------------------------------------------------------------
-
-    /**
-     * Run the {@link SessionInfo#equals} method test.
-     */
-    @Test
-    public void testEqualsReflexivity() {
-        assertTrue("equals", fSessionInfo1.equals(fSessionInfo1));
-        assertTrue("equals", fSessionInfo2.equals(fSessionInfo2));
-
-        assertTrue("equals", !fSessionInfo1.equals(fSessionInfo2));
-        assertTrue("equals", !fSessionInfo2.equals(fSessionInfo1));
-    }
-
-    /**
-     * Run the {@link SessionInfo#equals} method test.
-     */
-    @Test
-    public void testEqualsSymmetry() {
-        SessionInfo event1 = new SessionInfo((SessionInfo)fSessionInfo1);
-        SessionInfo event2 = new SessionInfo((SessionInfo)fSessionInfo2);
-
-        assertTrue("equals", event1.equals(fSessionInfo1));
-        assertTrue("equals", fSessionInfo1.equals(event1));
-
-        assertTrue("equals", event2.equals(fSessionInfo2));
-        assertTrue("equals", fSessionInfo2.equals(event2));
-    }
-
-    /**
-     * Run the {@link SessionInfo#equals} method test.
-     */
-    @Test
-    public void testEqualsTransivity() {
-        SessionInfo channel1 = new SessionInfo((SessionInfo)fSessionInfo1);
-        SessionInfo channel2 = new SessionInfo((SessionInfo)fSessionInfo1);
-        SessionInfo channel3 = new SessionInfo((SessionInfo)fSessionInfo1);
-
-        assertTrue("equals", channel1.equals(channel2));
-        assertTrue("equals", channel2.equals(channel3));
-        assertTrue("equals", channel1.equals(channel3));
-    }
-
-    /**
-     * Run the {@link SessionInfo#equals} method test.
-     */
-    @Test
-    public void testEqualsNull() {
-        assertTrue("equals", !fSessionInfo1.equals(null));
-        assertTrue("equals", !fSessionInfo2.equals(null));
-    }
-
-    // ------------------------------------------------------------------------
-    // hashCode
-    // ------------------------------------------------------------------------
-
-    /**
-     * Run the {@link SessionInfo#hashCode} method test.
-     */
-    @Test
-    public void testHashCode() {
-        SessionInfo channel1 = new SessionInfo((SessionInfo)fSessionInfo1);
-        SessionInfo channel2 = new SessionInfo((SessionInfo)fSessionInfo2);
-
-        assertTrue("hashCode", fSessionInfo1.hashCode() == channel1.hashCode());
-        assertTrue("hashCode", fSessionInfo2.hashCode() == channel2.hashCode());
-
-        assertTrue("hashCode", fSessionInfo1.hashCode() != channel2.hashCode());
-        assertTrue("hashCode", fSessionInfo2.hashCode() != channel1.hashCode());
-    }
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/SnapshotInfoTest.java b/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/SnapshotInfoTest.java
deleted file mode 100644 (file)
index 180af84..0000000
+++ /dev/null
@@ -1,229 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2013, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-
-package org.eclipse.tracecompass.lttng2.control.core.tests.model.impl;
-
-import static org.junit.Assert.assertEquals;
-import static org.junit.Assert.assertNotNull;
-import static org.junit.Assert.assertTrue;
-import static org.junit.Assert.fail;
-
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISnapshotInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.SnapshotInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.TraceInfo;
-import org.junit.Before;
-import org.junit.Test;
-
-/**
- * The class <code>SnapshotInfoTest</code> contains test for the class
- * <code>{@link SnapshotInfo}</code>.
- */
-public class SnapshotInfoTest {
-
-    // ------------------------------------------------------------------------
-    // Test data
-    // ------------------------------------------------------------------------
-
-    private ISnapshotInfo fSnapshotInfo1 = null;
-    private ISnapshotInfo fSnapshotInfo2 = null;
-
-
-    // ------------------------------------------------------------------------
-    // Housekeeping
-    // ------------------------------------------------------------------------
-
-    /**
-     * Perform pre-test initialization.
-     */
-    @Before
-    public void setUp() {
-        ModelImplFactory factory = new ModelImplFactory();
-        fSnapshotInfo1 = factory.getSnapshotInfo1();
-        fSnapshotInfo2 = factory.getSnapshotInfo2();
-    }
-
-    // ------------------------------------------------------------------------
-    // Tests
-    // ------------------------------------------------------------------------
-
-    /**
-     * Constructor test.
-     */
-    @Test
-    public void testSnapshotInfo() {
-        SnapshotInfo fixture = new SnapshotInfo("event");
-        assertNotNull(fixture);
-        assertEquals("event", fixture.getName());
-    }
-
-    /**
-     * Test Copy Constructor
-     */
-    @Test
-    public void testSnapshotInfo2() {
-        try {
-            String name = null;
-            new SnapshotInfo(name);
-            fail("null name in custructor");
-        }
-        catch (IllegalArgumentException e) {
-            // Success
-        }
-    }
-
-    /**
-     * Test Copy Constructor
-     */
-    @Test
-    public void testSnapshotCopy() {
-        SnapshotInfo info = new SnapshotInfo((SnapshotInfo)fSnapshotInfo1);
-
-        assertEquals(fSnapshotInfo1.getName(), info.getName());
-    }
-
-    /**
-     * Test Copy Constructor
-     */
-    @Test
-    public void testTraceCopy2() {
-        try {
-            SnapshotInfo info = null;
-            new SnapshotInfo(info);
-            fail("null copy");
-        }
-        catch (IllegalArgumentException e) {
-            // Success
-        }
-    }
-
-    /**
-     * Run the void setEventType(String) method test.
-     */
-    @Test
-    public void testSetName() {
-        SnapshotInfo fixture = new SnapshotInfo("event");
-        fixture.setName("newName");
-        assertEquals("newName", fixture.getName());
-    }
-
-    /**
-     * Run the String toString() method test.
-     */
-    @Test
-    public void testToString_1() {
-        String result = fSnapshotInfo1.toString();
-
-        // add additional test code here
-        assertEquals("[SnapshotInfo([TraceInfo(Name=snapshot-1)],snapshotPath=/home/user/lttng-trace/mysession/,ID=1,isStreamedSnapshot=false)]", result);
-    }
-
-    // ------------------------------------------------------------------------
-    // equals
-    // ------------------------------------------------------------------------
-
-    /**
-     * Run the equals() method test.
-     */
-    @Test
-    public void testEqualsReflexivity() {
-        assertTrue("equals", fSnapshotInfo1.equals(fSnapshotInfo1));
-        assertTrue("equals", fSnapshotInfo2.equals(fSnapshotInfo2));
-
-        assertTrue("equals", !fSnapshotInfo1.equals(fSnapshotInfo2));
-        assertTrue("equals", !fSnapshotInfo2.equals(fSnapshotInfo1));
-    }
-
-    /**
-     * Run the equals() method test.
-     */
-    @Test
-    public void testEqualsSymmetry() {
-        SnapshotInfo info1 = new SnapshotInfo((SnapshotInfo)fSnapshotInfo1);
-        SnapshotInfo info2 = new SnapshotInfo((SnapshotInfo)fSnapshotInfo2);
-
-        assertTrue("equals", info1.equals(fSnapshotInfo1));
-        assertTrue("equals", fSnapshotInfo1.equals(info1));
-
-        assertTrue("equals", info2.equals(fSnapshotInfo2));
-        assertTrue("equals", fSnapshotInfo2.equals(info2));
-    }
-    /**
-     * Run the equals() method test.
-     */
-    @Test
-    public void testEqualsTransivity() {
-        SnapshotInfo info1 = new SnapshotInfo((SnapshotInfo)fSnapshotInfo1);
-        SnapshotInfo info2 = new SnapshotInfo((SnapshotInfo)fSnapshotInfo1);
-        SnapshotInfo info3 = new SnapshotInfo((SnapshotInfo)fSnapshotInfo1);
-
-        assertTrue("equals", info1.equals(info2));
-        assertTrue("equals", info2.equals(info3));
-        assertTrue("equals", info1.equals(info3));
-    }
-    /**
-     * Run the equals() method test.
-     */
-    @Test
-    public void testEqualsNull() {
-        assertTrue("equals", !fSnapshotInfo1.equals(null));
-        assertTrue("equals", !fSnapshotInfo2.equals(null));
-
-        SnapshotInfo info = new SnapshotInfo("snapshot-1");
-        assertTrue("equals", !fSnapshotInfo1.equals(info));
-
-        info.setSnapshotPath(null);
-        assertTrue("equals", !fSnapshotInfo1.equals(info));
-
-        info.setId(fSnapshotInfo1.getId());
-        assertTrue("equals", !info.equals(fSnapshotInfo1));
-
-        info.setSnapshotPath("/home/user/lttng-trace/mysession/");
-        assertTrue("equals", fSnapshotInfo1.equals(info));
-        info.setId(2);
-        assertTrue("equals", !fSnapshotInfo1.equals(info));
-
-        info.setId(fSnapshotInfo1.getId());
-        info.setStreamedSnapshot(true);
-        assertTrue("equals", !fSnapshotInfo1.equals(info));
-
-        assertTrue("equals", !fSnapshotInfo1.equals(new TraceInfo(fSnapshotInfo1.getName())));
-    }
-
-    // ------------------------------------------------------------------------
-    // hashCode
-    // ------------------------------------------------------------------------
-
-    /**
-     * Run the hashCode() method test.
-     */
-    @Test
-    public void testHashCode() {
-        SnapshotInfo info1 = new SnapshotInfo((SnapshotInfo)fSnapshotInfo1);
-        SnapshotInfo info2 = new SnapshotInfo((SnapshotInfo)fSnapshotInfo2);
-
-        assertTrue("hashCode", fSnapshotInfo1.hashCode() == info1.hashCode());
-        assertTrue("hashCode", fSnapshotInfo2.hashCode() == info2.hashCode());
-
-        assertTrue("hashCode", fSnapshotInfo1.hashCode() != info2.hashCode());
-        assertTrue("hashCode", fSnapshotInfo2.hashCode() != info1.hashCode());
-
-        // null values
-        SnapshotInfo info3 = new SnapshotInfo("snapshot-1");
-        assertTrue("hashCode", fSnapshotInfo1.hashCode() != info3.hashCode());
-
-        info3.setSnapshotPath(null);
-        assertTrue("hashCode", fSnapshotInfo1.hashCode() != info3.hashCode());
-
-        info3.setSnapshotPath("/home/user/lttng-trace/mysession/");
-        assertTrue("hashCode", fSnapshotInfo1.hashCode() != info3.hashCode());
-    }
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/TraceInfoTest.java b/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/TraceInfoTest.java
deleted file mode 100644 (file)
index bdea62f..0000000
+++ /dev/null
@@ -1,199 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Alexandre Montplaisir - Port to JUnit4
- **********************************************************************/
-
-package org.eclipse.tracecompass.lttng2.control.core.tests.model.impl;
-
-import static org.junit.Assert.assertEquals;
-import static org.junit.Assert.assertNotNull;
-import static org.junit.Assert.assertTrue;
-import static org.junit.Assert.fail;
-
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.ITraceInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.TraceInfo;
-import org.junit.Before;
-import org.junit.Test;
-
-/**
- * The class <code>TraceInfoTest</code> contains test for the class
- * <code>{@link TraceInfo}</code>.
- */
-public class TraceInfoTest {
-
-    // ------------------------------------------------------------------------
-    // Test data
-    // ------------------------------------------------------------------------
-
-    private ITraceInfo fTraceInfo1 = null;
-    private ITraceInfo fTraceInfo2 = null;
-
-
-    // ------------------------------------------------------------------------
-    // Housekeeping
-    // ------------------------------------------------------------------------
-
-    /**
-     * Perform pre-test initialization.
-     */
-    @Before
-    public void setUp() {
-        fTraceInfo1 = new TraceInfo("event1");
-        fTraceInfo2 = new TraceInfo("event2");
-    }
-
-    // ------------------------------------------------------------------------
-    // Tests
-    // ------------------------------------------------------------------------
-
-    /**
-     * Run the BaseEventInfo() constructor test.
-     */
-    @Test
-    public void testTraceInfo() {
-        TraceInfo fixture = new TraceInfo("event");
-        assertNotNull(fixture);
-
-        assertEquals("event", fixture.getName());
-    }
-
-    /**
-     * Test Copy Constructor
-     */
-    @Test
-    public void testTraceInfo2() {
-        try {
-            String name = null;
-            new TraceInfo(name);
-            fail("null name in custructor");
-        }
-        catch (IllegalArgumentException e) {
-            // Success
-        }
-    }
-
-    /**
-     * Test Copy Constructor
-     */
-    @Test
-    public void testTraceInfoCopy() {
-        TraceInfo info = new TraceInfo((TraceInfo)fTraceInfo1);
-
-        assertEquals(fTraceInfo1.getName(), info.getName());
-    }
-
-    /**
-     * Test Copy Constructor
-     */
-    @Test
-    public void testTraceCopy2() {
-        try {
-            TraceInfo info = null;
-            new TraceInfo(info);
-            fail("null copy");
-        }
-        catch (IllegalArgumentException e) {
-            // Success
-        }
-    }
-
-    /**
-     * Run the void setEventType(String) method test.
-     */
-    @Test
-    public void testSetName() {
-        TraceInfo fixture = new TraceInfo("event");
-        fixture.setName("newName");
-        assertEquals("newName", fixture.getName());
-    }
-
-    /**
-     * Run the String toString() method test.
-     */
-    @Test
-    public void testToString_1() {
-        String result = fTraceInfo1.toString();
-
-        // add additional test code here
-        assertEquals("[TraceInfo(Name=event1)]", result);
-    }
-
-    // ------------------------------------------------------------------------
-    // equals
-    // ------------------------------------------------------------------------
-
-    /**
-     * Run the equals() method test.
-     */
-    @Test
-    public void testEqualsReflexivity() {
-        assertTrue("equals", fTraceInfo1.equals(fTraceInfo1));
-        assertTrue("equals", fTraceInfo2.equals(fTraceInfo2));
-
-        assertTrue("equals", !fTraceInfo1.equals(fTraceInfo2));
-        assertTrue("equals", !fTraceInfo2.equals(fTraceInfo1));
-    }
-
-    /**
-     * Run the equals() method test.
-     */
-    @Test
-    public void testEqualsSymmetry() {
-        TraceInfo info1 = new TraceInfo((TraceInfo)fTraceInfo1);
-        TraceInfo info2 = new TraceInfo((TraceInfo)fTraceInfo2);
-
-        assertTrue("equals", info1.equals(fTraceInfo1));
-        assertTrue("equals", fTraceInfo1.equals(info1));
-
-        assertTrue("equals", info2.equals(fTraceInfo2));
-        assertTrue("equals", fTraceInfo2.equals(info2));
-    }
-    /**
-     * Run the equals() method test.
-     */
-    @Test
-    public void testEqualsTransivity() {
-        TraceInfo info1 = new TraceInfo((TraceInfo)fTraceInfo1);
-        TraceInfo info2 = new TraceInfo((TraceInfo)fTraceInfo1);
-        TraceInfo info3 = new TraceInfo((TraceInfo)fTraceInfo1);
-
-        assertTrue("equals", info1.equals(info2));
-        assertTrue("equals", info2.equals(info3));
-        assertTrue("equals", info1.equals(info3));
-    }
-    /**
-     * Run the equals() method test.
-     */
-    @Test
-    public void testEqualsNull() {
-        assertTrue("equals", !fTraceInfo1.equals(null));
-        assertTrue("equals", !fTraceInfo2.equals(null));
-    }
-
-    // ------------------------------------------------------------------------
-    // hashCode
-    // ------------------------------------------------------------------------
-
-    /**
-     * Run the hashCode() method test.
-     */
-    @Test
-    public void testHashCode() {
-        TraceInfo info1 = new TraceInfo((TraceInfo)fTraceInfo1);
-        TraceInfo info2 = new TraceInfo((TraceInfo)fTraceInfo2);
-
-        assertTrue("hashCode", fTraceInfo1.hashCode() == info1.hashCode());
-        assertTrue("hashCode", fTraceInfo2.hashCode() == info2.hashCode());
-
-        assertTrue("hashCode", fTraceInfo1.hashCode() != info2.hashCode());
-        assertTrue("hashCode", fTraceInfo2.hashCode() != info1.hashCode());
-    }
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/UstProviderInfoTest.java b/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/model/impl/UstProviderInfoTest.java
deleted file mode 100644 (file)
index 0099c8a..0000000
+++ /dev/null
@@ -1,254 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Alexandre Montplaisir - Port to JUnit4
- **********************************************************************/
-
-package org.eclipse.tracecompass.lttng2.control.core.tests.model.impl;
-
-import static org.junit.Assert.*;
-
-import java.util.LinkedList;
-import java.util.List;
-
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IBaseEventInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IUstProviderInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.BaseEventInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.UstProviderInfo;
-import org.junit.Before;
-import org.junit.Test;
-
-/**
- * The class <code>ChannelInfoTest</code> contains tests for the class
- * <code>{@link UstProviderInfo}</code>.
- */
-public class UstProviderInfoTest {
-
-    // ------------------------------------------------------------------------
-    // Test data
-    // ------------------------------------------------------------------------
-
-    private IUstProviderInfo fUstProviderInfo1 = null;
-    private IUstProviderInfo fUstProviderInfo2 = null;
-
-    private IBaseEventInfo fEventInfo1 = null;
-    private IBaseEventInfo fEventInfo2 = null;
-
-    // ------------------------------------------------------------------------
-    // Housekeeping
-    // ------------------------------------------------------------------------
-
-    /**
-     * Perform pre-test initialization.
-     */
-    @Before
-    public void setUp() {
-        ModelImplFactory factory = new ModelImplFactory();
-        fUstProviderInfo1 = factory.getUstProviderInfo1();
-        fUstProviderInfo2 = factory.getUstProviderInfo2();
-        fEventInfo1 = factory.getBaseEventInfo1();
-        fEventInfo2 = factory.getBaseEventInfo2();
-    }
-
-    // ------------------------------------------------------------------------
-    // Tests
-    // ------------------------------------------------------------------------
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-
-    /**
-     * Run the UstProviderInfo() constructor test.
-     */
-    @Test
-    public void testUstProviderInfo() {
-        IUstProviderInfo result = new UstProviderInfo("test");
-        assertNotNull(result);
-
-        assertEquals("test", result.getName());
-        assertEquals(0, result.getPid());
-        assertEquals(0, result.getEvents().length);
-    }
-
-    /**
-     * Test the copy constructor.
-     */
-    @Test
-    public void testUstProviderInfoCopy() {
-        IUstProviderInfo providerInf = new UstProviderInfo((UstProviderInfo)fUstProviderInfo1);
-
-        assertEquals(fUstProviderInfo1.getName(), providerInf.getName());
-        assertEquals(fUstProviderInfo1.getPid(), providerInf.getPid());
-        assertEquals(fUstProviderInfo1.getEvents().length, providerInf.getEvents().length);
-
-        IBaseEventInfo[] orignalEvents = fUstProviderInfo1.getEvents();
-        IBaseEventInfo[] resultEvents = providerInf.getEvents();
-        for (int i = 0; i < orignalEvents.length; i++) {
-            assertEquals(orignalEvents[i], resultEvents[i]);
-        }
-    }
-
-    /**
-     * Test the copy constructor.
-     */
-    @Test
-    public void testUstProviderCopy2() {
-        try {
-            UstProviderInfo providerInfo = null;
-            new UstProviderInfo(providerInfo);
-            fail("null copy");
-        }
-        catch (IllegalArgumentException e) {
-            // Success
-        }
-    }
-
-    /**
-     * Run the IEventInfo[] getEvents() method test.
-     */
-    @Test
-    public void testGetAndSetters() {
-        IUstProviderInfo fixture = new UstProviderInfo("test");
-        fixture.setPid(2468);
-
-        // add an event
-        IBaseEventInfo event = new BaseEventInfo("event");
-        fixture.addEvent(event);
-
-        // Verify the stored events
-        IBaseEventInfo[] result = fixture.getEvents();
-
-        assertNotNull(result);
-        assertEquals(1, result.length);
-        assertNotNull(result[0]);
-        assertTrue(event.equals(result[0]));
-
-        assertEquals(2468, fixture.getPid());
-    }
-
-    /**
-     * Run the void setEvents(List<IBaseEventInfo>) method test.
-     */
-    @Test
-    public void testSetEvents_1() {
-        UstProviderInfo fixture = new UstProviderInfo("test");
-        fixture.setPid(2468);
-        List<IBaseEventInfo> events = new LinkedList<>();
-        events.add(fEventInfo1);
-        events.add(fEventInfo2);
-        fixture.setEvents(events);
-
-        IBaseEventInfo[] infos = fixture.getEvents();
-
-        assertEquals(events.size(), infos.length);
-
-        for (int i = 0; i < infos.length; i++) {
-            assertEquals(events.get(i), infos[i]);
-        }
-    }
-
-    /**
-     * Run the String toString() method test.
-     */
-    @Test
-    public void testToString_1() {
-        UstProviderInfo fixture = new UstProviderInfo("test");
-        fixture.setPid(2468);
-        String result = fixture.toString();
-
-        assertEquals("[EventInfo([TraceInfo(Name=test)],PID=2468,Events=None)]", result);
-    }
-
-    /**
-     * Run the String toString() method test.
-     */
-    @Test
-    public void testToString_2() {
-        String result = fUstProviderInfo2.toString();
-        assertEquals("[EventInfo([TraceInfo(Name=myUST2)],PID=2345,Events=[BaseEventInfo([TraceInfo(Name=event1)]," +
-                "type=UNKNOWN,level=TRACE_DEBUG,Fields=[FieldInfo([TraceInfo(Name=intfield)],type=int[FieldInfo" +
-                "([TraceInfo(Name=stringfield)],type=string,Filter=intField==10)][BaseEventInfo([TraceInfo(Name=event2)]," +
-                "type=TRACEPOINT,level=TRACE_DEBUG)])]", result);
-    }
-
-    // ------------------------------------------------------------------------
-    // equals
-    // ------------------------------------------------------------------------
-
-    /**
-     * Run the equals() method test.
-     */
-    @Test
-    public void testEqualsReflexivity() {
-        assertTrue("equals", fUstProviderInfo1.equals(fUstProviderInfo1));
-        assertTrue("equals", fUstProviderInfo2.equals(fUstProviderInfo2));
-
-        assertTrue("equals", !fUstProviderInfo1.equals(fUstProviderInfo2));
-        assertTrue("equals", !fUstProviderInfo2.equals(fUstProviderInfo1));
-    }
-
-    /**
-     * Run the equals() method test.
-     */
-    @Test
-    public void testEqualsSymmetry() {
-        UstProviderInfo event1 = new UstProviderInfo((UstProviderInfo)fUstProviderInfo1);
-        UstProviderInfo event2 = new UstProviderInfo((UstProviderInfo)fUstProviderInfo2);
-
-        assertTrue("equals", event1.equals(fUstProviderInfo1));
-        assertTrue("equals", fUstProviderInfo1.equals(event1));
-
-        assertTrue("equals", event2.equals(fUstProviderInfo2));
-        assertTrue("equals", fUstProviderInfo2.equals(event2));
-    }
-
-    /**
-     * Run the equals() method test.
-     */
-    @Test
-    public void testEqualsTransivity() {
-        UstProviderInfo UstProvider1 = new UstProviderInfo((UstProviderInfo)fUstProviderInfo1);
-        UstProviderInfo UstProvider2 = new UstProviderInfo((UstProviderInfo)fUstProviderInfo1);
-        UstProviderInfo UstProvider3 = new UstProviderInfo((UstProviderInfo)fUstProviderInfo1);
-
-        assertTrue("equals", UstProvider1.equals(UstProvider2));
-        assertTrue("equals", UstProvider2.equals(UstProvider3));
-        assertTrue("equals", UstProvider1.equals(UstProvider3));
-    }
-
-    /**
-     * Run the equals() method test.
-     */
-    @Test
-    public void testEqualsNull() {
-        assertTrue("equals", !fUstProviderInfo1.equals(null));
-        assertTrue("equals", !fUstProviderInfo2.equals(null));
-    }
-
-    // ------------------------------------------------------------------------
-    // hashCode
-    // ------------------------------------------------------------------------
-
-    /**
-     * Run the hashCode() method test.
-     */
-    @Test
-    public void testHashCode() {
-        UstProviderInfo UstProvider1 = new UstProviderInfo((UstProviderInfo)fUstProviderInfo1);
-        UstProviderInfo UstProvider2 = new UstProviderInfo((UstProviderInfo)fUstProviderInfo2);
-
-        assertTrue("hashCode", fUstProviderInfo1.hashCode() == UstProvider1.hashCode());
-        assertTrue("hashCode", fUstProviderInfo2.hashCode() == UstProvider2.hashCode());
-
-        assertTrue("hashCode", fUstProviderInfo1.hashCode() != UstProvider2.hashCode());
-        assertTrue("hashCode", fUstProviderInfo2.hashCode() != UstProvider1.hashCode());
-    }
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/relayd/LttngRelayd24Test.java b/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/relayd/LttngRelayd24Test.java
deleted file mode 100644 (file)
index 8533459..0000000
+++ /dev/null
@@ -1,108 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014 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:
- *   Matthew Khouzam - Initial implementation
- **********************************************************************/
-
-package org.eclipse.tracecompass.lttng2.control.core.tests.relayd;
-
-import static org.junit.Assert.assertEquals;
-import static org.junit.Assert.assertNotNull;
-import static org.junit.Assert.assertTrue;
-
-import java.io.DataInputStream;
-import java.io.DataOutputStream;
-import java.io.IOException;
-import java.net.InetAddress;
-import java.net.Socket;
-import java.util.List;
-
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.ILttngRelaydConnector;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.LttngRelaydConnectorFactory;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.AttachSessionResponse;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.Command;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.ConnectResponse;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.CreateSessionResponse;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.CreateSessionReturnCode;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.GetNextIndex;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.IndexResponse;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.NextIndexReturnCode;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.SessionResponse;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.StreamResponse;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.ViewerCommand;
-import org.junit.Test;
-
-/**
- * Unit tests for lttng-relayd. It actually allows us to test the API.
- *
- * @author Matthew Khouzam
- */
-public class LttngRelayd24Test {
-
-    private static final int PACKETS_TO_READ = 100;
-    private static final String ADDRESS = "127.0.0.1"; // change me //$NON-NLS-1$
-    private static final int PORT = 5344;
-
-    private static void getPackets(AttachSessionResponse attachedSession, Socket connection, ILttngRelaydConnector relayD) throws IOException {
-        int numPacketsReceived = 0;
-        DataOutputStream fOutNet = new DataOutputStream(connection.getOutputStream());
-        DataInputStream fInNet = new DataInputStream(connection.getInputStream());
-        while (numPacketsReceived < PACKETS_TO_READ) {
-            for (StreamResponse stream : attachedSession.getStreamList()) {
-                if (stream.getMetadataFlag() != 1) {
-                    ConnectResponse connectPayload = new ConnectResponse(fInNet);
-                    assertNotNull(connectPayload);
-
-                    ViewerCommand connectCommand = new ViewerCommand(Command.VIEWER_GET_NEXT_INDEX, ConnectResponse.SIZE, 0);
-                    fOutNet.write(connectCommand.serialize());
-                    fOutNet.flush();
-
-                    GetNextIndex indexRequest = new GetNextIndex(stream.getId());
-                    fOutNet.write(indexRequest.serialize());
-                    fOutNet.flush();
-
-                    IndexResponse indexReply = new IndexResponse(fInNet);
-                    // Nothing else supported for now
-                    if (indexReply.getStatus() == NextIndexReturnCode.VIEWER_INDEX_OK) {
-                        if (relayD.getPacketFromStream(indexReply, stream.getId()) != null) {
-                            numPacketsReceived++;
-                        }
-                    }
-                }
-            }
-        }
-    }
-
-    /**
-     * Test a connection
-     *
-     * @throws IOException
-     *             network timeout?
-     */
-    @Test
-    public void testViewerConnection() throws IOException {
-        InetAddress addr = InetAddress.getByName(ADDRESS);
-        try (Socket connection = new Socket(addr, PORT);
-                ILttngRelaydConnector relayD = LttngRelaydConnectorFactory.getNewConnector(connection);) {
-
-            List<SessionResponse> sessions = relayD.getSessions();
-            assertTrue(sessions.size() > 0);
-            SessionResponse lttngViewerSession = sessions.get(0);
-            assertNotNull(lttngViewerSession);
-            CreateSessionResponse createSession = relayD.createSession();
-            assertEquals(createSession.getStatus(), CreateSessionReturnCode.LTTNG_VIEWER_CREATE_SESSION_OK);
-            AttachSessionResponse attachedSession = relayD.attachToSession(lttngViewerSession);
-
-            String metaData = relayD.getMetadata(attachedSession);
-            assertNotNull(metaData);
-
-            getPackets(attachedSession, connection, relayD);
-        }
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/session/AllTests.java b/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/session/AllTests.java
deleted file mode 100644 (file)
index c489583..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014 École Polytechnique de Montréal
- *
- * 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:
- *   Guilliano Molaire - Initial API and implementation
- *********************************************************************/
-package org.eclipse.tracecompass.lttng2.control.core.tests.session;
-
-import org.junit.runner.RunWith;
-import org.junit.runners.Suite;
-
-/**
- * Run all the tests in the lttng2.core.session plugin.
- */
-@RunWith(Suite.class)
-@Suite.SuiteClasses({
-    SessionConfigGeneratorTest.class
-})
-public class AllTests {
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/session/SessionConfigGeneratorTest.java b/org.eclipse.tracecompass.lttng2.control.core.tests/src/org/eclipse/tracecompass/lttng2/control/core/tests/session/SessionConfigGeneratorTest.java
deleted file mode 100644 (file)
index a232b81..0000000
+++ /dev/null
@@ -1,156 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014 École Polytechnique de Montréal
- *
- * 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:
- *   Guilliano Molaire - Initial API and implementation
- *********************************************************************/
-
-package org.eclipse.tracecompass.lttng2.control.core.tests.session;
-
-import static org.junit.Assert.assertFalse;
-import static org.junit.Assert.assertTrue;
-import static org.junit.Assert.fail;
-
-import java.io.File;
-import java.util.HashSet;
-import java.util.Set;
-
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.tracecompass.internal.lttng2.control.core.Activator;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IDomainInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISessionInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.BufferType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.SessionInfo;
-import org.eclipse.tracecompass.lttng2.control.core.session.SessionConfigGenerator;
-import org.eclipse.tracecompass.lttng2.control.core.session.SessionConfigStrings;
-import org.eclipse.tracecompass.lttng2.control.core.tests.model.impl.ModelImplFactory;
-import org.junit.After;
-import org.junit.Before;
-import org.junit.Test;
-
-/**
- * This class contains tests for the class {@link SessionConfigGenerator}.
- */
-public class SessionConfigGeneratorTest {
-
-    // ------------------------------------------------------------------------
-    // Test data
-    // ------------------------------------------------------------------------
-
-    /** Session files for validation */
-    private static final File VALID_SESSION_FILE = new File("../org.eclipse.tracecompass.lttng2.control.core.tests/test_session_config_files/test_valid.lttng");
-    private static final File INVALID_SESSION_FILE = new File("../org.eclipse.tracecompass.lttng2.control.core.tests/test_session_config_files/test_invalid.lttng");
-
-    private static final String SESSION_FILENAME = "test_session." + SessionConfigStrings.SESSION_CONFIG_FILE_EXTENSION;
-    private static final IPath SESSION_FILE_PATH = Activator.getDefault().getStateLocation().addTrailingSeparator().append(SESSION_FILENAME);
-    private static final String TRACE_SESSION_PATH = "/home/user/folder";
-
-    private static final String SESSION_NAME_1 = "session1";
-    private static final String SESSION_NAME_2 = "session2";
-    private static final String SESSION_NAME_3 = "session3";
-
-    /** Session informations for generation tests */
-    private ISessionInfo fValidSessionInfo = null;
-    private ISessionInfo fValidSessionSnapshotInfo = null;
-    private ISessionInfo fInvalidSessionInfo = null;
-
-    // ------------------------------------------------------------------------
-    // Housekeeping
-    // ------------------------------------------------------------------------
-    /**
-     * Perform pre-test initialization.
-     */
-    @Before
-    public void setUp() {
-        /* A valid domain with shared buffer type */
-        ModelImplFactory factory = new ModelImplFactory();
-        IDomainInfo domain = factory.getDomainInfo1();
-        domain.setBufferType(BufferType.BUFFER_SHARED);
-
-        /* The valid sessions */
-        fValidSessionInfo = new SessionInfo(SESSION_NAME_1);
-        fValidSessionInfo.setSessionPath(TRACE_SESSION_PATH);
-        fValidSessionInfo.setSessionState(TraceSessionState.ACTIVE);
-        fValidSessionInfo.addDomain(domain);
-
-        fValidSessionSnapshotInfo = new SessionInfo(SESSION_NAME_2);
-        fValidSessionSnapshotInfo.setSessionPath(TRACE_SESSION_PATH);
-        fValidSessionSnapshotInfo.setSessionState(TraceSessionState.ACTIVE);
-        fValidSessionSnapshotInfo.addDomain(domain);
-        fValidSessionSnapshotInfo.setSnapshotInfo(factory.getSnapshotInfo1());
-
-        /* The invalid session contains an event with an invalid type */
-        fInvalidSessionInfo = factory.getSessionInfo2();
-        fInvalidSessionInfo.setName(SESSION_NAME_3);
-    }
-
-    /**
-     * Delete the session file created
-     */
-    @After
-    public void tearUp() {
-        /* Tear up the file created if it exists */
-        File sessionConfigurationFile = SESSION_FILE_PATH.toFile();
-        if (sessionConfigurationFile.exists()) {
-            sessionConfigurationFile.delete();
-        }
-
-    }
-
-    // ------------------------------------------------------------------------
-    // Tests
-    // ------------------------------------------------------------------------
-
-    /**
-     * Test method for {@link SessionConfigGenerator#sessionValidate(File)}
-     */
-    @Test
-    public void testSessionValidate() {
-        File testSessionFile = VALID_SESSION_FILE;
-        if ((testSessionFile == null) || !testSessionFile.exists()) {
-            fail("Session test file does not exist");
-        }
-        IStatus status = SessionConfigGenerator.sessionValidate(testSessionFile);
-        if (!status.isOK()) {
-            fail(status.getMessage());
-        }
-
-        testSessionFile = INVALID_SESSION_FILE;
-        if ((testSessionFile == null) || !testSessionFile.exists()) {
-            fail("Session test file does not exist");
-        }
-        assertFalse(SessionConfigGenerator.sessionValidate(testSessionFile).isOK());
-    }
-
-    /**
-     * Test method for
-     * {@link SessionConfigGenerator#generateSessionConfig(Set, IPath)}
-     */
-    @Test
-    public void testGenerateSessionConfig() {
-        /* Should fail since it's empty */
-        final Set<ISessionInfo> sessions = new HashSet<>();
-        assertFalse(SessionConfigGenerator.generateSessionConfig(sessions, SESSION_FILE_PATH).isOK());
-
-        /* Add a valid session and validate */
-        sessions.add(fValidSessionInfo);
-        assertTrue(SessionConfigGenerator.generateSessionConfig(sessions, SESSION_FILE_PATH).isOK());
-        assertTrue(SessionConfigGenerator.sessionValidate(SESSION_FILE_PATH.toFile()).isOK());
-
-        /* Add a valid snapshot session and validate */
-        sessions.add(fValidSessionSnapshotInfo);
-        assertTrue(SessionConfigGenerator.generateSessionConfig(sessions, SESSION_FILE_PATH).isOK());
-        assertTrue(SessionConfigGenerator.sessionValidate(SESSION_FILE_PATH.toFile()).isOK());
-
-        /* Add an invalid session */
-        sessions.add(fInvalidSessionInfo);
-        assertFalse(SessionConfigGenerator.generateSessionConfig(sessions, SESSION_FILE_PATH).isOK());
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.core.tests/test_session_config_files/test_invalid.lttng b/org.eclipse.tracecompass.lttng2.control.core.tests/test_session_config_files/test_invalid.lttng
deleted file mode 100644 (file)
index d13f485..0000000
+++ /dev/null
@@ -1,55 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" standalone="no"?>\r
- <!--***************************************************************************\r
- * Copyright(C) 2014 École Polytechnique de Montréal\r
- *\r
- * All rights reserved. This program and the accompanying materials are\r
- * made available under the terms of the Eclipse Public License v1.0 which\r
- * accompanies this distribution, and is available at\r
- * http://www.eclipse.org/legal/epl-v10.html\r
- *\r
- * Contributors:\r
- *   Guilliano Molaire - Initial API and implementation\r
- ***************************************************************************\r
- This is an invalid session configuration file. The domain type\r
- is missing.-->\r
-<sessions>\r
-    <session>\r
-        <name>auto-20140323-130527</name>\r
-        <started>false</started>\r
-        <domains>\r
-            <domain>\r
-                <buffer_type>GLOBAL</buffer_type>\r
-                <channels>\r
-                    <channel>\r
-                        <name>channel0</name>\r
-                        <overwrite_mode>DISCARD</overwrite_mode>\r
-                        <subbuffer_count>4</subbuffer_count>\r
-                        <switch_timer_interval>0</switch_timer_interval>\r
-                        <tracefile_size>0</tracefile_size>\r
-                        <tracefile_count>0</tracefile_count>\r
-                        <live_timer_interval>0</live_timer_interval>\r
-                        <enabled>false</enabled>\r
-                        <subbuffer_size>262144</subbuffer_size>\r
-                        <read_timer_interval>200000</read_timer_interval>\r
-                        <output_type>SPLICE</output_type>\r
-                        <events>\r
-                            <event>\r
-                                <name>exit_syscall</name>\r
-                                <enabled>true</enabled>\r
-                                <type>TRACEPOINT</type>\r
-                            </event>\r
-                        </events>\r
-                    </channel>\r
-                </channels>\r
-            </domain>\r
-        </domains>\r
-        <output>\r
-            <consumer_output>\r
-                <enabled>true</enabled>\r
-                <destination>\r
-                    <path>/home/user/folder</path>\r
-                </destination>\r
-            </consumer_output>\r
-        </output>\r
-    </session>\r
-</sessions>\r
diff --git a/org.eclipse.tracecompass.lttng2.control.core.tests/test_session_config_files/test_valid.lttng b/org.eclipse.tracecompass.lttng2.control.core.tests/test_session_config_files/test_valid.lttng
deleted file mode 100644 (file)
index 4dea4df..0000000
+++ /dev/null
@@ -1,56 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" standalone="no"?>\r
- <!--***************************************************************************\r
- * Copyright(C) 2014 École Polytechnique de Montréal\r
- *\r
- * All rights reserved. This program and the accompanying materials are\r
- * made available under the terms of the Eclipse Public License v1.0 which\r
- * accompanies this distribution, and is available at\r
- * http://www.eclipse.org/legal/epl-v10.html\r
- *\r
- * Contributors:\r
- *   Guilliano Molaire - Initial API and implementation\r
- ***************************************************************************\r
- This is a valid session configuration file. All mandatory\r
- elements are provided.-->\r
-<sessions>\r
-    <session>\r
-        <name>auto-20140323-130527</name>\r
-        <started>false</started>\r
-        <domains>\r
-            <domain>\r
-                <type>KERNEL</type>\r
-                <buffer_type>GLOBAL</buffer_type>\r
-                <channels>\r
-                    <channel>\r
-                        <name>channel0</name>\r
-                        <overwrite_mode>DISCARD</overwrite_mode>\r
-                        <subbuffer_count>4</subbuffer_count>\r
-                        <switch_timer_interval>0</switch_timer_interval>\r
-                        <tracefile_size>0</tracefile_size>\r
-                        <tracefile_count>0</tracefile_count>\r
-                        <live_timer_interval>0</live_timer_interval>\r
-                        <enabled>false</enabled>\r
-                        <subbuffer_size>262144</subbuffer_size>\r
-                        <read_timer_interval>200000</read_timer_interval>\r
-                        <output_type>SPLICE</output_type>\r
-                        <events>\r
-                            <event>\r
-                                <name>exit_syscall</name>\r
-                                <enabled>true</enabled>\r
-                                <type>TRACEPOINT</type>\r
-                            </event>\r
-                        </events>\r
-                    </channel>\r
-                </channels>\r
-            </domain>\r
-        </domains>\r
-        <output>\r
-            <consumer_output>\r
-                <enabled>true</enabled>\r
-                <destination>\r
-                    <path>/home/user/folder</path>\r
-                </destination>\r
-            </consumer_output>\r
-        </output>\r
-    </session>\r
-</sessions>\r
diff --git a/org.eclipse.tracecompass.lttng2.control.core/.classpath b/org.eclipse.tracecompass.lttng2.control.core/.classpath
deleted file mode 100644 (file)
index 098194c..0000000
+++ /dev/null
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
-       <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7"/>
-       <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
-       <classpathentry kind="src" path="src"/>
-       <classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/org.eclipse.tracecompass.lttng2.control.core/.project b/org.eclipse.tracecompass.lttng2.control.core/.project
deleted file mode 100644 (file)
index a1054ac..0000000
+++ /dev/null
@@ -1,34 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
-       <name>org.eclipse.tracecompass.lttng2.control.core</name>
-       <comment></comment>
-       <projects>
-       </projects>
-       <buildSpec>
-               <buildCommand>
-                       <name>org.eclipse.jdt.core.javabuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-               <buildCommand>
-                       <name>org.eclipse.pde.ManifestBuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-               <buildCommand>
-                       <name>org.eclipse.pde.SchemaBuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-               <buildCommand>
-                       <name>org.eclipse.pde.api.tools.apiAnalysisBuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-       </buildSpec>
-       <natures>
-               <nature>org.eclipse.pde.PluginNature</nature>
-               <nature>org.eclipse.jdt.core.javanature</nature>
-               <nature>org.eclipse.pde.api.tools.apiAnalysisNature</nature>
-       </natures>
-</projectDescription>
diff --git a/org.eclipse.tracecompass.lttng2.control.core/.settings/org.eclipse.core.resources.prefs b/org.eclipse.tracecompass.lttng2.control.core/.settings/org.eclipse.core.resources.prefs
deleted file mode 100644 (file)
index 99f26c0..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-eclipse.preferences.version=1
-encoding/<project>=UTF-8
diff --git a/org.eclipse.tracecompass.lttng2.control.core/.settings/org.eclipse.core.runtime.prefs b/org.eclipse.tracecompass.lttng2.control.core/.settings/org.eclipse.core.runtime.prefs
deleted file mode 100644 (file)
index 5a0ad22..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-eclipse.preferences.version=1
-line.separator=\n
diff --git a/org.eclipse.tracecompass.lttng2.control.core/.settings/org.eclipse.jdt.core.prefs b/org.eclipse.tracecompass.lttng2.control.core/.settings/org.eclipse.jdt.core.prefs
deleted file mode 100644 (file)
index a2b5e6b..0000000
+++ /dev/null
@@ -1,405 +0,0 @@
-eclipse.preferences.version=1
-org.eclipse.jdt.core.codeComplete.argumentPrefixes=
-org.eclipse.jdt.core.codeComplete.argumentSuffixes=
-org.eclipse.jdt.core.codeComplete.fieldPrefixes=f
-org.eclipse.jdt.core.codeComplete.fieldSuffixes=
-org.eclipse.jdt.core.codeComplete.localPrefixes=
-org.eclipse.jdt.core.codeComplete.localSuffixes=
-org.eclipse.jdt.core.codeComplete.staticFieldPrefixes=
-org.eclipse.jdt.core.codeComplete.staticFieldSuffixes=
-org.eclipse.jdt.core.codeComplete.staticFinalFieldPrefixes=
-org.eclipse.jdt.core.codeComplete.staticFinalFieldSuffixes=
-org.eclipse.jdt.core.compiler.annotation.inheritNullAnnotations=enabled
-org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore
-org.eclipse.jdt.core.compiler.annotation.nonnull=org.eclipse.jdt.annotation.NonNull
-org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=org.eclipse.jdt.annotation.NonNullByDefault
-org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nullable
-org.eclipse.jdt.core.compiler.annotation.nullanalysis=enabled
-org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
-org.eclipse.jdt.core.compiler.codegen.methodParameters=do not generate
-org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
-org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
-org.eclipse.jdt.core.compiler.compliance=1.7
-org.eclipse.jdt.core.compiler.debug.lineNumber=generate
-org.eclipse.jdt.core.compiler.debug.localVariable=generate
-org.eclipse.jdt.core.compiler.debug.sourceFile=generate
-org.eclipse.jdt.core.compiler.doc.comment.support=enabled
-org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=error
-org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
-org.eclipse.jdt.core.compiler.problem.autoboxing=ignore
-org.eclipse.jdt.core.compiler.problem.comparingIdentical=error
-org.eclipse.jdt.core.compiler.problem.deadCode=error
-org.eclipse.jdt.core.compiler.problem.deprecation=error
-org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled
-org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=enabled
-org.eclipse.jdt.core.compiler.problem.discouragedReference=warning
-org.eclipse.jdt.core.compiler.problem.emptyStatement=error
-org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
-org.eclipse.jdt.core.compiler.problem.explicitlyClosedAutoCloseable=error
-org.eclipse.jdt.core.compiler.problem.fallthroughCase=error
-org.eclipse.jdt.core.compiler.problem.fatalOptionalError=disabled
-org.eclipse.jdt.core.compiler.problem.fieldHiding=error
-org.eclipse.jdt.core.compiler.problem.finalParameterBound=error
-org.eclipse.jdt.core.compiler.problem.finallyBlockNotCompletingNormally=error
-org.eclipse.jdt.core.compiler.problem.forbiddenReference=error
-org.eclipse.jdt.core.compiler.problem.hiddenCatchBlock=error
-org.eclipse.jdt.core.compiler.problem.includeNullInfoFromAsserts=disabled
-org.eclipse.jdt.core.compiler.problem.incompatibleNonInheritedInterfaceMethod=error
-org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch=error
-org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=error
-org.eclipse.jdt.core.compiler.problem.invalidJavadoc=warning
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTags=enabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsDeprecatedRef=enabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsNotVisibleRef=enabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsVisibility=protected
-org.eclipse.jdt.core.compiler.problem.localVariableHiding=error
-org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=error
-org.eclipse.jdt.core.compiler.problem.missingDefaultCase=error
-org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=error
-org.eclipse.jdt.core.compiler.problem.missingEnumCaseDespiteDefault=enabled
-org.eclipse.jdt.core.compiler.problem.missingHashCodeMethod=error
-org.eclipse.jdt.core.compiler.problem.missingJavadocComments=warning
-org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsOverriding=disabled
-org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsVisibility=protected
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagDescription=all_standard_tags
-org.eclipse.jdt.core.compiler.problem.missingJavadocTags=warning
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagsMethodTypeParameters=disabled
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagsOverriding=disabled
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagsVisibility=protected
-org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotation=error
-org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotationForInterfaceMethodImplementation=enabled
-org.eclipse.jdt.core.compiler.problem.missingSerialVersion=error
-org.eclipse.jdt.core.compiler.problem.missingSynchronizedOnInheritedMethod=error
-org.eclipse.jdt.core.compiler.problem.noEffectAssignment=error
-org.eclipse.jdt.core.compiler.problem.noImplicitStringConversion=error
-org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=warning
-org.eclipse.jdt.core.compiler.problem.nonnullParameterAnnotationDropped=warning
-org.eclipse.jdt.core.compiler.problem.nullAnnotationInferenceConflict=warning
-org.eclipse.jdt.core.compiler.problem.nullReference=error
-org.eclipse.jdt.core.compiler.problem.nullSpecViolation=error
-org.eclipse.jdt.core.compiler.problem.nullUncheckedConversion=warning
-org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=error
-org.eclipse.jdt.core.compiler.problem.parameterAssignment=error
-org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=error
-org.eclipse.jdt.core.compiler.problem.potentialNullReference=error
-org.eclipse.jdt.core.compiler.problem.potentiallyUnclosedCloseable=warning
-org.eclipse.jdt.core.compiler.problem.rawTypeReference=warning
-org.eclipse.jdt.core.compiler.problem.redundantNullAnnotation=warning
-org.eclipse.jdt.core.compiler.problem.redundantNullCheck=error
-org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=error
-org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=error
-org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore
-org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=error
-org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled
-org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=error
-org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=disabled
-org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled
-org.eclipse.jdt.core.compiler.problem.syntacticNullAnalysisForFields=enabled
-org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=ignore
-org.eclipse.jdt.core.compiler.problem.typeParameterHiding=error
-org.eclipse.jdt.core.compiler.problem.unavoidableGenericTypeProblems=disabled
-org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=warning
-org.eclipse.jdt.core.compiler.problem.unclosedCloseable=error
-org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=ignore
-org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=error
-org.eclipse.jdt.core.compiler.problem.unnecessaryElse=error
-org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=error
-org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=warning
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionExemptExceptionAndThrowable=disabled
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionIncludeDocCommentReference=disabled
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverriding=disabled
-org.eclipse.jdt.core.compiler.problem.unusedExceptionParameter=ignore
-org.eclipse.jdt.core.compiler.problem.unusedImport=error
-org.eclipse.jdt.core.compiler.problem.unusedLabel=error
-org.eclipse.jdt.core.compiler.problem.unusedLocal=error
-org.eclipse.jdt.core.compiler.problem.unusedObjectAllocation=ignore
-org.eclipse.jdt.core.compiler.problem.unusedParameter=error
-org.eclipse.jdt.core.compiler.problem.unusedParameterIncludeDocCommentReference=enabled
-org.eclipse.jdt.core.compiler.problem.unusedParameterWhenImplementingAbstract=disabled
-org.eclipse.jdt.core.compiler.problem.unusedParameterWhenOverridingConcrete=disabled
-org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=error
-org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=error
-org.eclipse.jdt.core.compiler.problem.unusedWarningToken=error
-org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=error
-org.eclipse.jdt.core.compiler.source=1.7
-org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_call=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression=16
-org.eclipse.jdt.core.formatter.alignment_for_assignment=0
-org.eclipse.jdt.core.formatter.alignment_for_binary_expression=16
-org.eclipse.jdt.core.formatter.alignment_for_compact_if=16
-org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=80
-org.eclipse.jdt.core.formatter.alignment_for_enum_constants=0
-org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=16
-org.eclipse.jdt.core.formatter.alignment_for_method_declaration=0
-org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16
-org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=80
-org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation=0
-org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_constructor_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_method_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_union_type_in_multicatch=16
-org.eclipse.jdt.core.formatter.blank_lines_after_imports=1
-org.eclipse.jdt.core.formatter.blank_lines_after_package=1
-org.eclipse.jdt.core.formatter.blank_lines_before_field=0
-org.eclipse.jdt.core.formatter.blank_lines_before_first_class_body_declaration=0
-org.eclipse.jdt.core.formatter.blank_lines_before_imports=1
-org.eclipse.jdt.core.formatter.blank_lines_before_member_type=1
-org.eclipse.jdt.core.formatter.blank_lines_before_method=1
-org.eclipse.jdt.core.formatter.blank_lines_before_new_chunk=1
-org.eclipse.jdt.core.formatter.blank_lines_before_package=0
-org.eclipse.jdt.core.formatter.blank_lines_between_import_groups=1
-org.eclipse.jdt.core.formatter.blank_lines_between_type_declarations=1
-org.eclipse.jdt.core.formatter.brace_position_for_annotation_type_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_array_initializer=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_block=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_block_in_case=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_constructor_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_enum_constant=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_enum_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_method_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_switch=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_type_declaration=end_of_line
-org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_block_comment=false
-org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_javadoc_comment=false
-org.eclipse.jdt.core.formatter.comment.format_block_comments=true
-org.eclipse.jdt.core.formatter.comment.format_header=false
-org.eclipse.jdt.core.formatter.comment.format_html=true
-org.eclipse.jdt.core.formatter.comment.format_javadoc_comments=true
-org.eclipse.jdt.core.formatter.comment.format_line_comments=true
-org.eclipse.jdt.core.formatter.comment.format_source_code=true
-org.eclipse.jdt.core.formatter.comment.indent_parameter_description=true
-org.eclipse.jdt.core.formatter.comment.indent_root_tags=true
-org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags=insert
-org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter=insert
-org.eclipse.jdt.core.formatter.comment.line_length=80
-org.eclipse.jdt.core.formatter.comment.new_lines_at_block_boundaries=true
-org.eclipse.jdt.core.formatter.comment.new_lines_at_javadoc_boundaries=true
-org.eclipse.jdt.core.formatter.comment.preserve_white_space_between_code_and_line_comments=false
-org.eclipse.jdt.core.formatter.compact_else_if=true
-org.eclipse.jdt.core.formatter.continuation_indentation=2
-org.eclipse.jdt.core.formatter.continuation_indentation_for_array_initializer=2
-org.eclipse.jdt.core.formatter.disabling_tag=@formatter\:off
-org.eclipse.jdt.core.formatter.enabling_tag=@formatter\:on
-org.eclipse.jdt.core.formatter.format_guardian_clause_on_one_line=false
-org.eclipse.jdt.core.formatter.format_line_comment_starting_on_first_column=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_annotation_declaration_header=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_constant_header=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_declaration_header=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_type_header=true
-org.eclipse.jdt.core.formatter.indent_breaks_compare_to_cases=true
-org.eclipse.jdt.core.formatter.indent_empty_lines=false
-org.eclipse.jdt.core.formatter.indent_statements_compare_to_block=true
-org.eclipse.jdt.core.formatter.indent_statements_compare_to_body=true
-org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_cases=true
-org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_switch=false
-org.eclipse.jdt.core.formatter.indentation.size=4
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_field=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_local_variable=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_method=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_package=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_parameter=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_type=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_label=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_opening_brace_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_at_end_of_file_if_missing=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_finally_in_try_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_while_in_do_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_annotation_declaration=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_anonymous_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_block=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter=insert
-org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_binary_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_paren_in_cast=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_assert=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_case=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_labeled_statement=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_allocation_expression=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_annotation=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_throws=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_constant_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_declarations=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_explicitconstructorcall_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_increments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_inits=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_throws=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_invocation_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_field_declarations=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_local_declarations=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_parameterized_type_reference=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_superinterfaces=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_ellipsis=insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_brace_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_cast=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_catch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_for=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_if=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_parenthesized_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_switch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_synchronized=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_try=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_while=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_try_resources=insert
-org.eclipse.jdt.core.formatter.insert_space_after_unary_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter=insert
-org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_binary_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_brace_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_cast=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_catch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_for=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_if=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_parenthesized_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_switch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_synchronized=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_try=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_while=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_assert=insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_case=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_default=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_labeled_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_throws=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_constant_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_declarations=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_explicitconstructorcall_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_increments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_inits=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_throws=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_invocation_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_field_declarations=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_local_declarations=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_superinterfaces=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_ellipsis=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_annotation_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_anonymous_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_block=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_constructor_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_constant=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_method_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_switch=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation_type_member_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_catch=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_if=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_parenthesized_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_switch=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_synchronized=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_try=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_while=insert
-org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_return=insert
-org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_throw=insert
-org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_semicolon=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_try_resources=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_unary_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_brackets_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_annotation_type_member_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.join_lines_in_comments=true
-org.eclipse.jdt.core.formatter.join_wrapped_lines=false
-org.eclipse.jdt.core.formatter.keep_else_statement_on_same_line=false
-org.eclipse.jdt.core.formatter.keep_empty_array_initializer_on_one_line=false
-org.eclipse.jdt.core.formatter.keep_imple_if_on_one_line=false
-org.eclipse.jdt.core.formatter.keep_then_statement_on_same_line=false
-org.eclipse.jdt.core.formatter.lineSplit=250
-org.eclipse.jdt.core.formatter.never_indent_block_comments_on_first_column=false
-org.eclipse.jdt.core.formatter.never_indent_line_comments_on_first_column=false
-org.eclipse.jdt.core.formatter.number_of_blank_lines_at_beginning_of_method_body=0
-org.eclipse.jdt.core.formatter.number_of_empty_lines_to_preserve=1
-org.eclipse.jdt.core.formatter.put_empty_statement_on_new_line=true
-org.eclipse.jdt.core.formatter.tabulation.char=space
-org.eclipse.jdt.core.formatter.tabulation.size=4
-org.eclipse.jdt.core.formatter.use_on_off_tags=false
-org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false
-org.eclipse.jdt.core.formatter.wrap_before_binary_operator=true
-org.eclipse.jdt.core.formatter.wrap_before_or_operator_multicatch=true
-org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true
diff --git a/org.eclipse.tracecompass.lttng2.control.core/.settings/org.eclipse.jdt.ui.prefs b/org.eclipse.tracecompass.lttng2.control.core/.settings/org.eclipse.jdt.ui.prefs
deleted file mode 100644 (file)
index 232a3fd..0000000
+++ /dev/null
@@ -1,60 +0,0 @@
-eclipse.preferences.version=1
-editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true
-formatter_profile=_tmf-style
-formatter_settings_version=12
-org.eclipse.jdt.ui.exception.name=e
-org.eclipse.jdt.ui.gettersetter.use.is=true
-org.eclipse.jdt.ui.keywordthis=false
-org.eclipse.jdt.ui.overrideannotation=true
-sp_cleanup.add_default_serial_version_id=true
-sp_cleanup.add_generated_serial_version_id=false
-sp_cleanup.add_missing_annotations=false
-sp_cleanup.add_missing_deprecated_annotations=true
-sp_cleanup.add_missing_methods=false
-sp_cleanup.add_missing_nls_tags=false
-sp_cleanup.add_missing_override_annotations=true
-sp_cleanup.add_missing_override_annotations_interface_methods=true
-sp_cleanup.add_serial_version_id=false
-sp_cleanup.always_use_blocks=true
-sp_cleanup.always_use_parentheses_in_expressions=false
-sp_cleanup.always_use_this_for_non_static_field_access=false
-sp_cleanup.always_use_this_for_non_static_method_access=false
-sp_cleanup.convert_to_enhanced_for_loop=false
-sp_cleanup.correct_indentation=false
-sp_cleanup.format_source_code=false
-sp_cleanup.format_source_code_changes_only=false
-sp_cleanup.make_local_variable_final=false
-sp_cleanup.make_parameters_final=false
-sp_cleanup.make_private_fields_final=true
-sp_cleanup.make_type_abstract_if_missing_method=false
-sp_cleanup.make_variable_declarations_final=false
-sp_cleanup.never_use_blocks=false
-sp_cleanup.never_use_parentheses_in_expressions=true
-sp_cleanup.on_save_use_additional_actions=true
-sp_cleanup.organize_imports=false
-sp_cleanup.qualify_static_field_accesses_with_declaring_class=false
-sp_cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=true
-sp_cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=true
-sp_cleanup.qualify_static_member_accesses_with_declaring_class=false
-sp_cleanup.qualify_static_method_accesses_with_declaring_class=false
-sp_cleanup.remove_private_constructors=true
-sp_cleanup.remove_trailing_whitespaces=true
-sp_cleanup.remove_trailing_whitespaces_all=true
-sp_cleanup.remove_trailing_whitespaces_ignore_empty=false
-sp_cleanup.remove_unnecessary_casts=false
-sp_cleanup.remove_unnecessary_nls_tags=false
-sp_cleanup.remove_unused_imports=false
-sp_cleanup.remove_unused_local_variables=false
-sp_cleanup.remove_unused_private_fields=true
-sp_cleanup.remove_unused_private_members=false
-sp_cleanup.remove_unused_private_methods=true
-sp_cleanup.remove_unused_private_types=true
-sp_cleanup.sort_members=false
-sp_cleanup.sort_members_all=false
-sp_cleanup.use_blocks=true
-sp_cleanup.use_blocks_only_for_return_and_throw=false
-sp_cleanup.use_parentheses_in_expressions=false
-sp_cleanup.use_this_for_non_static_field_access=false
-sp_cleanup.use_this_for_non_static_field_access_only_if_necessary=true
-sp_cleanup.use_this_for_non_static_method_access=false
-sp_cleanup.use_this_for_non_static_method_access_only_if_necessary=true
diff --git a/org.eclipse.tracecompass.lttng2.control.core/.settings/org.eclipse.pde.api.tools.prefs b/org.eclipse.tracecompass.lttng2.control.core/.settings/org.eclipse.pde.api.tools.prefs
deleted file mode 100644 (file)
index acc3abd..0000000
+++ /dev/null
@@ -1,97 +0,0 @@
-ANNOTATION_ELEMENT_TYPE_ADDED_METHOD_WITHOUT_DEFAULT_VALUE=Error
-ANNOTATION_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-ANNOTATION_ELEMENT_TYPE_REMOVED_FIELD=Error
-ANNOTATION_ELEMENT_TYPE_REMOVED_METHOD=Error
-ANNOTATION_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_API_TYPE=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_API_TYPE=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_TYPE=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_TYPE=Error
-API_USE_SCAN_FIELD_SEVERITY=Error
-API_USE_SCAN_METHOD_SEVERITY=Error
-API_USE_SCAN_TYPE_SEVERITY=Error
-CLASS_ELEMENT_TYPE_ADDED_METHOD=Error
-CLASS_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
-CLASS_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-CLASS_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
-CLASS_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-CLASS_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
-CLASS_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
-CLASS_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-CLASS_ELEMENT_TYPE_REMOVED_CONSTRUCTOR=Error
-CLASS_ELEMENT_TYPE_REMOVED_FIELD=Error
-CLASS_ELEMENT_TYPE_REMOVED_METHOD=Error
-CLASS_ELEMENT_TYPE_REMOVED_SUPERCLASS=Error
-CLASS_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-CLASS_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-CONSTRUCTOR_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-CONSTRUCTOR_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-CONSTRUCTOR_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
-CONSTRUCTOR_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-ENUM_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
-ENUM_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-ENUM_ELEMENT_TYPE_REMOVED_ENUM_CONSTANT=Error
-ENUM_ELEMENT_TYPE_REMOVED_FIELD=Error
-ENUM_ELEMENT_TYPE_REMOVED_METHOD=Error
-ENUM_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-FIELD_ELEMENT_TYPE_ADDED_VALUE=Error
-FIELD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-FIELD_ELEMENT_TYPE_CHANGED_FINAL_TO_NON_FINAL_STATIC_CONSTANT=Error
-FIELD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
-FIELD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
-FIELD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
-FIELD_ELEMENT_TYPE_CHANGED_TYPE=Error
-FIELD_ELEMENT_TYPE_CHANGED_VALUE=Error
-FIELD_ELEMENT_TYPE_REMOVED_TYPE_ARGUMENT=Error
-FIELD_ELEMENT_TYPE_REMOVED_VALUE=Error
-ILLEGAL_EXTEND=Warning
-ILLEGAL_IMPLEMENT=Warning
-ILLEGAL_INSTANTIATE=Warning
-ILLEGAL_OVERRIDE=Warning
-ILLEGAL_REFERENCE=Warning
-INTERFACE_ELEMENT_TYPE_ADDED_FIELD=Error
-INTERFACE_ELEMENT_TYPE_ADDED_METHOD=Error
-INTERFACE_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
-INTERFACE_ELEMENT_TYPE_ADDED_SUPER_INTERFACE_WITH_METHODS=Error
-INTERFACE_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-INTERFACE_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
-INTERFACE_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_FIELD=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_METHOD=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-INVALID_JAVADOC_TAG=Warning
-INVALID_REFERENCE_IN_SYSTEM_LIBRARIES=Warning
-LEAK_EXTEND=Warning
-LEAK_FIELD_DECL=Warning
-LEAK_IMPLEMENT=Warning
-LEAK_METHOD_PARAM=Warning
-LEAK_METHOD_RETURN_TYPE=Warning
-METHOD_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
-METHOD_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-METHOD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-METHOD_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
-METHOD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
-METHOD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
-METHOD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
-METHOD_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
-METHOD_ELEMENT_TYPE_REMOVED_ANNOTATION_DEFAULT_VALUE=Error
-METHOD_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-MISSING_EE_DESCRIPTIONS=Ignore
-TYPE_PARAMETER_ELEMENT_TYPE_ADDED_CLASS_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_ADDED_INTERFACE_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_CLASS_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_INTERFACE_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_CLASS_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_INTERFACE_BOUND=Error
-UNUSED_PROBLEM_FILTERS=Warning
-automatically_removed_unused_problem_filters=false
-eclipse.preferences.version=1
-incompatible_api_component_version=Error
-incompatible_api_component_version_include_major_without_breaking_change=Disabled
-incompatible_api_component_version_include_minor_without_api_change=Disabled
-invalid_since_tag_version=Error
-malformed_since_tag=Error
-missing_since_tag=Error
-report_api_breakage_when_major_version_incremented=Disabled
-report_resolution_errors_api_component=Warning
diff --git a/org.eclipse.tracecompass.lttng2.control.core/.settings/org.eclipse.pde.prefs b/org.eclipse.tracecompass.lttng2.control.core/.settings/org.eclipse.pde.prefs
deleted file mode 100644 (file)
index d92b94f..0000000
+++ /dev/null
@@ -1,32 +0,0 @@
-compilers.f.unresolved-features=1
-compilers.f.unresolved-plugins=1
-compilers.incompatible-environment=1
-compilers.p.build=1
-compilers.p.build.bin.includes=1
-compilers.p.build.encodings=2
-compilers.p.build.java.compiler=2
-compilers.p.build.java.compliance=1
-compilers.p.build.missing.output=2
-compilers.p.build.output.library=1
-compilers.p.build.source.library=1
-compilers.p.build.src.includes=1
-compilers.p.deprecated=1
-compilers.p.discouraged-class=1
-compilers.p.internal=1
-compilers.p.missing-packages=1
-compilers.p.missing-version-export-package=2
-compilers.p.missing-version-import-package=2
-compilers.p.missing-version-require-bundle=2
-compilers.p.no-required-att=0
-compilers.p.not-externalized-att=1
-compilers.p.unknown-attribute=1
-compilers.p.unknown-class=1
-compilers.p.unknown-element=1
-compilers.p.unknown-identifier=1
-compilers.p.unknown-resource=1
-compilers.p.unresolved-ex-points=0
-compilers.p.unresolved-import=0
-compilers.s.create-docs=false
-compilers.s.doc-folder=doc
-compilers.s.open-tags=1
-eclipse.preferences.version=1
diff --git a/org.eclipse.tracecompass.lttng2.control.core/META-INF/MANIFEST.MF b/org.eclipse.tracecompass.lttng2.control.core/META-INF/MANIFEST.MF
deleted file mode 100644 (file)
index 9bcb35b..0000000
+++ /dev/null
@@ -1,22 +0,0 @@
-Manifest-Version: 1.0
-Bundle-ManifestVersion: 2
-Bundle-Name: %Bundle-Name
-Bundle-Vendor: %Bundle-Vendor
-Bundle-Version: 1.0.0.qualifier
-Bundle-Localization: plugin
-Bundle-SymbolicName: org.eclipse.tracecompass.lttng2.control.core;singleton:=true
-Bundle-Activator: org.eclipse.tracecompass.internal.lttng2.control.core.Activator
-Bundle-ActivationPolicy: lazy
-Bundle-RequiredExecutionEnvironment: JavaSE-1.7
-Require-Bundle: org.eclipse.core.runtime,
- org.eclipse.tracecompass.ctf.core,
- org.eclipse.tracecompass.tmf.core,
- org.eclipse.tracecompass.tmf.ctf.core
-Export-Package: org.eclipse.tracecompass.internal.lttng2.control.core;x-friends:="org.eclipse.tracecompass.lttng2.control.core.tests",
- org.eclipse.tracecompass.internal.lttng2.control.core.model;x-friends:="org.eclipse.tracecompass.lttng2.control.ui,org.eclipse.tracecompass.lttng2.control.ui.tests,org.eclipse.tracecompass.lttng2.control.core.tests",
- org.eclipse.tracecompass.internal.lttng2.control.core.model.impl;x-friends:="org.eclipse.tracecompass.lttng2.control.ui,org.eclipse.tracecompass.lttng2.control.ui.tests,org.eclipse.tracecompass.lttng2.control.core.tests",
- org.eclipse.tracecompass.internal.lttng2.control.core.relayd;x-friends:="org.eclipse.tracecompass.lttng2.control.core.tests,org.eclipse.tracecompass.lttng2.control.ui,org.eclipse.tracecompass.lttng2.control.ui.tests",
- org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;x-friends:="org.eclipse.tracecompass.lttng2.control.core.tests,org.eclipse.tracecompass.lttng2.control.ui,org.eclipse.tracecompass.lttng2.control.ui.tests",
- org.eclipse.tracecompass.internal.lttng2.control.core.relayd.impl;x-friends:="org.eclipse.tracecompass.lttng2.control.core.tests,org.eclipse.tracecompass.lttng2.control.ui,org.eclipse.tracecompass.lttng2.control.ui.tests",
- org.eclipse.tracecompass.lttng2.control.core.session
-Import-Package: com.google.common.collect
diff --git a/org.eclipse.tracecompass.lttng2.control.core/about.html b/org.eclipse.tracecompass.lttng2.control.core/about.html
deleted file mode 100644 (file)
index c258ef5..0000000
+++ /dev/null
@@ -1,28 +0,0 @@
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
-    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml">
-<head>
-<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"/>
-<title>About</title>
-</head>
-<body lang="EN-US">
-<h2>About This Content</h2>
-<p>June 5, 2006</p>    
-<h3>License</h3>
-
-<p>The Eclipse Foundation makes available all content in this plug-in (&quot;Content&quot;).  Unless otherwise 
-indicated below, the Content is provided to you under the terms and conditions of the
-Eclipse Public License Version 1.0 (&quot;EPL&quot;).  A copy of the EPL is available 
-at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>.
-For purposes of the EPL, &quot;Program&quot; will mean the Content.</p>
-
-<p>If you did not receive this Content directly from the Eclipse Foundation, the Content is 
-being redistributed by another party (&quot;Redistributor&quot;) and different terms and conditions may
-apply to your use of any object code in the Content.  Check the Redistributor's license that was 
-provided with the Content.  If no such license exists, contact the Redistributor.  Unless otherwise
-indicated below, the terms and conditions of the EPL still apply to any source code in the Content
-and such source code may be obtained at <a href="http://www.eclipse.org/">http://www.eclipse.org</a>.</p>
-
-</body>
-</html>
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.core/build.properties b/org.eclipse.tracecompass.lttng2.control.core/build.properties
deleted file mode 100644 (file)
index 964b6eb..0000000
+++ /dev/null
@@ -1,21 +0,0 @@
-###############################################################################
-# Copyright (c) 2013, 2014 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:
-#     Ericsson - Initial API and implementation
-###############################################################################
-
-source.. = src/
-output.. = bin/
-bin.includes = META-INF/,\
-               .,\
-               about.html,\
-               plugin.properties
-src.includes = about.html
-additional.bundles = org.eclipse.jdt.annotation
-jars.extra.classpath = platform:/plugin/org.eclipse.jdt.annotation
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.core/plugin.properties b/org.eclipse.tracecompass.lttng2.control.core/plugin.properties
deleted file mode 100644 (file)
index eb16206..0000000
+++ /dev/null
@@ -1,15 +0,0 @@
-###############################################################################
-# Copyright (c) 2013, 2014 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:
-#     Ericsson - Initial API and implementation
-###############################################################################
-
-#Properties file for org.eclipse.tracecompass.lttng2.control.core
-Bundle-Vendor = Eclipse Trace Compass
-Bundle-Name = Trace Compass LTTng Control Core Plug-in
diff --git a/org.eclipse.tracecompass.lttng2.control.core/pom.xml b/org.eclipse.tracecompass.lttng2.control.core/pom.xml
deleted file mode 100644 (file)
index ef5460e..0000000
+++ /dev/null
@@ -1,36 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-   Copyright (C) 2011, Red Hat, Inc.
-
-   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
--->
-<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>
-    <artifactId>org.eclipse.tracecompass</artifactId>
-    <groupId>org.eclipse.tracecompass</groupId>
-    <version>1.0.0-SNAPSHOT</version>
-  </parent>
-
-  <artifactId>org.eclipse.tracecompass.lttng2.control.core</artifactId>
-  <version>1.0.0-SNAPSHOT</version>
-  <packaging>eclipse-plugin</packaging>
-
-  <name>Trace Compass LTTng Control Core Plug-in</name>
-
- <build>
-    <plugins>
-      <plugin>
-        <groupId>org.eclipse.tycho</groupId>
-        <artifactId>tycho-source-plugin</artifactId>
-      </plugin>
-    </plugins>
-  </build>
-
- <groupId>org.eclipse.tracecompass</groupId>
-</project>
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/Activator.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/Activator.java
deleted file mode 100644 (file)
index 11901a7..0000000
+++ /dev/null
@@ -1,136 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2012, 2015 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:
- *   Francois Chouinard - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.core;
-
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Plugin;
-import org.eclipse.core.runtime.Status;
-import org.osgi.framework.BundleContext;
-
-/**
- * <b><u>Activator</u></b>
- * <p>
- * The activator class controls the plug-in life cycle
- */
-public class Activator extends Plugin {
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-
-    /**
-     * The plug-in ID
-     */
-    public static final String PLUGIN_ID = "org.eclipse.tracecompass.lttng2.control.core"; //$NON-NLS-1$
-
-    /**
-     * The shared instance
-     */
-    private static Activator plugin;
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-
-    /**
-     * The constructor
-     */
-    public Activator() {
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    /**
-     * Returns the shared instance
-     *
-     * @return the shared instance
-     */
-    public static Activator getDefault() {
-        return plugin;
-    }
-
-    // ------------------------------------------------------------------------
-    // Operators
-    // ------------------------------------------------------------------------
-
-    @Override
-    public void start(BundleContext context) throws Exception {
-        super.start(context);
-        plugin = this;
-    }
-
-    @Override
-    public void stop(BundleContext context) throws Exception {
-        plugin = null;
-        super.stop(context);
-    }
-
-    /**
-     * Logs a message with severity INFO in the runtime log of the plug-in.
-     *
-     * @param message A message to log
-     */
-    public void logInfo(String message) {
-        getLog().log(new Status(IStatus.INFO, PLUGIN_ID, message));
-    }
-
-    /**
-     * Logs a message and exception with severity INFO in the runtime log of the plug-in.
-     *
-     * @param message A message to log
-     * @param exception A exception to log
-     */
-    public void logInfo(String message, Throwable exception) {
-        getLog().log(new Status(IStatus.INFO, PLUGIN_ID, message, exception));
-    }
-
-    /**
-     * Logs a message and exception with severity WARNING in the runtime log of the plug-in.
-     *
-     * @param message A message to log
-     */
-    public void logWarning(String message) {
-        getLog().log(new Status(IStatus.WARNING, PLUGIN_ID, message));
-    }
-
-    /**
-     * Logs a message and exception with severity WARNING in the runtime log of the plug-in.
-     *
-     * @param message A message to log
-     * @param exception A exception to log
-     */
-    public void logWarning(String message, Throwable exception) {
-        getLog().log(new Status(IStatus.WARNING, PLUGIN_ID, message, exception));
-    }
-
-    /**
-     * Logs a message and exception with severity ERROR in the runtime log of the plug-in.
-     *
-     * @param message A message to log
-     */
-    public void logError(String message) {
-        getLog().log(new Status(IStatus.ERROR, PLUGIN_ID, message));
-    }
-
-    /**
-     * Logs a message and exception with severity ERROR in the runtime log of the plug-in.
-     *
-     * @param message A message to log
-     * @param exception A exception to log
-     */
-    public void logError(String message, Throwable exception) {
-        getLog().log(new Status(IStatus.ERROR, PLUGIN_ID, message, exception));
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/IBaseEventInfo.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/IBaseEventInfo.java
deleted file mode 100644 (file)
index e231ce8..0000000
+++ /dev/null
@@ -1,89 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.core.model;
-
-import java.util.List;
-
-/**
- * <p>
- * Interface for retrieval of basic trace event information.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public interface IBaseEventInfo extends ITraceInfo {
-
-    /**
-     * @return the trace event type
-     */
-    TraceEventType getEventType();
-
-    /**
-     * Sets the trace event type to the given type
-     * @param type - type to set
-     */
-    void setEventType(TraceEventType type);
-
-    /**
-     * Sets the trace event type to the type specified by the given name.
-     * @param typeName - event type name
-     */
-    void setEventType(String typeName);
-
-    /**
-     * @return the trace event log level
-     */
-    TraceLogLevel getLogLevel();
-
-    /**
-     * Sets the trace event log level to the given level
-     * @param level - event log level to set
-     */
-    void setLogLevel(TraceLogLevel level);
-
-    /**
-     * Sets the trace event log level to the level specified by the given name.
-     * @param levelName - event log level name
-     */
-    void setLogLevel(String levelName);
-
-    /**
-     * Returns the field information (if exists)
-     * @return the field information or null
-     */
-    IFieldInfo[] getFields();
-
-    /**
-     * @param field The field to add
-     */
-    void addField(IFieldInfo field);
-
-    /**
-     * Sets the fields
-     * @param fields The fields
-     */
-    void setFields(List<IFieldInfo> fields);
-
-    /**
-     * Returns filter expression.
-     * @return filter expression
-     */
-    String getFilterExpression();
-
-    /**
-     * Sets the filter expression.
-     * @param filter The filter expression to set
-     */
-    void setFilterExpression(String filter);
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/IChannelInfo.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/IChannelInfo.java
deleted file mode 100644 (file)
index 7a32707..0000000
+++ /dev/null
@@ -1,157 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Simon Delisle - Updated for support of LTTng Tools 2.2
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.core.model;
-
-import java.util.List;
-
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.BufferType;
-
-/**
- * <p>
- * Interface for retrieval of trace channel information.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public interface IChannelInfo extends ITraceInfo {
-
-    // ------------------------------------------------------------------------
-    // Constants
-    // ------------------------------------------------------------------------
-    /**
-     * Default value for overwrite mode.
-     */
-    boolean DEFAULT_OVERWRITE_MODE = false;
-
-    /**
-     * @return the overwrite mode value.
-     */
-    boolean isOverwriteMode();
-    /**
-     * Sets the overwrite mode value to the given mode.
-     * @param mode - mode to set.
-     */
-    void setOverwriteMode(boolean mode);
-
-    /**
-     * @return the sub-buffer size.
-     */
-    long getSubBufferSize();
-    /**
-     * Sets the sub-buffer size to the given value.
-     * @param bufferSize - size to set to set.
-     */
-    void setSubBufferSize(long bufferSize);
-
-    /**
-     * @return the number of sub-buffers.
-     */
-    int getNumberOfSubBuffers();
-    /**
-     * Sets the number of sub-buffers to the given value.
-     * @param numberOfSubBuffers - value to set.
-     */
-    void setNumberOfSubBuffers(int numberOfSubBuffers);
-
-    /**
-     * @return the switch timer interval.
-     */
-    long getSwitchTimer();
-    /**
-     * Sets the switch timer interval to the given value.
-     * @param timer - timer value to set.
-     */
-    void setSwitchTimer(long timer);
-
-    /**
-     * @return the read timer interval.
-     */
-    long getReadTimer();
-    /**
-     * Sets the read timer interval to the given value.
-     * @param timer - timer value to set..
-     */
-    void setReadTimer(long timer);
-
-    /**
-     * @return the output type.
-     */
-    TraceChannelOutputType getOutputType();
-    /**
-     * Sets the output type to the given value.
-     * @param type - type to set.
-     */
-    void setOutputType(String type);
-    /**
-     * Sets the output type to the given value.
-     * @param type - type to set.
-     */
-    void setOutputType(TraceChannelOutputType type);
-
-    /**
-     * @return the channel state (enabled or disabled).
-     */
-    TraceEnablement getState();
-    /**
-     * Sets the channel state (enablement) to the given value.
-     * @param state - state to set.
-     */
-    void setState(TraceEnablement state);
-    /**
-     * Sets the channel state (enablement) to the value specified by the given name.
-     * @param stateName - state to set.
-     */
-    void setState(String stateName);
-
-    /**
-     * @return all event information as array.
-     */
-    IEventInfo[] getEvents();
-    /**
-     * Sets the event information specified by given list.
-     * @param events - all event information to set.
-     */
-    void setEvents(List<IEventInfo> events);
-    /**
-     * Adds a single event information.
-     * @param event - event information to add.
-     */
-    void addEvent(IEventInfo event);
-    /**
-     * Sets the maximum size of trace files
-     * @param maxSizeTraceFiles - maximum size
-     */
-    void setMaxSizeTraceFiles(long maxSizeTraceFiles);
-    /**
-     * Sets the maximum number of trace files
-     * @param maxNumberTraceFiles - maximum number
-     */
-    void setMaxNumberTraceFiles(int maxNumberTraceFiles);
-    /**
-     * @return maximum size of trace files
-     */
-    long getMaxSizeTraceFiles();
-    /**
-     * @return maximum number of trace files
-     */
-    int getMaxNumberTraceFiles();
-    /**
-     * Sets per UID buffers
-     * @param buffersUID - enable or not
-     */
-    void setBufferType(BufferType buffersUID);
-    /**
-     * @return the value of buffersUID (enable or not)
-     */
-    BufferType getBufferType();
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/IDomainInfo.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/IDomainInfo.java
deleted file mode 100644 (file)
index 70b399e..0000000
+++ /dev/null
@@ -1,69 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.core.model;
-
-import java.util.List;
-
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.BufferType;
-
-/**
- * <p>
- * Interface for retrieval of trace domain information.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public interface IDomainInfo extends ITraceInfo {
-
-    /**
-     * @return information about all channels
-     */
-    IChannelInfo[] getChannels();
-
-    /**
-     * Sets the channel information specified by given list.
-     * @param channels - all channel information to set.
-     */
-    void setChannels(List<IChannelInfo> channels);
-
-    /**
-     * Adds a single channel information.
-     * @param channel - channel information to add.
-     */
-    void addChannel(IChannelInfo channel);
-
-    /**
-     * @return true if domain is kernel, false for UST
-     */
-    boolean isKernel();
-
-    /**
-     * Sets whether domain is  Kernel domain or UST
-     * @param isKernel true for kernel, false for UST
-     */
-    void setIsKernel(boolean isKernel);
-
-    /**
-     * @return Information about the buffer type
-     */
-    BufferType getBufferType();
-
-    /**
-     * Sets the buffer type
-     *
-     * @param bufferType
-     *            The buffer type
-     */
-    void setBufferType(BufferType bufferType);
-
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/IEventInfo.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/IEventInfo.java
deleted file mode 100644 (file)
index 86b423b..0000000
+++ /dev/null
@@ -1,58 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.core.model;
-
-/**
- * <p>
- * Interface for retrieval of trace event information.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public interface IEventInfo extends IBaseEventInfo {
-
-    /**
-     * @return the event state (enabled or disabled).
-     */
-    TraceEnablement getState();
-
-    /**
-     * Sets the event state (enablement) to the given value.
-     * @param state - state to set.
-     */
-    void setState(TraceEnablement state);
-
-    /**
-     * Sets the event state (enablement) to the value specified by the given name.
-     * @param stateName - state to set.
-     */
-    void setState(String stateName);
-
-    /**
-     * Returns the log level type.
-     * @return log level type.
-     */
-    LogLevelType getLogLevelType();
-
-    /**
-     * Sets the LogLevelType.
-     * @param type - log level type
-     */
-    void setLogLevelType(LogLevelType type);
-
-    /**
-     * Sets the LogLevelType based on given short name.
-     * @param shortName - short name of type
-     */
-    void setLogLevelType(String shortName);
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/IFieldInfo.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/IFieldInfo.java
deleted file mode 100644 (file)
index 4e1db84..0000000
+++ /dev/null
@@ -1,34 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.core.model;
-
-/**
- * <p>
- * Interface for retrieval of event field information.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public interface IFieldInfo extends ITraceInfo {
-
-    /**
-     * @return the event field type
-     */
-    String getFieldType();
-
-    /**
-     * Sets field type string
-     *
-     * @param fieldType - sting of event field type
-     */
-    void setFieldType(String fieldType);
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/IProbeEventInfo.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/IProbeEventInfo.java
deleted file mode 100644 (file)
index c397e97..0000000
+++ /dev/null
@@ -1,55 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.core.model;
-
-/**
- * <p>
- * Interface for retrieval of probe event information.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public interface IProbeEventInfo extends IEventInfo {
-
-    /**
-     * @return the address of the probe. (null if not used)
-     */
-    String getAddress();
-
-    /**
-     * Sets the address of the probe.
-     * @param address - a address (null if not used)
-     */
-    void setAddress(String address);
-
-    /**
-     * @return the offset applied to the symbol (null if not used).
-     */
-    String getOffset();
-
-    /**
-     * Sets the offset applied to the symbol.
-     * @param offset - a offset ((null if not used)
-     */
-    void setOffset(String offset);
-
-    /**
-     * @return the symbol name. ((null if not used))
-     */
-    String getSymbol();
-
-    /**
-     * Sets the symbol name.
-     * @param symbol - a symbol name ((null if not used))
-     */
-    void setSymbol(String symbol);
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/ISessionInfo.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/ISessionInfo.java
deleted file mode 100644 (file)
index c5ce569..0000000
+++ /dev/null
@@ -1,222 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
- *   Marc-Andre Laperle - Support for creating a live session
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.core.model;
-
-import java.util.List;
-
-/**
- * <p>
- * Interface for retrieval of trace session information.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public interface ISessionInfo extends ITraceInfo {
-
-    /**
-     * @return the session state state (active or inactive).
-     */
-    TraceSessionState getSessionState();
-    /**
-     * Sets the session state  to the given value.
-     * @param state - state to set.
-     */
-    void setSessionState(TraceSessionState state);
-
-    /**
-     * Sets the event state to the value specified by the given name.
-     * @param stateName - state to set.
-     */
-    void setSessionState(String stateName);
-
-    /**
-     * @return path string where session is located.
-     */
-    String getSessionPath();
-
-    /**
-     * Sets the path string (where session is located) to the given value.
-     * @param path - session path to set.
-     */
-    void setSessionPath(String path);
-
-    /**
-     * @return all domain information as array.
-     */
-    IDomainInfo[] getDomains();
-
-    /**
-     * Sets all domain information specified by given list.
-     * @param domains - all domain information to set.
-     */
-    void setDomains(List<IDomainInfo> domains);
-
-    /**
-     * Adds a single domain information.
-     * @param domainInfo domain information to add.
-     */
-    void addDomain(IDomainInfo domainInfo);
-
-    /**
-     * Returns if session is streamed over network
-     * @return <code>true</code> if streamed over network else <code>false</code>
-     */
-    boolean isStreamedTrace();
-
-    /**
-     * Sets whether the trace is streamed or not
-     * @param isStreamedTrace <code>true</code> if streamed over network else <code>false</code>
-     */
-    void setStreamedTrace(boolean isStreamedTrace);
-
-    /**
-     * Returns whether the session is snapshot session or not
-     * @return <code>true</code> if it is snapshot session else <code>false</code>
-     */
-    boolean isSnapshotSession();
-
-    /**
-     * Set whether or not the session should be in snapshot mode
-     *
-     * @param isSnapshot
-     *            true for snapshot mode, false otherwise
-     */
-    void setSnapshot(boolean isSnapshot);
-
-    /**
-     * Gets the snapshot information the session or null if it is not a
-     * snapshot session.
-     * @return snapshot information
-     */
-    ISnapshotInfo getSnapshotInfo();
-
-    /**
-     * Sets the snapshot information of the session
-     * @param setSnapshotInfo - the snapshot data to set.
-     */
-    void setSnapshotInfo(ISnapshotInfo setSnapshotInfo);
-
-    /**
-     * Get whether or not the session should be in Live mode
-     *
-     * @return <code>true</code> if is a live session else <code>false</code>
-     */
-    public boolean isLive();
-
-    /**
-     * Set whether or not the session should be in Live mode
-     *
-     * @param isLive
-     *            true for Live mode, false otherwise
-     */
-    public void setLive(boolean isLive);
-
-    /**
-     * Get the live delay which is the delay in micro seconds before the data is
-     * flushed and streamed.
-     *
-     * @return the live delay or -1 if the default value should be used
-     */
-    public long getLiveDelay();
-
-    /**
-     * Set the live delay which is the delay in micro seconds before the data is
-     * flushed and streamed.
-     *
-     * @param liveDelay
-     *            the live delay
-     */
-    public void setLiveDelay(long liveDelay);
-
-    /**
-     * Get the network URL in case control and data is configured together
-     * otherwise null If it returns a non-null value, getControlUrl() and
-     * getDataUrl() have to return null.
-     *
-     * @return The network URL or null.
-     */
-    String getNetworkUrl();
-
-    /**
-     * Set the network URL
-     *
-     * @param networkUrl
-     *            the network URL
-     */
-    void setNetworkUrl(String networkUrl);
-
-    /**
-     * Get the control URL in case control and data is configured separately. If
-     * it returns a non-null value, getDataUrl() has to return a valid value too
-     * and getNetworkUrl() has to return null.
-     *
-     * @return The control URL or null.
-     */
-    String getControlUrl();
-
-    /**
-     * Set the control URL
-     *
-     * @param controlUrl
-     *            the control URL
-     */
-    void setControlUrl(String controlUrl);
-
-    /**
-     * Get the data URL in case control and data is configured separately. If it
-     * returns a non-null value, getControlUrl() has to return a valid value too
-     * and getNetworkUrl() has to return null.
-     *
-     * @return The data URL or null.
-     */
-    String getDataUrl();
-
-    /**
-     * Set the data URL
-     *
-     * @param datalUrl
-     *            the data URL
-     */
-    void setDataUrl(String datalUrl);
-
-    /**
-     * Get the live URL.
-     *
-     * @return the live URL
-     */
-    String getLiveUrl();
-
-    /**
-     * Set the live URL.
-     *
-     * @param liveUrl
-     *            the live URL
-     */
-    void setLiveUrl(String liveUrl);
-
-    /**
-     * Get the live port.
-     *
-     * @return the live port
-     */
-    Integer getLivePort();
-
-    /**
-     * Set the live port.
-     *
-     * @param livePort
-     *            the live port
-     */
-    void setLivePort(Integer livePort);
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/ISnapshotInfo.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/ISnapshotInfo.java
deleted file mode 100644 (file)
index 852ae54..0000000
+++ /dev/null
@@ -1,62 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2013, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.core.model;
-
-
-/**
- * <p>
- * Interface for retrieval of snapshot information of a session.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public interface ISnapshotInfo extends ITraceInfo {
-
-    /**
-     * @return path string where snapshot is located.
-     */
-    String getSnapshotPath();
-
-    /**
-     * Sets the path string (where snapshot is located) to the given value.
-     * @param path - session path to set.
-     */
-    void setSnapshotPath(String path);
-
-    /**
-     * @return the snapshot ID.
-     */
-    int getId();
-
-    /**
-     * Sets the snapshot ID.
-     * @param id - the ID to set.
-     */
-    void setId(int id);
-
-    /**
-     * Sets whether snapshot is streamed over the network or stored locally
-     * at the tracers host.
-     *
-     * @param isStreamed - <code>true</code> if streamed else <code>false</code>
-     */
-    void setStreamedSnapshot(boolean isStreamed);
-
-    /**
-     * Gets whether snapshot is streamed over the network or stored locally
-     * at the tracers host.
-     *
-     * @return <code>true</code> if streamed else <code>false</code>
-     */
-    boolean isStreamedSnapshot();
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/ITraceInfo.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/ITraceInfo.java
deleted file mode 100644 (file)
index 1c4bd6c..0000000
+++ /dev/null
@@ -1,35 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2013, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.core.model;
-
-/**
- * <p>
- * Interface for retrieve trace comon information.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public interface ITraceInfo {
-    /**
-     * @return the name of the information element.
-     */
-    String getName();
-
-    /**
-     * Sets the name of the information element.
-     *
-     * @param name
-     *            The name to assign
-     */
-    void setName(String name);
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/IUstProviderInfo.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/IUstProviderInfo.java
deleted file mode 100644 (file)
index cc2c282..0000000
+++ /dev/null
@@ -1,52 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.core.model;
-
-import java.util.List;
-
-/**
- * <p>
- * Interface for retrieval of UST provider information.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public interface IUstProviderInfo extends ITraceInfo {
-
-    /**
-     * @return the process ID of the UST provider.
-     */
-    int getPid();
-
-    /**
-     * Sets the process ID of the UST provider to the given value.
-     * @param pid - process ID to set
-     */
-    void setPid(int pid);
-
-    /**
-     * @return all event information as array.
-     */
-    IBaseEventInfo[] getEvents();
-
-    /**
-     * Sets the event information specified by given list.
-     * @param events - all event information to set.
-     */
-    void setEvents(List<IBaseEventInfo> events);
-
-    /**
-     * Adds a single event information.
-     * @param event - event information to add.
-     */
-    void addEvent(IBaseEventInfo event);
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/LogLevelType.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/LogLevelType.java
deleted file mode 100644 (file)
index d152e10..0000000
+++ /dev/null
@@ -1,104 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- *********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.core.model;
-
-
-/**
- * Type of log Level enumeration.
- *
- * @author Bernd Hufmann
- */
-public enum LogLevelType {
-
-    // ------------------------------------------------------------------------
-    // Enum definition
-    // ------------------------------------------------------------------------
-    /** range of log levels [0,logLevel] */
-    LOGLEVEL("<=", "RANGE"), //$NON-NLS-1$ //$NON-NLS-2$
-
-    /** all log level */
-    LOGLEVEL_ALL("", "ALL"), //$NON-NLS-1$//$NON-NLS-2$
-
-    /** single log level */
-    LOGLEVEL_ONLY("==", "SINGLE"), //$NON-NLS-1$ //$NON-NLS-2$
-
-    /** no log level */
-    LOGLEVEL_NONE("", "UNKNOWN"); //$NON-NLS-1$ //$NON-NLS-2$
-
-    // ------------------------------------------------------------------------
-    // Constuctors
-    // ------------------------------------------------------------------------
-
-    /**
-     * Private constructor
-     *
-     * @param name
-     *            the name of state
-     */
-    private LogLevelType(String shortName, String miName) {
-        fShortName = shortName;
-        fMiName = miName;
-    }
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-    /**
-     * Name of enum.
-     */
-    private final String fShortName;
-    private final String fMiName;
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-    /**
-     * @return short string
-     */
-    public String getShortName() {
-        return fShortName;
-    }
-
-    /**
-     * @return machine interface name string
-     */
-    public String getMiName() {
-        return fMiName;
-    }
-
-    // ------------------------------------------------------------------------
-    // Utility
-    // ------------------------------------------------------------------------
-    /**
-     * Return the corresponding {@link LogLevelType} to String "name"
-     *
-     * @param name
-     *            String to compare to retrieve the good LogLevelType
-     * @return the corresponding {@link LogLevelType}
-     */
-    public static LogLevelType valueOfString(String name) {
-        if (name == null) {
-            throw new IllegalArgumentException();
-        }
-        for (LogLevelType lltype : LogLevelType.values()) {
-            if (!lltype.equals(LOGLEVEL_NONE)) {
-                boolean isEqual = lltype.fShortName.equalsIgnoreCase(name) || lltype.fMiName.equalsIgnoreCase(name);
-                if (isEqual) {
-                    return lltype;
-                }
-            }
-        }
-
-        // No match
-        return LogLevelType.LOGLEVEL_NONE;
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/TargetNodeState.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/TargetNodeState.java
deleted file mode 100644 (file)
index 1dbf95f..0000000
+++ /dev/null
@@ -1,30 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.core.model;
-
-/**
- * <p>
- *  Enumeration for the node connection state.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public enum TargetNodeState {
-     /** State when disconnected */
-    DISCONNECTED,
-     /** State while disconnecting */
-    DISCONNECTING,
-     /** State when connected */
-    CONNECTED,
-     /** State while connecting */
-    CONNECTING;
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/TraceChannelOutputType.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/TraceChannelOutputType.java
deleted file mode 100644 (file)
index 5b1cc97..0000000
+++ /dev/null
@@ -1,74 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014 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:
- *   Jonathan Rajotte - Initial API and implementation
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.core.model;
-
-/**
- * Trace domain type enumeration.
- *
- * @author Jonathan Rajotte
- */
-public enum TraceChannelOutputType {
-    /** Channel output type : splice */
-    SPLICE("splice()", "SPLICE" ), //$NON-NLS-1$ //$NON-NLS-2$
-    /** Channel output type : mmap */
-    MMAP("mmap()", "MMAP"), //$NON-NLS-1$ //$NON-NLS-2$
-    /** Channel output type : unknown */
-    UNKNOWN("unknown", "unknown"); //$NON-NLS-1$ //$NON-NLS-2$
-
-    private final String fInName;
-    private final String fInMiName;
-
-    private TraceChannelOutputType(String name, String miName) {
-        fInName = name;
-        fInMiName = miName;
-    }
-
-    /**
-     * Get the type's name
-     *
-     * @return The type's name
-     */
-    public String getInName() {
-        return fInName;
-    }
-
-    /**
-     * Get the type's name
-     *
-     * @return The type's name
-     */
-    public String getInMiName() {
-        return fInMiName;
-    }
-
-    /**
-     * Return the corresponding {@link TraceChannelOutputType} of string miName
-     *
-     * @param name
-     *            name of the Trace domain type to look for
-     * @return the corresponding {@link TraceChannelOutputType}
-     */
-    public static TraceChannelOutputType valueOfString(String name) {
-        if (name == null) {
-            throw new IllegalArgumentException();
-        }
-        for (TraceChannelOutputType tdType : TraceChannelOutputType.values()) {
-            boolean isEqual = tdType.getInName().equalsIgnoreCase(name) || tdType.getInMiName().equalsIgnoreCase(name);
-            if (isEqual) {
-                return tdType;
-            }
-        }
-        // Unknown domain
-        return UNKNOWN;
-    }
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/TraceDomainType.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/TraceDomainType.java
deleted file mode 100644 (file)
index 3cd690f..0000000
+++ /dev/null
@@ -1,64 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014 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:
- *   Jonathan Rajotte - Initial API and implementation
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.core.model;
-
-/**
- * Trace domain type enumeration.
- *
- * @author Jonathan Rajotte
- */
-public enum TraceDomainType {
-    /** Domain type : ust */
-    UST("ust"), //$NON-NLS-1$
-    /** Domain type : kernel */
-    KERNEL("kernel"), //$NON-NLS-1$
-    /** Domain type : jul */
-    JUL("jul"), //$NON-NLS-1$
-    /** Unknown domain type */
-    UNKNOWN("Unknown domain type"); //$NON-NLS-1$
-
-    private final String fInName;
-
-    private TraceDomainType(String name) {
-        fInName = name;
-    }
-
-    /**
-     * Get the type's name
-     *
-     * @return The type's name
-     */
-    public String getInName() {
-        return fInName;
-    }
-
-    /**
-     * Return the corresponding {@link TraceDomainType} of string miName
-     *
-     * @param miName
-     *            name of the Trace domain type to look for
-     * @return the corresponding {@link TraceDomainType}
-     */
-    public static TraceDomainType valueOfString(String miName) {
-        if (miName == null) {
-            throw new IllegalArgumentException();
-        }
-        for (TraceDomainType tdType : TraceDomainType.values()) {
-            if (tdType.getInName().equalsIgnoreCase(miName)) {
-                return tdType;
-            }
-        }
-        // Unknown domain
-        return UNKNOWN;
-    }
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/TraceEnablement.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/TraceEnablement.java
deleted file mode 100644 (file)
index b2abe49..0000000
+++ /dev/null
@@ -1,91 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Jonathan Rajotte - Machine interface support and utility function
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.core.model;
-
-import java.security.InvalidParameterException;
-
-/**
- * Enumeration for enabled/disabled states.
- *
- * @author Bernd Hufmann
- */
-public enum TraceEnablement {
-
-    // ------------------------------------------------------------------------
-    // Enum definition
-    // ------------------------------------------------------------------------
-    /** Tracing is disabled */
-    DISABLED("disabled", "false"), //$NON-NLS-1$ //$NON-NLS-2$
-    /** Tracing is enabled */
-    ENABLED("enabled", "true"); //$NON-NLS-1$ //$NON-NLS-2$
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-    /**
-     * Name of enum
-     */
-    private final String fInName;
-    private final String fInMiName;
-
-    // ------------------------------------------------------------------------
-    // Constuctors
-    // ------------------------------------------------------------------------
-
-    /**
-     * Private constructor
-     *
-     * @param name
-     *            the name of state
-     */
-    private TraceEnablement(String name, String miName) {
-        fInName = name;
-        fInMiName = miName;
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-    /**
-     * @return state name
-     */
-    public String getInName() {
-        return fInName;
-    }
-
-    /**
-     * @return state name
-     */
-    public String getInMiName() {
-        return fInMiName;
-    }
-
-    /**
-     * @param name
-     *            name of the desired enum
-     * @return the corresponding {@link TraceEnablement} matching name
-     */
-    public static TraceEnablement valueOfString(String name) {
-        if (name == null) {
-            throw new InvalidParameterException();
-        }
-        for (TraceEnablement enablementType : TraceEnablement.values()) {
-            boolean exist = enablementType.fInName.equalsIgnoreCase(name) || enablementType.fInMiName.equalsIgnoreCase(name);
-            if (exist) {
-                return enablementType;
-            }
-        }
-        return DISABLED;
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/TraceEventType.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/TraceEventType.java
deleted file mode 100644 (file)
index c6327f3..0000000
+++ /dev/null
@@ -1,65 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.core.model;
-
-/**
- * Trace event type enumeration.
- *
- * @author Bernd Hufmann
- */
-public enum TraceEventType {
-    /** Event type: tracepoint */
-    TRACEPOINT("tracepoint"), //$NON-NLS-1$
-    /** Event type: syscall */
-    SYSCALL("syscall"), //$NON-NLS-1$
-    /** Event type: probe */
-    PROBE("probe"), //$NON-NLS-1$
-    /** Event type: function */
-    FUNCTION("function"), //$NON-NLS-1$
-    /** Event type unknown */
-    UNKNOWN("unknown"); //$NON-NLS-1$
-
-    private final String fInName;
-
-    private TraceEventType(String name) {
-        fInName = name;
-    }
-
-    /**
-     * Get the type's name
-     *
-     * @return The type's name
-     */
-    public String getInName() {
-        return fInName;
-    }
-
-    /**
-     * Return the corresponding {@link TraceEventType} of string miName
-     *
-     * @param name
-     *            name of the {@link TraceEventType} to look for
-     * @return the corresponding {@link TraceEventType}
-     */
-    public static TraceEventType valueOfString(String name) {
-        if (name == null) {
-            throw new IllegalArgumentException();
-        }
-        for (TraceEventType teType : TraceEventType.values()) {
-            if (teType.getInName().equalsIgnoreCase(name)) {
-                return teType;
-            }
-        }
-        return UNKNOWN;
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/TraceLogLevel.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/TraceLogLevel.java
deleted file mode 100644 (file)
index 8ce9d76..0000000
+++ /dev/null
@@ -1,114 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Jonathan Rajotte - Utility function
- *********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.core.model;
-
-
-/**
- * Log Level enumeration.
- *
- * @author Bernd Hufmann
- */
-@SuppressWarnings("nls")
-public enum TraceLogLevel {
-
-    // ------------------------------------------------------------------------
-    // Enum definition
-    // ------------------------------------------------------------------------
-    /** Log level 0 */
-    TRACE_EMERG("TRACE_EMERG"),
-    /** Log level 1 */
-    TRACE_ALERT("TRACE_ALERT"),
-    /** Log level 2 */
-    TRACE_CRIT("TRACE_CRIT"),
-    /** Log level 3 */
-    TRACE_ERR("TRACE_ERR"),
-    /** Log level 4 */
-    TRACE_WARNING("TRACE_WARNING"),
-    /** Log level 5 */
-    TRACE_NOTICE("TRACE_NOTICE"),
-    /** Log level 6 */
-    TRACE_INFO("TRACE_INFO"),
-    /** Log level 7 */
-    TRACE_DEBUG_SYSTEM("TRACE_DEBUG_SYSTEM"),
-    /** Log level 8 */
-    TRACE_DEBUG_PROGRAM("TRACE_DEBUG_PROGRAM"),
-    /** Log level 9 */
-    TRACE_DEBUG_PROCESS("TRACE_DEBUG_PROCESS"),
-    /** Log level 10 */
-    TRACE_DEBUG_MODULE("TRACE_DEBUG_MODULE"),
-    /** Log level 11 */
-    TRACE_DEBUG_UNIT("TRACE_DEBUG_UNIT"),
-    /** Log level 12 */
-    TRACE_DEBUG_FUNCTION("TRACE_DEBUG_FUNCTION"),
-    /** Log level 13 */
-    TRACE_DEBUG_LINE("TRACE_DEBUG_LINE"),
-    /** Log level 14 */
-    TRACE_DEBUG("TRACE_DEBUG"),
-    /** Log level 15 */
-    LEVEL_UNKNOWN("LEVEL_UNKNOWN");
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-    /**
-     * Name of enum.
-     */
-    private final String fInName;
-
-    // ------------------------------------------------------------------------
-    // Constuctors
-    // ------------------------------------------------------------------------
-
-    /**
-     * Private constructor
-     *
-     * @param name
-     *            the name of state
-     */
-    private TraceLogLevel(String name) {
-        fInName = name;
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-    /**
-     * @return state name
-     */
-    public String getInName() {
-        return fInName;
-    }
-
-    // ------------------------------------------------------------------------
-    // Utility
-    // ------------------------------------------------------------------------
-    /**
-     * Return the corresponding {@link TraceLogLevel} to String "name"
-     *
-     * @param name
-     *            String to compare to retrieve the good {@link TraceLogLevel}
-     * @return the corresponding {@link TraceLogLevel}
-     */
-    public static TraceLogLevel valueOfString(String name) {
-        if (name == null) {
-            throw new IllegalArgumentException();
-        }
-        for (TraceLogLevel tllevel : TraceLogLevel.values()) {
-            if (tllevel.getInName().equalsIgnoreCase(name)) {
-                return tllevel;
-            }
-        }
-        // No match
-        return LEVEL_UNKNOWN;
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/TraceSessionState.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/TraceSessionState.java
deleted file mode 100644 (file)
index d83de83..0000000
+++ /dev/null
@@ -1,96 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Jonathan Rajotte - machine interface support and utility function
- *********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.core.model;
-
-/**
- * Session state enumeration.
- *
- * @author Bernd Hufmann
- */
-public enum TraceSessionState {
-
-    // ------------------------------------------------------------------------
-    // Enum definition
-    // ------------------------------------------------------------------------
-    /** Trace session inactive */
-    INACTIVE("inactive", "false"), //$NON-NLS-1$ //$NON-NLS-2$
-    /** Trace session active */
-    ACTIVE("active", "true"); //$NON-NLS-1$ //$NON-NLS-2$
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-    /**
-     * Name of enum.
-     */
-    private final String fInName;
-    private final String fMiName;
-
-    // ------------------------------------------------------------------------
-    // Constuctors
-    // ------------------------------------------------------------------------
-
-    /**
-     * Private constructor
-     *
-     * @param name
-     *            the name of state
-     */
-    private TraceSessionState(String name, String miName) {
-        fInName = name;
-        fMiName = miName;
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-    /**
-     * @return state name
-     */
-    public String getInName() {
-        return fInName;
-    }
-
-    /**
-     * @return the machine interface name
-     */
-    public String getfMiName() {
-        return fMiName;
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-    /**
-     * Return the corresponding {@link TraceSessionState} to String "name"
-     *
-     * @param name
-     *            String to compare to retrieve the good
-     *            {@link TraceSessionState}
-     * @return the corresponding {@link TraceSessionState}
-     */
-    public static TraceSessionState valueOfString(String name) {
-        if (name == null) {
-            return INACTIVE;
-        }
-        for (TraceSessionState tst : TraceSessionState.values()) {
-            boolean isEqual = tst.fInName.equalsIgnoreCase(name) || tst.fMiName.equalsIgnoreCase(name);
-            if (isEqual) {
-                return tst;
-            }
-        }
-        // No match
-        return INACTIVE;
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/BaseEventInfo.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/BaseEventInfo.java
deleted file mode 100644 (file)
index e6ed96a..0000000
+++ /dev/null
@@ -1,223 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.core.model.impl;
-
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IBaseEventInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IFieldInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEventType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
-
-/**
-* <p>
-* Implementation of the basic trace event interface (IEventInfo) to store event
-* related data.
-* </p>
-*
-* @author Bernd Hufmann
-*/
-public class BaseEventInfo extends TraceInfo implements IBaseEventInfo {
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-    /**
-     * The trace event type.
-     */
-    private TraceEventType fEventType = TraceEventType.UNKNOWN;
-    /**
-     * The trace log level.
-     */
-    private TraceLogLevel fLogLevel = TraceLogLevel.TRACE_DEBUG;
-    /**
-     * The Event fields
-     */
-    private final List<IFieldInfo> fFields = new ArrayList<>();
-    /**
-     * The filter expression.
-     */
-    private String fFilterExpression;
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-    /**
-     * Constructor
-     * @param name - name of base event
-     */
-    public BaseEventInfo(String name) {
-        super(name);
-    }
-
-    /**
-     * Copy constructor
-     * @param other - the instance to copy
-     */
-    public BaseEventInfo(BaseEventInfo other) {
-        super(other);
-        fEventType = other.fEventType;
-        fLogLevel = other.fLogLevel;
-        for (Iterator<IFieldInfo> iterator = other.fFields.iterator(); iterator.hasNext();) {
-            IFieldInfo field = iterator.next();
-            if (field instanceof FieldInfo) {
-                fFields.add(new FieldInfo((FieldInfo)field));
-            } else {
-                fFields.add(field);
-            }
-        }
-        fFilterExpression = other.fFilterExpression;
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    @Override
-    public TraceEventType getEventType() {
-        return fEventType;
-    }
-
-    @Override
-    public void setEventType(TraceEventType type) {
-        fEventType = type;
-    }
-
-    @Override
-    public void setEventType(String typeName) {
-        if(TraceEventType.TRACEPOINT.getInName().equalsIgnoreCase(typeName)) {
-            fEventType = TraceEventType.TRACEPOINT;
-        } else if(TraceEventType.SYSCALL.getInName().equalsIgnoreCase(typeName)) {
-            fEventType = TraceEventType.SYSCALL;
-        } else if (TraceEventType.PROBE.getInName().equalsIgnoreCase(typeName)) {
-            fEventType = TraceEventType.PROBE;
-        } else if (TraceEventType.FUNCTION.getInName().equalsIgnoreCase(typeName)) {
-            fEventType = TraceEventType.FUNCTION;
-        } else {
-            fEventType = TraceEventType.UNKNOWN;
-        }
-    }
-
-    @Override
-    public TraceLogLevel getLogLevel() {
-        return fLogLevel;
-    }
-
-    @Override
-    public void setLogLevel(TraceLogLevel level) {
-        fLogLevel = level;
-    }
-
-    @Override
-    public void setLogLevel(String levelName) {
-        fLogLevel = TraceLogLevel.valueOfString(levelName);
-    }
-
-    @Override
-    public IFieldInfo[] getFields() {
-        return fFields.toArray(new IFieldInfo[fFields.size()]);
-    }
-
-    @Override
-    public void addField(IFieldInfo field) {
-        fFields.add(field);
-    }
-
-    @Override
-    public void setFields(List<IFieldInfo> fields) {
-        fFields.clear();
-        for (Iterator<IFieldInfo> iterator = fields.iterator(); iterator.hasNext();) {
-            IFieldInfo fieldInfo = iterator.next();
-            fFields.add(fieldInfo);
-        }
-    }
-
-    @Override
-    public String getFilterExpression() {
-        return fFilterExpression;
-    }
-
-    @Override
-    public void setFilterExpression(String filter) {
-        fFilterExpression = filter;
-    }
-
-    @Override
-    public int hashCode() {
-        final int prime = 31;
-        int result = super.hashCode();
-        result = prime * result + ((fEventType == null) ? 0 : fEventType.hashCode());
-        result = prime * result + fFields.hashCode();
-        result = prime * result + ((fFilterExpression == null) ? 0 : fFilterExpression.hashCode());
-        result = prime * result + ((fLogLevel == null) ? 0 : fLogLevel.hashCode());
-        return result;
-    }
-
-    @Override
-    public boolean equals(Object obj) {
-        if (this == obj) {
-            return true;
-        }
-        if (!super.equals(obj)) {
-            return false;
-        }
-        if (getClass() != obj.getClass()) {
-            return false;
-        }
-        BaseEventInfo other = (BaseEventInfo) obj;
-        if (fEventType != other.fEventType) {
-            return false;
-        }
-        if (!fFields.equals(other.fFields)) {
-            return false;
-        }
-        if (fFilterExpression == null) {
-            if (other.fFilterExpression != null) {
-                return false;
-            }
-        } else if (!fFilterExpression.equals(other.fFilterExpression)) {
-            return false;
-        }
-        if (fLogLevel != other.fLogLevel) {
-            return false;
-        }
-        return true;
-    }
-
-    @SuppressWarnings("nls")
-    @Override
-    public String toString() {
-        StringBuffer output = new StringBuffer();
-            output.append("[BaseEventInfo(");
-            output.append(super.toString());
-            output.append(",type=");
-            output.append(fEventType);
-            output.append(",level=");
-            output.append(fLogLevel);
-            if (!fFields.isEmpty()) {
-                output.append(",Fields=");
-                for (Iterator<IFieldInfo> iterator = fFields.iterator(); iterator.hasNext();) {
-                    IFieldInfo field = iterator.next();
-                    output.append(field.toString());
-                }
-            }
-            if (fFilterExpression != null) {
-                output.append(",Filter=");
-                output.append(fFilterExpression);
-            }
-            output.append(")]");
-            return output.toString();
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/BufferType.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/BufferType.java
deleted file mode 100644 (file)
index 2f06600..0000000
+++ /dev/null
@@ -1,116 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2013, 2014 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:
- *   Simon Delisle - Initial API and implementation
- *   Bernd Hufmann - Updated to enum definition
- *   Jonathan Rajotte - Updated enum definition for lttng machine interface
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.core.model.impl;
-
-/**
- * Constants for buffer type.
- *
- * @author Simon Delisle
- * @author Bernd Hufmann
- */
-
-public enum BufferType {
-    // ------------------------------------------------------------------------
-    // Enum definition
-    // ------------------------------------------------------------------------
-    /**
-     * Buffer type : per UID
-     */
-    BUFFER_PER_UID("per UID", "PER_UID"), //$NON-NLS-1$ //$NON-NLS-2$
-    /**
-     * Buffer type : per PID
-     */
-    BUFFER_PER_PID("per PID", "PER_PID"), //$NON-NLS-1$ //$NON-NLS-2$
-    /**
-     * Buffer type : shared
-     */
-    BUFFER_SHARED("shared"), //$NON-NLS-1$
-    /**
-     * If the LTTng version doesn't show the buffer type
-     */
-    BUFFER_TYPE_UNKNOWN("information not unavailable"); //$NON-NLS-1$
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-    /**
-     * Name of enum
-     */
-    private final String fInName;
-
-    /**
-     * Name of the machine interface enum
-     */
-    private final String fInMiName;
-
-    // ------------------------------------------------------------------------
-    // Constuctors
-    // ------------------------------------------------------------------------
-
-    /**
-     * Private constructor
-     *
-     * @param name
-     *            the name of state
-     */
-    private BufferType(String name, String miName) {
-        fInName = name;
-        fInMiName = miName;
-    }
-
-    private BufferType(String name) {
-        fInName = name;
-        fInMiName = ""; //$NON-NLS-1$
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-    /**
-     * @return state name
-     */
-    public String getInName() {
-        return fInName;
-    }
-
-    /**
-     * @return machine interface buffer name
-     */
-    public String getInMiName() {
-        return fInMiName;
-    }
-
-    // /
-    // ------------------------------------------------------------------------
-    // Utility function
-    // -------------------------------------------------------------------------
-    /**
-     * @param name
-     *            the string representation of the type
-     * @return enum BufferType of the corresponding type
-     */
-    public static BufferType valueOfString(String name) {
-        if (name == null) {
-            throw new IllegalArgumentException();
-        }
-        for (BufferType bufferType : BufferType.values()) {
-            boolean isEqual = bufferType.getInName().equalsIgnoreCase(name) || bufferType.getInMiName().equalsIgnoreCase(name);
-            if (isEqual) {
-                return bufferType;
-            }
-        }
-        return BUFFER_TYPE_UNKNOWN;
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/ChannelInfo.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/ChannelInfo.java
deleted file mode 100644 (file)
index e588100..0000000
+++ /dev/null
@@ -1,353 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2015 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Simon Delisle - Updated for support of LTTng Tools 2.2
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.core.model.impl;
-
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IChannelInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IEventInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceChannelOutputType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEnablement;
-
-/**
- * Implementation of the trace channel interface (IChannelInfo) to store channel
- * related data.
- *
- * @author Bernd Hufmann
- */
-public class ChannelInfo extends TraceInfo implements IChannelInfo {
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-    /**
-     * The overwrite mode of the channel.
-     */
-    private boolean fOverwriteMode;
-    /**
-     * The sub-buffer size of the channel.
-     */
-    private long fSubBufferSize;
-    /**
-     * The number of sub-buffers of the channel.
-     */
-    private int fNumberOfSubBuffers;
-    /**
-     * The switch timer interval of the channel.
-     */
-    private long fSwitchTimer;
-    /**
-     * The read timer interval of the channel.
-     */
-    private long fReadTimer;
-    /**
-     * The Output type of the channel.
-     */
-    private TraceChannelOutputType fOutputType = TraceChannelOutputType.UNKNOWN;
-    /**
-     * The channel enable state.
-     */
-    private TraceEnablement fState = TraceEnablement.DISABLED;
-    /**
-     * The events information of the channel.
-     */
-    private final List<IEventInfo> fEvents = new ArrayList<>();
-    /**
-     * The maximum size of trace files
-     */
-    private long fMaxSizeTraceFiles;
-    /**
-     * The maximum number of trace files
-     */
-    private int fMaxNumberTraceFiles;
-    /**
-     * The value of buffer type
-     */
-    private BufferType fBufferType = BufferType.BUFFER_TYPE_UNKNOWN;
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-    /**
-     * Constructor
-     *
-     * @param name
-     *            - name channel
-     */
-    public ChannelInfo(String name) {
-        super(name);
-    }
-
-    /**
-     * Copy constructor
-     *
-     * @param other
-     *            - the instance to copy
-     */
-    public ChannelInfo(ChannelInfo other) {
-        super(other);
-        fOverwriteMode = other.fOverwriteMode;
-        fSubBufferSize = other.fSubBufferSize;
-        fNumberOfSubBuffers = other.fNumberOfSubBuffers;
-        fSwitchTimer = other.fSwitchTimer;
-        fReadTimer = other.fReadTimer;
-        fMaxSizeTraceFiles = other.fMaxSizeTraceFiles;
-        fMaxNumberTraceFiles = other.fMaxNumberTraceFiles;
-        fBufferType = other.fBufferType;
-        fOutputType = (other.fOutputType == null ? null : other.fOutputType);
-        fState = other.fState;
-        for (Iterator<IEventInfo> iterator = other.fEvents.iterator(); iterator.hasNext();) {
-            IEventInfo event = iterator.next();
-            if (event instanceof EventInfo) {
-                fEvents.add(new EventInfo((EventInfo) event));
-            } else {
-                fEvents.add(event);
-            }
-        }
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    @Override
-    public boolean isOverwriteMode() {
-        return fOverwriteMode;
-    }
-
-    @Override
-    public void setOverwriteMode(boolean mode) {
-        fOverwriteMode = mode;
-    }
-
-    @Override
-    public long getSubBufferSize() {
-        return fSubBufferSize;
-    }
-
-    @Override
-    public void setSubBufferSize(long bufferSize) {
-        fSubBufferSize = bufferSize;
-    }
-
-    @Override
-    public int getNumberOfSubBuffers() {
-        return fNumberOfSubBuffers;
-    }
-
-    @Override
-    public void setNumberOfSubBuffers(int numberOfSubBuffers) {
-        fNumberOfSubBuffers = numberOfSubBuffers;
-    }
-
-    @Override
-    public long getSwitchTimer() {
-        return fSwitchTimer;
-    }
-
-    @Override
-    public void setSwitchTimer(long timer) {
-        fSwitchTimer = timer;
-    }
-
-    @Override
-    public long getReadTimer() {
-        return fReadTimer;
-    }
-
-    @Override
-    public void setReadTimer(long timer) {
-        fReadTimer = timer;
-    }
-
-    @Override
-    public TraceChannelOutputType getOutputType() {
-        return fOutputType;
-    }
-
-    @Override
-    public void setOutputType(String type) {
-        fOutputType = TraceChannelOutputType.valueOfString(type);
-    }
-
-    @Override
-    public void setOutputType(TraceChannelOutputType type) {
-        fOutputType = type;
-    }
-
-    @Override
-    public TraceEnablement getState() {
-        return fState;
-    }
-
-    @Override
-    public void setState(TraceEnablement state) {
-        fState = state;
-    }
-
-    @Override
-    public void setState(String stateName) {
-        fState = TraceEnablement.valueOfString(stateName);
-    }
-
-    @Override
-    public IEventInfo[] getEvents() {
-        return fEvents.toArray(new IEventInfo[fEvents.size()]);
-    }
-
-    @Override
-    public void setEvents(List<IEventInfo> events) {
-        fEvents.clear();
-        for (Iterator<IEventInfo> iterator = events.iterator(); iterator.hasNext();) {
-            IEventInfo eventInfo = iterator.next();
-            fEvents.add(eventInfo);
-        }
-    }
-
-    @Override
-    public void addEvent(IEventInfo channel) {
-        fEvents.add(channel);
-    }
-
-    @Override
-    public int hashCode() {
-        final int prime = 31;
-        int result = super.hashCode();
-        result = prime * result + fEvents.hashCode();
-        result = prime * result + fNumberOfSubBuffers;
-        result = prime * result + ((fOutputType == null) ? 0 : fOutputType.hashCode());
-        result = prime * result + (fOverwriteMode ? 1231 : 1237);
-        result = prime * result + (int) (fReadTimer ^ (fReadTimer >>> 32));
-        result = prime * result + ((fState == null) ? 0 : (fState.ordinal() + 1));
-        result = prime * result + (int) (fSubBufferSize ^ (fSubBufferSize >>> 32));
-        result = prime * result + (int) (fSwitchTimer ^ (fSwitchTimer >>> 32));
-        result = prime * result + ((fBufferType == null) ? 0 : (fBufferType.ordinal() + 1));
-        return result;
-    }
-
-    @Override
-    public boolean equals(Object obj) {
-        if (this == obj) {
-            return true;
-        }
-        if (!super.equals(obj)) {
-            return false;
-        }
-        if (getClass() != obj.getClass()) {
-            return false;
-        }
-        ChannelInfo other = (ChannelInfo) obj;
-        if (!fEvents.equals(other.fEvents)) {
-            return false;
-        }
-        if (fNumberOfSubBuffers != other.fNumberOfSubBuffers) {
-            return false;
-        }
-        if (fOutputType == null) {
-            if (other.fOutputType != null) {
-                return false;
-            }
-        } else if (!fOutputType.equals(other.fOutputType)) {
-            return false;
-        }
-        if (fOverwriteMode != other.fOverwriteMode) {
-            return false;
-        }
-        if (fReadTimer != other.fReadTimer) {
-            return false;
-        }
-        if (fState != other.fState) {
-            return false;
-        }
-        if (fSubBufferSize != other.fSubBufferSize) {
-            return false;
-        }
-        if (fSwitchTimer != other.fSwitchTimer) {
-            return false;
-        }
-        if (fBufferType != other.fBufferType) {
-            return false;
-        }
-        return true;
-    }
-
-    @SuppressWarnings("nls")
-    @Override
-    public String toString() {
-        StringBuffer output = new StringBuffer();
-        output.append("[ChannelInfo(");
-        output.append(super.toString());
-        output.append(",State=");
-        output.append(fState);
-        output.append(",OverwriteMode=");
-        output.append(fOverwriteMode);
-        output.append(",SubBuffersSize=");
-        output.append(fSubBufferSize);
-        output.append(",NumberOfSubBuffers=");
-        output.append(fNumberOfSubBuffers);
-        output.append(",SwitchTimer=");
-        output.append(fSwitchTimer);
-        output.append(",ReadTimer=");
-        output.append(fReadTimer);
-        output.append(",output=");
-        output.append(fOutputType.getInName());
-        if ((fBufferType != null) && !fBufferType.equals(BufferType.BUFFER_TYPE_UNKNOWN) && !fBufferType.equals(BufferType.BUFFER_SHARED)) {
-            output.append(",BufferType=");
-            output.append(fBufferType);
-        }
-        output.append(",Events=");
-        if (fEvents.isEmpty()) {
-            output.append("None");
-        } else {
-            for (Iterator<IEventInfo> iterator = fEvents.iterator(); iterator.hasNext();) {
-                IEventInfo event = iterator.next();
-                output.append(event.toString());
-            }
-        }
-        output.append(")]");
-        return output.toString();
-    }
-
-    @Override
-    public void setMaxSizeTraceFiles(long maxSizeTraceFiles) {
-        fMaxSizeTraceFiles = maxSizeTraceFiles;
-    }
-
-    @Override
-    public void setMaxNumberTraceFiles(int maxNumberTraceFiles) {
-        fMaxNumberTraceFiles = maxNumberTraceFiles;
-    }
-
-    @Override
-    public long getMaxSizeTraceFiles() {
-        return fMaxSizeTraceFiles;
-    }
-
-    @Override
-    public int getMaxNumberTraceFiles() {
-        return fMaxNumberTraceFiles;
-    }
-
-    @Override
-    public void setBufferType(BufferType bufferType) {
-        fBufferType = bufferType;
-    }
-
-    @Override
-    public BufferType getBufferType() {
-        return fBufferType;
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/DomainInfo.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/DomainInfo.java
deleted file mode 100644 (file)
index 5f77cd0..0000000
+++ /dev/null
@@ -1,173 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.core.model.impl;
-
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IChannelInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IDomainInfo;
-
-/**
- * <p>
- * Implementation of the trace domain interface (IDomainInfo) to store domain
- * related data.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class DomainInfo extends TraceInfo implements IDomainInfo {
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-    /**
-     * The channels information of the domain.
-     */
-    private final List<IChannelInfo> fChannels = new ArrayList<>();
-    private boolean fIsKernel = false;
-    private BufferType fBufferType = BufferType.BUFFER_TYPE_UNKNOWN;
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-    /**
-     * Constructor
-     * @param name - name of domain
-     */
-    public DomainInfo(String name) {
-        super(name);
-    }
-
-    /**
-     * Copy constructor
-     * @param other - the instance to copy
-     */
-    public DomainInfo(DomainInfo other) {
-        super(other);
-        for (int i = 0; i < other.fChannels.size(); i++) {
-            if (other.fChannels.get(i) instanceof ChannelInfo) {
-                fChannels.add(new ChannelInfo((ChannelInfo)other.fChannels.get(i)));
-            } else {
-                fChannels.add(other.fChannels.get(i));
-            }
-        }
-        fIsKernel = other.fIsKernel;
-        fBufferType = other.fBufferType;
-    }
-
-    @Override
-    public boolean isKernel() {
-        return fIsKernel;
-    }
-
-    @Override
-    public void setIsKernel(boolean isKernel) {
-        fIsKernel = isKernel;
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    @Override
-    public IChannelInfo[] getChannels() {
-        return fChannels.toArray(new IChannelInfo[fChannels.size()]);
-    }
-
-    @Override
-    public void setChannels(List<IChannelInfo> channels) {
-        fChannels.clear();
-        for (Iterator<IChannelInfo> iterator = channels.iterator(); iterator.hasNext();) {
-            IChannelInfo channelInfo = iterator.next();
-            fChannels.add(channelInfo);
-        }
-    }
-
-    @Override
-    public void addChannel(IChannelInfo channel) {
-        fChannels.add(channel);
-    }
-
-    @Override
-    public int hashCode() {
-        final int prime = 31;
-        int result = super.hashCode();
-        result = prime * result + fChannels.hashCode();
-        result = prime * result + (fIsKernel ? 1231 : 1237);
-        result = prime * result + ((fBufferType == null) ? 0 : (fBufferType.ordinal() + 1));
-        return result;
-    }
-
-    @Override
-    public boolean equals(Object obj) {
-        if (this == obj) {
-            return true;
-        }
-        if (!super.equals(obj)) {
-            return false;
-        }
-        if (getClass() != obj.getClass()) {
-            return false;
-        }
-        DomainInfo other = (DomainInfo) obj;
-        if (!fChannels.equals(other.fChannels)) {
-            return false;
-        }
-        if (fIsKernel != other.fIsKernel) {
-            return false;
-        }
-        if (fBufferType != other.fBufferType) {
-            return false;
-        }
-        return true;
-    }
-
-    @Override
-    public BufferType getBufferType() {
-        if (fIsKernel) {
-            return BufferType.BUFFER_SHARED;
-        }
-        return fBufferType;
-    }
-
-    @Override
-    public void setBufferType(BufferType bufferType) {
-        fBufferType = bufferType;
-    }
-
-    @SuppressWarnings("nls")
-    @Override
-    public String toString() {
-        StringBuffer output = new StringBuffer();
-            output.append("[DomainInfo(");
-            output.append(super.toString());
-            output.append(",Channels=");
-            if (fChannels.isEmpty()) {
-                output.append("None");
-            } else {
-                for (Iterator<IChannelInfo> iterator = fChannels.iterator(); iterator.hasNext();) {
-                    IChannelInfo channel = iterator.next();
-                    output.append(channel.toString());
-                }
-            }
-            output.append(",isKernel=");
-            output.append(String.valueOf(fIsKernel));
-            if ((fBufferType != null) && !fBufferType.equals(BufferType.BUFFER_TYPE_UNKNOWN) && !fBufferType.equals(BufferType.BUFFER_SHARED)) {
-                output.append(",BufferType=");
-                output.append(fBufferType);
-            }
-            output.append(")]");
-            return output.toString();
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/EventInfo.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/EventInfo.java
deleted file mode 100644 (file)
index c73e46c..0000000
+++ /dev/null
@@ -1,139 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.core.model.impl;
-
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IEventInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.LogLevelType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEnablement;
-
-/**
-* <p>
-* Implementation of the trace event interface (IEventInfo) to store event
-* related data.
-* </p>
-*
-* @author Bernd Hufmann
-*/
-public class EventInfo extends BaseEventInfo implements IEventInfo {
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-    /**
-     * The enable state of the event.
-     */
-    private TraceEnablement fState = TraceEnablement.DISABLED;
-    /**
-     * The log level type.
-     */
-    private LogLevelType fLogLevelType = LogLevelType.LOGLEVEL_NONE;
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-    /**
-     * Constructor
-     * @param name - name of event
-     */
-    public EventInfo(String name) {
-        super(name);
-    }
-
-    /**
-     * Copy constructor
-     * @param other - the instance to copy
-     */
-    public EventInfo(EventInfo other) {
-        super(other);
-        fState = other.fState;
-        fLogLevelType = other.fLogLevelType;
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    @Override
-    public TraceEnablement getState() {
-        return fState;
-    }
-
-    @Override
-    public void setState(TraceEnablement state) {
-        fState = state;
-    }
-
-    @Override
-    public void setState(String stateName) {
-        fState = TraceEnablement.valueOfString(stateName);
-    }
-
-    @Override
-    public LogLevelType getLogLevelType() {
-        return fLogLevelType;
-    }
-
-    @Override
-    public void setLogLevelType(LogLevelType type) {
-        fLogLevelType = type;
-    }
-
-    @Override
-    public void setLogLevelType(String shortName) {
-        fLogLevelType = LogLevelType.valueOfString(shortName);
-    }
-
-
-    @Override
-    public int hashCode() {
-        final int prime = 31;
-        int result = super.hashCode();
-        result = prime * result + ((fState == null) ? 0 : (fState.ordinal() + 1));
-        result = prime * result + ((fLogLevelType == null) ? 0 : fLogLevelType.hashCode());
-        return result;
-    }
-
-    @Override
-    public boolean equals(Object obj) {
-        if (this == obj) {
-            return true;
-        }
-        if (!super.equals(obj)) {
-            return false;
-        }
-        if (getClass() != obj.getClass()) {
-            return false;
-        }
-        EventInfo other = (EventInfo) obj;
-        if (fState != other.fState) {
-            return false;
-        }
-        if (fLogLevelType != other.fLogLevelType) {
-            return false;
-        }
-        return true;
-    }
-
-    @SuppressWarnings("nls")
-    @Override
-    public String toString() {
-        StringBuffer output = new StringBuffer();
-            output.append("[EventInfo(");
-            output.append(super.toString());
-            output.append(",State=");
-            output.append(fState);
-            output.append(",levelType=");
-            output.append(fLogLevelType);
-            output.append(")]");
-            return output.toString();
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/FieldInfo.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/FieldInfo.java
deleted file mode 100644 (file)
index 5a588c2..0000000
+++ /dev/null
@@ -1,109 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.core.model.impl;
-
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IFieldInfo;
-
-/**
-* <p>
-* Implementation of the basic trace event interface (IEventInfo) to store event
-* related data.
-* </p>
-*
-* @author Bernd Hufmann
-*/
-public class FieldInfo extends TraceInfo implements IFieldInfo {
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-    /**
-     * The trace event type.
-     */
-    private String fFieldType;
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-    /**
-     * Constructor
-     * @param name - name of base event
-     */
-    public FieldInfo(String name) {
-        super(name);
-    }
-
-    /**
-     * Copy constructor
-     * @param other - the instance to copy
-     */
-    public FieldInfo(FieldInfo other) {
-        super(other);
-        fFieldType = other.fFieldType;
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    @Override
-    public String getFieldType() {
-        return fFieldType;
-    }
-
-    @Override
-    public void setFieldType(String fieldType) {
-        fFieldType = fieldType.toLowerCase();
-    }
-
-    @Override
-    public int hashCode() {
-        final int prime = 31;
-        int result = super.hashCode();
-        result = prime * result
-                + ((fFieldType == null) ? 0 : fFieldType.hashCode());
-        return result;
-    }
-
-    @Override
-    public boolean equals(Object obj) {
-        if (this == obj) {
-            return true;
-        }
-        if (!super.equals(obj)) {
-            return false;
-        }
-        if (getClass() != obj.getClass()) {
-            return false;
-        }
-        FieldInfo other = (FieldInfo) obj;
-        if (fFieldType == null) {
-            if (other.fFieldType != null) {
-                return false;
-            }
-        } else if (!fFieldType.equals(other.fFieldType)) {
-            return false;
-        }
-        return true;
-    }
-
-    @SuppressWarnings("nls")
-    @Override
-    public String toString() {
-        StringBuffer output = new StringBuffer();
-            output.append("[FieldInfo(");
-            output.append(super.toString());
-            output.append(",type=");
-            output.append(fFieldType);
-            return output.toString();
-    }
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/ProbeEventInfo.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/ProbeEventInfo.java
deleted file mode 100644 (file)
index 42550a5..0000000
+++ /dev/null
@@ -1,187 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.core.model.impl;
-
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IEventInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IProbeEventInfo;
-
-/**
- * Implementation of the trace event interface (IProbeEventInfo) to store probe
- * event related data.
- *
- * @author Bernd Hufmann
- */
-public class ProbeEventInfo extends EventInfo implements IProbeEventInfo {
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-    /**
-     * The dynamic probe address (null if symbol is used).
-     */
-    private String fAddress;
-    /**
-     * The dynamic probe offset (if symbol is used).
-     */
-    private String fOffset;
-
-    /**
-     * The symbol name (null if address is used)
-     */
-    private String fSymbol;
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-    /**
-     * Constructor
-     *
-     * @param name
-     *            - name of event
-     */
-    public ProbeEventInfo(String name) {
-        super(name);
-    }
-
-    /**
-     * Copy constructor
-     *
-     * @param other
-     *            - the instance to copy
-     */
-    public ProbeEventInfo(ProbeEventInfo other) {
-        super(other);
-        fAddress = other.fAddress;
-        fOffset = other.fOffset;
-        fSymbol = other.fSymbol;
-    }
-
-    /**
-     * Constructor from a {@link IEventInfo}
-     *
-     * @param eventInfo
-     *            - the instance to copy
-     */
-    public ProbeEventInfo(IEventInfo eventInfo) {
-        super(eventInfo.getName());
-        setState(eventInfo.getState());
-        setLogLevelType(eventInfo.getLogLevelType());
-        setLogLevel(eventInfo.getLogLevel());
-        setFilterExpression(eventInfo.getFilterExpression());
-        setEventType(eventInfo.getEventType());
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    @Override
-    public String getAddress() {
-        return fAddress;
-    }
-
-    @Override
-    public void setAddress(String address) {
-        fAddress = address;
-    }
-
-    @Override
-    public String getOffset() {
-        return fOffset;
-    }
-
-    @Override
-    public void setOffset(String offset) {
-        fOffset = offset;
-    }
-
-    @Override
-    public String getSymbol() {
-        return fSymbol;
-    }
-
-    @Override
-    public void setSymbol(String symbol) {
-        fSymbol = symbol;
-    }
-
-    // ------------------------------------------------------------------------
-    // Operation
-    // ------------------------------------------------------------------------
-
-    @Override
-    public int hashCode() {
-        final int prime = 31;
-        int result = super.hashCode();
-        result = prime * result + ((fAddress == null) ? 0 : fAddress.hashCode());
-        result = prime * result + ((fOffset == null) ? 0 : fOffset.hashCode());
-        result = prime * result + ((fSymbol == null) ? 0 : fSymbol.hashCode());
-        return result;
-    }
-
-    @Override
-    public boolean equals(Object obj) {
-        if (this == obj) {
-            return true;
-        }
-        if (!super.equals(obj)) {
-            return false;
-        }
-        if (getClass() != obj.getClass()) {
-            return false;
-        }
-        ProbeEventInfo other = (ProbeEventInfo) obj;
-        if (fAddress == null) {
-            if (other.fAddress != null) {
-                return false;
-            }
-        } else if (!fAddress.equals(other.fAddress)) {
-            return false;
-        }
-        if (fOffset == null) {
-            if (other.fOffset != null) {
-                return false;
-            }
-        } else if (!fOffset.equals(other.fOffset)) {
-            return false;
-        }
-        if (fSymbol == null) {
-            if (other.fSymbol != null) {
-                return false;
-            }
-        } else if (!fSymbol.equals(other.fSymbol)) {
-            return false;
-        }
-        return true;
-    }
-
-    @SuppressWarnings("nls")
-    @Override
-    public String toString() {
-        StringBuffer output = new StringBuffer();
-        output.append("[ProbeEventInfo(");
-        output.append(super.toString());
-        if (fAddress != null) {
-            output.append(",fAddress=");
-            output.append(fAddress);
-        } else {
-            output.append(",fOffset=");
-            output.append(fOffset);
-            output.append(",fSymbol=");
-            output.append(fSymbol);
-        }
-        output.append(")]");
-        return output.toString();
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/SessionInfo.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/SessionInfo.java
deleted file mode 100644 (file)
index 53a78fa..0000000
+++ /dev/null
@@ -1,338 +0,0 @@
-/**********************************************************************
-
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
- *   Marc-Andre Laperle - Support for creating a live session
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.core.model.impl;
-
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IDomainInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISessionInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISnapshotInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
-
-/**
- * Implementation of the trace session interface (ISessionInfo) to store session
- * related data.
- *
- * @author Bernd Hufmann
- */
-public class SessionInfo extends TraceInfo implements ISessionInfo {
-
-    /**
-     * The default network URL when creating a live session.
-     */
-    public static final String DEFAULT_LIVE_NETWORK_URL = "net://127.0.0.1"; //$NON-NLS-1$
-
-    /**
-     * The default live port for a live session.
-     */
-    public static final int DEFAULT_LIVE_PORT = 5344;
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-    /**
-     * The trace session state.
-     */
-    private TraceSessionState fState = TraceSessionState.INACTIVE;
-    /**
-     * The trace session path for storing traces.
-     */
-    private String fSessionPath = ""; //$NON-NLS-1$
-    /**
-     * The domains information of this session.
-     */
-    private final List<IDomainInfo> fDomains = new ArrayList<>();
-    /**
-     * Flag to indicate whether trace is streamed over network or not.
-     */
-    private boolean fIsStreamedTrace = false;
-    /**
-     * Flag to indicate whether the session is a snapshot session or not.
-     */
-    private boolean fIsSnapshot = false;
-    /**
-     * The snapshot information of the session
-     */
-    private ISnapshotInfo fSnapshotInfo = null;
-    /**
-     * The network URL for the session (-U)
-     */
-    private String fNetworkUrl = null;
-    /**
-     * The control URL for the session (-C)
-     */
-    private String fControlUrl = null;
-    /**
-     * The data URL for the session (-D)
-     */
-    private String fDataUrl = null;
-
-    /**
-     * Flag to indicate whether trace is live or not.
-     */
-    private boolean fIsLive = false;
-
-    /**
-     * The delay in micro seconds before the data is flushed and streamed.
-     */
-    private long fLiveDelay = -1;
-
-    /**
-     * The live connection url (Relayd).
-     */
-    private String fLiveUrl;
-
-    /**
-     * The live connection port (Relayd).
-     */
-    private Integer fLivePort;
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-    /**
-     * Constructor
-     *
-     * @param name
-     *            - name of base event
-     */
-    public SessionInfo(String name) {
-        super(name);
-    }
-
-    /**
-     * Copy constructor
-     *
-     * @param other
-     *            - the instance to copy
-     */
-    public SessionInfo(SessionInfo other) {
-        super(other);
-        fState = other.fState;
-        fSessionPath = other.fSessionPath;
-        fIsStreamedTrace = other.fIsStreamedTrace;
-        fIsSnapshot = other.fIsSnapshot;
-        fSnapshotInfo = other.fSnapshotInfo;
-        fNetworkUrl = other.fNetworkUrl;
-        fControlUrl = other.fControlUrl;
-        fDataUrl = other.fDataUrl;
-
-        for (Iterator<IDomainInfo> iterator = other.fDomains.iterator(); iterator.hasNext();) {
-            IDomainInfo domain = iterator.next();
-            if (domain instanceof DomainInfo) {
-                fDomains.add(new DomainInfo((DomainInfo) domain));
-            } else {
-                fDomains.add(domain);
-            }
-        }
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    @Override
-    public TraceSessionState getSessionState() {
-        return fState;
-    }
-
-    @Override
-    public void setSessionState(TraceSessionState state) {
-        fState = state;
-    }
-
-    @Override
-    public void setSessionState(String stateName) {
-        fState = TraceSessionState.valueOfString(stateName);
-    }
-
-    @Override
-    public String getSessionPath() {
-        if (isSnapshotSession() && fSnapshotInfo != null) {
-            return fSnapshotInfo.getSnapshotPath();
-        }
-        return fSessionPath;
-    }
-
-    @Override
-    public void setSessionPath(String path) {
-        fSessionPath = path;
-    }
-
-    @Override
-    public IDomainInfo[] getDomains() {
-        return fDomains.toArray(new IDomainInfo[fDomains.size()]);
-    }
-
-    @Override
-    public void setDomains(List<IDomainInfo> domains) {
-        fDomains.clear();
-        for (Iterator<IDomainInfo> iterator = domains.iterator(); iterator.hasNext();) {
-            IDomainInfo domainInfo = iterator.next();
-            fDomains.add(domainInfo);
-        }
-    }
-
-    @Override
-    public boolean isStreamedTrace() {
-        if (isSnapshotSession() && getSnapshotInfo() != null) {
-            return getSnapshotInfo().isStreamedSnapshot();
-        }
-        return fIsStreamedTrace;
-    }
-
-    @Override
-    public void setStreamedTrace(boolean isStreamedTrace) {
-        fIsStreamedTrace = isStreamedTrace;
-    }
-
-    @Override
-    public boolean isSnapshotSession() {
-        return fIsSnapshot || fSnapshotInfo != null;
-    }
-
-    @Override
-    public void setSnapshot(boolean isSnapshot) {
-        fIsSnapshot = isSnapshot;
-    }
-
-    @Override
-    public ISnapshotInfo getSnapshotInfo() {
-        return fSnapshotInfo;
-    }
-
-    @Override
-    public void setSnapshotInfo(ISnapshotInfo info) {
-        fSnapshotInfo = info;
-    }
-
-    @Override
-    public boolean isLive() {
-        return fIsLive;
-    }
-
-    @Override
-    public void setLive(boolean isLive) {
-        fIsLive = isLive;
-    }
-
-    @Override
-    public long getLiveDelay() {
-        return fLiveDelay;
-    }
-
-    @Override
-    public void setLiveDelay(long liveDelay) {
-        fLiveDelay = liveDelay;
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    public void addDomain(IDomainInfo domainInfo) {
-        fDomains.add(domainInfo);
-    }
-
-    @SuppressWarnings("nls")
-    @Override
-    public String toString() {
-        StringBuffer output = new StringBuffer();
-        output.append("[SessionInfo(");
-        output.append(super.toString());
-        output.append(",Path=");
-        output.append(getSessionPath());
-        output.append(",State=");
-        output.append(fState);
-        output.append(",isStreamedTrace=");
-        output.append(fIsStreamedTrace);
-        output.append(",isSnapshot=");
-        output.append(fIsSnapshot);
-
-        if (fSnapshotInfo != null) {
-            output.append(",snapshotInfo=");
-            output.append(fSnapshotInfo.toString());
-        }
-        output.append(",Domains=");
-        for (Iterator<IDomainInfo> iterator = fDomains.iterator(); iterator.hasNext();) {
-            IDomainInfo domain = iterator.next();
-            output.append(domain.toString());
-        }
-
-        output.append(",NetworkUrl=");
-        output.append(getNetworkUrl());
-        output.append(",ControlUrl=");
-        output.append(getControlUrl());
-        output.append(",DataUrl=");
-        output.append(getDataUrl());
-
-        output.append(")]");
-        return output.toString();
-    }
-
-    @Override
-    public String getNetworkUrl() {
-        return fNetworkUrl;
-    }
-
-    @Override
-    public void setNetworkUrl(String networkUrl) {
-        fNetworkUrl = networkUrl;
-    }
-
-    @Override
-    public String getControlUrl() {
-        return fControlUrl;
-    }
-
-    @Override
-    public void setControlUrl(String controlUrl) {
-        fControlUrl = controlUrl;
-    }
-
-    @Override
-    public void setDataUrl(String datalUrl) {
-        fDataUrl = datalUrl;
-    }
-
-    @Override
-    public String getDataUrl() {
-        return fDataUrl;
-    }
-
-    @Override
-    public void setLiveUrl(String liveUrl) {
-        fLiveUrl = liveUrl;
-    }
-
-    @Override
-    public void setLivePort(Integer livePort) {
-        fLivePort = livePort;
-    }
-
-    @Override
-    public String getLiveUrl() {
-        return fLiveUrl;
-    }
-
-    @Override
-    public Integer getLivePort() {
-        return fLivePort;
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/SnapshotInfo.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/SnapshotInfo.java
deleted file mode 100644 (file)
index 9adc78f..0000000
+++ /dev/null
@@ -1,150 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2013, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.core.model.impl;
-
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISnapshotInfo;
-
-/**
- * <p>
- * Implementation of the snapshot interface (ISnapshotInfo) to store snapshot
- * related data.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class SnapshotInfo extends TraceInfo implements ISnapshotInfo {
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-    /** The snapshot path for storing traces. */
-    private String fPath = ""; //$NON-NLS-1$
-    /** The snapshot ID */
-    private int fId = -1;
-    /** Flag whether snapshot is stored over the network or locally */
-    private boolean fIsStreamed = false;
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-    /**
-     * Constructor
-     * @param name - name of base event
-     */
-    public SnapshotInfo(String name) {
-        super(name);
-    }
-
-    /**
-     * Copy constructor
-     * @param other - the instance to copy
-     */
-    public SnapshotInfo(SnapshotInfo other) {
-        super(other);
-        fPath = other.fPath;
-        fId = other.fId;
-        fIsStreamed = other.fIsStreamed;
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    @Override
-    public String getSnapshotPath() {
-        return fPath;
-    }
-
-    @Override
-    public void setSnapshotPath(String path) {
-        fPath = path;
-    }
-
-    @Override
-    public int getId() {
-        return fId;
-    }
-
-    @Override
-    public void setId(int id) {
-        fId = id;
-    }
-
-    @Override
-    public void setStreamedSnapshot(boolean isStreamed) {
-        fIsStreamed = isStreamed;
-    }
-
-    @Override
-    public boolean isStreamedSnapshot() {
-        return fIsStreamed;
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    public int hashCode() {
-        final int prime = 31;
-        int result = super.hashCode();
-        result = prime * result + fId;
-        result = prime * result + (fIsStreamed ? 1231 : 1237);
-        result = prime * result + ((fPath == null) ? 0 : fPath.hashCode());
-        return result;
-    }
-
-    @Override
-    public boolean equals(Object obj) {
-        if (this == obj) {
-            return true;
-        }
-        if (!super.equals(obj)) {
-            return false;
-        }
-        if (getClass() != obj.getClass()) {
-            return false;
-        }
-        SnapshotInfo other = (SnapshotInfo) obj;
-        if (fId != other.fId) {
-            return false;
-        }
-        if (fIsStreamed != other.fIsStreamed) {
-            return false;
-        }
-        if (fPath == null) {
-            if (other.fPath != null) {
-                return false;
-            }
-        } else if (!fPath.equals(other.fPath)) {
-            return false;
-        }
-        return true;
-    }
-
-    @SuppressWarnings("nls")
-    @Override
-    public String toString() {
-        StringBuffer output = new StringBuffer();
-            output.append("[SnapshotInfo(");
-            output.append(super.toString());
-            output.append(",snapshotPath=");
-            output.append(fPath);
-            output.append(",ID=");
-            output.append(fId);
-            output.append(",isStreamedSnapshot=");
-            output.append(fIsStreamed);
-            output.append(")]");
-            return output.toString();
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/TraceInfo.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/TraceInfo.java
deleted file mode 100644 (file)
index 82e70d6..0000000
+++ /dev/null
@@ -1,113 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.core.model.impl;
-
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.ITraceInfo;
-
-/**
- * <p>
- * Implementation of the base trace information interface (ITraceInfo) to
- * store common data.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class TraceInfo implements ITraceInfo {
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-    /**
-     * The name of the element.
-     */
-    private String fName = null;
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-    /**
-     * Constructor
-     * @param name - name of trace element
-     */
-    public TraceInfo(String name) {
-        if (name == null) {
-            throw new IllegalArgumentException();
-        }
-        fName = name;
-    }
-
-    /**
-     * Copy constructor
-     * @param other - the instance to copy
-     */
-    public TraceInfo(TraceInfo other) {
-        if (other == null) {
-            throw new IllegalArgumentException();
-        }
-        fName = String.valueOf(other.fName);
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    @Override
-    public String getName() {
-        return fName;
-    }
-
-    @Override
-    public void setName(String name) {
-        fName = name;
-    }
-
-    @Override
-    public int hashCode() {
-        final int prime = 31;
-        int result = 1;
-        result = prime * result + ((fName == null) ? 0 : fName.hashCode());
-        return result;
-    }
-
-    @Override
-    public boolean equals(Object obj) {
-        if (this == obj) {
-            return true;
-        }
-        if (obj == null) {
-            return false;
-        }
-        if (getClass() != obj.getClass()) {
-            return false;
-        }
-        TraceInfo other = (TraceInfo) obj;
-        if (fName == null) {
-            if (other.fName != null) {
-                return false;
-            }
-        } else if (!fName.equals(other.fName)) {
-            return false;
-        }
-        return true;
-    }
-
-    @SuppressWarnings("nls")
-    @Override
-    public String toString() {
-        StringBuffer output = new StringBuffer();
-            output.append("[TraceInfo(");
-            output.append("Name=");
-            output.append(getName());
-            output.append(")]");
-            return output.toString();
-    }
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/UstProviderInfo.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/model/impl/UstProviderInfo.java
deleted file mode 100644 (file)
index 570d1a6..0000000
+++ /dev/null
@@ -1,162 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.core.model.impl;
-
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IBaseEventInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IUstProviderInfo;
-
-/**
- * <p>
- * Implementation of the Ust Provider interface (IUstProviderInfo) to store UST
- * provider related data.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class UstProviderInfo extends TraceInfo implements IUstProviderInfo {
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-
-    /**
-     * The process ID of the UST provider.
-     */
-    private int fPid = 0;
-
-    /**
-     * List of event information.
-     */
-    private final List<IBaseEventInfo> fEvents = new ArrayList<>();
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-
-    /**
-     * Constructor
-     * @param name - name of UST provider
-     */
-    public UstProviderInfo(String name) {
-        super(name);
-    }
-
-    /**
-     * Copy constructor
-     * @param other - the instance to copy
-     */
-    public UstProviderInfo(UstProviderInfo other) {
-        super(other);
-        fPid = other.fPid;
-        for (Iterator<IBaseEventInfo> iterator = other.fEvents.iterator(); iterator.hasNext();) {
-            IBaseEventInfo event = iterator.next();
-            if (event instanceof BaseEventInfo) {
-                fEvents.add(new BaseEventInfo((BaseEventInfo)event));
-            } else {
-                fEvents.add(event);
-            }
-        }
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    @Override
-    public int getPid() {
-        return fPid;
-    }
-
-    @Override
-    public void setPid(int pid) {
-        fPid = pid;
-    }
-
-    @Override
-    public IBaseEventInfo[] getEvents() {
-        return fEvents.toArray(new IBaseEventInfo[fEvents.size()]);
-    }
-
-    @Override
-    public void setEvents(List<IBaseEventInfo> events) {
-        fEvents.clear();
-        for (Iterator<IBaseEventInfo> iterator = events.iterator(); iterator.hasNext();) {
-            IBaseEventInfo eventInfo = iterator.next();
-            fEvents.add(eventInfo);
-        }
-    }
-
-    @Override
-    public void addEvent(IBaseEventInfo event) {
-        fEvents.add(event);
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    public int hashCode() {
-        final int prime = 31;
-        int result = super.hashCode();
-        result = prime * result + fEvents.hashCode();
-        result = prime * result + fPid;
-        return result;
-    }
-
-    @Override
-    public boolean equals(Object obj) {
-        if (this == obj) {
-            return true;
-        }
-        if (!super.equals(obj)) {
-            return false;
-        }
-        if (getClass() != obj.getClass()) {
-            return false;
-        }
-        UstProviderInfo other = (UstProviderInfo) obj;
-        if (!fEvents.equals(other.fEvents)) {
-            return false;
-        }
-        if (fPid != other.fPid) {
-            return false;
-        }
-        return true;
-    }
-
-    @SuppressWarnings("nls")
-    @Override
-    public String toString() {
-        StringBuffer output = new StringBuffer();
-            output.append("[EventInfo(");
-            output.append(super.toString());
-            output.append(",PID=");
-            output.append(fPid);
-            output.append(",Events=");
-            if (fEvents.isEmpty()) {
-                output.append("None");
-            } else {
-                for (Iterator<IBaseEventInfo> iterator = fEvents.iterator(); iterator.hasNext();) {
-                    IBaseEventInfo event = iterator.next();
-                    output.append(event.toString());
-                }
-            }
-            output.append(")]");
-            return output.toString();
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/ILttngRelaydConnector.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/ILttngRelaydConnector.java
deleted file mode 100644 (file)
index 88862b0..0000000
+++ /dev/null
@@ -1,118 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014 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:
- *   Matthew Khouzam - Initial implementation
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.core.relayd;
-
-import java.io.IOException;
-import java.util.List;
-
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.AttachSessionResponse;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.CreateSessionResponse;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.IndexResponse;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.SessionResponse;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.StreamResponse;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.TracePacketResponse;
-
-/**
- * Connector for Lttng Relayd
- *
- * @author Matthew Khouzam
- */
-public interface ILttngRelaydConnector extends AutoCloseable {
-
-    /**
-     * Gets a list of active Lttng sessions
-     *
-     * @return the session List (we need the get function)
-     * @throws IOException
-     *             timeout and such
-     */
-    List<SessionResponse> getSessions() throws IOException;
-
-    /**
-     * Create a session
-     *
-     * @return create session response
-     * @throws IOException
-     *             timeout and such
-     */
-    CreateSessionResponse createSession() throws IOException;
-
-    /**
-     * Attach the trace viewer to a Session
-     *
-     * @param lttngViewerSession
-     *            viewer session
-     * @return An AttachSessionResponse
-     * @throws IOException
-     *             timeout and such
-     */
-    AttachSessionResponse attachToSession(SessionResponse lttngViewerSession) throws IOException;
-
-    /**
-     * Get the metadata from the relayd
-     *
-     * @param attachedSession
-     *            the attached session
-     * @return a chunk of TSDL metadata
-     * @throws IOException
-     *             timeout and such
-     */
-    String getMetadata(AttachSessionResponse attachedSession) throws IOException;
-
-    /**
-     * Get the next index
-     *
-     * @param stream
-     *            the stream
-     * @return the stream input packet entry
-     * @throws IOException
-     *             timeout and such
-     */
-    IndexResponse getNextIndex(StreamResponse stream) throws IOException;
-
-    /**
-     * Get the next packet in a stream
-     *
-     * @param stream
-     *            the stream response
-     * @return the packet response
-     * @throws IOException
-     *             timeout and such
-     */
-    TracePacketResponse getNextPacket(StreamResponse stream) throws IOException;
-
-    /**
-     * Gets the packet from the stream
-     *
-     * @param index
-     *            the index of the stream
-     * @param id
-     *            the stream id
-     * @return the packet response
-     * @throws IOException
-     *             timeout and such
-     */
-    TracePacketResponse getPacketFromStream(IndexResponse index, long id) throws IOException;
-
-    /**
-     * Gets the new streams
-     *
-     * @return a list of stream responses
-     * @throws IOException
-     *             timeout and such
-     */
-    Iterable<StreamResponse> getNewStreams() throws IOException;
-
-    @Override
-    void close() throws IOException;
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/LttngRelaydConnectorFactory.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/LttngRelaydConnectorFactory.java
deleted file mode 100644 (file)
index faac481..0000000
+++ /dev/null
@@ -1,77 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014 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:
- *   Matthew Khouzam - Initial implementation
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.core.relayd;
-
-import java.io.DataInputStream;
-import java.io.DataOutputStream;
-import java.io.IOException;
-import java.net.Socket;
-
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.Command;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.ConnectResponse;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.ConnectionType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.ViewerCommand;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.impl.LttngRelaydConnector_2_4;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.impl.LttngRelaydConnector_Unsupported;
-
-/**
- * LTTng RelayD connector factory
- *
- * @author Matthew Khouzam
- */
-public final class LttngRelaydConnectorFactory {
-
-    private LttngRelaydConnectorFactory() {
-    }
-
-    /**
-     * Create a connection to a relayd
-     *
-     * @param myConnection
-     *            a connection to the relayd
-     *
-     * @return A relayd connector
-     * @throws IOException
-     *             caused by invalid sockets
-     */
-    public static ILttngRelaydConnector getNewConnector(Socket myConnection) throws IOException {
-        DataOutputStream outNet = new DataOutputStream(myConnection.getOutputStream());
-        DataInputStream inNet = new DataInputStream(myConnection.getInputStream());
-
-        ViewerCommand connectCommand = new ViewerCommand(Command.VIEWER_CONNECT, ConnectResponse.SIZE, 0);
-
-        outNet.write(connectCommand.serialize());
-        outNet.flush();
-
-        ConnectResponse payload = new ConnectResponse(0, 2, 4, ConnectionType.VIEWER_CLIENT_COMMAND);
-        outNet.write(payload.serialize());
-        outNet.flush();
-
-        ConnectResponse connectReply = new ConnectResponse(inNet);
-        switch (connectReply.getMajor()) {
-        case 2:
-            switch (connectReply.getMinor()) {
-            case 0:
-            case 1:
-            case 2:
-            case 3:
-                return new LttngRelaydConnector_Unsupported();
-            case 4:
-            default:
-                return new LttngRelaydConnector_2_4(inNet, outNet);
-            }
-        default:
-            return new LttngRelaydConnector_Unsupported();
-        }
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/AttachReturnCode.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/AttachReturnCode.java
deleted file mode 100644 (file)
index d81fed8..0000000
+++ /dev/null
@@ -1,46 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014 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:
- *   Matthew Khouzam - Initial implementation and API
- *   Marc-Andre Laperle - Initial implementation and API
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
-
-/**
- * Return codes for "viewer attach" command
- *
- * @author Matthew Khouzam
- */
-public enum AttachReturnCode implements IBaseCommand {
-
-    /** If the attach command succeeded. */
-    VIEWER_ATTACH_OK(1),
-    /** If a viewer is already attached. */
-    VIEWER_ATTACH_ALREADY(2),
-    /** If the session ID is unknown. */
-    VIEWER_ATTACH_UNK(3),
-    /** If the session is not live. */
-    VIEWER_ATTACH_NOT_LIVE(4),
-    /** Seek error. */
-    VIEWER_ATTACH_SEEK_ERR(5),
-    /** No session */
-    VIEWER_ATTACH_NO_SESSION(6);
-
-    private final int fCode;
-
-    private AttachReturnCode(int c) {
-        fCode = c;
-    }
-
-    @Override
-    public int getCommand() {
-        return fCode;
-    }
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/AttachSessionRequest.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/AttachSessionRequest.java
deleted file mode 100644 (file)
index cf9ee7b..0000000
+++ /dev/null
@@ -1,80 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014 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:
- *   Matthew Khouzam - Initial implementation and API
- *   Marc-Andre Laperle - Initial implementation and API
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
-
-import java.nio.ByteBuffer;
-import java.nio.ByteOrder;
-
-/**
- * VIEWER_ATTACH_SESSION payload.
- *
- * @author Matthew Khouzam
- */
-public class AttachSessionRequest implements IRelayCommand {
-
-    /**
-     * Command size
-     *
-     * fSessionId + fOffset + fSeek
-     */
-    public static final int SIZE = (Long.SIZE + Long.SIZE) / 8 + SeekCommand.SIZE;
-    /** the id of a session */
-    private final long fSessionId;
-    /** unused for now */
-    private final long fOffset;
-    /** enum lttng_viewer_seek */
-    private final SeekCommand fSeek;
-
-    /**
-     * Attach session request constructor
-     *
-     * @param id
-     *            the session id
-     * @param seekCommand
-     *            the seek command
-     */
-    public AttachSessionRequest(long id, SeekCommand seekCommand) {
-        this(id, 0, seekCommand);
-    }
-
-    /**
-     * Attach session request constructor
-     *
-     * @param id
-     *            the session id
-     * @param offset
-     *            unused for now
-     * @param seekCommand
-     *            the seek command
-     */
-
-    public AttachSessionRequest(long id, int offset, SeekCommand seekCommand) {
-        fSessionId = id;
-        fOffset = offset;
-        fSeek = seekCommand;
-
-    }
-
-    @Override
-    public byte[] serialize() {
-        byte data[] = new byte[SIZE];
-        ByteBuffer bb = ByteBuffer.wrap(data);
-        bb.order(ByteOrder.BIG_ENDIAN);
-        bb.putLong(fSessionId);
-        bb.putLong(fOffset);
-        bb.putInt(fSeek.getCommand());
-        return data;
-    }
-
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/AttachSessionResponse.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/AttachSessionResponse.java
deleted file mode 100644 (file)
index d30876a..0000000
+++ /dev/null
@@ -1,94 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014 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:
- *   Matthew Khouzam - Initial implementation and API
- *   Marc-Andre Laperle - Initial implementation and API
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
-
-import java.io.DataInputStream;
-import java.io.IOException;
-import java.nio.ByteBuffer;
-import java.nio.ByteOrder;
-import java.util.List;
-
-import com.google.common.collect.ImmutableList;
-import com.google.common.collect.ImmutableList.Builder;
-
-/**
- * Attach session response
- *
- * @author Matthew Khouzam
- */
-public class AttachSessionResponse implements IRelayResponse {
-
-    /**
-     * Response size
-     *
-     * fStatus + fStreamsCount (first half of a packet) */
-    private static final int SIZE = (Integer.SIZE + Integer.SIZE) / 8;
-    /** enum lttng_viewer_attach_return_code */
-    private final AttachReturnCode fStatus;
-    /** how many streams are there */
-    private final int fStreamsCount;
-    /** public class lttng_viewer_stream */
-    private final List<StreamResponse> fStreamList;
-
-    /**
-     * Attach session response network constructor
-     *
-     * @param inNet
-     *            network input stream
-     * @throws IOException
-     *             network error
-     */
-    public AttachSessionResponse(DataInputStream inNet) throws IOException {
-        byte[] data = new byte[SIZE];
-        inNet.readFully(data, 0, SIZE);
-        ByteBuffer bb = ByteBuffer.wrap(data);
-        bb.order(ByteOrder.BIG_ENDIAN);
-        fStatus = AttachReturnCode.values()[bb.getInt() - 1];
-        fStreamsCount = bb.getInt();
-        Builder<StreamResponse> streamResponses = ImmutableList.builder();
-        for (int i = 0; i < getNbStreams(); i++) {
-            streamResponses.add(new StreamResponse(inNet));
-        }
-        fStreamList = streamResponses.build();
-
-    }
-
-    /**
-     * Gets the Status
-     *
-     * @return the Status
-     */
-    public AttachReturnCode getStatus() {
-        return fStatus;
-    }
-
-    /**
-     * Gets the StreamsCount
-     *
-     * @return the StreamsCount
-     */
-    public int getNbStreams() {
-        return fStreamsCount;
-    }
-
-    /**
-     * Gets the StreamList
-     *
-     * @return the StreamList
-     */
-    public List<StreamResponse> getStreamList() {
-        return fStreamList;
-    }
-
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/Command.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/Command.java
deleted file mode 100644 (file)
index 706d189..0000000
+++ /dev/null
@@ -1,55 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014 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:
- *   Matthew Khouzam - Initial implementation and API
- *   Marc-Andre Laperle - Initial implementation and API
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
-
-/**
- * Viewer commands
- *
- * @author Matthew Khouzam
- */
-public enum Command implements IBaseCommand {
-
-    /** get version */
-    VIEWER_CONNECT(1),
-    /** list all lttng sessions */
-    VIEWER_LIST_SESSIONS(2),
-    /** attach to a session */
-    VIEWER_ATTACH_SESSION(3),
-    /** get the next index */
-    VIEWER_GET_NEXT_INDEX(4),
-    /** get packet */
-    VIEWER_GET_PACKET(5),
-    /** get metadata */
-    VIEWER_GET_METADATA(6),
-    /** get new streams */
-    VIEWER_GET_NEW_STREAMS(7),
-    /** create a new session */
-    VIEWER_CREATE_SESSION(8);
-
-    /**
-     * Command size (fCode)
-     */
-    public static final int SIZE = Integer.SIZE / 8;
-
-    private final int fCode;
-
-    private Command(int c) {
-        fCode = c;
-    }
-
-    @Override
-    public int getCommand() {
-        return fCode;
-    }
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/ConnectResponse.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/ConnectResponse.java
deleted file mode 100644 (file)
index e608151..0000000
+++ /dev/null
@@ -1,118 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014 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:
- *   Matthew Khouzam - Initial implementation and API
- *   Marc-Andre Laperle - Initial implementation and API
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
-
-import java.io.DataInputStream;
-import java.io.IOException;
-import java.nio.ByteBuffer;
-import java.nio.ByteOrder;
-
-/**
- * CONNECT payload.
- *
- * @author Matthew Khouzam
- */
-public class ConnectResponse implements IRelayResponse, IRelayCommand {
-
-    /**
-     * Response or command size
-     *
-     * fViewerSessionId + fMajor + fMinor + fType
-     */
-    public static final int SIZE = (Long.SIZE + Integer.SIZE + Integer.SIZE + Integer.SIZE) / 8;
-    /** session id, counts from 1 and increments by session */
-    private final long fViewerSessionId;
-    /**
-     * Major version, hint, it's at least 2
-     */
-    private final int fMajor;
-    /**
-     * Minor version, hint, it's at least 4
-     */
-    private final int fMinor;
-    /**
-     * type of connect to {@link ConnectionType}
-     */
-    private final ConnectionType fType;
-
-    /**
-     * Connection response reply constructor
-     *
-     * @param inStream
-     *            the data input stream
-     * @throws IOException
-     *             a network error
-     */
-    public ConnectResponse(DataInputStream inStream) throws IOException {
-        byte data[] = new byte[SIZE];
-        inStream.readFully(data);
-        ByteBuffer bb = ByteBuffer.wrap(data);
-        bb.order(ByteOrder.BIG_ENDIAN);
-        fViewerSessionId = bb.getLong();
-        fMajor = bb.getInt();
-        fMinor = bb.getInt();
-        bb.getInt(); // Should not be used, see http://bugs.lttng.org/issues/728
-        fType = ConnectionType.VIEWER_CLIENT_COMMAND;
-    }
-
-    /**
-     * Constructor for command
-     *
-     * @param sessionID
-     *            session id
-     * @param major
-     *            the major version
-     * @param minor
-     *            the minor version
-     * @param connection
-     *            the connection type, typically VIEWER_CLIENT_COMMAND
-     */
-    public ConnectResponse(long sessionID, int major, int minor, ConnectionType connection) {
-        fViewerSessionId = sessionID;
-        fMajor = major;
-        fMinor = minor;
-        fType = connection;
-    }
-
-    /**
-     * get the major version
-     *
-     * @return the major version
-     */
-    public int getMajor() {
-        return fMajor;
-    }
-
-    /**
-     * get the minor version
-     *
-     * @return the minor version
-     */
-    public int getMinor() {
-        return fMinor;
-    }
-
-    @Override
-    public byte[] serialize() {
-        byte data[] = new byte[SIZE];
-        ByteBuffer bb = ByteBuffer.wrap(data);
-        bb.order(ByteOrder.BIG_ENDIAN);
-        bb.putLong(fViewerSessionId);
-        bb.putInt(fMajor);
-        bb.putInt(fMinor);
-        bb.putInt(fType.getCommand());
-        return data;
-    }
-
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/ConnectionType.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/ConnectionType.java
deleted file mode 100644 (file)
index a89c374..0000000
+++ /dev/null
@@ -1,39 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014 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:
- *   Matthew Khouzam - Initial implementation and API
- *   Marc-Andre Laperle - Initial implementation and API
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
-
-/**
- * Get viewer connection type
- *
- * @author Matthew Khouzam
- */
-public enum ConnectionType implements IBaseCommand {
-
-    /** Command sent */
-    VIEWER_CLIENT_COMMAND(1),
-    /** Notification sent */
-    VIEWER_CLIENT_NOTIFICATION(2);
-
-    private final int fCode;
-
-    private ConnectionType(int c) {
-        fCode = c;
-    }
-
-    @Override
-    public int getCommand() {
-        return fCode;
-    }
-
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/CreateSessionResponse.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/CreateSessionResponse.java
deleted file mode 100644 (file)
index 6e988f6..0000000
+++ /dev/null
@@ -1,61 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014 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:
- *   Matthew Khouzam - Initial implementation and API
- *   Marc-Andre Laperle - Initial implementation and API
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
-
-import java.io.DataInputStream;
-import java.io.IOException;
-import java.nio.ByteBuffer;
-import java.nio.ByteOrder;
-
-/**
- * Response to a "create session" command
- *
- * @author Matthew Khouzam
- */
-public class CreateSessionResponse implements IRelayResponse {
-
-    /**
-     * Response size (fStatus)
-     */
-    public static final int SIZE = Integer.SIZE / 8;
-
-    /** enum lttng_viewer_create_session_return_code */
-    private final CreateSessionReturnCode fStatus;
-
-    /**
-     * Create session response network constructor
-     *
-     * @param inNet
-     *            network input stream
-     * @throws IOException
-     *             network error
-     */
-    public CreateSessionResponse(DataInputStream inNet) throws IOException {
-        byte[] data = new byte[SIZE];
-        inNet.readFully(data);
-        ByteBuffer bb = ByteBuffer.wrap(data);
-        bb.order(ByteOrder.BIG_ENDIAN);
-        fStatus = (CreateSessionReturnCode.values()[bb.getInt() - 1]);
-    }
-
-    /**
-     * Get status
-     *
-     * @return the status
-     */
-    public CreateSessionReturnCode getStatus() {
-        return fStatus;
-    }
-
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/CreateSessionReturnCode.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/CreateSessionReturnCode.java
deleted file mode 100644 (file)
index cd910a2..0000000
+++ /dev/null
@@ -1,38 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014 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:
- *   Matthew Khouzam - Initial implementation and API
- *   Marc-Andre Laperle - Initial implementation and API
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
-
-/**
- * Create new session return code
- *
- * @author Matthew Khouzam
- */
-public enum CreateSessionReturnCode implements IBaseCommand {
-
-    /** If new streams are being sent. */
-    LTTNG_VIEWER_CREATE_SESSION_OK(1),
-    /** Fatal error on the server-side. */
-    LTTNG_VIEWER_CREATE_SESSION_ERR(2);
-
-    private final int fCode;
-
-    private CreateSessionReturnCode(int c) {
-        fCode = c;
-    }
-
-    @Override
-    public int getCommand() {
-        return fCode;
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/GetMetadata.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/GetMetadata.java
deleted file mode 100644 (file)
index 13c61dc..0000000
+++ /dev/null
@@ -1,64 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014 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:
- *   Matthew Khouzam - Initial implementation and API
- *   Marc-Andre Laperle - Initial implementation and API
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
-
-import java.nio.ByteBuffer;
-import java.nio.ByteOrder;
-
-/**
- * VIEWER_GET_METADATA payload.
- *
- * @author Matthew Khouzam
- */
-public class GetMetadata implements IRelayCommand {
-
-    /**
-     * Command size (fStreamId)
-     */
-    public static final int SIZE = Long.SIZE / 8;
-
-    /**
-     * The stream id
-     */
-    private final long fStreamId;
-
-    /**
-     * Set the stream id
-     *
-     * @param streamId
-     *            the stream id
-     */
-    public GetMetadata(long streamId) {
-        fStreamId = streamId;
-    }
-
-    /**
-     * Get the stream id
-     *
-     * @return the stream id
-     */
-    public long getStreamId() {
-        return fStreamId;
-    }
-
-    @Override
-    public byte[] serialize() {
-        byte data[] = new byte[SIZE];
-        ByteBuffer bb = ByteBuffer.wrap(data);
-        bb.order(ByteOrder.BIG_ENDIAN);
-        bb.putLong(getStreamId());
-        return data;
-    }
-
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/GetMetadataReturnCode.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/GetMetadataReturnCode.java
deleted file mode 100644 (file)
index f126dc4..0000000
+++ /dev/null
@@ -1,41 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014 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:
- *   Matthew Khouzam - Initial implementation and API
- *   Marc-Andre Laperle - Initial implementation and API
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
-
-/**
- * Get metadata return code
- *
- * @author Matthew Khouzam
- */
-public enum GetMetadataReturnCode implements IBaseCommand {
-
-    /** Response was OK */
-    VIEWER_METADATA_OK(1),
-    /** Response was nothing new */
-    VIEWER_NO_NEW_METADATA(2),
-    /** Response was Error */
-    VIEWER_METADATA_ERR(3);
-
-    private final int fCode;
-
-    private GetMetadataReturnCode(int c) {
-        fCode = c;
-    }
-
-    @Override
-    public int getCommand() {
-        return fCode;
-    }
-
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/GetNextIndex.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/GetNextIndex.java
deleted file mode 100644 (file)
index 697789a..0000000
+++ /dev/null
@@ -1,63 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014 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:
- *   Matthew Khouzam - Initial implementation and API
- *   Marc-Andre Laperle - Initial implementation and API
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
-
-import java.nio.ByteBuffer;
-import java.nio.ByteOrder;
-
-/**
- * VIEWER_GET_NEXT_INDEX payload.
- *
- * @author Matthew Khouzam
- */
-public class GetNextIndex implements IRelayCommand {
-
-    /**
-     * Command size (fStreamId)
-     */
-    public static final int SIZE = Long.SIZE / 8;
-    /**
-     * the id of the stream
-     */
-    private final long fStreamId;
-
-    /**
-     * Constructor
-     *
-     * @param streamId
-     *            the index stream id
-     */
-    public GetNextIndex(long streamId) {
-        fStreamId = streamId;
-    }
-
-    /**
-     * Gets the stream id
-     *
-     * @return the stream id
-     */
-    public long getStreamId() {
-        return fStreamId;
-    }
-
-    @Override
-    public byte[] serialize() {
-        byte data[] = new byte[SIZE];
-        ByteBuffer bb = ByteBuffer.wrap(data);
-        bb.order(ByteOrder.BIG_ENDIAN);
-        bb.putLong(getStreamId());
-        return data;
-    }
-
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/GetPacket.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/GetPacket.java
deleted file mode 100644 (file)
index 2eb0483..0000000
+++ /dev/null
@@ -1,93 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014 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:
- *   Matthew Khouzam - Initial implementation and API
- *   Marc-Andre Laperle - Initial implementation and API
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
-
-import java.nio.ByteBuffer;
-import java.nio.ByteOrder;
-
-/**
- * VIEWER_GET_PACKET payload.
- *
- * @author Matthew Khouzam
- */
-public class GetPacket implements IRelayCommand {
-
-    /**
-     * Command size
-     *
-     * fStreamId + fOffset + fLength
-     */
-    public static final int SIZE = (Long.SIZE + Long.SIZE + Integer.SIZE) / 8;
-    /** the stream Id */
-    private final long fStreamId;
-    /** the offset */
-    private final long fOffset;
-    /** the length of the packet */
-    private final int fLength;
-
-    /**
-     * Get packet constructor
-     *
-     * @param streamId
-     *            the stream id
-     * @param offset
-     *            the offset
-     * @param length
-     *            the packet length
-     */
-    public GetPacket(long streamId, long offset, int length) {
-        fStreamId = streamId;
-        fOffset = offset;
-        fLength = length;
-    }
-
-    /**
-     * Get the length of the packet
-     *
-     * @return the length of the packet in bytes
-     */
-    public int getLength() {
-        return fLength;
-    }
-
-    /**
-     * Gets the offset of the packet
-     *
-     * @return the offset
-     */
-    public long getOffset() {
-        return fOffset;
-    }
-
-    /**
-     * Gets the stream id
-     *
-     * @return the stream id
-     */
-    public long getStreamId() {
-        return fStreamId;
-    }
-
-    @Override
-    public byte[] serialize() {
-        byte data[] = new byte[SIZE];
-        ByteBuffer bb = ByteBuffer.wrap(data);
-        bb.order(ByteOrder.BIG_ENDIAN);
-        bb.putLong(getStreamId());
-        bb.putLong(getOffset());
-        bb.putInt(getLength());
-        return data;
-    }
-
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/GetPacketReturnCode.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/GetPacketReturnCode.java
deleted file mode 100644 (file)
index b46d171..0000000
+++ /dev/null
@@ -1,43 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014 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:
- *   Matthew Khouzam - Initial implementation and API
- *   Marc-Andre Laperle - Initial implementation and API
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
-
-/**
- * Get packet return code
- *
- * @author Matthew Khouzam
- */
-public enum GetPacketReturnCode implements IBaseCommand {
-
-    /** Response was OK */
-    VIEWER_GET_PACKET_OK(1),
-    /** Response was RETRY */
-    VIEWER_GET_PACKET_RETRY(2),
-    /** Response was ERROR */
-    VIEWER_GET_PACKET_ERR(3),
-    /** Response was End of File */
-    VIEWER_GET_PACKET_EOF(4);
-
-    private final int fCode;
-
-    private GetPacketReturnCode(int c) {
-        fCode = c;
-    }
-
-    @Override
-    public int getCommand() {
-        return fCode;
-    }
-
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/IBaseCommand.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/IBaseCommand.java
deleted file mode 100644 (file)
index 16fe7b3..0000000
+++ /dev/null
@@ -1,29 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014 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:
- *   Matthew Khouzam - Initial implementation and API
- *   Marc-Andre Laperle - Initial implementation and API
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
-
-/**
- * Instruction to send to relayd
- *
- * @author Matthew Khouzam
- */
-public interface IBaseCommand {
-
-    /**
-     * gets the numerical value of the command
-     *
-     * @return the numerical value of the command
-     */
-    int getCommand();
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/IRelayCommand.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/IRelayCommand.java
deleted file mode 100644 (file)
index 4c0f5e6..0000000
+++ /dev/null
@@ -1,30 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014 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:
- *   Matthew Khouzam - Initial implementation and API
- *   Marc-Andre Laperle - Initial implementation and API
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
-
-
-/**
- * Command sent, needs a getBytes to stream the data
- *
- * @author Matthew Khouzam
- */
-public interface IRelayCommand {
-
-    /**
-     * Gets a byte array of the command so that it may be streamed
-     *
-     * @return the byte array of the command
-     */
-    byte[] serialize();
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/IRelayResponse.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/IRelayResponse.java
deleted file mode 100644 (file)
index b034da6..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014 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:
- *   Matthew Khouzam - Initial implementation and API
- *   Marc-Andre Laperle - Initial implementation and API
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
-
-/**
- * Command response, this will allow sorting commands easier
- *
- * @author Matthew Khouzam
- */
-public interface IRelayResponse {
-
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/IndexResponse.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/IndexResponse.java
deleted file mode 100644 (file)
index ebfcf88..0000000
+++ /dev/null
@@ -1,162 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014 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:
- *   Matthew Khouzam - Initial implementation and API
- *   Marc-Andre Laperle - Initial implementation and API
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
-
-import java.io.DataInputStream;
-import java.io.IOException;
-import java.nio.ByteBuffer;
-import java.nio.ByteOrder;
-
-/**
- * An Lttng packet index
- *
- * @author Matthew Khouzam
- */
-public class IndexResponse implements IRelayResponse {
-
-    /**
-     * Command size
-     *
-     * Sum of the field sizes / 8 ( 7 longs and 2 ints):
-     * fOffset + fPacketSize + fContentSize + fTimestampBegin + fTimestampEnd +
-     * fEventsDiscarded + fStreamId + fStatus + fFlags
-     */
-    public static final int SIZE =
-            (Long.SIZE * 7 + Integer.SIZE * 2) / 8;
-
-    /** the offset */
-    private final long fOffset;
-    /** packet_size */
-    private final long fPacketSize;
-    /** the content size - how much of the packet is used */
-    private final long fContentSize;
-    /** timestamp of the beginning of the packet */
-    private final long fTimestampBegin;
-    /** timestamp of the end of the packet */
-    private final long fTimestampEnd;
-    /** number of discarded events BEFORE this packet */
-    private final long fEventsDiscarded;
-    /** the CTF stream id */
-    private final long fStreamId;
-    /** the status of the getNextIndex request */
-    private final NextIndexReturnCode fStatus;
-    /** whether there are new streams or metadata */
-    private final int fFlags;
-
-    /**
-     * IndexResposne from network
-     *
-     * @param inNet
-     *            data input stream
-     * @throws IOException
-     *             network error
-     */
-    public IndexResponse(DataInputStream inNet) throws IOException {
-        byte[] data = new byte[SIZE];
-        inNet.readFully(data);
-        ByteBuffer bb = ByteBuffer.wrap(data);
-        bb.order(ByteOrder.BIG_ENDIAN);
-        fOffset = bb.getLong();
-        fPacketSize = bb.getLong();
-        fContentSize = bb.getLong();
-        fTimestampBegin = bb.getLong();
-        fTimestampEnd = bb.getLong();
-        fEventsDiscarded = bb.getLong();
-        fStreamId = bb.getLong();
-        fStatus = NextIndexReturnCode.values()[bb.getInt() - 1];
-        fFlags = bb.getInt();
-    }
-
-    /**
-     * Gets the offset
-     *
-     * @return the offset
-     */
-    public long getOffset() {
-        return fOffset;
-    }
-
-    /**
-     * Gets the packet size
-     *
-     * @return the packet size
-     */
-    public long getPacketSize() {
-        return fPacketSize;
-    }
-
-    /**
-     * Gets the content size - how much of the packet is used
-     *
-     * @return the content size
-     */
-    public long getContentSize() {
-        return fContentSize;
-    }
-
-    /**
-     * Gets the timestamp of the beginning of the packet
-     *
-     * @return the timestamp of the beginning of the packet
-     */
-    public long getTimestampBegin() {
-        return fTimestampBegin;
-    }
-
-    /**
-     * Gets the timestamp of the end of the packet
-     *
-     * @return the timestamp of the end of the packet
-     */
-    public long getTimestampEnd() {
-        return fTimestampEnd;
-    }
-
-    /**
-     * Gets the number of discarded events BEFORE this packet
-     *
-     * @return the number of discarded events BEFORE this packet
-     */
-    public long getEventsDiscarded() {
-        return fEventsDiscarded;
-    }
-
-    /**
-     * Gets the CTF stream id
-     *
-     * @return the CTF stream id
-     */
-    public long getStreamId() {
-        return fStreamId;
-    }
-
-    /**
-     * Gets the status
-     *
-     * @return the status
-     */
-    public NextIndexReturnCode getStatus() {
-        return fStatus;
-    }
-
-    /**
-     * Gets the flags that describe whether there are new streams or metadata
-     *
-     * @return the flags
-     */
-    public int getFlags() {
-        return fFlags;
-    }
-
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/ListSessionsResponse.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/ListSessionsResponse.java
deleted file mode 100644 (file)
index 532c8a5..0000000
+++ /dev/null
@@ -1,71 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014 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:
- *   Matthew Khouzam - Initial implementation and API
- *   Marc-Andre Laperle - Initial implementation and API
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
-
-import java.io.DataInputStream;
-import java.io.IOException;
-import java.nio.ByteBuffer;
-import java.nio.ByteOrder;
-import java.util.List;
-
-import com.google.common.collect.ImmutableList;
-import com.google.common.collect.ImmutableList.Builder;
-
-/**
- * VIEWER_LIST_SESSIONS payload.
- *
- * @author Matthew Khouzam
- */
-public class ListSessionsResponse implements IRelayResponse {
-
-    /**
-     * Response size (nbSessions)
-     */
-    public static final int PACKET_FIXED_SIZE = Integer.SIZE / 8;
-
-    /** the list of sessions */
-    private final List<SessionResponse> fSessionList;
-
-    /**
-     * List Sessions response from network
-     *
-     * @param inNet
-     *            the network stream
-     * @throws IOException
-     *             network error
-     */
-    public ListSessionsResponse(DataInputStream inNet) throws IOException {
-        byte[] data = new byte[PACKET_FIXED_SIZE];
-        inNet.readFully(data);
-        ByteBuffer bb = ByteBuffer.wrap(data);
-        bb.order(ByteOrder.BIG_ENDIAN);
-        int nbSessions = bb.getInt();
-        Builder<SessionResponse> sl = new ImmutableList.Builder<>();
-        for (int session = 0; session < nbSessions; session++) {
-            sl.add(new SessionResponse(inNet));
-        }
-        fSessionList = sl.build();
-    }
-
-    /**
-     * Gets the session list
-     *
-     * @return the sessions list
-     */
-    public List<SessionResponse> getSessionsList() {
-        return fSessionList;
-    }
-
-
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/LttngViewerCommands.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/LttngViewerCommands.java
deleted file mode 100644 (file)
index 4a77664..0000000
+++ /dev/null
@@ -1,36 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014 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:
- *   Matthew Khouzam - Initial implementation
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
-
-/**
- * LTTng Relay Daemon API. needs a TCP connection, API is defined from
- * BSD-licensed implementation in Lttng tools: <a href=
- * "http://git.lttng.org/?p=lttng-tools.git;a=blob;f=src/bin/lttng-relayd/lttng-viewer-abi.h"
- * > src/bin/lttng-relayd/lttng-viewer-abi.h</a>
- *
- * @author Matthew Khouzam
- */
-public interface LttngViewerCommands {
-
-    /** Maximum path name length */
-    static final int LTTNG_VIEWER_PATH_MAX = 4096;
-    /** Maximum name length */
-    static final int LTTNG_VIEWER_NAME_MAX = 255;
-    /** Maximum host name length */
-    static final int LTTNG_VIEWER_HOST_NAME_MAX = 64;
-    /** New stream in the trace */
-    static final int NEW_STREAM = (1 << 1);
-    /** New metadata in the trace */
-    static final int NEW_METADATA = (1 << 0);
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/MetadataPacketResponse.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/MetadataPacketResponse.java
deleted file mode 100644 (file)
index 528593c..0000000
+++ /dev/null
@@ -1,78 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014 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:
- *   Matthew Khouzam - Initial implementation and API
- *   Marc-Andre Laperle - Initial implementation and API
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
-
-import java.io.DataInputStream;
-import java.io.IOException;
-import java.nio.ByteBuffer;
-import java.nio.ByteOrder;
-
-/**
- * Metadata packet response containing a packet of metadata
- *
- * @author Matthew Khouzam
- */
-public class MetadataPacketResponse implements IRelayResponse {
-
-    /**
-     * Response size
-     *
-     * fData.length + fStatus
-     */
-    private static final int SIZE = (Long.SIZE + Integer.SIZE) / 8;
-    /** status of the metadata request */
-    private final GetMetadataReturnCode fStatus;
-    /** the packet */
-    private final byte fData[];
-
-    /**
-     * Read new metadata packet from the network
-     *
-     * @param inNet
-     *            network input reader
-     * @throws IOException
-     *             network error
-     */
-    public MetadataPacketResponse(DataInputStream inNet) throws IOException {
-        byte[] data = new byte[SIZE];
-        inNet.readFully(data);
-        ByteBuffer bb = ByteBuffer.wrap(data);
-        bb.order(ByteOrder.BIG_ENDIAN);
-        long length = bb.getLong();
-        fStatus = GetMetadataReturnCode.values()[bb.getInt() - 1];
-        if (length >= Integer.MAX_VALUE) {
-            throw new IOException("Metadata Packet too big " + length); //$NON-NLS-1$
-        }
-        fData = new byte[(int) length];
-        inNet.readFully(fData);
-    }
-
-    /**
-     * Get the packet
-     *
-     * @return the packet
-     */
-    public byte[] getData() {
-        return fData;
-    }
-
-    /**
-     * Gets the status
-     *
-     * @return the status
-     */
-    public GetMetadataReturnCode getStatus() {
-        return fStatus;
-    }
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/NewStreamsRequest.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/NewStreamsRequest.java
deleted file mode 100644 (file)
index edb2c68..0000000
+++ /dev/null
@@ -1,52 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014 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:
- *   Matthew Khouzam - Initial implementation and API
- *   Marc-Andre Laperle - Initial implementation and API
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
-
-import java.nio.ByteBuffer;
-import java.nio.ByteOrder;
-
-/**
- * LTTNG_VIEWER_GET_NEW_STREAMS payload.
- *
- * @author Matthew Khouzam
- */
-public class NewStreamsRequest implements IRelayCommand {
-
-    /**
-     * Command size (fSessionId)
-     */
-    public static final int SIZE = Long.SIZE / 8;
-
-    /** session ID */
-    private final long fSessionId;
-
-    /**
-     * Constructor
-     *
-     * @param sessionId
-     *            the session id we want
-     */
-    public NewStreamsRequest(long sessionId) {
-        fSessionId = sessionId;
-    }
-
-    @Override
-    public byte[] serialize() {
-        byte data[] = new byte[SIZE];
-        ByteBuffer bb = ByteBuffer.wrap(data);
-        bb.order(ByteOrder.BIG_ENDIAN);
-        bb.putLong(fSessionId);
-        return data;
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/NewStreamsResponse.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/NewStreamsResponse.java
deleted file mode 100644 (file)
index b02ef88..0000000
+++ /dev/null
@@ -1,95 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014 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:
- *   Matthew Khouzam - Initial implementation and API
- *   Marc-Andre Laperle - Initial implementation and API
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
-
-import java.io.DataInputStream;
-import java.io.IOException;
-import java.nio.ByteBuffer;
-import java.nio.ByteOrder;
-import java.util.List;
-
-import com.google.common.collect.ImmutableList;
-
-/**
- * Response to a "new streams" command
- *
- * @author Matthew Khouzam
- */
-public class NewStreamsResponse implements IRelayResponse {
-
-    /**
-     * Response size
-     *
-     * fStatus + fNbStreams
-     */
-    private static final int SIZE = (Integer.SIZE + Integer.SIZE) / 8;
-    /** status of the request */
-    private final NewStreamsReturnCode fStatus;
-    /** the number of streams */
-    private final int fNbStreams;
-    /** the list of streams in the response */
-    private final List<StreamResponse> fStreamList;
-
-    /**
-     * New stream response network constructor
-     *
-     * @param inNet
-     *            network stream
-     * @throws IOException
-     *             network error
-     */
-    public NewStreamsResponse(DataInputStream inNet) throws IOException {
-        byte[] data = new byte[SIZE];
-        inNet.readFully(data);
-        ByteBuffer bb = ByteBuffer.wrap(data);
-        bb.order(ByteOrder.BIG_ENDIAN);
-        fStatus = NewStreamsReturnCode.values()[bb.getInt() - 1];
-        fNbStreams = bb.getInt();
-        ImmutableList.Builder<StreamResponse> sl = new ImmutableList.Builder<>();
-        if (getStatus().equals(NewStreamsReturnCode.LTTNG_VIEWER_NEW_STREAMS_OK)) {
-            for (int stream = 0; stream < fNbStreams; stream++) {
-                sl.add(new StreamResponse(inNet));
-            }
-        }
-        fStreamList = sl.build();
-    }
-
-    /**
-     * Gets the status
-     *
-     * @return the status
-     */
-    public NewStreamsReturnCode getStatus() {
-        return fStatus;
-    }
-
-    /**
-     * gets the stream list
-     *
-     * @return the stream list
-     */
-    public List<StreamResponse> getStreamList() {
-        return fStreamList;
-    }
-
-    /**
-     * The number of streams
-     *
-     * @return the number of streams
-     */
-    public int getNbStreams() {
-        return fNbStreams;
-    }
-
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/NewStreamsReturnCode.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/NewStreamsReturnCode.java
deleted file mode 100644 (file)
index aa324f7..0000000
+++ /dev/null
@@ -1,42 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014 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:
- *   Matthew Khouzam - Initial implementation and API
- *   Marc-Andre Laperle - Initial implementation and API
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
-
-/**
- * Return codes for "new streams" command
- *
- * @author Matthew Khouzam
- */
-public enum NewStreamsReturnCode implements IBaseCommand {
-
-    /** If new streams are being sent. */
-    LTTNG_VIEWER_NEW_STREAMS_OK(1),
-    /** If no new streams are available. */
-    LTTNG_VIEWER_NEW_STREAMS_NO_NEW(2),
-    /** Error. */
-    LTTNG_VIEWER_NEW_STREAMS_ERR(3),
-    /** Session closed. */
-    LTTNG_VIEWER_NEW_STREAMS_HUP(4);
-
-    private final int fCode;
-
-    private NewStreamsReturnCode(int c) {
-        fCode = c;
-    }
-
-    @Override
-    public int getCommand() {
-        return fCode;
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/NextIndexReturnCode.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/NextIndexReturnCode.java
deleted file mode 100644 (file)
index 3c5c32a..0000000
+++ /dev/null
@@ -1,46 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014 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:
- *   Matthew Khouzam - Initial implementation and API
- *   Marc-Andre Laperle - Initial implementation and API
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
-
-/**
- * Get next index return code (hope it's viewer_index_ok)
- *
- * @author Matthew Khouzam
- */
-public enum NextIndexReturnCode implements IBaseCommand {
-
-    /** Index is available. */
-    VIEWER_INDEX_OK(1),
-    /** Index not yet available. */
-    VIEWER_INDEX_RETRY(2),
-    /** Index closed (trace destroyed). */
-    VIEWER_INDEX_HUP(3),
-    /** Unknown error. */
-    VIEWER_INDEX_ERR(4),
-    /** Inactive stream beacon. */
-    VIEWER_INDEX_INACTIVE(5),
-    /** End of index file. */
-    VIEWER_INDEX_EOF(6);
-
-    private final int fCode;
-
-    private NextIndexReturnCode(int c) {
-        fCode = c;
-    }
-
-    @Override
-    public int getCommand() {
-        return fCode;
-    }
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/SeekCommand.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/SeekCommand.java
deleted file mode 100644 (file)
index e187830..0000000
+++ /dev/null
@@ -1,43 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014 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:
- *   Matthew Khouzam - Initial implementation and API
- *   Marc-Andre Laperle - Initial implementation and API
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
-
-/**
- * Seek command
- *
- * @author Matthew Khouzam
- */
-public enum SeekCommand implements IBaseCommand {
-
-    /** Receive the trace packets from the beginning. */
-    VIEWER_SEEK_BEGINNING(1),
-    /** Receive the trace packets from now. */
-    VIEWER_SEEK_LAST(2);
-
-    private final int fCode;
-
-    /**
-     * Command size (fCode)
-     */
-    public static final int SIZE = Integer.SIZE / 8;
-
-    private SeekCommand(int c) {
-        fCode = c;
-    }
-
-    @Override
-    public int getCommand() {
-        return fCode;
-    }
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/SessionResponse.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/SessionResponse.java
deleted file mode 100644 (file)
index 7253ecb..0000000
+++ /dev/null
@@ -1,127 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014 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:
- *   Matthew Khouzam - Initial implementation and API
- *   Marc-Andre Laperle - Initial implementation and API
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
-
-import java.io.DataInputStream;
-import java.io.IOException;
-import java.nio.ByteBuffer;
-import java.nio.ByteOrder;
-
-/**
- * Get viewer session response to command
- *
- * @author Matthew Khouzam
- */
-public class SessionResponse implements IRelayResponse {
-
-    /**
-     * Response size
-     *
-     * fHostname + fSessionName + fId + fLiveTimer + fClients + fStreams
-     */
-    public static final int SIZE =
-            LttngViewerCommands.LTTNG_VIEWER_HOST_NAME_MAX + LttngViewerCommands.LTTNG_VIEWER_NAME_MAX + (Long.SIZE + Integer.SIZE + Integer.SIZE + Integer.SIZE) / 8;
-    /** id of the session */
-    private final long fId;
-    /** live timer */
-    private final int fLiveTimer;
-    /** number of clients */
-    private final int fClients;
-    /** number streams */
-    private final int fStreams;
-    /** Hostname, like 'localhost' */
-    private final String fHostname;
-    /** Session name, like 'streaming session' */
-    private final String fSessionName;
-
-    /**
-     * Session response network constructor
-     *
-     * @param inNet
-     *            input network stream
-     * @throws IOException
-     *             network error
-     */
-    public SessionResponse(DataInputStream inNet) throws IOException {
-        byte[] data = new byte[SIZE];
-        inNet.readFully(data);
-        ByteBuffer bb = ByteBuffer.wrap(data);
-        bb.order(ByteOrder.BIG_ENDIAN);
-        fId = bb.getLong();
-        fLiveTimer = bb.getInt();
-        fClients = bb.getInt();
-        fStreams = bb.getInt();
-        byte[] hostName = new byte[LttngViewerCommands.LTTNG_VIEWER_HOST_NAME_MAX];
-        byte[] sessionName = new byte[LttngViewerCommands.LTTNG_VIEWER_NAME_MAX];
-        bb.get(hostName, 0, hostName.length);
-        bb.get(sessionName, 0, sessionName.length);
-        fHostname = new String(hostName);
-        fSessionName = new String(sessionName);
-    }
-
-    /**
-     * Gets the id of the session
-     *
-     * @return the id of the session
-     */
-    public long getId() {
-        return fId;
-    }
-
-    /**
-     * Gets the live timer
-     *
-     * @return the live timer
-     */
-    public int getLiveTimer() {
-        return fLiveTimer;
-    }
-
-    /**
-     * Gets the number of clients
-     *
-     * @return the number of clients
-     */
-    public int getClients() {
-        return fClients;
-    }
-
-    /**
-     * Gets the number streams
-     *
-     * @return the number streams
-     */
-    public int getStreams() {
-        return fStreams;
-    }
-
-    /**
-     * Gets the Hostname
-     *
-     * @return the Hostname
-     */
-    public String getHostname() {
-        return fHostname;
-    }
-
-    /**
-     * Gets the session name
-     *
-     * @return the session name
-     */
-    public String getSessionName() {
-        return fSessionName;
-    }
-
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/StreamResponse.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/StreamResponse.java
deleted file mode 100644 (file)
index 89d2c34..0000000
+++ /dev/null
@@ -1,126 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014 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:
- *   Matthew Khouzam - Initial implementation and API
- *   Marc-Andre Laperle - Initial implementation and API
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
-
-import java.io.DataInputStream;
-import java.io.IOException;
-import java.nio.ByteBuffer;
-import java.nio.ByteOrder;
-
-/**
- * Get response of viewer stream
- *
- * @author Matthew Khouzam
- */
-public class StreamResponse implements IRelayResponse {
-
-    /**
-     * Response size
-     *
-     * fId + fCtfTraceId + fMetadataFlag + fPathName + fChannelName
-     */
-    public static final int SIZE = (Long.SIZE + Long.SIZE + Integer.SIZE) / 8 + LttngViewerCommands.LTTNG_VIEWER_PATH_MAX + LttngViewerCommands.LTTNG_VIEWER_NAME_MAX;
-
-    /**
-     * id of the stream
-     */
-    private final long fId;
-    /**
-     * It is guaranteed to be unique, because the value is assigned sequentially
-     * by the relay.
-     */
-    private final long fCtfTraceId;
-    /**
-     * if the stream is a metadata stream
-     */
-    private final int fMetadataFlag;
-    /**
-     * the path
-     */
-    private final String fPathName;
-    /**
-     * The channel, traditionally channel0
-     */
-    private final String fChannelName;
-
-    /**
-     * Stream response
-     *
-     * @param inNet
-     *            input data stream
-     * @throws IOException
-     *             network time
-     */
-    public StreamResponse(DataInputStream inNet) throws IOException {
-        byte[] streamData = new byte[SIZE];
-        inNet.readFully(streamData, 0, SIZE);
-        ByteBuffer bb = ByteBuffer.wrap(streamData);
-        bb.order(ByteOrder.BIG_ENDIAN);
-        fId = (bb.getLong());
-        fCtfTraceId = bb.getLong();
-        fMetadataFlag = bb.getInt();
-        byte pathName[] = new byte[LttngViewerCommands.LTTNG_VIEWER_PATH_MAX];
-        byte channelName[] = new byte[LttngViewerCommands.LTTNG_VIEWER_NAME_MAX];
-        bb.get(pathName, 0, LttngViewerCommands.LTTNG_VIEWER_PATH_MAX);
-        bb.get(channelName, 0, LttngViewerCommands.LTTNG_VIEWER_NAME_MAX);
-        fPathName = new String(pathName);
-        fChannelName = new String(channelName);
-    }
-
-    /**
-     * Get the id
-     *
-     * @return the Id
-     */
-    public long getId() {
-        return fId;
-    }
-
-    /**
-     * Get the CtfTraceId
-     *
-     * @return the CtfTraceId
-     */
-    public long getCtfTraceId() {
-        return fCtfTraceId;
-    }
-
-    /**
-     * Get the metadata flag
-     *
-     * @return the MetadataFlag
-     */
-    public int getMetadataFlag() {
-        return fMetadataFlag;
-    }
-
-    /**
-     * Get the path name
-     *
-     * @return the PathName
-     */
-    public String getPathName() {
-        return fPathName;
-    }
-
-    /**
-     * get the Channel name
-     *
-     * @return the ChannelName
-     */
-    public String getChannelName() {
-        return fChannelName;
-    }
-
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/TracePacketResponse.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/TracePacketResponse.java
deleted file mode 100644 (file)
index 11fa823..0000000
+++ /dev/null
@@ -1,92 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014 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:
- *   Matthew Khouzam - Initial implementation and API
- *   Marc-Andre Laperle - Initial implementation and API
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
-
-import java.io.DataInputStream;
-import java.io.IOException;
-import java.nio.ByteBuffer;
-import java.nio.ByteOrder;
-
-/**
- * Response to getpacket command
- *
- * @author Matthew Khouzam
- */
-public class TracePacketResponse implements IRelayResponse {
-
-    /**
-     * Command size
-     *
-     * fStatus + fData.length + fFlags
-     */
-    private static final int SIZE = (Integer.SIZE + Integer.SIZE + Integer.SIZE) / 8;
-    /** Enum lttng_viewer_get_packet_return_code */
-    private final GetPacketReturnCode fStatus;
-    /** flags: is there new metadata or new streams? */
-    private final int fFlags;
-    /** the packet */
-    private final byte[] fData;
-
-    /**
-     * Trace packet response network constructor
-     *
-     * @param inNet
-     *            network input stream
-     * @throws IOException
-     *             network error
-     */
-    public TracePacketResponse(DataInputStream inNet) throws IOException {
-        byte[] data = new byte[SIZE];
-        inNet.readFully(data);
-        ByteBuffer bb = ByteBuffer.wrap(data);
-        bb.order(ByteOrder.BIG_ENDIAN);
-        fStatus = GetPacketReturnCode.values()[bb.getInt() - 1];
-        int length = bb.getInt();
-        fFlags = bb.getInt();
-        if (fStatus.equals(GetPacketReturnCode.VIEWER_GET_PACKET_OK)) {
-            fData = new byte[length];
-            inNet.readFully(fData);
-        } else {
-            fData = new byte[0];
-        }
-    }
-
-    /**
-     * Get the status
-     *
-     * @return the Status
-     */
-    public GetPacketReturnCode getStatus() {
-        return fStatus;
-    }
-
-    /**
-     * Get the flags
-     *
-     * @return the Flags
-     */
-    public int getFlags() {
-        return fFlags;
-    }
-
-    /**
-     * Get the packet data, please do not modify the data
-     *
-     * @return the Data
-     */
-    public byte[] getData() {
-        return fData;
-    }
-
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/ViewerCommand.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/commands/ViewerCommand.java
deleted file mode 100644 (file)
index 06e6b16..0000000
+++ /dev/null
@@ -1,95 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014 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:
- *   Matthew Khouzam - Initial implementation and API
- *   Marc-Andre Laperle - Initial implementation and API
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands;
-
-import java.nio.ByteBuffer;
-import java.nio.ByteOrder;
-
-/**
- * The LTTng command
- *
- * @author Matthew Khouzam
- */
-public class ViewerCommand implements IRelayCommand {
-
-    /**
-     * Command size
-     *
-     * fDataSize + fCmdVersion + fCmd
-     */
-    public static final int SIZE = (Long.SIZE + Integer.SIZE) / 8 + Command.SIZE;
-    /**
-     * data size following this header, you normally attach a payload that one,
-     * in bytes
-     */
-    private final long fDataSize;
-    /** enum lttcomm_relayd_command */
-    private final Command fCmd;
-    /** command version */
-    private final int fCmdVersion;
-
-    /**
-     * Sets the packet command
-     *
-     * @param viewerConnect
-     *            the command
-     * @param size size of the command
-     * @param version the version number
-     */
-    public ViewerCommand(Command viewerConnect, long size, int version) {
-        fCmd = viewerConnect;
-        fDataSize = size;
-        fCmdVersion = version;
-    }
-
-    /**
-     * Get the data size
-     *
-     * @return the DataSize
-     */
-    public long getDataSize() {
-        return fDataSize;
-    }
-
-    /**
-     * Get the command
-     *
-     * @return the Cmd
-     */
-    public Command getCmd() {
-        return fCmd;
-    }
-
-    /**
-     * Get the command version
-     *
-     * @return the CmdVersion
-     */
-    public int getCmdVersion() {
-        return fCmdVersion;
-    }
-
-    @Override
-    public byte[] serialize() {
-        byte data[] = new byte[SIZE];
-        ByteBuffer bb = ByteBuffer.wrap(data);
-        bb.order(ByteOrder.BIG_ENDIAN);
-        bb.putLong(getDataSize());
-        bb.putInt(getCmd().getCommand());
-        bb.putInt(fCmdVersion);
-        return data;
-    }
-
-
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/impl/LttngRelaydConnector_2_4.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/impl/LttngRelaydConnector_2_4.java
deleted file mode 100644 (file)
index 288d914..0000000
+++ /dev/null
@@ -1,181 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014 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:
- *   Matthew Khouzam - Initial implementation
- *   Marc-Andre Laperle - Create session and split getNextIndex from getNextPacket
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.impl;
-
-import java.io.DataInputStream;
-import java.io.DataOutputStream;
-import java.io.IOException;
-import java.util.List;
-
-import org.eclipse.jdt.annotation.NonNull;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.ILttngRelaydConnector;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.AttachSessionRequest;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.AttachSessionResponse;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.Command;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.ConnectResponse;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.CreateSessionResponse;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.GetMetadata;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.GetNextIndex;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.GetPacket;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.IndexResponse;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.ListSessionsResponse;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.MetadataPacketResponse;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.NewStreamsResponse;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.NextIndexReturnCode;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.SeekCommand;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.SessionResponse;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.StreamResponse;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.TracePacketResponse;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.ViewerCommand;
-
-/**
- * Lttng 2.4 implementation
- *
- * @author Matthew Khouzam
- */
-public class LttngRelaydConnector_2_4 implements ILttngRelaydConnector {
-
-    private final @NonNull DataInputStream fInNet;
-    private final @NonNull DataOutputStream fOutNet;
-
-    /**
-     * Constructor needs two network streams
-     *
-     * @param inNet
-     *            network incoming data
-     * @param outNet
-     *            network outgoing data
-     */
-    public LttngRelaydConnector_2_4(@NonNull DataInputStream inNet, @NonNull DataOutputStream outNet) {
-        fInNet = inNet;
-        fOutNet = outNet;
-    }
-
-    // ------------------------------------------------------------------------
-    // AutoCloseable
-    // ------------------------------------------------------------------------
-
-    @Override
-    public void close() throws IOException {
-        fInNet.close();
-        fOutNet.close();
-    }
-
-    // ------------------------------------------------------------------------
-    // ILttngRelaydConnector
-    // ------------------------------------------------------------------------
-
-    @Override
-    public List<SessionResponse> getSessions() throws IOException {
-        ViewerCommand listSessionsCmd = new ViewerCommand(Command.VIEWER_LIST_SESSIONS, 0,0);
-
-        fOutNet.write(listSessionsCmd.serialize());
-        fOutNet.flush();
-
-        return new ListSessionsResponse(fInNet).getSessionsList();
-    }
-
-    @Override
-    public CreateSessionResponse createSession() throws IOException {
-        ViewerCommand listSessionsCmd = new ViewerCommand(Command.VIEWER_CREATE_SESSION, 0, 0);
-        fOutNet.write(listSessionsCmd.serialize());
-        fOutNet.flush();
-
-        return new CreateSessionResponse(fInNet);
-    }
-
-    @Override
-    public AttachSessionResponse attachToSession(SessionResponse lttngViewerSession) throws IOException {
-        ViewerCommand listSessionsCmd = new ViewerCommand(Command.VIEWER_ATTACH_SESSION, 0,0);
-        fOutNet.write(listSessionsCmd.serialize());
-        /*
-         * only flush if you read after
-         */
-
-        AttachSessionRequest attachRequest = new AttachSessionRequest(lttngViewerSession.getId(), SeekCommand.VIEWER_SEEK_LAST);
-        fOutNet.write(attachRequest.serialize());
-        fOutNet.flush();
-
-        return new AttachSessionResponse(fInNet);
-    }
-
-    @Override
-    public String getMetadata(AttachSessionResponse attachedSession) throws IOException {
-
-        for (StreamResponse stream : attachedSession.getStreamList()) {
-            if (stream.getMetadataFlag() == 1) {
-                issueCommand(Command.VIEWER_GET_METADATA);
-
-                GetMetadata metadataRequest = new GetMetadata(stream.getId());
-                fOutNet.write(metadataRequest.serialize());
-                fOutNet.flush();
-
-                MetadataPacketResponse metaDataPacket = new MetadataPacketResponse(fInNet);
-                return new String(metaDataPacket.getData());
-            }
-        }
-
-        return null;
-    }
-
-    @Override
-    public TracePacketResponse getPacketFromStream(IndexResponse index, long id) throws IOException {
-
-        issueCommand(Command.VIEWER_GET_PACKET);
-
-        GetPacket packetRequest = new GetPacket(id, index.getOffset(), (int) (index.getPacketSize() / 8));
-        fOutNet.write(packetRequest.serialize());
-        fOutNet.flush();
-
-        return new TracePacketResponse(fInNet);
-    }
-
-    @Override
-    public TracePacketResponse getNextPacket(StreamResponse stream) throws IOException {
-        IndexResponse indexReply = getNextIndex(stream);
-
-        TracePacketResponse packet = null;
-        if (indexReply.getStatus() == NextIndexReturnCode.VIEWER_INDEX_OK) {
-            packet = getPacketFromStream(indexReply, stream.getId());
-        }
-        return packet;
-    }
-
-    @Override
-    public IndexResponse getNextIndex(StreamResponse stream) throws IOException {
-        issueCommand(Command.VIEWER_GET_NEXT_INDEX);
-
-        GetNextIndex indexRequest = new GetNextIndex(stream.getId());
-        fOutNet.write(indexRequest.serialize());
-        fOutNet.flush();
-
-        return new IndexResponse(fInNet);
-    }
-
-    @Override
-    public List<StreamResponse> getNewStreams() throws IOException {
-
-        Command viewerGetNewStreams = Command.VIEWER_GET_NEW_STREAMS;
-
-        issueCommand(viewerGetNewStreams);
-
-        return new NewStreamsResponse(fInNet).getStreamList();
-    }
-
-    private void issueCommand(Command command) throws IOException {
-        ViewerCommand connectCommand = new ViewerCommand(command, ConnectResponse.SIZE, 0);
-        fOutNet.write(connectCommand.serialize());
-        fOutNet.flush();
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/impl/LttngRelaydConnector_Unsupported.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/internal/lttng2/control/core/relayd/impl/LttngRelaydConnector_Unsupported.java
deleted file mode 100644 (file)
index 1635445..0000000
+++ /dev/null
@@ -1,76 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014 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:
- *   Matthew Khouzam - Initial implementation
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.core.relayd.impl;
-
-import java.util.List;
-
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.ILttngRelaydConnector;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.AttachSessionResponse;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.CreateSessionResponse;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.IndexResponse;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.SessionResponse;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.StreamResponse;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.TracePacketResponse;
-
-/**
- * Unsupported version of the relay daemon
- *
- * @author Matthew Khouzam
- */
-public class LttngRelaydConnector_Unsupported implements ILttngRelaydConnector {
-
-    @Override
-    public List<SessionResponse> getSessions() {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    public AttachSessionResponse attachToSession(SessionResponse lttngViewerSession) {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    public String getMetadata(AttachSessionResponse attachedSession) {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    public TracePacketResponse getNextPacket(StreamResponse stream) {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    public TracePacketResponse getPacketFromStream(IndexResponse index, long id) {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    public List<StreamResponse> getNewStreams() {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    public CreateSessionResponse createSession() {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    public IndexResponse getNextIndex(StreamResponse stream) {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    public void close() {
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/lttng2/control/core/session/Messages.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/lttng2/control/core/session/Messages.java
deleted file mode 100644 (file)
index 8eaace4..0000000
+++ /dev/null
@@ -1,45 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2014 École Polytechnique de Montréal
- *
- * 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:
- *   Guilliano Molaire - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.control.core.session;
-
-import org.eclipse.osgi.util.NLS;
-
-/**
- * Externalized message strings from the lttng2.core.control.session
- *
- * @author Guilliano Molaire
- */
-@SuppressWarnings("javadoc")
-public class Messages extends NLS {
-    private static final String BUNDLE_NAME = "org.eclipse.tracecompass.lttng2.control.core.session.messages"; //$NON-NLS-1$
-
-    public static String SessionConfigXML_BadRequirementType;
-    public static String SessionConfigXML_DomainTypeMissing;
-    public static String SessionConfigXML_EventTypeMissing;
-    public static String SessionConfigXML_InvalidSessionInfoList;
-    public static String SessionConfigXML_InvalidTraceSessionPath;
-    public static String SessionConfigXML_UnknownEventType;
-    public static String SessionConfigXML_UnknownDomainBufferType;
-    public static String SessionConfigXML_SessionConfigGenerationError;
-    public static String SessionConfigXML_XmlParseError;
-    public static String SessionConfigXML_XmlValidateError;
-    public static String SessionConfigXML_XmlValidationError;
-
-    static {
-        // initialize resource bundle
-        NLS.initializeMessages(BUNDLE_NAME, Messages.class);
-    }
-
-    private Messages() {
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/lttng2/control/core/session/SessionConfigGenerator.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/lttng2/control/core/session/SessionConfigGenerator.java
deleted file mode 100644 (file)
index be4479e..0000000
+++ /dev/null
@@ -1,534 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014 École Polytechnique de Montréal
- *
- * 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:
- *   Guilliano Molaire - Initial API and implementation
- *********************************************************************/
-package org.eclipse.tracecompass.lttng2.control.core.session;
-
-import java.io.File;
-import java.io.IOException;
-import java.net.URL;
-import java.util.Set;
-
-import javax.xml.XMLConstants;
-import javax.xml.parsers.DocumentBuilder;
-import javax.xml.parsers.DocumentBuilderFactory;
-import javax.xml.parsers.ParserConfigurationException;
-import javax.xml.transform.OutputKeys;
-import javax.xml.transform.Source;
-import javax.xml.transform.Transformer;
-import javax.xml.transform.TransformerException;
-import javax.xml.transform.TransformerFactory;
-import javax.xml.transform.dom.DOMSource;
-import javax.xml.transform.stream.StreamResult;
-import javax.xml.transform.stream.StreamSource;
-import javax.xml.validation.Schema;
-import javax.xml.validation.SchemaFactory;
-import javax.xml.validation.Validator;
-
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.jdt.annotation.NonNull;
-import org.eclipse.osgi.util.NLS;
-import org.eclipse.tracecompass.internal.lttng2.control.core.Activator;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IChannelInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IDomainInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IEventInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISessionInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEnablement;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEventType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
-import org.w3c.dom.Document;
-import org.w3c.dom.Element;
-import org.xml.sax.SAXException;
-import org.xml.sax.SAXParseException;
-
-/**
- * Class for generating a session configuration file. A session configuration is
- * used to configure a trace session. It is a XML formatted file that contains
- * values defining the behavior of that specific trace session.
- * <p>
- * Kernel session configuration example:
- *
- * <pre>
- * {@code
- * <sessions>
- *     <session>
- *         <name>test_kernel</name>
- *         <domains>
- *             <domain>
- *                 <type>KERNEL</type>
- *                 <buffer_type>GLOBAL</buffer_type>
- *                 <channels>
- *                     <channel>
- *                         <name>channel0</name>
- *                         <enabled>false</enabled>
- *                         <overwrite_mode>DISCARD</overwrite_mode>
- *                         <subbuffer_size>262144</subbuffer_size>
- *                         <subbuffer_count>4</subbuffer_count>
- *                         <switch_timer_interval>0</switch_timer_interval>
- *                         <read_timer_interval>200000</read_timer_interval>
- *                         <output_type>SPLICE</output_type>
- *                         <tracefile_size>0</tracefile_size>
- *                         <tracefile_count>0</tracefile_count>
- *                         <live_timer_interval>0</live_timer_interval>
- *                         <events>
- *                             <event>
- *                                 <enabled>true</enabled>
- *                                 <type>SYSCALL</type>
- *                             </event>
- *                             <event>
- *                                 <name>snd_soc_cache_sync</name>
- *                                 <enabled>true</enabled>
- *                                 <type>TRACEPOINT</type>
- *                             </event>
- *                         </events>
- *                     </channel>
- *                 </channels>
- *             </domain>
- *         </domains>
- *         <started>false</started>
- *         <output>
- *             <consumer_output>
- *                 <enabled>true</enabled>
- *                 <destination>
- *                     <path>/home/user/lttng-traces/test_kernel</path>
- *                 </destination>
- *             </consumer_output>
- *         </output>
- *     </session>
- * </sessions>
- * }
- * </pre>
- *
- * </p>
- *
- * @author Guilliano Molaire
- */
-public final class SessionConfigGenerator {
-
-    /** The name of the session schema */
-    private static final String SESSION_XSD_FILENAME = "session.xsd"; //$NON-NLS-1$
-
-    /** The indent size used for the session configuration XML file */
-    private static final String INDENT_AMOUNT_PROPERTY_NAME = "{http://xml.apache.org/xslt}indent-amount"; //$NON-NLS-1$
-    private static final String INDENT_AMOUNT_PROPERTY_VALUE = "4"; //$NON-NLS-1$
-
-    /**
-     * Private constructor. The class should not be instantiated.
-     */
-    private SessionConfigGenerator() {
-    }
-
-    // ---------------------------------------------------------
-    // Methods to generate session configuration files
-    // ---------------------------------------------------------
-
-    /**
-     * Generates a session configuration file from a set of session information.
-     *
-     * @param sessions
-     *            The session informations
-     * @param sessionFileDestination
-     *            The path of the locally saved session configuration file
-     * @return The status of the session configuration generation
-     */
-    public static IStatus generateSessionConfig(Set<ISessionInfo> sessions, IPath sessionFileDestination) {
-        /* Parameters validation */
-        if (sessions == null || sessions.isEmpty()) {
-            return new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.SessionConfigXML_InvalidSessionInfoList);
-        } else if (sessionFileDestination == null) {
-            return new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.SessionConfigXML_InvalidTraceSessionPath);
-        }
-
-        /* Generate the session configuration file */
-        try {
-            Document sessionConfigDocument = generateSessionConfig(sessions);
-            saveSessionConfig(sessionConfigDocument, sessionFileDestination.toString());
-        } catch (TransformerException | IllegalArgumentException | ParserConfigurationException e) {
-            Activator.getDefault().logError("Error generating the session configuration file: " + sessionFileDestination.toString(), e); //$NON-NLS-1$
-            return new Status(IStatus.ERROR, Activator.PLUGIN_ID, e.getMessage());
-        }
-
-        return Status.OK_STATUS;
-    }
-
-    /**
-     * Generates a session configuration from a set of session informations.
-     *
-     * @param sessions
-     *            The session informations
-     * @return The document with all session configuration nodes
-     * @throws IllegalArgumentException
-     *             On an illegal argument inside sessions
-     * @throws ParserConfigurationException
-     *             On an parser configuration error
-     */
-    private static @NonNull Document generateSessionConfig(Iterable<ISessionInfo> sessions) throws IllegalArgumentException, ParserConfigurationException {
-        DocumentBuilderFactory docFactory = DocumentBuilderFactory.newInstance();
-        DocumentBuilder docBuilder = docFactory.newDocumentBuilder();
-
-        Document document = docBuilder.newDocument();
-
-        Element rootElement = document.createElement(SessionConfigStrings.CONFIG_ELEMENT_SESSIONS);
-        document.appendChild(rootElement);
-
-        for (ISessionInfo session : sessions) {
-            /* All elements under "sessions" elements */
-            Element sessionElement = document.createElement(SessionConfigStrings.CONFIG_ELEMENT_SESSION);
-
-            /* Contents of session element */
-            String enabled = session.getSessionState().equals(TraceSessionState.ACTIVE) ? SessionConfigStrings.CONFIG_STRING_TRUE : SessionConfigStrings.CONFIG_STRING_FALSE;
-
-            addElementContent(document, sessionElement, SessionConfigStrings.CONFIG_ELEMENT_NAME, session.getName());
-            addElementContent(document, sessionElement, SessionConfigStrings.CONFIG_ELEMENT_STARTED, enabled);
-
-            if (session.isSnapshotSession()) {
-                /* If it's a snapshot, we must add an attribute telling it is */
-                Element attributesElement = document.createElement(SessionConfigStrings.CONFIG_ELEMENT_ATTRIBUTES);
-                addElementContent(document, attributesElement, SessionConfigStrings.CONFIG_ELEMENT_SNAPSHOT_MODE, SessionConfigStrings.CONFIG_STRING_TRUE);
-                sessionElement.appendChild(attributesElement);
-            }
-
-            sessionElement.appendChild(getDomainsElement(document, session));
-            sessionElement.appendChild(getOutputElement(document, session));
-            rootElement.appendChild(sessionElement);
-        }
-
-        return document;
-    }
-
-    // ---------------------------------------------------------
-    // Getters for each element of the configuration file
-    // ---------------------------------------------------------
-
-    /**
-     * Gets the 'domains' element after creating it.
-     *
-     * @param document
-     *            The document in which the nodes are being added
-     * @param session
-     *            The session informations
-     * @return The domains element as an XML element
-     */
-    private static Element getDomainsElement(Document document, ISessionInfo session) {
-        Element domainsElement = document.createElement(SessionConfigStrings.CONFIG_ELEMENT_DOMAINS);
-
-        for (IDomainInfo domain : session.getDomains()) {
-            Element domainElement = document.createElement(SessionConfigStrings.CONFIG_ELEMENT_DOMAIN);
-
-            /*
-             * Add everything specific to a domain
-             *
-             * TODO: We suppose here that domain is either kernel or UST. It
-             * will have to change if other domains are supported
-             */
-            String domainType = domain.isKernel() ? SessionConfigStrings.CONFIG_DOMAIN_TYPE_KERNEL : SessionConfigStrings.CONFIG_DOMAIN_TYPE_UST;
-            addElementContent(document, domainElement, SessionConfigStrings.CONFIG_ELEMENT_TYPE, domainType);
-
-            String bufferType = null;
-            switch (domain.getBufferType()) {
-            case BUFFER_PER_UID:
-                bufferType = SessionConfigStrings.CONFIG_BUFFER_TYPE_PER_UID;
-                break;
-            case BUFFER_PER_PID:
-                bufferType = SessionConfigStrings.CONFIG_BUFFER_TYPE_PER_PID;
-                break;
-            case BUFFER_SHARED:
-                bufferType = SessionConfigStrings.CONFIG_BUFFER_TYPE_GLOBAL;
-                break;
-            case BUFFER_TYPE_UNKNOWN:
-            default:
-                throw new IllegalArgumentException(Messages.SessionConfigXML_UnknownDomainBufferType);
-            }
-            addElementContent(document, domainElement, SessionConfigStrings.CONFIG_ELEMENT_DOMAIN_BUFFER_TYPE, bufferType);
-
-            /* Add the channels */
-            domainElement.appendChild(getChannelsElement(document, domain.isKernel(), domain.getChannels()));
-            domainsElement.appendChild(domainElement);
-        }
-
-        return domainsElement;
-    }
-
-    /**
-     * Gets the 'output' element after creating it. If the session is a
-     * snapshot, it will be composed of a snapshot outputs element. Otherwise,
-     * it will contain the consumer output element.
-     *
-     * @param document
-     *            The document in which the nodes are being added
-     * @param session
-     *            The session informations
-     * @return The output element as an XML node
-     */
-    private static Element getOutputElement(Document document, ISessionInfo session) {
-        Element outputElement = document.createElement(SessionConfigStrings.CONFIG_ELEMENT_OUTPUT);
-
-        if (session.isSnapshotSession()) {
-            outputElement.appendChild(getSnapshotOuputsElement(document, session));
-        } else if (session.isStreamedTrace()) {
-            outputElement.appendChild(getNetOutputElement(document, session));
-        } else {
-            outputElement.appendChild(getConsumerOutputElement(document, session));
-        }
-
-        return outputElement;
-    }
-
-    /**
-     * Gets the 'channels' element after creating it.
-     *
-     * @param document
-     *            The document in which the nodes are being added
-     * @param isKernel
-     *            Is it a kernel domain type
-     * @param channels
-     *            The channels to be added as elements
-     * @return The channels element as an XML element
-     */
-    private static Element getChannelsElement(Document document, boolean isKernel, IChannelInfo[] channels) {
-        Element channelsElement = document.createElement(SessionConfigStrings.CONFIG_ELEMENT_CHANNELS);
-
-        for (IChannelInfo channel : channels) {
-            Element channelElement = document.createElement(SessionConfigStrings.CONFIG_ELEMENT_CHANNEL);
-
-            /* Add everything related to a channel */
-            addElementContent(document, channelElement, SessionConfigStrings.CONFIG_ELEMENT_NAME, channel.getName());
-
-            String overwriteMode = channel.isOverwriteMode() ? SessionConfigStrings.CONFIG_OVERWRITE_MODE_OVERWRITE : SessionConfigStrings.CONFIG_OVERWRITE_MODE_DISCARD;
-            String enabled = channel.getState().equals(TraceEnablement.ENABLED) ? SessionConfigStrings.CONFIG_STRING_TRUE : SessionConfigStrings.CONFIG_STRING_FALSE;
-
-            addElementContent(document, channelElement, SessionConfigStrings.CONFIG_ELEMENT_ENABLED, enabled);
-            addElementContent(document, channelElement, SessionConfigStrings.CONFIG_ELEMENT_OVERWRITE_MODE, overwriteMode);
-            addElementContent(document, channelElement, SessionConfigStrings.CONFIG_ELEMENT_SUBBUFFER_SIZE, channel.getSubBufferSize());
-            addElementContent(document, channelElement, SessionConfigStrings.CONFIG_ELEMENT_SUBBUFFER_COUNT, channel.getNumberOfSubBuffers());
-            addElementContent(document, channelElement, SessionConfigStrings.CONFIG_ELEMENT_SWITCH_TIMER_INTERVAL, channel.getSwitchTimer());
-            addElementContent(document, channelElement, SessionConfigStrings.CONFIG_ELEMENT_READ_TIMER_INTERVAL, channel.getReadTimer());
-
-            String outputType = channel.getOutputType().getInName().startsWith(SessionConfigStrings.CONFIG_OUTPUT_TYPE_MMAP) ?
-                    outputType = SessionConfigStrings.CONFIG_OUTPUT_TYPE_MMAP : SessionConfigStrings.CONFIG_OUTPUT_TYPE_SPLICE;
-            addElementContent(document, channelElement, SessionConfigStrings.CONFIG_ELEMENT_OUTPUT_TYPE, outputType);
-            addElementContent(document, channelElement, SessionConfigStrings.CONFIG_ELEMENT_TRACEFILE_SIZE, channel.getMaxSizeTraceFiles());
-            addElementContent(document, channelElement, SessionConfigStrings.CONFIG_ELEMENT_TRACEFILE_COUNT, channel.getMaxNumberTraceFiles());
-
-            /*
-             * TODO: Replace the 0 value by the channel live timer property from
-             * SessionInfo once live session tracing is supported
-             */
-            addElementContent(document, channelElement, SessionConfigStrings.CONFIG_ELEMENT_LIVE_TIMER_INTERVAL, SessionConfigStrings.CONFIG_STRING_ZERO);
-
-            /* Add the events */
-            channelElement.appendChild(getEventsElement(document, isKernel, channel.getEvents()));
-            channelsElement.appendChild(channelElement);
-        }
-
-        return channelsElement;
-    }
-
-    /**
-     * Gets the 'events' element after creating it. It is composed of the event
-     * informations from a list of IEventInfo.
-     *
-     * @param document
-     *            The document in which the nodes are being added
-     * @param isKernel
-     *            Is the domain type kernel
-     * @param events
-     *            The event informations to be added
-     * @return An element containing all the event informations as XML elements
-     */
-    private static Element getEventsElement(Document document, boolean isKernel, IEventInfo[] events) {
-        Element eventsElement = document.createElement(SessionConfigStrings.CONFIG_ELEMENT_EVENTS);
-
-        for (IEventInfo event : events) {
-            Element eventElement = document.createElement(SessionConfigStrings.CONFIG_ELEMENT_EVENT);
-
-            /* Enabled attribute */
-            String enabled = event.getState().equals(TraceEnablement.ENABLED) ? SessionConfigStrings.CONFIG_STRING_TRUE : SessionConfigStrings.CONFIG_STRING_FALSE;
-
-            /* Add the attributes to the event node */
-            addElementContent(document, eventElement, SessionConfigStrings.CONFIG_ELEMENT_NAME, event.getName());
-            addElementContent(document, eventElement, SessionConfigStrings.CONFIG_ELEMENT_ENABLED, enabled);
-            TraceEventType eventType = event.getEventType();
-            if (!eventType.equals(TraceEventType.UNKNOWN)) {
-                addElementContent(document, eventElement, SessionConfigStrings.CONFIG_ELEMENT_TYPE, eventType.getInName().toUpperCase());
-            } else {
-                throw new IllegalArgumentException(Messages.SessionConfigXML_UnknownEventType);
-            }
-
-            /* Specific to UST session config: the log level */
-            if (!isKernel && !event.getLogLevel().equals(TraceLogLevel.LEVEL_UNKNOWN)) {
-                addElementContent(document, eventElement, SessionConfigStrings.CONFIG_ELEMENT_LOGLEVEL, event.getLogLevel().ordinal());
-            }
-
-            /* Add the node to the parent node events */
-            eventsElement.appendChild(eventElement);
-        }
-
-        return eventsElement;
-    }
-
-    /**
-     * Gets the 'consumer_output' element after creating it.
-     *
-     * @param document
-     *            The document in which the nodes are being added
-     * @param session
-     *            The session informations
-     * @return The consumer output element with his informations as XML elements
-     */
-    private static Element getConsumerOutputElement(Document document, ISessionInfo session) {
-        Element consumerOutputElement = document.createElement(SessionConfigStrings.CONFIG_ELEMENT_CONSUMER_OUTPUT);
-        Element destinationElement = document.createElement(SessionConfigStrings.CONFIG_ELEMENT_DESTINATION);
-
-        /* Value of consumer output element */
-        addElementContent(document, consumerOutputElement, SessionConfigStrings.CONFIG_ELEMENT_ENABLED, SessionConfigStrings.CONFIG_STRING_TRUE);
-
-        if (session.isStreamedTrace()) {
-            /* If it is a streamed session, add the net output element */
-            destinationElement.appendChild(getNetOutputElement(document, session));
-        } else {
-            addElementContent(document, destinationElement, SessionConfigStrings.CONFIG_ELEMENT_PATH, session.getSessionPath());
-        }
-
-        consumerOutputElement.appendChild(destinationElement);
-        return consumerOutputElement;
-    }
-
-    /**
-     * Gets the 'net_output' element after creating it. It is composed of the
-     * control and data URIs.
-     *
-     * @param document
-     *            The document in which the nodes are being added
-     * @param session
-     *            The session informations
-     * @return The net output element
-     */
-    private static Element getNetOutputElement(Document document, ISessionInfo session) {
-        Element netOutputElement = document.createElement(SessionConfigStrings.CONFIG_ELEMENT_NET_OUTPUT);
-
-        String networkUrl = session.getNetworkUrl();
-        String controlUri = networkUrl == null ? session.getControlUrl() : networkUrl;
-        String dataUri = networkUrl == null ? session.getDataUrl() : networkUrl;
-        addElementContent(document, netOutputElement, SessionConfigStrings.CONFIG_ELEMENT_CONTROL_URI, controlUri);
-        addElementContent(document, netOutputElement, SessionConfigStrings.CONFIG_ELEMENT_DATA_URI, dataUri);
-
-        return netOutputElement;
-    }
-
-    /**
-     * Gets the 'snapshot_outputs' element after creating it.
-     *
-     * @param document
-     *            The document in which the nodes are being added
-     * @param session
-     *            The session informations
-     * @return The snapshot outputs element with snapshot informations as XML
-     *         elements
-     */
-    private static Element getSnapshotOuputsElement(Document document, ISessionInfo session) {
-        Element snapshotOutputsElement = document.createElement(SessionConfigStrings.CONFIG_ELEMENT_SNAPSHOT_OUTPUTS);
-        Element outputElement = document.createElement(SessionConfigStrings.CONFIG_ELEMENT_OUTPUT);
-
-        /* Add the name of the snapshot and the max size element */
-        addElementContent(document, outputElement, SessionConfigStrings.CONFIG_ELEMENT_NAME, session.getSnapshotInfo().getName());
-
-        /*
-         * TODO: find the proper max size value of output element. For now it is
-         * set to the default 0 value which means unlimited for lttng.
-         */
-        addElementContent(document, outputElement, SessionConfigStrings.CONFIG_ELEMENT_MAX_SIZE, SessionConfigStrings.CONFIG_STRING_ZERO);
-        outputElement.appendChild(getConsumerOutputElement(document, session));
-
-        snapshotOutputsElement.appendChild(outputElement);
-        return snapshotOutputsElement;
-    }
-
-    // ---------------------------------------------------------
-    // Utilities
-    // ---------------------------------------------------------
-
-    /**
-     * Validates the session configuration file against its schema.
-     *
-     * @param sessionFile
-     *            The session configuration file
-     * @return The status of the validation
-     */
-    public static IStatus sessionValidate(File sessionFile) {
-        URL url = SessionConfigGenerator.class.getResource(SESSION_XSD_FILENAME);
-        SchemaFactory schemaFactory = SchemaFactory.newInstance(XMLConstants.W3C_XML_SCHEMA_NS_URI);
-        Source xmlSource = new StreamSource(sessionFile);
-
-        try {
-            Schema schema = schemaFactory.newSchema(url);
-            Validator validator = schema.newValidator();
-            validator.validate(xmlSource);
-        } catch (SAXParseException e) {
-            String error = NLS.bind(Messages.SessionConfigXML_XmlParseError, e.getLineNumber(), e.getLocalizedMessage());
-            Activator.getDefault().logError(error);
-            return new Status(IStatus.ERROR, Activator.PLUGIN_ID, error, e);
-        } catch (SAXException e) {
-            String error = NLS.bind(Messages.SessionConfigXML_XmlValidationError, e.getLocalizedMessage());
-            Activator.getDefault().logError(error);
-            return new Status(IStatus.ERROR, Activator.PLUGIN_ID, error, e);
-        } catch (IOException e) {
-            String error = Messages.SessionConfigXML_XmlValidateError;
-            Activator.getDefault().logError("IO exception occurred", e); //$NON-NLS-1$
-            return new Status(IStatus.ERROR, Activator.PLUGIN_ID, error, e);
-        }
-        return Status.OK_STATUS;
-    }
-
-    /**
-     * Saves the session configuration into a XML file.
-     *
-     * @param document
-     *            The document representing the session configuration file
-     * @param destination
-     *            The path of the locally saved session configuration file
-     * @throws TransformerException
-     *             On an transformation process
-     */
-    private static void saveSessionConfig(Document document, String destination) throws TransformerException {
-        /* Write the content into a XML file */
-        TransformerFactory transformerFactory = TransformerFactory.newInstance();
-        Transformer transformer = transformerFactory.newTransformer();
-
-        transformer.setOutputProperty(OutputKeys.INDENT, "yes"); //$NON-NLS-1$
-        transformer.setOutputProperty(INDENT_AMOUNT_PROPERTY_NAME, INDENT_AMOUNT_PROPERTY_VALUE);
-
-        DOMSource source = new DOMSource(document);
-        StreamResult result = new StreamResult(new File(destination));
-
-        transformer.transform(source, result);
-    }
-
-    /**
-     * Adds to a parent node an element with his content.
-     *
-     * @param document
-     *            The document in which the nodes are being added
-     * @param parent
-     *            The parent node that contains the element and his content
-     * @param elementName
-     *            The element container name
-     * @param elementContent
-     *            The content itself
-     */
-    private static void addElementContent(Document document, Element parent, String elementName, Object elementContent) {
-        Element contentElement = document.createElement(elementName);
-        contentElement.appendChild(document.createTextNode(elementContent.toString()));
-        parent.appendChild(contentElement);
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/lttng2/control/core/session/SessionConfigStrings.java b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/lttng2/control/core/session/SessionConfigStrings.java
deleted file mode 100644 (file)
index 9bb1869..0000000
+++ /dev/null
@@ -1,81 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014 École Polytechnique de Montréal
- *
- * 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:
- *   Guilliano Molaire - Initial API and implementation
- *********************************************************************/
-package org.eclipse.tracecompass.lttng2.control.core.session;
-
-/**
- * This file defines most markers from a session configuration file used to
- * configure a trace session. They can be found in the session configuration
- * schema "session.xsd" in src/common/config/ folder of LTTng-tools.
- *
- * @author Guilliano Molaire
- */
-@SuppressWarnings({ "javadoc", "nls" })
-public interface SessionConfigStrings {
-
-    /* Session configuration file extension */
-    String SESSION_CONFIG_FILE_EXTENSION = "lttng";
-
-    /* Elements of the session configuration file */
-    String CONFIG_ELEMENT_SESSIONS = "sessions";
-    String CONFIG_ELEMENT_SESSION = "session";
-    String CONFIG_ELEMENT_DOMAINS = "domains";
-    String CONFIG_ELEMENT_DOMAIN = "domain";
-    String CONFIG_ELEMENT_CHANNELS = "channels";
-    String CONFIG_ELEMENT_CHANNEL = "channel";
-    String CONFIG_ELEMENT_EVENTS = "events";
-    String CONFIG_ELEMENT_EVENT = "event";
-    String CONFIG_ELEMENT_OUTPUT = "output";
-    String CONFIG_ELEMENT_ATTRIBUTES = "attributes";
-    String CONFIG_ELEMENT_NET_OUTPUT = "net_output";
-    String CONFIG_ELEMENT_MAX_SIZE = "max_size";
-    String CONFIG_ELEMENT_SNAPSHOT_OUTPUTS = "snapshot_outputs";
-    String CONFIG_ELEMENT_CONSUMER_OUTPUT = "consumer_output";
-    String CONFIG_ELEMENT_DESTINATION = "destination";
-    String CONFIG_ELEMENT_CONTROL_URI = "control_uri";
-    String CONFIG_ELEMENT_DATA_URI = "data_uri";
-    String CONFIG_ELEMENT_SNAPSHOT_MODE = "snapshot_mode";
-    String CONFIG_ELEMENT_PATH = "path";
-    String CONFIG_ELEMENT_NAME = "name";
-    String CONFIG_ELEMENT_ENABLED = "enabled";
-    String CONFIG_ELEMENT_TYPE = "type";
-    String CONFIG_ELEMENT_STARTED = "started";
-    String CONFIG_ELEMENT_DOMAIN_BUFFER_TYPE = "buffer_type";
-    String CONFIG_ELEMENT_OVERWRITE_MODE = "overwrite_mode";
-    String CONFIG_ELEMENT_SUBBUFFER_SIZE = "subbuffer_size";
-    String CONFIG_ELEMENT_SUBBUFFER_COUNT = "subbuffer_count";
-    String CONFIG_ELEMENT_SWITCH_TIMER_INTERVAL = "switch_timer_interval";
-    String CONFIG_ELEMENT_READ_TIMER_INTERVAL = "read_timer_interval";
-    String CONFIG_ELEMENT_OUTPUT_TYPE = "output_type";
-    String CONFIG_ELEMENT_TRACEFILE_SIZE = "tracefile_size";
-    String CONFIG_ELEMENT_TRACEFILE_COUNT = "tracefile_count";
-    String CONFIG_ELEMENT_LIVE_TIMER_INTERVAL = "live_timer_interval";
-    String CONFIG_ELEMENT_LOGLEVEL_TYPE = "loglevel_type";
-    String CONFIG_ELEMENT_LOGLEVEL = "loglevel";
-
-    /* Common element values */
-    String CONFIG_STRING_TRUE = "true";
-    String CONFIG_STRING_FALSE = "false";
-    String CONFIG_STRING_ZERO = "0";
-
-    String CONFIG_DOMAIN_TYPE_KERNEL = "KERNEL";
-    String CONFIG_DOMAIN_TYPE_UST = "UST";
-
-    String CONFIG_BUFFER_TYPE_PER_UID = "PER_UID";
-    String CONFIG_BUFFER_TYPE_PER_PID = "PER_PID";
-    String CONFIG_BUFFER_TYPE_GLOBAL = "GLOBAL";
-
-    String CONFIG_OVERWRITE_MODE_DISCARD = "DISCARD";
-    String CONFIG_OVERWRITE_MODE_OVERWRITE = "OVERWRITE";
-
-    String CONFIG_OUTPUT_TYPE_SPLICE = "SPLICE";
-    String CONFIG_OUTPUT_TYPE_MMAP = "MMAP";
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/lttng2/control/core/session/messages.properties b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/lttng2/control/core/session/messages.properties
deleted file mode 100644 (file)
index c0d252d..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-###############################################################################
-# Copyright (c) 2014 École Polytechnique de Montréal
-#
-# 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:
-#     Guilliano Molaire - Initial API and implementation
-###############################################################################
-
-SessionConfigXML_BadRequirementType=The requirement type is not supported
-SessionConfigXML_DomainTypeMissing=The domain requirement type is missing
-SessionConfigXML_EventTypeMissing=The event requirement type is missing
-SessionConfigXML_InvalidSessionInfoList=The list of session is empty or null
-SessionConfigXML_InvalidTraceSessionPath=The trace session path is not valid
-SessionConfigXML_UnknownEventType=The event type is not handled by the session configuration
-SessionConfigXML_UnknownDomainBufferType=The domain buffer type is not handled by the session configuration
-SessionConfigXML_SessionConfigGenerationError=An error occurred while generating the session configuration file
-SessionConfigXML_XmlParseError=XML Parsing error at line {0}: {1}
-SessionConfigXML_XmlValidateError=An error occurred while validating the XML file.
-SessionConfigXML_XmlValidationError=Error validating XML file {0}
diff --git a/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/lttng2/control/core/session/session.xsd b/org.eclipse.tracecompass.lttng2.control.core/src/org/eclipse/tracecompass/lttng2/control/core/session/session.xsd
deleted file mode 100644 (file)
index 3023216..0000000
+++ /dev/null
@@ -1,296 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-Copyright (c) 2014 - Jérémie Galarneau <jeremie.galarneau@efficios.com>
-
-Permission is hereby granted, free of charge, to any person obtaining a copy
-of this software and associated documentation files (the "Software"), to deal
-in the Software without restriction, including without limitation the rights
-to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-copies of the Software, and to permit persons to whom the Software is
-furnished to do so, subject to the following conditions:
-
-The above copyright notice and this permission notice shall be included in
-all copies or substantial portions of the Software.
-
-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-THE SOFTWARE.
--->
-<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
-elementFormDefault="qualified" version="2.5">
-
-<xs:simpleType name="name_type">
-       <xs:restriction base="xs:string">
-               <xs:maxLength value="255"/>
-       </xs:restriction>
-</xs:simpleType>
-
-<xs:simpleType name="uint64_type">
-       <xs:restriction base="xs:integer">
-               <xs:minInclusive value="0"/>
-               <xs:maxInclusive value="18446744073709551615"/>
-       </xs:restriction>
-</xs:simpleType>
-
-<xs:simpleType name="uint32_type">
-       <xs:restriction base="xs:integer">
-               <xs:minInclusive value="0"/>
-               <xs:maxInclusive value="4294967295"/>
-       </xs:restriction>
-</xs:simpleType>
-
-<xs:simpleType name="channel_overwrite_mode_type">
-       <xs:restriction base="xs:string">
-               <xs:enumeration value="DISCARD"/>
-               <xs:enumeration value="OVERWRITE"/>
-       </xs:restriction>
-</xs:simpleType>
-
-<!-- Maps to the lttng_event_output enum -->
-<xs:simpleType name="event_output_type">
-       <xs:restriction base="xs:string">
-               <xs:enumeration value="SPLICE"/>
-               <xs:enumeration value="MMAP"/>
-       </xs:restriction>
-</xs:simpleType>
-
-<!-- Maps to the lttng_loglevel_type enum -->
-<xs:simpleType name="loglevel_type">
-       <xs:restriction base="xs:string">
-               <xs:enumeration value="ALL"/>
-               <xs:enumeration value="RANGE"/>
-               <xs:enumeration value="SINGLE"/>
-       </xs:restriction>
-</xs:simpleType>
-
-<!-- Maps to the lttng_event_type enum -->
-<xs:simpleType name="event_type_type">
-       <xs:restriction base="xs:string">
-               <xs:enumeration value="ALL"/>
-               <xs:enumeration value="TRACEPOINT"/>
-               <xs:enumeration value="PROBE"/>
-               <xs:enumeration value="FUNCTION"/>
-               <xs:enumeration value="FUNCTION_ENTRY"/>
-               <xs:enumeration value="NOOP"/>
-               <xs:enumeration value="SYSCALL"/>
-               <xs:enumeration value="KPROBE"/>
-               <xs:enumeration value="KRETPROBE"/>
-       </xs:restriction>
-</xs:simpleType>
-
-<xs:complexType name="event_probe_attributes_type">
-       <xs:all>
-               <xs:element name="symbol_name" type="name_type" minOccurs="0"/>
-               <xs:element name="address" type="uint64_type" minOccurs="0"/>
-               <xs:element name="offset" type="uint64_type" minOccurs="0"/>
-       </xs:all>
-</xs:complexType>
-
-<xs:complexType name="event_ftrace_attributes_type">
-       <xs:all>
-               <xs:element name="symbol_name" type="name_type"/>
-       </xs:all>
-</xs:complexType>
-
-<xs:complexType name="event_attributes_type">
-       <xs:choice>
-               <xs:element name="probe_attributes" type="event_probe_attributes_type"/>
-               <xs:element name="function_attributes" type="event_ftrace_attributes_type"/>
-       </xs:choice>
-</xs:complexType>
-
-<xs:complexType name="event_exclusion_list_type">
-       <xs:sequence>
-               <xs:element name="exclusion" type="xs:string" minOccurs="0" maxOccurs="unbounded"/>
-       </xs:sequence>
-</xs:complexType>
-
-<xs:complexType name="event_type">
-       <xs:all>
-               <xs:element name="name" type="name_type" minOccurs="0"/>
-               <xs:element name="enabled" type="xs:boolean" default="true" minOccurs="0"/>
-               <xs:element name="type" type="event_type_type" default="TRACEPOINT" minOccurs="0"/>
-               <xs:element name="loglevel_type" type="loglevel_type" default="ALL" minOccurs="0"/>
-               <xs:element name="loglevel" type="xs:int" default="-1" minOccurs="0"/>
-               <xs:element name="filter" type="xs:string" minOccurs="0"/>
-               <xs:element name="exclusions" type="event_exclusion_list_type" minOccurs="0"/>
-               <xs:element name="attributes" type="event_attributes_type" minOccurs="0"/>
-       </xs:all>
-</xs:complexType>
-
-<xs:complexType name="event_list_type">
-       <xs:sequence>
-               <xs:element name="event" type="event_type" minOccurs="0" maxOccurs="unbounded"/>
-       </xs:sequence>
-</xs:complexType>
-
-<xs:complexType name="event_perf_context_type">
-       <xs:all>
-               <xs:element name="type" type="uint32_type"/>
-               <xs:element name="config" type="uint64_type"/>
-               <xs:element name="name" type="name_type"/>
-       </xs:all>
-</xs:complexType>
-
-<!-- Maps to the lttng_event_context_type enum -->
-<xs:simpleType name="event_context_type_type">
-       <xs:restriction base="xs:string">
-               <xs:enumeration value="PID"/>
-               <xs:enumeration value="PROCNAME"/>
-               <xs:enumeration value="PRIO"/>
-               <xs:enumeration value="NICE"/>
-               <xs:enumeration value="VPID"/>
-               <xs:enumeration value="TID"/>
-               <xs:enumeration value="VTID"/>
-               <xs:enumeration value="PPID"/>
-               <xs:enumeration value="VPPID"/>
-               <xs:enumeration value="PTHREAD_ID"/>
-               <xs:enumeration value="HOSTNAME"/>
-               <xs:enumeration value="IP"/>
-       </xs:restriction>
-</xs:simpleType>
-
-<xs:complexType name="event_context_type">
-       <xs:choice>
-               <xs:element name="type" type="event_context_type_type"/>
-               <xs:element name="perf" type="event_perf_context_type"/>
-       </xs:choice>
-</xs:complexType>
-
-<xs:complexType name="event_context_list_type">
-       <xs:sequence>
-               <xs:element name="context" type="event_context_type" minOccurs="0" maxOccurs="unbounded"/>
-       </xs:sequence>
-</xs:complexType>
-
-<!-- Maps to struct lttng_channel -->
-<xs:complexType name="channel_type">
-       <xs:all>
-               <xs:element name="name" type="name_type"/>
-               <xs:element name="enabled" type="xs:boolean" default="true" minOccurs="0"/>
-               <xs:element name="overwrite_mode" type="channel_overwrite_mode_type" default="DISCARD" minOccurs="0"/>
-               <xs:element name="subbuffer_size" type="uint64_type" minOccurs="0"/> <!-- bytes -->
-               <xs:element name="subbuffer_count" type="uint64_type" default="4" minOccurs="0"/>
-               <xs:element name="switch_timer_interval" type="uint32_type" default="0" minOccurs="0"/>  <!-- usec -->
-               <xs:element name="read_timer_interval" type="uint32_type"/>  <!-- usec -->
-               <xs:element name="output_type" type="event_output_type"/>
-               <xs:element name="tracefile_size" type="uint64_type" default="0" minOccurs="0"/> <!-- bytes -->
-               <xs:element name="tracefile_count" type="uint64_type" default="0" minOccurs="0"/>
-               <xs:element name="live_timer_interval" type="uint32_type" default="0" minOccurs="0"/> <!-- usec -->
-               <xs:element name="events" type="event_list_type" minOccurs="0"/>
-               <xs:element name="contexts" type="event_context_list_type" minOccurs="0"/>
-       </xs:all>
-</xs:complexType>
-
-<!-- Maps to the lttng_domain_type enum -->
-<xs:simpleType name="domain_type_type">
-       <xs:restriction base="xs:string">
-               <xs:enumeration value="KERNEL"/>
-               <xs:enumeration value="UST"/>
-               <xs:enumeration value="JUL"/>
-               <xs:enumeration value="LOG4J"/>
-       </xs:restriction>
-</xs:simpleType>
-
-<!-- Maps to the lttng_buffer_type enum -->
-<xs:simpleType name="domain_buffer_type">
-       <xs:restriction base="xs:string">
-               <xs:enumeration value="PER_PID"/>
-               <xs:enumeration value="PER_UID"/>
-               <xs:enumeration value="GLOBAL"/>
-       </xs:restriction>
-</xs:simpleType>
-
-<xs:complexType name="channel_list_type">
-       <xs:sequence>
-               <xs:element name="channel" type="channel_type" minOccurs="0" maxOccurs="unbounded"/>
-       </xs:sequence>
-</xs:complexType>
-
-<!-- Maps to struct lttng_domain and contains channels -->
-<xs:complexType name="domain_type">
-       <xs:all>
-               <xs:element name="type" type="domain_type_type"/>
-               <xs:element name="buffer_type" type="domain_buffer_type"/>
-               <xs:element name="channels" type="channel_list_type" minOccurs="0"/>
-       </xs:all>
-</xs:complexType>
-
-<xs:complexType name="session_attributes_type">
-       <xs:choice>
-               <xs:element name="snapshot_mode" type="xs:boolean"/>
-               <xs:element name="live_timer_interval" type="uint32_type"/> <!-- usec -->
-       </xs:choice>
-</xs:complexType>
-
-<xs:complexType name="domain_list_type">
-       <xs:sequence>
-               <xs:element name="domain" type="domain_type" minOccurs="0" maxOccurs="unbounded"/>
-       </xs:sequence>
-</xs:complexType>
-
-<xs:complexType name="net_output_type">
-       <xs:all>
-               <xs:element name="control_uri" type="xs:string"/>
-               <xs:element name="data_uri" type="xs:string"/>
-       </xs:all>
-</xs:complexType>
-
-<xs:complexType name="destination_type">
-       <xs:choice>
-               <xs:element name="path" type="xs:string"/>
-               <xs:element name="net_output" type="net_output_type"/>
-       </xs:choice>
-</xs:complexType>
-
-<xs:complexType name="consumer_output_type">
-       <xs:all>
-               <xs:element name="enabled" type="xs:boolean" default="true"/>
-               <xs:element name="destination" type="destination_type"/>
-       </xs:all>
-</xs:complexType>
-
-<xs:complexType name="snapshot_output_type">
-       <xs:all>
-               <xs:element name="name" type="name_type"/>
-               <xs:element name="max_size" type="uint64_type"/>
-               <xs:element name="consumer_output" type="consumer_output_type"/>
-       </xs:all>
-</xs:complexType>
-
-<xs:complexType name="snapshot_output_list_type">
-       <xs:sequence>
-               <xs:element name="output" type="snapshot_output_type" minOccurs="0" maxOccurs="unbounded"/>
-       </xs:sequence>
-</xs:complexType>
-
-<xs:complexType name="session_output_type">
-       <xs:choice>
-               <xs:element name="snapshot_outputs" type="snapshot_output_list_type"/>
-               <xs:element name="consumer_output" type="consumer_output_type"/>
-       </xs:choice>
-</xs:complexType>
-
-<xs:complexType name="session_type">
-       <xs:all>
-               <xs:element name="name" type="name_type"/>
-               <xs:element name="domains" type="domain_list_type" minOccurs="0"/>
-               <xs:element name="started" type="xs:boolean" default="0" minOccurs="0"/>
-               <xs:element name="attributes" type="session_attributes_type" minOccurs="0"/>
-               <xs:element name="output" type="session_output_type" minOccurs="0"/>
-       </xs:all>
-</xs:complexType>
-
-<xs:element name="sessions">
-       <xs:complexType>
-               <xs:sequence>
-                       <xs:element name="session" type="session_type" maxOccurs="unbounded"/>
-               </xs:sequence>
-       </xs:complexType>
-</xs:element>
-
-</xs:schema>
diff --git a/org.eclipse.tracecompass.lttng2.control.ui.tests/.classpath b/org.eclipse.tracecompass.lttng2.control.ui.tests/.classpath
deleted file mode 100644 (file)
index f1d3296..0000000
+++ /dev/null
@@ -1,8 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
-       <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7"/>
-       <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
-       <classpathentry kind="src" path="src"/>
-       <classpathentry kind="src" path="stubs"/>
-       <classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/org.eclipse.tracecompass.lttng2.control.ui.tests/.project b/org.eclipse.tracecompass.lttng2.control.ui.tests/.project
deleted file mode 100644 (file)
index b9f247d..0000000
+++ /dev/null
@@ -1,34 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
-       <name>org.eclipse.tracecompass.lttng2.control.ui.tests</name>
-       <comment></comment>
-       <projects>
-       </projects>
-       <buildSpec>
-               <buildCommand>
-                       <name>org.eclipse.jdt.core.javabuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-               <buildCommand>
-                       <name>org.eclipse.pde.ManifestBuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-               <buildCommand>
-                       <name>org.eclipse.pde.SchemaBuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-               <buildCommand>
-                       <name>org.eclipse.pde.api.tools.apiAnalysisBuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-       </buildSpec>
-       <natures>
-               <nature>org.eclipse.pde.PluginNature</nature>
-               <nature>org.eclipse.jdt.core.javanature</nature>
-               <nature>org.eclipse.pde.api.tools.apiAnalysisNature</nature>
-       </natures>
-</projectDescription>
diff --git a/org.eclipse.tracecompass.lttng2.control.ui.tests/.settings/org.eclipse.core.resources.prefs b/org.eclipse.tracecompass.lttng2.control.ui.tests/.settings/org.eclipse.core.resources.prefs
deleted file mode 100644 (file)
index 99f26c0..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-eclipse.preferences.version=1
-encoding/<project>=UTF-8
diff --git a/org.eclipse.tracecompass.lttng2.control.ui.tests/.settings/org.eclipse.core.runtime.prefs b/org.eclipse.tracecompass.lttng2.control.ui.tests/.settings/org.eclipse.core.runtime.prefs
deleted file mode 100644 (file)
index 5a0ad22..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-eclipse.preferences.version=1
-line.separator=\n
diff --git a/org.eclipse.tracecompass.lttng2.control.ui.tests/.settings/org.eclipse.jdt.core.prefs b/org.eclipse.tracecompass.lttng2.control.ui.tests/.settings/org.eclipse.jdt.core.prefs
deleted file mode 100644 (file)
index 0409c61..0000000
+++ /dev/null
@@ -1,403 +0,0 @@
-eclipse.preferences.version=1
-org.eclipse.jdt.core.codeComplete.argumentPrefixes=
-org.eclipse.jdt.core.codeComplete.argumentSuffixes=
-org.eclipse.jdt.core.codeComplete.fieldPrefixes=f
-org.eclipse.jdt.core.codeComplete.fieldSuffixes=
-org.eclipse.jdt.core.codeComplete.localPrefixes=
-org.eclipse.jdt.core.codeComplete.localSuffixes=
-org.eclipse.jdt.core.codeComplete.staticFieldPrefixes=
-org.eclipse.jdt.core.codeComplete.staticFieldSuffixes=
-org.eclipse.jdt.core.codeComplete.staticFinalFieldPrefixes=
-org.eclipse.jdt.core.codeComplete.staticFinalFieldSuffixes=
-org.eclipse.jdt.core.compiler.annotation.inheritNullAnnotations=enabled
-org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore
-org.eclipse.jdt.core.compiler.annotation.nonnull=org.eclipse.jdt.annotation.NonNull
-org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=org.eclipse.jdt.annotation.NonNullByDefault
-org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nullable
-org.eclipse.jdt.core.compiler.annotation.nullanalysis=enabled
-org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
-org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
-org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
-org.eclipse.jdt.core.compiler.compliance=1.7
-org.eclipse.jdt.core.compiler.debug.lineNumber=generate
-org.eclipse.jdt.core.compiler.debug.localVariable=generate
-org.eclipse.jdt.core.compiler.debug.sourceFile=generate
-org.eclipse.jdt.core.compiler.doc.comment.support=enabled
-org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=error
-org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
-org.eclipse.jdt.core.compiler.problem.autoboxing=ignore
-org.eclipse.jdt.core.compiler.problem.comparingIdentical=error
-org.eclipse.jdt.core.compiler.problem.deadCode=error
-org.eclipse.jdt.core.compiler.problem.deprecation=error
-org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled
-org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=enabled
-org.eclipse.jdt.core.compiler.problem.discouragedReference=error
-org.eclipse.jdt.core.compiler.problem.emptyStatement=error
-org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
-org.eclipse.jdt.core.compiler.problem.explicitlyClosedAutoCloseable=error
-org.eclipse.jdt.core.compiler.problem.fallthroughCase=error
-org.eclipse.jdt.core.compiler.problem.fatalOptionalError=disabled
-org.eclipse.jdt.core.compiler.problem.fieldHiding=error
-org.eclipse.jdt.core.compiler.problem.finalParameterBound=error
-org.eclipse.jdt.core.compiler.problem.finallyBlockNotCompletingNormally=error
-org.eclipse.jdt.core.compiler.problem.forbiddenReference=error
-org.eclipse.jdt.core.compiler.problem.hiddenCatchBlock=error
-org.eclipse.jdt.core.compiler.problem.includeNullInfoFromAsserts=disabled
-org.eclipse.jdt.core.compiler.problem.incompatibleNonInheritedInterfaceMethod=error
-org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch=error
-org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=error
-org.eclipse.jdt.core.compiler.problem.invalidJavadoc=warning
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTags=enabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsDeprecatedRef=enabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsNotVisibleRef=enabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsVisibility=protected
-org.eclipse.jdt.core.compiler.problem.localVariableHiding=error
-org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=error
-org.eclipse.jdt.core.compiler.problem.missingDefaultCase=error
-org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=error
-org.eclipse.jdt.core.compiler.problem.missingEnumCaseDespiteDefault=enabled
-org.eclipse.jdt.core.compiler.problem.missingHashCodeMethod=error
-org.eclipse.jdt.core.compiler.problem.missingJavadocComments=warning
-org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsOverriding=disabled
-org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsVisibility=protected
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagDescription=all_standard_tags
-org.eclipse.jdt.core.compiler.problem.missingJavadocTags=warning
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagsMethodTypeParameters=disabled
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagsOverriding=disabled
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagsVisibility=protected
-org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotation=error
-org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotationForInterfaceMethodImplementation=enabled
-org.eclipse.jdt.core.compiler.problem.missingSerialVersion=error
-org.eclipse.jdt.core.compiler.problem.missingSynchronizedOnInheritedMethod=error
-org.eclipse.jdt.core.compiler.problem.noEffectAssignment=error
-org.eclipse.jdt.core.compiler.problem.noImplicitStringConversion=error
-org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=ignore
-org.eclipse.jdt.core.compiler.problem.nonnullParameterAnnotationDropped=warning
-org.eclipse.jdt.core.compiler.problem.nullAnnotationInferenceConflict=warning
-org.eclipse.jdt.core.compiler.problem.nullReference=error
-org.eclipse.jdt.core.compiler.problem.nullSpecViolation=error
-org.eclipse.jdt.core.compiler.problem.nullUncheckedConversion=warning
-org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=error
-org.eclipse.jdt.core.compiler.problem.parameterAssignment=error
-org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=error
-org.eclipse.jdt.core.compiler.problem.potentialNullReference=error
-org.eclipse.jdt.core.compiler.problem.potentiallyUnclosedCloseable=warning
-org.eclipse.jdt.core.compiler.problem.rawTypeReference=error
-org.eclipse.jdt.core.compiler.problem.redundantNullAnnotation=warning
-org.eclipse.jdt.core.compiler.problem.redundantNullCheck=error
-org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=error
-org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=error
-org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore
-org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=error
-org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled
-org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=error
-org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=disabled
-org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled
-org.eclipse.jdt.core.compiler.problem.syntacticNullAnalysisForFields=enabled
-org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=ignore
-org.eclipse.jdt.core.compiler.problem.typeParameterHiding=error
-org.eclipse.jdt.core.compiler.problem.unavoidableGenericTypeProblems=disabled
-org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=error
-org.eclipse.jdt.core.compiler.problem.unclosedCloseable=error
-org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=ignore
-org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=error
-org.eclipse.jdt.core.compiler.problem.unnecessaryElse=error
-org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=error
-org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=error
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionExemptExceptionAndThrowable=disabled
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionIncludeDocCommentReference=disabled
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverriding=disabled
-org.eclipse.jdt.core.compiler.problem.unusedImport=error
-org.eclipse.jdt.core.compiler.problem.unusedLabel=error
-org.eclipse.jdt.core.compiler.problem.unusedLocal=error
-org.eclipse.jdt.core.compiler.problem.unusedObjectAllocation=ignore
-org.eclipse.jdt.core.compiler.problem.unusedParameter=ignore
-org.eclipse.jdt.core.compiler.problem.unusedParameterIncludeDocCommentReference=enabled
-org.eclipse.jdt.core.compiler.problem.unusedParameterWhenImplementingAbstract=disabled
-org.eclipse.jdt.core.compiler.problem.unusedParameterWhenOverridingConcrete=disabled
-org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=error
-org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=ignore
-org.eclipse.jdt.core.compiler.problem.unusedWarningToken=error
-org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=error
-org.eclipse.jdt.core.compiler.source=1.7
-org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_call=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression=16
-org.eclipse.jdt.core.formatter.alignment_for_assignment=0
-org.eclipse.jdt.core.formatter.alignment_for_binary_expression=16
-org.eclipse.jdt.core.formatter.alignment_for_compact_if=16
-org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=80
-org.eclipse.jdt.core.formatter.alignment_for_enum_constants=0
-org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=16
-org.eclipse.jdt.core.formatter.alignment_for_method_declaration=0
-org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16
-org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=80
-org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation=0
-org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_constructor_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_method_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_union_type_in_multicatch=16
-org.eclipse.jdt.core.formatter.blank_lines_after_imports=1
-org.eclipse.jdt.core.formatter.blank_lines_after_package=1
-org.eclipse.jdt.core.formatter.blank_lines_before_field=0
-org.eclipse.jdt.core.formatter.blank_lines_before_first_class_body_declaration=0
-org.eclipse.jdt.core.formatter.blank_lines_before_imports=1
-org.eclipse.jdt.core.formatter.blank_lines_before_member_type=1
-org.eclipse.jdt.core.formatter.blank_lines_before_method=1
-org.eclipse.jdt.core.formatter.blank_lines_before_new_chunk=1
-org.eclipse.jdt.core.formatter.blank_lines_before_package=0
-org.eclipse.jdt.core.formatter.blank_lines_between_import_groups=1
-org.eclipse.jdt.core.formatter.blank_lines_between_type_declarations=1
-org.eclipse.jdt.core.formatter.brace_position_for_annotation_type_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_array_initializer=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_block=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_block_in_case=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_constructor_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_enum_constant=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_enum_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_method_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_switch=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_type_declaration=end_of_line
-org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_block_comment=false
-org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_javadoc_comment=false
-org.eclipse.jdt.core.formatter.comment.format_block_comments=true
-org.eclipse.jdt.core.formatter.comment.format_header=false
-org.eclipse.jdt.core.formatter.comment.format_html=true
-org.eclipse.jdt.core.formatter.comment.format_javadoc_comments=true
-org.eclipse.jdt.core.formatter.comment.format_line_comments=true
-org.eclipse.jdt.core.formatter.comment.format_source_code=true
-org.eclipse.jdt.core.formatter.comment.indent_parameter_description=true
-org.eclipse.jdt.core.formatter.comment.indent_root_tags=true
-org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags=insert
-org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter=insert
-org.eclipse.jdt.core.formatter.comment.line_length=80
-org.eclipse.jdt.core.formatter.comment.new_lines_at_block_boundaries=true
-org.eclipse.jdt.core.formatter.comment.new_lines_at_javadoc_boundaries=true
-org.eclipse.jdt.core.formatter.comment.preserve_white_space_between_code_and_line_comments=false
-org.eclipse.jdt.core.formatter.compact_else_if=true
-org.eclipse.jdt.core.formatter.continuation_indentation=2
-org.eclipse.jdt.core.formatter.continuation_indentation_for_array_initializer=2
-org.eclipse.jdt.core.formatter.disabling_tag=@formatter\:off
-org.eclipse.jdt.core.formatter.enabling_tag=@formatter\:on
-org.eclipse.jdt.core.formatter.format_guardian_clause_on_one_line=false
-org.eclipse.jdt.core.formatter.format_line_comment_starting_on_first_column=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_annotation_declaration_header=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_constant_header=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_declaration_header=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_type_header=true
-org.eclipse.jdt.core.formatter.indent_breaks_compare_to_cases=true
-org.eclipse.jdt.core.formatter.indent_empty_lines=false
-org.eclipse.jdt.core.formatter.indent_statements_compare_to_block=true
-org.eclipse.jdt.core.formatter.indent_statements_compare_to_body=true
-org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_cases=true
-org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_switch=false
-org.eclipse.jdt.core.formatter.indentation.size=4
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_field=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_local_variable=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_method=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_package=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_parameter=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_type=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_label=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_opening_brace_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_at_end_of_file_if_missing=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_finally_in_try_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_while_in_do_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_annotation_declaration=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_anonymous_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_block=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter=insert
-org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_binary_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_paren_in_cast=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_assert=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_case=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_labeled_statement=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_allocation_expression=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_annotation=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_throws=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_constant_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_declarations=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_explicitconstructorcall_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_increments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_inits=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_throws=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_invocation_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_field_declarations=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_local_declarations=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_parameterized_type_reference=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_superinterfaces=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_ellipsis=insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_brace_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_cast=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_catch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_for=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_if=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_parenthesized_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_switch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_synchronized=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_try=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_while=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_try_resources=insert
-org.eclipse.jdt.core.formatter.insert_space_after_unary_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter=insert
-org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_binary_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_brace_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_cast=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_catch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_for=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_if=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_parenthesized_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_switch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_synchronized=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_try=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_while=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_assert=insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_case=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_default=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_labeled_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_throws=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_constant_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_declarations=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_explicitconstructorcall_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_increments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_inits=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_throws=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_invocation_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_field_declarations=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_local_declarations=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_superinterfaces=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_ellipsis=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_annotation_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_anonymous_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_block=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_constructor_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_constant=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_method_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_switch=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation_type_member_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_catch=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_if=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_parenthesized_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_switch=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_synchronized=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_try=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_while=insert
-org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_return=insert
-org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_throw=insert
-org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_semicolon=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_try_resources=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_unary_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_brackets_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_annotation_type_member_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.join_lines_in_comments=true
-org.eclipse.jdt.core.formatter.join_wrapped_lines=false
-org.eclipse.jdt.core.formatter.keep_else_statement_on_same_line=false
-org.eclipse.jdt.core.formatter.keep_empty_array_initializer_on_one_line=false
-org.eclipse.jdt.core.formatter.keep_imple_if_on_one_line=false
-org.eclipse.jdt.core.formatter.keep_then_statement_on_same_line=false
-org.eclipse.jdt.core.formatter.lineSplit=250
-org.eclipse.jdt.core.formatter.never_indent_block_comments_on_first_column=false
-org.eclipse.jdt.core.formatter.never_indent_line_comments_on_first_column=false
-org.eclipse.jdt.core.formatter.number_of_blank_lines_at_beginning_of_method_body=0
-org.eclipse.jdt.core.formatter.number_of_empty_lines_to_preserve=1
-org.eclipse.jdt.core.formatter.put_empty_statement_on_new_line=true
-org.eclipse.jdt.core.formatter.tabulation.char=space
-org.eclipse.jdt.core.formatter.tabulation.size=4
-org.eclipse.jdt.core.formatter.use_on_off_tags=false
-org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false
-org.eclipse.jdt.core.formatter.wrap_before_binary_operator=true
-org.eclipse.jdt.core.formatter.wrap_before_or_operator_multicatch=true
-org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true
diff --git a/org.eclipse.tracecompass.lttng2.control.ui.tests/.settings/org.eclipse.jdt.ui.prefs b/org.eclipse.tracecompass.lttng2.control.ui.tests/.settings/org.eclipse.jdt.ui.prefs
deleted file mode 100644 (file)
index 232a3fd..0000000
+++ /dev/null
@@ -1,60 +0,0 @@
-eclipse.preferences.version=1
-editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true
-formatter_profile=_tmf-style
-formatter_settings_version=12
-org.eclipse.jdt.ui.exception.name=e
-org.eclipse.jdt.ui.gettersetter.use.is=true
-org.eclipse.jdt.ui.keywordthis=false
-org.eclipse.jdt.ui.overrideannotation=true
-sp_cleanup.add_default_serial_version_id=true
-sp_cleanup.add_generated_serial_version_id=false
-sp_cleanup.add_missing_annotations=false
-sp_cleanup.add_missing_deprecated_annotations=true
-sp_cleanup.add_missing_methods=false
-sp_cleanup.add_missing_nls_tags=false
-sp_cleanup.add_missing_override_annotations=true
-sp_cleanup.add_missing_override_annotations_interface_methods=true
-sp_cleanup.add_serial_version_id=false
-sp_cleanup.always_use_blocks=true
-sp_cleanup.always_use_parentheses_in_expressions=false
-sp_cleanup.always_use_this_for_non_static_field_access=false
-sp_cleanup.always_use_this_for_non_static_method_access=false
-sp_cleanup.convert_to_enhanced_for_loop=false
-sp_cleanup.correct_indentation=false
-sp_cleanup.format_source_code=false
-sp_cleanup.format_source_code_changes_only=false
-sp_cleanup.make_local_variable_final=false
-sp_cleanup.make_parameters_final=false
-sp_cleanup.make_private_fields_final=true
-sp_cleanup.make_type_abstract_if_missing_method=false
-sp_cleanup.make_variable_declarations_final=false
-sp_cleanup.never_use_blocks=false
-sp_cleanup.never_use_parentheses_in_expressions=true
-sp_cleanup.on_save_use_additional_actions=true
-sp_cleanup.organize_imports=false
-sp_cleanup.qualify_static_field_accesses_with_declaring_class=false
-sp_cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=true
-sp_cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=true
-sp_cleanup.qualify_static_member_accesses_with_declaring_class=false
-sp_cleanup.qualify_static_method_accesses_with_declaring_class=false
-sp_cleanup.remove_private_constructors=true
-sp_cleanup.remove_trailing_whitespaces=true
-sp_cleanup.remove_trailing_whitespaces_all=true
-sp_cleanup.remove_trailing_whitespaces_ignore_empty=false
-sp_cleanup.remove_unnecessary_casts=false
-sp_cleanup.remove_unnecessary_nls_tags=false
-sp_cleanup.remove_unused_imports=false
-sp_cleanup.remove_unused_local_variables=false
-sp_cleanup.remove_unused_private_fields=true
-sp_cleanup.remove_unused_private_members=false
-sp_cleanup.remove_unused_private_methods=true
-sp_cleanup.remove_unused_private_types=true
-sp_cleanup.sort_members=false
-sp_cleanup.sort_members_all=false
-sp_cleanup.use_blocks=true
-sp_cleanup.use_blocks_only_for_return_and_throw=false
-sp_cleanup.use_parentheses_in_expressions=false
-sp_cleanup.use_this_for_non_static_field_access=false
-sp_cleanup.use_this_for_non_static_field_access_only_if_necessary=true
-sp_cleanup.use_this_for_non_static_method_access=false
-sp_cleanup.use_this_for_non_static_method_access_only_if_necessary=true
diff --git a/org.eclipse.tracecompass.lttng2.control.ui.tests/.settings/org.eclipse.pde.api.tools.prefs b/org.eclipse.tracecompass.lttng2.control.ui.tests/.settings/org.eclipse.pde.api.tools.prefs
deleted file mode 100644 (file)
index acc3abd..0000000
+++ /dev/null
@@ -1,97 +0,0 @@
-ANNOTATION_ELEMENT_TYPE_ADDED_METHOD_WITHOUT_DEFAULT_VALUE=Error
-ANNOTATION_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-ANNOTATION_ELEMENT_TYPE_REMOVED_FIELD=Error
-ANNOTATION_ELEMENT_TYPE_REMOVED_METHOD=Error
-ANNOTATION_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_API_TYPE=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_API_TYPE=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_TYPE=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_TYPE=Error
-API_USE_SCAN_FIELD_SEVERITY=Error
-API_USE_SCAN_METHOD_SEVERITY=Error
-API_USE_SCAN_TYPE_SEVERITY=Error
-CLASS_ELEMENT_TYPE_ADDED_METHOD=Error
-CLASS_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
-CLASS_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-CLASS_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
-CLASS_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-CLASS_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
-CLASS_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
-CLASS_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-CLASS_ELEMENT_TYPE_REMOVED_CONSTRUCTOR=Error
-CLASS_ELEMENT_TYPE_REMOVED_FIELD=Error
-CLASS_ELEMENT_TYPE_REMOVED_METHOD=Error
-CLASS_ELEMENT_TYPE_REMOVED_SUPERCLASS=Error
-CLASS_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-CLASS_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-CONSTRUCTOR_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-CONSTRUCTOR_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-CONSTRUCTOR_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
-CONSTRUCTOR_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-ENUM_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
-ENUM_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-ENUM_ELEMENT_TYPE_REMOVED_ENUM_CONSTANT=Error
-ENUM_ELEMENT_TYPE_REMOVED_FIELD=Error
-ENUM_ELEMENT_TYPE_REMOVED_METHOD=Error
-ENUM_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-FIELD_ELEMENT_TYPE_ADDED_VALUE=Error
-FIELD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-FIELD_ELEMENT_TYPE_CHANGED_FINAL_TO_NON_FINAL_STATIC_CONSTANT=Error
-FIELD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
-FIELD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
-FIELD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
-FIELD_ELEMENT_TYPE_CHANGED_TYPE=Error
-FIELD_ELEMENT_TYPE_CHANGED_VALUE=Error
-FIELD_ELEMENT_TYPE_REMOVED_TYPE_ARGUMENT=Error
-FIELD_ELEMENT_TYPE_REMOVED_VALUE=Error
-ILLEGAL_EXTEND=Warning
-ILLEGAL_IMPLEMENT=Warning
-ILLEGAL_INSTANTIATE=Warning
-ILLEGAL_OVERRIDE=Warning
-ILLEGAL_REFERENCE=Warning
-INTERFACE_ELEMENT_TYPE_ADDED_FIELD=Error
-INTERFACE_ELEMENT_TYPE_ADDED_METHOD=Error
-INTERFACE_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
-INTERFACE_ELEMENT_TYPE_ADDED_SUPER_INTERFACE_WITH_METHODS=Error
-INTERFACE_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-INTERFACE_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
-INTERFACE_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_FIELD=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_METHOD=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-INVALID_JAVADOC_TAG=Warning
-INVALID_REFERENCE_IN_SYSTEM_LIBRARIES=Warning
-LEAK_EXTEND=Warning
-LEAK_FIELD_DECL=Warning
-LEAK_IMPLEMENT=Warning
-LEAK_METHOD_PARAM=Warning
-LEAK_METHOD_RETURN_TYPE=Warning
-METHOD_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
-METHOD_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-METHOD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-METHOD_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
-METHOD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
-METHOD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
-METHOD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
-METHOD_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
-METHOD_ELEMENT_TYPE_REMOVED_ANNOTATION_DEFAULT_VALUE=Error
-METHOD_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-MISSING_EE_DESCRIPTIONS=Ignore
-TYPE_PARAMETER_ELEMENT_TYPE_ADDED_CLASS_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_ADDED_INTERFACE_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_CLASS_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_INTERFACE_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_CLASS_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_INTERFACE_BOUND=Error
-UNUSED_PROBLEM_FILTERS=Warning
-automatically_removed_unused_problem_filters=false
-eclipse.preferences.version=1
-incompatible_api_component_version=Error
-incompatible_api_component_version_include_major_without_breaking_change=Disabled
-incompatible_api_component_version_include_minor_without_api_change=Disabled
-invalid_since_tag_version=Error
-malformed_since_tag=Error
-missing_since_tag=Error
-report_api_breakage_when_major_version_incremented=Disabled
-report_resolution_errors_api_component=Warning
diff --git a/org.eclipse.tracecompass.lttng2.control.ui.tests/.settings/org.eclipse.pde.prefs b/org.eclipse.tracecompass.lttng2.control.ui.tests/.settings/org.eclipse.pde.prefs
deleted file mode 100644 (file)
index 62cfa90..0000000
+++ /dev/null
@@ -1,32 +0,0 @@
-compilers.f.unresolved-features=1
-compilers.f.unresolved-plugins=1
-compilers.incompatible-environment=1
-compilers.p.build=1
-compilers.p.build.bin.includes=1
-compilers.p.build.encodings=2
-compilers.p.build.java.compiler=2
-compilers.p.build.java.compliance=1
-compilers.p.build.missing.output=2
-compilers.p.build.output.library=1
-compilers.p.build.source.library=1
-compilers.p.build.src.includes=1
-compilers.p.deprecated=1
-compilers.p.discouraged-class=1
-compilers.p.internal=1
-compilers.p.missing-packages=2
-compilers.p.missing-version-export-package=2
-compilers.p.missing-version-import-package=2
-compilers.p.missing-version-require-bundle=2
-compilers.p.no-required-att=0
-compilers.p.not-externalized-att=2
-compilers.p.unknown-attribute=1
-compilers.p.unknown-class=1
-compilers.p.unknown-element=1
-compilers.p.unknown-identifier=1
-compilers.p.unknown-resource=1
-compilers.p.unresolved-ex-points=0
-compilers.p.unresolved-import=0
-compilers.s.create-docs=false
-compilers.s.doc-folder=doc
-compilers.s.open-tags=1
-eclipse.preferences.version=1
diff --git a/org.eclipse.tracecompass.lttng2.control.ui.tests/META-INF/MANIFEST.MF b/org.eclipse.tracecompass.lttng2.control.ui.tests/META-INF/MANIFEST.MF
deleted file mode 100644 (file)
index c406999..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-Manifest-Version: 1.0
-Bundle-ManifestVersion: 2
-Bundle-Name: %Bundle-Name
-Bundle-Vendor: %Bundle-Vendor
-Bundle-Version: 1.0.0.qualifier
-Bundle-Localization: plugin
-Bundle-SymbolicName: org.eclipse.tracecompass.lttng2.control.ui.tests;singleton:=true
-Bundle-ActivationPolicy: lazy
-Bundle-RequiredExecutionEnvironment: JavaSE-1.7
-Require-Bundle: org.junit;bundle-version="4.0.0",
- org.eclipse.core.commands,
- org.eclipse.core.runtime,
- org.eclipse.ui,
- org.eclipse.ui.ide,
- org.eclipse.remote.core,
- org.eclipse.tracecompass.common.core,
- org.eclipse.tracecompass.lttng2.control.core,
- org.eclipse.tracecompass.lttng2.control.ui,
- org.eclipse.tracecompass.tmf.remote.core,
- org.eclipse.tracecompass.tmf.remote.core.tests
-Export-Package: org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs;x-internal:=true,
- org.eclipse.tracecompass.internal.lttng2.control.stubs.service;x-internal:=true,
- org.eclipse.tracecompass.internal.lttng2.control.stubs.shells;x-internal:=true,
- org.eclipse.tracecompass.lttng2.control.ui.tests;x-friends:="org.eclipse.tracecompass.alltests",
- org.eclipse.tracecompass.lttng2.control.ui.tests.model.component;x-internal:=true,
- org.eclipse.tracecompass.lttng2.control.ui.tests.service;x-internal:=true
diff --git a/org.eclipse.tracecompass.lttng2.control.ui.tests/about.html b/org.eclipse.tracecompass.lttng2.control.ui.tests/about.html
deleted file mode 100644 (file)
index c258ef5..0000000
+++ /dev/null
@@ -1,28 +0,0 @@
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
-    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml">
-<head>
-<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"/>
-<title>About</title>
-</head>
-<body lang="EN-US">
-<h2>About This Content</h2>
-<p>June 5, 2006</p>    
-<h3>License</h3>
-
-<p>The Eclipse Foundation makes available all content in this plug-in (&quot;Content&quot;).  Unless otherwise 
-indicated below, the Content is provided to you under the terms and conditions of the
-Eclipse Public License Version 1.0 (&quot;EPL&quot;).  A copy of the EPL is available 
-at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>.
-For purposes of the EPL, &quot;Program&quot; will mean the Content.</p>
-
-<p>If you did not receive this Content directly from the Eclipse Foundation, the Content is 
-being redistributed by another party (&quot;Redistributor&quot;) and different terms and conditions may
-apply to your use of any object code in the Content.  Check the Redistributor's license that was 
-provided with the Content.  If no such license exists, contact the Redistributor.  Unless otherwise
-indicated below, the terms and conditions of the EPL still apply to any source code in the Content
-and such source code may be obtained at <a href="http://www.eclipse.org/">http://www.eclipse.org</a>.</p>
-
-</body>
-</html>
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.ui.tests/build.properties b/org.eclipse.tracecompass.lttng2.control.ui.tests/build.properties
deleted file mode 100644 (file)
index 203b5b3..0000000
+++ /dev/null
@@ -1,22 +0,0 @@
-###############################################################################
-# Copyright (c) 2013, 2015 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:
-#     Ericsson - Initial API and implementation
-###############################################################################
-
-source.. = src/,\
-           stubs/
-output.. = bin/
-bin.includes = META-INF/,\
-               .,\
-               plugin.properties,\
-               about.html
-src.includes = about.html
-additional.bundles = org.eclipse.jdt.annotation
-jars.extra.classpath = platform:/plugin/org.eclipse.jdt.annotation
diff --git a/org.eclipse.tracecompass.lttng2.control.ui.tests/plugin.properties b/org.eclipse.tracecompass.lttng2.control.ui.tests/plugin.properties
deleted file mode 100644 (file)
index d0deb3e..0000000
+++ /dev/null
@@ -1,14 +0,0 @@
-###############################################################################
-# Copyright (c) 2013, 2014 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:
-#     Ericsson - Initial API and implementation
-###############################################################################
-
-Bundle-Vendor = Eclipse Trace Compass
-Bundle-Name = Trace Compass LTTng Control UI Tests Plug-in
diff --git a/org.eclipse.tracecompass.lttng2.control.ui.tests/pom.xml b/org.eclipse.tracecompass.lttng2.control.ui.tests/pom.xml
deleted file mode 100644 (file)
index 0399b20..0000000
+++ /dev/null
@@ -1,45 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-   Copyright (C) 2011, Red Hat, Inc.
-
-   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
--->
-<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>
-    <artifactId>org.eclipse.tracecompass</artifactId>
-    <groupId>org.eclipse.tracecompass</groupId>
-    <version>1.0.0-SNAPSHOT</version>
-  </parent>
-
-  <artifactId>org.eclipse.tracecompass.lttng2.control.ui.tests</artifactId>
-  <version>1.0.0-SNAPSHOT</version>
-  <packaging>eclipse-test-plugin</packaging>
-
-  <name>Trace Compass LTTng Control UI Tests Plug-in</name>
-
- <build>
-     <plugins>
-      <plugin>
-        <groupId>org.eclipse.tycho</groupId>
-        <artifactId>tycho-surefire-plugin</artifactId>
-        <version>${tycho-version}</version>
-        <configuration>
-          <testSuite>org.eclipse.tracecompass.lttng2.control.ui.tests</testSuite>
-          <testClass>org.eclipse.tracecompass.lttng2.control.ui.tests.AllTests</testClass>
-          <useUIHarness>true</useUIHarness>
-          <useUIThread>true</useUIThread>
-          <argLine>${tycho.testArgLine} ${base.ui.test.vmargs}</argLine>
-          <product>org.eclipse.platform.ide</product>
-        </configuration>
-      </plugin>
-    </plugins>
-  </build>
-
- <groupId>org.eclipse.tracecompass</groupId>
-</project>
diff --git a/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/ActivatorTest.java b/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/ActivatorTest.java
deleted file mode 100644 (file)
index a9f05de..0000000
+++ /dev/null
@@ -1,60 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Francois Chouinard - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.control.ui.tests;
-
-import static org.junit.Assert.assertTrue;
-
-import org.junit.Test;
-
-/**
- * Test suite for the Activator class
- */
-public class ActivatorTest {
-
-    // ------------------------------------------------------------------------
-    // Tests
-    // ------------------------------------------------------------------------
-
-    /**
-     * Test method for {@link org.eclipse.tracecompass.internal.lttng2.control.ui.Activator#Activator}.
-     */
-    @Test
-    public void testActivator() {
-        assertTrue(true);
-    }
-
-    /**
-     * Test method for {@link org.eclipse.tracecompass.internal.lttng2.control.ui.Activator#getDefault}.
-     */
-    @Test
-    public void testGetDefault() {
-        assertTrue(true);
-    }
-
-    /**
-     * Test method for {@link org.eclipse.tracecompass.internal.lttng2.control.ui.Activator#start}.
-     */
-    @Test
-    public void testStartBundleContext() {
-        assertTrue(true);
-    }
-
-    /**
-     * Test method for {@link org.eclipse.tracecompass.internal.lttng2.control.ui.Activator#stop}.
-     */
-    @Test
-    public void testStopBundleContext() {
-        assertTrue(true);
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/AllTests.java b/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/AllTests.java
deleted file mode 100644 (file)
index fdc59a1..0000000
+++ /dev/null
@@ -1,30 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Francois Chouinard - Initial API and implementation
- *   Alexandre Montplaisir - Port to JUnit4
- *******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.control.ui.tests;
-
-import org.junit.runner.RunWith;
-import org.junit.runners.Suite;
-
-/**
- * Runner for the test suite
- */
-@RunWith(Suite.class)
-@Suite.SuiteClasses({
-    ActivatorTest.class,
-    org.eclipse.tracecompass.lttng2.control.ui.tests.model.component.AllTests.class,
-    org.eclipse.tracecompass.lttng2.control.ui.tests.service.AllTests.class
-})
-public class AllTests {
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/AllTests.java b/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/AllTests.java
deleted file mode 100644 (file)
index e6f2315..0000000
+++ /dev/null
@@ -1,39 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2011, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Alexandre Montplaisir - Port to JUnit4
- *******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.control.ui.tests.model.component;
-
-import org.junit.runner.RunWith;
-import org.junit.runners.Suite;
-
-/**
- * Runner for the model.component unit tests.
- */
-@RunWith(Suite.class)
-@Suite.SuiteClasses({
-    TraceControlComponentTest.class,
-    TraceControlCreateSessionTests.class,
-    TraceControlCreateSessionMiTests.class,
-    TraceControlKernelProviderTests.class,
-    TraceControlKernelSessionTests.class,
-    TraceControlPropertiesTest.class,
-    TraceControlTreeModelNoProvidersTest.class,
-    TraceControlTreeModelTest.class,
-    TraceControlUstProviderTests.class,
-    TraceControlUstSessionTests.class,
-    TraceControlUstSessionTests2.class,
-    TraceControlSnapshotSessionTests.class
-})
-public class AllTests {
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/ListenerValidator.java b/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/ListenerValidator.java
deleted file mode 100644 (file)
index 0dc5b11..0000000
+++ /dev/null
@@ -1,94 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.lttng2.control.ui.tests.model.component;
-
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponentChangedListener;
-
-/**
- * The class can be used to validate the listener interface.
- */
-@SuppressWarnings("javadoc")
-public class ListenerValidator implements ITraceControlComponentChangedListener {
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-    private boolean fisAddedCalled = false;
-    private boolean fisRemoveCalled = false;
-    private boolean fisChangedCalled = false;
-
-    private ITraceControlComponent fParent = null;
-    private ITraceControlComponent fChild = null;
-    private ITraceControlComponent fChangedComponent = null;
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-    public boolean isAddedCalled() {
-        return fisAddedCalled;
-    }
-
-    public boolean isRemovedCalled() {
-        return fisRemoveCalled;
-    }
-
-    public boolean isChangedCalled() {
-        return fisChangedCalled;
-    }
-
-    public ITraceControlComponent getSavedParent() {
-        return fParent;
-    }
-
-    public ITraceControlComponent getSavedChild() {
-        return fChild;
-    }
-
-    public ITraceControlComponent getSavedComponent() {
-        return fChangedComponent;
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-    public void initialize() {
-        fisAddedCalled = false;
-        fisRemoveCalled = false;
-        fisChangedCalled = false;
-        fParent = null;
-        fChild = null;
-        fChangedComponent = null;
-    }
-
-    @Override
-    public void componentAdded(ITraceControlComponent parent, ITraceControlComponent component) {
-        fisAddedCalled = true;
-        fParent = parent;
-        fChild = component;
-    }
-
-    @Override
-    public void componentRemoved(ITraceControlComponent parent, ITraceControlComponent component) {
-        fisRemoveCalled = true;
-        fParent = parent;
-        fChild = component;
-    }
-
-    @Override
-    public void componentChanged(ITraceControlComponent component) {
-        fisChangedCalled = true;
-        fParent = null;
-        fChangedComponent = component;
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlComponentTest.java b/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlComponentTest.java
deleted file mode 100644 (file)
index 2ddb6e9..0000000
+++ /dev/null
@@ -1,544 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Alexandre Montplaisir - Port to JUnit4
- **********************************************************************/
-
-package org.eclipse.tracecompass.lttng2.control.ui.tests.model.component;
-
-import static org.junit.Assert.assertEquals;
-import static org.junit.Assert.assertFalse;
-import static org.junit.Assert.assertNotNull;
-import static org.junit.Assert.assertTrue;
-
-import java.util.LinkedList;
-import java.util.List;
-
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.remote.core.IRemoteConnection;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TargetNodeState;
-import org.eclipse.tracecompass.internal.lttng2.control.stubs.service.TestRemoteSystemProxy;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponentChangedListener;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceControlComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceControlRoot;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.service.ILttngControlService;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.service.LTTngControlService;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.service.LTTngControlServiceConstants;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.service.LTTngControlServiceMI;
-import org.eclipse.tracecompass.tmf.remote.core.proxy.TmfRemoteConnectionFactory;
-import org.eclipse.ui.ISharedImages;
-import org.eclipse.ui.PlatformUI;
-import org.junit.Test;
-
-/**
- * The class <code>TraceControlComponentTest</code> contains tests for the class
- * <code>{@link TraceControlComponent}</code>.
- */
-public class TraceControlComponentTest {
-
-    private IRemoteConnection fHost = TmfRemoteConnectionFactory.getLocalConnection();
-
-    /**
-     * Run the TraceControlComponent(String) constructor test.
-     */
-    @Test
-    public void testTraceControlComponent_1() {
-
-        String name = "node";
-
-        TraceControlComponent result = new TraceControlComponent(name);
-
-        assertNotNull(result);
-        assertEquals(name, result.getName());
-        assertEquals(null, result.getParent());
-        assertEquals(false, result.hasChildren());
-        assertEquals(null, result.getImage());
-        assertEquals(null, result.getControlService());
-        assertEquals(null, result.getToolTip());
-    }
-
-    /**
-     * Run the TraceControlComponent(String,ITraceControlComponent) constructor test.
-     */
-    @Test
-    public void testTraceControlComponent_2() {
-        String name = "node";
-
-        ITraceControlComponent parent = new TraceControlRoot();
-        TraceControlComponent result = new TraceControlComponent(name, parent);
-
-        assertNotNull(result);
-        assertEquals(name, result.getName());
-        assertEquals(false, result.hasChildren());
-        assertEquals(null, result.getImage());
-        assertEquals(null, result.getControlService());
-        assertEquals(null, result.getToolTip());
-    }
-
-    /**
-     * Run the void addChild(ITraceControlComponent) method test.
-     */
-    @Test
-    public void testAddAndGetChild1() {
-        TraceControlComponent fixture = new TraceControlComponent("node", new TraceControlRoot());
-        fixture.setToolTip("This is the test node");
-        fixture.addChild(new TraceControlRoot());
-        ITraceControlComponent component = new TraceControlRoot();
-        fixture.addChild(component);
-
-        ITraceControlComponent child = fixture.getChild(TraceControlRoot.TRACE_CONTROL_ROOT_NAME);
-        assertNotNull(child);
-        assertEquals(TraceControlRoot.TRACE_CONTROL_ROOT_NAME, child.getName());
-    }
-
-    /**
-     * Run the void addChild(ITraceControlComponent) method test.
-     */
-    @Test
-    public void testAddAndGetChild2() {
-        TraceControlComponent fixture = new TraceControlComponent("", new TraceControlRoot());
-        fixture.setToolTip("");
-        ITraceControlComponent component = null;
-
-        fixture.addChild(component);
-        assertFalse(fixture.hasChildren());
-    }
-
-    /**
-     * Run the void addComponentListener(ITraceControlComponentChangedListener) method test.
-     */
-    @Test
-    public void testAddComponentListener_1() {
-        TraceControlComponent fixture = new TraceControlComponent("", (ITraceControlComponent) null);
-        fixture.setToolTip("");
-
-        ListenerValidator validator = new ListenerValidator();
-        fixture.addComponentListener(validator);
-
-        TraceControlRoot root = new TraceControlRoot();
-        fixture.addChild(root);
-        assertTrue(validator.isAddedCalled());
-
-        fixture.removeChild(root);
-        assertTrue(validator.isRemovedCalled());
-
-        fixture.fireComponentChanged(fixture);
-        assertTrue(validator.isChangedCalled());
-    }
-
-    /**
-     * Run the boolean containsChild(String) method test.
-     */
-    @Test
-    public void testContainsChild_1() {
-        TraceControlComponent fixture = new TraceControlComponent("", new TraceControlRoot());
-        fixture.setToolTip("");
-        fixture.addChild(new TraceControlRoot());
-        String name = "node";
-
-        boolean result = fixture.containsChild(name);
-
-        assertEquals(false, result);
-    }
-
-    /**
-     * Run the boolean containsChild(String) method test.
-     */
-    @Test
-    public void testContainsChild_2() {
-        TraceControlComponent fixture = new TraceControlComponent("name", new TraceControlRoot());
-        fixture.setToolTip("");
-
-        boolean result = fixture.containsChild(TraceControlRoot.TRACE_CONTROL_ROOT_NAME);
-
-        assertEquals(false, result);
-    }
-
-    /**
-     * Run the void fireCompenentAdded(ITraceControlComponent,ITraceControlComponent) method test.
-     * Run the void fireCompenentRemoved(ITraceControlComponent,ITraceControlComponent) method test.
-     * Run the void fireCompenentChanged(ITraceControlComponent) method test
-     */
-    @Test
-    public void testFireCompenentUpdated() {
-        ITraceControlComponent parent = new TraceControlRoot();
-
-        TraceControlComponent fixture = new TraceControlComponent("node", parent);
-        fixture.setToolTip("");
-
-        ITraceControlComponent component = new TraceControlComponent("child");
-        fixture.addChild(component);
-
-        ListenerValidator validator = new ListenerValidator();
-        fixture.addComponentListener(validator);
-
-        fixture.fireComponentAdded(parent, component);
-        assertTrue(validator.isAddedCalled());
-        assertEquals(parent.getName(), validator.getSavedParent().getName());
-        assertEquals(component.getName(), validator.getSavedChild().getName());
-
-        validator.initialize();
-
-        fixture.fireComponentRemoved(parent, component);
-        assertTrue(validator.isRemovedCalled());
-        assertEquals(parent.getName(), validator.getSavedParent().getName());
-        assertEquals(component.getName(), validator.getSavedChild().getName());
-
-        validator.initialize();
-        fixture.fireComponentChanged(fixture);
-        assertTrue(validator.isChangedCalled());
-        assertEquals(fixture.getName(), validator.getSavedComponent().getName());
-    }
-
-    /**
-     * Run the Object getAdapter(Class) method test.
-     */
-    @Test
-    public void testGetAdapter() {
-        TraceControlComponent fixture = new TraceControlComponent("", new TraceControlRoot());
-        fixture.setToolTip("");
-        fixture.addChild(new TraceControlRoot());
-        Class<Object> adapter = Object.class;
-
-        Object result = fixture.getAdapter(adapter);
-
-        assertEquals(null, result);
-    }
-
-    /**
-     * Run the ITraceControlComponent[] getChildren() method test.
-     */
-    @Test
-    public void testGetChildren_1() {
-        TraceControlComponent fixture = new TraceControlComponent("", new TraceControlRoot());
-        fixture.setToolTip("");
-        fixture.addChild(new TraceControlRoot());
-
-        ITraceControlComponent[] result = fixture.getChildren();
-
-        assertNotNull(result);
-        assertEquals(1, result.length);
-        assertNotNull(result[0]);
-        assertEquals("trace_control_root", result[0].getName());
-        assertEquals(null, result[0].getParent());
-        assertEquals(false, result[0].hasChildren());
-        assertEquals(null, result[0].getImage());
-        assertEquals(null, result[0].getControlService());
-        assertEquals(null, result[0].getToolTip());
-    }
-
-    /**
-     * Run the ILttngControlService getControlService()/setControlService()
-     * method test.
-     *
-     * @throws ExecutionException
-     *             Would fail the test
-     */
-    @Test
-    public void testGetAndSetControlService_1() throws ExecutionException {
-
-        TraceControlComponent parent = new TraceControlComponent("parent") {
-            ILttngControlService fService = null;
-
-            @Override
-            public void setControlService(ILttngControlService service ) {
-                fService = service;
-            }
-
-            @Override
-            public ILttngControlService getControlService() {
-                return fService;
-            }
-        };
-
-        TraceControlComponent fixture = new TraceControlComponent("", parent);
-        parent.addChild(fixture);
-        fixture.setToolTip("");
-        TraceControlComponent child = new TraceControlComponent("child", fixture);
-        fixture.addChild(child);
-
-        ILttngControlService result = fixture.getControlService();
-        assertEquals(null, result);
-
-        TestRemoteSystemProxy proxy = new TestRemoteSystemProxy(fHost);
-        ILttngControlService service = new LTTngControlService(proxy.createCommandShell());
-        fixture.setControlService(service);
-        result = fixture.getControlService();
-        assertNotNull(service);
-        assertEquals(service, result);
-
-        service = new LTTngControlServiceMI(proxy.createCommandShell(), LTTngControlServiceMI.class.getResource(LTTngControlServiceConstants.MI_XSD_FILENAME));
-        fixture.setControlService(service);
-        result = fixture.getControlService();
-        assertNotNull(service);
-        assertEquals(service, result);
-
-        result = fixture.getChildren()[0].getControlService();
-        assertNotNull(service);
-        assertEquals(service, result);
-    }
-
-    /**
-     * Run the Image getImage() method test.
-     */
-    @Test
-    public void testGetImage_1() {
-        TraceControlComponent fixture = new TraceControlComponent("", new TraceControlRoot());
-        fixture.setToolTip("");
-        fixture.addChild(new TraceControlRoot());
-
-        Image result = fixture.getImage();
-        assertEquals(null, result);
-
-        fixture.setImage(PlatformUI.getWorkbench().getSharedImages().getImage(ISharedImages.IMG_OBJ_FOLDER));
-        assertNotNull(fixture.getImage());
-    }
-
-    /**
-     * Run the boolean hasChildren() method test.
-     */
-    @Test
-    public void testHasChildren_1() {
-        TraceControlComponent fixture = new TraceControlComponent("", new TraceControlRoot());
-        fixture.setToolTip("");
-        fixture.addChild(new TraceControlRoot());
-
-        boolean result = fixture.hasChildren();
-
-        assertTrue(result);
-    }
-
-    /**
-     * Run the boolean hasChildren() method test.
-     */
-    @Test
-    public void testHasChildren_2() {
-        TraceControlComponent fixture = new TraceControlComponent("", new TraceControlRoot());
-        fixture.setToolTip("");
-
-        boolean result = fixture.hasChildren();
-
-        assertFalse(result);
-    }
-
-    /**
-     * Run the void removeAllChildren() method test.
-     */
-    @Test
-    public void testRemoveAllChildren_2() {
-        TraceControlComponent fixture = new TraceControlComponent("", new TraceControlRoot());
-        fixture.setToolTip("");
-
-        fixture.addChild(new TraceControlRoot());
-        fixture.addChild(new TraceControlComponent("child"));
-
-        fixture.removeAllChildren();
-        assertFalse(fixture.hasChildren());
-    }
-
-    /**
-     * Run the void removeChild(ITraceControlComponent) method test.
-     */
-    @Test
-    public void testRemoveChild_1() {
-        TraceControlComponent fixture = new TraceControlComponent("", new TraceControlRoot());
-        fixture.setToolTip("");
-        TraceControlComponent child = new TraceControlComponent("child", fixture);
-
-        fixture.addChild(child);
-        fixture.removeChild(child);
-        assertFalse(fixture.hasChildren());
-    }
-
-    /**
-     * Run the void removeChild(ITraceControlComponent) method test.
-     */
-    @Test
-    public void testRemoveChild_2() {
-        TraceControlComponent fixture = new TraceControlComponent("", new TraceControlRoot());
-        fixture.setToolTip("");
-        fixture.addChild(new TraceControlRoot());
-        ITraceControlComponent component = null;
-
-        fixture.removeChild(component);
-        assertTrue(fixture.hasChildren());
-    }
-
-    /**
-     * Run the void removeComponentListener(ITraceControlComponentChangedListener) method test.
-     */
-    @Test
-    public void testRemoveComponentListener_1() {
-        TraceControlComponent fixture = new TraceControlComponent("", (ITraceControlComponent) null);
-        fixture.setToolTip("");
-
-        ListenerValidator validator = new ListenerValidator();
-        fixture.addComponentListener(validator);
-
-        // Remove listener and check that validator is not called anymore
-        validator.initialize();
-        fixture.removeComponentListener(validator);
-        TraceControlRoot root = new TraceControlRoot();
-        fixture.addChild(root);
-        assertFalse(validator.isAddedCalled());
-
-        fixture.removeChild(root);
-        assertFalse(validator.isRemovedCalled());
-
-        fixture.fireComponentChanged(fixture);
-        assertFalse(validator.isChangedCalled());
-    }
-
-    /**
-     * Run the void removeComponentListener(ITraceControlComponentChangedListener) method test.
-     */
-    @Test
-    public void testRemoveComponentListener_2() {
-        TraceControlComponent fixture = new TraceControlComponent("", new TraceControlRoot());
-        fixture.setToolTip("");
-        fixture.addChild(new TraceControlRoot());
-        ITraceControlComponentChangedListener listener = new ControlView();
-
-        fixture.removeComponentListener(listener);
-
-    }
-
-    /**
-     * Run the void setChildren(List<ITraceControlComponent>)/ITraceControlComponent[] getChildren() method test.
-     */
-    @Test
-    public void testGetAndSetChildren() {
-        TraceControlComponent fixture = new TraceControlComponent("", new TraceControlRoot());
-        fixture.setToolTip("");
-        List<ITraceControlComponent> children = new LinkedList<>();
-        children.add(new TraceControlComponent("child1"));
-        children.add(new TraceControlComponent("child2"));
-
-        fixture.setChildren(children);
-
-        ITraceControlComponent[] result = fixture.getChildren();
-        assertEquals(2, result.length);
-        assertEquals("child1", result[0].getName());
-        assertEquals("child2", result[1].getName());
-    }
-
-    /**
-     * Run the void String getName()/setName(String) method tests.
-     */
-    @Test
-    public void testGetAndSetName() {
-        TraceControlComponent fixture = new TraceControlComponent("", new TraceControlRoot());
-        fixture.setToolTip("");
-        fixture.addChild(new TraceControlRoot());
-        String name = "node";
-
-        fixture.setName(name);
-        assertEquals(name,fixture.getName());
-
-    }
-
-    /**
-     * Run the void ITraceControlComponent getParent()/setParent(ITraceControlComponent) method tests.
-     */
-    @Test
-    public void testGetAndSetParent() {
-        TraceControlComponent fixture = new TraceControlComponent("", new TraceControlRoot());
-        fixture.setToolTip("");
-        fixture.addChild(new TraceControlRoot());
-        ITraceControlComponent parent = new TraceControlRoot();
-        parent.addChild(fixture);
-
-        fixture.setParent(parent);
-        ITraceControlComponent retrievedParent = fixture.getParent();
-        assertNotNull(retrievedParent);
-        assertEquals(parent.getName(), retrievedParent.getName());
-        assertEquals(TraceControlRoot.TRACE_CONTROL_ROOT_NAME, retrievedParent.getName());
-        assertEquals(null, retrievedParent.getParent());
-        assertEquals(true, retrievedParent.hasChildren());
-    }
-
-    /**
-     * Run the void TargetNodeState getTargetNodeState()/etTargetNodeState(TargetNodeState) method tests.
-     */
-    @Test
-    public void testGetAndSetTargetNodeState_1() {
-        TraceControlComponent parent = new TraceControlComponent("parent") {
-            private TargetNodeState fState;
-
-            @Override
-            public void setTargetNodeState(TargetNodeState state ) {
-                fState = state;
-            }
-
-            @Override
-            public TargetNodeState getTargetNodeState() {
-                return fState;
-            }
-        };
-
-        TraceControlComponent fixture = new TraceControlComponent("", parent);
-        parent.addChild(fixture);
-
-        fixture.setToolTip("");
-        TargetNodeState state = TargetNodeState.CONNECTED;
-
-        fixture.setTargetNodeState(state);
-        TargetNodeState result = fixture.getTargetNodeState();
-
-        assertNotNull(result);
-        assertEquals(state, result);
-        // Check also parent
-        assertEquals(state, fixture.getParent().getTargetNodeState());
-        assertEquals("CONNECTED", result.name());
-        assertEquals("CONNECTED", result.toString());
-        assertEquals(2, result.ordinal());
-
-        fixture.setTargetNodeState(TargetNodeState.DISCONNECTED);
-        result = fixture.getTargetNodeState();
-        assertNotNull(result);
-        assertEquals("DISCONNECTED", result.name());
-        assertEquals("DISCONNECTED", result.toString());
-        assertEquals(0, result.ordinal());
-
-        state = TargetNodeState.CONNECTING;
-
-        fixture.setTargetNodeState(state);
-        result = fixture.getTargetNodeState();
-        assertNotNull(result);
-        assertEquals("CONNECTING", result.name());
-        assertEquals("CONNECTING", result.toString());
-        assertEquals(3, result.ordinal());
-
-        fixture.setTargetNodeState(TargetNodeState.DISCONNECTING);
-        result = fixture.getTargetNodeState();
-        assertNotNull(result);
-        assertEquals("DISCONNECTING", result.name());
-        assertEquals("DISCONNECTING", result.toString());
-        assertEquals(1, result.ordinal());
-
-    }
-
-    /**
-     * Run the void setToolTip(String) method test.
-     */
-    @Test
-    public void testGetSndSetToolTip() {
-        TraceControlComponent fixture = new TraceControlComponent("", new TraceControlRoot());
-        fixture.setToolTip("This is a tooltip");
-        fixture.addChild(new TraceControlRoot());
-
-        String result = fixture.getToolTip();
-
-        assertEquals("This is a tooltip", result);
-    }
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlCreateSessionMiTests.java b/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlCreateSessionMiTests.java
deleted file mode 100644 (file)
index 8710336..0000000
+++ /dev/null
@@ -1,27 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014 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:
- *   Jonathan Rajotte - Support for machine interface LTTng 2.6
- **********************************************************************/
-
-package org.eclipse.tracecompass.lttng2.control.ui.tests.model.component;
-
-/**
- * Machine interface Kernel session manipulation handling test cases.
- * LTTng 2.6
- */
-public class TraceControlCreateSessionMiTests extends TraceControlCreateSessionTests {
-
-    private static final String TEST_STREAM = "CreateSessionTestMi.cfg";
-
-    @Override
-    protected String getTestStream() {
-        return TEST_STREAM;
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlCreateSessionTests.java b/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlCreateSessionTests.java
deleted file mode 100644 (file)
index 787684d..0000000
+++ /dev/null
@@ -1,280 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2013, 2015 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Jonathan Rajotte - Support for LTTng 2.6
- *   Markus Schorn - Bug 448058: Use org.eclipse.remote in favor of RSE
- **********************************************************************/
-
-package org.eclipse.tracecompass.lttng2.control.ui.tests.model.component;
-
-import static org.junit.Assert.assertEquals;
-import static org.junit.Assert.assertNotNull;
-import static org.junit.Assert.assertTrue;
-
-import java.io.File;
-import java.net.URL;
-
-import org.eclipse.core.runtime.FileLocator;
-import org.eclipse.core.runtime.Path;
-import org.eclipse.jdt.annotation.NonNull;
-import org.eclipse.remote.core.IRemoteConnection;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TargetNodeState;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
-import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.CreateSessionDialogStub;
-import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.DestroyConfirmDialogStub;
-import org.eclipse.tracecompass.internal.lttng2.control.stubs.service.TestRemoteSystemProxy;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.TraceControlDialogFactory;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.service.ILttngControlService;
-import org.eclipse.tracecompass.tmf.remote.core.proxy.TmfRemoteConnectionFactory;
-import org.junit.After;
-import org.junit.Before;
-import org.junit.Test;
-import org.osgi.framework.FrameworkUtil;
-
-/**
- * The class {@link TraceControlKernelSessionTests} contains Kernel
- * session/channel/event handling test cases.
- */
-public class TraceControlCreateSessionTests {
-
-    // ------------------------------------------------------------------------
-    // Constants
-    // ------------------------------------------------------------------------
-    private static final String TEST_STREAM = "CreateSessionTest.cfg";
-    private static final String SCEN_SCENARIO_FILE_PROTO_TEST = "CreateSessionFileProto";
-    private static final String SCEN_SCENARIO_CONTROL_DATA_TEST = "CreateSessionControlData";
-    private static final String SCEN_SCENARIO_NETWORK_TEST = "CreateSessionNetwork";
-    private static final String SCEN_SCENARIO_NETWORK2_TEST = "CreateSessionNetwork2";
-
-    private static final String SESSION = "mysession";
-
-    // ------------------------------------------------------------------------
-    // Test data
-    // ------------------------------------------------------------------------
-    private TraceControlTestFacility fFacility;
-    private IRemoteConnection fHost = TmfRemoteConnectionFactory.getLocalConnection();
-    private @NonNull TestRemoteSystemProxy fProxy = new TestRemoteSystemProxy(fHost);
-    private String fTestFile;
-
-    // ------------------------------------------------------------------------
-    // Housekeeping
-    // ------------------------------------------------------------------------
-
-    /**
-     * Perform pre-test initialization.
-     *
-     * @throws Exception
-     *             if the initialization fails for some reason
-     */
-    @Before
-    public void setUp() throws Exception {
-        fFacility = TraceControlTestFacility.getInstance();
-        fFacility.init();
-        URL location = FileLocator.find(FrameworkUtil.getBundle(this.getClass()), new Path(TraceControlTestFacility.DIRECTORY + File.separator + getTestStream()), null);
-        File testfile = new File(FileLocator.toFileURL(location).toURI());
-        fTestFile = testfile.getAbsolutePath();
-    }
-
-    /**
-     * Get the test stream file name to use for the test suite
-     *
-     * @return the name of the test stream file
-     */
-    protected String getTestStream() {
-        return TEST_STREAM;
-    }
-
-    /**
-     * Perform post-test clean-up.
-     */
-    @After
-    public void tearDown() {
-        fFacility.waitForJobs();
-    }
-
-    /**
-     * Run the TraceControlComponent.
-     *
-     * @throws Exception
-     *             on internal error
-     */
-    @Test
-    public void testTraceSessionTree() throws Exception {
-
-        fProxy.setTestFile(fTestFile);
-        fProxy.setScenario(TraceControlTestFacility.SCEN_INIT_TEST);
-
-        ITraceControlComponent root = TraceControlTestFacility.getInstance().getControlView().getTraceControlRoot();
-
-        TargetNodeComponent node = new TargetNodeComponent("myNode", root, fProxy);
-
-        root.addChild(node);
-        fFacility.waitForJobs();
-
-        fFacility.executeCommand(node, "connect");
-        int i = 0;
-        while ((i < 10) && (node.getTargetNodeState() != TargetNodeState.CONNECTED)) {
-            i++;
-            fFacility.delay(TraceControlTestFacility.GUI_REFESH_DELAY);
-        }
-
-        // Verify that node is connected
-        assertEquals(TargetNodeState.CONNECTED, node.getTargetNodeState());
-
-        ILttngControlService controleService = node.getControlService();
-
-        // Get provider groups
-        ITraceControlComponent[] groups = node.getChildren();
-        assertNotNull(groups);
-        assertEquals(2, groups.length);
-
-        // Initialize dialog implementations for command execution
-        CreateSessionDialogStub sessionDialogStub = new CreateSessionDialogStub();
-        TraceControlDialogFactory.getInstance().setCreateSessionDialog(sessionDialogStub);
-        TraceControlDialogFactory.getInstance().setConfirmDialog(new DestroyConfirmDialogStub());
-
-        // ------------------------------------------------------------------------
-        // Create session (--U file://...) and destroy
-        // ------------------------------------------------------------------------
-        // Initialize session handling scenario
-        fProxy.setScenario(SCEN_SCENARIO_FILE_PROTO_TEST);
-
-        sessionDialogStub.setNetworkUrl("file:///tmp");
-        sessionDialogStub.setStreamedTrace(true);
-        TraceSessionComponent session = fFacility.createSession(groups[1]);
-
-        // Verify that session was created
-        assertNotNull(session);
-        assertEquals(getSessionName(), session.getName());
-        if (controleService.isVersionSupported("2.6.0")) {
-            assertEquals("/tmp", session.getSessionPath());
-        } else {
-            assertEquals("file:///tmp", session.getSessionPath());
-        }
-
-        assertTrue(!session.isStreamedTrace());
-        assertEquals(TraceSessionState.INACTIVE, session.getSessionState());
-        sessionDialogStub.setNetworkUrl(null);
-        sessionDialogStub.setStreamedTrace(false);
-
-        fFacility.destroySession(session);
-
-        // Verify that no more session components exist
-        assertEquals(0, groups[1].getChildren().length);
-
-        // ------------------------------------------------------------------------
-        // Create session (--U file://,,, and destroy
-        // ------------------------------------------------------------------------
-        // Initialize session handling scenario
-        fProxy.setScenario(SCEN_SCENARIO_CONTROL_DATA_TEST);
-
-        sessionDialogStub.setControlUrl("tcp://172.0.0.1");
-        sessionDialogStub.setDataUrl("tcp://172.0.0.1:5343");
-        sessionDialogStub.setStreamedTrace(true);
-
-        session = fFacility.createSession(groups[1]);
-
-        // Verify that session was created
-        assertNotNull(session);
-        assertEquals(getSessionName(), session.getName());
-        if (controleService.isVersionSupported("2.6.0")) {
-            assertEquals("tcp4://172.0.0.1:5342/ [data: 5343]", session.getSessionPath());
-        } else {
-            assertEquals("tcp://172.0.0.1:5342 [data: 5343]", session.getSessionPath());
-        }
-        assertTrue(session.isStreamedTrace());
-        assertEquals(TraceSessionState.INACTIVE, session.getSessionState());
-        sessionDialogStub.setControlUrl(null);
-        sessionDialogStub.setDataUrl(null);
-        sessionDialogStub.setStreamedTrace(false);
-
-        fFacility.destroySession(session);
-
-        // Verify that no more session components exist
-        assertEquals(0, groups[1].getChildren().length);
-
-        // ------------------------------------------------------------------------
-        // Create session (--U file://... and destroy
-        // ------------------------------------------------------------------------
-        // Initialize session handling scenario
-        fProxy.setScenario(SCEN_SCENARIO_NETWORK_TEST);
-
-        sessionDialogStub.setNetworkUrl("net://172.0.0.1:1234:2345");
-        sessionDialogStub.setStreamedTrace(true);
-
-        session = fFacility.createSession(groups[1]);
-
-        // Verify that session was created
-        assertNotNull(session);
-        assertEquals(getSessionName(), session.getName());
-        if (controleService.isVersionSupported("2.6.0")) {
-            assertEquals("tcp4://172.0.0.1:1234/mysession-20140820-153527 [data: 2345]", session.getSessionPath());
-        } else {
-            assertEquals("net://172.0.0.1:1234 [data: 2345]", session.getSessionPath());
-        }
-        assertTrue(session.isStreamedTrace());
-        assertEquals(TraceSessionState.INACTIVE, session.getSessionState());
-        sessionDialogStub.setNetworkUrl(null);
-
-        fFacility.destroySession(session);
-
-        // Verify that no more session components exist
-        assertEquals(0, groups[1].getChildren().length);
-
-        // ------------------------------------------------------------------------
-        // Create session (--U net6://[...] and destroy
-        // ------------------------------------------------------------------------
-        // Initialize session handling scenario
-        fProxy.setScenario(SCEN_SCENARIO_NETWORK2_TEST);
-
-        sessionDialogStub.setNetworkUrl("net6://[ffff::eeee:dddd:cccc:0]");
-        sessionDialogStub.setStreamedTrace(true);
-
-        session = fFacility.createSession(groups[1]);
-
-        // Verify that session was created
-        assertNotNull(session);
-        assertEquals(getSessionName(), session.getName());
-        if (controleService.isVersionSupported("2.6.0")) {
-            assertEquals("tcp6://[ffff::eeee:dddd:cccc:0]:5342/mysession-20140820-153801 [data: 5343]", session.getSessionPath());
-        } else {
-            assertEquals("net://[ffff::eeee:dddd:cccc:0]:5342/mysession-20130221-144451 [data: 5343]", session.getSessionPath());
-        }
-        assertTrue(session.isStreamedTrace());
-        assertEquals(TraceSessionState.INACTIVE, session.getSessionState());
-        sessionDialogStub.setNetworkUrl(null);
-
-        fFacility.destroySession(session);
-
-        // Verify that no more session components exist
-        assertEquals(0, groups[1].getChildren().length);
-
-        // -------------------------------------------------------------------------
-        // Disconnect node
-        // -------------------------------------------------------------------------
-        fFacility.executeCommand(node, "disconnect");
-        assertEquals(TargetNodeState.DISCONNECTED, node.getTargetNodeState());
-
-        // -------------------------------------------------------------------------
-        // Delete node
-        // -------------------------------------------------------------------------
-
-        fFacility.executeCommand(node, "delete");
-        assertEquals(0, fFacility.getControlView().getTraceControlRoot().getChildren().length);
-    }
-
-    private static String getSessionName() {
-        return SESSION;
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlKernelProviderTests.java b/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlKernelProviderTests.java
deleted file mode 100644 (file)
index 7cb7a04..0000000
+++ /dev/null
@@ -1,267 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2015 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Alexandre Montplaisir - Port to JUnit4
- *   Markus Schorn - Bug 448058: Use org.eclipse.remote in favor of RSE
- **********************************************************************/
-
-package org.eclipse.tracecompass.lttng2.control.ui.tests.model.component;
-
-import static org.junit.Assert.assertEquals;
-import static org.junit.Assert.assertNotNull;
-import static org.junit.Assert.assertTrue;
-
-import java.io.File;
-import java.net.URL;
-
-import org.eclipse.core.runtime.FileLocator;
-import org.eclipse.core.runtime.Path;
-import org.eclipse.jdt.annotation.NonNull;
-import org.eclipse.remote.core.IRemoteConnection;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TargetNodeState;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceChannelOutputType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEnablement;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEventType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
-import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.CreateSessionDialogStub;
-import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.DestroyConfirmDialogStub;
-import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.GetEventInfoDialogStub;
-import org.eclipse.tracecompass.internal.lttng2.control.stubs.service.TestRemoteSystemProxy;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.TraceControlDialogFactory;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.BaseEventComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.KernelProviderComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceEventComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceProviderGroup;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
-import org.eclipse.tracecompass.tmf.remote.core.proxy.TmfRemoteConnectionFactory;
-import org.junit.After;
-import org.junit.Before;
-import org.junit.Test;
-import org.osgi.framework.FrameworkUtil;
-
-/**
- * The class <code>TraceControlKernelProviderTests</code> contains UST provider
- * handling test cases.
- */
-public class TraceControlKernelProviderTests {
-
-    // ------------------------------------------------------------------------
-    // Constants
-    // ------------------------------------------------------------------------
-
-    private static final String TEST_STREAM = "CreateTreeTest.cfg";
-    private static final String SCEN_SCENARIO1_TEST = "Scenario1";
-
-    // ------------------------------------------------------------------------
-    // Test data
-    // ------------------------------------------------------------------------
-
-    private TraceControlTestFacility fFacility;
-    private IRemoteConnection fHost = TmfRemoteConnectionFactory.getLocalConnection();
-    private @NonNull TestRemoteSystemProxy fProxy = new TestRemoteSystemProxy(fHost);
-    private String fTestFile;
-
-    // ------------------------------------------------------------------------
-    // Housekeeping
-    // ------------------------------------------------------------------------
-
-    /**
-     * Perform pre-test initialization.
-     *
-     * @throws Exception
-     *         if the initialization fails for some reason
-     */
-    @Before
-    public void setUp() throws Exception {
-        fFacility = TraceControlTestFacility.getInstance();
-        fFacility.init();
-        URL location = FileLocator.find(FrameworkUtil.getBundle(this.getClass()), new Path(TraceControlTestFacility.DIRECTORY + File.separator + TEST_STREAM), null);
-        File testfile = new File(FileLocator.toFileURL(location).toURI());
-        fTestFile = testfile.getAbsolutePath();
-    }
-
-    /**
-     * Perform post-test clean-up.
-     */
-    @After
-    public void tearDown() {
-        fFacility.waitForJobs();
-        fFacility.dispose();
-    }
-
-    /**
-     * Run the TraceControlComponent.
-     *
-     * @throws Exception
-     *             Would fail the test
-     */
-    @Test
-    public void testKernelProviderTree() throws Exception {
-
-        fProxy.setTestFile(fTestFile);
-        fProxy.setScenario(TraceControlTestFacility.SCEN_INIT_TEST);
-
-        ITraceControlComponent root = fFacility.getControlView().getTraceControlRoot();
-
-        TargetNodeComponent node = new TargetNodeComponent("myNode", root, fProxy);
-
-        root.addChild(node);
-
-        fFacility.waitForJobs();
-
-        fFacility.executeCommand(node, "connect");
-        int i = 0;
-        while ((i < 20) && (node.getTargetNodeState() != TargetNodeState.CONNECTED)) {
-            i++;
-            fFacility.delay(TraceControlTestFacility.GUI_REFESH_DELAY);
-        }
-
-        // Verify that node is connected
-        assertEquals(TargetNodeState.CONNECTED, node.getTargetNodeState());
-
-        // Get provider and session group
-        ITraceControlComponent[] groups = node.getChildren();
-        assertNotNull(groups);
-        assertEquals(2, groups.length);
-
-        // Check for kernel provider
-        TraceProviderGroup providerGroup = (TraceProviderGroup) groups[0];
-        assertTrue(providerGroup.hasKernelProvider());
-
-        // Get kernel provider
-        ITraceControlComponent[] providers = providerGroup.getChildren();
-        KernelProviderComponent kernelProvider = (KernelProviderComponent) providers[0];
-
-        // Get kernel provider events and select 2 events
-        ITraceControlComponent[] events = kernelProvider.getChildren();
-        assertNotNull(events);
-        assertEquals(3, events.length);
-
-        BaseEventComponent baseEventInfo0 = (BaseEventComponent) events[0];
-        BaseEventComponent baseEventInfo1  = (BaseEventComponent) events[1];
-
-        // Initialize dialog implementations for command execution
-        TraceControlDialogFactory.getInstance().setCreateSessionDialog(new CreateSessionDialogStub());
-        TraceControlDialogFactory.getInstance().setGetEventInfoDialog(new GetEventInfoDialogStub());
-        TraceControlDialogFactory.getInstance().setConfirmDialog(new DestroyConfirmDialogStub());
-
-        // Initialize session handling scenario
-        fProxy.setScenario(TraceControlTestFacility.SCEN_SCENARIO_SESSION_HANDLING);
-
-        // ------------------------------------------------------------------------
-        // Create session
-        // ------------------------------------------------------------------------
-        TraceSessionComponent session = fFacility.createSession(groups[1]);
-
-        // Verify that session was created
-        assertNotNull(session);
-        assertEquals("mysession", session.getName());
-        assertEquals("/home/user/lttng-traces/mysession-20120314-132824", session.getSessionPath());
-        assertEquals(TraceSessionState.INACTIVE, session.getSessionState());
-
-        // ------------------------------------------------------------------------
-        // Enable event on default channel on created session above
-        // ------------------------------------------------------------------------
-        // Initialize scenario
-        fProxy.setScenario(SCEN_SCENARIO1_TEST);
-
-        ITraceControlComponent[] components =  { baseEventInfo0, baseEventInfo1 };
-
-        fFacility.executeCommand(components, "assign.event");
-
-        // Verify that kernel domain was created
-        ITraceControlComponent[] domains = session.getChildren();
-        assertNotNull(domains);
-        assertEquals(1, domains.length);
-
-        assertEquals("Kernel", domains[0].getName());
-
-        // Verify that channel0 was created with default values
-        ITraceControlComponent[] channels =  domains[0].getChildren();
-        assertNotNull(channels);
-        assertEquals(1, channels.length);
-
-        assertTrue(channels[0] instanceof TraceChannelComponent);
-        TraceChannelComponent channel = (TraceChannelComponent) channels[0];
-        assertEquals("channel0", channel.getName());
-        assertEquals(4, channel.getNumberOfSubBuffers());
-        assertEquals("splice()", channel.getOutputType().getInName());
-        assertEquals(TraceChannelOutputType.SPLICE, channel.getOutputType());
-        assertEquals(false, channel.isOverwriteMode());
-        assertEquals(200, channel.getReadTimer());
-        assertEquals(TraceEnablement.ENABLED, channel.getState());
-        assertEquals(262144, channel.getSubBufferSize());
-        assertEquals(0, channel.getSwitchTimer());
-
-        // Verify that event components were created
-        ITraceControlComponent[] channel0Events = channel.getChildren();
-        assertNotNull(channel0Events);
-        assertEquals(2, channel0Events.length);
-        assertTrue(channel0Events[0] instanceof TraceEventComponent);
-        assertTrue(channel0Events[1] instanceof TraceEventComponent);
-
-        TraceEventComponent event = (TraceEventComponent) channel0Events[0];
-        assertEquals("sched_kthread_stop_ret", event.getName());
-        assertEquals(TraceLogLevel.TRACE_EMERG, event.getLogLevel());
-        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
-        assertEquals(TraceEnablement.ENABLED, event.getState());
-
-        TraceEventComponent event1 = (TraceEventComponent) channel0Events[1];
-        assertEquals("sched_kthread_stop", event1.getName());
-        assertEquals(TraceLogLevel.TRACE_EMERG, event1.getLogLevel());
-        assertEquals(TraceEventType.TRACEPOINT, event1.getEventType());
-        assertEquals(TraceEnablement.ENABLED, event1.getState());
-
-        // ------------------------------------------------------------------------
-        // Disable event components
-        // ------------------------------------------------------------------------
-        ITraceControlComponent[] selection = { event, event1 };
-        fFacility.executeCommand(selection, "disableEvent");
-
-        assertEquals(TraceEnablement.DISABLED, event.getState());
-        assertEquals(TraceEnablement.DISABLED, event1.getState());
-
-        // ------------------------------------------------------------------------
-        // Enable event component
-        // ------------------------------------------------------------------------
-        fFacility.executeCommand(event1, "enableEvent");
-
-        // Verify event state
-        assertEquals(TraceEnablement.ENABLED, event1.getState());
-
-        // ------------------------------------------------------------------------
-        // Destroy session
-        // ------------------------------------------------------------------------
-        // Initialize session handling scenario
-        fProxy.setScenario(TraceControlTestFacility.SCEN_SCENARIO_SESSION_HANDLING);
-
-        fFacility.destroySession(session);
-
-        // Verify that no more session components exist
-        assertEquals(0, groups[1].getChildren().length);
-
-        //-------------------------------------------------------------------------
-        // Disconnect node
-        //-------------------------------------------------------------------------
-        fFacility.executeCommand(node, "disconnect");
-        assertEquals(TargetNodeState.DISCONNECTED, node.getTargetNodeState());
-
-        //-------------------------------------------------------------------------
-        // Delete node
-        //-------------------------------------------------------------------------
-        fFacility.executeCommand(node, "delete");
-        assertEquals(0, fFacility.getControlView().getTraceControlRoot().getChildren().length);
-
-    }
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlKernelSessionTests.java b/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlKernelSessionTests.java
deleted file mode 100644 (file)
index 71b8bb7..0000000
+++ /dev/null
@@ -1,819 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2015 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Alexandre Montplaisir - Port to JUnit4
- *   Markus Schorn - Bug 448058: Use org.eclipse.remote in favor of RSE
- **********************************************************************/
-
-package org.eclipse.tracecompass.lttng2.control.ui.tests.model.component;
-
-import static org.junit.Assert.assertEquals;
-import static org.junit.Assert.assertNotNull;
-import static org.junit.Assert.assertNull;
-import static org.junit.Assert.assertTrue;
-import static org.junit.Assert.fail;
-
-import java.io.File;
-import java.net.URL;
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.core.runtime.FileLocator;
-import org.eclipse.core.runtime.Path;
-import org.eclipse.jdt.annotation.NonNull;
-import org.eclipse.remote.core.IRemoteConnection;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TargetNodeState;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceChannelOutputType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEnablement;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEventType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.ChannelInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.AddContextDialogStub;
-import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.CreateSessionDialogStub;
-import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.DestroyConfirmDialogStub;
-import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.EnableChannelDialogStub;
-import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.EnableEventsDialogStub;
-import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.GetEventInfoDialogStub;
-import org.eclipse.tracecompass.internal.lttng2.control.stubs.service.TestRemoteSystemProxy;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.TraceControlDialogFactory;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceEventComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceProbeEventComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
-import org.eclipse.tracecompass.tmf.remote.core.proxy.TmfRemoteConnectionFactory;
-import org.junit.After;
-import org.junit.Before;
-import org.junit.Test;
-import org.osgi.framework.FrameworkUtil;
-
-/**
- * The class <code>TraceControlKernelSessionTests</code> contains Kernel
- * session/channel/event handling test cases.
- */
-public class TraceControlKernelSessionTests {
-
-    // ------------------------------------------------------------------------
-    // Constants
-    // ------------------------------------------------------------------------
-
-    private static final String TEST_STREAM = "CreateTreeTest.cfg";
-    private static final String SCEN_SCENARIO3_TEST = "Scenario3";
-
-    // ------------------------------------------------------------------------
-    // Test data
-    // ------------------------------------------------------------------------
-
-    private TraceControlTestFacility fFacility;
-    private IRemoteConnection fHost = TmfRemoteConnectionFactory.getLocalConnection();
-    private @NonNull TestRemoteSystemProxy fProxy = new TestRemoteSystemProxy(fHost);
-    private String fTestFile;
-
-    // ------------------------------------------------------------------------
-    // Housekeeping
-    // ------------------------------------------------------------------------
-
-    /**
-     * Perform pre-test initialization.
-     *
-     * @throws Exception
-     *         if the initialization fails for some reason
-     */
-    @Before
-    public void setUp() throws Exception {
-        fFacility = TraceControlTestFacility.getInstance();
-        fFacility.init();
-        URL location = FileLocator.find(FrameworkUtil.getBundle(this.getClass()), new Path(TraceControlTestFacility.DIRECTORY + File.separator + TEST_STREAM), null);
-        File testfile = new File(FileLocator.toFileURL(location).toURI());
-        fTestFile = testfile.getAbsolutePath();
-    }
-
-    /**
-     * Perform post-test clean-up.
-     */
-    @After
-    public void tearDown() {
-        fFacility.waitForJobs();
-        fFacility.dispose();
-    }
-
-    /**
-     * Run the TraceControlComponent.
-     *
-     * @throws Exception
-     *             Would fail the test
-     */
-    @Test
-    public void testTraceSessionTree() throws Exception {
-
-        fProxy.setTestFile(fTestFile);
-        fProxy.setScenario(TraceControlTestFacility.SCEN_INIT_TEST);
-
-        ITraceControlComponent root = fFacility.getControlView().getTraceControlRoot();
-
-        TargetNodeComponent node = new TargetNodeComponent("myNode", root, fProxy);
-
-        root.addChild(node);
-        fFacility.waitForJobs();
-
-        fFacility.executeCommand(node, "connect");
-        int i = 0;
-        while ((i < 10) && (node.getTargetNodeState() != TargetNodeState.CONNECTED)) {
-            i++;
-            fFacility.delay(TraceControlTestFacility.GUI_REFESH_DELAY);
-        }
-
-        // Verify that node is connected
-        assertEquals(TargetNodeState.CONNECTED, node.getTargetNodeState());
-
-        // Get provider groups
-        ITraceControlComponent[] groups = node.getChildren();
-        assertNotNull(groups);
-        assertEquals(2, groups.length);
-
-        // Initialize dialog implementations for command execution
-        TraceControlDialogFactory.getInstance().setCreateSessionDialog(new CreateSessionDialogStub());
-        TraceControlDialogFactory.getInstance().setGetEventInfoDialog(new GetEventInfoDialogStub());
-        TraceControlDialogFactory.getInstance().setConfirmDialog(new DestroyConfirmDialogStub());
-
-        // Initialize session handling scenario
-        fProxy.setScenario(TraceControlTestFacility.SCEN_SCENARIO_SESSION_HANDLING);
-
-        // ------------------------------------------------------------------------
-        // Create session
-        // ------------------------------------------------------------------------
-        TraceSessionComponent session = fFacility.createSession(groups[1]);
-
-        // Verify that session was created
-        assertNotNull(session);
-        assertEquals("mysession", session.getName());
-        assertEquals("/home/user/lttng-traces/mysession-20120314-132824", session.getSessionPath());
-        assertEquals(TraceSessionState.INACTIVE, session.getSessionState());
-
-        // Initialize scenario
-        fProxy.setScenario(SCEN_SCENARIO3_TEST);
-
-        // ------------------------------------------------------------------------
-        // Enable channel on session
-        // ------------------------------------------------------------------------
-        EnableChannelDialogStub channelStub = new EnableChannelDialogStub();
-        channelStub.setIsKernel(true);
-        TraceControlDialogFactory.getInstance().setEnableChannelDialog(channelStub);
-
-        fFacility.executeCommand(session, "enableChannelOnSession");
-
-        // Verify that Kernel domain was created
-        ITraceControlComponent[] domains = session.getChildren();
-        assertNotNull(domains);
-        assertEquals(1, domains.length);
-
-        assertEquals("Kernel", domains[0].getName());
-
-        // Verify that channel was created with correct data
-        ITraceControlComponent[] channels =  domains[0].getChildren();
-        assertNotNull(channels);
-        assertEquals(1, channels.length);
-
-        assertTrue(channels[0] instanceof TraceChannelComponent);
-        TraceChannelComponent channel = (TraceChannelComponent) channels[0];
-        assertEquals("mychannel", channel.getName());
-        assertEquals(4, channel.getNumberOfSubBuffers());
-        assertEquals("splice()", channel.getOutputType().getInName());
-        assertEquals(TraceChannelOutputType.SPLICE, channel.getOutputType());
-        assertEquals(true, channel.isOverwriteMode());
-        assertEquals(200, channel.getReadTimer());
-        assertEquals(TraceEnablement.ENABLED, channel.getState());
-        assertEquals(16384, channel.getSubBufferSize());
-        assertEquals(100, channel.getSwitchTimer());
-
-        // ------------------------------------------------------------------------
-        // Create channel on domain
-        // ------------------------------------------------------------------------
-        ChannelInfo info = (ChannelInfo)channelStub.getChannelInfo();
-        info.setName("mychannel2");
-        info.setOverwriteMode(false);
-        info.setSubBufferSize(32768);
-        info.setNumberOfSubBuffers(2);
-        info.setSwitchTimer(100);
-        info.setReadTimer(200);
-        channelStub.setChannelInfo(info);
-
-        fFacility.executeCommand(domains[0], "enableChannelOnDomain");
-
-        // Get Kernel domain component instance
-        domains = session.getChildren();
-        assertNotNull(domains);
-        assertEquals(1, domains.length);
-
-        // Verify that channel was created with correct data
-        channels =  domains[0].getChildren();
-        assertNotNull(channels);
-        assertEquals(2, channels.length);
-
-        assertTrue(channels[1] instanceof TraceChannelComponent);
-        channel = (TraceChannelComponent) channels[1];
-        assertEquals("mychannel2", channel.getName());
-        assertEquals(2, channel.getNumberOfSubBuffers());
-        assertEquals("splice()", channel.getOutputType().getInName());
-        assertEquals(TraceChannelOutputType.SPLICE, channel.getOutputType());
-        assertEquals(false, channel.isOverwriteMode());
-        assertEquals(200, channel.getReadTimer());
-        assertEquals(TraceEnablement.ENABLED, channel.getState());
-        assertEquals(32768, channel.getSubBufferSize());
-        assertEquals(100, channel.getSwitchTimer());
-
-        EnableEventsDialogStub eventsDialogStub = new EnableEventsDialogStub();
-        eventsDialogStub.setIsTracePoints(true);
-        List<String> events = new ArrayList<>();
-        events.add("sched_kthread_stop");
-        events.add("sched_kthread_stop_ret");
-        eventsDialogStub.setNames(events);
-        eventsDialogStub.setIsKernel(true);
-        TraceControlDialogFactory.getInstance().setEnableEventsDialog(eventsDialogStub);
-
-        // ------------------------------------------------------------------------
-        // disable channels
-        // ------------------------------------------------------------------------
-        // Get Kernel domain component instance
-        domains = session.getChildren();
-        assertNotNull(domains);
-        assertEquals(1, domains.length);
-
-        // Verify that channel was created with correct data
-        channels =  domains[0].getChildren();
-        assertNotNull(channels);
-        assertEquals(2, channels.length);
-
-        fFacility.executeCommand(channels, "disableChannel");
-
-        assertEquals(TraceEnablement.DISABLED, ((TraceChannelComponent)channels[0]).getState());
-        assertEquals(TraceEnablement.DISABLED, ((TraceChannelComponent)channels[1]).getState());
-
-        // ------------------------------------------------------------------------
-        // enable channels
-        // ------------------------------------------------------------------------
-        // Get Kernel domain component instance
-        domains = session.getChildren();
-        assertNotNull(domains);
-        assertEquals(1, domains.length);
-
-        // Verify that channel was created with correct data
-        channels =  domains[0].getChildren();
-        assertNotNull(channels);
-        assertEquals(2, channels.length);
-
-        fFacility.executeCommand(channels, "enableChannel");
-
-        assertEquals(TraceEnablement.ENABLED, ((TraceChannelComponent)channels[0]).getState());
-        assertEquals(TraceEnablement.ENABLED, ((TraceChannelComponent)channels[1]).getState());
-
-        // ------------------------------------------------------------------------
-        // enable event (tracepoints) on session
-        // ------------------------------------------------------------------------
-        fFacility.executeCommand(session, "enableEventOnSession");
-
-        // Get Kernel domain component instance
-        domains = session.getChildren();
-        assertNotNull(domains);
-        assertEquals(1, domains.length);
-
-        // Verify that channel was created with correct data
-        channels =  domains[0].getChildren();
-        assertNotNull(channels);
-        assertEquals(3, channels.length);
-
-        assertTrue(channels[2] instanceof TraceChannelComponent);
-        channel = (TraceChannelComponent) channels[2];
-        assertEquals("channel0", channel.getName());
-        // No need to check parameters of default channel because that has been done in other tests
-
-        ITraceControlComponent[] channel0Events = channel.getChildren();
-        assertEquals(2, channel0Events.length);
-
-        assertTrue(channel0Events[0] instanceof TraceEventComponent);
-        assertTrue(channel0Events[1] instanceof TraceEventComponent);
-
-        TraceEventComponent event = (TraceEventComponent) channel0Events[0];
-        assertEquals("sched_kthread_stop_ret", event.getName());
-        assertEquals(TraceLogLevel.TRACE_EMERG, event.getLogLevel());
-        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
-        assertEquals(TraceEnablement.ENABLED, event.getState());
-
-        event = (TraceEventComponent) channel0Events[1];
-        assertEquals("sched_kthread_stop", event.getName());
-        assertEquals(TraceLogLevel.TRACE_EMERG, event.getLogLevel());
-        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
-        assertEquals(TraceEnablement.ENABLED, event.getState());
-
-        // ------------------------------------------------------------------------
-        // enable event (tracepoints) on domain
-        // ------------------------------------------------------------------------
-        events.clear();
-        events.add("sched_wakeup_new");
-        eventsDialogStub.setNames(events);
-
-        fFacility.executeCommand(domains[0], "enableEventOnDomain");
-
-        // Get Kernel domain component instance
-        domains = session.getChildren();
-        assertNotNull(domains);
-        assertEquals(1, domains.length);
-
-        // Verify that channel was created with correct data
-        channels =  domains[0].getChildren();
-        channel = (TraceChannelComponent) channels[2];
-        // No need to check parameters of default channel because that has been done in other tests
-
-        channel = (TraceChannelComponent) channels[2];
-
-        channel0Events = channel.getChildren();
-        assertEquals(3, channel0Events.length);
-
-        assertTrue(channel0Events[2] instanceof TraceEventComponent);
-
-        event = (TraceEventComponent) channel0Events[2];
-        assertEquals("sched_wakeup_new", event.getName());
-        assertEquals(TraceLogLevel.TRACE_EMERG, event.getLogLevel());
-        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
-        assertEquals(TraceEnablement.ENABLED, event.getState());
-
-        // ------------------------------------------------------------------------
-        // enable event (tracepoints) on channel
-        // ------------------------------------------------------------------------
-        events.clear();
-        eventsDialogStub.setNames(events);
-        eventsDialogStub.setIsAllTracePoints(true);
-
-        fFacility.executeCommand(channels[1], "enableEventOnChannel");
-
-        // Get Kernel domain component instance
-        domains = session.getChildren();
-        assertNotNull(domains);
-        assertEquals(1, domains.length);
-
-        // Verify that channel was created with correct data
-        channels =  domains[0].getChildren();
-        // No need to check parameters of default channel because that has been done in other tests
-        channel = (TraceChannelComponent) channels[1];
-
-        channel0Events = channel.getChildren();
-        assertEquals(3, channel0Events.length);
-
-        assertTrue(channel0Events[0] instanceof TraceEventComponent);
-        assertTrue(channel0Events[1] instanceof TraceEventComponent);
-        assertTrue(channel0Events[2] instanceof TraceEventComponent);
-
-        event = (TraceEventComponent) channel0Events[0];
-        assertEquals("sched_kthread_stop_ret", event.getName());
-        assertEquals(TraceLogLevel.TRACE_EMERG, event.getLogLevel());
-        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
-        assertEquals(TraceEnablement.ENABLED, event.getState());
-
-        event = (TraceEventComponent) channel0Events[1];
-        assertEquals("sched_kthread_stop", event.getName());
-        assertEquals(TraceLogLevel.TRACE_EMERG, event.getLogLevel());
-        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
-        assertEquals(TraceEnablement.ENABLED, event.getState());
-
-        event = (TraceEventComponent) channel0Events[2];
-        assertEquals("sched_wakeup_new", event.getName());
-        assertEquals(TraceLogLevel.TRACE_EMERG, event.getLogLevel());
-        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
-        assertEquals(TraceEnablement.ENABLED, event.getState());
-
-        // ------------------------------------------------------------------------
-        // enable event (syscall) on channel
-        // ------------------------------------------------------------------------
-        events.clear();
-        eventsDialogStub.setIsTracePoints(false);
-        eventsDialogStub.setIsAllTracePoints(false);
-        eventsDialogStub.setIsSysCalls(true);
-
-        fFacility.executeCommand(channels[0], "enableEventOnChannel");
-
-        // Get Kernel domain component instance
-        domains = session.getChildren();
-        assertNotNull(domains);
-        assertEquals(1, domains.length);
-
-        // Verify that channel was created with correct data
-        channels =  domains[0].getChildren();
-        channel = (TraceChannelComponent) channels[0];
-        // No need to check parameters of default channel because that has been done in other tests
-
-        channel = (TraceChannelComponent) channels[0];
-
-        channel0Events = channel.getChildren();
-        assertEquals(1, channel0Events.length);
-
-        assertTrue(channel0Events[0] instanceof TraceEventComponent);
-
-        event = (TraceEventComponent) channel0Events[0];
-        assertEquals("syscalls", event.getName());
-        assertEquals(TraceLogLevel.LEVEL_UNKNOWN, event.getLogLevel());
-        assertEquals(TraceEventType.SYSCALL, event.getEventType());
-        assertEquals(TraceEnablement.ENABLED, event.getState());
-
-        // ------------------------------------------------------------------------
-        // enable event (syscall) on domain
-        // ------------------------------------------------------------------------
-        fFacility.executeCommand(domains[0], "enableEventOnDomain");
-
-        // Get Kernel domain component instance
-        domains = session.getChildren();
-        assertNotNull(domains);
-        assertEquals(1, domains.length);
-
-        // Verify that channel was created with correct data
-        channels =  domains[0].getChildren();
-        channel = (TraceChannelComponent) channels[0];
-        // No need to check parameters of default channel because that has been done in other tests
-
-        channel = (TraceChannelComponent) channels[2];
-
-        channel0Events = channel.getChildren();
-        assertEquals(4, channel0Events.length);
-
-        assertTrue(channel0Events[0] instanceof TraceEventComponent);
-
-        event = (TraceEventComponent) channel0Events[0];
-        assertEquals("syscalls", event.getName());
-        assertEquals(TraceLogLevel.LEVEL_UNKNOWN, event.getLogLevel());
-        assertEquals(TraceEventType.SYSCALL, event.getEventType());
-        assertEquals(TraceEnablement.ENABLED, event.getState());
-
-        // ------------------------------------------------------------------------
-        // enable event (syscall) on session
-        // ------------------------------------------------------------------------
-        fFacility.executeCommand(session, "enableEventOnSession");
-
-        // Get Kernel domain component instance
-        domains = session.getChildren();
-        assertNotNull(domains);
-        assertEquals(1, domains.length);
-
-        // Verify that channel was created with correct data
-        channels =  domains[0].getChildren();
-        channel = (TraceChannelComponent) channels[0];
-        // No need to check parameters of default channel because that has been done in other tests
-
-        channel = (TraceChannelComponent) channels[2];
-
-        channel0Events = channel.getChildren();
-        assertEquals(4, channel0Events.length);
-
-        assertTrue(channel0Events[0] instanceof TraceEventComponent);
-
-        event = (TraceEventComponent) channel0Events[0];
-        assertEquals("syscalls", event.getName());
-        assertEquals(TraceLogLevel.LEVEL_UNKNOWN, event.getLogLevel());
-        assertEquals(TraceEventType.SYSCALL, event.getEventType());
-        assertEquals(TraceEnablement.ENABLED, event.getState());
-
-
-        // ------------------------------------------------------------------------
-        // enable event (dynamic probe) on domain
-        // ------------------------------------------------------------------------
-        events.clear();
-        eventsDialogStub.setIsSysCalls(false);
-        eventsDialogStub.setIsDynamicProbe(true);
-        eventsDialogStub.setDynamicProbe("0xc0101280");
-        eventsDialogStub.setProbeEventName("myevent1");
-
-        fFacility.executeCommand(domains[0], "enableEventOnDomain");
-
-        // Get Kernel domain component instance
-        domains = session.getChildren();
-        assertNotNull(domains);
-        assertEquals(1, domains.length);
-
-        // Verify that channel was created with correct data
-        channels =  domains[0].getChildren();
-        channel = (TraceChannelComponent) channels[2];
-        // No need to check parameters of default channel because that has been done in other tests
-
-        channel0Events = channel.getChildren();
-        assertEquals(5, channel0Events.length);
-
-        assertTrue(channel0Events[0] instanceof TraceProbeEventComponent);
-
-        TraceProbeEventComponent probeEvent = (TraceProbeEventComponent) channel0Events[0];
-        assertEquals("myevent1", probeEvent.getName());
-        assertEquals(TraceLogLevel.LEVEL_UNKNOWN, probeEvent.getLogLevel());
-        assertEquals(TraceEventType.PROBE, probeEvent.getEventType());
-        assertEquals(TraceEnablement.ENABLED, probeEvent.getState());
-        assertNull(probeEvent.getOffset());
-        assertEquals("0xc0101280", probeEvent.getAddress());
-        assertNull(probeEvent.getSymbol());
-
-        // ------------------------------------------------------------------------
-        // enable event (dynamic probe) on channel
-        // ------------------------------------------------------------------------
-        eventsDialogStub.setIsDynamicProbe(true);
-        eventsDialogStub.setDynamicProbe("init_post");
-        eventsDialogStub.setProbeEventName("myevent2");
-
-        fFacility.executeCommand(channels[2], "enableEventOnChannel");
-
-        // Get Kernel domain component instance
-        domains = session.getChildren();
-        assertNotNull(domains);
-        assertEquals(1, domains.length);
-
-        // Verify that channel was created with correct data
-        channels =  domains[0].getChildren();
-        channel = (TraceChannelComponent) channels[2];
-        // No need to check parameters of default channel because that has been done in other tests
-
-        channel0Events = channel.getChildren();
-        assertEquals(6, channel0Events.length);
-
-        assertTrue(channel0Events[0] instanceof TraceProbeEventComponent);
-
-        probeEvent = (TraceProbeEventComponent) channel0Events[0];
-        assertEquals("myevent2", probeEvent.getName());
-        assertEquals(TraceLogLevel.LEVEL_UNKNOWN, probeEvent.getLogLevel());
-        assertEquals(TraceEventType.PROBE, probeEvent.getEventType());
-        assertEquals(TraceEnablement.ENABLED, probeEvent.getState());
-        assertEquals("0x0", probeEvent.getOffset());
-        assertNull(null, probeEvent.getAddress());
-        assertEquals("init_post", probeEvent.getSymbol());
-
-        // ------------------------------------------------------------------------
-        // enable event (dynamic probe) on session
-        // ------------------------------------------------------------------------
-        eventsDialogStub.setIsDynamicProbe(true);
-        eventsDialogStub.setDynamicProbe("init_post:0x1000");
-        eventsDialogStub.setProbeEventName("myevent3");
-
-        fFacility.executeCommand(session, "enableEventOnSession");
-
-        // Get Kernel domain component instance
-        domains = session.getChildren();
-        assertNotNull(domains);
-        assertEquals(1, domains.length);
-
-        // Verify that channel was created with correct data
-        channels =  domains[0].getChildren();
-        channel = (TraceChannelComponent) channels[2];
-        // No need to check parameters of default channel because that has been done in other tests
-
-        channel0Events = channel.getChildren();
-        assertEquals(7, channel0Events.length);
-
-        assertTrue(channel0Events[0] instanceof TraceProbeEventComponent);
-
-        probeEvent = (TraceProbeEventComponent) channel0Events[0];
-        assertEquals("myevent3", probeEvent.getName());
-        assertEquals(TraceLogLevel.LEVEL_UNKNOWN, probeEvent.getLogLevel());
-        assertEquals(TraceEventType.PROBE, probeEvent.getEventType());
-        assertEquals(TraceEnablement.ENABLED, probeEvent.getState());
-        assertEquals("0x1000", probeEvent.getOffset());
-        assertNull(null, probeEvent.getAddress());
-        assertEquals("init_post", probeEvent.getSymbol());
-
-        // ------------------------------------------------------------------------
-        // enable event (dynamic function probe) on session
-        // ------------------------------------------------------------------------
-        eventsDialogStub.setIsDynamicProbe(false);
-        eventsDialogStub.setDynamicProbe(null);
-        eventsDialogStub.setProbeEventName(null);
-        eventsDialogStub.setIsFunctionProbe(true);
-        eventsDialogStub.setFunctionEventName("myevent4");
-        eventsDialogStub.setFunctionProbe("create_dev");
-
-        fFacility.executeCommand(session, "enableEventOnSession");
-
-        // Get Kernel domain component instance
-        domains = session.getChildren();
-        assertNotNull(domains);
-        assertEquals(1, domains.length);
-
-        // Verify that channel was created with correct data
-        channels =  domains[0].getChildren();
-        channel = (TraceChannelComponent) channels[2];
-        // No need to check parameters of default channel because that has been done in other tests
-
-        channel0Events = channel.getChildren();
-        assertEquals(8, channel0Events.length);
-
-        assertTrue(channel0Events[0] instanceof TraceProbeEventComponent);
-
-        probeEvent = (TraceProbeEventComponent) channel0Events[0];
-        assertEquals("myevent4", probeEvent.getName());
-        assertEquals(TraceLogLevel.LEVEL_UNKNOWN, probeEvent.getLogLevel());
-        // Changed for Bug fix 419454 to function event which was introduced by LTTng 2.2
-        assertEquals(TraceEventType.FUNCTION, probeEvent.getEventType());
-        assertEquals(TraceEnablement.ENABLED, probeEvent.getState());
-        assertEquals("0x0", probeEvent.getOffset());
-        assertNull(null, probeEvent.getAddress());
-        assertEquals("create_dev", probeEvent.getSymbol());
-
-        // ------------------------------------------------------------------------
-        // enable event (dynamic function probe) on domain
-        // ------------------------------------------------------------------------
-        eventsDialogStub.setIsFunctionProbe(true);
-        eventsDialogStub.setFunctionEventName("myevent5");
-        eventsDialogStub.setFunctionProbe("create_dev:0x2000");
-
-        fFacility.executeCommand(domains[0], "enableEventOnDomain");
-
-        // Get Kernel domain component instance
-        domains = session.getChildren();
-        assertNotNull(domains);
-        assertEquals(1, domains.length);
-
-        // Verify that channel was created with correct data
-        channels =  domains[0].getChildren();
-        channel = (TraceChannelComponent) channels[2];
-        // No need to check parameters of default channel because that has been done in other tests
-
-        channel0Events = channel.getChildren();
-        assertEquals(9, channel0Events.length);
-
-        assertTrue(channel0Events[0] instanceof TraceProbeEventComponent);
-
-        probeEvent = (TraceProbeEventComponent) channel0Events[0];
-        assertEquals("myevent5", probeEvent.getName());
-        assertEquals(TraceLogLevel.LEVEL_UNKNOWN, probeEvent.getLogLevel());
-        assertEquals(TraceEventType.PROBE, probeEvent.getEventType());
-        assertEquals(TraceEnablement.ENABLED, probeEvent.getState());
-        assertEquals("0x2000", probeEvent.getOffset());
-        assertNull(null, probeEvent.getAddress());
-        assertEquals("create_dev", probeEvent.getSymbol());
-
-        // ------------------------------------------------------------------------
-        // enable event (dynamic function probe) on channel
-        // ------------------------------------------------------------------------
-        eventsDialogStub.setIsFunctionProbe(true);
-        eventsDialogStub.setFunctionEventName("myevent");
-        eventsDialogStub.setFunctionProbe("create_dev:0x2000");
-
-        fFacility.executeCommand(channels[0], "enableEventOnChannel");
-
-        // Get Kernel domain component instance
-        domains = session.getChildren();
-        assertNotNull(domains);
-        assertEquals(1, domains.length);
-
-        // Verify that channel was created with correct data
-        channels =  domains[0].getChildren();
-        channel = (TraceChannelComponent) channels[0];
-        // No need to check parameters of default channel because that has been done in other tests
-
-        channel0Events = channel.getChildren();
-        assertEquals(2, channel0Events.length);
-
-        assertTrue(channel0Events[0] instanceof TraceProbeEventComponent);
-
-        probeEvent = (TraceProbeEventComponent) channel0Events[0];
-        assertEquals("myevent", probeEvent.getName());
-        assertEquals(TraceLogLevel.LEVEL_UNKNOWN, probeEvent.getLogLevel());
-        assertEquals(TraceEventType.PROBE, probeEvent.getEventType());
-        assertEquals(TraceEnablement.ENABLED, probeEvent.getState());
-        assertEquals("0x2000", probeEvent.getOffset());
-        assertNull(null, probeEvent.getAddress());
-        assertEquals("create_dev", probeEvent.getSymbol());
-
-        // ------------------------------------------------------------------------
-        // Add Context on domain
-        // ------------------------------------------------------------------------
-        // Get Kernel domain component instance
-        domains = session.getChildren();
-        assertNotNull(domains);
-        assertEquals(1, domains.length);
-
-        AddContextDialogStub addContextStub = new AddContextDialogStub();
-        List<String> contexts = new ArrayList<>();
-        contexts.add("prio");
-        contexts.add("perf:branch-misses");
-        contexts.add("perf:cache-misses");
-        addContextStub.setContexts(contexts);
-        TraceControlDialogFactory.getInstance().setAddContextDialog(addContextStub);
-
-        fFacility.executeCommand(domains[0], "addContextOnDomain");
-        // Currently there is nothing to verify because the list commands don't show any context information
-        // However, the execution of the command make sure that the correct service command line is build and executed.
-
-        // ------------------------------------------------------------------------
-        // Add Context on channel
-        // ------------------------------------------------------------------------
-
-        // Get Kernel domain component instance
-        domains = session.getChildren();
-        assertNotNull(domains);
-        assertEquals(1, domains.length);
-
-        //Verify that channel was created with correct data
-        channels =  domains[0].getChildren();
-        channel = (TraceChannelComponent) channels[0];
-
-        try {
-            // The setContext() verifies that the contexts set are part of the available contexts
-            // The available contexts are set by the command handler addContextOnDomain above.
-            // So we indirectly test here that the parsing and setting of available contexts were
-            // done correctly above.
-            addContextStub.setContexts(contexts);
-        } catch (IllegalArgumentException e) {
-            fail("Exception caught - unknown context");
-        }
-
-        fFacility.executeCommand(channel, "addContextOnChannel");
-        // Currently there is nothing to verify because the list commands don't show any context information
-        // However, the execution of the command make sure that the correct service command line is build and executed.
-
-        // ------------------------------------------------------------------------
-        // Add Context on event
-        // ------------------------------------------------------------------------
-        // Get Kernel domain component instance
-        domains = session.getChildren();
-        assertNotNull(domains);
-        assertEquals(1, domains.length);
-
-        //Verify that channel was created with correct data
-        channels =  domains[0].getChildren();
-        channel = (TraceChannelComponent) channels[2];
-
-        channel0Events = channel.getChildren();
-
-        event = (TraceEventComponent) channel0Events[6];
-
-        fFacility.executeCommand(event, "addContextOnEvent");
-        // Currently there is nothing to verify because the list commands don't show any context information
-        // However, the execution of the command make sure that the correct service command line is build and executed.
-
-        // ------------------------------------------------------------------------
-        // Calibrate
-        // ------------------------------------------------------------------------
-        // Get Kernel domain component instance
-        domains = session.getChildren();
-        assertNotNull(domains);
-        assertEquals(1, domains.length);
-
-        fFacility.executeCommand(domains[0], "calibrate");
-        // There is nothing to verify here.
-        // However, the execution of the command make sure that the correct service command line is build and executed.
-
-        // ------------------------------------------------------------------------
-        // refresh
-        // ------------------------------------------------------------------------
-        fFacility.executeCommand(node, "refresh");
-        groups = node.getChildren();
-        assertNotNull(groups);
-        assertEquals(2, groups.length);
-        assertEquals(3, groups[0].getChildren().length); // provider
-        assertEquals(1, groups[1].getChildren().length); // sessions
-        assertEquals(1, groups[1].getChildren()[0].getChildren().length); // domains
-        assertEquals(3, groups[1].getChildren()[0].getChildren()[0].getChildren().length); // channels
-        assertEquals(2, groups[1].getChildren()[0].getChildren()[0].getChildren()[0].getChildren().length); // events (of channel[0])
-
-        // Initialize session handling scenario
-        fProxy.setScenario(TraceControlTestFacility.SCEN_SCENARIO_SESSION_HANDLING);
-
-        session = (TraceSessionComponent)groups[1].getChildren()[0];
-
-        // ------------------------------------------------------------------------
-        // start session
-        // ------------------------------------------------------------------------
-        fFacility.startSession(session);
-        assertEquals(TraceSessionState.ACTIVE, session.getSessionState());
-
-        // ------------------------------------------------------------------------
-        // stop session
-        // ------------------------------------------------------------------------
-        fFacility.stopSession(session);
-        assertEquals(TraceSessionState.INACTIVE, session.getSessionState());
-
-        // ------------------------------------------------------------------------
-        // Destroy session
-        // ------------------------------------------------------------------------
-
-        fFacility.destroySession(session);
-
-        // Verify that no more session components exist
-        assertEquals(0, groups[1].getChildren().length);
-
-        //-------------------------------------------------------------------------
-        // Disconnect node
-        //-------------------------------------------------------------------------
-        fFacility.executeCommand(node, "disconnect");
-        assertEquals(TargetNodeState.DISCONNECTED, node.getTargetNodeState());
-
-        //-------------------------------------------------------------------------
-        // Delete node
-        //-------------------------------------------------------------------------
-
-        fFacility.executeCommand(node, "delete");
-        assertEquals(0,fFacility.getControlView().getTraceControlRoot().getChildren().length);
-    }
-
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlPropertiesTest.java b/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlPropertiesTest.java
deleted file mode 100644 (file)
index a4b0108..0000000
+++ /dev/null
@@ -1,363 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2015 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Alexandre Montplaisir - Port to JUnit4
- *   Markus Schorn - Bug 448058: Use org.eclipse.remote in favor of RSE
- **********************************************************************/
-
-package org.eclipse.tracecompass.lttng2.control.ui.tests.model.component;
-
-import static org.junit.Assert.assertEquals;
-import static org.junit.Assert.assertFalse;
-import static org.junit.Assert.assertNotNull;
-import static org.junit.Assert.assertNull;
-import static org.junit.Assert.assertTrue;
-
-import java.io.File;
-import java.net.URL;
-
-import org.eclipse.core.runtime.FileLocator;
-import org.eclipse.core.runtime.Path;
-import org.eclipse.remote.core.IRemoteConnection;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IChannelInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TargetNodeState;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEnablement;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEventType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.BufferType;
-import org.eclipse.tracecompass.internal.lttng2.control.stubs.service.TestRemoteSystemProxy;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.BaseEventComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.KernelProviderComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceEventComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceProbeEventComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.UstProviderComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.property.BaseEventPropertySource;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.property.KernelProviderPropertySource;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.property.TargetNodePropertySource;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.property.TraceChannelPropertySource;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.property.TraceDomainPropertySource;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.property.TraceEventPropertySource;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.property.TraceProbeEventPropertySource;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.property.TraceSessionPropertySource;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.property.UstProviderPropertySource;
-import org.eclipse.tracecompass.tmf.remote.core.proxy.TmfRemoteConnectionFactory;
-import org.eclipse.ui.views.properties.IPropertySource;
-import org.junit.After;
-import org.junit.Test;
-import org.osgi.framework.FrameworkUtil;
-
-/**
- * The class <code>TraceControlPropertiesTest</code> contains tests for the all
- * property class</code>.
- */
-public class TraceControlPropertiesTest {
-
-    // ------------------------------------------------------------------------
-    // Constants
-    // ------------------------------------------------------------------------
-
-    private static final String DIRECTORY   = "testfiles";
-    private static final String TEST_STREAM = "ListInfoTest.cfg";
-    private static final String SCEN_LIST_INFO_TEST = "ListInfoTest";
-
-    // ------------------------------------------------------------------------
-    // Housekeeping
-    // ------------------------------------------------------------------------
-
-    /**
-     * Perform post-test clean-up.
-     */
-    @After
-    public void tearDown() {
-        TraceControlTestFacility.getInstance().waitForJobs();
-    }
-
-    /**
-     * Run the TraceControlComponent.
-     *
-     * @throws Exception
-     *             This will fail the test
-     */
-    @Test
-    public void testComponentProperties() throws Exception {
-        IRemoteConnection host = TmfRemoteConnectionFactory.getLocalConnection();
-        TestRemoteSystemProxy proxy = new TestRemoteSystemProxy(host);
-
-        URL location = FileLocator.find(FrameworkUtil.getBundle(this.getClass()), new Path(DIRECTORY + File.separator + TEST_STREAM), null);
-        File testfile = new File(FileLocator.toFileURL(location).toURI());
-        proxy.setTestFile(testfile.getAbsolutePath());
-        proxy.setScenario(SCEN_LIST_INFO_TEST);
-
-        ITraceControlComponent root = TraceControlTestFacility.getInstance().getControlView().getTraceControlRoot();
-
-        TargetNodeComponent node = new TargetNodeComponent("myNode", root, proxy);
-
-        root.addChild(node);
-        node.connect();
-
-        TraceControlTestFacility.getInstance().waitForConnect(node);
-        TraceControlTestFacility.getInstance().waitForJobs();
-
-        // ------------------------------------------------------------------------
-        // Verify Node Properties (adapter)
-        // ------------------------------------------------------------------------
-        Object adapter = node.getAdapter(IPropertySource.class);
-        assertNotNull(adapter);
-        assertTrue(adapter instanceof TargetNodePropertySource);
-
-        TargetNodePropertySource source = (TargetNodePropertySource)adapter;
-
-        assertNull(source.getEditableValue());
-        assertFalse(source.isPropertySet(TargetNodePropertySource.TARGET_NODE_NAME_PROPERTY_ID));
-        assertNotNull(source.getPropertyDescriptors());
-
-        assertEquals("myNode", source.getPropertyValue(TargetNodePropertySource.TARGET_NODE_NAME_PROPERTY_ID));
-        // Don't check the address property because the string can vary on the machine the test is running
-//        assertEquals("localhost",  source.getPropertyValue(TargetNodePropertySource.TARGET_NODE_ADDRESS_PROPERTY_ID));
-        assertEquals(TargetNodeState.CONNECTED.name(), source.getPropertyValue(TargetNodePropertySource.TARGET_NODE_STATE_PROPERTY_ID));
-        assertEquals("2.5.0", source.getPropertyValue(TargetNodePropertySource.TARGET_NODE_VERSION_PROPERTY_ID));
-        assertNull(source.getPropertyValue("test"));
-
-        adapter = node.getAdapter(IChannelInfo.class);
-        assertNull(adapter);
-
-        ITraceControlComponent[] groups = node.getChildren();
-        assertNotNull(groups);
-        assertEquals(2, groups.length);
-
-        ITraceControlComponent[] providers = groups[0].getChildren();
-
-        assertNotNull(providers);
-        assertEquals(3, providers.length);
-
-        // ------------------------------------------------------------------------
-        // Verify Kernel Provider Properties (adapter)
-        // ------------------------------------------------------------------------
-        KernelProviderComponent kernelProvider = (KernelProviderComponent) providers[0];
-
-        adapter = kernelProvider.getAdapter(IPropertySource.class);
-        assertNotNull(adapter);
-        assertTrue(adapter instanceof KernelProviderPropertySource);
-
-        KernelProviderPropertySource kernelSource = (KernelProviderPropertySource)adapter;
-        assertNotNull(kernelSource.getPropertyDescriptors());
-
-        assertEquals("Kernel", kernelSource.getPropertyValue(KernelProviderPropertySource.KERNEL_PROVIDER_NAME_PROPERTY_ID));
-
-        // ------------------------------------------------------------------------
-        // Verify UST Provider Properties (adapter)
-        // ------------------------------------------------------------------------
-        UstProviderComponent ustProvider = (UstProviderComponent) providers[1];
-
-        adapter = ustProvider.getAdapter(IPropertySource.class);
-        assertNotNull(adapter);
-        assertTrue(adapter instanceof UstProviderPropertySource);
-
-        UstProviderPropertySource ustSource = (UstProviderPropertySource)adapter;
-        assertNotNull(ustSource.getPropertyDescriptors());
-
-        assertEquals("/home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello [PID=9379]", ustSource.getPropertyValue(UstProviderPropertySource.UST_PROVIDER_NAME_PROPERTY_ID));
-        assertEquals(String.valueOf(9379), ustSource.getPropertyValue(UstProviderPropertySource.UST_PROVIDER_PID_PROPERTY_ID));
-
-        // ------------------------------------------------------------------------
-        // Verify Base Event Properties (adapter)
-        // ------------------------------------------------------------------------
-        ITraceControlComponent[] events = ustProvider.getChildren();
-        assertNotNull(events);
-        assertEquals(2, events.length);
-
-        BaseEventComponent baseEventInfo = (BaseEventComponent) events[0];
-        assertNotNull(baseEventInfo);
-
-        adapter = baseEventInfo.getAdapter(IPropertySource.class);
-        assertNotNull(adapter);
-        assertTrue(adapter instanceof BaseEventPropertySource);
-
-        BaseEventPropertySource baseSource = (BaseEventPropertySource)adapter;
-        assertNotNull(baseSource.getPropertyDescriptors());
-
-        assertEquals("ust_tests_hello:tptest_sighandler", baseSource.getPropertyValue(BaseEventPropertySource.BASE_EVENT_NAME_PROPERTY_ID));
-        assertEquals(TraceEventType.TRACEPOINT.name(), baseSource.getPropertyValue(BaseEventPropertySource.BASE_EVENT_TYPE_PROPERTY_ID));
-        assertEquals(TraceLogLevel.TRACE_DEBUG_MODULE.name(), baseSource.getPropertyValue(BaseEventPropertySource.BASE_EVENT_LOGLEVEL_PROPERTY_ID));
-
-        baseEventInfo = (BaseEventComponent) events[1];
-        assertNotNull(baseEventInfo);
-
-        adapter = baseEventInfo.getAdapter(IPropertySource.class);
-        assertNotNull(adapter);
-        assertTrue(adapter instanceof BaseEventPropertySource);
-        baseSource = (BaseEventPropertySource)adapter;
-        assertNotNull(baseSource.getPropertyDescriptors());
-        assertEquals("doublefield=float;floatfield=float;stringfield=string", baseSource.getPropertyValue(BaseEventPropertySource.BASE_EVENT_FIELDS_PROPERTY_ID));
-
-        // ------------------------------------------------------------------------
-        // Verify Session Properties (adapter)
-        // ------------------------------------------------------------------------
-        ITraceControlComponent[] sessions = groups[1].getChildren();
-        assertNotNull(sessions);
-        assertEquals(2, sessions.length);
-
-        TraceSessionComponent session = (TraceSessionComponent)sessions[1];
-
-        adapter = session.getAdapter(IPropertySource.class);
-        assertNotNull(adapter);
-        assertTrue(adapter instanceof TraceSessionPropertySource);
-
-        TraceSessionPropertySource sessionSource = (TraceSessionPropertySource)adapter;
-        assertNotNull(sessionSource.getPropertyDescriptors());
-
-        assertEquals("mysession", sessionSource.getPropertyValue(TraceSessionPropertySource.TRACE_SESSION_NAME_PROPERTY_ID));
-        assertEquals("/home/user/lttng-traces/mysession-20120129-084256", sessionSource.getPropertyValue(TraceSessionPropertySource.TRACE_SESSION_PATH_PROPERTY_ID));
-        assertEquals(TraceSessionState.ACTIVE.name(), sessionSource.getPropertyValue(TraceSessionPropertySource.TRACE_SESSION_STATE_PROPERTY_ID));
-
-        // ------------------------------------------------------------------------
-        // Verify Domain Provider Properties (adapter)
-        // ------------------------------------------------------------------------
-        ITraceControlComponent[] domains = session.getChildren();
-        assertNotNull(domains);
-        assertEquals(2, domains.length);
-
-        TraceDomainComponent domain = (TraceDomainComponent) domains[0];
-        adapter = domain.getAdapter(IPropertySource.class);
-        assertNotNull(adapter);
-        assertTrue(adapter instanceof TraceDomainPropertySource);
-
-        TraceDomainPropertySource domainSource = (TraceDomainPropertySource)adapter;
-        assertNotNull(domainSource.getPropertyDescriptors());
-
-        assertEquals("Kernel", domainSource.getPropertyValue(TraceDomainPropertySource.TRACE_DOMAIN_NAME_PROPERTY_ID));
-        assertEquals(BufferType.BUFFER_SHARED.getInName(), domainSource.getPropertyValue(TraceDomainPropertySource.BUFFER_TYPE_PROPERTY_ID));
-
-        ITraceControlComponent[] channels =  domains[0].getChildren();
-        assertNotNull(channels);
-        assertEquals(2, channels.length);
-
-        // ------------------------------------------------------------------------
-        // Verify Channel Properties (adapter)
-        // ------------------------------------------------------------------------
-        assertTrue(channels[0] instanceof TraceChannelComponent);
-        TraceChannelComponent channel = (TraceChannelComponent) channels[0];
-
-        adapter = channel.getAdapter(IPropertySource.class);
-        assertNotNull(adapter);
-        assertTrue(adapter instanceof TraceChannelPropertySource);
-
-        TraceChannelPropertySource channelSource = (TraceChannelPropertySource)adapter;
-        assertNotNull(channelSource.getPropertyDescriptors());
-
-        assertEquals("channel0", channelSource.getPropertyValue(TraceChannelPropertySource.TRACE_CHANNEL_NAME_PROPERTY_ID));
-        assertEquals(String.valueOf(4), channelSource.getPropertyValue(TraceChannelPropertySource.TRACE_CHANNEL_NO_SUBBUFFERS_PROPERTY_ID));
-        assertEquals(TraceEnablement.ENABLED.name(), channelSource.getPropertyValue(TraceChannelPropertySource.TRACE_CHANNEL_STATE_PROPERTY_ID));
-        assertEquals(String.valueOf(false), channelSource.getPropertyValue(TraceChannelPropertySource.TRACE_CHANNEL_OVERWRITE_MODE_PROPERTY_ID));
-        assertEquals("splice()", channelSource.getPropertyValue(TraceChannelPropertySource.TRACE_CHANNEL_OUTPUT_TYPE_PROPERTY_ID));
-        assertEquals(String.valueOf(200), channelSource.getPropertyValue(TraceChannelPropertySource.TRACE_CHANNEL_READ_TIMER_PROPERTY_ID));
-        assertEquals(String.valueOf(262144), channelSource.getPropertyValue(TraceChannelPropertySource.TRACE_CHANNEL_SUBBUFFER_SIZE_PROPERTY_ID));
-        assertEquals(String.valueOf(0), channelSource.getPropertyValue(TraceChannelPropertySource.TRACE_CHANNEL_SWITCH_TIMER_PROPERTY_ID));
-        assertEquals(Integer.valueOf(2), channelSource.getPropertyValue(TraceChannelPropertySource.TRACE_CHANNEL_TRACE_FILE_COUNT_PROPERTY_ID));
-        assertEquals(Long.valueOf(262144), channelSource.getPropertyValue(TraceChannelPropertySource.TRACE_CHANNEL_TRACE_FILE_SIZE_PROPERTY_ID));
-
-        // ------------------------------------------------------------------------
-        // Verify Event Properties (adapter)
-        // ------------------------------------------------------------------------
-        ITraceControlComponent[] channel0Events = channel.getChildren();
-        assertNotNull(channel0Events);
-        assertEquals(5, channel0Events.length);
-        assertTrue(channel0Events[0] instanceof TraceEventComponent);
-
-        TraceEventComponent event = (TraceEventComponent) channel0Events[0];
-
-        adapter = event.getAdapter(IPropertySource.class);
-        assertNotNull(adapter);
-        assertTrue(adapter instanceof TraceEventPropertySource);
-
-        TraceEventPropertySource eventSource = (TraceEventPropertySource)adapter;
-        assertNotNull(eventSource.getPropertyDescriptors());
-
-        assertEquals("block_rq_remap", eventSource.getPropertyValue(TraceEventPropertySource.TRACE_EVENT_NAME_PROPERTY_ID));
-        assertEquals(TraceLogLevel.TRACE_EMERG.name(), eventSource.getPropertyValue(TraceEventPropertySource.TRACE_EVENT_LOGLEVEL_PROPERTY_ID));
-        assertEquals(TraceEventType.TRACEPOINT.name(), eventSource.getPropertyValue(TraceEventPropertySource.TRACE_EVENT_TYPE_PROPERTY_ID));
-        assertEquals(TraceEnablement.ENABLED.name(), eventSource.getPropertyValue(TraceEventPropertySource.TRACE_EVENT_STATE_PROPERTY_ID));
-
-        // ------------------------------------------------------------------------
-        // Verify Probe Event Properties (adapter)
-        // ------------------------------------------------------------------------
-        assertTrue(channel0Events[2] instanceof TraceProbeEventComponent);
-
-        TraceProbeEventComponent probeEvent = (TraceProbeEventComponent) channel0Events[2];
-
-        adapter = probeEvent.getAdapter(IPropertySource.class);
-        assertNotNull(adapter);
-        assertTrue(adapter instanceof TraceProbeEventPropertySource);
-
-        TraceProbeEventPropertySource probeEventSource = (TraceProbeEventPropertySource)adapter;
-        assertNotNull(probeEventSource.getPropertyDescriptors());
-        assertEquals(4, probeEventSource.getPropertyDescriptors().length);
-
-        assertEquals("myevent2", probeEventSource.getPropertyValue(TraceEventPropertySource.TRACE_EVENT_NAME_PROPERTY_ID));
-        assertEquals(TraceEventType.PROBE.name(), probeEventSource.getPropertyValue(TraceEventPropertySource.TRACE_EVENT_TYPE_PROPERTY_ID));
-        assertEquals(TraceEnablement.ENABLED.name(), probeEventSource.getPropertyValue(TraceEventPropertySource.TRACE_EVENT_STATE_PROPERTY_ID));
-        assertEquals("0xc0101340", probeEventSource.getPropertyValue(TraceProbeEventPropertySource.TRACE_EVENT_PROBE_ADDRESS_PROPERTY_ID));
-
-        assertTrue(channel0Events[3] instanceof TraceProbeEventComponent);
-
-        probeEvent = (TraceProbeEventComponent) channel0Events[3];
-
-        adapter = probeEvent.getAdapter(IPropertySource.class);
-        assertNotNull(adapter);
-        assertTrue(adapter instanceof TraceProbeEventPropertySource);
-
-        probeEventSource = (TraceProbeEventPropertySource)adapter;
-        assertNotNull(probeEventSource.getPropertyDescriptors());
-        assertEquals(5, probeEventSource.getPropertyDescriptors().length);
-
-        assertEquals("myevent0", probeEventSource.getPropertyValue(TraceEventPropertySource.TRACE_EVENT_NAME_PROPERTY_ID));
-        assertEquals(TraceEventType.PROBE.name(), probeEventSource.getPropertyValue(TraceEventPropertySource.TRACE_EVENT_TYPE_PROPERTY_ID));
-        assertEquals(TraceEnablement.ENABLED.name(), probeEventSource.getPropertyValue(TraceEventPropertySource.TRACE_EVENT_STATE_PROPERTY_ID));
-        assertEquals("0x0", probeEventSource.getPropertyValue(TraceProbeEventPropertySource.TRACE_EVENT_PROBE_OFFSET_PROPERTY_ID));
-        assertEquals("init_post", probeEventSource.getPropertyValue(TraceProbeEventPropertySource.TRACE_EVENT_PROBE_SYMBOL_PROPERTY_ID));
-
-        //-------------------------------------------------------------------------
-        // Verify Filter of UST event
-        //-------------------------------------------------------------------------
-        event = (TraceEventComponent) domains[1].getChildren()[1].getChildren()[0];
-        adapter = event.getAdapter(IPropertySource.class);
-        assertEquals("with filter", event.getFilterExpression());
-
-        //-------------------------------------------------------------------------
-        // Verify Log Level Type of UST events (> LTTng 2.4)
-        //-------------------------------------------------------------------------
-        event = (TraceEventComponent) domains[1].getChildren()[1].getChildren()[0];
-        adapter = event.getAdapter(IPropertySource.class);
-        eventSource = (TraceEventPropertySource) adapter;
-        assertEquals("== TRACE_DEBUG_LINE", eventSource.getPropertyValue(TraceEventPropertySource.TRACE_EVENT_LOGLEVEL_PROPERTY_ID));
-
-        event = (TraceEventComponent) domains[1].getChildren()[1].getChildren()[1];
-        adapter = event.getAdapter(IPropertySource.class);
-        eventSource = (TraceEventPropertySource) adapter;
-        assertEquals("<= TRACE_INFO", eventSource.getPropertyValue(TraceEventPropertySource.TRACE_EVENT_LOGLEVEL_PROPERTY_ID));
-
-        event = (TraceEventComponent) domains[1].getChildren()[1].getChildren()[2];
-        adapter = event.getAdapter(IPropertySource.class);
-        eventSource = (TraceEventPropertySource) adapter;
-        assertEquals("TRACE_DEBUG_SYSTEM", eventSource.getPropertyValue(TraceEventPropertySource.TRACE_EVENT_LOGLEVEL_PROPERTY_ID));
-
-        //-------------------------------------------------------------------------
-        // Delete node
-        //-------------------------------------------------------------------------
-        node.disconnect();
-        node.getParent().removeChild(node);
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlSnapshotSessionTests.java b/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlSnapshotSessionTests.java
deleted file mode 100644 (file)
index ed588a8..0000000
+++ /dev/null
@@ -1,217 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2013, 2015 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Markus Schorn - Bug 448058: Use org.eclipse.remote in favor of RSE
- **********************************************************************/
-
-package org.eclipse.tracecompass.lttng2.control.ui.tests.model.component;
-
-import static org.junit.Assert.assertEquals;
-import static org.junit.Assert.assertNotNull;
-import static org.junit.Assert.assertTrue;
-
-import java.io.File;
-import java.net.URL;
-import java.util.HashMap;
-import java.util.Map;
-
-import org.eclipse.core.runtime.FileLocator;
-import org.eclipse.core.runtime.Path;
-import org.eclipse.jdt.annotation.NonNull;
-import org.eclipse.remote.core.IRemoteConnection;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TargetNodeState;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
-import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.CreateSessionDialogStub;
-import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.DestroyConfirmDialogStub;
-import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.GetEventInfoDialogStub;
-import org.eclipse.tracecompass.internal.lttng2.control.stubs.service.TestRemoteSystemProxy;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.TraceControlDialogFactory;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.property.TraceSessionPropertySource;
-import org.eclipse.tracecompass.tmf.remote.core.proxy.TmfRemoteConnectionFactory;
-import org.eclipse.ui.views.properties.IPropertyDescriptor;
-import org.eclipse.ui.views.properties.IPropertySource;
-import org.junit.After;
-import org.junit.Before;
-import org.junit.Test;
-import org.osgi.framework.FrameworkUtil;
-
-/**
- * The class <code>TraceControlSnapshotSessionTests</code> contains Snapshot
- * session test cases for support of LTTng Tools 2.3.
- */
-public class TraceControlSnapshotSessionTests {
-
-    // ------------------------------------------------------------------------
-    // Constants
-    // ------------------------------------------------------------------------
-
-    private static final String TEST_STREAM = "CreateSessionTest2.cfg";
-    private static final String SCEN_CREATE_SESSION = "ScenCreateSession";
-
-    // ------------------------------------------------------------------------
-    // Test data
-    // ------------------------------------------------------------------------
-
-    private TraceControlTestFacility fFacility;
-    private IRemoteConnection fHost = TmfRemoteConnectionFactory.getLocalConnection();
-    private @NonNull TestRemoteSystemProxy fProxy = new TestRemoteSystemProxy(fHost);
-    private String fTestFile;
-
-    // ------------------------------------------------------------------------
-    // Housekeeping
-    // ------------------------------------------------------------------------
-
-    /**
-     * Perform pre-test initialization.
-     *
-     * @throws Exception
-     *         if the initialization fails for some reason
-     */
-    @Before
-    public void setUp() throws Exception {
-        fFacility = TraceControlTestFacility.getInstance();
-        fFacility.init();
-        fProxy = new TestRemoteSystemProxy(fHost);
-        URL location = FileLocator.find(FrameworkUtil.getBundle(this.getClass()), new Path(TraceControlTestFacility.DIRECTORY + File.separator + TEST_STREAM), null);
-        File testfile = new File(FileLocator.toFileURL(location).toURI());
-        fTestFile = testfile.getAbsolutePath();
-    }
-
-    /**
-     * Perform post-test clean-up.
-     */
-    @After
-    public void tearDown() {
-        fFacility.waitForJobs();
-        fFacility.dispose();
-    }
-
-    /**
-     * Run the TraceControlComponent.
-     *
-     * @throws Exception
-     *             This will fail the test
-     */
-    @Test
-    public void testTraceSessionTree() throws Exception {
-
-        fProxy.setTestFile(fTestFile);
-        fProxy.setScenario(TraceControlTestFacility.SCEN_INIT_TEST);
-
-        ITraceControlComponent root = fFacility.getControlView().getTraceControlRoot();
-
-        TargetNodeComponent node = new TargetNodeComponent("myNode", root, fProxy);
-
-        root.addChild(node);
-        fFacility.waitForJobs();
-
-        fFacility.executeCommand(node, "connect");
-        int i = 0;
-        while ((i < 10) && (node.getTargetNodeState() != TargetNodeState.CONNECTED)) {
-            i++;
-            fFacility.delay(TraceControlTestFacility.GUI_REFESH_DELAY);
-        }
-
-        // Get provider groups
-        ITraceControlComponent[] groups = node.getChildren();
-        assertNotNull(groups);
-        assertEquals(2, groups.length);
-
-        // Initialize dialog implementations for command execution
-        // --- snapshot session ---
-        CreateSessionDialogStub sessionDialog = new CreateSessionDialogStub();
-        sessionDialog.setSnapshot(true);
-
-        TraceControlDialogFactory.getInstance().setCreateSessionDialog(sessionDialog);
-        TraceControlDialogFactory.getInstance().setGetEventInfoDialog(new GetEventInfoDialogStub());
-        TraceControlDialogFactory.getInstance().setConfirmDialog(new DestroyConfirmDialogStub());
-
-        // Initialize scenario
-        fProxy.setScenario(SCEN_CREATE_SESSION);
-
-        // ------------------------------------------------------------------------
-        // Create session
-        // ------------------------------------------------------------------------
-        TraceSessionComponent session = fFacility.createSession(groups[1]);
-
-        // Verify that session was created
-        assertNotNull(session);
-        assertEquals("mysession", session.getName());
-        assertTrue(session.isSnapshotSession());
-        assertNotNull(session.getSnapshotInfo());
-        assertEquals("snapshot-1", session.getSnapshotInfo().getName());
-        assertEquals("/home/user/lttng-traces/mysession-20130913-141651", session.getSnapshotInfo().getSnapshotPath());
-        assertEquals(1, session.getSnapshotInfo().getId());
-
-        // ------------------------------------------------------------------------
-        // Start session
-        // ------------------------------------------------------------------------
-        fFacility.startSession(session);
-        assertEquals(TraceSessionState.ACTIVE, session.getSessionState());
-
-        // verify properties
-        Object adapter = session.getAdapter(IPropertySource.class);
-        assertNotNull(adapter);
-        assertTrue(adapter instanceof TraceSessionPropertySource);
-
-        TraceSessionPropertySource sessionSource = (TraceSessionPropertySource)adapter;
-        IPropertyDescriptor[] descriptors = sessionSource.getPropertyDescriptors();
-        assertNotNull(descriptors);
-
-        Map<String,String> map = new HashMap<>();
-        map.put(TraceSessionPropertySource.TRACE_SESSION_NAME_PROPERTY_ID, "mysession");
-        map.put(TraceSessionPropertySource.TRACE_SNAPSHOT_NAME_PROPERTY_ID, "snapshot-1");
-        map.put(TraceSessionPropertySource.TRACE_SNAPSHOT_PATH_PROPERTY_ID, "/home/user/lttng-traces/mysession-20130913-141651");
-        map.put(TraceSessionPropertySource.TRACE_SNAPSHOT_ID_PROPERTY_ID, "1");
-        map.put(TraceSessionPropertySource.TRACE_SESSION_STATE_PROPERTY_ID, TraceSessionState.ACTIVE.name());
-
-        for (int j = 0; j < descriptors.length; j++) {
-            String expected = map.get(descriptors[j].getId());
-            assertNotNull(expected);
-            assertEquals(expected, sessionSource.getPropertyValue(descriptors[j].getId()).toString());
-        }
-
-        // ------------------------------------------------------------------------
-        // Record snapshot
-        // ------------------------------------------------------------------------
-        fFacility.executeCommand(session, "snapshot");
-
-        // ------------------------------------------------------------------------
-        // Stop snapshot
-        // ------------------------------------------------------------------------
-        fFacility.stopSession(session);
-        assertEquals(TraceSessionState.INACTIVE, session.getSessionState());
-
-        // ------------------------------------------------------------------------
-        // Destroy session
-        // ------------------------------------------------------------------------
-        fFacility.destroySession(session);
-
-        // Verify that no more session components exist
-        assertEquals(0, groups[1].getChildren().length);
-
-        //-------------------------------------------------------------------------
-        // Disconnect node
-        //-------------------------------------------------------------------------
-        fFacility.executeCommand(node, "disconnect");
-        assertEquals(TargetNodeState.DISCONNECTED, node.getTargetNodeState());
-
-        //-------------------------------------------------------------------------
-        // Delete node
-        //-------------------------------------------------------------------------
-
-        fFacility.executeCommand(node, "delete");
-
-        assertEquals(0,fFacility.getControlView().getTraceControlRoot().getChildren().length);
-    }
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlTestFacility.java b/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlTestFacility.java
deleted file mode 100644 (file)
index f14a4a3..0000000
+++ /dev/null
@@ -1,303 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2011, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.control.ui.tests.model.component;
-
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.core.commands.NotEnabledException;
-import org.eclipse.core.commands.NotHandledException;
-import org.eclipse.core.commands.common.NotDefinedException;
-import org.eclipse.core.runtime.jobs.Job;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TargetNodeState;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
-import org.eclipse.ui.IViewPart;
-import org.eclipse.ui.PartInitException;
-import org.eclipse.ui.PlatformUI;
-import org.eclipse.ui.handlers.IHandlerService;
-import org.junit.Assert;
-
-/**
- *  Singleton class to facilitate the test cases. Creates UML2SD view and loader objects as well as provides
- *  utility methods for interacting with the loader/view.
- */
-@SuppressWarnings("javadoc")
-public class TraceControlTestFacility {
-
-    // ------------------------------------------------------------------------
-    // Constants
-    // ------------------------------------------------------------------------
-    public final static int WAIT_FOR_JOBS_DELAY = 50;
-    public final static int GUI_REFESH_DELAY = 500;
-
-    public final static String DIRECTORY = "testfiles";
-    public final static String COMMAND_CATEGORY_PREFIX = "org.eclipse.linuxtools.internal.lttng2.ui.commands.control.";
-    public final static String SCEN_INIT_TEST = "Initialize";
-    public final static String SCEN_SCENARIO_SESSION_HANDLING = "SessionHandling";
-    public final static String SCEN_SCENARIO_SESSION_HANDLING_WITH_PATH = "SessionHandlingWithPath";
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-    private static TraceControlTestFacility fInstance = null;
-    private ControlView fControlView = null;
-    private boolean fIsInitialized = false;
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-    private TraceControlTestFacility() {
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-    public static TraceControlTestFacility getInstance() {
-        if (fInstance == null) {
-            fInstance = new TraceControlTestFacility();
-        }
-        return fInstance;
-    }
-
-    /**
-     * Initial the test facility.
-     */
-    public void init() {
-
-        if (!fIsInitialized) {
-
-            IViewPart view;
-            try {
-
-                view = PlatformUI.getWorkbench()
-                        .getActiveWorkbenchWindow()
-                        .getActivePage()
-                        .findView("org.eclipse.ui.internal.introview");
-
-                if (view != null) {
-                    PlatformUI.getWorkbench()
-                    .getActiveWorkbenchWindow()
-                    .getActivePage().hideView(view);
-                }
-
-                view = PlatformUI.getWorkbench()
-                                 .getActiveWorkbenchWindow()
-                                 .getActivePage()
-                                 .showView(ControlView.ID);
-
-            } catch (PartInitException e) {
-                throw new RuntimeException(e);
-            }
-
-            fControlView = (ControlView) view;
-
-            delay(3000);
-            fIsInitialized = true;
-        }
-    }
-
-
-    /**
-     * Disposes the facility (and GUI)
-     */
-    public void dispose() {
-        if (fIsInitialized) {
-            waitForJobs();
-
-            PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActivePage().hideView(fControlView);
-            fIsInitialized = false;
-        }
-    }
-
-    /**
-     * Creates a delay for given time.
-     * @param waitTimeMillis - time in milli seconds
-     */
-    public void delay(long waitTimeMillis) {
-        Display display = Display.getCurrent();
-        if (display != null) {
-            long endTimeMillis = System.currentTimeMillis() + waitTimeMillis;
-            while(System.currentTimeMillis() < endTimeMillis) {
-                if (!display.readAndDispatch()) {
-                    // We do not use Display.sleep because it might never wake up
-                    // if there is no user interaction
-                    try {
-                        Thread.sleep(Math.min(waitTimeMillis, 10));
-                    } catch (final InterruptedException e) {
-                        // Ignored
-                    }
-                }
-                display.update();
-            }
-        } else {
-            try {
-                Thread.sleep(waitTimeMillis);
-            } catch (InterruptedException e) {
-                // Ignored
-            }
-        }
-    }
-
-    /**
-     * Waits for a connection to be connected
-     */
-    public void waitForConnect(TargetNodeComponent node) {
-        for (int i = 1; i < 5000 && node.getTargetNodeState() == TargetNodeState.CONNECTING; i *= 2) {
-            try {
-                Thread.sleep(i);
-            } catch (InterruptedException e) {
-                Assert.fail();
-            }
-        }
-    }
-
-    /**
-     * Waits for all Eclipse jobs to finish
-     */
-    public void waitForJobs() {
-        while (!Job.getJobManager().isIdle()) {
-            delay(WAIT_FOR_JOBS_DELAY);
-        }
-    }
-
-    /**
-     * @return current control view
-     */
-    public ControlView getControlView() {
-        return fControlView;
-    }
-
-    /**
-     * Executes an Eclipse command with command ID after selecting passed component
-     * @param component - component to select in the tree
-     * @param commandId - command ID
-     * @throws ExecutionException
-     * @throws NotDefinedException
-     * @throws NotEnabledException
-     * @throws NotHandledException
-     */
-    public void executeCommand(ITraceControlComponent component, String commandId) throws ExecutionException, NotDefinedException, NotEnabledException, NotHandledException {
-        setSelection(component);
-        executeCommand(commandId);
-    }
-
-    /**
-     * Executes an Eclipse command with command ID after selecting passed components
-     * @param components - array of components to select in the tree
-     * @param commandId - command ID
-     * @throws ExecutionException
-     * @throws NotDefinedException
-     * @throws NotEnabledException
-     * @throws NotHandledException
-     */
-    public void executeCommand(ITraceControlComponent[] components, String commandId) throws ExecutionException, NotDefinedException, NotEnabledException, NotHandledException {
-        setSelection(components);
-        executeCommand(commandId);
-    }
-
-    /**
-     * Executes an Eclipse command with command ID
-     * @param commandId
-     * @throws ExecutionException
-     * @throws NotDefinedException
-     * @throws NotEnabledException
-     * @throws NotHandledException
-     */
-    public void executeCommand(String commandId) throws ExecutionException, NotDefinedException, NotEnabledException, NotHandledException {
-        Object handlerServiceObject = fControlView.getSite().getService(IHandlerService.class);
-        IHandlerService handlerService = (IHandlerService) handlerServiceObject;
-        handlerService.executeCommand(COMMAND_CATEGORY_PREFIX + commandId, null);
-        waitForJobs();
-    }
-
-    /**
-     * Selects passed component
-     * @param component - component to select in the tree
-     * @param commandId - command ID
-     */
-    public void setSelection(ITraceControlComponent component) {
-        fControlView.setSelection(component);
-        // Selection is done in own job
-        waitForJobs();
-    }
-
-
-    /**
-     * Selects passed components
-     * @param components - array of component to select in the tree
-     * @param commandId - command ID
-     */
-    public void setSelection(ITraceControlComponent[] components) {
-        fControlView.setSelection(components);
-
-        // Selection is done in own job
-        waitForJobs();
-    }
-
-    /**
-     * Creates session on passed session group.
-     * @param group - session group
-     * @return - trace session group if it's successful else null
-     * @throws ExecutionException
-     * @throws NotDefinedException
-     * @throws NotEnabledException
-     * @throws NotHandledException
-     */
-    public TraceSessionComponent createSession(ITraceControlComponent group) throws ExecutionException, NotDefinedException, NotEnabledException, NotHandledException {
-        executeCommand(group, "createSession");
-
-        ITraceControlComponent[] sessions = group.getChildren();
-        if ((sessions == null) || (sessions.length == 0)) {
-            return null;
-        }
-        return (TraceSessionComponent)sessions[0];
-    }
-
-    /**
-     * Destroys a given session.
-     * @param session - session to destroy
-     * @throws ExecutionException
-     * @throws NotDefinedException
-     * @throws NotEnabledException
-     * @throws NotHandledException
-     */
-    public void destroySession(TraceSessionComponent session) throws ExecutionException, NotDefinedException, NotEnabledException, NotHandledException {
-        executeCommand(session, "destroySession");
-    }
-
-    /**
-     * Starts a given session
-     * @param session - session to start
-     * @throws ExecutionException
-     * @throws NotDefinedException
-     * @throws NotEnabledException
-     * @throws NotHandledException
-     */
-    public void startSession(TraceSessionComponent session) throws ExecutionException, NotDefinedException, NotEnabledException, NotHandledException {
-        executeCommand(session, "start");
-    }
-
-    /**
-     * Stops a given session
-     * @param session - session to stop
-     * @throws ExecutionException
-     * @throws NotDefinedException
-     * @throws NotEnabledException
-     * @throws NotHandledException
-     */
-    public void stopSession(TraceSessionComponent session) throws ExecutionException, NotDefinedException, NotEnabledException, NotHandledException {
-        executeCommand(session, "stop");
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlTreeModelNoProvidersTest.java b/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlTreeModelNoProvidersTest.java
deleted file mode 100644 (file)
index b1acded..0000000
+++ /dev/null
@@ -1,160 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2015 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Alexandre Montplaisir - Port to JUnit4
- *   Markus Schorn - Bug 448058: Use org.eclipse.remote in favor of RSE
- **********************************************************************/
-
-package org.eclipse.tracecompass.lttng2.control.ui.tests.model.component;
-
-import static org.junit.Assert.assertEquals;
-import static org.junit.Assert.assertFalse;
-import static org.junit.Assert.assertNotNull;
-import static org.junit.Assert.assertNotSame;
-import static org.junit.Assert.assertTrue;
-
-import java.io.File;
-import java.net.URL;
-
-import org.eclipse.core.runtime.FileLocator;
-import org.eclipse.core.runtime.Path;
-import org.eclipse.jdt.annotation.NonNull;
-import org.eclipse.remote.core.IRemoteConnection;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TargetNodeState;
-import org.eclipse.tracecompass.internal.lttng2.control.stubs.service.TestRemoteSystemProxy;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceProviderGroup;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionGroup;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.UstProviderComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.service.ILttngControlService;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.service.LTTngControlService;
-import org.eclipse.tracecompass.tmf.remote.core.proxy.TmfRemoteConnectionFactory;
-import org.junit.After;
-import org.junit.Before;
-import org.junit.Test;
-import org.osgi.framework.FrameworkUtil;
-
-/**
- * The class <code>TraceControlTreeModelNoProvidersTest</code> verifies that the
- * Tracer Control can handle the case where no kernel provider and only UST
- * provider are available.
- */
-public class TraceControlTreeModelNoProvidersTest {
-
-    // ------------------------------------------------------------------------
-    // Constants
-    // ------------------------------------------------------------------------
-
-    private static final String TEST_STREAM = "ListInfoTest.cfg";
-    private static final String SCEN_LIST_INFO_TEST = "ListInfoTestNoKernel";
-    private static final String TARGET_NODE_NAME = "myNode";
-
-    // ------------------------------------------------------------------------
-    // Test data
-    // ------------------------------------------------------------------------
-
-    private IRemoteConnection fHost = TmfRemoteConnectionFactory.getLocalConnection();
-    private @NonNull TestRemoteSystemProxy fProxy = new TestRemoteSystemProxy(fHost);
-    private String fTestFile;
-
-    // ------------------------------------------------------------------------
-    // Housekeeping
-    // ------------------------------------------------------------------------
-
-    /**
-     * Perform pre-test initialization.
-     *
-     * @throws Exception
-     *         if the initialization fails for some reason
-     */
-    @Before
-    public void setUp() throws Exception {
-        URL location = FileLocator.find(FrameworkUtil.getBundle(this.getClass()), new Path(TraceControlTestFacility.DIRECTORY + File.separator + TEST_STREAM), null);
-        File testfile = new File(FileLocator.toFileURL(location).toURI());
-        fTestFile = testfile.getAbsolutePath();
-    }
-
-    /**
-     * Perform post-test clean-up.
-     */
-    @After
-    public void tearDown()  {
-        TraceControlTestFacility.getInstance().waitForJobs();
-    }
-
-    /**
-     * Run the TraceControlComponent.
-     */
-    @Test
-    public void testTraceControlComponents() {
-
-        fProxy.setTestFile(fTestFile);
-        fProxy.setScenario(SCEN_LIST_INFO_TEST);
-
-        ITraceControlComponent root = TraceControlTestFacility.getInstance().getControlView().getTraceControlRoot();
-
-        TargetNodeComponent node = new TargetNodeComponent(TARGET_NODE_NAME, root, fProxy);
-
-        root.addChild(node);
-        node.connect();
-
-        TraceControlTestFacility.getInstance().waitForConnect(node);
-        TraceControlTestFacility.getInstance().waitForJobs();
-
-        // ------------------------------------------------------------------------
-        // Verify Parameters of TargetNodeComponent
-        // ------------------------------------------------------------------------
-        assertEquals("Local", node.getToolTip()); // assigned in createLocalHost() above
-        Image connectedImage = node.getImage();
-        assertNotNull(connectedImage);
-        assertEquals(TargetNodeState.CONNECTED, node.getTargetNodeState());
-        assertNotNull(node.getControlService());
-        ILttngControlService service = node.getControlService();
-        assertTrue(service instanceof LTTngControlService);
-        node.setControlService(service);
-        assertTrue(node.getControlService() instanceof LTTngControlService);
-
-        // ------------------------------------------------------------------------
-        // Verify Children of TargetNodeComponent
-        // ------------------------------------------------------------------------
-        ITraceControlComponent[] groups = node.getChildren();
-        assertNotNull(groups);
-        assertEquals(2, groups.length);
-
-        assertTrue(groups[0] instanceof TraceProviderGroup);
-        assertTrue(groups[1] instanceof TraceSessionGroup);
-
-        // Check for kernel provider
-        TraceProviderGroup providerGroup = (TraceProviderGroup) groups[0];
-        assertFalse(providerGroup.hasKernelProvider());
-
-        assertEquals("Provider", providerGroup.getName());
-        assertEquals("Sessions", groups[1].getName());
-
-        // ------------------------------------------------------------------------
-        // Verify TraceProviderGroup
-        // ------------------------------------------------------------------------
-        ITraceControlComponent[] providers = groups[0].getChildren();
-
-        assertNotNull(providers);
-        assertEquals(1, providers.length);
-        assertTrue(providers[0] instanceof UstProviderComponent);
-
-        // disconnect
-        node.disconnect();
-        assertEquals(TargetNodeState.DISCONNECTED, node.getTargetNodeState());
-        assertNotNull(node.getImage());
-        assertNotSame(connectedImage, node.getImage());
-
-        node.getParent().removeChild(node);
-    }
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlTreeModelTest.java b/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlTreeModelTest.java
deleted file mode 100644 (file)
index e323130..0000000
+++ /dev/null
@@ -1,693 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2015 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Alexandre Montplaisir - Port to JUnit4
- *   Markus Schorn - Bug 448058: Use org.eclipse.remote in favor of RSE
- **********************************************************************/
-
-package org.eclipse.tracecompass.lttng2.control.ui.tests.model.component;
-
-import static org.junit.Assert.assertEquals;
-import static org.junit.Assert.assertFalse;
-import static org.junit.Assert.assertNotNull;
-import static org.junit.Assert.assertNotSame;
-import static org.junit.Assert.assertNull;
-import static org.junit.Assert.assertTrue;
-
-import java.io.File;
-import java.net.URL;
-
-import org.eclipse.core.runtime.FileLocator;
-import org.eclipse.core.runtime.Path;
-import org.eclipse.jdt.annotation.NonNull;
-import org.eclipse.remote.core.IRemoteConnection;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.LogLevelType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TargetNodeState;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceChannelOutputType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEnablement;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEventType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
-import org.eclipse.tracecompass.internal.lttng2.control.stubs.service.TestRemoteSystemProxy;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.BaseEventComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.KernelProviderComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceEventComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceProbeEventComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceProviderGroup;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionGroup;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.UstProviderComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.service.ILttngControlService;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.service.LTTngControlService;
-import org.eclipse.tracecompass.tmf.remote.core.proxy.TmfRemoteConnectionFactory;
-import org.junit.After;
-import org.junit.Before;
-import org.junit.Test;
-import org.osgi.framework.FrameworkUtil;
-
-/**
- * The class <code>TraceControlTreeModelTest</code> contains tests for the tree
- * component classes.
- */
-public class TraceControlTreeModelTest {
-
-    // ------------------------------------------------------------------------
-    // Constants
-    // ------------------------------------------------------------------------
-
-    private static final String TEST_STREAM = "ListInfoTest.cfg";
-    private static final String SCEN_LIST_INFO_TEST = "ListInfoTest";
-    private static final String TARGET_NODE_NAME = "myNode";
-
-    // ------------------------------------------------------------------------
-    // Test data
-    // ------------------------------------------------------------------------
-
-    private IRemoteConnection fHost = TmfRemoteConnectionFactory.getLocalConnection();
-    private @NonNull TestRemoteSystemProxy fProxy = new TestRemoteSystemProxy(fHost);
-    private String fTestFile;
-
-    // ------------------------------------------------------------------------
-    // Housekeeping
-    // ------------------------------------------------------------------------
-
-    /**
-     * Perform pre-test initialization.
-     *
-     * @throws Exception
-     *         if the initialization fails for some reason
-     */
-    @Before
-    public void setUp() throws Exception {
-        URL location = FileLocator.find(FrameworkUtil.getBundle(this.getClass()), new Path(TraceControlTestFacility.DIRECTORY + File.separator + TEST_STREAM), null);
-        File testfile = new File(FileLocator.toFileURL(location).toURI());
-        fTestFile = testfile.getAbsolutePath();
-    }
-
-    /**
-     * Perform post-test clean-up.
-     */
-    @After
-    public void tearDown() {
-        TraceControlTestFacility.getInstance().waitForJobs();
-    }
-
-    /**
-     * Run the TraceControlComponent.
-     */
-    @Test
-    public void testTraceControlComponents() {
-
-        fProxy.setTestFile(fTestFile);
-        fProxy.setScenario(SCEN_LIST_INFO_TEST);
-
-        ITraceControlComponent root = TraceControlTestFacility.getInstance().getControlView().getTraceControlRoot();
-
-        TargetNodeComponent node = new TargetNodeComponent(TARGET_NODE_NAME, root, fProxy);
-
-        root.addChild(node);
-        node.connect();
-
-        TraceControlTestFacility.getInstance().waitForConnect(node);
-        TraceControlTestFacility.getInstance().waitForJobs();
-
-        // ------------------------------------------------------------------------
-        // Verify Parameters of TargetNodeComponent
-        // ------------------------------------------------------------------------
-        assertEquals("Local", node.getToolTip()); // assigned in createLocalHost() above
-        Image connectedImage = node.getImage();
-        assertNotNull(connectedImage);
-        assertEquals(TargetNodeState.CONNECTED, node.getTargetNodeState());
-        assertNotNull(node.getControlService());
-        ILttngControlService service = node.getControlService();
-        assertTrue(service instanceof LTTngControlService);
-        node.setControlService(service);
-        assertTrue(node.getControlService() instanceof LTTngControlService);
-
-
-        // ------------------------------------------------------------------------
-        // Verify Children of TargetNodeComponent
-        // ------------------------------------------------------------------------
-        ITraceControlComponent[] groups = node.getChildren();
-        assertNotNull(groups);
-        assertEquals(2, groups.length);
-
-        assertTrue(groups[0] instanceof TraceProviderGroup);
-        assertTrue(groups[1] instanceof TraceSessionGroup);
-
-        assertEquals("Provider", groups[0].getName());
-        assertEquals("Sessions", groups[1].getName());
-
-        // ------------------------------------------------------------------------
-        // Verify TraceProviderGroup
-        // ------------------------------------------------------------------------
-        ITraceControlComponent[] providers = groups[0].getChildren();
-
-        assertNotNull(providers);
-        assertEquals(3, providers.length);
-
-        // ------------------------------------------------------------------------
-        // Verify KernelProviderComponent
-        // ------------------------------------------------------------------------
-        KernelProviderComponent kernelProvider = (KernelProviderComponent) providers[0];
-
-        // ------------------------------------------------------------------------
-        // Verify event info (kernel provider)
-        // ------------------------------------------------------------------------
-        ITraceControlComponent[] events = kernelProvider.getChildren();
-        assertNotNull(events);
-        assertEquals(3, events.length);
-
-        BaseEventComponent baseEventInfo = (BaseEventComponent) events[0];
-        assertNotNull(baseEventInfo);
-        assertEquals("sched_kthread_stop", baseEventInfo.getName());
-        assertEquals(TraceLogLevel.TRACE_EMERG, baseEventInfo.getLogLevel());
-        assertEquals(TraceEventType.TRACEPOINT, baseEventInfo.getEventType());
-
-        baseEventInfo = (BaseEventComponent) events[1];
-        assertEquals("sched_kthread_stop_ret", baseEventInfo.getName());
-        assertEquals(TraceLogLevel.TRACE_EMERG, baseEventInfo.getLogLevel());
-        assertEquals(TraceEventType.TRACEPOINT, baseEventInfo.getEventType());
-
-        baseEventInfo = (BaseEventComponent) events[2];
-        assertEquals("sched_wakeup_new", baseEventInfo.getName());
-        assertEquals(TraceLogLevel.TRACE_EMERG, baseEventInfo.getLogLevel());
-        assertEquals(TraceEventType.TRACEPOINT, baseEventInfo.getEventType());
-
-        // ------------------------------------------------------------------------
-        // Verify UstProviderComponent
-        // ------------------------------------------------------------------------
-        UstProviderComponent ustProvider = (UstProviderComponent) providers[1];
-        assertEquals("/home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello [PID=9379]", ustProvider.getName());
-        assertEquals(9379, ustProvider.getPid());
-
-        // ------------------------------------------------------------------------
-        // Verify event info (UST provider)
-        // ------------------------------------------------------------------------
-        events = ustProvider.getChildren();
-        assertNotNull(events);
-        assertEquals(2, events.length);
-
-        baseEventInfo = (BaseEventComponent) events[0];
-        assertNotNull(baseEventInfo);
-        assertEquals("ust_tests_hello:tptest_sighandler", baseEventInfo.getName());
-        assertEquals(TraceLogLevel.TRACE_DEBUG_MODULE, baseEventInfo.getLogLevel());
-        assertEquals(TraceEventType.TRACEPOINT, baseEventInfo.getEventType());
-
-        baseEventInfo = (BaseEventComponent) events[1];
-        assertEquals("ust_tests_hello:tptest", baseEventInfo.getName());
-        assertEquals(TraceLogLevel.TRACE_INFO, baseEventInfo.getLogLevel());
-        assertEquals(TraceEventType.TRACEPOINT, baseEventInfo.getEventType());
-
-        // ------------------------------------------------------------------------
-        // Verify UstProviderComponent
-        // ------------------------------------------------------------------------
-        ustProvider = (UstProviderComponent) providers[2];
-        assertEquals("/home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello [PID=4852]", ustProvider.getName());
-        assertEquals(4852, ustProvider.getPid());
-
-        // verify getters and setter
-        verifyUstProviderGettersSetters(ustProvider);
-
-        // ------------------------------------------------------------------------
-        // Verify event info (UST provider)
-        // ------------------------------------------------------------------------
-        events = ustProvider.getChildren();
-        assertNotNull(events);
-        assertEquals(2, events.length);
-
-        baseEventInfo = (BaseEventComponent) events[0];
-        assertNotNull(baseEventInfo);
-        assertEquals("ust_tests_hello:tptest_sighandler", baseEventInfo.getName());
-        assertEquals(TraceLogLevel.TRACE_WARNING, baseEventInfo.getLogLevel());
-        assertEquals(TraceEventType.TRACEPOINT, baseEventInfo.getEventType());
-
-        baseEventInfo = (BaseEventComponent) events[1];
-        assertEquals("ust_tests_hello:tptest", baseEventInfo.getName());
-        assertEquals(TraceLogLevel.TRACE_DEBUG_FUNCTION, baseEventInfo.getLogLevel());
-        assertEquals(TraceEventType.TRACEPOINT, baseEventInfo.getEventType());
-
-        // verify getters and setters
-        verifyBaseEventGettersSetters(baseEventInfo);
-
-        // ------------------------------------------------------------------------
-        // Verify TraceSessionGroup
-        // ------------------------------------------------------------------------
-        ITraceControlComponent[] sessions = groups[1].getChildren();
-        assertNotNull(sessions);
-        assertEquals(2, sessions.length);
-        for (int i = 0; i < sessions.length; i++) {
-            assertTrue(sessions[i] instanceof TraceSessionComponent);
-        }
-        assertEquals("mysession1", sessions[0].getName());
-        assertEquals("mysession", sessions[1].getName());
-
-        // ------------------------------------------------------------------------
-        // Verify TraceSessionComponent
-        // ------------------------------------------------------------------------
-        TraceSessionComponent session = (TraceSessionComponent)sessions[1];
-        assertEquals("mysession", session.getName());
-        assertEquals("/home/user/lttng-traces/mysession-20120129-084256", session.getSessionPath());
-        assertEquals(TraceSessionState.ACTIVE, session.getSessionState());
-
-        // Verify setters and setters
-        verifySessionGetterSetters(session);
-
-        ITraceControlComponent[] domains = session.getChildren();
-        assertNotNull(domains);
-        assertEquals(2, domains.length);
-
-        // ------------------------------------------------------------------------
-        // Verify Kernel domain
-        // ------------------------------------------------------------------------
-        assertEquals("Kernel", domains[0].getName());
-        ITraceControlComponent[] channels =  domains[0].getChildren();
-        assertNotNull(channels);
-        assertEquals(2, channels.length);
-
-        // Verify setters and setters
-        verifyDomainGettersSetters((TraceDomainComponent) domains[0]);
-
-        // ------------------------------------------------------------------------
-        // Verify Kernel's channel0
-        // ------------------------------------------------------------------------
-        assertTrue(channels[0] instanceof TraceChannelComponent);
-        TraceChannelComponent channel = (TraceChannelComponent) channels[0];
-        assertEquals("channel0", channel.getName());
-        assertEquals(4, channel.getNumberOfSubBuffers());
-        assertEquals("splice()", channel.getOutputType().getInName());
-        assertEquals(TraceChannelOutputType.SPLICE, channel.getOutputType());
-        assertEquals(false, channel.isOverwriteMode());
-        assertEquals(200, channel.getReadTimer());
-        assertEquals(TraceEnablement.ENABLED, channel.getState());
-        assertEquals(262144, channel.getSubBufferSize());
-        assertEquals(0, channel.getSwitchTimer());
-
-        // ------------------------------------------------------------------------
-        // Verify event info (kernel, channel0)
-        // ------------------------------------------------------------------------
-        ITraceControlComponent[] channel0Events = channel.getChildren();
-        assertNotNull(channel0Events);
-        assertEquals(5, channel0Events.length);
-        assertTrue(channel0Events[0] instanceof TraceEventComponent);
-        assertTrue(channel0Events[1] instanceof TraceEventComponent);
-        assertTrue(channel0Events[2] instanceof TraceProbeEventComponent);
-        assertTrue(channel0Events[3] instanceof TraceProbeEventComponent);
-        assertTrue(channel0Events[4] instanceof TraceEventComponent);
-
-        TraceEventComponent event = (TraceEventComponent) channel0Events[0];
-        assertEquals("block_rq_remap", event.getName());
-        assertEquals(TraceLogLevel.TRACE_EMERG, event.getLogLevel());
-        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
-        assertEquals(TraceEnablement.ENABLED, event.getState());
-
-        event = (TraceEventComponent) channel0Events[1];
-        assertEquals("block_bio_remap", event.getName());
-        assertEquals(TraceLogLevel.TRACE_EMERG, event.getLogLevel());
-        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
-        assertEquals(TraceEnablement.DISABLED, event.getState());
-
-        TraceProbeEventComponent probeEvent = (TraceProbeEventComponent) channel0Events[2];
-        assertEquals("myevent2", probeEvent.getName());
-        assertEquals(TraceLogLevel.LEVEL_UNKNOWN, probeEvent.getLogLevel());
-        assertEquals(TraceEventType.PROBE, probeEvent.getEventType());
-        assertEquals(TraceEnablement.ENABLED, probeEvent.getState());
-        assertEquals("0xc0101340", probeEvent.getAddress());
-        assertNull(probeEvent.getOffset());
-        assertNull(probeEvent.getSymbol());
-
-        // verify getters and setter
-        verifyProbeEventGettersSetters(probeEvent);
-
-        probeEvent = (TraceProbeEventComponent) channel0Events[3];
-        assertEquals("myevent0", probeEvent.getName());
-        assertEquals(TraceLogLevel.LEVEL_UNKNOWN, probeEvent.getLogLevel());
-        assertEquals(TraceEventType.PROBE, probeEvent.getEventType());
-        assertEquals(TraceEnablement.ENABLED, probeEvent.getState());
-        assertNull(probeEvent.getAddress());
-        assertEquals("0x0", probeEvent.getOffset());
-        assertEquals("init_post", probeEvent.getSymbol());
-
-        event = (TraceEventComponent) channel0Events[4];
-        assertEquals("syscalls", event.getName());
-        assertEquals(TraceLogLevel.LEVEL_UNKNOWN, event.getLogLevel());
-        assertEquals(TraceEventType.SYSCALL, event.getEventType());
-        assertEquals(TraceEnablement.ENABLED, event.getState());
-
-        // ------------------------------------------------------------------------
-        // Verify Kernel's channel1
-        // ------------------------------------------------------------------------
-        assertEquals("channel1", channels[1].getName());
-        channel = (TraceChannelComponent) channels[1];
-        assertEquals(4, channel.getNumberOfSubBuffers());
-        assertEquals("splice()", channel.getOutputType().getInName());
-        assertEquals(TraceChannelOutputType.SPLICE, channel.getOutputType());
-        assertEquals(true, channel.isOverwriteMode());
-        assertEquals(400, channel.getReadTimer());
-        assertEquals(TraceEnablement.DISABLED, channel.getState());
-        assertEquals(524288, channel.getSubBufferSize());
-        assertEquals(100, channel.getSwitchTimer());
-
-        // ------------------------------------------------------------------------
-        // Verify event info (kernel, channel1)
-        // ------------------------------------------------------------------------
-        ITraceControlComponent[] channel1Events = channels[1].getChildren();
-        assertEquals(0, channel1Events.length);
-
-        // ------------------------------------------------------------------------
-        // Verify domain UST global
-        // ------------------------------------------------------------------------
-        assertEquals("UST global", domains[1].getName());
-
-        ITraceControlComponent[] ustChannels = domains[1].getChildren();
-
-        for (int i = 0; i < ustChannels.length; i++) {
-            assertTrue(ustChannels[i] instanceof TraceChannelComponent);
-        }
-
-        // ------------------------------------------------------------------------
-        // Verify UST global's mychannel1
-        // ------------------------------------------------------------------------
-        channel = (TraceChannelComponent) ustChannels[0];
-        assertEquals("mychannel1", channel.getName());
-        assertEquals(8, channel.getNumberOfSubBuffers());
-        assertEquals("mmap()", channel.getOutputType().getInName());
-        assertEquals(TraceChannelOutputType.MMAP, channel.getOutputType());
-        assertEquals(true, channel.isOverwriteMode());
-        assertEquals(100, channel.getReadTimer());
-        assertEquals(TraceEnablement.DISABLED, channel.getState());
-        assertEquals(8192, channel.getSubBufferSize());
-        assertEquals(200, channel.getSwitchTimer());
-
-        // verify getters and setters
-        verifyChannelGettersSetters(channel);
-
-        // ------------------------------------------------------------------------
-        // Verify event info (UST global, mychannel1)
-        // ------------------------------------------------------------------------
-        ITraceControlComponent[] ustEvents = channel.getChildren();
-        assertEquals(0, ustEvents.length);
-
-        // ------------------------------------------------------------------------
-        // Verify UST global's channel0
-        // ------------------------------------------------------------------------
-        channel = (TraceChannelComponent) ustChannels[1];
-        assertEquals("channel0", channel.getName());
-        assertEquals(4, channel.getNumberOfSubBuffers());
-        assertEquals("mmap()", channel.getOutputType().getInName());
-        assertEquals(TraceChannelOutputType.MMAP, channel.getOutputType());
-        assertEquals(false, channel.isOverwriteMode());
-        assertEquals(200, channel.getReadTimer());
-        assertEquals(TraceEnablement.ENABLED, channel.getState());
-        assertEquals(4096, channel.getSubBufferSize());
-        assertEquals(0, channel.getSwitchTimer());
-
-        // ------------------------------------------------------------------------
-        // Verify event info (UST global, channel0)
-        // ------------------------------------------------------------------------
-        ustEvents = channel.getChildren();
-        assertEquals(4, ustEvents.length);
-
-        event = (TraceEventComponent) ustEvents[0];
-        assertEquals("ust_tests_hello:tptest_sighandler", event.getName());
-        assertEquals(TraceLogLevel.TRACE_DEBUG_LINE, event.getLogLevel());
-        assertEquals(LogLevelType.LOGLEVEL_ONLY, event.getLogLevelType());
-        assertEquals(LogLevelType.LOGLEVEL_ONLY.getShortName(), event.getLogLevelType().getShortName());
-        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
-        assertEquals(TraceEnablement.DISABLED, event.getState());
-
-        event = (TraceEventComponent) ustEvents[1];
-        assertEquals("ust_tests_hello:tptest_sighandler1", event.getName());
-        assertEquals(TraceLogLevel.TRACE_INFO, event.getLogLevel());
-        assertEquals(LogLevelType.LOGLEVEL, event.getLogLevelType());
-        assertEquals(LogLevelType.LOGLEVEL.getShortName(), event.getLogLevelType().getShortName());
-        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
-        assertEquals(TraceEnablement.DISABLED, event.getState());
-
-        event = (TraceEventComponent) ustEvents[2];
-        assertEquals("ust_tests_hello:tptest_sighandler2", event.getName());
-        assertEquals(TraceLogLevel.TRACE_DEBUG_SYSTEM, event.getLogLevel());
-        assertEquals(LogLevelType.LOGLEVEL_NONE, event.getLogLevelType());
-        assertEquals(LogLevelType.LOGLEVEL_NONE.getShortName(), event.getLogLevelType().getShortName());
-        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
-        assertEquals(TraceEnablement.DISABLED, event.getState());
-
-        event = (TraceEventComponent) ustEvents[3];
-        assertEquals("*", event.getName());
-        assertEquals(TraceLogLevel.LEVEL_UNKNOWN, event.getLogLevel());
-        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
-        assertEquals(TraceEnablement.ENABLED, event.getState());
-
-        // verify getters and setters
-        verifyEventGettersSetters(event);
-
-        // disconnect
-        node.disconnect();
-        assertEquals(TargetNodeState.DISCONNECTED, node.getTargetNodeState());
-        assertNotNull(node.getImage());
-        assertNotSame(connectedImage, node.getImage());
-
-        node.getParent().removeChild(node);
-    }
-
-    private static void verifySessionGetterSetters(TraceSessionComponent session) {
-        // save original values
-        String name = session.getName();
-        String origPath = session.getSessionPath();
-        TraceSessionState origState = session.getSessionState();
-
-        // test cases
-        session.setName("newName");
-        assertEquals("newName", session.getName());
-
-        session.setSessionPath("/home/user/tmp");
-        assertEquals("/home/user/tmp", session.getSessionPath());
-
-        session.setSessionState(TraceSessionState.INACTIVE);
-        assertEquals(TraceSessionState.INACTIVE, session.getSessionState());
-        Image inactiveImage = session.getImage();
-        assertNotNull(inactiveImage);
-
-        session.setSessionState("active");
-        assertEquals(TraceSessionState.ACTIVE, session.getSessionState());
-
-        Image activeImage = session.getImage();
-        assertNotNull(activeImage);
-        assertNotSame(activeImage, inactiveImage);
-
-        ITraceControlComponent[] children = session.getChildren();
-        TraceDomainComponent[] domains = session.getDomains();
-
-        assertEquals(children.length, domains.length);
-
-        for (int i = 0; i < domains.length; i++) {
-            assertEquals(domains[i].getName(), children[i].getName());
-        }
-
-        // restore original values
-        session.setName(name);
-        session.setSessionPath(origPath);
-        session.setSessionState(origState);
-    }
-
-    private static void verifyDomainGettersSetters(TraceDomainComponent domain) {
-        // save original values
-        boolean isKernel = domain.isKernel();
-
-        domain.setIsKernel(false);
-        assertFalse(domain.isKernel());
-        domain.setIsKernel(true);
-        assertTrue(domain.isKernel());
-
-        ITraceControlComponent[] children = domain.getChildren();
-        TraceChannelComponent[] channels = domain.getChannels();
-
-        assertEquals(children.length, channels.length);
-
-        for (int i = 0; i < channels.length; i++) {
-            assertEquals(channels[i].getName(), children[i].getName());
-        }
-
-        String nodeName = domain.getTargetNode().getName();
-        assertEquals(TARGET_NODE_NAME, nodeName);
-
-        // restore original values
-        domain.setIsKernel(isKernel);
-    }
-
-    private static void verifyBaseEventGettersSetters(BaseEventComponent event) {
-        // save original values
-        String name =  event.getName();
-        TraceLogLevel level = event.getLogLevel();
-        TraceEventType type = event.getEventType();
-
-        // test cases
-        event.setName("newName");
-        assertEquals("newName", event.getName());
-
-        event.setLogLevel(TraceLogLevel.TRACE_INFO);
-        assertEquals(TraceLogLevel.TRACE_INFO, event.getLogLevel());
-        event.setLogLevel("TRACE_ALERT");
-        assertEquals(TraceLogLevel.TRACE_ALERT, event.getLogLevel());
-
-        event.setEventType(TraceEventType.UNKNOWN);
-        assertEquals(TraceEventType.UNKNOWN, event.getEventType());
-        event.setEventType("tracepoint");
-        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
-
-        // restore original values
-        event.setName(name);
-        event.setLogLevel(level);
-        event.setEventType(type);
-    }
-
-    private static void verifyEventGettersSetters(TraceEventComponent event) {
-        // save original values
-        String name =  event.getName();
-        TraceLogLevel level = event.getLogLevel();
-        TraceEventType type = event.getEventType();
-        TraceEnablement state = event.getState();
-
-        // test cases
-        event.setName("newName");
-        assertEquals("newName", event.getName());
-
-        event.setLogLevel(TraceLogLevel.TRACE_INFO);
-        assertEquals(TraceLogLevel.TRACE_INFO, event.getLogLevel());
-        event.setLogLevel("TRACE_ALERT");
-        assertEquals(TraceLogLevel.TRACE_ALERT, event.getLogLevel());
-
-        event.setEventType(TraceEventType.UNKNOWN);
-        assertEquals(TraceEventType.UNKNOWN, event.getEventType());
-        event.setEventType("tracepoint");
-        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
-
-        event.setState("disabled");
-        assertEquals(TraceEnablement.DISABLED, event.getState());
-
-        Image disabledImage = event.getImage();
-        assertNotNull(disabledImage);
-
-        event.setState(TraceEnablement.ENABLED);
-        assertEquals(TraceEnablement.ENABLED, event.getState());
-
-        Image enabledImage = event.getImage();
-        assertNotNull(enabledImage);
-        assertNotSame(enabledImage, disabledImage);
-
-        // restore original values
-        event.setName(name);
-        event.setLogLevel(level);
-        event.setEventType(type);
-        event.setState(state);
-    }
-
-    private static void verifyProbeEventGettersSetters(TraceProbeEventComponent event) {
-        // save original values
-        String address = event.getAddress();
-        String offset = event.getOffset();
-        String symbol = event.getSymbol();
-
-        // test cases
-        event.setAddress("0xffff1234");
-        assertEquals("0xffff1234", event.getAddress());
-
-        event.setOffset("0x1234");
-        assertEquals("0x1234", event.getOffset());
-
-        event.setSymbol("init");
-        assertEquals("init", event.getSymbol());
-
-        // restore original values
-        event.setAddress(address);
-        event.setOffset(offset);
-        event.setSymbol(symbol);
-    }
-
-    private static void verifyChannelGettersSetters(TraceChannelComponent channel) {
-        // save original values
-        String name = channel.getName();
-        int nbSubBuffers = channel.getNumberOfSubBuffers();
-        TraceChannelOutputType type = channel.getOutputType();
-        boolean mode = channel.isOverwriteMode();
-        long readTimer = channel.getReadTimer();
-        TraceEnablement state =  channel.getState();
-        long subBufferSize = channel.getSubBufferSize();
-        long switchTimer = channel.getSwitchTimer();
-
-        // test cases
-        channel.setName("newName");
-        assertEquals("newName", channel.getName());
-
-        channel.setNumberOfSubBuffers(2);
-        assertEquals(2, channel.getNumberOfSubBuffers());
-
-        channel.setOutputType("splice()");
-        assertEquals("splice()", channel.getOutputType().getInName());
-        assertEquals(TraceChannelOutputType.SPLICE, channel.getOutputType());
-
-        channel.setOverwriteMode(false);
-        assertEquals(false, channel.isOverwriteMode());
-
-        channel.setReadTimer(250);
-        assertEquals(250, channel.getReadTimer());
-
-        channel.setState("enabled");
-        assertEquals(TraceEnablement.ENABLED, channel.getState());
-
-        Image enabledImage = channel.getImage();
-        assertNotNull(enabledImage);
-        channel.setState(TraceEnablement.DISABLED);
-        assertEquals(TraceEnablement.DISABLED, channel.getState());
-
-        Image disabledImage = channel.getImage();
-        assertNotNull(disabledImage);
-        assertNotSame(enabledImage, disabledImage);
-
-        channel.setSubBufferSize(1024);
-        assertEquals(1024, channel.getSubBufferSize());
-
-        channel.setSwitchTimer(1000);
-        assertEquals(1000, channel.getSwitchTimer());
-
-        // restore original values
-        channel.setName(name);
-        channel.setNumberOfSubBuffers(nbSubBuffers);
-        channel.setOutputType(type);
-        channel.setOverwriteMode(mode);
-        channel.setReadTimer(readTimer);
-        channel.setState(state);
-        channel.setSubBufferSize(subBufferSize);
-        channel.setSwitchTimer(switchTimer);
-    }
-
-    private static void verifyUstProviderGettersSetters(UstProviderComponent ustProvider) {
-        // save original values
-        String name = ustProvider.getName();
-        int pid = ustProvider.getPid();
-
-        // test cases
-        ustProvider.setName("newName");
-        assertEquals("newName", ustProvider.getName());
-
-        ustProvider.setPid(9876);
-        assertEquals(9876, ustProvider.getPid());
-
-        // restore original values
-        ustProvider.setName(name);
-        ustProvider.setPid(pid);
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlUstProviderTests.java b/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlUstProviderTests.java
deleted file mode 100644 (file)
index 47a878c..0000000
+++ /dev/null
@@ -1,294 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2015 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Alexandre Montplaisir - Port to JUnit4
- *   Markus Schorn - Bug 448058: Use org.eclipse.remote in favor of RSE
- **********************************************************************/
-
-package org.eclipse.tracecompass.lttng2.control.ui.tests.model.component;
-
-import static org.junit.Assert.assertEquals;
-import static org.junit.Assert.assertNotNull;
-import static org.junit.Assert.assertTrue;
-
-import java.io.File;
-import java.net.URL;
-
-import org.eclipse.core.runtime.FileLocator;
-import org.eclipse.core.runtime.Path;
-import org.eclipse.jdt.annotation.NonNull;
-import org.eclipse.remote.core.IRemoteConnection;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TargetNodeState;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceChannelOutputType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEnablement;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEventType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
-import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.CreateSessionDialogStub;
-import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.DestroyConfirmDialogStub;
-import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.EnableChannelDialogStub;
-import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.GetEventInfoDialogStub;
-import org.eclipse.tracecompass.internal.lttng2.control.stubs.service.TestRemoteSystemProxy;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.TraceControlDialogFactory;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.BaseEventComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.KernelProviderComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceEventComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.UstProviderComponent;
-import org.eclipse.tracecompass.tmf.remote.core.proxy.TmfRemoteConnectionFactory;
-import org.junit.After;
-import org.junit.Before;
-import org.junit.Test;
-import org.osgi.framework.FrameworkUtil;
-
-/**
- * The class <code>TraceControlUstProviderTests</code> contains UST provider
- * handling test cases.
- */
-public class TraceControlUstProviderTests {
-
-    // ------------------------------------------------------------------------
-    // Constants
-    // ------------------------------------------------------------------------
-
-    private static final String TEST_STREAM = "CreateTreeTest.cfg";
-    private static final String SCEN_SCENARIO2_TEST = "Scenario2";
-
-    // ------------------------------------------------------------------------
-    // Test data
-    // ------------------------------------------------------------------------
-    private IRemoteConnection fHost = TmfRemoteConnectionFactory.getLocalConnection();
-    private TraceControlTestFacility fFacility;
-    private @NonNull TestRemoteSystemProxy fProxy = new TestRemoteSystemProxy(fHost);
-    private String fTestFile;
-
-    // ------------------------------------------------------------------------
-    // Housekeeping
-    // ------------------------------------------------------------------------
-
-    /**
-     * Perform pre-test initialization.
-     *
-     * @throws Exception
-     *         if the initialization fails for some reason
-     */
-    @Before
-    public void setUp() throws Exception {
-        fFacility = TraceControlTestFacility.getInstance();
-        fFacility.init();
-        fProxy = new TestRemoteSystemProxy(fHost);
-        URL location = FileLocator.find(FrameworkUtil.getBundle(this.getClass()), new Path(TraceControlTestFacility.DIRECTORY + File.separator + TEST_STREAM), null);
-        File testfile = new File(FileLocator.toFileURL(location).toURI());
-        fTestFile = testfile.getAbsolutePath();
-    }
-
-    /**
-     * Perform post-test clean-up.
-     */
-    @After
-    public void tearDown() {
-        fFacility.waitForJobs();
-        fFacility.dispose();
-    }
-
-    /**
-     * Run the TraceControlComponent.
-     *
-     * @throws Exception
-     *             This will fail the test
-     */
-    @Test
-    public void testUstProviderTree() throws Exception {
-
-        fProxy.setTestFile(fTestFile);
-        fProxy.setScenario(TraceControlTestFacility.SCEN_INIT_TEST);
-
-        ITraceControlComponent root = fFacility.getControlView().getTraceControlRoot();
-
-        TargetNodeComponent node = new TargetNodeComponent("myNode", root, fProxy);
-        root.addChild(node);
-
-        fFacility.waitForJobs();
-
-        fFacility.executeCommand(node, "connect");
-
-        int i = 0;
-        while ((i < 10) && (node.getTargetNodeState() != TargetNodeState.CONNECTED)) {
-            i++;
-            fFacility.delay(TraceControlTestFacility.GUI_REFESH_DELAY);
-        }
-
-        // Verify that node is connected
-        assertEquals(TargetNodeState.CONNECTED, node.getTargetNodeState());
-
-        // Get provider groups
-        ITraceControlComponent[] groups = node.getChildren();
-        assertNotNull(groups);
-        assertEquals(2, groups.length);
-
-        // Get kernel provider
-        ITraceControlComponent[] providers = groups[0].getChildren();
-        KernelProviderComponent kernelProvider = (KernelProviderComponent) providers[0];
-
-        // Get kernel provider events and select 2 events
-        ITraceControlComponent[] events = kernelProvider.getChildren();
-        assertNotNull(events);
-        assertEquals(3, events.length);
-
-        BaseEventComponent baseEventInfo0 = (BaseEventComponent) events[0];
-        BaseEventComponent baseEventInfo1  = (BaseEventComponent) events[1];
-
-        // Initialize dialog implementations for command execution
-        TraceControlDialogFactory.getInstance().setCreateSessionDialog(new CreateSessionDialogStub());
-        TraceControlDialogFactory.getInstance().setGetEventInfoDialog(new GetEventInfoDialogStub());
-        TraceControlDialogFactory.getInstance().setConfirmDialog(new DestroyConfirmDialogStub());
-
-        // ------------------------------------------------------------------------
-        // Create session
-        // ------------------------------------------------------------------------
-        // Initialize session handling scenario
-        fProxy.setScenario(TraceControlTestFacility.SCEN_SCENARIO_SESSION_HANDLING_WITH_PATH);
-
-        CreateSessionDialogStub sessionDialogStub = new CreateSessionDialogStub();
-        sessionDialogStub.setSessionPath("/home/user/temp");
-        TraceControlDialogFactory.getInstance().setCreateSessionDialog(sessionDialogStub);
-
-        TraceSessionComponent session = fFacility.createSession(groups[1]);
-
-        // Verify that session was created
-        assertNotNull(session);
-        assertEquals("mysession", session.getName());
-        assertEquals("/home/user/temp", session.getSessionPath());
-        assertEquals(TraceSessionState.INACTIVE, session.getSessionState());
-
-        // ------------------------------------------------------------------------
-        // Enable Channel on UST global domain
-        // ------------------------------------------------------------------------
-        fProxy.setScenario(SCEN_SCENARIO2_TEST);
-        EnableChannelDialogStub channelDialogStub = new EnableChannelDialogStub();
-        channelDialogStub.setIsKernel(false);
-        channelDialogStub.getChannelInfo().setOverwriteMode(false);
-        channelDialogStub.getChannelInfo().setSwitchTimer(200);
-        channelDialogStub.getChannelInfo().setReadTimer(100);
-        channelDialogStub.getChannelInfo().setNumberOfSubBuffers(2);
-        TraceControlDialogFactory.getInstance().setEnableChannelDialog(channelDialogStub);
-
-        fFacility.executeCommand(session, "enableChannelOnSession");
-
-        // Verify that UST domain was created
-        ITraceControlComponent[] domains = session.getChildren();
-        assertNotNull(domains);
-        assertEquals(1, domains.length);
-
-        assertEquals("UST global", domains[0].getName());
-
-        // Verify that channel was created with correct data
-        ITraceControlComponent[]channels =  domains[0].getChildren();
-        assertNotNull(channels);
-        assertEquals(1, channels.length);
-
-        assertTrue(channels[0] instanceof TraceChannelComponent);
-        TraceChannelComponent channel = (TraceChannelComponent) channels[0];
-        assertEquals("mychannel", channel.getName());
-        assertEquals(2, channel.getNumberOfSubBuffers());
-        assertEquals("mmap()", channel.getOutputType().getInName());
-        assertEquals(TraceChannelOutputType.MMAP, channel.getOutputType());
-        assertEquals(false, channel.isOverwriteMode());
-        assertEquals(100, channel.getReadTimer());
-        assertEquals(TraceEnablement.ENABLED, channel.getState());
-        assertEquals(16384, channel.getSubBufferSize());
-        assertEquals(200, channel.getSwitchTimer());
-
-        // ------------------------------------------------------------------------
-        // Enable event on default channel on created session above
-        // ------------------------------------------------------------------------
-        // Get first UST provider
-        UstProviderComponent ustProvider = (UstProviderComponent) providers[1];
-        assertEquals("/home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello [PID=9379]", ustProvider.getName());
-        assertEquals(9379, ustProvider.getPid());
-
-        // Get events
-        events = ustProvider.getChildren();
-        assertNotNull(events);
-        assertEquals(2, events.length);
-
-        baseEventInfo0 = (BaseEventComponent) events[0];
-        baseEventInfo1 = (BaseEventComponent) events[1];
-
-        ITraceControlComponent[] ustSelection =  { baseEventInfo0, baseEventInfo1 };
-
-        fFacility.executeCommand(ustSelection, "assign.event");
-
-        // verify that events were created under the channel
-        // Note that domain and channel has to be re-read because the tree is re-created
-
-        domains = session.getChildren();
-
-        // Verify that channel was created with correct data
-        channels =  domains[0].getChildren();
-
-        ITraceControlComponent[] ustEvents = channels[0].getChildren();
-        assertEquals(2, ustEvents.length);
-
-        TraceEventComponent event = (TraceEventComponent) ustEvents[0];
-        assertEquals("ust_tests_hello:tptest_sighandler", event.getName());
-        assertEquals(TraceLogLevel.LEVEL_UNKNOWN, event.getLogLevel());
-        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
-        assertEquals(TraceEnablement.ENABLED, event.getState());
-
-        event = (TraceEventComponent) ustEvents[1];
-        assertEquals("ust_tests_hello:tptest", ustEvents[1].getName());
-        assertEquals(TraceLogLevel.LEVEL_UNKNOWN, event.getLogLevel());
-        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
-        assertEquals(TraceEnablement.ENABLED, event.getState());
-
-        // ------------------------------------------------------------------------
-        // Disable event components
-        // ------------------------------------------------------------------------
-        fFacility.executeCommand(event, "disableEvent");
-
-        assertEquals(TraceEnablement.DISABLED, event.getState());
-
-        // ------------------------------------------------------------------------
-        // Enable event component
-        // ------------------------------------------------------------------------
-        fFacility.executeCommand(event, "enableEvent");
-
-        // Verify event state
-        assertEquals(TraceEnablement.ENABLED, event.getState());
-
-        // ------------------------------------------------------------------------
-        // Destroy session
-        // ------------------------------------------------------------------------
-
-        // Initialize session handling scenario
-        fProxy.setScenario(TraceControlTestFacility.SCEN_SCENARIO_SESSION_HANDLING);
-
-        fFacility.destroySession(session);
-
-        // Verify that no more session components exist
-        assertEquals(0, groups[1].getChildren().length);
-
-        //-------------------------------------------------------------------------
-        // Disconnect node
-        //-------------------------------------------------------------------------
-        fFacility.executeCommand(node, "disconnect");
-        assertEquals(TargetNodeState.DISCONNECTED, node.getTargetNodeState());
-
-        //-------------------------------------------------------------------------
-        // Delete node
-        //-------------------------------------------------------------------------
-        fFacility.executeCommand(node, "delete");
-        assertEquals(0,fFacility.getControlView().getTraceControlRoot().getChildren().length);
-   }
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlUstSessionTests.java b/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlUstSessionTests.java
deleted file mode 100644 (file)
index 00e929e..0000000
+++ /dev/null
@@ -1,545 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2015 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Alexandre Montplaisir - Port to JUnit4
- *   Markus Schorn - Bug 448058: Use org.eclipse.remote in favor of RSE
- **********************************************************************/
-
-package org.eclipse.tracecompass.lttng2.control.ui.tests.model.component;
-
-import static org.junit.Assert.assertEquals;
-import static org.junit.Assert.assertNotNull;
-import static org.junit.Assert.assertTrue;
-
-import java.io.File;
-import java.net.URL;
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.core.runtime.FileLocator;
-import org.eclipse.core.runtime.Path;
-import org.eclipse.jdt.annotation.NonNull;
-import org.eclipse.remote.core.IRemoteConnection;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.LogLevelType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TargetNodeState;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceChannelOutputType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEnablement;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEventType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.BufferType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.ChannelInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.CreateSessionDialogStub;
-import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.DestroyConfirmDialogStub;
-import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.EnableChannelDialogStub;
-import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.EnableEventsDialogStub;
-import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.GetEventInfoDialogStub;
-import org.eclipse.tracecompass.internal.lttng2.control.stubs.service.TestRemoteSystemProxy;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.TraceControlDialogFactory;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceEventComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
-import org.eclipse.tracecompass.tmf.remote.core.proxy.TmfRemoteConnectionFactory;
-import org.junit.After;
-import org.junit.Before;
-import org.junit.Test;
-import org.osgi.framework.FrameworkUtil;
-
-/**
- * The class <code>TraceControlUstSessionTests</code> contains UST
- * session/channel/event handling test cases.
- */
-public class TraceControlUstSessionTests {
-
-    // ------------------------------------------------------------------------
-    // Constants
-    // ------------------------------------------------------------------------
-
-    private static final String TEST_STREAM = "CreateTreeTest.cfg";
-    private static final String SCEN_SCENARIO4_TEST = "Scenario4";
-
-    // ------------------------------------------------------------------------
-    // Test data
-    // ------------------------------------------------------------------------
-    private IRemoteConnection fHost = TmfRemoteConnectionFactory.getLocalConnection();
-    private TraceControlTestFacility fFacility;
-    private @NonNull TestRemoteSystemProxy fProxy = new TestRemoteSystemProxy(fHost);
-    private String fTestFile;
-
-    // ------------------------------------------------------------------------
-    // Housekeeping
-    // ------------------------------------------------------------------------
-
-    /**
-     * Perform pre-test initialization.
-     *
-     * @throws Exception
-     *         if the initialization fails for some reason
-     */
-    @Before
-    public void setUp() throws Exception {
-        fFacility = TraceControlTestFacility.getInstance();
-        fFacility.init();
-        URL location = FileLocator.find(FrameworkUtil.getBundle(this.getClass()), new Path(TraceControlTestFacility.DIRECTORY + File.separator + TEST_STREAM), null);
-        File testfile = new File(FileLocator.toFileURL(location).toURI());
-        fTestFile = testfile.getAbsolutePath();
-    }
-
-    /**
-     * Perform post-test clean-up.
-     */
-    @After
-    public void tearDown() {
-        fFacility.waitForJobs();
-        fFacility.dispose();
-    }
-
-    /**
-     * Run the TraceControlComponent.
-     *
-     * @throws Exception
-     *             This will fail the test
-     */
-    @Test
-    public void testTraceSessionTree() throws Exception {
-
-        fProxy.setTestFile(fTestFile);
-        fProxy.setScenario(TraceControlTestFacility.SCEN_INIT_TEST);
-
-        ITraceControlComponent root = fFacility.getControlView().getTraceControlRoot();
-
-        TargetNodeComponent node = new TargetNodeComponent("myNode", root, fProxy);
-
-        root.addChild(node);
-        fFacility.waitForJobs();
-
-        fFacility.executeCommand(node, "connect");
-        int i = 0;
-        while ((i < 10) && (node.getTargetNodeState() != TargetNodeState.CONNECTED)) {
-            i++;
-            fFacility.delay(TraceControlTestFacility.GUI_REFESH_DELAY);
-        }
-
-        // Get provider groups
-        ITraceControlComponent[] groups = node.getChildren();
-        assertNotNull(groups);
-        assertEquals(2, groups.length);
-
-        // Initialize dialog implementations for command execution
-        TraceControlDialogFactory.getInstance().setCreateSessionDialog(new CreateSessionDialogStub());
-        TraceControlDialogFactory.getInstance().setGetEventInfoDialog(new GetEventInfoDialogStub());
-        TraceControlDialogFactory.getInstance().setConfirmDialog(new DestroyConfirmDialogStub());
-
-        // Initialize session handling scenario
-        fProxy.setScenario(TraceControlTestFacility.SCEN_SCENARIO_SESSION_HANDLING);
-
-        // ------------------------------------------------------------------------
-        // Create session
-        // ------------------------------------------------------------------------
-        TraceSessionComponent session = fFacility.createSession(groups[1]);
-
-        // Verify that session was created
-        assertNotNull(session);
-        assertEquals("mysession", session.getName());
-        assertEquals("/home/user/lttng-traces/mysession-20120314-132824", session.getSessionPath());
-        assertEquals(TraceSessionState.INACTIVE, session.getSessionState());
-
-        // Initialize scenario
-        fProxy.setScenario(SCEN_SCENARIO4_TEST);
-
-        // ------------------------------------------------------------------------
-        // Enable default channel on created session above
-        // ------------------------------------------------------------------------
-        EnableChannelDialogStub channelStub = new EnableChannelDialogStub();
-        channelStub.setIsKernel(false);
-        TraceControlDialogFactory.getInstance().setEnableChannelDialog(channelStub);
-
-        fFacility.executeCommand(session, "enableChannelOnSession");
-
-        // Verify that Kernel domain was created
-        ITraceControlComponent[] domains = session.getChildren();
-        assertNotNull(domains);
-        assertEquals(1, domains.length);
-
-        assertEquals("UST global", domains[0].getName());
-        assertEquals("Domain buffer Type", BufferType.BUFFER_TYPE_UNKNOWN, ((TraceDomainComponent)domains[0]).getBufferType());
-
-        // Verify that channel was created with correct data
-        ITraceControlComponent[] channels =  domains[0].getChildren();
-        assertNotNull(channels);
-        assertEquals(1, channels.length);
-
-        assertTrue(channels[0] instanceof TraceChannelComponent);
-        TraceChannelComponent channel = (TraceChannelComponent) channels[0];
-        assertEquals("mychannel", channel.getName());
-        assertEquals(4, channel.getNumberOfSubBuffers());
-        assertEquals("mmap()", channel.getOutputType().getInName());
-        assertEquals(TraceChannelOutputType.MMAP, channel.getOutputType());
-        assertEquals(true, channel.isOverwriteMode());
-        assertEquals(200, channel.getReadTimer());
-        assertEquals(TraceEnablement.ENABLED, channel.getState());
-        assertEquals(16384, channel.getSubBufferSize());
-        assertEquals(100, channel.getSwitchTimer());
-
-        // ------------------------------------------------------------------------
-        // Enable channel on domain
-        // ------------------------------------------------------------------------
-        ChannelInfo info = (ChannelInfo)channelStub.getChannelInfo();
-        info.setName("mychannel2");
-        info.setOverwriteMode(false);
-        info.setSubBufferSize(32768);
-        info.setNumberOfSubBuffers(2);
-        info.setSwitchTimer(100);
-        info.setReadTimer(200);
-        channelStub.setChannelInfo(info);
-
-        fFacility.executeCommand(domains[0], "enableChannelOnDomain");
-
-        // Get Kernel domain component instance
-        domains = session.getChildren();
-        assertNotNull(domains);
-        assertEquals(1, domains.length);
-
-        // Verify that channel was created with correct data
-        channels =  domains[0].getChildren();
-        assertNotNull(channels);
-        assertEquals(2, channels.length);
-
-        assertTrue(channels[1] instanceof TraceChannelComponent);
-        channel = (TraceChannelComponent) channels[1];
-        assertEquals("mychannel2", channel.getName());
-        assertEquals(2, channel.getNumberOfSubBuffers());
-        assertEquals("mmap()", channel.getOutputType().getInName());
-        assertEquals(TraceChannelOutputType.MMAP, channel.getOutputType());
-        assertEquals(false, channel.isOverwriteMode());
-        assertEquals(200, channel.getReadTimer());
-        assertEquals(TraceEnablement.ENABLED, channel.getState());
-        assertEquals(32768, channel.getSubBufferSize());
-        assertEquals(100, channel.getSwitchTimer());
-
-        // ------------------------------------------------------------------------
-        // Enable event (tracepoint) on session and default channel
-        // ------------------------------------------------------------------------
-        EnableEventsDialogStub eventsDialogStub = new EnableEventsDialogStub();
-        eventsDialogStub.setIsTracePoints(true);
-        List<String> events = new ArrayList<>();
-        events.add("ust_tests_hello:tptest_sighandler");
-        eventsDialogStub.setNames(events);
-        eventsDialogStub.setIsKernel(false);
-        TraceControlDialogFactory.getInstance().setEnableEventsDialog(eventsDialogStub);
-
-        fFacility.executeCommand(session, "enableEventOnSession");
-
-        // Get Kernel domain component instance
-        domains = session.getChildren();
-        assertNotNull(domains);
-        assertEquals(1, domains.length);
-
-        // Verify that channel was created with correct data
-        channels =  domains[0].getChildren();
-        assertNotNull(channels);
-        assertEquals(3, channels.length);
-
-        assertTrue(channels[2] instanceof TraceChannelComponent);
-        channel = (TraceChannelComponent) channels[2];
-        assertEquals("channel0", channel.getName());
-        // No need to check parameters of default channel because that has been done in other tests
-
-        ITraceControlComponent[] channel0Events = channel.getChildren();
-        assertEquals(1, channel0Events.length);
-
-        assertTrue(channel0Events[0] instanceof TraceEventComponent);
-
-        TraceEventComponent event = (TraceEventComponent) channel0Events[0];
-        assertEquals("ust_tests_hello:tptest_sighandler", event.getName());
-        assertEquals(TraceLogLevel.LEVEL_UNKNOWN, event.getLogLevel()); // TODO
-        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
-        assertEquals(TraceEnablement.ENABLED, event.getState());
-
-        // ------------------------------------------------------------------------
-        // Enable event (tracepoint) on domain and default channel
-        // ------------------------------------------------------------------------
-        events.clear();
-        events.add("ust_tests_hello:tptest");
-        eventsDialogStub.setNames(events);
-
-        fFacility.executeCommand(domains[0], "enableEventOnDomain");
-
-        // Get Kernel domain component instance
-        domains = session.getChildren();
-        assertNotNull(domains);
-        assertEquals(1, domains.length);
-
-        // Verify that channel was created with correct data
-        channels =  domains[0].getChildren();
-        channel = (TraceChannelComponent) channels[2];
-        // No need to check parameters of default channel because that has been done in other tests
-
-        channel0Events = channel.getChildren();
-        assertEquals(2, channel0Events.length);
-
-        assertTrue(channel0Events[1] instanceof TraceEventComponent);
-
-        event = (TraceEventComponent) channel0Events[1];
-        assertEquals("ust_tests_hello:tptest", event.getName());
-        assertEquals(TraceLogLevel.LEVEL_UNKNOWN, event.getLogLevel()); // TODO
-        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
-        assertEquals(TraceEnablement.ENABLED, event.getState());
-
-        // ------------------------------------------------------------------------
-        // Enable event (all tracepoints) on specific channel
-        // ------------------------------------------------------------------------
-        events.clear();
-        eventsDialogStub.setNames(events);
-        eventsDialogStub.setIsAllTracePoints(true);
-
-        fFacility.executeCommand(channels[1], "enableEventOnChannel");
-
-        // Get Kernel domain component instance
-        domains = session.getChildren();
-        assertNotNull(domains);
-        assertEquals(1, domains.length);
-
-        // Verify that channel was created with correct data
-        channels =  domains[0].getChildren();
-        channel = (TraceChannelComponent) channels[1];
-        // No need to check parameters of default channel because that has been done in other tests
-
-        channel = (TraceChannelComponent) channels[1];
-
-        channel0Events = channel.getChildren();
-        assertEquals(1, channel0Events.length);
-
-        assertTrue(channel0Events[0] instanceof TraceEventComponent);
-
-        event = (TraceEventComponent) channel0Events[0];
-        assertEquals("*", event.getName());
-        assertEquals(TraceLogLevel.LEVEL_UNKNOWN, event.getLogLevel());
-        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
-        assertEquals(TraceEnablement.ENABLED, event.getState());
-
-        // ------------------------------------------------------------------------
-        // Enable event (wildcard) on specific channel
-        // ------------------------------------------------------------------------
-        events.clear();
-        eventsDialogStub.setIsTracePoints(false);
-        eventsDialogStub.setIsAllTracePoints(false);
-        eventsDialogStub.setIsWildcard(true);
-        eventsDialogStub.setWildcard("ust*");
-
-        fFacility.executeCommand(channels[0], "enableEventOnChannel");
-
-        // Get Kernel domain component instance
-        domains = session.getChildren();
-        assertNotNull(domains);
-        assertEquals(1, domains.length);
-
-        // Verify that channel was created with correct data
-        channels =  domains[0].getChildren();
-        channel = (TraceChannelComponent) channels[0];
-        // No need to check parameters of default channel because that has been done in other tests
-
-        channel0Events = channel.getChildren();
-        assertEquals(1, channel0Events.length);
-
-        assertTrue(channel0Events[0] instanceof TraceEventComponent);
-
-        event = (TraceEventComponent) channel0Events[0];
-        assertEquals("ust*", event.getName());
-        assertEquals(TraceLogLevel.LEVEL_UNKNOWN, event.getLogLevel());
-        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
-        assertEquals(TraceEnablement.ENABLED, event.getState());
-
-        // ------------------------------------------------------------------------
-        // Enable event (wildcard) on domain
-        // ------------------------------------------------------------------------
-        events.clear();
-        eventsDialogStub.setIsTracePoints(false);
-        eventsDialogStub.setIsAllTracePoints(false);
-        eventsDialogStub.setIsWildcard(true);
-        eventsDialogStub.setWildcard("ust*");
-
-        fFacility.executeCommand(domains[0], "enableEventOnDomain");
-
-        // Get Kernel domain component instance
-        domains = session.getChildren();
-        assertNotNull(domains);
-        assertEquals(1, domains.length);
-
-        // Verify that channel was created with correct data
-        channels =  domains[0].getChildren();
-        channel = (TraceChannelComponent) channels[0];
-        // No need to check parameters of default channel because that has been done in other tests
-
-        channel0Events = channel.getChildren();
-        assertEquals(1, channel0Events.length);
-
-        assertTrue(channel0Events[0] instanceof TraceEventComponent);
-
-        event = (TraceEventComponent) channel0Events[0];
-        assertEquals("ust*", event.getName());
-        assertEquals(TraceLogLevel.LEVEL_UNKNOWN, event.getLogLevel());
-        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
-        assertEquals(TraceEnablement.ENABLED, event.getState());
-
-        // ------------------------------------------------------------------------
-        // Enable event (wildcard) on session
-        // ------------------------------------------------------------------------
-        events.clear();
-        eventsDialogStub.setIsTracePoints(false);
-        eventsDialogStub.setIsAllTracePoints(false);
-        eventsDialogStub.setIsWildcard(true);
-        eventsDialogStub.setWildcard("ust*");
-
-        fFacility.executeCommand(domains[0], "enableEventOnDomain");
-
-        // Get Kernel domain component instance
-        domains = session.getChildren();
-        assertNotNull(domains);
-        assertEquals(1, domains.length);
-
-        // Verify that channel was created with correct data
-        channels =  domains[0].getChildren();
-        channel = (TraceChannelComponent) channels[2];
-        // No need to check parameters of default channel because that has been done in other tests
-
-        channel0Events = channel.getChildren();
-        assertEquals(4, channel0Events.length);
-
-        assertTrue(channel0Events[0] instanceof TraceEventComponent);
-
-        event = (TraceEventComponent) channel0Events[0];
-        assertEquals("u*", event.getName());
-        assertEquals(TraceLogLevel.LEVEL_UNKNOWN, event.getLogLevel());
-        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
-        assertEquals(TraceEnablement.ENABLED, event.getState());
-
-        // ------------------------------------------------------------------------
-        // Enable event (loglevel) on domain
-        // ------------------------------------------------------------------------
-        events.clear();
-        eventsDialogStub.setIsWildcard(false);
-        eventsDialogStub.setIsLogLevel(true);
-        eventsDialogStub.setLogLevelEventName("myevent1");
-        eventsDialogStub.setLogLevelType(LogLevelType.LOGLEVEL);
-        eventsDialogStub.setLogLevel(TraceLogLevel.TRACE_WARNING);
-
-        fFacility.executeCommand(domains[0], "enableEventOnDomain");
-
-        // Get Kernel domain component instance
-        domains = session.getChildren();
-        assertNotNull(domains);
-        assertEquals(1, domains.length);
-
-        // Verify that channel was created with correct data
-        channels =  domains[0].getChildren();
-        channel = (TraceChannelComponent) channels[2];
-        // No need to check parameters of default channel because that has been done in other tests
-
-        channel0Events = channel.getChildren();
-        assertEquals(5, channel0Events.length);
-
-        assertTrue(channel0Events[0] instanceof TraceEventComponent);
-
-        event = (TraceEventComponent) channel0Events[0];
-        assertEquals("myevent1", event.getName());
-        assertEquals(TraceLogLevel.TRACE_WARNING, event.getLogLevel());
-        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
-        assertEquals(TraceEnablement.ENABLED, event.getState());
-
-        // ------------------------------------------------------------------------
-        // Enable event (loglevel) on session
-        // ------------------------------------------------------------------------
-        eventsDialogStub.setLogLevelEventName("myevent2");
-        eventsDialogStub.setLogLevelType(LogLevelType.LOGLEVEL_ONLY);
-        eventsDialogStub.setLogLevel(TraceLogLevel.TRACE_DEBUG_FUNCTION);
-
-        fFacility.executeCommand(session, "enableEventOnSession");
-
-        // Get Kernel domain component instance
-        domains = session.getChildren();
-        assertNotNull(domains);
-        assertEquals(1, domains.length);
-
-        // Verify that channel was created with correct data
-        channels =  domains[0].getChildren();
-        channel = (TraceChannelComponent) channels[2];
-        // No need to check parameters of default channel because that has been done in other tests
-
-        channel0Events = channel.getChildren();
-        assertEquals(6, channel0Events.length);
-
-        assertTrue(channel0Events[0] instanceof TraceEventComponent);
-
-        event = (TraceEventComponent) channel0Events[0];
-        assertEquals("myevent2", event.getName());
-        assertEquals(TraceLogLevel.TRACE_DEBUG_FUNCTION, event.getLogLevel());
-        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
-        assertEquals(TraceEnablement.ENABLED, event.getState());
-
-        // ------------------------------------------------------------------------
-        // Enable event (loglevel) on channel
-        // ------------------------------------------------------------------------
-        eventsDialogStub.setLogLevelEventName("myevent0");
-        eventsDialogStub.setLogLevelType(LogLevelType.LOGLEVEL_ONLY);
-        eventsDialogStub.setLogLevel(TraceLogLevel.TRACE_DEBUG_FUNCTION);
-
-        fFacility.executeCommand(channels[0], "enableEventOnChannel");
-
-        // Get Kernel domain component instance
-        domains = session.getChildren();
-        assertNotNull(domains);
-        assertEquals(1, domains.length);
-
-        // Verify that channel was created with correct data
-        channels =  domains[0].getChildren();
-        channel = (TraceChannelComponent) channels[0];
-        // No need to check parameters of default channel because that has been done in other tests
-
-        channel0Events = channel.getChildren();
-        assertEquals(2, channel0Events.length);
-
-        assertTrue(channel0Events[0] instanceof TraceEventComponent);
-
-        event = (TraceEventComponent) channel0Events[0];
-        assertEquals("myevent0", event.getName());
-        assertEquals(TraceLogLevel.TRACE_DEBUG_FUNCTION, event.getLogLevel());
-        assertEquals(TraceEventType.TRACEPOINT, event.getEventType());
-        assertEquals(TraceEnablement.ENABLED, event.getState());
-
-        // ------------------------------------------------------------------------
-        // Destroy session
-        // ------------------------------------------------------------------------
-        // Initialize session handling scenario
-        fProxy.setScenario(TraceControlTestFacility.SCEN_SCENARIO_SESSION_HANDLING);
-
-        fFacility.destroySession(session);
-
-        // Verify that no more session components exist
-        assertEquals("Session components still exist.", 0, groups[1].getChildren().length);
-
-        //-------------------------------------------------------------------------
-        // Disconnect node
-        //-------------------------------------------------------------------------
-        fFacility.executeCommand(node, "disconnect");
-        assertEquals(TargetNodeState.DISCONNECTED, node.getTargetNodeState());
-
-        //-------------------------------------------------------------------------
-        // Delete node
-        //-------------------------------------------------------------------------
-
-        fFacility.executeCommand(node, "delete");
-
-        assertEquals("Node not deleted.", 0, fFacility.getControlView().getTraceControlRoot().getChildren().length);
-    }
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlUstSessionTests2.java b/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/model/component/TraceControlUstSessionTests2.java
deleted file mode 100644 (file)
index b4b0d56..0000000
+++ /dev/null
@@ -1,305 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2013, 2015 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Markus Schorn - Bug 448058: Use org.eclipse.remote in favor of RSE
- **********************************************************************/
-
-package org.eclipse.tracecompass.lttng2.control.ui.tests.model.component;
-
-import static org.junit.Assert.assertEquals;
-import static org.junit.Assert.assertNotNull;
-import static org.junit.Assert.assertTrue;
-
-import java.io.File;
-import java.net.URL;
-
-import org.eclipse.core.runtime.FileLocator;
-import org.eclipse.core.runtime.Path;
-import org.eclipse.jdt.annotation.NonNull;
-import org.eclipse.remote.core.IRemoteConnection;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TargetNodeState;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.BufferType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.ChannelInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.CreateSessionDialogStub;
-import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.DestroyConfirmDialogStub;
-import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.EnableChannelDialogStub;
-import org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs.GetEventInfoDialogStub;
-import org.eclipse.tracecompass.internal.lttng2.control.stubs.service.TestRemoteSystemProxy;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.TraceControlDialogFactory;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
-import org.eclipse.tracecompass.tmf.remote.core.proxy.TmfRemoteConnectionFactory;
-import org.junit.After;
-import org.junit.Before;
-import org.junit.Test;
-import org.osgi.framework.FrameworkUtil;
-
-/**
- * The class <code>TraceControlUstSessionTests</code> contains UST
- * session/channel/event handling test cases for LTTng 2.2.
- */
-public class TraceControlUstSessionTests2 {
-
-    // ------------------------------------------------------------------------
-    // Constants
-    // ------------------------------------------------------------------------
-
-    private static final String TEST_STREAM = "CreateTreeTest2.cfg";
-    private static final String SCEN_SCEN_PER_UID_TEST = "ScenPerUidTest";
-    private static final String SCEN_SCEN_PER_PID_TEST = "ScenPerPidTest";
-    private static final String SCEN_SCEN_BUF_SIZE_TEST = "ScenBufSizeTest";
-
-    // ------------------------------------------------------------------------
-    // Test data
-    // ------------------------------------------------------------------------
-
-    private TraceControlTestFacility fFacility;
-    private IRemoteConnection fHost = TmfRemoteConnectionFactory.getLocalConnection();
-    private @NonNull TestRemoteSystemProxy fProxy = new TestRemoteSystemProxy(fHost);
-    private String fTestFile;
-
-    // ------------------------------------------------------------------------
-    // Housekeeping
-    // ------------------------------------------------------------------------
-
-    /**
-     * Perform pre-test initialization.
-     *
-     * @throws Exception
-     *         if the initialization fails for some reason
-     */
-    @Before
-    public void setUp() throws Exception {
-        fFacility = TraceControlTestFacility.getInstance();
-        fFacility.init();
-        URL location = FileLocator.find(FrameworkUtil.getBundle(this.getClass()), new Path(TraceControlTestFacility.DIRECTORY + File.separator + TEST_STREAM), null);
-        File testfile = new File(FileLocator.toFileURL(location).toURI());
-        fTestFile = testfile.getAbsolutePath();
-    }
-
-    /**
-     * Perform post-test clean-up.
-     */
-    @After
-    public void tearDown() {
-        fFacility.waitForJobs();
-        fFacility.dispose();
-    }
-
-    /**
-     * Run the TraceControlComponent.
-     *
-     * @throws Exception
-     *             This will fail the test
-     */
-    @Test
-    public void testTraceSessionTree() throws Exception {
-
-        fProxy.setTestFile(fTestFile);
-        fProxy.setScenario(TraceControlTestFacility.SCEN_INIT_TEST);
-
-        ITraceControlComponent root = fFacility.getControlView().getTraceControlRoot();
-
-        TargetNodeComponent node = new TargetNodeComponent("myNode", root, fProxy);
-
-        root.addChild(node);
-        fFacility.waitForJobs();
-
-        fFacility.executeCommand(node, "connect");
-        int i = 0;
-        while ((i < 10) && (node.getTargetNodeState() != TargetNodeState.CONNECTED)) {
-            i++;
-            fFacility.delay(TraceControlTestFacility.GUI_REFESH_DELAY);
-        }
-
-        // Get provider groups
-        ITraceControlComponent[] groups = node.getChildren();
-        assertNotNull(groups);
-        assertEquals(2, groups.length);
-
-        // Initialize dialog implementations for command execution
-        TraceControlDialogFactory.getInstance().setCreateSessionDialog(new CreateSessionDialogStub());
-        TraceControlDialogFactory.getInstance().setGetEventInfoDialog(new GetEventInfoDialogStub());
-        TraceControlDialogFactory.getInstance().setConfirmDialog(new DestroyConfirmDialogStub());
-
-        // Initialize scenario
-        fProxy.setScenario(SCEN_SCEN_PER_UID_TEST);
-
-        // ------------------------------------------------------------------------
-        // Create session
-        // ------------------------------------------------------------------------
-        TraceSessionComponent session = fFacility.createSession(groups[1]);
-
-        // Verify that session was created
-        assertNotNull(session);
-        assertEquals("mysession", session.getName());
-
-        // ------------------------------------------------------------------------
-        // Enable default channel on created session above
-        // ------------------------------------------------------------------------
-        EnableChannelDialogStub channelStub = new EnableChannelDialogStub();
-        channelStub.setIsKernel(false);
-        ChannelInfo info = (ChannelInfo)channelStub.getChannelInfo();
-        info.setName("mychannel");
-        info.setOverwriteMode(false);
-        info.setSubBufferSize(-1);
-        info.setNumberOfSubBuffers(-1);
-        info.setSwitchTimer(-1);
-        info.setReadTimer(-1);
-        info.setMaxNumberTraceFiles(-1);
-        info.setMaxSizeTraceFiles(-1);
-        info.setBufferType(BufferType.BUFFER_PER_UID);
-        channelStub.setChannelInfo(info);
-
-        TraceControlDialogFactory.getInstance().setEnableChannelDialog(channelStub);
-
-        fFacility.executeCommand(session, "enableChannelOnSession");
-
-        // Verify that UST domain was created
-        ITraceControlComponent[] domains = session.getChildren();
-        assertNotNull(domains);
-        assertEquals(1, domains.length);
-
-        assertEquals("UST global", domains[0].getName());
-        assertEquals("Domain buffer Type", BufferType.BUFFER_PER_UID, ((TraceDomainComponent)domains[0]).getBufferType());
-
-        // Verify that channel was created with correct data
-        ITraceControlComponent[] channels =  domains[0].getChildren();
-        assertNotNull(channels);
-        assertEquals(1, channels.length);
-
-        assertTrue(channels[0] instanceof TraceChannelComponent);
-        TraceChannelComponent channel = (TraceChannelComponent) channels[0];
-        assertEquals("mychannel", channel.getName());
-
-        // ------------------------------------------------------------------------
-        // Destroy session
-        // ------------------------------------------------------------------------
-        fFacility.destroySession(session);
-
-        // Verify that no more session components exist
-        assertEquals(0, groups[1].getChildren().length);
-
-        // ------------------------------------------------------------------------
-        // Create session (per-pid buffers)
-        // ------------------------------------------------------------------------
-
-        // Initialize scenario
-        fProxy.setScenario(SCEN_SCEN_PER_PID_TEST);
-
-        session = fFacility.createSession(groups[1]);
-
-        // Verify that session was created
-        assertNotNull(session);
-        assertEquals("mysession", session.getName());
-
-        // ------------------------------------------------------------------------
-        // Enable default channel on created session above
-        // ------------------------------------------------------------------------
-        info = (ChannelInfo)channelStub.getChannelInfo();
-        info.setName("mychannel");
-        info.setBufferType(BufferType.BUFFER_PER_PID);
-        channelStub.setChannelInfo(info);
-
-        fFacility.executeCommand(session, "enableChannelOnSession");
-
-        // Verify that UST domain was created
-        domains = session.getChildren();
-        assertNotNull(domains);
-        assertEquals(1, domains.length);
-
-        assertEquals("UST global", domains[0].getName());
-        assertEquals("Domain buffer Type", BufferType.BUFFER_PER_PID, ((TraceDomainComponent)domains[0]).getBufferType());
-
-        // Verify that channel was created with correct data
-        channels =  domains[0].getChildren();
-        assertNotNull(channels);
-        assertEquals(1, channels.length);
-
-        assertTrue(channels[0] instanceof TraceChannelComponent);
-        channel = (TraceChannelComponent) channels[0];
-        assertEquals("mychannel", channel.getName());
-
-        // ------------------------------------------------------------------------
-        // Destroy session
-        // ------------------------------------------------------------------------
-        fFacility.destroySession(session);
-
-        // Verify that no more session components exist
-        assertEquals(0, groups[1].getChildren().length);
-
-        // ------------------------------------------------------------------------
-        // Create session (configured file size and number of files)
-        // ------------------------------------------------------------------------
-
-        // Initialize scenario
-        fProxy.setScenario(SCEN_SCEN_BUF_SIZE_TEST);
-
-        session = fFacility.createSession(groups[1]);
-
-        // Verify that session was created
-        assertNotNull(session);
-        assertEquals("mysession", session.getName());
-
-        // ------------------------------------------------------------------------
-        // Enable default channel on created session above
-        // ------------------------------------------------------------------------
-        info = (ChannelInfo)channelStub.getChannelInfo();
-        info.setName("mychannel");
-        info.setMaxNumberTraceFiles(10);
-        info.setMaxSizeTraceFiles(1024);
-        info.setBufferType(BufferType.BUFFER_TYPE_UNKNOWN);
-        channelStub.setChannelInfo(info);
-
-        fFacility.executeCommand(session, "enableChannelOnSession");
-
-        // Verify that UST domain was created
-        domains = session.getChildren();
-        assertNotNull(domains);
-        assertEquals(1, domains.length);
-
-        assertEquals("UST global", domains[0].getName());
-        assertEquals("Domain buffer Type", BufferType.BUFFER_PER_PID, ((TraceDomainComponent)domains[0]).getBufferType());
-
-        // Verify that channel was created with correct data
-        channels =  domains[0].getChildren();
-        assertNotNull(channels);
-        assertEquals(1, channels.length);
-
-        assertTrue(channels[0] instanceof TraceChannelComponent);
-        channel = (TraceChannelComponent) channels[0];
-        assertEquals("mychannel", channel.getName());
-
-        // ------------------------------------------------------------------------
-        // Destroy session
-        // ------------------------------------------------------------------------
-        fFacility.destroySession(session);
-
-        // Verify that no more session components exist
-        assertEquals(0, groups[1].getChildren().length);
-
-        //-------------------------------------------------------------------------
-        // Disconnect node
-        //-------------------------------------------------------------------------
-        fFacility.executeCommand(node, "disconnect");
-        assertEquals(TargetNodeState.DISCONNECTED, node.getTargetNodeState());
-
-        //-------------------------------------------------------------------------
-        // Delete node
-        //-------------------------------------------------------------------------
-
-        fFacility.executeCommand(node, "delete");
-
-        assertEquals(0,fFacility.getControlView().getTraceControlRoot().getChildren().length);
-    }
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/service/AllTests.java b/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/service/AllTests.java
deleted file mode 100644 (file)
index 4181191..0000000
+++ /dev/null
@@ -1,29 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2011, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Alexandre Montplaisir - Port to JUnit4
- *******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.control.ui.tests.service;
-
-import org.junit.runner.RunWith;
-import org.junit.runners.Suite;
-
-/**
- * Runner for the service unit tests.
- */
-@RunWith(Suite.class)
-@Suite.SuiteClasses({
-    LTTngControlServiceTest.class,
-    LTTngControlServiceMiTest.class
-})
-public class AllTests {
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/service/LTTngControlServiceMiTest.java b/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/service/LTTngControlServiceMiTest.java
deleted file mode 100644 (file)
index 626f4f1..0000000
+++ /dev/null
@@ -1,211 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014 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:
- *   Jonathan Rajotte - Support of machine interface
- **********************************************************************/
-
-package org.eclipse.tracecompass.lttng2.control.ui.tests.service;
-
-import static org.junit.Assert.assertEquals;
-import static org.junit.Assert.assertNotNull;
-import static org.junit.Assert.assertTrue;
-import static org.junit.Assert.fail;
-
-import java.net.URL;
-import java.util.List;
-
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.core.runtime.NullProgressMonitor;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IChannelInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IDomainInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IEventInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISessionInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceChannelOutputType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEnablement;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEventType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.SessionInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.service.ILttngControlService;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.service.LTTngControlServiceConstants;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.service.LTTngControlServiceMI;
-import org.junit.Test;
-
-/**
- * @author ejorajo
- *
- */
-public class LTTngControlServiceMiTest extends LTTngControlServiceTest {
-
-    private static final String MI_TEST_STREAM = "LTTngServiceMiTest.cfg";
-
-    private static final String SCEN_SESSION_WITH_SYSCALLS = "GetSessionWithSyscalls";
-
-    @Override
-    protected ILttngControlService getControlService() {
-        try {
-            URL resource = LTTngControlServiceMI.class.getResource(LTTngControlServiceConstants.MI_XSD_FILENAME);
-            return new LTTngControlServiceMI(getShell(), resource);
-        } catch (ExecutionException e) {
-            return null;
-        }
-    }
-
-    @Override
-    public void testGetSessionNameGarbage() {
-        try {
-            fShell.setScenario(SCEN_GET_SESSION_GARBAGE_OUT);
-            fService.getSessionNames(new NullProgressMonitor());
-        } catch (ExecutionException e) {
-            // Success. Parsing of garbage result in an ExecutionException
-            // generated by the XML document parser: Unable to parse the xml
-            // document.
-        }
-    }
-
-    @Override
-    public void testCreateLiveSession() throws ExecutionException {
-        fShell.setScenario(SCEN_CREATE_LIVE_SESSION);
-
-        ISessionInfo params = new SessionInfo("mysession");
-        params.setLive(true);
-        params.setStreamedTrace(true);
-        params.setNetworkUrl("net://127.0.0.1");
-        ISessionInfo sessionInfo = fService.createSession(params, new NullProgressMonitor());
-        assertNotNull(sessionInfo);
-        assertEquals("mysession", sessionInfo.getName());
-        assertEquals(TraceSessionState.INACTIVE, sessionInfo.getSessionState());
-        assertTrue(sessionInfo.isStreamedTrace());
-        assertTrue(sessionInfo.isLive());
-        assertEquals("tcp4://127.0.0.1:5342/ [data: 5343]", sessionInfo.getSessionPath());
-        List<String> names = fService.getSessionNames(new NullProgressMonitor());
-        assertEquals(names.get(0), "mysession");
-        fService.destroySession("mysession", new NullProgressMonitor());
-    }
-
-    @Override
-    protected String getTestStream() {
-        return MI_TEST_STREAM;
-    }
-
-    @Override
-    protected TraceLogLevel getAllEventTraceLogLevel() {
-        return TraceLogLevel.TRACE_DEBUG;
-    }
-
-    @Override
-    public void testGetKernelProviderNoUstVerbose() {
-        // Verbose mode in machine interface is deactivated. This test is
-        // ignored.
-    }
-
-    @Override
-    public void testCreateSession2_1() {
-        // 2.1 is not supported by mi. This test is ignored.
-    }
-
-    @Override
-    public void testGetKernelProviderNoUst3() {
-        // Verbose mode in machine interface is deactivated. This test is
-        // ignored.
-    }
-
-    @Override
-    public void testGetKernelProviderNoKernelVerbose() {
-        // Verbose mode in machine interface is deactivated. This test is
-        // ignored.
-    }
-
-    @Override
-    public void testCreateSessionVerbose2_1() {
-        // Verbose mode in machine interface is deactivated. This test is
-        // ignored.
-    }
-
-    @Override
-    public void testDestroySessionVerbose() {
-        // Verbose mode in machine interface is deactivated. This test is
-        // ignored.
-    }
-
-    @Override
-    public void testCreateSessionWithPrompt() {
-        // TODO Investigate if this case can happen in production. If yes than
-        // we need to rethinks the MI fetching and parsing.
-    }
-
-    @Override
-    public void testAddContext() {
-        // TODO This does not use mi feature.And currently the context enabling
-        // is wrong for 2.6.
-    }
-
-    @Override
-    public void testAddContextFailure() {
-        // TODO This does not use mi feature.And currently the context enabling
-        // is wrong for 2.6.
-    }
-
-    @Override
-    public void testCreateSnapshotSession2_5() {
-        // not applicable for MI
-    }
-
-    /**
-     * Tests the listing of syscalls
-     */
-    @Test
-    public void testListSycallEvents() {
-        try {
-            fShell.setScenario(SCEN_SESSION_WITH_SYSCALLS);
-            ISessionInfo session = fService.getSession("mysession", new NullProgressMonitor());
-
-            // Verify Session
-            assertNotNull(session);
-            assertEquals("mysession", session.getName());
-            assertEquals("/home/user/lttng-traces/mysession-20120129-084256", session.getSessionPath());
-            assertEquals(TraceSessionState.INACTIVE, session.getSessionState());
-
-            IDomainInfo[] domains = session.getDomains();
-            assertNotNull(domains);
-            assertEquals(1, domains.length);
-
-            // Verify Kernel domain
-            assertEquals("Kernel", domains[0].getName());
-            IChannelInfo[] channels =  domains[0].getChannels();
-            assertNotNull(channels);
-            assertEquals(1, channels.length);
-
-            // Verify Kernel's channel0
-            assertEquals("channel0", channels[0].getName());
-            assertEquals(4, channels[0].getNumberOfSubBuffers());
-            assertEquals("splice()", channels[0].getOutputType().getInName());
-            assertEquals(TraceChannelOutputType.SPLICE, channels[0].getOutputType());
-            assertEquals(false, channels[0].isOverwriteMode());
-            assertEquals(200, channels[0].getReadTimer());
-            assertEquals(TraceEnablement.ENABLED, channels[0].getState());
-            assertEquals(262144, channels[0].getSubBufferSize());
-            assertEquals(0, channels[0].getSwitchTimer());
-
-            // Verify event info
-            IEventInfo[] channel0Events = channels[0].getEvents();
-            assertNotNull(channel0Events);
-            assertEquals(2, channel0Events.length);
-            assertEquals("read", channel0Events[0].getName());
-            assertEquals(TraceEventType.SYSCALL, channel0Events[0].getEventType());
-            assertEquals(TraceEnablement.ENABLED, channel0Events[0].getState());
-
-            assertEquals("write", channel0Events[1].getName());
-            assertEquals(TraceEventType.SYSCALL, channel0Events[1].getEventType());
-            assertEquals(TraceEnablement.ENABLED, channel0Events[1].getState());
-        } catch (ExecutionException e) {
-            fail(e.toString());
-        }
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/service/LTTngControlServiceTest.java b/org.eclipse.tracecompass.lttng2.control.ui.tests/src/org/eclipse/tracecompass/lttng2/control/ui/tests/service/LTTngControlServiceTest.java
deleted file mode 100644 (file)
index d7cfcdc..0000000
+++ /dev/null
@@ -1,1595 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2015 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Alexandre Montplaisir - Port to JUnit4
- *   Marc-Andre Laperle - Support for creating a live session
- **********************************************************************/
-
-package org.eclipse.tracecompass.lttng2.control.ui.tests.service;
-
-import static org.junit.Assert.assertEquals;
-import static org.junit.Assert.assertFalse;
-import static org.junit.Assert.assertNotNull;
-import static org.junit.Assert.assertTrue;
-import static org.junit.Assert.fail;
-
-import java.io.File;
-import java.net.URL;
-import java.util.ArrayList;
-import java.util.HashSet;
-import java.util.List;
-import java.util.Set;
-
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.core.runtime.FileLocator;
-import org.eclipse.core.runtime.NullProgressMonitor;
-import org.eclipse.core.runtime.Path;
-import org.eclipse.jdt.annotation.NonNull;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IBaseEventInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IChannelInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IDomainInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IEventInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IFieldInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISessionInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISnapshotInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IUstProviderInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.LogLevelType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceChannelOutputType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEnablement;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEventType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.BufferType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.ChannelInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.SessionInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.stubs.shells.LTTngToolsFileShell;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.logging.ControlCommandLogger;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.preferences.ControlPreferences;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.service.ILttngControlService;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.service.LTTngControlService;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.service.LTTngControlServiceFactory;
-import org.junit.After;
-import org.junit.Before;
-import org.junit.Test;
-import org.osgi.framework.FrameworkUtil;
-
-/**
- * The class <code>LTTngControlServiceTest</code> contains test for the class
- * <code>{@link  LTTngControlService}</code>.
- */
-@SuppressWarnings("javadoc")
-public class LTTngControlServiceTest {
-
-    private static final String DIRECTORY   = "testfiles";
-    private static final String TEST_STREAM = "LTTngServiceTest.cfg";
-
-    private static final String SCEN_LTTNG_NOT_INSTALLED = "LttngNotInstalled";
-    private static final String SCEN_LTTNG_VERSION = "LttngVersion";
-    private static final String SCEN_LTTNG_VERSION_WITH_PROMPT = "LttngVersionWithPrompt";
-    private static final String SCEN_LTTNG_UNSUPPORTED_VERSION = "LttngUnsupportedVersion";
-    private static final String SCEN_LTTNG_NO_VERSION = "LttngNoVersion";
-    private static final String SCEN_LTTNG_COMPILED_VERSION = "LttngVersionCompiled";
-    private static final String SCEN_NO_SESSION_AVAILABLE = "NoSessionAvailable";
-    private static final String SCEN_GET_SESSION_NAMES1 = "GetSessionNames1";
-    private static final String SCEN_GET_SESSION_WITH_GROUP = "GetSessionWithTracingGroup";
-    private static final String SCEN_GET_SESSION_NAME_NOT_EXIST = "GetSessionNameNotExist";
-    private static final String SCEN_GET_SESSION_NAME_NOT_EXIST_VERBOSE = "GetSessionNameNotExistVerbose";
-    protected static final String SCEN_GET_SESSION_GARBAGE_OUT = "GetSessionGarbageOut";
-    private static final String SCEN_GET_SESSION1 = "GetSession1";
-    private static final String SCEN_GET_SESSION_WITH_LIVE = "GetSessionWithLiveInterval";
-    private static final String SCEN_GET_KERNEL_PROVIDER1 = "GetKernelProvider1";
-    private static final String SCEN_LIST_WITH_NO_KERNEL1 = "ListWithNoKernel1";
-    private static final String SCEN_LIST_WITH_NO_KERNEL2 = "ListWithNoKernel2";
-    private static final String SCEN_LIST_WITH_NO_KERNEL_VERBOSE = "ListWithNoKernelVerbose";
-    private static final String SCEN_GET_UST_PROVIDER1 = "GetUstProvider1";
-    private static final String SCEN_GET_UST_PROVIDER2 = "GetUstProvider2";
-    private static final String SCEN_GET_UST_PROVIDER3 = "GetUstProvider3";
-    private static final String SCEN_LIST_WITH_NO_UST1 = "ListWithNoUst1";
-    private static final String SCEN_LIST_WITH_NO_UST2 = "ListWithNoUst2";
-    private static final String SCEN_LIST_WITH_NO_UST3 = "ListWithNoUst3";
-    private static final String SCEN_LIST_WITH_NO_UST_VERBOSE = "ListWithNoUstVerbose";
-    private static final String SCEN_CREATE_SESSION1 = "CreateSession1";
-    private static final String SCEN_CREATE_SESSION_WITH_PROMPT = "CreateSessionWithPrompt";
-    private static final String SCEN_CREATE_SESSION_VARIANTS = "CreateSessionVariants";
-    private static final String SCEN_DESTROY_SESSION1 = "DestroySession1";
-    private static final String SCEN_DESTROY_SESSION_VERBOSE = "DestroySessionVerbose";
-    private static final String SCEN_CHANNEL_HANDLING = "ChannelHandling";
-    private static final String SCEN_EVENT_HANDLING = "EventHandling";
-    private static final String SCEN_CONTEXT_HANDLING = "ContextHandling";
-    private static final String SCEN_CONTEXT_ERROR_HANDLING = "ContextErrorHandling";
-    private static final String SCEN_CALIBRATE_HANDLING = "CalibrateHandling";
-    private static final String SCEN_CREATE_SESSION_2_1 = "CreateSessionLttng2.1";
-    private static final String SCEN_CREATE_SESSION_VERBOSE_2_1 = "CreateSessionLttngVerbose2.1";
-    private static final String SCEN_CREATE_SNAPSHOT_SESSION = "CreateSessionSnapshot";
-    private static final String SCEN_CREATE_SNAPSHOT_SESSION_2_5 = "CreateSessionSnapshot2.5";
-    private static final String SCEN_CREATE_STREAMED_SNAPSHOT_SESSION = "CreateSessionStreamedSnapshot";
-    private static final String SCEN_CREATE_SNAPSHOT_SESSION_ERRORS = "CreateSessionSnapshotErrors";
-    protected static final String SCEN_CREATE_LIVE_SESSION = "CreateSessionLive";
-    private static final String SCEN_CREATE_LIVE_SESSION_ERRORS = "CreateSessionLiveErrors";
-
-
-    // ------------------------------------------------------------------------
-    // Test data
-    // ------------------------------------------------------------------------
-    private String fTestfile;
-    protected final @NonNull LTTngToolsFileShell fShell = new LTTngToolsFileShell();
-    protected ILttngControlService fService;
-
-    // ------------------------------------------------------------------------
-    // Housekeeping
-    // ------------------------------------------------------------------------
-
-    /**
-     * Perform pre-test initialization.
-     *
-     * @throws Exception
-     *             if the initialization fails for some reason
-     */
-    @Before
-    public void setUp() throws Exception {
-        URL location = FileLocator.find(FrameworkUtil.getBundle(this.getClass()), new Path(getTestDirectory() + File.separator + getTestStream()), null);
-        File testfile = new File(FileLocator.toFileURL(location).toURI());
-        fTestfile = testfile.getAbsolutePath();
-        fShell.loadScenarioFile(fTestfile);
-        fService = getControlService();
-        if (fService == null) {
-            throw new Exception("Unable to obtain a valid ControlService");
-        }
-
-        ControlPreferences.getInstance().init(Activator.getDefault().getPreferenceStore());
-    }
-
-    /**
-     * @return the string of the test directory to use
-     */
-    protected String getTestDirectory() {
-        return DIRECTORY;
-    }
-
-    /**
-     * @return the LttngCon
-     */
-    protected ILttngControlService getControlService() {
-        return new LTTngControlService(fShell);
-    }
-
-    /**
-     * @return the shell implementation
-     */
-    public @NonNull LTTngToolsFileShell getShell() {
-        return fShell;
-    }
-
-    /**
-     * @return
-     */
-    protected String getTestStream() {
-        return TEST_STREAM;
-    }
-
-    @After
-    public void tearDown() {
-        disableVerbose();
-        ControlPreferences.getInstance().dispose();
-    }
-
-    // ------------------------------------------------------------------------
-    // Test Cases
-    // ------------------------------------------------------------------------
-
-    @Test
-    public void testVersion() {
-        try {
-            fShell.setScenario(SCEN_LTTNG_VERSION);
-            ILttngControlService service = LTTngControlServiceFactory.getLttngControlService(fShell);
-            assertNotNull(service);
-            assertEquals("2.1.0", service.getVersionString());
-        } catch (ExecutionException e) {
-            fail("Exeption thrown " + e);
-        }
-    }
-
-    @Test
-    public void testVersionWithPrompt() {
-        try {
-            fShell.setScenario(SCEN_LTTNG_VERSION_WITH_PROMPT);
-            ILttngControlService service = LTTngControlServiceFactory.getLttngControlService(fShell);
-            assertNotNull(service);
-            assertEquals("2.0.0", service.getVersionString());
-        } catch (ExecutionException e) {
-            fail("Exeption thrown " + e);
-        }
-    }
-
-    @Test(expected=ExecutionException.class)
-    public void testUnsupportedVersion() throws ExecutionException {
-        fShell.setScenario(SCEN_LTTNG_UNSUPPORTED_VERSION);
-        LTTngControlServiceFactory.getLttngControlService(fShell);
-    }
-
-    @Test
-    public void testNoVersion() {
-        try {
-            fShell.setScenario(SCEN_LTTNG_NO_VERSION);
-            LTTngControlServiceFactory.getLttngControlService(fShell);
-            fail("No exeption thrown");
-        } catch (ExecutionException e) {
-            // success
-        }
-    }
-
-    @Test
-    public void testVersionCompiled() {
-        try {
-            fShell.setScenario(SCEN_LTTNG_COMPILED_VERSION);
-            ILttngControlService service = LTTngControlServiceFactory.getLttngControlService(fShell);
-            assertNotNull(service);
-            assertEquals("2.5.0", service.getVersionString());
-        } catch (ExecutionException e) {
-            fail("Exeption thrown " + e);
-        }
-    }
-
-
-    @Test
-    public void testLttngNotInstalled() {
-        try {
-            fShell.setScenario(SCEN_LTTNG_NOT_INSTALLED);
-            fService.getSessionNames(new NullProgressMonitor());
-            fail("No exeption thrown");
-        } catch (ExecutionException e) {
-         // success
-        }
-    }
-
-    @Test
-    public void testGetSessionNames1() {
-        try {
-            fShell.setScenario(SCEN_NO_SESSION_AVAILABLE);
-            List<String> result = fService.getSessionNames(new NullProgressMonitor());
-
-            assertNotNull(result);
-            assertEquals(0, result.size());
-
-        } catch (ExecutionException e) {
-            fail(e.toString());
-        }
-    }
-
-    @Test
-    public void testGetSessionNames2() {
-        try {
-            fShell.setScenario(SCEN_GET_SESSION_NAMES1);
-            List<String> result = fService.getSessionNames(new NullProgressMonitor());
-
-            assertNotNull(result);
-            assertEquals(2, result.size());
-            assertEquals("mysession1", result.get(0));
-            assertEquals("mysession", result.get(1));
-
-        } catch (ExecutionException e) {
-            fail(e.toString());
-        }
-    }
-
-    @Test
-    public void testGetSessionNamesWithTracingGroup() {
-        try {
-            fShell.setScenario(SCEN_GET_SESSION_WITH_GROUP);
-            ControlPreferences.getInstance().getPreferenceStore().setValue(
-                    ControlPreferences.TRACE_CONTROL_TRACING_GROUP_PREF, "group");
-
-            List<String> result = fService.getSessionNames(new NullProgressMonitor());
-
-            assertNotNull(result);
-            assertEquals(2, result.size());
-            assertEquals("mysession1", result.get(0));
-            assertEquals("mysession", result.get(1));
-
-            ControlCommandLogger.init(ControlPreferences.getInstance().getLogfilePath(), false);
-            ControlPreferences.getInstance().getPreferenceStore().setValue(
-                    ControlPreferences.TRACE_CONTROL_TRACING_GROUP_PREF, ControlPreferences.TRACE_CONTROL_DEFAULT_TRACING_GROUP);
-
-
-        } catch (ExecutionException e) {
-            fail(e.toString());
-        }
-    }
-
-
-    @Test
-    public void testGetSessionNotExist() {
-        try {
-            fShell.setScenario(SCEN_GET_SESSION_NAME_NOT_EXIST);
-            fService.getSessionNames(new NullProgressMonitor());
-            fail("No exeption thrown");
-
-        } catch (ExecutionException e) {
-            // success
-        }
-    }
-
-    @Test
-    public void testGetSessionNotExistVerbose() {
-        try {
-            enableVerbose();
-            fShell.setScenario(SCEN_GET_SESSION_NAME_NOT_EXIST_VERBOSE);
-            fService.getSessionNames(new NullProgressMonitor());
-            fail("No exeption thrown");
-
-        } catch (ExecutionException e) {
-            // success
-        } finally {
-            disableVerbose();
-        }
-    }
-
-    @Test
-    public void testGetSessionNameGarbage() {
-        try {
-            fShell.setScenario(SCEN_GET_SESSION_GARBAGE_OUT);
-            List<String> result = fService.getSessionNames(new NullProgressMonitor());
-
-            assertNotNull(result);
-            assertEquals(0, result.size());
-
-        } catch (ExecutionException e) {
-            fail(e.toString());
-        }
-    }
-
-    @Test
-    public void testGetSession1() {
-        try {
-            fShell.setScenario(SCEN_GET_SESSION1);
-            ISessionInfo session = fService.getSession("mysession", new NullProgressMonitor());
-
-            // Verify Session
-            assertNotNull(session);
-            assertEquals("mysession", session.getName());
-            assertEquals("/home/user/lttng-traces/mysession-20120129-084256", session.getSessionPath());
-            assertEquals(TraceSessionState.ACTIVE, session.getSessionState());
-
-            IDomainInfo[] domains = session.getDomains();
-            assertNotNull(domains);
-            assertEquals(2, domains.length);
-
-            // Verify Kernel domain
-            assertEquals("Kernel", domains[0].getName());
-            IChannelInfo[] channels =  domains[0].getChannels();
-            assertNotNull(channels);
-            assertEquals(2, channels.length);
-
-            // Verify Kernel's channel0
-            assertEquals("channel0", channels[0].getName());
-            assertEquals(4, channels[0].getNumberOfSubBuffers());
-            assertEquals("splice()", channels[0].getOutputType().getInName());
-            assertEquals(TraceChannelOutputType.SPLICE, channels[0].getOutputType());
-            assertEquals(false, channels[0].isOverwriteMode());
-            assertEquals(200, channels[0].getReadTimer());
-            assertEquals(TraceEnablement.ENABLED, channels[0].getState());
-            assertEquals(262144, channels[0].getSubBufferSize());
-            assertEquals(0, channels[0].getSwitchTimer());
-
-            // Verify event info
-            IEventInfo[] channel0Events = channels[0].getEvents();
-            assertNotNull(channel0Events);
-            assertEquals(2, channel0Events.length);
-            assertEquals("block_rq_remap", channel0Events[0].getName());
-            assertEquals(TraceLogLevel.TRACE_EMERG, channel0Events[0].getLogLevel());
-            assertEquals(TraceEventType.TRACEPOINT, channel0Events[0].getEventType());
-            assertEquals(TraceEnablement.ENABLED, channel0Events[0].getState());
-
-            assertEquals("block_bio_remap", channel0Events[1].getName());
-            assertEquals(TraceLogLevel.TRACE_EMERG, channel0Events[1].getLogLevel());
-            assertEquals(TraceEventType.TRACEPOINT, channel0Events[1].getEventType());
-            assertEquals(TraceEnablement.DISABLED, channel0Events[1].getState());
-
-            // Verify Kernel's channel1
-            assertEquals("channel1", channels[1].getName());
-            assertEquals(4, channels[1].getNumberOfSubBuffers());
-            assertEquals("splice()", channels[1].getOutputType().getInName());
-            assertEquals(TraceChannelOutputType.SPLICE, channels[1].getOutputType());
-            assertEquals(true, channels[1].isOverwriteMode());
-            assertEquals(400, channels[1].getReadTimer());
-            assertEquals(TraceEnablement.DISABLED, channels[1].getState());
-            assertEquals(524288, channels[1].getSubBufferSize());
-            assertEquals(100, channels[1].getSwitchTimer());
-
-            // Verify event info
-            IEventInfo[] channel1Events = channels[1].getEvents();
-            assertEquals(0, channel1Events.length);
-
-            // Verify domain UST global
-            assertEquals("UST global", domains[1].getName());
-
-            IChannelInfo[] ustChannels =  domains[1].getChannels();
-
-            // Verify UST global's mychannel1
-            assertEquals("mychannel1", ustChannels[0].getName());
-            assertEquals(8, ustChannels[0].getNumberOfSubBuffers());
-            assertEquals("mmap()", ustChannels[0].getOutputType().getInName());
-            assertEquals(TraceChannelOutputType.MMAP, ustChannels[0].getOutputType());
-            assertEquals(true, ustChannels[0].isOverwriteMode());
-            assertEquals(100, ustChannels[0].getReadTimer());
-            assertEquals(TraceEnablement.DISABLED, ustChannels[0].getState());
-            assertEquals(8192, ustChannels[0].getSubBufferSize());
-            assertEquals(200, ustChannels[0].getSwitchTimer());
-
-            // Verify event info
-            IEventInfo[] ustEvents = ustChannels[0].getEvents();
-            assertEquals(0, ustEvents.length);
-
-            // Verify UST global's channel0
-            assertEquals("channel0", ustChannels[1].getName());
-            assertEquals(4, ustChannels[1].getNumberOfSubBuffers());
-            assertEquals("mmap()", ustChannels[1].getOutputType().getInName());
-            assertEquals(TraceChannelOutputType.MMAP, ustChannels[1].getOutputType());
-            assertEquals(false, ustChannels[1].isOverwriteMode());
-            assertEquals(200, ustChannels[1].getReadTimer());
-            assertEquals(TraceEnablement.ENABLED, ustChannels[1].getState());
-            assertEquals(4096, ustChannels[1].getSubBufferSize());
-            assertEquals(0, ustChannels[1].getSwitchTimer());
-
-            // Verify event info
-            ustEvents = ustChannels[1].getEvents();
-            assertEquals(2, ustEvents.length);
-
-            assertEquals("ust_tests_hello:tptest_sighandler", ustEvents[0].getName());
-            assertEquals(TraceLogLevel.TRACE_DEBUG_LINE, ustEvents[0].getLogLevel());
-            assertEquals(TraceEventType.TRACEPOINT, ustEvents[0].getEventType());
-            assertEquals(TraceEnablement.DISABLED, ustEvents[0].getState());
-
-            assertEquals("*", ustEvents[1].getName());
-            assertEquals(getAllEventTraceLogLevel(), ustEvents[1].getLogLevel());
-            assertEquals(TraceEventType.TRACEPOINT, ustEvents[1].getEventType());
-            assertEquals(TraceEnablement.ENABLED, ustEvents[1].getState());
-
-            // next session (no detailed information available)
-            session = fService.getSession("mysession1", new NullProgressMonitor());
-            assertNotNull(session);
-            assertEquals("mysession1", session.getName());
-            assertEquals("/home/user/lttng-traces/mysession1-20120203-133225", session.getSessionPath());
-            assertEquals(TraceSessionState.INACTIVE, session.getSessionState());
-
-            domains = session.getDomains();
-            assertNotNull(domains);
-            assertEquals(0, domains.length);
-        } catch (ExecutionException e) {
-            fail(e.toString());
-        }
-    }
-
-    @Test
-    public void testGetSessionWithLive() {
-        try {
-            fShell.setScenario(SCEN_GET_SESSION_WITH_LIVE);
-
-            // Verify Session (snapshot session, non-live)
-            ISessionInfo session = fService.getSession("mysession", new NullProgressMonitor());
-            assertNotNull(session);
-            assertEquals("mysession", session.getName());
-            assertEquals("/home/user/lttng-traces/mysession-20120129-084256", session.getSessionPath());
-            assertEquals(TraceSessionState.INACTIVE, session.getSessionState());
-            assertFalse(session.isLive());
-
-            // Verify Session (regular session, non-live)
-            session = fService.getSession("mysession1", new NullProgressMonitor());
-            assertNotNull(session);
-            assertEquals("mysession1", session.getName());
-            assertEquals("/home/user/lttng-traces/mysession1-20120129-084256", session.getSessionPath());
-            assertEquals(TraceSessionState.ACTIVE, session.getSessionState());
-            assertFalse(session.isLive());
-
-            // Verify Session (regular session, live)
-            session = fService.getSession("mysession2", new NullProgressMonitor());
-            assertNotNull(session);
-            assertEquals("mysession2", session.getName());
-            assertEquals("tcp4://172.0.0.1:5342/ [data: 5343]", session.getSessionPath());
-            assertEquals("net://127.0.0.1", session.getLiveUrl());
-            assertEquals(Integer.valueOf(5344), session.getLivePort());
-            assertEquals(1000000, session.getLiveDelay());
-            assertEquals(TraceSessionState.INACTIVE, session.getSessionState());
-            assertTrue(session.isLive());
-
-        } catch (ExecutionException e) {
-            fail(e.toString());
-        }
-    }
-
-    /**
-     * @return
-     */
-    protected TraceLogLevel getAllEventTraceLogLevel() {
-        return TraceLogLevel.LEVEL_UNKNOWN;
-    }
-
-    public void testGetKernelProvider() {
-        try {
-            fShell.setScenario(SCEN_GET_KERNEL_PROVIDER1);
-            List<IBaseEventInfo> events = fService.getKernelProvider(new NullProgressMonitor());
-
-            // Verify event info
-            assertNotNull(events);
-            assertEquals(3, events.size());
-
-            IBaseEventInfo baseEventInfo = events.get(0);
-            assertNotNull(baseEventInfo);
-            assertEquals("sched_kthread_stop", baseEventInfo.getName());
-            assertEquals(TraceLogLevel.TRACE_EMERG, baseEventInfo.getLogLevel());
-            assertEquals(TraceEventType.TRACEPOINT, baseEventInfo.getEventType());
-
-            baseEventInfo = events.get(1);
-            assertEquals("sched_kthread_stop_ret", baseEventInfo.getName());
-            assertEquals(TraceLogLevel.TRACE_EMERG, baseEventInfo.getLogLevel());
-            assertEquals(TraceEventType.TRACEPOINT, baseEventInfo.getEventType());
-
-            baseEventInfo = events.get(2);
-            assertEquals("sched_wakeup_new", baseEventInfo.getName());
-            assertEquals(TraceLogLevel.TRACE_EMERG, baseEventInfo.getLogLevel());
-            assertEquals(TraceEventType.TRACEPOINT, baseEventInfo.getEventType());
-
-        } catch (ExecutionException e) {
-            fail(e.toString());
-        }
-    }
-
-    @Test
-    public void testGetKernelProviderNoKernel1() {
-        try {
-            fShell.setScenario(SCEN_LIST_WITH_NO_KERNEL1);
-            List<IBaseEventInfo> events = fService.getKernelProvider(new NullProgressMonitor());
-
-            // Verify event info
-            assertNotNull(events);
-            assertEquals(0, events.size());
-
-        } catch (ExecutionException e) {
-            fail(e.toString());
-        }
-    }
-
-    @Test
-    public void testGetKernelProviderNoKernel2() {
-        try {
-            fShell.setScenario(SCEN_LIST_WITH_NO_KERNEL2);
-            List<IBaseEventInfo> events = fService.getKernelProvider(new NullProgressMonitor());
-
-            // Verify event info
-            assertNotNull(events);
-            assertEquals(0, events.size());
-
-        } catch (ExecutionException e) {
-            fail(e.toString());
-        }
-    }
-
-    @Test
-    public void testGetKernelProviderNoKernelVerbose() {
-        try {
-            enableVerbose();
-            fShell.setScenario(SCEN_LIST_WITH_NO_KERNEL_VERBOSE);
-            List<IBaseEventInfo> events = fService.getKernelProvider(new NullProgressMonitor());
-
-            // Verify event info
-            assertNotNull(events);
-            assertEquals(0, events.size());
-
-        } catch (ExecutionException e) {
-            fail(e.toString());
-        } finally {
-            disableVerbose();
-        }
-    }
-
-    @Test
-    public void testGetUstProvider() {
-        try {
-            fShell.setScenario(SCEN_GET_UST_PROVIDER1);
-            List<IUstProviderInfo> providers = fService.getUstProvider();
-
-            // Check all providers
-            assertNotNull(providers);
-            assertEquals(2, providers.size());
-
-            //Verify first provider
-            assertEquals("/home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello", providers.get(0).getName());
-            assertEquals(9379, providers.get(0).getPid());
-
-            // Verify event info
-            IBaseEventInfo[] events = providers.get(0).getEvents();
-            assertNotNull(events);
-            assertEquals(2, events.length);
-
-            IBaseEventInfo baseEventInfo = events[0];
-            assertNotNull(baseEventInfo);
-            assertEquals("ust_tests_hello:tptest_sighandler", baseEventInfo.getName());
-            assertEquals(TraceLogLevel.TRACE_DEBUG_MODULE, baseEventInfo.getLogLevel());
-            assertEquals(TraceEventType.TRACEPOINT, baseEventInfo.getEventType());
-
-            baseEventInfo = events[1];
-            assertEquals("ust_tests_hello:tptest", baseEventInfo.getName());
-            assertEquals(TraceLogLevel.TRACE_INFO, baseEventInfo.getLogLevel());
-            assertEquals(TraceEventType.TRACEPOINT, baseEventInfo.getEventType());
-
-            //Verify second provider
-            assertEquals("/home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello", providers.get(1).getName());
-            assertEquals(4852, providers.get(1).getPid());
-
-            // Verify event info
-            events = providers.get(1).getEvents();
-            assertNotNull(events);
-            assertEquals(2, events.length);
-
-            baseEventInfo = events[0];
-            assertNotNull(baseEventInfo);
-            assertEquals("ust_tests_hello:tptest_sighandler", baseEventInfo.getName());
-            assertEquals(TraceLogLevel.TRACE_WARNING, baseEventInfo.getLogLevel());
-            assertEquals(TraceEventType.TRACEPOINT, baseEventInfo.getEventType());
-
-            baseEventInfo = events[1];
-            assertEquals("ust_tests_hello:tptest", baseEventInfo.getName());
-            assertEquals(TraceLogLevel.TRACE_DEBUG_FUNCTION, baseEventInfo.getLogLevel());
-            assertEquals(TraceEventType.TRACEPOINT, baseEventInfo.getEventType());
-
-        } catch (ExecutionException e) {
-            fail(e.toString());
-        }
-    }
-
-    @Test
-    public void testUstProvider2() {
-        try {
-            fShell.setScenario(SCEN_GET_UST_PROVIDER2);
-            List<IUstProviderInfo> providers = fService.getUstProvider();
-
-            assertNotNull(providers);
-            assertEquals(0, providers.size());
-
-        } catch (ExecutionException e) {
-            fail(e.toString());
-        }
-    }
-
-    @Test
-    public void testGetUstProvider3() {
-        try {
-            fShell.setScenario(SCEN_GET_UST_PROVIDER3);
-            // Set version
-            ((LTTngControlService)fService).setVersion("2.1.0");
-            List<IUstProviderInfo> providers = fService.getUstProvider();
-
-            // Check all providers
-            assertNotNull(providers);
-            assertEquals(2, providers.size());
-
-            //Verify first provider
-            assertEquals("/home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello", providers.get(0).getName());
-            assertEquals(9379, providers.get(0).getPid());
-
-            // Verify event info
-            IBaseEventInfo[] events = providers.get(0).getEvents();
-            assertNotNull(events);
-            assertEquals(2, events.length);
-
-            IBaseEventInfo baseEventInfo = events[0];
-            assertNotNull(baseEventInfo);
-            IFieldInfo[] fields = baseEventInfo.getFields();
-            assertNotNull(fields);
-            assertEquals(0, fields.length);
-
-            baseEventInfo = events[1];
-            fields = baseEventInfo.getFields();
-            assertNotNull(fields);
-            assertEquals(3, fields.length);
-            assertEquals("doublefield", fields[0].getName());
-            assertEquals("float", fields[0].getFieldType());
-
-            assertEquals("floatfield", fields[1].getName());
-            assertEquals("float", fields[1].getFieldType());
-
-            assertEquals("stringfield", fields[2].getName());
-            assertEquals("string", fields[2].getFieldType());
-
-            //Verify second provider
-            assertEquals("/home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello", providers.get(1).getName());
-            assertEquals(4852, providers.get(1).getPid());
-
-            // Verify event info
-            events = providers.get(1).getEvents();
-            assertNotNull(events);
-            assertEquals(2, events.length);
-
-            baseEventInfo = events[0];
-            assertNotNull(baseEventInfo);
-            fields = baseEventInfo.getFields();
-            assertNotNull(fields);
-            assertEquals(0, fields.length);
-
-            baseEventInfo = events[1];
-            fields = baseEventInfo.getFields();
-            assertNotNull(fields);
-            assertEquals(3, fields.length);
-
-            assertEquals("doublefield", fields[0].getName());
-            assertEquals("float", fields[0].getFieldType());
-
-            assertEquals("floatfield", fields[1].getName());
-            assertEquals("float", fields[1].getFieldType());
-
-            assertEquals("stringfield", fields[2].getName());
-            assertEquals("string", fields[2].getFieldType());
-
-            // Reset version
-            ((LTTngControlService)fService).setVersion("2.0.0");
-
-        } catch (ExecutionException e) {
-            fail(e.toString());
-        }
-    }
-
-
-    @Test
-    public void testGetKernelProviderNoUst1() {
-        try {
-            fShell.setScenario(SCEN_LIST_WITH_NO_UST1);
-            List<IUstProviderInfo> providerList = fService.getUstProvider(new NullProgressMonitor());
-
-            // Verify Provider info
-            assertNotNull(providerList);
-            assertEquals(0, providerList.size());
-
-        } catch (ExecutionException e) {
-            fail(e.toString());
-        }
-    }
-
-
-    @Test
-    public void testGetKernelProviderNoUst2() {
-        try {
-            // Set version
-            ((LTTngControlService)fService).setVersion("2.1.0");
-
-            fShell.setScenario(SCEN_LIST_WITH_NO_UST2);
-            List<IUstProviderInfo> providerList = fService.getUstProvider(new NullProgressMonitor());
-
-            // Verify Provider info
-            assertNotNull(providerList);
-            assertEquals(0, providerList.size());
-
-            // Reset version
-            ((LTTngControlService)fService).setVersion("2.0.0");
-
-        } catch (ExecutionException e) {
-            fail(e.toString());
-        }
-    }
-
-    @Test
-    public void testGetKernelProviderNoUst3() {
-        try {
-
-            // Set version
-            ((LTTngControlService)fService).setVersion("2.1.0");
-
-            fShell.setScenario(SCEN_LIST_WITH_NO_UST3);
-            List<IUstProviderInfo> providerList = fService.getUstProvider(new NullProgressMonitor());
-
-            // Verify provider info
-            assertNotNull(providerList);
-            assertEquals(0, providerList.size());
-
-            // Reset version
-            ((LTTngControlService)fService).setVersion("2.0.0");
-
-        } catch (ExecutionException e) {
-            fail(e.toString());
-        }
-    }
-
-    @Test
-    public void testGetKernelProviderNoUstVerbose() {
-        try {
-            enableVerbose();
-
-            // Set version
-            ((LTTngControlService)fService).setVersion("2.1.0");
-
-            fShell.setScenario(SCEN_LIST_WITH_NO_UST_VERBOSE);
-            List<IUstProviderInfo> providerList = fService.getUstProvider(new NullProgressMonitor());
-
-            // Verify provider info
-            assertNotNull(providerList);
-            assertEquals(0, providerList.size());
-
-            // Reset version
-            ((LTTngControlService)fService).setVersion("2.0.0");
-
-        } catch (ExecutionException e) {
-            fail(e.toString());
-        } finally {
-            disableVerbose();
-        }
-    }
-
-
-
-    @Test
-    public void testCreateSession() {
-        try {
-            fShell.setScenario(SCEN_CREATE_SESSION1);
-
-            ISessionInfo info = fService.createSession(new SessionInfo("mysession2"), new NullProgressMonitor());
-            assertNotNull(info);
-            assertEquals("mysession2", info.getName());
-            assertNotNull(info.getSessionPath());
-            assertTrue(info.getSessionPath().contains("mysession2"));
-            assertEquals(TraceSessionState.INACTIVE, info.getSessionState());
-        } catch (ExecutionException e) {
-            fail(e.toString());
-        }
-    }
-
-    @Test
-    public void testCreateSessionWithPrompt() {
-        try {
-            // First line has the shell prompt before the command output
-            // This can happen in a real application if the command line is not echoed by the shell.
-            fShell.setScenario(SCEN_CREATE_SESSION_WITH_PROMPT);
-
-            // First line has no shell prompt before the output
-            ISessionInfo info = fService.createSession(new SessionInfo("mysession2"), new NullProgressMonitor());
-            assertNotNull(info);
-            assertEquals("mysession2", info.getName());
-            assertNotNull(info.getSessionPath());
-            assertTrue(info.getSessionPath().contains("mysession2"));
-            assertEquals(TraceSessionState.INACTIVE, info.getSessionState());
-        } catch (ExecutionException e) {
-            fail(e.toString());
-        }
-    }
-
-    @Test
-    public void testCreateSessionVariants() {
-
-        fShell.setScenario(SCEN_CREATE_SESSION_VARIANTS);
-
-        try {
-            fService.createSession(new SessionInfo("alreadyExist"), new NullProgressMonitor());
-            fail("No exeption thrown");
-        } catch (ExecutionException e) {
-            // success
-        }
-
-        try {
-            fService.createSession(new SessionInfo("wrongName"), new NullProgressMonitor());
-            fail("No exeption thrown");
-        } catch (ExecutionException e) {
-            // success
-        }
-
-        try {
-            ISessionInfo sessionInfo = new SessionInfo("withPath");
-            sessionInfo.setSessionPath("/home/user/hallo");
-            fService.createSession(sessionInfo, new NullProgressMonitor());
-            fail("No exeption thrown");
-        } catch (ExecutionException e) {
-            // success
-        }
-
-        try {
-            ISessionInfo info = fService.createSession(new SessionInfo("session with spaces"), new NullProgressMonitor());
-            assertNotNull(info);
-            assertEquals("session with spaces", info.getName());
-            assertNotNull(info.getSessionPath());
-            assertTrue(info.getSessionPath().contains("session with spaces"));
-            assertEquals(TraceSessionState.INACTIVE, info.getSessionState());
-
-        } catch (ExecutionException e) {
-            fail(e.toString());
-        }
-
-        try {
-            ISessionInfo sessionInfo = new SessionInfo("pathWithSpaces");
-            sessionInfo.setSessionPath("/home/user/hallo user/here");
-            ISessionInfo info = fService.createSession(sessionInfo, new NullProgressMonitor());
-            assertNotNull(info);
-            assertEquals("pathWithSpaces", info.getName());
-            assertNotNull(info.getSessionPath());
-            assertTrue(info.getSessionPath().contains("/home/user/hallo user/here"));
-            assertEquals(TraceSessionState.INACTIVE, info.getSessionState());
-
-        } catch (ExecutionException e) {
-            fail(e.toString());
-        }
-    }
-
-    @Test
-    public void testDestroySession() {
-        try {
-            fShell.setScenario(SCEN_DESTROY_SESSION1);
-            fService.destroySession("mysession2", new NullProgressMonitor());
-        } catch (ExecutionException e) {
-            fail(e.toString());
-        }
-    }
-
-    @Test
-    public void testDestroySessionVerbose() {
-        try {
-            enableVerbose();
-            fShell.setScenario(SCEN_DESTROY_SESSION_VERBOSE);
-            fService.destroySession("mysession2", new NullProgressMonitor());
-        } catch (ExecutionException e) {
-            fail(e.toString());
-        } finally {
-            disableVerbose();
-        }
-    }
-
-    @Test
-    public void testCreateChannel() {
-        try {
-            ((LTTngControlService)fService).setVersion("2.2.0");
-            String sessionName = "mysession2";
-            List<String> list = new ArrayList<>();
-            String kernelChannel0 = "mychannel0";
-            String kernelChannel1 = "mychannel1";
-            list.add(kernelChannel0);
-            list.add(kernelChannel1);
-
-            fShell.setScenario(SCEN_CHANNEL_HANDLING);
-
-            // Create/enable/configure 2 kernel channels
-            ChannelInfo chanInfo = new ChannelInfo("");
-            chanInfo.setOverwriteMode(true);
-            chanInfo.setSubBufferSize(16384);
-            chanInfo.setReadTimer(100);
-            chanInfo.setSwitchTimer(200);
-            chanInfo.setNumberOfSubBuffers(2);
-            chanInfo.setMaxNumberTraceFiles(10);
-            chanInfo.setMaxSizeTraceFiles(0);
-            fService.enableChannels(sessionName, list, true, chanInfo, new NullProgressMonitor());
-
-            // Create/enable/configure 1 UST channel
-            list.clear();
-            list.add("ustChannel");
-
-            chanInfo = new ChannelInfo("");
-            chanInfo.setOverwriteMode(true);
-            chanInfo.setSubBufferSize(32768);
-            chanInfo.setReadTimer(200);
-            chanInfo.setSwitchTimer(100);
-            chanInfo.setNumberOfSubBuffers(1);
-            chanInfo.setMaxNumberTraceFiles(20);
-            chanInfo.setMaxSizeTraceFiles(0);
-            fService.enableChannels(sessionName, list, false, chanInfo, new NullProgressMonitor());
-            ((LTTngControlService)fService).setVersion("2.0.0");
-
-        } catch (ExecutionException e) {
-            fail(e.toString());
-        }
-    }
-
-    @Test
-    public void testCreateChannelUIDBuffer() {
-        try {
-            ((LTTngControlService)fService).setVersion("2.2.0");
-            String sessionName = "mysession2";
-            List<String> list = new ArrayList<>();
-            String USTChannel = "ustChannel";
-            list.add(USTChannel);
-            fShell.setScenario(SCEN_CHANNEL_HANDLING);
-
-            ChannelInfo chanInfo = new ChannelInfo("");
-            chanInfo.setOverwriteMode(true);
-            chanInfo.setSubBufferSize(32768);
-            chanInfo.setReadTimer(200);
-            chanInfo.setSwitchTimer(100);
-            chanInfo.setNumberOfSubBuffers(1);
-            chanInfo.setMaxNumberTraceFiles(20);
-            chanInfo.setMaxSizeTraceFiles(0);
-            chanInfo.setBufferType(BufferType.BUFFER_PER_UID);
-            fService.enableChannels(sessionName, list, false, chanInfo, new NullProgressMonitor());
-            ((LTTngControlService)fService).setVersion("2.0.0");
-
-        } catch (ExecutionException e) {
-            fail(e.toString());
-        }
-    }
-
-    @Test
-    public void testCreateChannelPIDBuffer() {
-        try {
-            ((LTTngControlService)fService).setVersion("2.2.0");
-            String sessionName = "mysession2";
-            List<String> list = new ArrayList<>();
-            String USTChannel = "ustChannel";
-            list.add(USTChannel);
-            fShell.setScenario(SCEN_CHANNEL_HANDLING);
-
-
-            ChannelInfo chanInfo = new ChannelInfo("");
-            chanInfo.setOverwriteMode(true);
-            chanInfo.setSubBufferSize(-1);
-            chanInfo.setReadTimer(-1);
-            chanInfo.setSwitchTimer(-1);
-            chanInfo.setNumberOfSubBuffers(-1);
-            chanInfo.setMaxNumberTraceFiles(-1);
-            chanInfo.setMaxSizeTraceFiles(-1);
-            chanInfo.setBufferType(BufferType.BUFFER_PER_PID);
-
-            fService.enableChannels(sessionName, list, false, chanInfo, new NullProgressMonitor());
-            ((LTTngControlService)fService).setVersion("2.0.0");
-
-        } catch (ExecutionException e) {
-            fail(e.toString());
-        }
-    }
-
-    @Test
-    public void testDisableChannel() {
-        try {
-
-            String sessionName = "mysession2";
-            List<String> list = new ArrayList<>();
-            String kernelChannel0 = "mychannel0";
-            String kernelChannel1 = "mychannel1";
-            list.add(kernelChannel0);
-            list.add(kernelChannel1);
-
-            fShell.setScenario(SCEN_CHANNEL_HANDLING);
-            fService.disableChannels(sessionName, list, true, new NullProgressMonitor());
-
-            list.clear();
-            list.add("ustChannel");
-            fService.disableChannels(sessionName, list, false, new NullProgressMonitor());
-
-        } catch (ExecutionException e) {
-            fail(e.toString());
-        }
-    }
-
-    @Test
-    public void testEnableChannel() {
-        try {
-
-            String sessionName = "mysession2";
-            List<String> list = new ArrayList<>();
-            String kernelChannel0 = "mychannel0";
-            String kernelChannel1 = "mychannel1";
-            list.add(kernelChannel0);
-            list.add(kernelChannel1);
-
-            fShell.setScenario(SCEN_CHANNEL_HANDLING);
-            fService.enableChannels(sessionName, list, true, null, new NullProgressMonitor());
-
-            // Create/enable/configure 1 UST channel
-            list.clear();
-            list.add("ustChannel");
-
-            fService.enableChannels(sessionName, list, false, null, new NullProgressMonitor());
-
-        } catch (ExecutionException e) {
-            fail(e.toString());
-        }
-    }
-
-    @Test
-    public void testEnableEvents() {
-        try {
-            // 1) session name, channel = null, 3 event names, kernel
-            String sessionName = "mysession2";
-            List<String> list = new ArrayList<>();
-            String eventName0 = "block_rq_remap";
-            String eventName1 = "block_bio_remap";
-            String eventName2 = "softirq_entry";
-            list.add(eventName0);
-            list.add(eventName1);
-            list.add(eventName2);
-            fShell.setScenario(SCEN_EVENT_HANDLING);
-            fService.enableEvents(sessionName, null, list, true, null, new NullProgressMonitor());
-
-            // 2) session name, channel=mychannel, event name= null, kernel
-            String channelName = "mychannel";
-            fService.enableEvents(sessionName, channelName, null, true, null, new NullProgressMonitor());
-
-            // 3) session name, channel=mychannel, 1 event name, ust, no filter
-            String ustEventName = "ust_tests_hello:tptest_sighandler";
-            list.clear();
-            list.add(ustEventName);
-            fService.enableEvents(sessionName, channelName, list, false, null, new NullProgressMonitor());
-
-            // 4) session name, channel = mychannel, no event name, ust, with filter
-            fService.enableEvents(sessionName, channelName, list, false, "intfield==10", new NullProgressMonitor());
-
-            // 5) session name, channel = mychannel, no event name, ust, no filter
-            list.clear();
-            fService.enableEvents(sessionName, channelName, list, false, null, new NullProgressMonitor());
-
-            // TODO add test with filters
-
-        } catch (ExecutionException e) {
-            fail(e.toString());
-        }
-    }
-
-    @Test
-    public void testEnableSyscalls() {
-        try {
-            // 1) session name, channel = null, 3 event names, kernel
-            String sessionName = "mysession2";
-            String channelName = "mychannel";
-
-            fShell.setScenario(SCEN_EVENT_HANDLING);
-
-            // 1) session name, channel = null
-            fService.enableSyscalls(sessionName, null, new NullProgressMonitor());
-
-            // 2) session name, channel = mychannel
-            fService.enableSyscalls(sessionName, channelName, new NullProgressMonitor());
-
-        } catch (ExecutionException e) {
-            fail(e.toString());
-        }
-    }
-
-    @Test
-    public void testDynamicProbe() {
-        try {
-            // 1) session name, channel = null, 3 event names, kernel
-            String sessionName = "mysession2";
-            String channelName = "mychannel";
-            String eventName0 = "myevent0";
-            String eventName1 = "myevent1";
-            String functionProbe = "0xc0101340";
-            String dynProbe = "init_post";
-
-            fShell.setScenario(SCEN_EVENT_HANDLING);
-
-            // 1) session name, channel = null, event name, function probe, probe
-            fService.enableProbe(sessionName, null, eventName0, true, functionProbe, new NullProgressMonitor());
-
-            // 2) session name, channel = mychannel
-            fService.enableProbe(sessionName, channelName, eventName1, false, dynProbe, new NullProgressMonitor());
-
-        } catch (ExecutionException e) {
-            fail(e.toString());
-        }
-    }
-
-    @Test
-    public void testEnableLogLevel() {
-        try {
-            // 1) session name, channel = null, 3 event names, kernel
-            String sessionName = "mysession2";
-            String channelName = "mychannel";
-            String eventName4 = "myevent4";
-            String eventName5 = "myevent5";
-
-            fShell.setScenario(SCEN_EVENT_HANDLING);
-
-            // 1) session name, channel = null, event name, loglevel-only, TRACE_DEBUG
-            fService.enableLogLevel(sessionName, null, eventName4, LogLevelType.LOGLEVEL_ONLY, TraceLogLevel.TRACE_DEBUG, null, new NullProgressMonitor());
-
-            // 2) session name, channel = mychannel, null, loglevel, TRACE_DEBUG_FUNCTION
-            fService.enableLogLevel(sessionName, channelName, eventName5, LogLevelType.LOGLEVEL, TraceLogLevel.TRACE_DEBUG_FUNCTION, null, new NullProgressMonitor());
-
-            // TODO add test with filters
-
-        } catch (ExecutionException e) {
-            fail(e.toString());
-        }
-    }
-
-    @Test
-    public void testAddContext() {
-        try {
-            // 1) session name, channel = null, 3 event names, kernel
-            String sessionName = "mysession2";
-            String channelName = "mychannel";
-            String eventName = "ust_tests_hello:tptest_sighandler";
-            List<String> contexts = new ArrayList<>();
-            contexts.add("prio");
-            contexts.add("pid");
-
-            fShell.setScenario(SCEN_CONTEXT_HANDLING);
-
-            List<String> availContexts = fService.getContextList(new NullProgressMonitor());
-            assertNotNull(availContexts);
-            assertEquals(12, availContexts.size());
-
-            // A very "hard-coded" way to verify but it works ...
-            Set<String> expectedContexts = new HashSet<>();
-            expectedContexts.add("pid");
-            expectedContexts.add("procname");
-            expectedContexts.add("prio");
-            expectedContexts.add("nice");
-            expectedContexts.add("vpid");
-            expectedContexts.add("tid");
-            expectedContexts.add("pthread_id");
-            expectedContexts.add("vtid");
-            expectedContexts.add("ppid");
-            expectedContexts.add("vppid");
-            expectedContexts.add("perf:cpu-cycles");
-            expectedContexts.add("perf:cycles");
-
-            assertTrue(expectedContexts.containsAll(availContexts));
-
-            // 1) session name, channel = null, event name, loglevel-only, TRACE_DEBUG
-            fService.addContexts(sessionName, channelName, eventName, false, contexts, new NullProgressMonitor());
-
-        } catch (ExecutionException e) {
-            fail(e.toString());
-        }
-    }
-
-    @Test
-    public void testAddContextFailure() {
-
-        // 1) session name, channel = null, 3 event names, kernel
-        String sessionName = "mysession2";
-        String channelName = "mychannel";
-        String eventName = "ust_tests_hello:tptest_sighandler";
-        List<String> contexts = new ArrayList<>();
-        contexts.add("prio");
-        contexts.add("pid");
-        fShell.setScenario(SCEN_CONTEXT_ERROR_HANDLING);
-        try {
-            fService.getContextList(new NullProgressMonitor());
-            fail("No exeption generated");
-        } catch (ExecutionException e) {
-            // success
-        }
-        try {
-            // 1) session name, channel = null, event name, loglevel-only, TRACE_DEBUG
-            fService.addContexts(sessionName, channelName, eventName, false, contexts, new NullProgressMonitor());
-            fail("No exeption generated");
-        } catch (ExecutionException e) {
-            // success
-        }
-    }
-
-    @Test
-    public void testCalibrate() {
-        try {
-            fShell.setScenario(SCEN_CALIBRATE_HANDLING);
-            fService.calibrate(true, new NullProgressMonitor());
-
-        } catch (ExecutionException e) {
-            fail(e.toString());
-        }
-    }
-
-    @Test
-    public void testCalibrateFailure() {
-        try {
-            fShell.setScenario(SCEN_CALIBRATE_HANDLING);
-            fService.calibrate(false, new NullProgressMonitor());
-            fail("No exeption generated");
-        } catch (ExecutionException e) {
-            // success
-        }
-    }
-
-    @Test
-    public void testCreateSession2_1() {
-
-        try {
-            fShell.setScenario(SCEN_CREATE_SESSION_2_1);
-
-            ISessionInfo sessionInfo = new SessionInfo("mysession");
-            sessionInfo.setNetworkUrl("net://172.0.0.1");
-            sessionInfo.setStreamedTrace(true);
-            ISessionInfo info = fService.createSession(sessionInfo, new NullProgressMonitor());
-            assertNotNull(info);
-            assertEquals("mysession", info.getName());
-            assertEquals("net://172.0.0.1", info.getSessionPath());
-            assertTrue(info.isStreamedTrace());
-            fService.destroySession("mysession", new NullProgressMonitor());
-
-            sessionInfo = new SessionInfo("mysession");
-            sessionInfo.setStreamedTrace(true);
-            sessionInfo.setNetworkUrl("file:///tmp");
-            info = fService.createSession(sessionInfo, new NullProgressMonitor());
-            assertNotNull(info);
-            assertEquals("mysession", info.getName());
-            assertEquals("file:///tmp", info.getSessionPath());
-            assertTrue(!info.isStreamedTrace());
-            fService.destroySession("mysession", new NullProgressMonitor());
-
-            sessionInfo = new SessionInfo("mysession");
-            sessionInfo.setStreamedTrace(true);
-            sessionInfo.setNetworkUrl("file:///tmp");
-            info = fService.createSession(sessionInfo, new NullProgressMonitor());
-            assertNotNull(info);
-            assertEquals("mysession", info.getName());
-            assertEquals("file:///tmp", info.getSessionPath());
-            assertTrue(!info.isStreamedTrace());
-            fService.destroySession("mysession", new NullProgressMonitor());
-
-            sessionInfo = new SessionInfo("mysession");
-            sessionInfo.setStreamedTrace(true);
-            sessionInfo.setControlUrl("tcp://172.0.0.1");
-            sessionInfo.setDataUrl("tcp://172.0.0.1:5343");
-            info = fService.createSession(sessionInfo, new NullProgressMonitor());
-            assertNotNull(info);
-            assertEquals("mysession", info.getName());
-            assertEquals("", info.getSessionPath()); // the complete network path is not available at this point
-            assertTrue(info.isStreamedTrace());
-            fService.destroySession("mysession", new NullProgressMonitor());
-
-            sessionInfo = new SessionInfo("mysession");
-            sessionInfo.setStreamedTrace(true);
-            sessionInfo.setNetworkUrl("net://172.0.0.1:1234:2345");
-            info = fService.createSession(sessionInfo, new NullProgressMonitor());
-            assertNotNull(info);
-            assertEquals("mysession", info.getName());
-            assertEquals("net://172.0.0.1:1234:2345", info.getSessionPath());
-            assertTrue(info.isStreamedTrace());
-            fService.destroySession("mysession", new NullProgressMonitor());
-
-            // verbose
-            enableVerbose();
-            sessionInfo = new SessionInfo("mysession");
-            sessionInfo.setStreamedTrace(true);
-            sessionInfo.setNetworkUrl("net://172.0.0.1");
-            info = fService.createSession(sessionInfo, new NullProgressMonitor());
-            assertNotNull(info);
-            assertEquals("mysession", info.getName());
-            assertEquals("net://172.0.0.1", info.getSessionPath());
-            assertTrue(info.isStreamedTrace());
-            disableVerbose();
-            fService.destroySession("mysession", new NullProgressMonitor());
-
-
-        } catch (ExecutionException e) {
-            fail(e.toString());
-        }
-    }
-
-    @Test
-    public void testCreateSessionVerbose2_1() {
-        try {
-            fShell.setScenario(SCEN_CREATE_SESSION_VERBOSE_2_1);
-
-            enableVerbose();
-            ISessionInfo sessionInfo = new SessionInfo("mysession");
-            sessionInfo.setStreamedTrace(true);
-            sessionInfo.setNetworkUrl("net://172.0.0.1");
-            ISessionInfo info = fService.createSession(sessionInfo, new NullProgressMonitor());
-            assertNotNull(info);
-            assertEquals("mysession", info.getName());
-            assertEquals("net://172.0.0.1", info.getSessionPath());
-            assertTrue(info.isStreamedTrace());
-            fService.destroySession("mysession", new NullProgressMonitor());
-        } catch (ExecutionException e) {
-            fail(e.toString());
-        } finally {
-            disableVerbose();
-        }
-    }
-
-    @Test
-    public void testCreateSnapshotSession() {
-        try {
-            fShell.setScenario(SCEN_CREATE_SNAPSHOT_SESSION);
-            ISessionInfo params = new SessionInfo("mysession");
-            params.setSnapshot(true);
-            ISessionInfo sessionInfo = fService.createSession(params, new NullProgressMonitor());
-            assertNotNull(sessionInfo);
-            assertEquals("mysession", sessionInfo.getName());
-            assertTrue(sessionInfo.isSnapshotSession());
-            assertEquals("", sessionInfo.getSessionPath());
-            assertTrue(!sessionInfo.isStreamedTrace());
-
-            assertEquals(TraceSessionState.INACTIVE, sessionInfo.getSessionState());
-
-            List<String> names = fService.getSessionNames(new NullProgressMonitor());
-            assertEquals(names.get(0), "mysession");
-
-            ISnapshotInfo snapshotInfo = fService.getSnapshotInfo("mysession", new NullProgressMonitor());
-            assertNotNull(snapshotInfo);
-            assertEquals("snapshot-1", snapshotInfo.getName());
-            assertEquals("/home/user/lttng-traces/mysession-20130913-141651", snapshotInfo.getSnapshotPath());
-            assertEquals(1, snapshotInfo.getId());
-            assertTrue(!snapshotInfo.isStreamedSnapshot());
-
-            // we need to set the snapshotInfo to so that the session path is set correctly
-            sessionInfo.setSnapshotInfo(snapshotInfo);
-            assertEquals("/home/user/lttng-traces/mysession-20130913-141651", sessionInfo.getSessionPath());
-
-            fService.recordSnapshot("mysession", new NullProgressMonitor());
-
-            fService.destroySession("mysession", new NullProgressMonitor());
-
-        } catch (ExecutionException e) {
-            fail(e.toString());
-        }
-    }
-
-    @Test
-    public void testCreateSnapshotSession2_5() {
-        try {
-            fShell.setScenario(SCEN_CREATE_SNAPSHOT_SESSION_2_5);
-            ISessionInfo params = new SessionInfo("mysession");
-            params.setSnapshot(true);
-            ISessionInfo sessionInfo = fService.createSession(params, new NullProgressMonitor());
-            assertNotNull(sessionInfo);
-            assertEquals("mysession", sessionInfo.getName());
-            assertTrue(sessionInfo.isSnapshotSession());
-            assertEquals("", sessionInfo.getSessionPath());
-            assertTrue(!sessionInfo.isStreamedTrace());
-
-            assertEquals(TraceSessionState.INACTIVE, sessionInfo.getSessionState());
-
-            List<String> names = fService.getSessionNames(new NullProgressMonitor());
-            assertEquals(names.get(0), "mysession");
-
-            ISnapshotInfo snapshotInfo = fService.getSnapshotInfo("mysession", new NullProgressMonitor());
-            assertNotNull(snapshotInfo);
-            assertEquals("snapshot-1", snapshotInfo.getName());
-            assertEquals("/home/user/lttng-traces/mysession-20130913-141651", snapshotInfo.getSnapshotPath());
-            assertEquals(1, snapshotInfo.getId());
-            assertTrue(!snapshotInfo.isStreamedSnapshot());
-
-            // we need to set the snapshotInfo to so that the session path is set correctly
-            sessionInfo.setSnapshotInfo(snapshotInfo);
-            assertEquals("/home/user/lttng-traces/mysession-20130913-141651", sessionInfo.getSessionPath());
-
-            fService.recordSnapshot("mysession", new NullProgressMonitor());
-
-            fService.destroySession("mysession", new NullProgressMonitor());
-
-        } catch (ExecutionException e) {
-            fail(e.toString());
-        }
-    }
-
-    public void testCreateStreamedSnapshotSession() {
-        try {
-            fShell.setScenario(SCEN_CREATE_STREAMED_SNAPSHOT_SESSION);
-
-            ISessionInfo params = new SessionInfo("mysession");
-            params.setNetworkUrl("net://172.0.0.1");
-            ISessionInfo sessionInfo = fService.createSession(params, new NullProgressMonitor());
-            assertNotNull(sessionInfo);
-            assertEquals("mysession", sessionInfo.getName());
-            assertTrue(sessionInfo.isSnapshotSession());
-
-            assertEquals(TraceSessionState.INACTIVE, sessionInfo.getSessionState());
-            assertTrue(sessionInfo.isStreamedTrace());
-
-            List<String> names = fService.getSessionNames(new NullProgressMonitor());
-            assertEquals(names.get(0), "mysession");
-
-            ISnapshotInfo snapshotInfo = sessionInfo.getSnapshotInfo();
-            assertNotNull(sessionInfo);
-            assertEquals("snapshot-2", snapshotInfo.getName());
-            assertEquals("net4://172.0.0.1:5342/", snapshotInfo.getSnapshotPath());
-            assertEquals(2, snapshotInfo.getId());
-            assertTrue(snapshotInfo.isStreamedSnapshot());
-
-            // we need to set the snapshotInfo to so that the session path is set correctly
-            sessionInfo.setSnapshotInfo(snapshotInfo);
-            assertEquals("net4://172.0.0.1:5342/", sessionInfo.getSessionPath());
-
-            fService.recordSnapshot("mysession", new NullProgressMonitor());
-
-            fService.destroySession("mysession", new NullProgressMonitor());
-
-        } catch (ExecutionException e) {
-            fail(e.toString());
-        }
-    }
-
-    @Test
-    public void testCreateSnapshotSessionErrors() {
-        try {
-            fShell.setScenario(SCEN_CREATE_SNAPSHOT_SESSION_ERRORS);
-
-            List<String> names = fService.getSessionNames(new NullProgressMonitor());
-            assertEquals(names.get(0), "mysession");
-        } catch (ExecutionException e) {
-            fail(e.toString());
-        }
-
-        try {
-            fService.getSnapshotInfo("blabla", new NullProgressMonitor());
-            fail("getSnapshoInfo() didn't fail");
-        } catch (ExecutionException e) {
-            // successful
-        }
-
-        try {
-            fService.recordSnapshot("blabla", new NullProgressMonitor());
-            fail("getSnapshoInfo() didn't fail");
-        } catch (ExecutionException e) {
-            // successful
-        }
-
-        try {
-            fService.recordSnapshot("mysession", new NullProgressMonitor());
-            fail("getSnapshoInfo() didn't fail");
-        } catch (ExecutionException e) {
-            // successful
-        }
-    }
-
-    @Test
-    public void testCreateLiveSession() throws ExecutionException {
-        fShell.setScenario(SCEN_CREATE_LIVE_SESSION);
-
-        ISessionInfo params = new SessionInfo("mysession");
-        params.setLive(true);
-        params.setStreamedTrace(true);
-        params.setNetworkUrl("net://127.0.0.1");
-        ISessionInfo sessionInfo = fService.createSession(params, new NullProgressMonitor());
-        assertNotNull(sessionInfo);
-        assertEquals("mysession", sessionInfo.getName());
-        assertEquals(TraceSessionState.INACTIVE, sessionInfo.getSessionState());
-        assertTrue(sessionInfo.isStreamedTrace());
-        assertTrue(sessionInfo.isLive());
-        assertEquals("net://127.0.0.1", sessionInfo.getSessionPath());
-        List<String> names = fService.getSessionNames(new NullProgressMonitor());
-        assertEquals(names.get(0), "mysession");
-        fService.destroySession("mysession", new NullProgressMonitor());
-    }
-
-    @Test
-    public void testCreateLiveSessionErrors() {
-        try {
-            fShell.setScenario(SCEN_CREATE_LIVE_SESSION_ERRORS);
-
-            ISessionInfo parameters = new SessionInfo("mysession");
-            parameters.setLive(true);
-            parameters.setSnapshot(true);
-            fService.createSession(parameters, new NullProgressMonitor());
-            fail("createSession() didn't fail");
-        } catch (ExecutionException e) {
-            // successful
-        }
-
-        try {
-            ISessionInfo parameters = new SessionInfo("mysession");
-            parameters.setNetworkUrl("blah");
-            parameters.setLive(true);
-            fService.createSession(parameters, new NullProgressMonitor());
-            fail("createSession() didn't fail");
-        } catch (ExecutionException e) {
-            // successful
-        }
-
-        try {
-            ISessionInfo parameters = new SessionInfo("mysession");
-            parameters.setControlUrl("net://127.0.0.1");
-            parameters.setLive(true);
-            fService.createSession(parameters, new NullProgressMonitor());
-            fail("createSession() didn't fail");
-        } catch (ExecutionException e) {
-            // successful
-        }
-    }
-
-    private static void enableVerbose() {
-        // verbose
-        ControlCommandLogger.init(ControlPreferences.getInstance().getLogfilePath(), false);
-        ControlPreferences.getInstance().getPreferenceStore().setDefault(ControlPreferences.TRACE_CONTROL_LOG_COMMANDS_PREF, true);
-        ControlPreferences.getInstance().getPreferenceStore().setDefault(ControlPreferences.TRACE_CONTROL_VERBOSE_LEVEL_PREF, ControlPreferences.TRACE_CONTROL_VERBOSE_LEVEL_V_V_VERBOSE);
-    }
-
-    private static void disableVerbose() {
-        ControlPreferences.getInstance().getPreferenceStore().setDefault(ControlPreferences.TRACE_CONTROL_LOG_COMMANDS_PREF, false);
-    }
-
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui.tests/stubs/org/eclipse/tracecompass/internal/lttng2/control/stubs/dialogs/AddContextDialogStub.java b/org.eclipse.tracecompass.lttng2.control.ui.tests/stubs/org/eclipse/tracecompass/internal/lttng2/control/stubs/dialogs/AddContextDialogStub.java
deleted file mode 100644 (file)
index c929186..0000000
+++ /dev/null
@@ -1,63 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs;
-
-import java.util.ArrayList;
-import java.util.HashSet;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Set;
-
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.IAddContextDialog;
-
-/**
- * Add Context dialog stub.
- */
-@SuppressWarnings("javadoc")
-public class AddContextDialogStub implements IAddContextDialog {
-
-    private Set<String> fAvailableContexts = null;
-    private List<String> fContexts = null;
-
-    @Override
-    public int open() {
-        return 0;
-    }
-
-    @Override
-    public void setAvalibleContexts(List<String> contexts) {
-        fAvailableContexts = new HashSet<>();
-        fAvailableContexts.addAll(contexts);
-    }
-
-    @Override
-    public List<String> getContexts() {
-        List<String> ret = new ArrayList<>();
-        ret.addAll(fContexts);
-        return ret;
-    }
-
-    public void setContexts(List<String> contexts) throws IllegalArgumentException{
-        fContexts = new ArrayList<>();
-        fContexts.addAll(contexts);
-        // If availableContexts are null we cannot verify
-        if (fAvailableContexts != null) {
-            for (Iterator<String> iterator = fContexts.iterator(); iterator.hasNext();) {
-                String string = iterator.next();
-                if (!fAvailableContexts.contains(string)) {
-                    throw new IllegalArgumentException();
-                }
-            }
-        }
-    }
-}
-
diff --git a/org.eclipse.tracecompass.lttng2.control.ui.tests/stubs/org/eclipse/tracecompass/internal/lttng2/control/stubs/dialogs/CreateSessionDialogStub.java b/org.eclipse.tracecompass.lttng2.control.ui.tests/stubs/org/eclipse/tracecompass/internal/lttng2/control/stubs/dialogs/CreateSessionDialogStub.java
deleted file mode 100644 (file)
index 0d4ca9d..0000000
+++ /dev/null
@@ -1,101 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
- *   Marc-Andre Laperle - Support for creating a live session
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs;
-
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISessionInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.SessionInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.ICreateSessionDialog;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionGroup;
-
-/**
- * Create session dialog stub implementation.
- */
-@SuppressWarnings("javadoc")
-public class CreateSessionDialogStub implements ICreateSessionDialog {
-
-    public String fName = "mysession";
-    public String fPath = null;
-    private boolean fIsStreamedTrace = false;
-    private String fNetworkUrl = null;
-    private String fControlUrl = null;
-    private String fDataUrl = null;
-    private boolean fIsSnapshot;
-    private boolean fIsLive = false;
-    private long fLiveDelay = 0;
-
-    @Override
-    public void initialize(TraceSessionGroup group) {
-    }
-
-    @Override
-    public int open() {
-        return 0;
-    }
-
-    public void setSessionPath(String path) {
-        fPath = path;
-    }
-
-    public void setSessionName(String name) {
-        fName = name;
-    }
-
-    public void setStreamedTrace(boolean isStreamedTrace) {
-        fIsStreamedTrace = isStreamedTrace;
-    }
-
-    public void setNetworkUrl(String fNetworkUrl) {
-        this.fNetworkUrl = fNetworkUrl;
-    }
-
-    public void setControlUrl(String fControlUrl) {
-        this.fControlUrl = fControlUrl;
-    }
-
-    public void setDataUrl(String fDataUrl) {
-        this.fDataUrl = fDataUrl;
-    }
-
-    public void setSnapshot(boolean isSnapshot) {
-        fIsSnapshot = isSnapshot;
-    }
-
-    public void setLive(boolean isLive) {
-        fIsLive = isLive;
-    }
-
-    public void setLiveDelay(int liveDelay) {
-        fLiveDelay = liveDelay;
-    }
-
-    @Override
-    public ISessionInfo getParameters() {
-        ISessionInfo sessionInfo = new SessionInfo(fName);
-
-        if (fIsStreamedTrace) {
-            sessionInfo.setNetworkUrl(fNetworkUrl);
-            sessionInfo.setControlUrl(fControlUrl);
-            sessionInfo.setDataUrl(fDataUrl);
-            sessionInfo.setStreamedTrace(true);
-        } else if (fPath != null) {
-            sessionInfo.setSessionPath(fPath);
-        }
-
-        sessionInfo.setLive(fIsLive);
-        sessionInfo.setLiveDelay(fLiveDelay);
-        sessionInfo.setSnapshot(fIsSnapshot);
-
-        return sessionInfo;
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui.tests/stubs/org/eclipse/tracecompass/internal/lttng2/control/stubs/dialogs/DestroyConfirmDialogStub.java b/org.eclipse.tracecompass.lttng2.control.ui.tests/stubs/org/eclipse/tracecompass/internal/lttng2/control/stubs/dialogs/DestroyConfirmDialogStub.java
deleted file mode 100644 (file)
index 6cfc86a..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs;
-
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.IConfirmDialog;
-
-/**
- * A confirmation dialog stub implementation.
- */
-public class DestroyConfirmDialogStub implements IConfirmDialog {
-
-    @Override
-    public boolean openConfirm(Shell parent, String title, String message) {
-        return true;
-    }
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.ui.tests/stubs/org/eclipse/tracecompass/internal/lttng2/control/stubs/dialogs/EnableChannelDialogStub.java b/org.eclipse.tracecompass.lttng2.control.ui.tests/stubs/org/eclipse/tracecompass/internal/lttng2/control/stubs/dialogs/EnableChannelDialogStub.java
deleted file mode 100644 (file)
index 570f0a7..0000000
+++ /dev/null
@@ -1,93 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs;
-
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IChannelInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.BufferType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.ChannelInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.IEnableChannelDialog;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent;
-
-/**
- * Create channel dialog stub implementation.
- */
-@SuppressWarnings("javadoc")
-public class EnableChannelDialogStub implements IEnableChannelDialog {
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-    private TraceDomainComponent fDomain;
-    private ChannelInfo fChannelInfo;
-    private boolean fIsKernel;
-
-    // ------------------------------------------------------------------------
-    // Constructor
-    // ------------------------------------------------------------------------
-    public EnableChannelDialogStub() {
-        fChannelInfo = new ChannelInfo("mychannel");
-        fChannelInfo.setNumberOfSubBuffers(4);
-        fChannelInfo.setOverwriteMode(true);
-        fChannelInfo.setReadTimer(200);
-        fChannelInfo.setSwitchTimer(100);
-        fChannelInfo.setSubBufferSize(16384);
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-    public void setIsKernel(boolean isKernel) {
-        fIsKernel = isKernel;
-    }
-
-    @Override
-    public IChannelInfo getChannelInfo() {
-        return fChannelInfo;
-    }
-
-    @Override
-    public void setDomainComponent(TraceDomainComponent domain) {
-        fDomain = domain;
-        if (fDomain != null) {
-            fIsKernel = fDomain.isKernel();
-        }
-    }
-
-    @Override
-    public int open() {
-        return 0;
-    }
-
-    @Override
-    public boolean isKernel() {
-        return fIsKernel;
-    }
-
-    @Override
-    public void setHasKernel(boolean hasKernel) {
-        // Do nothing
-    }
-
-    public void setChannelInfo(ChannelInfo info) {
-        fChannelInfo = info;
-    }
-
-    @Override
-    public void setTargetNodeComponent(TargetNodeComponent node) {
-        // Do nothing
-    }
-
-    public void setBufferType (BufferType bufferType) {
-        fChannelInfo.setBufferType(bufferType);
-    }
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.ui.tests/stubs/org/eclipse/tracecompass/internal/lttng2/control/stubs/dialogs/EnableEventsDialogStub.java b/org.eclipse.tracecompass.lttng2.control.ui.tests/stubs/org/eclipse/tracecompass/internal/lttng2/control/stubs/dialogs/EnableEventsDialogStub.java
deleted file mode 100644 (file)
index 0e3e9e7..0000000
+++ /dev/null
@@ -1,234 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.LogLevelType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.IEnableEventsDialog;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceProviderGroup;
-
-/**
- * Enable events dialog stub implementation.
- */
-@SuppressWarnings("javadoc")
-public class EnableEventsDialogStub implements IEnableEventsDialog {
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-    private boolean fIsKernel;
-    private boolean fIsTracePoints;
-    private boolean fIsAllTracePoints;
-    private boolean fIsSysCalls;
-    private boolean fIsDynamicProbe;
-    private String fProbeEventName;
-    private String fDynamicProbe;
-    private boolean fIsFunctionProbe;
-    private String fFunctionEventName;
-    private String fFunctionProbe;
-    private boolean fIsWildcard;
-    private String fWildcard;
-    private boolean fIsLogLevel;
-    private String fLogLevelEventName;
-    private TraceLogLevel fLogLevel;
-    private LogLevelType fLogLevelType;
-    private String fFilter;
-    private List<String> fNames = new ArrayList<>();
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-    public void setIsKernel(boolean isKernel) {
-        fIsKernel = isKernel;
-    }
-
-    public void setIsTracePoints(boolean isTracePoints) {
-        fIsTracePoints = isTracePoints;
-    }
-
-    public void setIsAllTracePoints(boolean isAllTracePoints) {
-        fIsAllTracePoints = isAllTracePoints;
-    }
-
-    public void setIsSysCalls(boolean isSysCalls) {
-        this.fIsSysCalls = isSysCalls;
-    }
-
-    public void setIsDynamicProbe(boolean isDynamicProbe) {
-        fIsDynamicProbe = isDynamicProbe;
-    }
-
-    public void setProbeEventName(String probeEventName) {
-        fProbeEventName = probeEventName;
-    }
-
-    public void setDynamicProbe(String dynamicProbe) {
-        fDynamicProbe = dynamicProbe;
-    }
-
-    public void setIsFunctionProbe(boolean isFunctionProbe) {
-        fIsFunctionProbe = isFunctionProbe;
-    }
-
-    public void setFunctionEventName(String functionEventName) {
-        fFunctionEventName = functionEventName;
-    }
-
-    public void setFunctionProbe(String functionProbe) {
-        fFunctionProbe = functionProbe;
-    }
-
-    public void setIsWildcard(boolean isWildcard) {
-        fIsWildcard = isWildcard;
-    }
-
-    public void setWildcard(String wildcard) {
-        fWildcard = wildcard;
-    }
-
-    public void setIsLogLevel(boolean isLogLevel) {
-        fIsLogLevel = isLogLevel;
-    }
-
-    public void setLogLevelEventName(String logLevelEventName) {
-        fLogLevelEventName = logLevelEventName;
-    }
-
-    public void setLogLevel(TraceLogLevel logLevel) {
-        fLogLevel = logLevel;
-    }
-
-    public void setLogLevelType(LogLevelType logLevelType) {
-        fLogLevelType = logLevelType;
-    }
-
-    public void setNames(List<String> names) {
-        fNames = names;
-    }
-
-    public void setFilterExpression(String filter) {
-        fFilter = filter;
-    }
-
-    @Override
-    public boolean isTracepoints() {
-        return fIsTracePoints;
-    }
-
-    @Override
-    public boolean isAllTracePoints() {
-        return fIsAllTracePoints;
-    }
-
-    @Override
-    public boolean isSysCalls() {
-        return fIsSysCalls;
-    }
-
-    @Override
-    public boolean isAllSysCalls() {
-        return fIsSysCalls;
-    }
-
-    @Override
-    public List<String> getEventNames() {
-        return fNames;
-    }
-
-    @Override
-    public boolean isDynamicProbe() {
-        return fIsDynamicProbe;
-    }
-
-    @Override
-    public String getProbeEventName() {
-        return fProbeEventName;
-    }
-
-    @Override
-    public String getProbeName() {
-        return fDynamicProbe;
-    }
-
-    @Override
-    public boolean isDynamicFunctionProbe() {
-        return fIsFunctionProbe;
-    }
-
-    @Override
-    public String getFunctionEventName() {
-        return fFunctionEventName;
-    }
-
-    @Override
-    public String getFunction() {
-        return fFunctionProbe;
-    }
-
-    @Override
-    public boolean isWildcard() {
-        return fIsWildcard;
-    }
-
-    @Override
-    public String getWildcard() {
-        return fWildcard;
-    }
-
-    @Override
-    public boolean isLogLevel() {
-        return fIsLogLevel;
-    }
-
-    @Override
-    public LogLevelType getLogLevelType() {
-        return fLogLevelType;
-    }
-
-    @Override
-    public TraceLogLevel getLogLevel() {
-        return fLogLevel;
-    }
-
-    @Override
-    public String getLogLevelEventName() {
-        return fLogLevelEventName;
-    }
-
-    @Override
-    public boolean isKernel() {
-        return fIsKernel;
-    }
-
-    @Override
-    public void setTraceProviderGroup(TraceProviderGroup providerGroup) {
-    }
-
-    @Override
-    public void setTraceDomainComponent(TraceDomainComponent domain) {
-    }
-
-    @Override
-    public int open() {
-        return 0;
-    }
-
-    @Override
-    public String getFilterExpression() {
-        return fFilter;
-    }
-
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.ui.tests/stubs/org/eclipse/tracecompass/internal/lttng2/control/stubs/dialogs/GetEventInfoDialogStub.java b/org.eclipse.tracecompass.lttng2.control.ui.tests/stubs/org/eclipse/tracecompass/internal/lttng2/control/stubs/dialogs/GetEventInfoDialogStub.java
deleted file mode 100644 (file)
index c08978e..0000000
+++ /dev/null
@@ -1,68 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs;
-
-import java.util.Arrays;
-
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.IGetEventInfoDialog;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
-
-/**
- * Get event information dialog stub implementation.
- */
-public class GetEventInfoDialogStub implements IGetEventInfoDialog {
-
-    private TraceSessionComponent[] fSessions;
-    private String fFilterExpression;
-
-    @Override
-    public TraceSessionComponent getSession() {
-        return fSessions[0];
-    }
-
-    @Override
-    public TraceChannelComponent getChannel() {
-        return null;
-    }
-
-    @Override
-    public void setIsKernel(boolean isKernel) {
-    }
-
-    @Override
-    public void setSessions(TraceSessionComponent[] sessions) {
-        if (sessions != null) {
-            fSessions = Arrays.copyOf(sessions, sessions.length);
-            return;
-        }
-        fSessions = null;
-    }
-
-    @Override
-    public String getFilterExpression() {
-        return fFilterExpression;
-    }
-
-    @Override
-    public int open() {
-        return 0;
-    }
-
-    /**
-     * @param filter the filter to set
-     */
-    public void setFilterExpression(String filter) {
-        fFilterExpression = filter;
-    }
-}
-
diff --git a/org.eclipse.tracecompass.lttng2.control.ui.tests/stubs/org/eclipse/tracecompass/internal/lttng2/control/stubs/service/TestRemoteSystemProxy.java b/org.eclipse.tracecompass.lttng2.control.ui.tests/stubs/org/eclipse/tracecompass/internal/lttng2/control/stubs/service/TestRemoteSystemProxy.java
deleted file mode 100644 (file)
index 4b7c501..0000000
+++ /dev/null
@@ -1,78 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2015 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Markus Schorn - Bug 448058: Use org.eclipse.remote in favor of RSE
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.stubs.service;
-
-import static org.eclipse.tracecompass.common.core.NonNullUtils.checkNotNull;
-
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.remote.core.IRemoteConnection;
-import org.eclipse.tracecompass.internal.lttng2.control.stubs.shells.LTTngToolsFileShell;
-import org.eclipse.tracecompass.tmf.remote.core.proxy.RemoteSystemProxy;
-import org.eclipse.tracecompass.tmf.remote.core.shell.ICommandShell;
-
-@SuppressWarnings("javadoc")
-public class TestRemoteSystemProxy extends RemoteSystemProxy {
-
-    public TestRemoteSystemProxy(IRemoteConnection host) {
-        super(checkNotNull(host));
-    }
-
-    private LTTngToolsFileShell fShell = null;
-    private String fTestFile = null;
-    private String fScenario = null;
-
-    @Override
-    public void connect(IProgressMonitor monitor) throws ExecutionException {
-    }
-
-    @Override
-    public void disconnect() {
-        fShell = null;
-    }
-
-    @Override
-    public void dispose() {
-    }
-
-    @Override
-    public ICommandShell createCommandShell() {
-        LTTngToolsFileShell shell = fShell;
-        if (shell == null) {
-            shell = new LTTngToolsFileShell();
-            if ((fTestFile != null) && (fScenario != null)) {
-                shell.loadScenarioFile(fTestFile);
-                shell.setScenario(fScenario);
-                fShell = shell;
-            }
-            fShell = shell;
-        }
-        return shell;
-    }
-
-    public void setTestFile(String testFile) {
-        fTestFile = testFile;
-    }
-
-    public void setScenario(String scenario) {
-        fScenario = scenario;
-        if (fShell != null) {
-            fShell.setScenario(fScenario);
-        }
-    }
-
-    @Override
-    public boolean isConnected() {
-        return true;
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui.tests/stubs/org/eclipse/tracecompass/internal/lttng2/control/stubs/shells/LTTngToolsFileShell.java b/org.eclipse.tracecompass.lttng2.control.ui.tests/stubs/org/eclipse/tracecompass/internal/lttng2/control/stubs/shells/LTTngToolsFileShell.java
deleted file mode 100644 (file)
index 5d6bf94..0000000
+++ /dev/null
@@ -1,286 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2015 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Markus Schorn - Bug 448058: Use org.eclipse.remote in favor of RSE
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.stubs.shells;
-
-import static org.eclipse.tracecompass.common.core.NonNullUtils.checkNotNull;
-
-import java.io.BufferedReader;
-import java.io.DataInputStream;
-import java.io.FileInputStream;
-import java.io.IOException;
-import java.io.InputStreamReader;
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.HashMap;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Map;
-import java.util.regex.Matcher;
-import java.util.regex.Pattern;
-
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.tracecompass.internal.tmf.remote.core.stubs.shells.TestCommandShell;
-import org.eclipse.tracecompass.tmf.remote.core.shell.ICommandInput;
-import org.eclipse.tracecompass.tmf.remote.core.shell.ICommandResult;
-
-@SuppressWarnings("javadoc")
-public class LTTngToolsFileShell extends TestCommandShell {
-
-    // ------------------------------------------------------------------------
-    // CONSTANTS
-    // ------------------------------------------------------------------------
-    private final static String SCENARIO_KEY = "<SCENARIO>";
-    private final static String SCENARIO_END_KEY = "</SCENARIO>";
-    private final static String INPUT_KEY = "<COMMAND_INPUT>";
-    private final static String INPUT_END_KEY = "</COMMAND_INPUT>";
-    private final static String RESULT_KEY = "<COMMAND_RESULT>";
-    private final static String OUTPUT_KEY = "<COMMAND_OUTPUT>";
-    private final static String OUTPUT_END_KEY = "</COMMAND_OUTPUT>";
-    private final static String ERROR_OUTPUT_KEY = "<COMMAND_ERROR_OUTPUT>";
-    private final static String ERROR_OUTPUT_END_KEY = "</COMMAND_ERROR_OUTPUT>";
-    private final static String COMMENT_KEY = "#.*";
-
-    private final static Pattern LTTNG_LIST_SESSION_PATTERN = Pattern.compile("lttng\\s+list\\s+(.+)");
-    private final static String LTTNG_LIST_PROVIDER_PATTERN = "lttng\\s+list\\s+(-u|-k)";
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-    private String fScenariofile;
-    private String fScenario;
-
-    private final Map<String, Map<String, ICommandResult>> fScenarioMap = new HashMap<>();
-    private final Map<String, Integer> fSessionNameMap = new HashMap<>();
-
-    /**
-     * Parse a scenario file with the format:
-     *
-     * <pre>
-     * &lt;SCENARIO&gt;
-     * ScenarioName
-     *
-     * &lt;COMMAND_INPUT&gt;
-     * Command
-     * &lt;/COMMAND_INPUT&gt;
-     *
-     * &lt;COMMAND_RESULT&gt;
-     * CommandResult
-     * &lt;/COMMAND_RESULT&gt;
-     *
-     * &lt;COMMAND_OUTPUT&gt;
-     * CommandOutput
-     * &lt;COMMAND_ERROR_OUTPUT&gt;
-     * CommandErrorOutput
-     * &lt;/COMMAND_ERROR_OUTPUT&gt;
-     * &lt;/COMMAND_OUTPUT&gt;
-     *
-     * &lt;/SCENARIO&gt;
-     *
-     * Where: ScenarioName - is the scenario name
-     *        Command - the command line string
-     *        CommandResult - the result integer of the command (0 for success, 1 for failure)
-     *        CommandOutput - the command output string (multi-line possible)
-     *        CommandErrorOutput - the command error output string (multi-line possible)
-     *
-     * Note: 1) There can be many scenarios per file
-     *       2) There can be many (Command-CommandResult-CommandOutput) triples per scenario
-     * 3) Lines starting with # will be ignored (comments)
-     *
-     * <pre>
-     * @param scenariofile - path to scenario file
-     */
-    public synchronized void loadScenarioFile(String scenariofile) {
-        fScenariofile = scenariofile;
-
-        // clean up map
-        Collection<Map<String, ICommandResult>> values = fScenarioMap.values();
-        for (Iterator<Map<String, ICommandResult>> iterator = values.iterator(); iterator.hasNext();) {
-            Map<String, ICommandResult> map = iterator.next();
-            map.clear();
-        }
-        fScenarioMap.clear();
-
-        // load from file
-
-        // Open the file
-        try (FileInputStream fstream = new FileInputStream(fScenariofile);
-                DataInputStream in = new DataInputStream(fstream);
-                BufferedReader br = new BufferedReader(new InputStreamReader(in));) {
-            String strLine;
-
-            // Read File Line by Line
-
-            // Temporary map for generating instance numbers for lttng list
-            // <session> commands.
-            // The numbers are per scenario.
-            Map<String, Integer> tmpSessionNameMap = new HashMap<>();
-            while ((strLine = br.readLine()) != null) {
-
-                // Ignore comments
-                if (isComment(strLine)) {
-                    continue;
-                }
-
-                if (SCENARIO_KEY.equals(strLine)) {
-                    // scenario start
-
-                    // Ignore comments
-                    strLine = br.readLine();
-                    while (isComment(strLine)) {
-                        strLine = br.readLine();
-                    }
-
-                    String scenario = strLine;
-                    Map<String, ICommandResult> commandMap = new HashMap<>();
-                    fScenarioMap.put(scenario, commandMap);
-                    List<String> output = null;
-                    List<String> errorOutput = null;
-                    String input = null;
-                    boolean inOutput = false;
-                    boolean inErrorOutput = false;
-                    int result = 0;
-                    tmpSessionNameMap.clear();
-                    while ((strLine = br.readLine()) != null) {
-                        // Ignore comments
-                        if (isComment(strLine)) {
-                            continue;
-                        }
-
-                        if (SCENARIO_END_KEY.equals(strLine)) {
-                            // Scenario is finished
-                            break;
-                        }
-                        if (INPUT_KEY.equals(strLine)) {
-                            strLine = br.readLine();
-                            // Ignore comments
-                            while (isComment(strLine)) {
-                                strLine = br.readLine();
-                            }
-                            // Read command
-                            input = strLine;
-
-                            // Handle instances of 'lttng list
-                            // <session"-command
-                            Matcher matcher = LTTNG_LIST_SESSION_PATTERN.matcher(strLine);
-                            if (matcher.matches() && !input.matches(LTTNG_LIST_PROVIDER_PATTERN)) {
-                                String sessionName = matcher.group(1).trim();
-                                Integer i = tmpSessionNameMap.get(sessionName);
-                                if (i != null) {
-                                    i++;
-                                } else {
-                                    i = 0;
-                                }
-                                tmpSessionNameMap.put(sessionName, i);
-                                input += String.valueOf(i);
-                            }
-                        } else if (INPUT_END_KEY.equals(strLine)) {
-                            // Initialize output array
-                            output = new ArrayList<>();
-                            errorOutput = new ArrayList<>();
-                        } else if (RESULT_KEY.equals(strLine)) {
-                            strLine = br.readLine();
-                            // Ignore comments
-                            while (isComment(strLine)) {
-                                strLine = br.readLine();
-                            }
-                            // Save result value
-                            result = Integer.parseInt(strLine);
-                        } else if (OUTPUT_END_KEY.equals(strLine)) {
-                            // Save output/result in command map
-                            if (output != null && errorOutput != null) {
-                                commandMap.put(input, createCommandResult(result,
-                                        checkNotNull(output.toArray(new String[output.size()])),
-                                        checkNotNull(errorOutput.toArray(new String[errorOutput.size()]))));
-                            }
-                            inOutput = false;
-                        } else if (OUTPUT_KEY.equals(strLine)) {
-                            // first line of output
-                            inOutput = true;
-                        } else if (ERROR_OUTPUT_KEY.equals(strLine)) {
-                            // first line of output
-                            inErrorOutput = true;
-                        } else if (ERROR_OUTPUT_END_KEY.equals(strLine)) {
-                            inErrorOutput = false;
-                        } else if (inOutput) {
-                            while (isComment(strLine)) {
-                                strLine = br.readLine();
-                            }
-                            // lines of output/error output
-                            if (errorOutput != null && inErrorOutput) {
-                                errorOutput.add(strLine);
-                            } else if (output != null) {
-                                output.add(strLine);
-                            }
-                        }
-                        // else {
-                        // if (RESULT_END_KEY.equals(strLine)) {
-                        // nothing to do
-                        // }
-                    }
-                }
-            }
-        } catch (IOException e) {
-            e.printStackTrace();
-        }
-    }
-
-    // Set the scenario to consider in executeCommand()
-    public synchronized void setScenario(String scenario) {
-        fScenario = scenario;
-        fSessionNameMap.clear();
-        if (!fScenarioMap.containsKey(fScenario)) {
-            throw new IllegalArgumentException();
-        }
-    }
-
-    @Override
-    public synchronized ICommandResult executeCommand(ICommandInput command, IProgressMonitor monitor) throws ExecutionException {
-        Map<String, ICommandResult> commands = fScenarioMap.get(fScenario);
-        String commandLine = command.toString();
-        String fullCommand = commandLine;
-
-        Matcher matcher = LTTNG_LIST_SESSION_PATTERN.matcher(commandLine);
-        if (matcher.matches() && !commandLine.matches(LTTNG_LIST_PROVIDER_PATTERN)) {
-            String sessionName = matcher.group(1).trim();
-            Integer i = fSessionNameMap.get(sessionName);
-            if (i != null) {
-                i++;
-            } else {
-                i = 0;
-            }
-            fSessionNameMap.put(sessionName, i);
-            fullCommand += String.valueOf(i);
-        }
-
-        if (commands.containsKey(fullCommand)) {
-            return checkNotNull(commands.get(fullCommand));
-        }
-
-        String[] output = new String[1];
-        output[0] = String.valueOf("Command not found");
-        ICommandResult result = createCommandResult(1, output, output);
-        return result;
-    }
-
-    // ------------------------------------------------------------------------
-    // Helper methods
-    // ------------------------------------------------------------------------
-
-    private static boolean isComment(String line) {
-        if (line == null) {
-            throw new RuntimeException("line is null");
-        }
-        return line.matches(COMMENT_KEY);
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui.tests/testfiles/CreateSessionTest.cfg b/org.eclipse.tracecompass.lttng2.control.ui.tests/testfiles/CreateSessionTest.cfg
deleted file mode 100644 (file)
index 870b87a..0000000
+++ /dev/null
@@ -1,228 +0,0 @@
-####################################################################
-# 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:
-#    Bernd Hufmann - Initial API and implementation
-####################################################################
-####################################################################
-# Scenario: Initialize
-####################################################################
-<SCENARIO>
-Initialize
-<COMMAND_INPUT>
-lttng version
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-lttng version 2.0.0 - Annedd'ale
-Web site: http://lttng.org/
-
-lttng is free software and under the GPL license and part LGPL
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Currently no available tracing session
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list -k
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Kernel events
--------------
-      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint)
-      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint)
-      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint)
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list -u
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-UST events:
--------------
-
-PID: 9379 - Name: /home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello
-    ust_tests_hello:tptest_sighandler (loglevel: TRACE_WARNING (4)) (type: tracepoint)
-    ust_tests_hello:tptest (loglevel: TRACE_DEBUG_FUNCTION (12)) (type: tracepoint)
-
-PID: 4852 - Name: /home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello
-    ust_tests_hello:tptest_sighandler (loglevel: TRACE_WARNING (4)) (type: tracepoint)
-    ust_tests_hello:tptest (loglevel: TRACE_DEBUG_FUNCTION (12)) (type: tracepoint)
-
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test "lttng create <session> with LTTng 2.1 options
-####################################################################
-##################################################################
-<SCENARIO>
-CreateSessionFileProto
-<COMMAND_INPUT>
-lttng create mysession -U file:///tmp
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Session mysession created.
-Traces will be written in file:///tmp
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession: [inactive]
-    Trace path: file:///tmp
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng destroy mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Session mysession destroyed.
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-##################################################################
-<SCENARIO>
-CreateSessionControlData
-<COMMAND_INPUT>
-lttng create mysession -C tcp://172.0.0.1 -D tcp://172.0.0.1:5343
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Session mysession created.
-Control URL tcp://172.0.0.1 set for session mysession
-Data URL tcp://172.0.0.1:5343 set for session mysession
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession: [inactive]
-    Trace path: tcp://172.0.0.1:5342 [data: 5343]
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng destroy mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Session mysession destroyed.
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-##################################################################
-<SCENARIO>
-CreateSessionNetwork
-<COMMAND_INPUT>
-lttng create mysession -U net://172.0.0.1:1234:2345
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Session mysession created.
-Traces will be written in net://172.0.0.1:1234:2345
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession: [inactive]
-    Trace path: net://172.0.0.1:1234 [data: 2345]
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng destroy mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Session mysession2 destroyed.
-</COMMAND_OUTPUT>
-
-</SCENARIO>
-
-##################################################################
-<SCENARIO>
-CreateSessionNetwork2
-<COMMAND_INPUT>
-lttng create mysession -U net6://[ffff::eeee:dddd:cccc:0]
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Session mysession created.
-Traces will be written in net6://[ffff::eeee:dddd:cccc:0]
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession: [inactive]
-    Trace path:  net://[ffff::eeee:dddd:cccc:0]:5342/mysession-20130221-144451 [data: 5343]
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng destroy mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Session mysession2 destroyed.
-</COMMAND_OUTPUT>
-
-</SCENARIO>
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.ui.tests/testfiles/CreateSessionTest2.cfg b/org.eclipse.tracecompass.lttng2.control.ui.tests/testfiles/CreateSessionTest2.cfg
deleted file mode 100644 (file)
index a8bd262..0000000
+++ /dev/null
@@ -1,158 +0,0 @@
-####################################################################
-# Copyright (c) 2013 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:
-#    Bernd Hufmann - Initial API and implementation
-####################################################################
-####################################################################
-# Scenario: Initialize
-####################################################################
-<SCENARIO>
-Initialize
-<COMMAND_INPUT>
-lttng version
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-lttng version 2.3.0 - Dominus Vobiscum
-
-A very succulent line-up of beers brewed at Microbrasserie Charlevoix. Elaborated starting from special malts and fermented with a Belgian yeast. These beers are refermented in bottle and will make you discover the richness of wheat, amber and triple styles.
-
-Web site: http://lttng.org
-
-lttng is free software and under the GPL license and part LGPL
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Currently no available tracing session
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list -k
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Kernel events
--------------
-      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint)
-      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint)
-      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint)
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list -u -f
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-UST events:
--------------
-
-PID: 9379 - Name: /home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello
-    ust_tests_hello:tptest_sighandler (loglevel: TRACE_WARNING (4)) (type: tracepoint)
-    ust_tests_hello:tptest (loglevel: TRACE_DEBUG_FUNCTION (12)) (type: tracepoint)
-
-PID: 4852 - Name: /home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello
-    ust_tests_hello:tptest_sighandler (loglevel: TRACE_WARNING (4)) (type: tracepoint)
-    ust_tests_hello:tptest (loglevel: TRACE_DEBUG_FUNCTION (12)) (type: tracepoint)
-
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test "lttng create <session> --snapshot" LTTng 2.3
-####################################################################
-<SCENARIO>
-ScenCreateSession
-<COMMAND_INPUT>
-lttng create mysession --snapshot
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Session mysession created.
-Default snapshot output set to: /home/user/lttng-traces/mysession-20130913-141651
-Snapshot mode set. Every channel enabled for that session will be set in overwrite mode and mmap output.
-</COMMAND_OUTPUT>
-#------------------------------------------------------------------------------
-<COMMAND_INPUT>
-lttng list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession: [inactive snapshot]
-    Trace path:
-
-</COMMAND_OUTPUT>
-#------------------------------------------------------------------------------
-<COMMAND_INPUT>
-lttng snapshot list-output -s mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Snapshot output list for session mysession
-    [1] snapshot-1: /home/user/lttng-traces/mysession-20130913-141651
-</COMMAND_OUTPUT>
-#------------------------------------------------------------------------------
-<COMMAND_INPUT>
-lttng start mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing started for session mysession.
-</COMMAND_OUTPUT>
-#------------------------------------------------------------------------------
-<COMMAND_INPUT>
-lttng snapshot record -s mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-    Snapshot recorded successfully for session mysession
-</COMMAND_OUTPUT>
-#------------------------------------------------------------------------------
-<COMMAND_INPUT>
-lttng stop mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing stopped for session mysession.
-</COMMAND_OUTPUT>
-#------------------------------------------------------------------------------
-<COMMAND_INPUT>
-lttng destroy mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Session mysession destroyed.
-</COMMAND_OUTPUT>
-</SCENARIO>
diff --git a/org.eclipse.tracecompass.lttng2.control.ui.tests/testfiles/CreateSessionTestMi.cfg b/org.eclipse.tracecompass.lttng2.control.ui.tests/testfiles/CreateSessionTestMi.cfg
deleted file mode 100644 (file)
index 330f25a..0000000
+++ /dev/null
@@ -1,528 +0,0 @@
-####################################################################
-# Copyright (c) 2014 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:
-#    Jonathan Rajotte - Initial API and implementation
-####################################################################
-####################################################################
-# Scenario: Initialize
-####################################################################
-<SCENARIO>
-Initialize
-<COMMAND_INPUT>
-lttng --mi xml version
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>version</name>
-  <output>
-    <version>
-      <string>2.6.0</string>
-      <major>2</major>
-      <minor>6</minor>
-      <commit></commit>
-      <patchLevel>0</patchLevel>
-      <name>TestMI</name>
-      <description>Lorem ipsum</description>
-      <url>http://lttng.org</url>
-      <license>lttng is free software and under the GPL license and part LGPL</license>
-    </version>
-  </output>
-</command>
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng --mi xml list
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>list</name>
-  <output>
-    <sessions/>
-  </output>
-</command>
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng --mi xml list -k
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>list</name>
-  <output>
-    <domains>
-      <domain>
-        <type>KERNEL</type>
-        <buffer_type>PER_PID</buffer_type>
-        <events>
-          <event>
-            <name>sched_kthread_stop</name>
-            <type>TRACEPOINT</type>
-            <enabled>true</enabled>
-            <filter>false</filter>
-            <loglevel>TRACE_EMERG</loglevel>
-            <loglevel_type>ALL</loglevel_type>
-            <exclusion>false</exclusion>
-          </event>
-          <event>
-            <name>sched_kthread_stop_ret</name>
-            <type>TRACEPOINT</type>
-            <enabled>true</enabled>
-            <filter>false</filter>
-            <loglevel>TRACE_EMERG</loglevel>
-            <loglevel_type>ALL</loglevel_type>
-            <exclusion>false</exclusion>
-          </event>
-          <event>
-            <name>sched_wakeup_new</name>
-            <type>TRACEPOINT</type>
-            <enabled>true</enabled>
-            <filter>false</filter>
-            <loglevel>TRACE_EMERG</loglevel>
-            <loglevel_type>ALL</loglevel_type>
-            <exclusion>false</exclusion>
-          </event>
-        </events>
-      </domain>
-    </domains>
-  </output>
-</command>
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng --mi xml list -u -f
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>list</name>
-  <output>
-    <domains>
-      <domain>
-        <type>UST</type>
-        <buffer_type>PER_PID</buffer_type>
-        <pids>
-          <pid>
-            <id>9379</id>
-            <name>/home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello</name>
-            <events>
-              <event>
-                <name>ust_tests_hello:tptest_sighandler</name>
-                <type>TRACEPOINT</type>
-                <enabled>true</enabled>
-                <filter>false</filter>
-                <loglevel>TRACE_DEBUG_MODULE</loglevel>
-                <loglevel_type>ALL</loglevel_type>
-                <exclusion>false</exclusion>
-                <event_fields/>
-              </event>
-              <event>
-                <name>ust_tests_hello:tptest</name>
-                <type>TRACEPOINT</type>
-                <enabled>true</enabled>
-                <filter>false</filter>
-                <loglevel>TRACE_INFO</loglevel>
-                <loglevel_type>ALL</loglevel_type>
-                <exclusion>false</exclusion>
-                <event_fields>
-                  <event_field>
-                    <name>doublefield</name>
-                    <type>FLOAT</type>
-                    <nowrite>0</nowrite>
-                  </event_field>
-                  <event_field>
-                    <name>floatfield</name>
-                    <type>FLOAT</type>
-                    <nowrite>0</nowrite>
-                  </event_field>
-                  <event_field>
-                    <name>stringfield</name>
-                    <type>STRING</type>
-                    <nowrite>0</nowrite>
-                  </event_field>
-                </event_fields>
-              </event>
-            </events>
-          </pid>
-          <pid>
-            <id>4852</id>
-            <name>/home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello</name>
-            <events>
-              <event>
-                <name>ust_tests_hello:tptest_sighandler</name>
-                <type>TRACEPOINT</type>
-                <enabled>true</enabled>
-                <filter>false</filter>
-                <loglevel>TRACE_WARNING</loglevel>
-                <loglevel_type>ALL</loglevel_type>
-                <exclusion>false</exclusion>
-                <event_fields/>
-              </event>
-              <event>
-                <name>ust_tests_hello:tptest</name>
-                <type>TRACEPOINT</type>
-                <enabled>true</enabled>
-                <filter>false</filter>
-                <loglevel>TRACE_DEBUG_FUNCTION</loglevel>
-                <loglevel_type>ALL</loglevel_type>
-                <exclusion>false</exclusion>
-                <event_fields>
-                  <event_field>
-                    <name>doublefield</name>
-                    <type>FLOAT</type>
-                    <nowrite>0</nowrite>
-                  </event_field>
-                  <event_field>
-                    <name>floatfield</name>
-                    <type>FLOAT</type>
-                    <nowrite>0</nowrite>
-                  </event_field>
-                  <event_field>
-                    <name>stringfield</name>
-                    <type>STRING</type>
-                    <nowrite>0</nowrite>
-                  </event_field>
-                </event_fields>
-              </event>
-            </events>
-          </pid>
-        </pids>
-      </domain>
-    </domains>
-  </output>
-</command>
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test "lttng create <session> with LTTng 2.1 options
-####################################################################
-##################################################################
-<SCENARIO>
-CreateSessionFileProto
-<COMMAND_INPUT>
-lttng --mi xml create mysession -U file:///tmp
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>create</name>
-  <output>
-    <session>
-      <name>mysession</name>
-      <path>/tmp</path>
-      <enabled>false</enabled>
-      <snapshot_mode>0</snapshot_mode>
-      <live_timer_interval>0</live_timer_interval>
-    </session>
-  </output>
-  <success>true</success>
-</command>
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng --mi xml list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>list</name>
-  <output>
-    <sessions>
-      <session>
-        <name>mysession</name>
-        <path>/tmp</path>
-        <enabled>false</enabled>
-        <snapshot_mode>0</snapshot_mode>
-        <live_timer_interval>0</live_timer_interval>
-        <domains/>
-      </session>
-    </sessions>
-  </output>
-</command>
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng --mi xml destroy mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>destroy</name>
-  <output>
-    <sessions>
-      <session>
-        <name>mysession</name>
-        <path>/tmp</path>
-        <enabled>false</enabled>
-        <snapshot_mode>0</snapshot_mode>
-        <live_timer_interval>0</live_timer_interval>
-      </session>
-    </sessions>
-  </output>
-  <success>true</success>
-</command>
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-##################################################################
-<SCENARIO>
-CreateSessionControlData
-<COMMAND_INPUT>
-lttng --mi xml create mysession -C tcp://172.0.0.1 -D tcp://172.0.0.1:5343
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>create</name>
-  <output>
-    <session>
-      <name>mysession</name>
-      <path>tcp4://172.0.0.1:5342/ [data: 5343]</path>
-      <enabled>false</enabled>
-      <snapshot_mode>0</snapshot_mode>
-      <live_timer_interval>0</live_timer_interval>
-    </session>
-  </output>
-  <success>true</success>
-</command>
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng --mi xml list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>list</name>
-  <output>
-    <sessions>
-      <session>
-        <name>mysession</name>
-        <path>tcp4://172.0.0.1:5342/ [data: 5343]</path>
-        <enabled>false</enabled>
-        <snapshot_mode>0</snapshot_mode>
-        <live_timer_interval>0</live_timer_interval>
-        <domains/>
-      </session>
-    </sessions>
-  </output>
-</command>
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng --mi xml destroy mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>destroy</name>
-  <output>
-    <sessions>
-      <session>
-        <name>mysession</name>
-        <path>tcp4://172.0.0.1:5342/ [data: 5343]</path>
-        <enabled>false</enabled>
-        <snapshot_mode>0</snapshot_mode>
-        <live_timer_interval>0</live_timer_interval>
-      </session>
-    </sessions>
-  </output>
-  <success>true</success>
-</command>
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-##################################################################
-<SCENARIO>
-CreateSessionNetwork
-<COMMAND_INPUT>
-lttng --mi xml create mysession -U net://172.0.0.1:1234:2345
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>create</name>
-  <output>
-    <session>
-      <name>mysession</name>
-      <path>tcp4://172.0.0.1:1234/mysession-20140820-153527 [data: 2345]</path>
-      <enabled>false</enabled>
-      <snapshot_mode>0</snapshot_mode>
-      <live_timer_interval>0</live_timer_interval>
-    </session>
-  </output>
-  <success>true</success>
-</command>
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng --mi xml list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>list</name>
-  <output>
-    <sessions>
-      <session>
-        <name>mysession</name>
-        <path>tcp4://172.0.0.1:1234/mysession-20140820-153527 [data: 2345]</path>
-        <enabled>false</enabled>
-        <snapshot_mode>0</snapshot_mode>
-        <live_timer_interval>0</live_timer_interval>
-        <domains/>
-      </session>
-    </sessions>
-  </output>
-</command>
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng --mi xml destroy mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>destroy</name>
-  <output>
-    <sessions>
-      <session>
-        <name>mysession</name>
-        <path>tcp4://172.0.0.1:1234/mysession-20140820-153527 [data: 2345]</path>
-        <enabled>false</enabled>
-        <snapshot_mode>0</snapshot_mode>
-        <live_timer_interval>0</live_timer_interval>
-      </session>
-    </sessions>
-  </output>
-  <success>true</success>
-</command>
-</COMMAND_OUTPUT>
-
-</SCENARIO>
-
-##################################################################
-<SCENARIO>
-CreateSessionNetwork2
-<COMMAND_INPUT>
-lttng --mi xml create mysession -U net6://[ffff::eeee:dddd:cccc:0]
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>create</name>
-  <output>
-    <session>
-      <name>mysession</name>
-      <path>tcp6://[ffff::eeee:dddd:cccc:0]:5342/mysession-20140820-153801 [data: 5343]</path>
-      <enabled>false</enabled>
-      <snapshot_mode>0</snapshot_mode>
-      <live_timer_interval>0</live_timer_interval>
-    </session>
-  </output>
-  <success>true</success>
-</command>
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng --mi xml list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>list</name>
-  <output>
-    <sessions>
-      <session>
-        <name>mysession</name>
-        <path>tcp6://[ffff::eeee:dddd:cccc:0]:5342/mysession-20140820-153801 [data: 5343]</path>
-        <enabled>false</enabled>
-        <snapshot_mode>0</snapshot_mode>
-        <live_timer_interval>0</live_timer_interval>
-        <domains/>
-      </session>
-    </sessions>
-  </output>
-</command>
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng --mi xml destroy mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>destroy</name>
-  <output>
-    <sessions>
-      <session>
-        <name>mysession</name>
-        <path>tcp6://[ffff::eeee:dddd:cccc:0]:5342/mysession-20140820-153801 [data: 5343]</path>
-        <enabled>false</enabled>
-        <snapshot_mode>0</snapshot_mode>
-        <live_timer_interval>0</live_timer_interval>
-      </session>
-    </sessions>
-  </output>
-  <success>true</success>
-</command>
-</COMMAND_OUTPUT>
-
-</SCENARIO>
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.ui.tests/testfiles/CreateTreeTest.cfg b/org.eclipse.tracecompass.lttng2.control.ui.tests/testfiles/CreateTreeTest.cfg
deleted file mode 100644 (file)
index 056077c..0000000
+++ /dev/null
@@ -1,2676 +0,0 @@
-####################################################################
-# Copyright (c) 2012, 2014 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:
-#    Bernd Hufmann - Initial API and implementation
-####################################################################
-####################################################################
-# Scenario: Initialize
-####################################################################
-<SCENARIO>
-Initialize
-<COMMAND_INPUT>
-lttng version
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-lttng version 2.0.0 - Annedd'ale
-Web site: http://lttng.org/
-
-lttng is free software and under the GPL license and part LGPL
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Currently no available tracing session
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list -k
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Kernel events
--------------
-      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint)
-      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint)
-      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint)
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list -u
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-UST events:
--------------
-
-PID: 9379 - Name: /home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello
-    ust_tests_hello:tptest_sighandler (loglevel: TRACE_WARNING (4)) (type: tracepoint)
-    ust_tests_hello:tptest (loglevel: TRACE_DEBUG_FUNCTION (12)) (type: tracepoint)
-
-PID: 4852 - Name: /home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello
-    ust_tests_hello:tptest_sighandler (loglevel: TRACE_WARNING (4)) (type: tracepoint)
-    ust_tests_hello:tptest (loglevel: TRACE_DEBUG_FUNCTION (12)) (type: tracepoint)
-
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Create and destroy session
-####################################################################
-<SCENARIO>
-SessionHandling
-<SCENARIO>
-<COMMAND_INPUT>
-lttng create mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Session mysession created.
-Traces will be written in /home/user/lttng-traces/mysession-20120314-132824
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession: [inactive]
-    Trace path: /home/user/lttng-traces/mysession-20120314-132824
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng destroy mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Session mysession destroyed.
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng start mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing started for session mysession.
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng stop mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing stopped for session mysession.
-</COMMAND_OUTPUT>
-
-</SCENARIO>
-
-####################################################################
-# Scenario: Create and destroy session
-####################################################################
-<SCENARIO>
-SessionHandlingWithPath
-<SCENARIO>
-<COMMAND_INPUT>
-lttng create mysession -o /home/user/temp
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Session mysession created.
-Traces will be written in /home/user/temp
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession: [inactive]
-    Trace path: /home/user/temp
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng destroy mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Session mysession destroyed.
-</COMMAND_OUTPUT>
-
-</SCENARIO>
-
-
-####################################################################
-# Scenario: Enable events from kernel provider events
-####################################################################
-<SCENARIO>
-Scenario1
-
-
-<COMMAND_INPUT>
-lttng enable-event sched_kthread_stop,sched_kthread_stop_ret -k -s mysession --tracepoint
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-kernel event sched_kthread_stop created in channel channel0
-kernel sched_kthread_stop_ret created in channel channel0
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession: [inactive]
-    Trace path: /home/user/lttng-traces/mysession-20120314-132824
-
-=== Domain: Kernel ===
-
-Channels:
--------------
-- channel0: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 262144
-      number of subbufers: 4
-      switch timer interval: 0
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng disable-event sched_kthread_stop_ret,sched_kthread_stop -k -s mysession -c channel0
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-kernel event sched_kthread_stop_ret disabled in channel channel0
-kernel event sched_kthread_stop disabled in channel channel0
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng enable-event sched_kthread_stop -k -s mysession -c channel0 --tracepoint
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-kernel event sched_kthread_stop enabled in channel channel0
-</COMMAND_OUTPUT>
-
-</SCENARIO>
-
-####################################################################
-# Scenario: Enable events from UST provider events
-####################################################################
-<SCENARIO>
-Scenario2
-
-<COMMAND_INPUT>
-lttng enable-channel mychannel -u -s mysession --subbuf-size 16384 --num-subbuf 2 --switch-timer 200 --read-timer 100
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-UST channel mychannel enabled for session mysession
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession: [inactive]
-    Trace path: /home/user/temp
-
-=== Domain: UST global ===
-
-Channels:
--------------
-- mychannel: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 16384
-      number of subbufers: 2
-      switch timer interval: 200
-      read timer interval: 100
-      output: mmap()
-
-    Events:
-      None
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng enable-event ust_tests_hello:tptest_sighandler,ust_tests_hello:tptest -u -s mysession --tracepoint
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-UST event ust_tests_hello:tptest_sighandler in channel channel0
-UST sched_ust_tests_hello:tptest created in channel channel0
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession: [inactive]
-    Trace path: /home/user/temp
-
-=== Domain: UST global ===
-
-Channels:
--------------
-- mychannel: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 16384
-      number of subbufers: 2
-      switch timer interval: 200
-      read timer interval: 100
-      output: mmap()
-
-    Events:
-      ust_tests_hello:tptest_sighandler (type: tracepoint) [enabled]
-      ust_tests_hello:tptest (type: tracepoint) [enabled]
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng disable-event ust_tests_hello:tptest -u -s mysession -c mychannel
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-kernel event ust_tests_hello:tptest in channel mychannel
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng enable-event ust_tests_hello:tptest -u -s mysession -c mychannel --tracepoint
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-kernel event ust_tests_hello:tptest enabled in channel mychannel
-</COMMAND_OUTPUT>
-
-</SCENARIO>
-
-<SCENARIO>
-Scenario3
-
-<COMMAND_INPUT>
-lttng enable-channel mychannel -k -s mysession --overwrite --subbuf-size 16384 --num-subbuf 4 --switch-timer 100 --read-timer 200
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Kernel channel mychannel enabled for session mysession
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession: [inactive]
-    Trace path: /home/user/lttng-traces/mysession-20120314-132824
-
-=== Domain: Kernel ===
-
-Channels:
--------------
-- mychannel: [enabled]
-
-    Attributes:
-      overwrite mode: 1
-      subbufers size: 16384
-      number of subbufers: 4
-      switch timer interval: 100
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      None
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng enable-channel mychannel2 -k -s mysession --subbuf-size 32768 --num-subbuf 2 --switch-timer 100 --read-timer 200
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Kernel channel mychannel2 enabled for session mysession
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession: [inactive]
-    Trace path: /home/user/lttng-traces/mysession-20120314-132824
-
-=== Domain: Kernel ===
-
-Channels:
--------------
-- mychannel: [enabled]
-
-    Attributes:
-      overwrite mode: 1
-      subbufers size: 16384
-      number of subbufers: 4
-      switch timer interval: 100
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      None
-
-- mychannel2: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 32768
-      number of subbufers: 2
-      switch timer interval: 100
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      None
-
-</COMMAND_OUTPUT>
-
-
-<COMMAND_INPUT>
-lttng disable-channel mychannel,mychannel2 -k -s mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Kernel channel mychannel disabled for session mysession
-Kernel channel mychannel2 disabled for session mysession
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng enable-channel mychannel,mychannel2 -k -s mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Kernel channel mychannel enabled for session mysession
-Kernel channel mychannel2 enabled for session mysession
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng enable-event sched_kthread_stop,sched_kthread_stop_ret -k -s mysession --tracepoint
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-kernel event sched_kthread_stop created in channel channel0
-kernel sched_kthread_stop_ret created in channel channel0
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession: [inactive]
-    Trace path: /home/user/lttng-traces/mysession-20120314-132824
-
-=== Domain: Kernel ===
-
-Channels:
--------------
-- mychannel: [enabled]
-
-    Attributes:
-      overwrite mode: 1
-      subbufers size: 16384
-      number of subbufers: 4
-      switch timer interval: 100
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      None
-
-- mychannel2: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 32768
-      number of subbufers: 2
-      switch timer interval: 100
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      None
-
-- channel0: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 262144
-      number of subbufers: 4
-      switch timer interval: 0
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng enable-event sched_wakeup_new -k -s mysession --tracepoint
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-kernel event sched_wakeup_new created in channel channel0
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession: [inactive]
-    Trace path: /home/user/lttng-traces/mysession-20120314-132824
-
-=== Domain: Kernel ===
-
-Channels:
--------------
-- mychannel: [enabled]
-
-    Attributes:
-      overwrite mode: 1
-      subbufers size: 16384
-      number of subbufers: 4
-      switch timer interval: 100
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      None
-
-- mychannel2: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 32768
-      number of subbufers: 2
-      switch timer interval: 100
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      None
-
-- channel0: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 262144
-      number of subbufers: 4
-      switch timer interval: 0
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng enable-event -a -k -s mysession -c mychannel2 --tracepoint
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-All kernel event sched_kthread_stop created in channel channel0
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession: [inactive]
-    Trace path: /home/user/lttng-traces/mysession-20120314-132824
-
-=== Domain: Kernel ===
-
-Channels:
--------------
-- mychannel: [enabled]
-
-    Attributes:
-      overwrite mode: 1
-      subbufers size: 16384
-      number of subbufers: 4
-      switch timer interval: 100
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      None
-
-- mychannel2: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 32768
-      number of subbufers: 2
-      switch timer interval: 100
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-
-- channel0: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 262144
-      number of subbufers: 4
-      switch timer interval: 0
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng enable-event -a -k -s mysession -c mychannel --syscall
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-All kernel system calls are enabled in channel mychannel
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession: [inactive]
-    Trace path: /home/user/lttng-traces/mysession-20120314-132824
-
-=== Domain: Kernel ===
-
-Channels:
--------------
-- mychannel: [enabled]
-
-    Attributes:
-      overwrite mode: 1
-      subbufers size: 16384
-      number of subbufers: 4
-      switch timer interval: 100
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      syscalls (type: syscall) [enabled]
-
-- mychannel2: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 32768
-      number of subbufers: 2
-      switch timer interval: 100
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-
-- channel0: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 262144
-      number of subbufers: 4
-      switch timer interval: 0
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng enable-event -a -k -s mysession --syscall
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-All kernel system calls are enabled in channel channel0
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession: [inactive]
-    Trace path: /home/user/lttng-traces/mysession-20120314-132824
-
-=== Domain: Kernel ===
-
-Channels:
--------------
-- mychannel: [enabled]
-
-    Attributes:
-      overwrite mode: 1
-      subbufers size: 16384
-      number of subbufers: 4
-      switch timer interval: 100
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      syscalls (type: syscall) [enabled]
-
-- mychannel2: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 32768
-      number of subbufers: 2
-      switch timer interval: 100
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-
-- channel0: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 262144
-      number of subbufers: 4
-      switch timer interval: 0
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      syscalls (type: syscall) [enabled]
-      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng enable-event -a -k -s mysession --syscall
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-All kernel system calls are enabled in channel channel0
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession: [inactive]
-    Trace path: /home/user/lttng-traces/mysession-20120314-132824
-
-=== Domain: Kernel ===
-
-Channels:
--------------
-- mychannel: [enabled]
-
-    Attributes:
-      overwrite mode: 1
-      subbufers size: 16384
-      number of subbufers: 4
-      switch timer interval: 100
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      syscalls (type: syscall) [enabled]
-
-- mychannel2: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 32768
-      number of subbufers: 2
-      switch timer interval: 100
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-
-- channel0: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 262144
-      number of subbufers: 4
-      switch timer interval: 0
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      syscalls (type: syscall) [enabled]
-      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng enable-event myevent1 -k -s mysession --probe 0xc0101280
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-kernel event myevent1 created in channel channel0
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession: [inactive]
-    Trace path: /home/user/lttng-traces/mysession-20120314-132824
-
-=== Domain: Kernel ===
-
-Channels:
--------------
-- mychannel: [enabled]
-
-    Attributes:
-      overwrite mode: 1
-      subbufers size: 16384
-      number of subbufers: 4
-      switch timer interval: 100
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      syscalls (type: syscall) [enabled]
-
-- mychannel2: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 32768
-      number of subbufers: 2
-      switch timer interval: 100
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-
-- channel0: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 262144
-      number of subbufers: 4
-      switch timer interval: 0
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      myevent1 (type: probe) [enabled]
-        addr: 0xc0101280
-      syscalls (type: syscall) [enabled]
-      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng enable-event myevent2 -k -s mysession -c channel0 --probe init_post
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-kernel event myevent2 created in channel channel0
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession: [inactive]
-    Trace path: /home/user/lttng-traces/mysession-20120314-132824
-
-=== Domain: Kernel ===
-
-Channels:
--------------
-- mychannel: [enabled]
-
-    Attributes:
-      overwrite mode: 1
-      subbufers size: 16384
-      number of subbufers: 4
-      switch timer interval: 100
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      syscalls (type: syscall) [enabled]
-
-- mychannel2: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 32768
-      number of subbufers: 2
-      switch timer interval: 100
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-
-- channel0: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 262144
-      number of subbufers: 4
-      switch timer interval: 0
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      myevent2 (type: probe) [enabled]
-        offset: 0x0
-        symbol: init_post
-      myevent1 (type: probe) [enabled]
-        addr: 0xc0101280
-      syscalls (type: syscall) [enabled]
-      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng enable-event myevent3 -k -s mysession --probe init_post:0x1000
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-kernel event myevent2 created in channel channel0
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession: [inactive]
-    Trace path: /home/user/lttng-traces/mysession-20120314-132824
-
-=== Domain: Kernel ===
-
-Channels:
--------------
-- mychannel: [enabled]
-
-    Attributes:
-      overwrite mode: 1
-      subbufers size: 16384
-      number of subbufers: 4
-      switch timer interval: 100
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      syscalls (type: syscall) [enabled]
-
-- mychannel2: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 32768
-      number of subbufers: 2
-      switch timer interval: 100
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-
-- channel0: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 262144
-      number of subbufers: 4
-      switch timer interval: 0
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      myevent3 (type: probe) [enabled]
-        offset: 0x1000
-        symbol: init_post
-      myevent2 (type: probe) [enabled]
-        offset: 0x0
-        symbol: init_post
-      myevent1 (type: probe) [enabled]
-        addr: 0xc0101280
-      syscalls (type: syscall) [enabled]
-      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng enable-event myevent4 -k -s mysession --function create_dev
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-kernel event myevent4 created in channel channel0
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession: [inactive]
-    Trace path: /home/user/lttng-traces/mysession-20120314-132824
-
-=== Domain: Kernel ===
-
-Channels:
--------------
-- mychannel: [enabled]
-
-    Attributes:
-      overwrite mode: 1
-      subbufers size: 16384
-      number of subbufers: 4
-      switch timer interval: 100
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      syscalls (type: syscall) [enabled]
-
-- mychannel2: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 32768
-      number of subbufers: 2
-      switch timer interval: 100
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-
-- channel0: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 262144
-      number of subbufers: 4
-      switch timer interval: 0
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      myevent4 (type: function) [enabled]
-        offset: 0x0
-        symbol: create_dev
-      myevent3 (type: probe) [enabled]
-        offset: 0x1000
-        symbol: init_post
-      myevent2 (type: probe) [enabled]
-        offset: 0x0
-        symbol: init_post
-      myevent1 (type: probe) [enabled]
-        addr: 0xc0101280
-      syscalls (type: syscall) [enabled]
-      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng enable-event myevent5 -k -s mysession --function create_dev:0x2000
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-kernel event myevent5 created in channel channel0
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession: [inactive]
-    Trace path: /home/user/lttng-traces/mysession-20120314-132824
-
-=== Domain: Kernel ===
-
-Channels:
--------------
-- mychannel: [enabled]
-
-    Attributes:
-      overwrite mode: 1
-      subbufers size: 16384
-      number of subbufers: 4
-      switch timer interval: 100
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      syscalls (type: syscall) [enabled]
-
-- mychannel2: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 32768
-      number of subbufers: 2
-      switch timer interval: 100
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-
-- channel0: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 262144
-      number of subbufers: 4
-      switch timer interval: 0
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      myevent5 (type: probe) [enabled]
-        offset: 0x2000
-        symbol: create_dev
-      myevent4 (type: function) [enabled]
-        offset: 0x0
-        symbol: create_dev
-      myevent3 (type: probe) [enabled]
-        offset: 0x1000
-        symbol: init_post
-      myevent2 (type: probe) [enabled]
-        offset: 0x0
-        symbol: init_post
-      myevent1 (type: probe) [enabled]
-        addr: 0xc0101280
-      syscalls (type: syscall) [enabled]
-      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng enable-event myevent -k -s mysession -c mychannel --function create_dev:0x2000
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-kernel event myevent created in channel mychannel
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession: [inactive]
-    Trace path: /home/user/lttng-traces/mysession-20120314-132824
-
-=== Domain: Kernel ===
-
-Channels:
--------------
-- mychannel: [enabled]
-
-    Attributes:
-      overwrite mode: 1
-      subbufers size: 16384
-      number of subbufers: 4
-      switch timer interval: 100
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      myevent (type: probe) [enabled]
-        offset: 0x2000
-        symbol: create_dev
-      syscalls (type: syscall) [enabled]
-
-- mychannel2: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 32768
-      number of subbufers: 2
-      switch timer interval: 100
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-
-- channel0: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 262144
-      number of subbufers: 4
-      switch timer interval: 0
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      myevent5 (type: probe) [enabled]
-        offset: 0x2000
-        symbol: create_dev
-      myevent4 (type: function) [enabled]
-        offset: 0x0
-        symbol: create_dev
-      myevent3 (type: probe) [enabled]
-        offset: 0x1000
-        symbol: init_post
-      myevent2 (type: probe) [enabled]
-        offset: 0x0
-        symbol: init_post
-      myevent1 (type: probe) [enabled]
-        addr: 0xc0101280
-      syscalls (type: syscall) [enabled]
-      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Available tracing sessions:
-  1) mysession (/home/eedbhu/lttng-traces/mysession-20120321-115617) [inactive]
-
-Use lttng list <session_name> for more details
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list -k
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Kernel events
--------------
-      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint)
-      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint)
-      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint)
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list -u
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-UST events:
--------------
-
-PID: 9379 - Name: /home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello
-    ust_tests_hello:tptest_sighandler (loglevel: TRACE_WARNING (4)) (type: tracepoint)
-    ust_tests_hello:tptest (loglevel: TRACE_DEBUG_FUNCTION (12)) (type: tracepoint)
-
-PID: 4852 - Name: /home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello
-    ust_tests_hello:tptest_sighandler (loglevel: TRACE_WARNING (4)) (type: tracepoint)
-    ust_tests_hello:tptest (loglevel: TRACE_DEBUG_FUNCTION (12)) (type: tracepoint)
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession: [inactive]
-    Trace path: /home/user/lttng-traces/mysession-20120314-132824
-
-=== Domain: Kernel ===
-
-Channels:
--------------
-- mychannel: [enabled]
-
-    Attributes:
-      overwrite mode: 1
-      subbufers size: 16384
-      number of subbufers: 4
-      switch timer interval: 100
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      myevent (type: probe) [enabled]
-        offset: 0x2000
-        symbol: create_dev
-      syscalls (type: syscall) [enabled]
-
-- mychannel2: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 32768
-      number of subbufers: 2
-      switch timer interval: 100
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-
-- channel0: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 262144
-      number of subbufers: 4
-      switch timer interval: 0
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      myevent5 (type: probe) [enabled]
-        offset: 0x2000
-        symbol: create_dev
-      myevent4 (type: function) [enabled]
-        offset: 0x0
-        symbol: create_dev
-      myevent3 (type: probe) [enabled]
-        offset: 0x1000
-        symbol: init_post
-      myevent2 (type: probe) [enabled]
-        offset: 0x0
-        symbol: init_post
-      myevent1 (type: probe) [enabled]
-        addr: 0xc0101280
-      syscalls (type: syscall) [enabled]
-      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng add-context -h
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-usage: lttng add-context -t TYPE
-
-If no channel and no event is given (-c/-e), the context
-will be added to all events and all channels.
-Otherwise the context will be added only to the channel (-c)
-and/or event (-e) indicated.
-Exactly one domain (-k/--kernel or -u/--userspace) must be specified.
-
-Options:
-  -h, --help               Show this help
-      --list-options       Simple listing of options
-  -s, --session NAME       Apply to session name
-  -c, --channel NAME       Apply to channel
-  -e, --event NAME         Apply to event
-  -k, --kernel             Apply to the kernel tracer
-  -u, --userspace          Apply to the user-space tracer
-  -t, --type TYPE          Context type. You can repeat that option on
-                           the command line to specify multiple contexts at once.
-                           (--kernel preempts --userspace)
-                           TYPE can be one of the strings below:
-                               pid, procname, prio, nice, vpid, tid, pthread_id,
-                               vtid, ppid, vppid, perf:cpu-cycles, perf:cycles,
-                               perf:stalled-cycles-frontend,
-                               perf:idle-cycles-frontend,
-                               perf:stalled-cycles-backend,
-                               perf:idle-cycles-backend, perf:instructions,
-                               perf:cache-references, perf:cache-misses,
-                               perf:branch-instructions, perf:branches,
-                               perf:branch-misses, perf:bus-cycles,
-                               perf:L1-dcache-loads, perf:L1-dcache-load-misses,
-                               perf:L1-dcache-stores,
-                               perf:L1-dcache-store-misses,
-                               perf:L1-dcache-prefetches,
-                               perf:L1-dcache-prefetch-misses,
-                               perf:L1-icache-loads, perf:L1-icache-load-misses,
-                               perf:L1-icache-stores,
-                               perf:L1-icache-store-misses,
-                               perf:L1-icache-prefetches,
-                               perf:L1-icache-prefetch-misses, perf:LLC-loads,
-                               perf:LLC-load-misses, perf:LLC-stores,
-                               perf:LLC-store-misses, perf:LLC-prefetches,
-                               perf:LLC-prefetch-misses, perf:dTLB-loads,
-                               perf:dTLB-load-misses, perf:dTLB-stores,
-                               perf:dTLB-store-misses, perf:dTLB-prefetches,
-                               perf:dTLB-prefetch-misses, perf:iTLB-loads,
-                               perf:iTLB-load-misses, perf:branch-loads,
-                               perf:branch-load-misses, perf:cpu-clock,
-                               perf:task-clock, perf:page-fault, perf:faults,
-                               perf:major-faults, perf:minor-faults,
-                               perf:context-switches, perf:cs,
-                               perf:cpu-migrations, perf:migrations,
-                               perf:alignment-faults, perf:emulation-faults
-Example:
-This command will add the context information 'prio' and two perf
-counters (hardware branch misses and cache misses), to all events
-in the trace data output:
-# lttng add-context -k -t prio -t perf:branch-misses -t perf:cache-misses
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng add-context -s mysession -k -t prio -t perf:branch-misses -t perf:cache-misses
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-kernel context perf:cache-misses added to all channels
-kernel context perf:branch-misses added to all channels
-kernel context prio added to all channels
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession: [inactive]
-    Trace path: /home/user/lttng-traces/mysession-20120314-132824
-
-=== Domain: Kernel ===
-
-Channels:
--------------
-- mychannel: [enabled]
-
-    Attributes:
-      overwrite mode: 1
-      subbufers size: 16384
-      number of subbufers: 4
-      switch timer interval: 100
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      myevent (type: probe) [enabled]
-        offset: 0x2000
-        symbol: create_dev
-      syscalls (type: syscall) [enabled]
-
-- mychannel2: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 32768
-      number of subbufers: 2
-      switch timer interval: 100
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-
-- channel0: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 262144
-      number of subbufers: 4
-      switch timer interval: 0
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      myevent5 (type: probe) [enabled]
-        offset: 0x2000
-        symbol: create_dev
-      myevent4 (type: function) [enabled]
-        offset: 0x0
-        symbol: create_dev
-      myevent3 (type: probe) [enabled]
-        offset: 0x1000
-        symbol: init_post
-      myevent2 (type: probe) [enabled]
-        offset: 0x0
-        symbol: init_post
-      myevent1 (type: probe) [enabled]
-        addr: 0xc0101280
-      syscalls (type: syscall) [enabled]
-      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng add-context -h
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-usage: lttng add-context -t TYPE
-
-If no channel and no event is given (-c/-e), the context
-will be added to all events and all channels.
-Otherwise the context will be added only to the channel (-c)
-and/or event (-e) indicated.
-Exactly one domain (-k/--kernel or -u/--userspace) must be specified.
-
-Options:
-  -h, --help               Show this help
-      --list-options       Simple listing of options
-  -s, --session NAME       Apply to session name
-  -c, --channel NAME       Apply to channel
-  -e, --event NAME         Apply to event
-  -k, --kernel             Apply to the kernel tracer
-  -u, --userspace          Apply to the user-space tracer
-  -t, --type TYPE          Context type. You can repeat that option on
-                           the command line to specify multiple contexts at once.
-                           (--kernel preempts --userspace)
-                           TYPE can be one of the strings below:
-                               pid, procname, prio, nice, vpid, tid, pthread_id,
-                               vtid, ppid, vppid, perf:cpu-cycles, perf:cycles,
-                               perf:stalled-cycles-frontend,
-                               perf:idle-cycles-frontend,
-                               perf:stalled-cycles-backend,
-                               perf:idle-cycles-backend, perf:instructions,
-                               perf:cache-references, perf:cache-misses,
-                               perf:branch-instructions, perf:branches,
-                               perf:branch-misses, perf:bus-cycles,
-                               perf:L1-dcache-loads, perf:L1-dcache-load-misses,
-                               perf:L1-dcache-stores,
-                               perf:L1-dcache-store-misses,
-                               perf:L1-dcache-prefetches,
-                               perf:L1-dcache-prefetch-misses,
-                               perf:L1-icache-loads, perf:L1-icache-load-misses,
-                               perf:L1-icache-stores,
-                               perf:L1-icache-store-misses,
-                               perf:L1-icache-prefetches,
-                               perf:L1-icache-prefetch-misses, perf:LLC-loads,
-                               perf:LLC-load-misses, perf:LLC-stores,
-                               perf:LLC-store-misses, perf:LLC-prefetches,
-                               perf:LLC-prefetch-misses, perf:dTLB-loads,
-                               perf:dTLB-load-misses, perf:dTLB-stores,
-                               perf:dTLB-store-misses, perf:dTLB-prefetches,
-                               perf:dTLB-prefetch-misses, perf:iTLB-loads,
-                               perf:iTLB-load-misses, perf:branch-loads,
-                               perf:branch-load-misses, perf:cpu-clock,
-                               perf:task-clock, perf:page-fault, perf:faults,
-                               perf:major-faults, perf:minor-faults,
-                               perf:context-switches, perf:cs,
-                               perf:cpu-migrations, perf:migrations,
-                               perf:alignment-faults, perf:emulation-faults
-Example:
-This command will add the context information 'prio' and two perf
-counters (hardware branch misses and cache misses), to all events
-in the trace data output:
-# lttng add-context -k -t prio -t perf:branch-misses -t perf:cache-misses
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng add-context -s mysession -c mychannel -k -t prio -t perf:branch-misses -t perf:cache-misses
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-kernel context perf:cache-misses added to channel mychannel
-kernel context perf:branch-misses added to channel mychannel
-kernel context prio added to channel mychannel
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession: [inactive]
-    Trace path: /home/user/lttng-traces/mysession-20120314-132824
-
-=== Domain: Kernel ===
-
-Channels:
--------------
-- mychannel: [enabled]
-
-    Attributes:
-      overwrite mode: 1
-      subbufers size: 16384
-      number of subbufers: 4
-      switch timer interval: 100
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      myevent (type: probe) [enabled]
-        offset: 0x2000
-        symbol: create_dev
-      syscalls (type: syscall) [enabled]
-
-- mychannel2: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 32768
-      number of subbufers: 2
-      switch timer interval: 100
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-
-- channel0: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 262144
-      number of subbufers: 4
-      switch timer interval: 0
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      myevent5 (type: probe) [enabled]
-        offset: 0x2000
-        symbol: create_dev
-      myevent4 (type: function) [enabled]
-        offset: 0x0
-        symbol: create_dev
-      myevent3 (type: probe) [enabled]
-        offset: 0x1000
-        symbol: init_post
-      myevent2 (type: probe) [enabled]
-        offset: 0x0
-        symbol: init_post
-      myevent1 (type: probe) [enabled]
-        addr: 0xc0101280
-      syscalls (type: syscall) [enabled]
-      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng add-context -h
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-usage: lttng add-context -t TYPE
-
-If no channel and no event is given (-c/-e), the context
-will be added to all events and all channels.
-Otherwise the context will be added only to the channel (-c)
-and/or event (-e) indicated.
-Exactly one domain (-k/--kernel or -u/--userspace) must be specified.
-
-Options:
-  -h, --help               Show this help
-      --list-options       Simple listing of options
-  -s, --session NAME       Apply to session name
-  -c, --channel NAME       Apply to channel
-  -e, --event NAME         Apply to event
-  -k, --kernel             Apply to the kernel tracer
-  -u, --userspace          Apply to the user-space tracer
-  -t, --type TYPE          Context type. You can repeat that option on
-                           the command line to specify multiple contexts at once.
-                           (--kernel preempts --userspace)
-                           TYPE can be one of the strings below:
-                               pid, procname, prio, nice, vpid, tid, pthread_id,
-                               vtid, ppid, vppid, perf:cpu-cycles, perf:cycles,
-                               perf:stalled-cycles-frontend,
-                               perf:idle-cycles-frontend,
-                               perf:stalled-cycles-backend,
-                               perf:idle-cycles-backend, perf:instructions,
-                               perf:cache-references, perf:cache-misses,
-                               perf:branch-instructions, perf:branches,
-                               perf:branch-misses, perf:bus-cycles,
-                               perf:L1-dcache-loads, perf:L1-dcache-load-misses,
-                               perf:L1-dcache-stores,
-                               perf:L1-dcache-store-misses,
-                               perf:L1-dcache-prefetches,
-                               perf:L1-dcache-prefetch-misses,
-                               perf:L1-icache-loads, perf:L1-icache-load-misses,
-                               perf:L1-icache-stores,
-                               perf:L1-icache-store-misses,
-                               perf:L1-icache-prefetches,
-                               perf:L1-icache-prefetch-misses, perf:LLC-loads,
-                               perf:LLC-load-misses, perf:LLC-stores,
-                               perf:LLC-store-misses, perf:LLC-prefetches,
-                               perf:LLC-prefetch-misses, perf:dTLB-loads,
-                               perf:dTLB-load-misses, perf:dTLB-stores,
-                               perf:dTLB-store-misses, perf:dTLB-prefetches,
-                               perf:dTLB-prefetch-misses, perf:iTLB-loads,
-                               perf:iTLB-load-misses, perf:branch-loads,
-                               perf:branch-load-misses, perf:cpu-clock,
-                               perf:task-clock, perf:page-fault, perf:faults,
-                               perf:major-faults, perf:minor-faults,
-                               perf:context-switches, perf:cs,
-                               perf:cpu-migrations, perf:migrations,
-                               perf:alignment-faults, perf:emulation-faults
-Example:
-This command will add the context information 'prio' and two perf
-counters (hardware branch misses and cache misses), to all events
-in the trace data output:
-# lttng add-context -k -t prio -t perf:branch-misses -t perf:cache-misses
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng add-context -s mysession -c channel0 -e sched_kthread_stop_ret -k -t prio -t perf:branch-misses -t perf:cache-misses
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-kernel context perf:cache-misses added to event sched_kthread_stop_ret channel mychannel
-kernel context perf:branch-misses added to event sched_kthread_stop_ret channel mychannel
-kernel context prio added to channel event sched_kthread_stop_ret mychannel
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession: [inactive]
-    Trace path: /home/user/lttng-traces/mysession-20120314-132824
-
-=== Domain: Kernel ===
-
-Channels:
--------------
-- mychannel: [enabled]
-
-    Attributes:
-      overwrite mode: 1
-      subbufers size: 16384
-      number of subbufers: 4
-      switch timer interval: 100
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      myevent (type: probe) [enabled]
-        offset: 0x2000
-        symbol: create_dev
-      syscalls (type: syscall) [enabled]
-
-- mychannel2: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 32768
-      number of subbufers: 2
-      switch timer interval: 100
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-
-- channel0: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 262144
-      number of subbufers: 4
-      switch timer interval: 0
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      myevent5 (type: probe) [enabled]
-        offset: 0x2000
-        symbol: create_dev
-      myevent4 (type: function) [enabled]
-        offset: 0x0
-        symbol: create_dev
-      myevent3 (type: probe) [enabled]
-        offset: 0x1000
-        symbol: init_post
-      myevent2 (type: probe) [enabled]
-        offset: 0x0
-        symbol: init_post
-      myevent1 (type: probe) [enabled]
-        addr: 0xc0101280
-      syscalls (type: syscall) [enabled]
-      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng calibrate -k --function
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Kernel calibration done
-</COMMAND_OUTPUT>
-
-</SCENARIO>
-
-<SCENARIO>
-Scenario4
-
-<COMMAND_INPUT>
-lttng enable-channel mychannel -u -s mysession --overwrite --subbuf-size 16384 --num-subbuf 4 --switch-timer 100 --read-timer 200
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-UST channel mychannel enabled for session mysession
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession: [inactive]
-    Trace path: /home/user/lttng-traces/mysession-20120314-132824
-
-=== Domain: UST global ===
-
-Channels:
--------------
-- mychannel: [enabled]
-
-    Attributes:
-      overwrite mode: 1
-      subbufers size: 16384
-      number of subbufers: 4
-      switch timer interval: 100
-      read timer interval: 200
-      output: mmap()
-
-    Events:
-      None
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng enable-channel mychannel2 -u -s mysession --subbuf-size 32768 --num-subbuf 2 --switch-timer 100 --read-timer 200
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-UST channel mychannel2 enabled for session mysession
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession: [inactive]
-    Trace path: /home/user/lttng-traces/mysession-20120314-132824
-
-=== Domain: UST global ===
-
-Channels:
--------------
-- mychannel: [enabled]
-
-    Attributes:
-      overwrite mode: 1
-      subbufers size: 16384
-      number of subbufers: 4
-      switch timer interval: 100
-      read timer interval: 200
-      output: mmap()
-
-    Events:
-      None
-
-- mychannel2: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 32768
-      number of subbufers: 2
-      switch timer interval: 100
-      read timer interval: 200
-      output: mmap()
-
-    Events:
-      None
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng enable-event ust_tests_hello:tptest_sighandler -u -s mysession --tracepoint
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-UST event ust_tests_hello:tptest_sighandler created in channel channel0
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession: [inactive]
-    Trace path: /home/user/lttng-traces/mysession-20120314-132824
-
-=== Domain: UST global ===
-
-Channels:
--------------
-- mychannel: [enabled]
-
-    Attributes:
-      overwrite mode: 1
-      subbufers size: 16384
-      number of subbufers: 4
-      switch timer interval: 100
-      read timer interval: 200
-      output: mmap()
-
-    Events:
-      None
-
-- mychannel2: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 32768
-      number of subbufers: 2
-      switch timer interval: 100
-      read timer interval: 200
-      output: mmap()
-
-    Events:
-      None
-
-- channel0: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 262144
-      number of subbufers: 4
-      switch timer interval: 0
-      read timer interval: 200
-      output: mmap()
-
-    Events:
-      ust_tests_hello:tptest_sighandler (type: tracepoint) [enabled]
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng enable-event ust_tests_hello:tptest -u -s mysession --tracepoint
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-UST event ust_tests_hello:tptest created in channel channel0
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession: [inactive]
-    Trace path: /home/user/lttng-traces/mysession-20120314-132824
-
-=== Domain: UST global ===
-
-Channels:
--------------
-- mychannel: [enabled]
-
-    Attributes:
-      overwrite mode: 1
-      subbufers size: 16384
-      number of subbufers: 4
-      switch timer interval: 100
-      read timer interval: 200
-      output: mmap()
-
-    Events:
-      None
-
-- mychannel2: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 32768
-      number of subbufers: 2
-      switch timer interval: 100
-      read timer interval: 200
-      output: mmap()
-
-    Events:
-      None
-
-- channel0: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 262144
-      number of subbufers: 4
-      switch timer interval: 0
-      read timer interval: 200
-      output: mmap()
-
-    Events:
-      ust_tests_hello:tptest_sighandler (type: tracepoint) [enabled]
-      ust_tests_hello:tptest (type: tracepoint) [enabled]
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng enable-event -a -u -s mysession -c mychannel2 --tracepoint
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-All UST events created in channel channel0
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession: [inactive]
-    Trace path: /home/user/lttng-traces/mysession-20120314-132824
-
-=== Domain: UST global ===
-
-Channels:
--------------
-- mychannel: [enabled]
-
-    Attributes:
-      overwrite mode: 1
-      subbufers size: 16384
-      number of subbufers: 4
-      switch timer interval: 100
-      read timer interval: 200
-      output: mmap()
-
-    Events:
-      None
-
-- mychannel2: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 32768
-      number of subbufers: 2
-      switch timer interval: 100
-      read timer interval: 200
-      output: mmap()
-
-    Events:
-      * (type: tracepoint) [enabled]
-
-- channel0: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 262144
-      number of subbufers: 4
-      switch timer interval: 0
-      read timer interval: 200
-      output: mmap()
-
-    Events:
-      ust_tests_hello:tptest_sighandler (type: tracepoint) [enabled]
-      ust_tests_hello:tptest (type: tracepoint) [enabled]
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng enable-event ust* -u -s mysession -c mychannel --tracepoint
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-UST event ust* created in channel mychannel
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession: [inactive]
-    Trace path: /home/user/lttng-traces/mysession-20120314-132824
-
-=== Domain: UST global ===
-
-Channels:
--------------
-- mychannel: [enabled]
-
-    Attributes:
-      overwrite mode: 1
-      subbufers size: 16384
-      number of subbufers: 4
-      switch timer interval: 100
-      read timer interval: 200
-      output: mmap()
-
-    Events:
-      ust* (type: tracepoint) [enabled]
-
-- mychannel2: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 32768
-      number of subbufers: 2
-      switch timer interval: 100
-      read timer interval: 200
-      output: mmap()
-
-    Events:
-      * (type: tracepoint) [enabled]
-
-- channel0: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 262144
-      number of subbufers: 4
-      switch timer interval: 0
-      read timer interval: 200
-      output: mmap()
-
-    Events:
-      ust_tests_hello:tptest_sighandler (type: tracepoint) [enabled]
-      ust_tests_hello:tptest (type: tracepoint) [enabled]
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng enable-event ust* -u -s mysession --tracepoint
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-UST event ust* created in channel channel0
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession: [inactive]
-    Trace path: /home/user/lttng-traces/mysession-20120314-132824
-
-=== Domain: UST global ===
-
-Channels:
--------------
-- mychannel: [enabled]
-
-    Attributes:
-      overwrite mode: 1
-      subbufers size: 16384
-      number of subbufers: 4
-      switch timer interval: 100
-      read timer interval: 200
-      output: mmap()
-
-    Events:
-      ust* (type: tracepoint) [enabled]
-
-- mychannel2: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 32768
-      number of subbufers: 2
-      switch timer interval: 100
-      read timer interval: 200
-      output: mmap()
-
-    Events:
-      * (type: tracepoint) [enabled]
-
-- channel0: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 262144
-      number of subbufers: 4
-      switch timer interval: 0
-      read timer interval: 200
-      output: mmap()
-
-    Events:
-      ust* (type: tracepoint) [enabled]
-      ust_tests_hello:tptest_sighandler (type: tracepoint) [enabled]
-      ust_tests_hello:tptest (type: tracepoint) [enabled]
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng enable-event "u*" -u -s mysession --tracepoint
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-UST event u* created in channel channel0
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession: [inactive]
-    Trace path: /home/user/lttng-traces/mysession-20120314-132824
-
-=== Domain: UST global ===
-
-Channels:
--------------
-- mychannel: [enabled]
-
-    Attributes:
-      overwrite mode: 1
-      subbufers size: 16384
-      number of subbufers: 4
-      switch timer interval: 100
-      read timer interval: 200
-      output: mmap()
-
-    Events:
-      ust* (type: tracepoint) [enabled]
-
-- mychannel2: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 32768
-      number of subbufers: 2
-      switch timer interval: 100
-      read timer interval: 200
-      output: mmap()
-
-    Events:
-      * (type: tracepoint) [enabled]
-
-- channel0: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 262144
-      number of subbufers: 4
-      switch timer interval: 0
-      read timer interval: 200
-      output: mmap()
-
-    Events:
-      u* (type: tracepoint) [enabled]
-      ust* (type: tracepoint) [enabled]
-      ust_tests_hello:tptest_sighandler (type: tracepoint) [enabled]
-      ust_tests_hello:tptest (type: tracepoint) [enabled]
-
-</COMMAND_OUTPUT>
-
-
-<COMMAND_INPUT>
-lttng enable-event myevent1 -u -s mysession --loglevel TRACE_WARNING
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-UST event myevent1 created in channel channel0
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession: [inactive]
-    Trace path: /home/user/lttng-traces/mysession-20120314-132824
-
-=== Domain: UST global ===
-
-Channels:
--------------
-- mychannel: [enabled]
-
-    Attributes:
-      overwrite mode: 1
-      subbufers size: 16384
-      number of subbufers: 4
-      switch timer interval: 100
-      read timer interval: 200
-      output: mmap()
-
-    Events:
-      ust* (type: tracepoint) [enabled]
-
-- mychannel2: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 32768
-      number of subbufers: 2
-      switch timer interval: 100
-      read timer interval: 200
-      output: mmap()
-
-    Events:
-      * (type: tracepoint) [enabled]
-
-- channel0: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 262144
-      number of subbufers: 4
-      switch timer interval: 0
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      myevent1 (loglevel <= TRACE_WARNING (4)) (type: tracepoint) [enabled]
-      u* (type: tracepoint) [enabled]
-      ust* (type: tracepoint) [enabled]
-      ust_tests_hello:tptest_sighandler (type: tracepoint) [enabled]
-      ust_tests_hello:tptest (type: tracepoint) [enabled]
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng enable-event myevent2 -u -s mysession --loglevel-only TRACE_DEBUG_FUNCTION
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-UST event myevent2 created in channel channel0
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession: [inactive]
-    Trace path: /home/user/lttng-traces/mysession-20120314-132824
-
-=== Domain: UST global ===
-
-Channels:
--------------
-- mychannel: [enabled]
-
-    Attributes:
-      overwrite mode: 1
-      subbufers size: 16384
-      number of subbufers: 4
-      switch timer interval: 100
-      read timer interval: 200
-      output: mmap()
-
-    Events:
-      ust* (type: tracepoint) [enabled]
-
-- mychannel2: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 32768
-      number of subbufers: 2
-      switch timer interval: 100
-      read timer interval: 200
-      output: mmap()
-
-    Events:
-      * (type: tracepoint) [enabled]
-
-- channel0: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 262144
-      number of subbufers: 4
-      switch timer interval: 0
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      myevent2 (loglevel == TRACE_DEBUG_FUNCTION (12)) (type: tracepoint) [enabled]
-      myevent1 (loglevel <= TRACE_WARNING (4)) (type: loglevel) [enabled]
-      u* (type: tracepoint) [enabled]
-      ust* (type: tracepoint) [enabled]
-      ust_tests_hello:tptest_sighandler (type: tracepoint) [enabled]
-      ust_tests_hello:tptest (type: tracepoint) [enabled]
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng enable-event myevent0 -u -s mysession -c mychannel --loglevel-only TRACE_DEBUG_FUNCTION
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-UST event myevent0 created in channel mychannel
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession: [inactive]
-    Trace path: /home/user/lttng-traces/mysession-20120314-132824
-
-=== Domain: UST global ===
-
-Channels:
--------------
-- mychannel: [enabled]
-
-    Attributes:
-      overwrite mode: 1
-      subbufers size: 16384
-      number of subbufers: 4
-      switch timer interval: 100
-      read timer interval: 200
-      output: mmap()
-
-    Events:
-      myevent0 (loglevel <= TRACE_DEBUG_FUNCTION (12)) (type: tracepoint) [enabled]
-      ust* (type: tracepoint) [enabled]
-
-- mychannel2: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 32768
-      number of subbufers: 2
-      switch timer interval: 100
-      read timer interval: 200
-      output: mmap()
-
-    Events:
-      * (type: tracepoint) [enabled]
-
-- channel0: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 262144
-      number of subbufers: 4
-      switch timer interval: 0
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      myevent2 (loglevel <= TRACE_DEBUG_FUNCTION (12)) (type: tracepoint) [enabled]
-      myevent1 (loglevel == TRACE_WARNING (4)) (type: loglevel) [enabled]
-      u* (type: tracepoint) [enabled]
-      ust* (type: tracepoint) [enabled]
-      ust_tests_hello:tptest_sighandler (type: tracepoint) [enabled]
-      ust_tests_hello:tptest (type: tracepoint) [enabled]
-
-</COMMAND_OUTPUT>
-
-
-</SCENARIO>
-
-
-
diff --git a/org.eclipse.tracecompass.lttng2.control.ui.tests/testfiles/CreateTreeTest2.cfg b/org.eclipse.tracecompass.lttng2.control.ui.tests/testfiles/CreateTreeTest2.cfg
deleted file mode 100644 (file)
index b7b88bc..0000000
+++ /dev/null
@@ -1,323 +0,0 @@
-####################################################################
-# Copyright (c) 2013 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:
-#    Bernd Hufmann - Initial API and implementation
-####################################################################
-####################################################################
-# Scenario: Initialize
-####################################################################
-<SCENARIO>
-Initialize
-<COMMAND_INPUT>
-lttng version
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-lttng version 2.2.0 - Cuda
-Web site: http://lttng.org/
-
-lttng is free software and under the GPL license and part LGPL
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Currently no available tracing session
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list -k
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Kernel events
--------------
-      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint)
-      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint)
-      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint)
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list -u -f
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-UST events:
--------------
-
-PID: 9379 - Name: /home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello
-    ust_tests_hello:tptest_sighandler (loglevel: TRACE_WARNING (4)) (type: tracepoint)
-    ust_tests_hello:tptest (loglevel: TRACE_DEBUG_FUNCTION (12)) (type: tracepoint)
-
-PID: 4852 - Name: /home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello
-    ust_tests_hello:tptest_sighandler (loglevel: TRACE_WARNING (4)) (type: tracepoint)
-    ust_tests_hello:tptest (loglevel: TRACE_DEBUG_FUNCTION (12)) (type: tracepoint)
-
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Session and channel with per-UID UST buffers
-####################################################################
-<SCENARIO>
-ScenPerUidTest
-<COMMAND_INPUT>
-lttng create mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Session mysession created.
-Traces will be written in /home/user/lttng-traces/mysession-20130812-113358
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession: [inactive]
-    Trace path: /home/user/lttng-traces/mysession-20130812-113358
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng destroy mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Session my destroyed.
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng enable-channel mychannel -u -s mysession --buffers-uid
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-UST channel mychannel enabled for session mysession
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession: [inactive]
-    Trace path: /home/user/lttng-traces/mysession-20130812-113358
-
-=== Domain: UST global ===
-
-Buffer type: per UID
-
-Channels:
--------------
-- mychannel: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 8388608
-      number of subbufers: 4
-      switch timer interval: 0
-      read timer interval: 0
-      output: mmap()
-
-    Events:
-      None
-
-</COMMAND_OUTPUT>
-
-</SCENARIO>
-
-####################################################################
-# Scenario: Session and channel with per-PID UST buffers
-####################################################################
-<SCENARIO>
-ScenPerPidTest
-<COMMAND_INPUT>
-lttng create mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Session mysession created.
-Traces will be written in /home/user/lttng-traces/mysession-20130812-113358
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession: [inactive]
-    Trace path: /home/user/lttng-traces/mysession-20130812-113358
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng destroy mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Session mysession destroyed.
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng enable-channel mychannel -u -s mysession --buffers-pid
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-UST channel mychannel enabled for session mysession
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession: [inactive]
-    Trace path: /home/user/lttng-traces/mysession-20130812-113358
-
-=== Domain: UST global ===
-
-Buffer type: per PID
-
-Channels:
--------------
-- mychannel: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 8388608
-      number of subbufers: 4
-      switch timer interval: 0
-      read timer interval: 0
-      output: mmap()
-
-    Events:
-      None
-
-</COMMAND_OUTPUT>
-
-</SCENARIO>
-
-####################################################################
-# Scenario: Session and channel with per-PID UST buffers with option -C -W
-####################################################################
-<SCENARIO>
-ScenBufSizeTest
-<COMMAND_INPUT>
-lttng create mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Session mysession created.
-Traces will be written in /home/user/lttng-traces/mysession-20130812-113358
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession: [inactive]
-    Trace path: /home/user/lttng-traces/mysession-20130812-113358
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng destroy mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Session mysession destroyed.
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng enable-channel mychannel -u -s mysession -C 1024 -W 10
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<COMMAND_ERROR_OUTPUT>
-Warning: Tracefile size rounded up from (1024) to subbuffer size (8388608)
-</COMMAND_ERROR_OUTPUT>
-UST channel mychannel enabled for session mysession
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession: [inactive]
-    Trace path: /home/user/lttng-traces/mysession-20130812-113358
-
-=== Domain: UST global ===
-
-Buffer type: per PID
-
-Channels:
--------------
-- mychannel: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 8388608
-      number of subbufers: 4
-      switch timer interval: 0
-      read timer interval: 0
-      output: mmap()
-
-    Events:
-      None
-
-</COMMAND_OUTPUT>
-
-</SCENARIO>
-
-
-
diff --git a/org.eclipse.tracecompass.lttng2.control.ui.tests/testfiles/LTTngServiceMiTest.cfg b/org.eclipse.tracecompass.lttng2.control.ui.tests/testfiles/LTTngServiceMiTest.cfg
deleted file mode 100644 (file)
index 1406ca4..0000000
+++ /dev/null
@@ -1,2616 +0,0 @@
-####################################################################
-# Copyright (c) 2014, 2015 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:
-#    Jonathan Rajotte - Initial API and implementation
-#    Bernd Hufmann - Added new test cases
-####################################################################
-####################################################################
-# Scenario: Test lttng not installed
-####################################################################
-<SCENARIO>
-LttngNotInstalled
-<COMMAND_INPUT>
-lttng --mi xml list
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-1
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<COMMAND_ERROR_OUTPUT>
-Command not found
-</COMMAND_ERROR_OUTPUT>
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test lttng version
-####################################################################
-<SCENARIO>
-LttngVersion
-<COMMAND_INPUT>
-lttng version
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-lttng version 2.1.0 - Basse Messe
-Web site: http://lttng.org/
-
-lttng is free software and under the GPL license and part LGPL
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test lttng version
-# output with prompt
-####################################################################
-<SCENARIO>
-LttngVersionWithPrompt
-<COMMAND_INPUT>
-lttng version
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Prompt> lttng version 2.0.0 - Annedd'ale
-Web site: http://lttng.org/
-
-lttng is free software and under the GPL license and part LGPL
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test lttng version (unsupported version)
-####################################################################
-<SCENARIO>
-LttngUnsupportedVersion
-<COMMAND_INPUT>
-lttng version
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-lttng version 200.0.0 - Annedd'ale
-Web site: http://lttng.org/
-
-lttng is free software and under the GPL license and part LGPL
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-
-####################################################################
-# Scenario: Test lttng version (noversion)
-####################################################################
-<SCENARIO>
-LttngNoVersion
-<COMMAND_INPUT>
-lttng version
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Web site: http://lttng.org/
-
-lttng is free software and under the GPL license and part LGPL
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test lttng version (compiled from source)
-####################################################################
-<SCENARIO>
-LttngVersionCompiled
-<COMMAND_INPUT>
-lttng --mi xml version
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>version</name>
-  <output>
-    <version>
-      <string>2.5.0-rc2</string>
-      <major>2</major>
-      <minor>5</minor>
-      <commit>v2.5.0-rc2-99-g234170a</commit>
-      <patchLevel>0</patchLevel>
-      <name>Fumisterie</name>
-      <description>The Fumisterie is a beer whose style is at the confluence of English and German ales. On the palate, it is full-bodied, malty and slightly caramelized. The organic hemp seeds incorporated during the brewing gives it a unique and original taste. The hop flavour comes through delicately in the after taste.</description>
-      <url>http://lttng.org</url>
-      <license>lttng is free software and under the GPL license and part LGPL</license>
-    </version>
-  </output>
-</command>
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test no sessions available
-####################################################################
-<SCENARIO>
-NoSessionAvailable
-<COMMAND_INPUT>
-lttng --mi xml list
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command><name>list</name><output><sessions/></output></command>
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test get sessions
-####################################################################
-<SCENARIO>
-GetSessionNames1
-<COMMAND_INPUT>
-lttng --mi xml list
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>list</name>
-  <output>
-    <sessions>
-      <session>
-        <name>mysession1</name>
-        <path>home/user/lttng-traces/mysession1-20120123-083928</path>
-        <enabled>false</enabled>
-        <snapshot_mode>0</snapshot_mode>
-        <live_timer_interval>0</live_timer_interval>
-      </session>
-      <session>
-        <name>mysession</name>
-        <path>home/user/lttng-traces/mysession-20120123-083318</path>
-        <enabled>false</enabled>
-        <snapshot_mode>0</snapshot_mode>
-        <live_timer_interval>0</live_timer_interval>
-      </session>
-    </sessions>
-  </output>
-</command>
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test get sessions with tracing group
-####################################################################
-<SCENARIO>
-GetSessionWithTracingGroup
-<COMMAND_INPUT>
-lttng -g group --mi xml list
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>list</name>
-  <output>
-    <sessions>
-      <session>
-        <name>mysession1</name>
-        <path>home/user/lttng-traces/mysession1-20120123-083928</path>
-        <enabled>false</enabled>
-        <snapshot_mode>0</snapshot_mode>
-        <live_timer_interval>0</live_timer_interval>
-      </session>
-      <session>
-        <name>mysession</name>
-        <path>home/user/lttng-traces/mysession-20120123-083318</path>
-        <enabled>false</enabled>
-        <snapshot_mode>0</snapshot_mode>
-        <live_timer_interval>0</live_timer_interval>
-      </session>
-    </sessions>
-  </output>
-</command>
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-
-####################################################################
-# Scenario: Test lttng list <name> where session doesn't exist
-####################################################################
-<SCENARIO>
-GetSessionNameNotExist
-<COMMAND_INPUT>
-lttng --mi xml list test
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-1
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command><name>list</name><output><sessions/></output></command>
-<COMMAND_ERROR_OUTPUT>
-Error: Session 'test' not found
-Error: Command error
-</COMMAND_ERROR_OUTPUT>
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test lttng -vvv list <name> where session doesn't exist
-####################################################################
-<SCENARIO>
-GetSessionNameNotExistVerbose
-<COMMAND_INPUT>
-lttng --mi xml -vvv list test
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-1
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command><name>list</name><output><sessions/></output></command>
-<COMMAND_ERROR_OUTPUT>
-Error: Session 'test' not found
-Error: Command error
-</COMMAND_ERROR_OUTPUT>
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test lttng list with garbage output
-####################################################################
-<SCENARIO>
-GetSessionGarbageOut
-<COMMAND_INPUT>
-lttng --mi xml list
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-asdfaereafsdcv 12333456434&*89**(())(^%$*
-@#$%^&*()@#$%^&*()0834523094578kj;djkfs
-a;sdf094v5u dsafj;sd9
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test lttng list <name> with sample outputs
-####################################################################
-<SCENARIO>
-GetSession1
-<COMMAND_INPUT>
-lttng --mi xml list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>list</name>
-  <output>
-    <sessions>
-      <session>
-        <name>mysession</name>
-        <path>/home/user/lttng-traces/mysession-20120129-084256</path>
-        <enabled>true</enabled>
-        <snapshot_mode>0</snapshot_mode>
-        <live_timer_interval>0</live_timer_interval>
-        <domains>
-          <domain>
-            <type>KERNEL</type>
-            <buffer_type>PER_PID</buffer_type>
-            <channels>
-              <channel>
-                <name>channel0</name>
-                <enabled>true</enabled>
-                <attributes>
-                  <overwrite_mode>DISCARD</overwrite_mode>
-                  <subbuffer_size>262144</subbuffer_size>
-                  <subbuffer_count>4</subbuffer_count>
-                  <switch_timer_interval>0</switch_timer_interval>
-                  <read_timer_interval>200</read_timer_interval>
-                  <output_type>SPLICE</output_type>
-                  <tracefile_size>0</tracefile_size>
-                  <tracefile_count>0</tracefile_count>
-                  <live_timer_interval>0</live_timer_interval>
-                </attributes>
-                <events>
-                  <event>
-                    <name>block_rq_remap</name>
-                    <type>TRACEPOINT</type>
-                    <enabled>true</enabled>
-                    <filter>false</filter>
-                    <loglevel>TRACE_EMERG</loglevel>
-                    <loglevel_type>ALL</loglevel_type>
-                    <exclusion>false</exclusion>
-                  </event>
-                  <event>
-                    <name>block_bio_remap</name>
-                    <type>TRACEPOINT</type>
-                    <enabled>false</enabled>
-                    <filter>false</filter>
-                    <loglevel>TRACE_EMERG</loglevel>
-                    <loglevel_type>ALL</loglevel_type>
-                    <exclusion>false</exclusion>
-                  </event>
-                </events>
-              </channel>
-              <channel>
-                <name>channel1</name>
-                <enabled>false</enabled>
-                <attributes>
-                  <overwrite_mode>OVERWRITE</overwrite_mode>
-                  <subbuffer_size>524288</subbuffer_size>
-                  <subbuffer_count>4</subbuffer_count>
-                  <switch_timer_interval>100</switch_timer_interval>
-                  <read_timer_interval>400</read_timer_interval>
-                  <output_type>SPLICE</output_type>
-                  <tracefile_size>0</tracefile_size>
-                  <tracefile_count>0</tracefile_count>
-                  <live_timer_interval>4294967295</live_timer_interval>
-                </attributes>
-                <events/>
-              </channel>
-            </channels>
-          </domain>
-          <domain>
-            <type>UST</type>
-            <buffer_type>PER_UID</buffer_type>
-            <channels>
-              <channel>
-                <name>mychannel1</name>
-                <enabled>false</enabled>
-                <attributes>
-                  <overwrite_mode>OVERWRITE</overwrite_mode>
-                  <subbuffer_size>8192</subbuffer_size>
-                  <subbuffer_count>8</subbuffer_count>
-                  <switch_timer_interval>200</switch_timer_interval>
-                  <read_timer_interval>100</read_timer_interval>
-                  <output_type>MMAP</output_type>
-                  <tracefile_size>0</tracefile_size>
-                  <tracefile_count>0</tracefile_count>
-                  <live_timer_interval>0</live_timer_interval>
-                </attributes>
-                <events/>
-              </channel>
-              <channel>
-                <name>channel0</name>
-                <enabled>true</enabled>
-                <attributes>
-                  <overwrite_mode>DISCARD</overwrite_mode>
-                  <subbuffer_size>4096</subbuffer_size>
-                  <subbuffer_count>4</subbuffer_count>
-                  <switch_timer_interval>0</switch_timer_interval>
-                  <read_timer_interval>200</read_timer_interval>
-                  <output_type>MMAP</output_type>
-                  <tracefile_size>0</tracefile_size>
-                  <tracefile_count>0</tracefile_count>
-                  <live_timer_interval>0</live_timer_interval>
-                </attributes>
-                <events>
-                  <event>
-                    <name>ust_tests_hello:tptest_sighandler</name>
-                    <type>TRACEPOINT</type>
-                    <enabled>false</enabled>
-                    <filter>false</filter>
-                    <loglevel>TRACE_DEBUG_LINE</loglevel>
-                    <loglevel_type>ALL</loglevel_type>
-                    <exclusion>false</exclusion>
-                  </event>
-                  <event>
-                    <name>*</name>
-                    <type>TRACEPOINT</type>
-                    <enabled>true</enabled>
-                    <filter>false</filter>
-                    <exclusion>false</exclusion>
-                  </event>
-                </events>
-              </channel>
-            </channels>
-          </domain>
-        </domains>
-      </session>
-    </sessions>
-  </output>
-</command>
-</COMMAND_OUTPUT>
-<COMMAND_INPUT>
-lttng --mi xml list mysession1
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>list</name>
-  <output>
-    <sessions>
-      <session>
-        <name>mysession1</name>
-        <path>/home/user/lttng-traces/mysession1-20120203-133225</path>
-        <enabled>false</enabled>
-        <snapshot_mode>0</snapshot_mode>
-        <live_timer_interval>0</live_timer_interval>
-        <domains/>
-      </session>
-    </sessions>
-  </output>
-</command>
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-
-####################################################################
-# Scenario: Test lttng list <name> (with live time interval)
-####################################################################
-<SCENARIO>
-GetSessionWithLiveInterval
-<COMMAND_INPUT>
-lttng --mi xml list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>list</name>
-  <output>
-    <sessions>
-      <session>
-        <name>mysession</name>
-        <path>/home/user/lttng-traces/mysession-20120129-084256</path>
-        <enabled>false</enabled>
-        <snapshot_mode>1</snapshot_mode>
-        <live_timer_interval>4294967295</live_timer_interval>
-        <domains>
-        </domains>
-      </session>
-    </sessions>
-  </output>
-</command>
-</COMMAND_OUTPUT>
-#------------------------------------------------------------------------------
-<COMMAND_INPUT>
-lttng --mi xml snapshot list-output -s mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>snapshot</name>
-  <output>
-    <snapshot_action>
-      <name>list-output</name>
-      <output>
-        <session>
-          <name>mysession</name>
-          <snapshots>
-            <snapshot>
-              <id>1</id>
-              <name>snapshot-1</name>
-              <ctrl_url>/home/user/lttng-traces/mysession-20120129-084256</ctrl_url>
-              <data_url/>
-              <max_size>0</max_size>
-            </snapshot>
-          </snapshots>
-        </session>
-      </output>
-    </snapshot_action>
-  </output>
-  <success>true</success>
-</command>
-</COMMAND_OUTPUT>
-#------------------------------------------------------------------------------
-<COMMAND_INPUT>
-lttng --mi xml list mysession1
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>list</name>
-  <output>
-    <sessions>
-      <session>
-        <name>mysession1</name>
-        <path>/home/user/lttng-traces/mysession1-20120129-084256</path>
-        <enabled>true</enabled>
-        <snapshot_mode>0</snapshot_mode>
-        <live_timer_interval>0</live_timer_interval>
-        <domains/>
-      </session>
-    </sessions>
-  </output>
-</command>
-</COMMAND_OUTPUT>
-#------------------------------------------------------------------------------
-<COMMAND_INPUT>
-lttng --mi xml list mysession2
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>list</name>
-  <output>
-    <sessions>
-      <session>
-        <name>mysession2</name>
-        <path>tcp4://172.0.0.1:5342/ [data: 5343]</path>
-        <enabled>false</enabled>
-        <snapshot_mode>0</snapshot_mode>
-        <live_timer_interval>1000000</live_timer_interval>
-        <domains/>
-      </session>
-    </sessions>
-  </output>
-</command>
-</COMMAND_OUTPUT>
-
-</SCENARIO>
-
-
-####################################################################
-# Scenario: Test "lttng list -k" with sample output
-####################################################################
-<SCENARIO>
-GetKernelProvider1
-<COMMAND_INPUT>
-lttng --mi xml list -k
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>list</name>
-  <output>
-    <domains>
-      <domain>
-        <type>KERNEL</type>
-        <buffer_type>PER_PID</buffer_type>
-        <events>
-          <event>
-            <name>sched_kthread_stop</name>
-            <type>TRACEPOINT</type>
-            <enabled>true</enabled>
-            <filter>false</filter>
-            <loglevel>TRACE_EMERG</loglevel>
-            <loglevel_type>ALL</loglevel_type>
-            <exclusion>false</exclusion>
-          </event>
-          <event>
-            <name>sched_kthread_stop_ret</name>
-            <type>TRACEPOINT</type>
-            <enabled>true</enabled>
-            <filter>false</filter>
-            <loglevel>TRACE_EMERG</loglevel>
-            <loglevel_type>ALL</loglevel_type>
-            <exclusion>false</exclusion>
-          </event>
-          <event>
-            <name>sched_wakeup_new</name>
-            <type>TRACEPOINT</type>
-            <enabled>true</enabled>
-            <filter>false</filter>
-            <loglevel>TRACE_EMERG</loglevel>
-            <loglevel_type>ALL</loglevel_type>
-            <exclusion>false</exclusion>
-          </event>
-       </events>
-      </domain>
-    </domains>
-  </output>
-</command>
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test "lttng list -k" with no kernel and no session daemon
-####################################################################
-<SCENARIO>
-ListWithNoKernel1
-<COMMAND_INPUT>
-lttng --mi xml list -k
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-1
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Spawning session daemon
-<COMMAND_ERROR_OUTPUT>
-Error: Unable to list kernel events
-</COMMAND_ERROR_OUTPUT>
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test "lttng list -k" with no kernel and with session daemon
-####################################################################
-<SCENARIO>
-ListWithNoKernel2
-<COMMAND_INPUT>
-lttng --mi xml list -k
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-1
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<COMMAND_ERROR_OUTPUT>
-Error: Unable to list kernel events
-</COMMAND_ERROR_OUTPUT>
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test "lttng list -u" with sample output
-####################################################################
-<SCENARIO>
-GetUstProvider1
-<COMMAND_INPUT>
-lttng --mi xml list -u -f
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>list</name>
-  <output>
-    <domains>
-      <domain>
-        <type>UST</type>
-        <buffer_type>PER_PID</buffer_type>
-        <pids>
-          <pid>
-            <id>9379</id>
-            <name>/home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello</name>
-            <events>
-              <event>
-                <name>ust_tests_hello:tptest_sighandler</name>
-                <type>TRACEPOINT</type>
-                <enabled>true</enabled>
-                <filter>false</filter>
-                <loglevel>TRACE_DEBUG_MODULE</loglevel>
-                <loglevel_type>ALL</loglevel_type>
-                <exclusion>false</exclusion>
-                <event_fields/>
-              </event>
-              <event>
-                <name>ust_tests_hello:tptest</name>
-                <type>TRACEPOINT</type>
-                <enabled>true</enabled>
-                <filter>false</filter>
-                <loglevel>TRACE_INFO</loglevel>
-                <loglevel_type>ALL</loglevel_type>
-                <exclusion>false</exclusion>
-                <event_fields>
-                  <event_field>
-                    <name>doublefield</name>
-                    <type>FLOAT</type>
-                    <nowrite>0</nowrite>
-                  </event_field>
-                  <event_field>
-                    <name>floatfield</name>
-                    <type>FLOAT</type>
-                    <nowrite>0</nowrite>
-                  </event_field>
-                  <event_field>
-                    <name>stringfield</name>
-                    <type>STRING</type>
-                    <nowrite>0</nowrite>
-                  </event_field>
-                </event_fields>
-              </event>
-            </events>
-          </pid>
-          <pid>
-            <id>4852</id>
-            <name>/home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello</name>
-            <events>
-              <event>
-                <name>ust_tests_hello:tptest_sighandler</name>
-                <type>TRACEPOINT</type>
-                <enabled>true</enabled>
-                <filter>false</filter>
-                <loglevel>TRACE_WARNING</loglevel>
-                <loglevel_type>ALL</loglevel_type>
-                <exclusion>false</exclusion>
-                <event_fields/>
-              </event>
-              <event>
-                <name>ust_tests_hello:tptest</name>
-                <type>TRACEPOINT</type>
-                <enabled>true</enabled>
-                <filter>false</filter>
-                <loglevel>TRACE_DEBUG_FUNCTION</loglevel>
-                <loglevel_type>ALL</loglevel_type>
-                <exclusion>false</exclusion>
-                <event_fields>
-                  <event_field>
-                    <name>doublefield</name>
-                    <type>FLOAT</type>
-                    <nowrite>0</nowrite>
-                  </event_field>
-                  <event_field>
-                    <name>floatfield</name>
-                    <type>FLOAT</type>
-                    <nowrite>0</nowrite>
-                  </event_field>
-                  <event_field>
-                    <name>stringfield</name>
-                    <type>STRING</type>
-                    <nowrite>0</nowrite>
-                  </event_field>
-                </event_fields>
-              </event>
-            </events>
-          </pid>
-        </pids>
-      </domain>
-    </domains>
-  </output>
-</command>
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test "lttng list -u" with no UST provider available
-####################################################################
-<SCENARIO>
-GetUstProvider2
-<COMMAND_INPUT>
-lttng --mi xml list -u -f
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>list</name>
-  <output>
-    <domains>
-      <domain>
-        <type>UST</type>
-        <buffer_type>PER_PID</buffer_type>
-        <pids/>
-      </domain>
-    </domains>
-  </output>
-</command>
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test "lttng list -u" with no UST available (LTTng 2.0.x)
-####################################################################
-<SCENARIO>
-ListWithNoUst1
-<COMMAND_INPUT>
-lttng --mi xml list -u -f
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-1
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command><name>list</name><output/></command>
-<COMMAND_ERROR_OUTPUT>
-Error: Unable to list UST event fields: LTTng-UST tracer is not supported. Please rebuild lttng-tools with lttng-ust support enabled.
-Error: Command error
-</COMMAND_ERROR_OUTPUT>
-</COMMAND_OUTPUT>
-</SCENARIO>
-####################################################################
-# Scenario: Test "lttng list -u" with no UST available and no session daemon
-####################################################################
-<SCENARIO>
-ListWithNoUst2
-<COMMAND_INPUT>
-lttng --mi xml list -u -f
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-1
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command><name>list</name><output/></command>
-<COMMAND_ERROR_OUTPUT>
-Error: Unable to list UST event fields: LTTng-UST tracer is not supported. Please rebuild lttng-tools with lttng-ust support enabled.
-Error: Command error
-</COMMAND_ERROR_OUTPUT>
-</COMMAND_OUTPUT>
-</SCENARIO>
-####################################################################
-# Scenario: Test "lttng list -" with no kernel and with session daemon
-####################################################################
-<SCENARIO>
-ListWithNoUst3
-<COMMAND_INPUT>
-lttng --mi xml list -u -f
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-1
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command><name>list</name><output/></command>
-<COMMAND_ERROR_OUTPUT>
-Error: Unable to list kernel events: Tracing the kernel requires a root lttng-sessiond daemon, as well as "tracing" group membership or root user ID for the lttng client.
-Error: Command Error
-</COMMAND_ERROR_OUTPUT>
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test "lttng list -u -f" with sample output (version 2.6.0)
-####################################################################
-<SCENARIO>
-GetUstProvider3
-<COMMAND_INPUT>
-lttng --mi xml list -u -f
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>list</name>
-  <output>
-    <domains>
-      <domain>
-        <type>UST</type>
-        <buffer_type>PER_PID</buffer_type>
-        <pids>
-          <pid>
-            <id>9379</id>
-            <name>/home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello</name>
-            <events>
-              <event>
-                <name>ust_tests_hello:tptest_sighandler</name>
-                <type>TRACEPOINT</type>
-                <enabled>true</enabled>
-                <filter>false</filter>
-                <loglevel>TRACE_DEBUG_MODULE</loglevel>
-                <loglevel_type>ALL</loglevel_type>
-                <exclusion>false</exclusion>
-                <event_fields/>
-              </event>
-              <event>
-                <name>ust_tests_hello:tptest</name>
-                <type>TRACEPOINT</type>
-                <enabled>true</enabled>
-                <filter>false</filter>
-                <loglevel>TRACE_INFO</loglevel>
-                <loglevel_type>ALL</loglevel_type>
-                <exclusion>false</exclusion>
-                <event_fields>
-                  <event_field>
-                    <name>doublefield</name>
-                    <type>FLOAT</type>
-                    <nowrite>0</nowrite>
-                  </event_field>
-                  <event_field>
-                    <name>floatfield</name>
-                    <type>FLOAT</type>
-                    <nowrite>0</nowrite>
-                  </event_field>
-                  <event_field>
-                    <name>stringfield</name>
-                    <type>STRING</type>
-                    <nowrite>0</nowrite>
-                  </event_field>
-                </event_fields>
-              </event>
-            </events>
-          </pid>
-          <pid>
-            <id>4852</id>
-            <name>/home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello</name>
-            <events>
-              <event>
-                <name>ust_tests_hello:tptest_sighandler</name>
-                <type>TRACEPOINT</type>
-                <enabled>true</enabled>
-                <filter>false</filter>
-                <loglevel>TRACE_WARNING</loglevel>
-                <loglevel_type>ALL</loglevel_type>
-                <exclusion>false</exclusion>
-                <event_fields/>
-              </event>
-              <event>
-                <name>ust_tests_hello:tptest</name>
-                <type>TRACEPOINT</type>
-                <enabled>true</enabled>
-                <filter>false</filter>
-                <loglevel>TRACE_DEBUG_FUNCTION</loglevel>
-                <loglevel_type>ALL</loglevel_type>
-                <exclusion>false</exclusion>
-                <event_fields>
-                  <event_field>
-                    <name>doublefield</name>
-                    <type>FLOAT</type>
-                    <nowrite>0</nowrite>
-                  </event_field>
-                  <event_field>
-                    <name>floatfield</name>
-                    <type>FLOAT</type>
-                    <nowrite>0</nowrite>
-                  </event_field>
-                  <event_field>
-                    <name>stringfield</name>
-                    <type>STRING</type>
-                    <nowrite>0</nowrite>
-                  </event_field>
-                </event_fields>
-              </event>
-            </events>
-          </pid>
-        </pids>
-      </domain>
-    </domains>
-  </output>
-</command>
-</COMMAND_OUTPUT>
-</SCENARIO>
-####################################################################
-# Scenario: Test "lttng create <session>
-####################################################################
-<SCENARIO>
-CreateSession1
-<COMMAND_INPUT>
-lttng --mi xml create mysession2
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>create</name>
-  <output>
-    <session>
-      <name>mysession2</name>
-      <path>/home/user/lttng-traces/mysession2-20120209-095418</path>
-      <enabled>false</enabled>
-      <snapshot_mode>0</snapshot_mode>
-      <live_timer_interval>0</live_timer_interval>
-    </session>
-  </output>
-  <success>true</success>
-</command>
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test "lttng create <session>
-####################################################################
-<SCENARIO>
-CreateSessionWithPrompt
-<COMMAND_INPUT>
-lttng --mi xml create mysession2
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Prompt> Session mysession2 created.
-Traces will be written in /home/user/lttng-traces/mysession2-20120209-095418
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test "lttng create <session> with different variants
-# and errors
-####################################################################
-<SCENARIO>
-CreateSessionVariants
-<COMMAND_INPUT>
-lttng --mi xml create alreadyExist
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-1
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>create</name>
-  <output/>
-  <success>false</success>
-</command>
-<COMMAND_ERROR_OUTPUT>
-Warning: Session mysession2 already exists
-Error: Session name already exists
-</COMMAND_ERROR_OUTPUT>
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng --mi xml create session with spaces
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>create</name>
-  <output>
-    <session>
-      <name>session with spaces</name>
-      <path>/home/user/lttng-traces/session with spaces-20120209-095418</path>
-      <enabled>false</enabled>
-      <snapshot_mode>0</snapshot_mode>
-      <live_timer_interval>0</live_timer_interval>
-    </session>
-  </output>
-  <success>true</success>
-</command>
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng --mi xml create wrongName
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>create</name>
-  <output>
-    <session>
-      <name>auto</name>
-      <path>/home/user/lttng-traces/auto-20120209-095418</path>
-      <enabled>false</enabled>
-      <snapshot_mode>0</snapshot_mode>
-      <live_timer_interval>0</live_timer_interval>
-    </session>
-  </output>
-  <success>true</success>
-</command>
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng --mi xml create wrongPath -o /home/user/hallo
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>create</name>
-  <output>
-    <session>
-      <name>wrongPath</name>
-      <path>/home/user/lttng-traces/wrongPath-20120209-095418</path>
-      <enabled>false</enabled>
-      <snapshot_mode>0</snapshot_mode>
-      <live_timer_interval>0</live_timer_interval>
-    </session>
-  </output>
-  <success>true</success>
-</command>
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng --mi xml create pathWithSpaces -o /home/user/hallo user/here
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>create</name>
-  <output>
-    <session>
-      <name>pathWithSpaces</name>
-      <path>/home/user/hallo user/here/pathWithSpaces-20120209-095418</path>
-      <enabled>false</enabled>
-      <snapshot_mode>0</snapshot_mode>
-      <live_timer_interval>0</live_timer_interval>
-    </session>
-  </output>
-  <success>true</success>
-</command>
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test "lttng destroy <session>
-####################################################################
-
-<SCENARIO>
-DestroySession1
-<COMMAND_INPUT>
-lttng --mi xml destroy mysession2
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>destroy</name>
-  <output>
-    <sessions>
-      <session>
-        <name>mysession2</name>
-        <path>/home/user/lttng-traces/mysession2-20140812-160632</path>
-        <enabled>false</enabled>
-        <snapshot_mode>0</snapshot_mode>
-        <live_timer_interval>0</live_timer_interval>
-      </session>
-    </sessions>
-  </output>
-  <success>true</success>
-</command>
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test "lttng enable-channel ..." with different inputs
-####################################################################
-
-<SCENARIO>
-ChannelHandling
-<COMMAND_INPUT>
-lttng --mi xml enable-channel mychannel0,mychannel1 -k -s mysession2 --overwrite --subbuf-size 16384 --num-subbuf 2 --switch-timer 200 --read-timer 100 -C 0 -W 10
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Kernel channel mychannel0 enabled for session mysession2
-Kernel channel mychannel1 enabled for session mysession2
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng --mi xml enable-channel mychannel0,mychannel1 -k -s mysession2 --overwrite --subbuf-size 16384 --num-subbuf 2 --switch-timer 200 --read-timer 100
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>enable-channel</name>
-  <output>
-    <channels>
-      <channel>
-        <name>mychannel0</name>
-        <enabled>false</enabled>
-        <attributes>
-          <overwrite_mode>OVERWRITE</overwrite_mode>
-          <subbuffer_size>16384</subbuffer_size>
-          <subbuffer_count>2</subbuffer_count>
-          <switch_timer_interval>200</switch_timer_interval>
-          <read_timer_interval>100</read_timer_interval>
-          <output_type>SPLICE</output_type>
-          <tracefile_size>0</tracefile_size>
-          <tracefile_count>0</tracefile_count>
-          <live_timer_interval>4294967295</live_timer_interval>
-        </attributes>
-        <success>true</success>
-      </channel>
-      <channel>
-        <name>mychannel1</name>
-        <enabled>false</enabled>
-        <attributes>
-          <overwrite_mode>OVERWRITE</overwrite_mode>
-          <subbuffer_size>16384</subbuffer_size>
-          <subbuffer_count>2</subbuffer_count>
-          <switch_timer_interval>200</switch_timer_interval>
-          <read_timer_interval>100</read_timer_interval>
-          <output_type>SPLICE</output_type>
-          <tracefile_size>0</tracefile_size>
-          <tracefile_count>0</tracefile_count>
-          <live_timer_interval>4294967295</live_timer_interval>
-        </attributes>
-        <success>true</success>
-      </channel>
-    </channels>
-  </output>
-  <success>true</success>
-</command>
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng --mi xml enable-channel ustChannel -u -s mysession2 --overwrite --subbuf-size 32768 --num-subbuf 1 --switch-timer 100 --read-timer 200 -C 0 -W 20
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-UST channel channel0 enabled for session mysession2
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng --mi xml enable-channel ustChannel -u -s mysession2 --overwrite --subbuf-size 32768 --num-subbuf 1 --switch-timer 100 --read-timer 200
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>enable-channel</name>
-  <output>
-    <channels>
-      <channel>
-        <name>ustChannel</name>
-        <enabled>false</enabled>
-        <attributes>
-          <overwrite_mode>OVERWRITE</overwrite_mode>
-          <subbuffer_size>32768</subbuffer_size>
-          <subbuffer_count>2</subbuffer_count>
-          <switch_timer_interval>100</switch_timer_interval>
-          <read_timer_interval>200</read_timer_interval>
-          <output_type>MMAP</output_type>
-          <tracefile_size>0</tracefile_size>
-          <tracefile_count>0</tracefile_count>
-          <live_timer_interval>4294967295</live_timer_interval>
-        </attributes>
-        <success>true</success>
-      </channel>
-    </channels>
-  </output>
-  <success>true</success>
-</command>
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng --mi xml enable-channel ustChannel -u -s mysession2 --overwrite --subbuf-size 32768 --num-subbuf 1 --switch-timer 100 --read-timer 200 --buffers-uid -C 0 -W 20
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-UST channel channel0 enabled for session mysession2
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng --mi xml enable-channel ustChannel -u -s mysession2 --overwrite --buffers-pid
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>enable-channel</name>
-  <output>
-    <channels>
-      <channel>
-        <name>ustChannel</name>
-        <enabled>false</enabled>
-        <attributes>
-          <overwrite_mode>OVERWRITE</overwrite_mode>
-          <subbuffer_size>4096</subbuffer_size>
-          <subbuffer_count>4</subbuffer_count>
-          <switch_timer_interval>0</switch_timer_interval>
-          <read_timer_interval>0</read_timer_interval>
-          <output_type>MMAP</output_type>
-          <tracefile_size>0</tracefile_size>
-          <tracefile_count>0</tracefile_count>
-          <live_timer_interval>4294967295</live_timer_interval>
-        </attributes>
-        <success>true</success>
-      </channel>
-    </channels>
-  </output>
-  <success>true</success>
-</command>
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng --mi xml enable-channel ustChannel -u -s mysession2 --overwrite --subbuf-size 32768 --num-subbuf 2 --switch-timer 100 --read-timer 200 --buffers-uid
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>enable-channel</name>
-  <output>
-    <channels>
-      <channel>
-        <name>ustChannel</name>
-        <enabled>false</enabled>
-        <attributes>
-          <overwrite_mode>OVERWRITE</overwrite_mode>
-          <subbuffer_size>32768</subbuffer_size>
-          <subbuffer_count>2</subbuffer_count>
-          <switch_timer_interval>100</switch_timer_interval>
-          <read_timer_interval>200</read_timer_interval>
-          <output_type>MMAP</output_type>
-          <tracefile_size>0</tracefile_size>
-          <tracefile_count>0</tracefile_count>
-          <live_timer_interval>4294967295</live_timer_interval>
-        </attributes>
-        <success>true</success>
-      </channel>
-    </channels>
-  </output>
-  <success>true</success>
-</command>
-</COMMAND_OUTPUT>
-
-
-<COMMAND_INPUT>
-lttng --mi xml enable-channel mychannel0,mychannel1 -k -s mysession2
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>enable-channel</name>
-  <output>
-    <channels>
-      <channel>
-        <name>mychannel0</name>
-        <enabled>false</enabled>
-        <attributes>
-          <overwrite_mode>DISCARD</overwrite_mode>
-          <subbuffer_size>262144</subbuffer_size>
-          <subbuffer_count>4</subbuffer_count>
-          <switch_timer_interval>0</switch_timer_interval>
-          <read_timer_interval>200000</read_timer_interval>
-          <output_type>SPLICE</output_type>
-          <tracefile_size>0</tracefile_size>
-          <tracefile_count>0</tracefile_count>
-          <live_timer_interval>4294967295</live_timer_interval>
-        </attributes>
-        <success>true</success>
-      </channel>
-      <channel>
-        <name>mychannel1</name>
-        <enabled>false</enabled>
-        <attributes>
-          <overwrite_mode>DISCARD</overwrite_mode>
-          <subbuffer_size>262144</subbuffer_size>
-          <subbuffer_count>4</subbuffer_count>
-          <switch_timer_interval>0</switch_timer_interval>
-          <read_timer_interval>200000</read_timer_interval>
-          <output_type>SPLICE</output_type>
-          <tracefile_size>0</tracefile_size>
-          <tracefile_count>0</tracefile_count>
-          <live_timer_interval>4294967295</live_timer_interval>
-        </attributes>
-        <success>true</success>
-      </channel>
-    </channels>
-  </output>
-  <success>true</success>
-</command>
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng --mi xml enable-channel ustChannel -u -s mysession2
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>enable-channel</name>
-  <output>
-    <channels>
-      <channel>
-        <name>ustChannel</name>
-        <enabled>false</enabled>
-        <attributes>
-          <overwrite_mode>DISCARD</overwrite_mode>
-          <subbuffer_size>131072</subbuffer_size>
-          <subbuffer_count>4</subbuffer_count>
-          <switch_timer_interval>0</switch_timer_interval>
-          <read_timer_interval>0</read_timer_interval>
-          <output_type>MMAP</output_type>
-          <tracefile_size>0</tracefile_size>
-          <tracefile_count>0</tracefile_count>
-          <live_timer_interval>4294967295</live_timer_interval>
-        </attributes>
-        <success>true</success>
-      </channel>
-    </channels>
-  </output>
-  <success>true</success>
-</command>
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng --mi xml disable-channel mychannel0,mychannel1 -k -s mysession2
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>disable-channel</name>
-  <output>
-    <channels>
-      <channel>
-        <name>mychannel0</name>
-        <enabled>false</enabled>
-        <success>true</success>
-      </channel>
-      <channel>
-        <name>mychannel1</name>
-        <enabled>false</enabled>
-        <success>true</success>
-      </channel>
-    </channels>
-  </output>
-  <success>true</success>
-</command>
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng --mi xml disable-channel ustChannel -u -s mysession2
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>disable-channel</name>
-  <output>
-    <channels>
-      <channel>
-        <name>ustChannel</name>
-        <enabled>false</enabled>
-        <success>true</success>
-      </channel>
-    </channels>
-  </output>
-  <success>true</success>
-</command>
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-
-####################################################################
-# Scenario: Test "lttng --mi xml enable-events ..." with different inputs
-####################################################################
-<SCENARIO>
-EventHandling
-
-# Tracepoint test cases
-
-<COMMAND_INPUT>
-lttng --mi xml enable-event block_rq_remap,block_bio_remap,softirq_entry -k -s mysession2 --tracepoint
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>enable-event</name>
-  <output>
-    <events>
-      <event>
-        <name>block_rq_remap</name>
-        <type>TRACEPOINT</type>
-        <enabled>true</enabled>
-        <filter>false</filter>
-        <loglevel>TRACE_EMERG</loglevel>
-        <loglevel_type>ALL</loglevel_type>
-        <exclusion>false</exclusion>
-        <success>true</success>
-      </event>
-      <event>
-        <name>block_bio_remap</name>
-        <type>TRACEPOINT</type>
-        <enabled>true</enabled>
-        <filter>false</filter>
-        <loglevel>TRACE_EMERG</loglevel>
-        <loglevel_type>ALL</loglevel_type>
-        <exclusion>false</exclusion>
-        <success>true</success>
-      </event>
-      <event>
-        <name>softirq_entry</name>
-        <type>TRACEPOINT</type>
-        <enabled>true</enabled>
-        <filter>false</filter>
-        <loglevel>TRACE_EMERG</loglevel>
-        <loglevel_type>ALL</loglevel_type>
-        <exclusion>false</exclusion>
-        <success>true</success>
-      </event>
-    </events>
-  </output>
-  <success>true</success>
-</command>
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng --mi xml enable-event -a -k -s mysession2 -c mychannel --tracepoint
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>enable-event</name>
-  <output>
-    <events>
-      <event>
-        <name>*</name>
-        <type>TRACEPOINT</type>
-        <enabled>true</enabled>
-        <filter>false</filter>
-        <loglevel>TRACE_EMERG</loglevel>
-        <loglevel_type>ALL</loglevel_type>
-        <exclusion>false</exclusion>
-        <success>true</success>
-      </event>
-    </events>
-  </output>
-  <success>true</success>
-</command>
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng --mi xml enable-event ust_tests_hello:tptest_sighandler -u -s mysession2 -c mychannel --tracepoint
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>enable-event</name>
-  <output>
-    <events>
-      <event>
-        <name>ust_tests_hello:tptest_sighandler</name>
-        <type>TRACEPOINT</type>
-        <enabled>true</enabled>
-        <filter>false</filter>
-        <exclusion>false</exclusion>
-        <success>true</success>
-      </event>
-    </events>
-  </output>
-  <success>true</success>
-</command>
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng --mi xml enable-event ust_tests_hello:tptest_sighandler -u -s mysession2 -c mychannel --tracepoint --filter intfield==10
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>enable-event</name>
-  <output>
-    <events>
-      <event>
-        <name>ust_tests_hello:tptest_sighandler</name>
-        <type>TRACEPOINT</type>
-        <enabled>true</enabled>
-        <filter>true</filter>
-        <exclusion>false</exclusion>
-        <success>true</success>
-      </event>
-    </events>
-  </output>
-  <success>true</success>
-</command>
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng --mi xml enable-event -a -u -s mysession2 -c mychannel --tracepoint
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>enable-event</name>
-  <output>
-    <events>
-      <event>
-        <name>*</name>
-        <type>TRACEPOINT</type>
-        <enabled>true</enabled>
-        <filter>false</filter>
-        <exclusion>false</exclusion>
-        <success>true</success>
-      </event>
-    </events>
-  </output>
-  <success>true</success>
-</command>
-</COMMAND_OUTPUT>
-
-# Syscall test cases
-
-<COMMAND_INPUT>
-lttng --mi xml enable-event -a -k -s mysession2 --syscall
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>enable-event</name>
-  <output>
-    <events>
-      <event>
-        <name>*</name>
-        <type>SYSCALL</type>
-        <enabled>true</enabled>
-        <filter>false</filter>
-        <success>true</success>
-      </event>
-    </events>
-  </output>
-  <success>true</success>
-</command>
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng --mi xml enable-event -a -k -s mysession2 -c mychannel --syscall
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>enable-event</name>
-  <output>
-    <events>
-      <event>
-        <name>*</name>
-        <type>SYSCALL</type>
-        <enabled>true</enabled>
-        <filter>false</filter>
-        <success>true</success>
-      </event>
-    </events>
-  </output>
-  <success>true</success>
-</command>
-</COMMAND_OUTPUT>
-
-# dynamic probe/function probe test cases
-
-<COMMAND_INPUT>
-lttng --mi xml enable-event myevent0 -k -s mysession2 --function 0xc0101340
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>enable-event</name>
-  <output>
-    <events>
-      <event>
-        <name>myevent0</name>
-        <type>FUNCTION</type>
-        <enabled>false</enabled>
-        <filter>false</filter>
-        <success>true</success>
-      </event>
-    </events>
-  </output>
-  <success>true</success>
-</command>
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng --mi xml enable-event myevent1 -k -s mysession2 -c mychannel --probe init_post
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>enable-event</name>
-  <output>
-    <events>
-      <event>
-        <name>myevent1</name>
-        <type>PROBE</type>
-        <enabled>false</enabled>
-        <filter>false</filter>
-        <offset>0</offset>
-        <symbol_name>init_post</symbol_name>
-        <success>true</success>
-      </event>
-    </events>
-  </output>
-  <success>true</success>
-</command>
-
-</COMMAND_OUTPUT>
-
-# log level test cases
-
-<COMMAND_INPUT>
-lttng --mi xml enable-event myevent4 -u -s mysession2 --loglevel-only TRACE_DEBUG
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>enable-event</name>
-  <output>
-    <events>
-      <event>
-        <name>myevent4</name>
-        <type>TRACEPOINT</type>
-        <enabled>true</enabled>
-        <filter>false</filter>
-        <loglevel>TRACE_DEBUG</loglevel>
-        <loglevel_type>SINGLE</loglevel_type>
-        <exclusion>false</exclusion>
-        <success>true</success>
-      </event>
-    </events>
-  </output>
-  <success>true</success>
-</command>
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng --mi xml enable-event myevent5 -u -s mysession2 -c mychannel --loglevel TRACE_DEBUG_FUNCTION
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>enable-event</name>
-  <output>
-    <events>
-      <event>
-        <name>myevent5</name>
-        <type>TRACEPOINT</type>
-        <enabled>true</enabled>
-        <filter>false</filter>
-        <loglevel>TRACE_DEBUG_FUNCTION</loglevel>
-        <loglevel_type>RANGE</loglevel_type>
-        <exclusion>false</exclusion>
-        <success>true</success>
-      </event>
-    </events>
-  </output>
-  <success>true</success>
-</command>
-</COMMAND_OUTPUT>
-
-</SCENARIO>
-
-####################################################################
-# Scenario: Test "lttng add-context -h" and lttng --mi xml add-context ..." with different inputs
-####################################################################
-
-<SCENARIO>
-ContextHandling
-
-<COMMAND_INPUT>
-lttng --mi xml add-context -h
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-usage: lttng add-context -t TYPE [-k|-u] [OPTIONS]
-
-If no channel is given (-c), the context is added to
-all channels.
-
-Otherwise the context is added only to the channel (-c).
-
-Exactly one domain (-k or -u) must be specified.
-
-Options:
-  -h, --help               Show this help
-      --list-options       Simple listing of options
-  -s, --session NAME       Apply to session name
-  -c, --channel NAME       Apply to channel
-  -k, --kernel             Apply to the kernel tracer
-  -u, --userspace          Apply to the user-space tracer
-
-Context:
-  -t, --type TYPE          Context type. You can repeat that option on
-                           the command line to specify multiple contexts at once.
-                           (--kernel preempts --userspace)
-                           TYPE can be one of the strings below:
-                               pid, procname, prio, nice, vpid, tid, pthread_id,
-                               vtid, ppid, vppid, perf:cpu:cpu-cycles, perf:cpu:cycles
-Note that the vpid, vppid and vtid context types represent the virtual process id,
-virtual parent process id and virtual thread id as seen from the current execution context
-as opposed to the pid, ppid and tid which are kernel internal data structures.
-
-Example:
-This command will add the context information 'prio' and two per-cpu
-perf counters (hardware branch misses and cache misses), to all channels
-in the trace data output:
-# lttng add-context -k -t prio -t perf:cpu:branch-misses -t perf:cpu:cache-misses
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng --mi xml add-context -s mysession2 -c mychannel -e ust_tests_hello:tptest_sighandler -u -t prio -t pid
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-UST context prio added to event ust_tests_hello:tptest_sighandle channel mychannel
-UST context pid added to event sched_kthread_stop_ret channel mychannel
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-<SCENARIO>
-ContextErrorHandling
-
-<COMMAND_INPUT>
-lttng --mi xml add-context -h
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-1
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-usage: lttng add-context -t TYPE
-
-If no channel and no event is given (-c/-e), the context
-will be added to all events and all channels.
-Otherwise the context will be added only to the channel (-c)
-and/or event (-e) indicated.
-Exactly one domain (-k/--kernel or -u/--userspace) must be specified.
-
-Options:
-  -h, --help               Show this help
-      --list-options       Simple listing of options
-  -s, --session NAME       Apply to session name
-  -c, --channel NAME       Apply to channel
-  -e, --event NAME         Apply to event
-  -k, --kernel             Apply to the kernel tracer
-  -u, --userspace          Apply to the user-space tracer
-  -t, --type TYPE          Context type. You can repeat that option on
-                           the command line to specify multiple contexts at once.
-                           (--kernel preempts --userspace)
-                           TYPE can be one of the strings below:
-                               pid, procname, prio, nice, vpid, tid, pthread_id,
-                               vtid, ppid, vppid, perf:cpu-cycles, perf:cycles
-Example:
-This command will add the context information 'prio' and two perf
-counters (hardware branch misses and cache misses), to all events
-in the trace data output:
-# lttng add-context -k -t prio -t perf:branch-misses -t perf:cache-misses
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng --mi xml add-context -s mysession2 -c mychannel -e ust_tests_hello:tptest_sighandler -u -t prio -t pid
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-1
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-UST context prio added to event ust_tests_hello:tptest_sighandle channel mychannel
-UST context pid added to event sched_kthread_stop_ret channel mychannel
-</COMMAND_OUTPUT>
-
-</SCENARIO>
-
-<SCENARIO>
-CalibrateHandling
-<COMMAND_INPUT>
-lttng --mi xml calibrate -k --function
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>calibrate</name>
-  <output>
-    <calibrate>
-      <type>FUNCTION</type>
-    </calibrate>
-  </output>
-  <success>true</success>
-</command>
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng --mi xml calibrate -u --function
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-1
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>calibrate</name>
-  <output>
-    <calibrate>
-      <type>FUNCTION</type>
-    </calibrate>
-  </output>
-  <success>true</success>
-</command>
-</COMMAND_OUTPUT>
-
-</SCENARIO>
-
-####################################################################
-# Scenario: Test "lttng create <session> with LTTng 2.1 options
-####################################################################
-<SCENARIO>
-CreateSessionLttng2.1
-
-<COMMAND_INPUT>
-lttng --mi xml create mysession -U net://172.0.0.1
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>create</name>
-  <output>
-    <session>
-      <name>mysession</name>
-      <path>tcp4://172.0.0.1:5342/mysession-20140813-095804 [data: 5343]</path>
-      <enabled>false</enabled>
-      <snapshot_mode>0</snapshot_mode>
-      <live_timer_interval>0</live_timer_interval>
-    </session>
-  </output>
-  <success>true</success>
-</command>
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng --mi xml create mysession -U file:///tmp
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>create</name>
-  <output>
-    <session>
-      <name>mysession</name>
-      <path>/tmp</path>
-      <enabled>false</enabled>
-      <snapshot_mode>0</snapshot_mode>
-      <live_timer_interval>0</live_timer_interval>
-    </session>
-  </output>
-  <success>true</success>
-</command>
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng --mi xml create mysession -C tcp://172.0.0.1 -D tcp://172.0.0.1:5343
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>create</name>
-  <output>
-    <session>
-      <name>mysession</name>
-      <path>tcp4://172.0.0.1:5342/ [data: 5343]</path>
-      <enabled>false</enabled>
-      <snapshot_mode>0</snapshot_mode>
-      <live_timer_interval>0</live_timer_interval>
-    </session>
-  </output>
-  <success>true</success>
-</command>
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng --mi xml create mysession -U 172.0.0.1:1234:2345
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>create</name>
-  <output>
-    <session>
-      <name>mysession</name>
-      <path>tcp4://172.0.0.1:1234/mysession-20140813-102225 [data: 2345]</path>
-      <enabled>false</enabled>
-      <snapshot_mode>0</snapshot_mode>
-      <live_timer_interval>0</live_timer_interval>
-    </session>
-  </output>
-  <success>true</success>
-</command>
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng --mi xml destroy mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>destroy</name>
-  <output>
-    <sessions>
-      <session>
-        <name>mysession</name>
-        <path>/home/user/lttng-traces/mysession-20140818-100114</path>
-        <enabled>false</enabled>
-        <snapshot_mode>0</snapshot_mode>
-        <live_timer_interval>0</live_timer_interval>
-      </session>
-    </sessions>
-  </output>
-  <success>true</success>
-</command>
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng --mi xml -vvv create mysession -U net://172.0.0.1
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-DEBUG3: URI string: net://172.0.0.1 [in uri_parse() at uri.c:253]
-DEBUG2: IP address resolved to 172.0.0.1 [in set_ip_address() at uri.c:132]
-DEBUG3: URI dtype: 1, proto: 1, host: 172.0.0.1, subdir: , ctrl: 0, data: 0 [in uri_parse() at uri.c:467]
-DEBUG1: LSM cmd type : 8 [in send_session_msg() at lttng-ctl.c:261]
-Session mysession created.
-Traces will be written in net://172.0.0.1
-DEBUG1: Init config session in /home/bernd [in config_init() at conf.c:294]
-</COMMAND_OUTPUT>
-
-</SCENARIO>
-
-####################################################################
-# Scenario: Test "lttng create <session> --snapshot (LTTng 2.3)
-####################################################################
-<SCENARIO>
-CreateSessionSnapshot
-<COMMAND_INPUT>
-lttng --mi xml create mysession --snapshot
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>create</name>
-  <output>
-    <session>
-      <name>mysession</name>
-      <path/>
-      <enabled>false</enabled>
-      <snapshot_mode>1</snapshot_mode>
-      <live_timer_interval>4294967295</live_timer_interval>
-    </session>
-  </output>
-  <success>true</success>
-</command>
-</COMMAND_OUTPUT>
-#------------------------------------------------------------------------------
-<COMMAND_INPUT>
-lttng --mi xml snapshot list-output -s mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>snapshot</name>
-  <output>
-    <snapshot_action>
-      <name>list-output</name>
-      <output>
-        <session>
-          <name>mysession</name>
-          <snapshots>
-            <snapshot>
-              <id>1</id>
-              <name>snapshot-1</name>
-              <ctrl_url>/home/user/lttng-traces/mysession-20130913-141651</ctrl_url>
-              <data_url/>
-              <max_size>0</max_size>
-            </snapshot>
-          </snapshots>
-        </session>
-      </output>
-    </snapshot_action>
-  </output>
-  <success>true</success>
-</command>
-</COMMAND_OUTPUT>
-#------------------------------------------------------------------------------
-<COMMAND_INPUT>
-lttng --mi xml list
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>list</name>
-  <output>
-    <sessions>
-      <session>
-        <name>mysession</name>
-        <path/>
-        <enabled>false</enabled>
-        <snapshot_mode>1</snapshot_mode>
-        <live_timer_interval>4294967295</live_timer_interval>
-      </session>
-    </sessions>
-  </output>
-</command>
-</COMMAND_OUTPUT>
-#------------------------------------------------------------------------------
-<COMMAND_INPUT>
-lttng --mi xml snapshot record -s mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-    Snapshot recorded successfully for session mysession
-</COMMAND_OUTPUT>
-#------------------------------------------------------------------------------
-<COMMAND_INPUT>
-lttng --mi xml destroy mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>destroy</name>
-  <output>
-    <sessions>
-      <session>
-        <name>mysession</name>
-        <path>/home/user/lttng-traces/mysession-20140818-100114</path>
-        <enabled>false</enabled>
-        <snapshot_mode>0</snapshot_mode>
-        <live_timer_interval>0</live_timer_interval>
-      </session>
-    </sessions>
-  </output>
-  <success>true</success>
-</command>
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test "lttng create <session> --snapshot -U <URL> (LTTng 2.3)
-####################################################################
-<SCENARIO>
-CreateSessionStreamedSnapshot
-<COMMAND_INPUT>
-lttng --mi xml create mysession --snapshot -U net://172.0.0.1
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Session mysession created.
-Default snapshot output set to: net://172.0.0.1
-Snapshot mode set. Every channel enabled for that session will be set in overwrite mode and mmap output.
-</COMMAND_OUTPUT>
-#------------------------------------------------------------------------------
-<COMMAND_INPUT>
-lttng --mi xml snapshot list-output -s mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Snapshot output list for session mysession
-    [2] snapshot-2: net4://172.0.0.1:5342/
-</COMMAND_OUTPUT>
-#------------------------------------------------------------------------------
-<COMMAND_INPUT>
-lttng --mi xml list
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-  1) mysession () [inactive snapshot]
-
-</COMMAND_OUTPUT>
-#------------------------------------------------------------------------------
-<COMMAND_INPUT>
-lttng --mi xml snapshot record -s mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-    Snapshot recorded successfully for session mysession
-</COMMAND_OUTPUT>
-#------------------------------------------------------------------------------
-<COMMAND_INPUT>
-lttng --mi xml destroy mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>destroy</name>
-  <output>
-    <sessions>
-      <session>
-        <name>mysession</name>
-        <path>/home/user/lttng-traces/mysession-20140818-100114</path>
-        <enabled>false</enabled>
-        <snapshot_mode>0</snapshot_mode>
-        <live_timer_interval>0</live_timer_interval>
-      </session>
-    </sessions>
-  </output>
-  <success>true</success>
-</command>
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test "lttng create <session> --snapshot (LTTng 2.3)
-####################################################################
-<SCENARIO>
-CreateSessionSnapshotErrors
-<COMMAND_INPUT>
-lttng --mi xml snapshot list-output -s blabla
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-1
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<COMMAND_ERROR_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>snapshot</name>
-  <output>
-    <snapshot_action>
-      <name>list-output</name>
-      <output/>
-    </snapshot_action>
-  </output>
-  <success>false</success>
-</command>
-</COMMAND_ERROR_OUTPUT>
-</COMMAND_OUTPUT>
-#------------------------------------------------------------------------------
-#next is not an error case but good to be tested
-<COMMAND_INPUT>
-lttng --mi xml list
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>list</name>
-  <output>
-    <sessions>
-      <session>
-        <name>mysession</name>
-        <path/>
-        <enabled>true</enabled>
-        <snapshot_mode>1</snapshot_mode>
-        <live_timer_interval>4294967295</live_timer_interval>
-      </session>
-    </sessions>
-  </output>
-</command>
-</COMMAND_OUTPUT>
-#------------------------------------------------------------------------------
-<COMMAND_INPUT>
-lttng --mi xml snapshot record -s blabla
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-1
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<COMMAND_ERROR_OUTPUT>
-    Error: Session name not found
-</COMMAND_ERROR_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>snapshot</name>
-  <output>
-    <snapshot_action>
-      <name>record</name>
-      <output/>
-    </snapshot_action>
-  </output>
-  <success>false</success>
-</command>
-</COMMAND_OUTPUT>
-#------------------------------------------------------------------------------
-<COMMAND_INPUT>
-lttng --mi xml snapshot record -s mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-1
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<COMMAND_ERROR_OUTPUT>
-    Error: Session needs to be started once
-</COMMAND_ERROR_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>snapshot</name>
-  <output>
-    <snapshot_action>
-      <name>record</name>
-      <output/>
-    </snapshot_action>
-  </output>
-  <success>false</success>
-</command>
-</COMMAND_OUTPUT>
-
-</SCENARIO>
-
-####################################################################
-# Scenario: Test "lttng create <session> --live [USEC] (LTTng 2.4)
-####################################################################
-<SCENARIO>
-CreateSessionLive
-<COMMAND_INPUT>
-lttng --mi xml create mysession --live -U net://127.0.0.1
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>create</name>
-  <output>
-    <session>
-      <name>mysession</name>
-      <path>tcp4://127.0.0.1:5342/ [data: 5343]</path>
-      <enabled>false</enabled>
-      <snapshot_mode>0</snapshot_mode>
-      <live_timer_interval>1000000</live_timer_interval>
-    </session>
-  </output>
-  <success>true</success>
-</command>
-</COMMAND_OUTPUT>
-#------------------------------------------------------------------------------
-<COMMAND_INPUT>
-lttng --mi xml list
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>list</name>
-  <output>
-    <sessions>
-      <session>
-        <name>mysession</name>
-        <path>tcp4://127.0.0.1:5342/ [data: 5343]</path>
-        <enabled>false</enabled>
-        <snapshot_mode>0</snapshot_mode>
-        <live_timer_interval>1000000</live_timer_interval>
-      </session>
-    </sessions>
-  </output>
-</command>
-</COMMAND_OUTPUT>
-#------------------------------------------------------------------------------
-<COMMAND_INPUT>
-lttng --mi xml destroy mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>destroy</name>
-  <output>
-    <sessions>
-      <session>
-        <name>mysession</name>
-        <path>/home/user/lttng-traces/mysession-20140818-100114</path>
-        <enabled>false</enabled>
-        <snapshot_mode>0</snapshot_mode>
-        <live_timer_interval>0</live_timer_interval>
-      </session>
-    </sessions>
-  </output>
-  <success>true</success>
-</command>
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test errors for  "lttng create <session> --live [USEC] (LTTng 2.4)
-####################################################################
-<SCENARIO>
-CreateSessionLiveErrors
-<COMMAND_INPUT>
-lttng --mi xml create mysession --live --snapshot
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-1
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<COMMAND_ERROR_OUTPUT>
-Error: Snapshot and live modes are mutually exclusive.
-Error: Command error
-</COMMAND_ERROR_OUTPUT>
-</COMMAND_OUTPUT>
-#------------------------------------------------------------------------------
-<COMMAND_INPUT>
-lttng --mi xml create mysession --live -U blah
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-1
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<COMMAND_ERROR_OUTPUT>
-Error: URI parse unknown protocol blah
-Error: Unable to parse the URL blah
-Error: Invalid parameter
-</COMMAND_ERROR_OUTPUT>
-</COMMAND_OUTPUT>
-#------------------------------------------------------------------------------
-<COMMAND_INPUT>
-lttng --mi xml create mysession --live -C net://127.0.0.1
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-1
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<COMMAND_ERROR_OUTPUT>
-Error: You need both control and data URL.
-Error: Command error
-</COMMAND_ERROR_OUTPUT>
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test "lttng list <session> (version 2.6.0, syscalls)
-####################################################################
-<SCENARIO>
-GetSessionWithSyscalls
-<COMMAND_INPUT>
-lttng --mi xml list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<?xml version="1.0" encoding="UTF-8"?>
-<command>
-  <name>list</name>
-  <output>
-    <sessions>
-      <session>
-        <name>mysession</name>
-        <path>/home/user/lttng-traces/mysession-20120129-084256</path>
-        <enabled>false</enabled><snapshot_mode>0</snapshot_mode>
-        <live_timer_interval>0</live_timer_interval>
-        <domains>
-          <domain>
-            <type>KERNEL</type>
-            <buffer_type>PER_PID</buffer_type>
-            <channels>
-              <channel>
-                <name>channel0</name>
-                <enabled>true</enabled>
-                <attributes>
-                  <overwrite_mode>DISCARD</overwrite_mode>
-                  <subbuffer_size>262144</subbuffer_size>
-                  <subbuffer_count>4</subbuffer_count>
-                  <switch_timer_interval>0</switch_timer_interval>
-                  <read_timer_interval>200</read_timer_interval>
-                  <output_type>SPLICE</output_type>
-                  <tracefile_size>0</tracefile_size>
-                  <tracefile_count>0</tracefile_count>
-                  <live_timer_interval>0</live_timer_interval>
-                </attributes><events>
-                <event>
-                  <name>read</name>
-                  <type>SYSCALL</type>
-                  <enabled>true</enabled>
-                  <filter>false</filter>
-                </event>
-                <event>
-                  <name>write</name>
-                  <type>SYSCALL</type>
-                  <enabled>true</enabled>
-                  <filter>false</filter>
-                </event>
-              </events>
-            </channel>
-          </channels>
-        </domain></domains>
-      </session>
-    </sessions>
-  </output>
-</command>
-</COMMAND_OUTPUT>
-</SCENARIO>
diff --git a/org.eclipse.tracecompass.lttng2.control.ui.tests/testfiles/LTTngServiceTest.cfg b/org.eclipse.tracecompass.lttng2.control.ui.tests/testfiles/LTTngServiceTest.cfg
deleted file mode 100644 (file)
index 316d0de..0000000
+++ /dev/null
@@ -1,1578 +0,0 @@
-####################################################################
-# Copyright (c) 2012, 2015 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:
-#    Bernd Hufmann - Initial API and implementation
-####################################################################
-####################################################################
-# Scenario: Test lttng not installed
-####################################################################
-<SCENARIO>
-LttngNotInstalled
-<COMMAND_INPUT>
-lttng list
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-1
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<COMMAND_ERROR_OUTPUT>
-Command not found
-</COMMAND_ERROR_OUTPUT>
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test lttng version
-####################################################################
-<SCENARIO>
-LttngVersion
-<COMMAND_INPUT>
-lttng version
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-lttng version 2.1.0 - Basse Messe
-Web site: http://lttng.org/
-
-lttng is free software and under the GPL license and part LGPL
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test lttng version
-# output with prompt
-####################################################################
-<SCENARIO>
-LttngVersionWithPrompt
-<COMMAND_INPUT>
-lttng version
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Prompt> lttng version 2.0.0 - Annedd'ale
-Web site: http://lttng.org/
-
-lttng is free software and under the GPL license and part LGPL
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test lttng version (unsupported version)
-####################################################################
-<SCENARIO>
-LttngUnsupportedVersion
-<COMMAND_INPUT>
-lttng version
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-lttng version 200.0.0 - Annedd'ale
-Web site: http://lttng.org/
-
-lttng is free software and under the GPL license and part LGPL
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-
-####################################################################
-# Scenario: Test lttng version (noversion)
-####################################################################
-<SCENARIO>
-LttngNoVersion
-<COMMAND_INPUT>
-lttng version
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Web site: http://lttng.org/
-
-lttng is free software and under the GPL license and part LGPL
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test lttng version (compiled from source)
-####################################################################
-<SCENARIO>
-LttngVersionCompiled
-<COMMAND_INPUT>
-lttng version
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-lttng version heads/stable-2.5-0-g3910e60 - Fumisterie
-
-The Fumisterie is a beer whose style is at the confluence of English and German ales. On the palate, it is full-bodied, malty and slightly caramelized. The organic hemp seeds incorporated during the brewing gives it a unique and original taste. The hop flavour comes through delicately in the after taste.
-
-Web site: http://lttng.org
-
-lttng is free software and under the GPL license and part LGPL
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test no sessions available
-####################################################################
-<SCENARIO>
-NoSessionAvailable
-<COMMAND_INPUT>
-lttng list
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Currently no available tracing session
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test get sessions
-####################################################################
-<SCENARIO>
-GetSessionNames1
-<COMMAND_INPUT>
-lttng list
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Available tracing sessions:
-  1) mysession1 (/home/user/lttng-traces/mysession1-20120123-083928) [inactive]
-  2) mysession (/home/user/lttng-traces/mysession-20120123-083318) [inactive]
-
- Use lttng list <session_name> for more details
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test get sessions with tracing group
-####################################################################
-<SCENARIO>
-GetSessionWithTracingGroup
-<COMMAND_INPUT>
-lttng -g group list
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Available tracing sessions:
-  1) mysession1 (/home/user/lttng-traces/mysession1-20120123-083928) [inactive]
-  2) mysession (/home/user/lttng-traces/mysession-20120123-083318) [inactive]
-
- Use lttng list <session_name> for more details
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test lttng list <name> where session doesn't exist
-####################################################################
-<SCENARIO>
-GetSessionNameNotExist
-<COMMAND_INPUT>
-lttng list test
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-1
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Session test not found
-<COMMAND_ERROR_OUTPUT>
-Error: Session name not found
-</COMMAND_ERROR_OUTPUT>
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test lttng -vvv list <name> where session doesn't exist
-####################################################################
-<SCENARIO>
-GetSessionNameNotExistVerbose
-<COMMAND_INPUT>
-lttng -vvv list test
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-1
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-DEBUG2: Session name: test [in cmd_list() at commands/list.c:618]
-DEBUG1: Session count 1 [in list_sessions() at commands/list.c:485]
-<COMMAND_ERROR_OUTPUT>
-Error: Session 'test' not found
-Error: Command error
-</COMMAND_ERROR_OUTPUT>
-DEBUG1: Clean exit [in clean_exit() at lttng.c:165]
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test lttng list with garbage output
-####################################################################
-<SCENARIO>
-GetSessionGarbageOut
-<COMMAND_INPUT>
-lttng list
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-asdfaereafsdcv 12333456434&*89**(())(^%$*
-@#$%^&*()@#$%^&*()0834523094578kj;djkfs
-a;sdf094v5u dsafj;sd9
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test lttng list <name> with sample outputs
-####################################################################
-<SCENARIO>
-GetSession1
-<COMMAND_INPUT>
-lttng list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession: [active]
-    Trace path: /home/user/lttng-traces/mysession-20120129-084256
-
-=== Domain: Kernel ===
-
-Channels:
--------------
-- channel0: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 262144
-      number of subbufers: 4
-      switch timer interval: 0
-      read timer interval: 200
-      output: splice()
-
-    Events:
-      block_rq_remap (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      block_bio_remap (loglevel: TRACE_EMERG (0)) (type: tracepoint) [disabled]
-
-- channel1: [disabled]
-
-    Attributes:
-      overwrite mode: 1
-      subbufers size: 524288
-      number of subbufers: 4
-      switch timer interval: 100
-      read timer interval: 400
-      output: splice()
-
-    Events:
-      None
-
-=== Domain: UST global ===
-
-Channels:
--------------
-- mychannel1: [disabled]
-
-    Attributes:
-     overwrite mode: 1
-     subbufers size: 8192
-      number of subbufers: 8
-      switch timer interval: 200
-      read timer interval: 100
-      output: mmap()
-
-    Events:
-      None
-
-- channel0: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 4096
-      number of subbufers: 4
-      switch timer interval: 0
-      read timer interval: 200
-      output: mmap()
-
-    Events:
-      ust_tests_hello:tptest_sighandler (loglevel: TRACE_DEBUG_LINE (13)) (type: tracepoint) [disabled]
-      * (type: tracepoint) [enabled]
-
-</COMMAND_OUTPUT>
-<COMMAND_INPUT>
-lttng list mysession1
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession1: [inactive]
-    Trace path: /home/user/lttng-traces/mysession1-20120203-133225
-
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test lttng list <name> (with live time interval)
-####################################################################
-<SCENARIO>
-GetSessionWithLiveInterval
-<COMMAND_INPUT>
-lttng list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession: [inactive snapshot]
-    Trace path: 
-    Live timer interval (usec): 4294967295
-
-</COMMAND_OUTPUT>
-#------------------------------------------------------------------------------
-<COMMAND_INPUT>
-lttng snapshot list-output -s mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Snapshot output list for session mysession
-    [1] snapshot-1: /home/user/lttng-traces/mysession-20120129-084256 (max-size: 0)
-</COMMAND_OUTPUT>
-#------------------------------------------------------------------------------
-<COMMAND_INPUT>
-lttng list mysession1
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession1: [active]
-    Trace path: /home/user/lttng-traces/mysession1-20120129-084256
-    Live timer interval (usec): 0
-
-</COMMAND_OUTPUT>
-#------------------------------------------------------------------------------
-<COMMAND_INPUT>
-lttng list mysession2
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession2: [inactive]
-    Trace path: tcp4://172.0.0.1:5342/ [data: 5343]
-    Live timer interval (usec): 1000000
-
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test "lttng list -k" with sample output
-####################################################################
-<SCENARIO>
-GetKernelProvider1
-<COMMAND_INPUT>
-lttng list -k
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Kernel events
--------------
-      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint)
-      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint)
-      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint)
-
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test "lttng list -k" with no kernel and no session daemon
-####################################################################
-<SCENARIO>
-ListWithNoKernel1
-<COMMAND_INPUT>
-lttng list -k
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-1
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Spawning session daemon
-<COMMAND_ERROR_OUTPUT>
-Error: Unable to list kernel events
-</COMMAND_ERROR_OUTPUT>
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test "lttng list -k" with no kernel and with session daemon
-####################################################################
-<SCENARIO>
-ListWithNoKernel2
-<COMMAND_INPUT>
-lttng list -k
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-1
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<COMMAND_ERROR_OUTPUT>
-Error: Unable to list kernel events
-</COMMAND_ERROR_OUTPUT>
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test "lttng list -k" with no kernel, with session daemon and verbose
-####################################################################
-<SCENARIO>
-ListWithNoKernelVerbose
-<COMMAND_INPUT>
-lttng -vvv list -k
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-1
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-DEBUG2: Session name: (null) [in cmd_list() at commands/list.c:618]
-DEBUG1: Getting kernel tracing events [in list_kernel_events() at commands/list.c:309]
-<COMMAND_ERROR_OUTPUT>
-Error: Unable to list kernel events
-</COMMAND_ERROR_OUTPUT>
-DEBUG1: Clean exit [in clean_exit() at lttng.c:165]
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test "lttng list -u" with sample output
-####################################################################
-<SCENARIO>
-GetUstProvider1
-<COMMAND_INPUT>
-lttng list -u
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-UST events:
--------------
-
-PID: 9379 - Name: /home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello
-    ust_tests_hello:tptest_sighandler (loglevel: TRACE_DEBUG_MODULE (10)) (type: tracepoint)
-    ust_tests_hello:tptest (loglevel: TRACE_INFO (6)) (type: tracepoint)
-
-PID: 4852 - Name: /home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello
-    ust_tests_hello:tptest_sighandler (loglevel: TRACE_WARNING (4)) (type: tracepoint)
-    ust_tests_hello:tptest (loglevel: TRACE_DEBUG_FUNCTION (12)) (type: tracepoint)
-
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test "lttng list -u" with no UST provider available
-####################################################################
-<SCENARIO>
-GetUstProvider2
-<COMMAND_INPUT>
-lttng list -u
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-UST events:
--------------
-None
-
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test "lttng list -u" with no UST available (LTTng 2.0.x)
-####################################################################
-<SCENARIO>
-ListWithNoUst1
-<COMMAND_INPUT>
-lttng list -u
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-1
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-UST events:
--------------
-None
-Segmentation Fault
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test "lttng list -u" with no UST available and no session daemon
-####################################################################
-<SCENARIO>
-ListWithNoUst2
-<COMMAND_INPUT>
-lttng list -u -f
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-1
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Spawning a session daemon
-<COMMAND_ERROR_OUTPUT>
-Error: Unable to list UST events: Listing UST events failed
-Error: Command Error
-</COMMAND_ERROR_OUTPUT>
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test "lttng list -u" with no ust and with session daemon
-####################################################################
-<SCENARIO>
-ListWithNoUst3
-<COMMAND_INPUT>
-lttng list -u -f
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-1
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<COMMAND_ERROR_OUTPUT>
-Error: Unable to list UST events: Listing UST events failed
-Error: Command Error
-</COMMAND_ERROR_OUTPUT>
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test "lttng list -u" with no kernel, with session daemon and verbose
-####################################################################
-<SCENARIO>
-ListWithNoUstVerbose
-<COMMAND_INPUT>
-lttng -vvv list -u -f
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-1
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-DEBUG2: Session name: (null) [in cmd_list() at commands/list.c:618]
-DEBUG1: Getting kernel tracing events [in list_kernel_events() at commands/list.c:309]
-Spawning a session daemon
-<COMMAND_ERROR_OUTPUT>
-Error: Unable to list UST events: Listing UST events failed
-Error: Command Error
-</COMMAND_ERROR_OUTPUT>
-DEBUG1: Clean exit [in clean_exit() at lttng.c:165]
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-
-####################################################################
-# Scenario: Test "lttng list -u -f" with sample output (version 2.1.0)
-####################################################################
-<SCENARIO>
-GetUstProvider3
-<COMMAND_INPUT>
-lttng list -u -f
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-UST events:
--------------
-
-PID: 9379 - Name: /home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello
-    ust_tests_hello:tptest_sighandler (loglevel: TRACE_DEBUG_MODULE (10)) (type: tracepoint)
-    ust_tests_hello:tptest (loglevel: TRACE_INFO (6)) (type: tracepoint)
-        field: doublefield (float)
-        field: floatfield (float)
-        field: stringfield (string)
-
-PID: 4852 - Name: /home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello
-    ust_tests_hello:tptest_sighandler (loglevel: TRACE_WARNING (4)) (type: tracepoint)
-    ust_tests_hello:tptest (loglevel: TRACE_DEBUG_FUNCTION (12)) (type: tracepoint)
-        field: doublefield (float)
-        field: floatfield (float)
-        field: stringfield (string)
-
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-
-####################################################################
-# Scenario: Test "lttng create <session>
-####################################################################
-<SCENARIO>
-CreateSession1
-<COMMAND_INPUT>
-lttng create mysession2
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Session mysession2 created.
-Traces will be written in /home/user/lttng-traces/mysession2-20120209-095418
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test "lttng create <session>
-####################################################################
-<SCENARIO>
-CreateSessionWithPrompt
-<COMMAND_INPUT>
-lttng create mysession2
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Prompt> Session mysession2 created.
-Traces will be written in /home/user/lttng-traces/mysession2-20120209-095418
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test "lttng create <session> with different variants
-# and errors
-####################################################################
-<SCENARIO>
-CreateSessionVariants
-<COMMAND_INPUT>
-lttng create alreadyExist
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-1
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<COMMAND_ERROR_OUTPUT>
-Error: Session name already exist
-</COMMAND_ERROR_OUTPUT>
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng create session with spaces
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Session session with spaces created.
-Traces will be written in /home/user/lttng-traces/session with spaces-20120209-095418
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng create wrongName
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Session auto created.
-Traces will be written in /home/user/lttng-traces/auto-20120209-095418
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng create wrongPath -o /home/user/hallo
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Session wrongPath created.
-Traces will be written in /home/user/lttng-traces/wrongPath-20120209-095418
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng create pathWithSpaces -o /home/user/hallo user/here
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Session pathWithSpaces created.
-Traces will be written in /home/user/hallo user/here/pathWithSpaces-20120209-095418
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test "lttng destroy <session>
-####################################################################
-
-<SCENARIO>
-DestroySession1
-<COMMAND_INPUT>
-lttng destroy mysession2
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Session mysession2 destroyed.
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test "lttng -vvv destroy <session>"
-####################################################################
-
-<SCENARIO>
-DestroySessionVerbose
-<COMMAND_INPUT>
-lttng -vvv destroy mysession2
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-DEBUG2: Config file path found: /home/eedbhu [in get_session_name() at utils.c:98]
-DEBUG1: Session name found: mysession2 [in get_session_name() at utils.c:99]
-Session mysession2 destroyed at /home/eedbhu
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-
-####################################################################
-# Scenario: Test "lttng enable-channel ..." with different inputs
-####################################################################
-
-<SCENARIO>
-ChannelHandling
-<COMMAND_INPUT>
-lttng enable-channel mychannel0,mychannel1 -k -s mysession2 --overwrite --subbuf-size 16384 --num-subbuf 2 --switch-timer 200 --read-timer 100 -C 0 -W 10
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Kernel channel mychannel0 enabled for session mysession2
-Kernel channel mychannel1 enabled for session mysession2
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng enable-channel mychannel0,mychannel1 -k -s mysession2 --overwrite --subbuf-size 16384 --num-subbuf 2 --switch-timer 200 --read-timer 100
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Kernel channel mychannel0 enabled for session mysession2
-Kernel channel mychannel1 enabled for session mysession2
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng enable-channel ustChannel -u -s mysession2 --overwrite --subbuf-size 32768 --num-subbuf 1 --switch-timer 100 --read-timer 200 -C 0 -W 20
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-UST channel channel0 enabled for session mysession2
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng enable-channel ustChannel -u -s mysession2 --overwrite --subbuf-size 32768 --num-subbuf 1 --switch-timer 100 --read-timer 200
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-UST channel channel0 enabled for session mysession2
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng enable-channel ustChannel -u -s mysession2 --overwrite --subbuf-size 32768 --num-subbuf 1 --switch-timer 100 --read-timer 200 --buffers-uid -C 0 -W 20
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-UST channel channel0 enabled for session mysession2
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng enable-channel ustChannel -u -s mysession2 --overwrite --buffers-pid
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-UST channel ustChannel enabled for session mysession2
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng enable-channel ustChannel -u -s mysession2 --overwrite --subbuf-size 32768 --num-subbuf 1 --switch-timer 100 --read-timer 200 --buffers-uid
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-UST channel channel0 enabled for session mysession2
-</COMMAND_OUTPUT>
-
-
-<COMMAND_INPUT>
-lttng enable-channel mychannel0,mychannel1 -k -s mysession2
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Kernel channel mychannel0 enabled for session mysession2
-Kernel channel mychannel1 enabled for session mysession2
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng enable-channel ustChannel -u -s mysession2
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-UST channel mychannel0 enabled for session mysession2
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng disable-channel mychannel0,mychannel1 -k -s mysession2
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Kernel channel mychannel0 disabled for session mysession2
-Kernel channel mychannel1 disabled for session mysession2
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng disable-channel ustChannel -u -s mysession2
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-UST channel mychannel0 enabled for session mysession2
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-
-####################################################################
-# Scenario: Test "lttng enable-events ..." with different inputs
-####################################################################
-<SCENARIO>
-EventHandling
-
-# Tracepoint test cases
-
-<COMMAND_INPUT>
-lttng enable-event block_rq_remap,block_bio_remap,softirq_entry -k -s mysession2 --tracepoint
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-kernel event block_rq_remap created in channel channel0
-kernel event block_bio_remap created in channel channel0
-kernel event softirq_entry created in channel channel0
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng enable-event -a -k -s mysession2 -c mychannel --tracepoint
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-All kernel tracepoints are enabled in channel channel0
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng enable-event ust_tests_hello:tptest_sighandler -u -s mysession2 -c mychannel --tracepoint
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-UST event ust_tests_hello:tptest_sighandler created in channel mychannel
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng enable-event ust_tests_hello:tptest_sighandler -u -s mysession2 -c mychannel --tracepoint --filter intfield==10
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-UST event ust_tests_hello:tptest_sighandler created in channel mychannel
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng enable-event -a -u -s mysession2 -c mychannel --tracepoint
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-All UST tracepoints are enabled in channel mychannel
-</COMMAND_OUTPUT>
-
-# Syscall test cases
-
-<COMMAND_INPUT>
-lttng enable-event -a -k -s mysession2 --syscall
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-All kernel system calls are enabled in channel channel0
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng enable-event -a -k -s mysession2 -c mychannel --syscall
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-All kernel system calls are enabled in channel mychannel
-</COMMAND_OUTPUT>
-
-# dynamic probe/function probe test cases
-
-<COMMAND_INPUT>
-lttng enable-event myevent0 -k -s mysession2 --function 0xc0101340
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-kernel event myevent0 created in channel mychannel
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng enable-event myevent1 -k -s mysession2 -c mychannel --probe init_post
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-kernel event myevent1 created in channel mychannel
-</COMMAND_OUTPUT>
-
-# log level test cases
-
-<COMMAND_INPUT>
-lttng enable-event myevent4 -u -s mysession2 --loglevel-only TRACE_DEBUG
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-UST event myevent4 created in channel channel0
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng enable-event myevent5 -u -s mysession2 -c mychannel --loglevel TRACE_DEBUG_FUNCTION
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-UST event myevent5 created in channel mychannel
-</COMMAND_OUTPUT>
-
-</SCENARIO>
-
-####################################################################
-# Scenario: Test "lttng add-context -h" and lttng add-context ..." with different inputs
-####################################################################
-
-<SCENARIO>
-ContextHandling
-
-<COMMAND_INPUT>
-lttng add-context -h
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-usage: lttng add-context -t TYPE
-
-If no channel and no event is given (-c/-e), the context
-will be added to all events and all channels.
-Otherwise the context will be added only to the channel (-c)
-and/or event (-e) indicated.
-Exactly one domain (-k/--kernel or -u/--userspace) must be specified.
-
-Options:
-  -h, --help               Show this help
-      --list-options       Simple listing of options
-  -s, --session NAME       Apply to session name
-  -c, --channel NAME       Apply to channel
-  -e, --event NAME         Apply to event
-  -k, --kernel             Apply to the kernel tracer
-  -u, --userspace          Apply to the user-space tracer
-  -t, --type TYPE          Context type. You can repeat that option on
-                           the command line to specify multiple contexts at once.
-                           (--kernel preempts --userspace)
-                           TYPE can be one of the strings below:
-                               pid, procname, prio, nice, vpid, tid, pthread_id,
-                               vtid, ppid, vppid, perf:cpu-cycles, perf:cycles
-Example:
-This command will add the context information 'prio' and two perf
-counters (hardware branch misses and cache misses), to all events
-in the trace data output:
-# lttng add-context -k -t prio -t perf:branch-misses -t perf:cache-misses
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng add-context -s mysession2 -c mychannel -e ust_tests_hello:tptest_sighandler -u -t prio -t pid
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-UST context prio added to event ust_tests_hello:tptest_sighandle channel mychannel
-UST context pid added to event sched_kthread_stop_ret channel mychannel
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-<SCENARIO>
-ContextErrorHandling
-
-<COMMAND_INPUT>
-lttng add-context -h
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-1
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-usage: lttng add-context -t TYPE
-
-If no channel and no event is given (-c/-e), the context
-will be added to all events and all channels.
-Otherwise the context will be added only to the channel (-c)
-and/or event (-e) indicated.
-Exactly one domain (-k/--kernel or -u/--userspace) must be specified.
-
-Options:
-  -h, --help               Show this help
-      --list-options       Simple listing of options
-  -s, --session NAME       Apply to session name
-  -c, --channel NAME       Apply to channel
-  -e, --event NAME         Apply to event
-  -k, --kernel             Apply to the kernel tracer
-  -u, --userspace          Apply to the user-space tracer
-  -t, --type TYPE          Context type. You can repeat that option on
-                           the command line to specify multiple contexts at once.
-                           (--kernel preempts --userspace)
-                           TYPE can be one of the strings below:
-                               pid, procname, prio, nice, vpid, tid, pthread_id,
-                               vtid, ppid, vppid, perf:cpu-cycles, perf:cycles
-Example:
-This command will add the context information 'prio' and two perf
-counters (hardware branch misses and cache misses), to all events
-in the trace data output:
-# lttng add-context -k -t prio -t perf:branch-misses -t perf:cache-misses
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng add-context -s mysession2 -c mychannel -e ust_tests_hello:tptest_sighandler -u -t prio -t pid
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-1
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-UST context prio added to event ust_tests_hello:tptest_sighandle channel mychannel
-UST context pid added to event sched_kthread_stop_ret channel mychannel
-</COMMAND_OUTPUT>
-
-</SCENARIO>
-
-<SCENARIO>
-CalibrateHandling
-<COMMAND_INPUT>
-lttng calibrate -k --function
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Kernel calibration done
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng calibrate -u --function
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-1
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Kernel calibration done
-</COMMAND_OUTPUT>
-
-</SCENARIO>
-
-####################################################################
-# Scenario: Test "lttng create <session> with LTTng 2.1 options
-####################################################################
-<SCENARIO>
-CreateSessionLttng2.1
-
-<COMMAND_INPUT>
-lttng create mysession -U net://172.0.0.1
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Session mysession created.
-Traces will be written in net://172.0.0.1
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng create mysession -U file:///tmp
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Session mysession created.
-Traces will be written in file:///tmp
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng create mysession -C tcp://172.0.0.1 -D tcp://172.0.0.1:5343
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Session mysession created.
-Control URL tcp://172.0.0.1 set for session mysession
-Data URL tcp://172.0.0.1:5343 set for session mysession
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng create mysession -U net://172.0.0.1:1234:2345
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Session mysession created.
-Traces will be written in net://172.0.0.1:1234:2345
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng destroy mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Session mysession destroyed.
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng -vvv create mysession -U net://172.0.0.1
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-DEBUG3: URI string: net://172.0.0.1 [in uri_parse() at uri.c:253]
-DEBUG2: IP address resolved to 172.0.0.1 [in set_ip_address() at uri.c:132]
-DEBUG3: URI dtype: 1, proto: 1, host: 172.0.0.1, subdir: , ctrl: 0, data: 0 [in uri_parse() at uri.c:467]
-DEBUG1: LSM cmd type : 8 [in send_session_msg() at lttng-ctl.c:261]
-Session mysession created.
-Traces will be written in net://172.0.0.1
-DEBUG1: Init config session in /home/bernd [in config_init() at conf.c:294]
-</COMMAND_OUTPUT>
-
-</SCENARIO>
-
-####################################################################
-# Scenario: Test "lttng -vvv create <session> with LTTng 2.1 options"
-####################################################################
-<SCENARIO>
-CreateSessionLttngVerbose2.1
-<COMMAND_INPUT>
-lttng -vvv create mysession -U net://172.0.0.1
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-DEBUG3: URI string: net://172.0.0.1 [in uri_parse() at uri.c:253]
-DEBUG2: IP address resolved to 172.0.0.1 [in set_ip_address() at uri.c:132]
-DEBUG3: URI dtype: 1, proto: 1, host: 172.0.0.1, subdir: , ctrl: 0, data: 0 [in uri_parse() at uri.c:467]
-DEBUG1: LSM cmd type : 8 [in send_session_msg() at lttng-ctl.c:261]
-Session mysession created.
-Traces will be written in net://172.0.0.1
-DEBUG1: Init config session in /home/bernd [in config_init() at conf.c:294]
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng -vvv destroy mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Session mysession destroyed.
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test "lttng create <session> --snapshot (LTTng 2.3)
-####################################################################
-<SCENARIO>
-CreateSessionSnapshot
-<COMMAND_INPUT>
-lttng create mysession --snapshot
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Session mysession created.
-Default snapshot output set to: /home/user/lttng-traces/mysession-20130913-141651
-Snapshot mode set. Every channel enabled for that session will be set in overwrite mode and mmap output.
-</COMMAND_OUTPUT>
-#------------------------------------------------------------------------------
-<COMMAND_INPUT>
-lttng snapshot list-output -s mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Snapshot output list for session mysession
-    [1] snapshot-1: /home/user/lttng-traces/mysession-20130913-141651
-</COMMAND_OUTPUT>
-#------------------------------------------------------------------------------
-<COMMAND_INPUT>
-lttng list
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-  1) mysession () [inactive snapshot]
-
-</COMMAND_OUTPUT>
-#------------------------------------------------------------------------------
-<COMMAND_INPUT>
-lttng snapshot record -s mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-    Snapshot recorded successfully for session mysession
-</COMMAND_OUTPUT>
-#------------------------------------------------------------------------------
-<COMMAND_INPUT>
-lttng destroy mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Session mysession destroyed.
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test "lttng create <session> --snapshot -U <URL> (LTTng 2.3)
-####################################################################
-<SCENARIO>
-CreateSessionStreamedSnapshot
-<COMMAND_INPUT>
-lttng create mysession --snapshot -U net://172.0.0.1
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Session mysession created.
-Default snapshot output set to: net://172.0.0.1
-Snapshot mode set. Every channel enabled for that session will be set in overwrite mode and mmap output.
-</COMMAND_OUTPUT>
-#------------------------------------------------------------------------------
-<COMMAND_INPUT>
-lttng snapshot list-output -s mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Snapshot output list for session mysession
-    [2] snapshot-2: net4://172.0.0.1:5342/
-</COMMAND_OUTPUT>
-#------------------------------------------------------------------------------
-<COMMAND_INPUT>
-lttng list
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-  1) mysession () [inactive snapshot]
-
-</COMMAND_OUTPUT>
-#------------------------------------------------------------------------------
-<COMMAND_INPUT>
-lttng snapshot record -s mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-    Snapshot recorded successfully for session mysession
-</COMMAND_OUTPUT>
-#------------------------------------------------------------------------------
-<COMMAND_INPUT>
-lttng destroy mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Session mysession destroyed.
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test "lttng create <session> --snapshot (LTTng 2.3)
-####################################################################
-<SCENARIO>
-CreateSessionSnapshotErrors
-<COMMAND_INPUT>
-lttng snapshot list-output -s blabla
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-1
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<COMMAND_ERROR_OUTPUT>
-Error: Session name not found
-</COMMAND_ERROR_OUTPUT>
-</COMMAND_OUTPUT>
-#------------------------------------------------------------------------------
-#next is not an error case but good to be tested
-<COMMAND_INPUT>
-lttng list
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-  1) mysession () [active snapshot]
-
-</COMMAND_OUTPUT>
-#------------------------------------------------------------------------------
-<COMMAND_INPUT>
-lttng snapshot record -s blabla
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-1
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<COMMAND_ERROR_OUTPUT>
-    Error: Session name not found
-</COMMAND_ERROR_OUTPUT>
-</COMMAND_OUTPUT>
-#------------------------------------------------------------------------------
-<COMMAND_INPUT>
-lttng snapshot record -s mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-1
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<COMMAND_ERROR_OUTPUT>
-    Error: Session needs to be started once
-</COMMAND_ERROR_OUTPUT>
-</COMMAND_OUTPUT>
-
-</SCENARIO>
-
-####################################################################
-# Scenario: Test "lttng create <session> --live [USEC] (LTTng 2.4)
-####################################################################
-<SCENARIO>
-CreateSessionLive
-<COMMAND_INPUT>
-lttng create mysession --live -U net://127.0.0.1
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Session mysession created.
-Traces will be written in net://127.0.0.1
-Live timer set to 1000000 usec
-</COMMAND_OUTPUT>
-#------------------------------------------------------------------------------
-<COMMAND_INPUT>
-lttng list
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Available tracing sessions:
-  1) mysession (net4://127.0.0.1:5342/ [data: 5343]) [inactive]
-
-Use lttng list <session_name> for more details
-</COMMAND_OUTPUT>
-#------------------------------------------------------------------------------
-<COMMAND_INPUT>
-lttng destroy mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Session mysession destroyed.
-</COMMAND_OUTPUT>
-</SCENARIO>
-
-####################################################################
-# Scenario: Test errors for  "lttng create <session> --live [USEC] (LTTng 2.4)
-####################################################################
-<SCENARIO>
-CreateSessionLiveErrors
-<COMMAND_INPUT>
-lttng create mysession --live --snapshot
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-1
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<COMMAND_ERROR_OUTPUT>
-Error: Snapshot and live modes are mutually exclusive.
-Error: Command error
-</COMMAND_ERROR_OUTPUT>
-</COMMAND_OUTPUT>
-#------------------------------------------------------------------------------
-<COMMAND_INPUT>
-lttng create mysession --live -U blah
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-1
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<COMMAND_ERROR_OUTPUT>
-Error: URI parse unknown protocol blah
-Error: Unable to parse the URL blah
-Error: Invalid parameter
-</COMMAND_ERROR_OUTPUT>
-</COMMAND_OUTPUT>
-#------------------------------------------------------------------------------
-<COMMAND_INPUT>
-lttng create mysession --live -C net://127.0.0.1
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-1
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<COMMAND_ERROR_OUTPUT>
-Error: You need both control and data URL.
-Error: Command error
-</COMMAND_ERROR_OUTPUT>
-</COMMAND_OUTPUT>
-</SCENARIO>
-####################################################################
-# Scenario: Test "lttng create <session> --snapshot (LTTng 2.5)
-####################################################################
-<SCENARIO>
-CreateSessionSnapshot2.5
-<COMMAND_INPUT>
-lttng create mysession --snapshot
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Session mysession created.
-Default snapshot output set to: /home/user/lttng-traces/mysession-20130913-141651
-Snapshot mode set. Every channel enabled for that session will be set in overwrite mode and mmap output.
-</COMMAND_OUTPUT>
-#------------------------------------------------------------------------------
-<COMMAND_INPUT>
-lttng snapshot list-output -s mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Snapshot output list for session mysession
-    [1] snapshot-1: /home/user/lttng-traces/mysession-20130913-141651 (max-size: 0)
-</COMMAND_OUTPUT>
-#------------------------------------------------------------------------------
-<COMMAND_INPUT>
-lttng list
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-  1) mysession () [inactive snapshot]
-
-</COMMAND_OUTPUT>
-#------------------------------------------------------------------------------
-<COMMAND_INPUT>
-lttng snapshot record -s mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-    Snapshot recorded successfully for session mysession
-</COMMAND_OUTPUT>
-#------------------------------------------------------------------------------
-<COMMAND_INPUT>
-lttng destroy mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Session mysession destroyed.
-</COMMAND_OUTPUT>
-</SCENARIO>
diff --git a/org.eclipse.tracecompass.lttng2.control.ui.tests/testfiles/ListInfoTest.cfg b/org.eclipse.tracecompass.lttng2.control.ui.tests/testfiles/ListInfoTest.cfg
deleted file mode 100644 (file)
index 95d3b52..0000000
+++ /dev/null
@@ -1,244 +0,0 @@
-####################################################################
-# Copyright (c) 2012, 2015 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:
-#    Bernd Hufmann - Initial API and implementation
-####################################################################
-####################################################################
-# Scenario: Test lttng list <name> with sample outputs
-####################################################################
-<SCENARIO>
-ListInfoTest
-
-<COMMAND_INPUT>
-lttng version
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-lttng version 2.5.0 - 20120129-084256
-Web site: http://lttng.org/
-
-lttng is free software and under the GPL license and part LGPL
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Available tracing sessions:
-  1) mysession1 (/home/user/lttng-traces/mysession1-20120123-083928) [inactive]
-  2) mysession (/home/user/lttng-traces/mysession-20120123-083318) [inactive]
-
- Use lttng list <session_name> for more details
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list mysession
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession: [active]
-    Trace path: /home/user/lttng-traces/mysession-20120129-084256
-
-=== Domain: Kernel ===
-
-Channels:
--------------
-- channel0: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 262144
-      number of subbufers: 4
-      switch timer interval: 0
-      read timer interval: 200
-      trace file count: 2
-      trace file size (bytes): 262144
-      output: splice()
-
-    Events:
-      block_rq_remap (loglevel: TRACE_EMERG (0)) (type: tracepoint) [enabled]
-      block_bio_remap (loglevel: TRACE_EMERG (0)) (type: tracepoint) [disabled]
-      myevent2 (type: probe) [enabled]
-        addr: 0xc0101340
-      myevent0 (type: probe) [enabled]
-        offset: 0x0
-        symbol: init_post
-      syscalls (type: syscall) [enabled]
-
-- channel1: [disabled]
-
-    Attributes:
-      overwrite mode: 1
-      subbufers size: 524288
-      number of subbufers: 4
-      switch timer interval: 100
-      read timer interval: 400
-      output: splice()
-
-    Events:
-      None
-
-=== Domain: UST global ===
-
-Channels:
--------------
-- mychannel1: [disabled]
-
-    Attributes:
-     overwrite mode: 1
-     subbufers size: 8192
-      number of subbufers: 8
-      switch timer interval: 200
-      read timer interval: 100
-      trace file count: 2
-      trace file size (bytes): 8192
-      output: mmap()
-
-    Events:
-      None
-
-- channel0: [enabled]
-
-    Attributes:
-      overwrite mode: 0
-      subbufers size: 4096
-      number of subbufers: 4
-      switch timer interval: 0
-      read timer interval: 200
-      output: mmap()
-
-    Events:
-      ust_tests_hello:tptest_sighandler (loglevel == TRACE_DEBUG_LINE (13)) (type: tracepoint) [disabled] [with filter]
-      ust_tests_hello:tptest_sighandler1 (loglevel <= TRACE_INFO (7)) (type: tracepoint) [disabled] [with filter]
-      ust_tests_hello:tptest_sighandler2 (loglevel: TRACE_DEBUG_SYSTEM (8)) (type: tracepoint) [disabled] [with filter]
-      * (type: tracepoint) [enabled]
-
-</COMMAND_OUTPUT>
-<COMMAND_INPUT>
-lttng list mysession1
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Tracing session mysession1: [inactive]
-    Trace path: /home/user/lttng-traces/mysession1-20120203-133225
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list -k
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Kernel events
--------------
-      sched_kthread_stop (loglevel: TRACE_EMERG (0)) (type: tracepoint)
-      sched_kthread_stop_ret (loglevel: TRACE_EMERG (0)) (type: tracepoint)
-      sched_wakeup_new (loglevel: TRACE_EMERG (0)) (type: tracepoint)
-
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list -u -f
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-UST events:
--------------
-
-PID: 9379 - Name: /home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello
-    ust_tests_hello:tptest_sighandler (loglevel: TRACE_DEBUG_MODULE (10)) (type: tracepoint)
-    ust_tests_hello:tptest (loglevel: TRACE_INFO (6)) (type: tracepoint)
-        field: doublefield (float)
-        field: floatfield (float)
-        field: stringfield (string)
-
-PID: 4852 - Name: /home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello
-    ust_tests_hello:tptest_sighandler (loglevel: TRACE_WARNING (4)) (type: tracepoint)
-    ust_tests_hello:tptest (loglevel: TRACE_DEBUG_FUNCTION (12)) (type: tracepoint)
-        field: doublefield (float)
-        field: floatfield (float)
-        field: stringfield (string)
-
-</COMMAND_OUTPUT>
-
-</SCENARIO>
-
-
-####################################################################
-# Scenario: Test "lttng list -k" with no kernel and no session daemon
-####################################################################
-<SCENARIO>
-ListInfoTestNoKernel
-
-<COMMAND_INPUT>
-lttng version
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-lttng version 2.0.0 - Annedd'ale
-Web site: http://lttng.org/
-
-lttng is free software and under the GPL license and part LGPL
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-Currently no available tracing session
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list -k
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-1
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-<COMMAND_ERROR_OUTPUT>
-Error: Unable to list kernel events
-</COMMAND_ERROR_OUTPUT>
-</COMMAND_OUTPUT>
-
-<COMMAND_INPUT>
-lttng list -u
-</COMMAND_INPUT>
-<COMMAND_RESULT>
-0
-</COMMAND_RESULT>
-<COMMAND_OUTPUT>
-UST events:
--------------
-
-PID: 9379 - Name: /home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello
-    ust_tests_hello:tptest_sighandler (loglevel: TRACE_DEBUG_MODULE (10)) (type: tracepoint)
-    ust_tests_hello:tptest (loglevel: TRACE_INFO (6)) (type: tracepoint)
-
-</COMMAND_OUTPUT>
-
-</SCENARIO>
-
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/.classpath b/org.eclipse.tracecompass.lttng2.control.ui/.classpath
deleted file mode 100644 (file)
index 098194c..0000000
+++ /dev/null
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
-       <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7"/>
-       <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
-       <classpathentry kind="src" path="src"/>
-       <classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/.project b/org.eclipse.tracecompass.lttng2.control.ui/.project
deleted file mode 100644 (file)
index 9988dea..0000000
+++ /dev/null
@@ -1,34 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
-       <name>org.eclipse.tracecompass.lttng2.control.ui</name>
-       <comment></comment>
-       <projects>
-       </projects>
-       <buildSpec>
-               <buildCommand>
-                       <name>org.eclipse.jdt.core.javabuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-               <buildCommand>
-                       <name>org.eclipse.pde.ManifestBuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-               <buildCommand>
-                       <name>org.eclipse.pde.SchemaBuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-               <buildCommand>
-                       <name>org.eclipse.pde.api.tools.apiAnalysisBuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-       </buildSpec>
-       <natures>
-               <nature>org.eclipse.pde.PluginNature</nature>
-               <nature>org.eclipse.jdt.core.javanature</nature>
-               <nature>org.eclipse.pde.api.tools.apiAnalysisNature</nature>
-       </natures>
-</projectDescription>
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/.settings/org.eclipse.core.resources.prefs b/org.eclipse.tracecompass.lttng2.control.ui/.settings/org.eclipse.core.resources.prefs
deleted file mode 100644 (file)
index 99f26c0..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-eclipse.preferences.version=1
-encoding/<project>=UTF-8
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/.settings/org.eclipse.core.runtime.prefs b/org.eclipse.tracecompass.lttng2.control.ui/.settings/org.eclipse.core.runtime.prefs
deleted file mode 100644 (file)
index 5a0ad22..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-eclipse.preferences.version=1
-line.separator=\n
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/.settings/org.eclipse.jdt.core.prefs b/org.eclipse.tracecompass.lttng2.control.ui/.settings/org.eclipse.jdt.core.prefs
deleted file mode 100644 (file)
index a2b5e6b..0000000
+++ /dev/null
@@ -1,405 +0,0 @@
-eclipse.preferences.version=1
-org.eclipse.jdt.core.codeComplete.argumentPrefixes=
-org.eclipse.jdt.core.codeComplete.argumentSuffixes=
-org.eclipse.jdt.core.codeComplete.fieldPrefixes=f
-org.eclipse.jdt.core.codeComplete.fieldSuffixes=
-org.eclipse.jdt.core.codeComplete.localPrefixes=
-org.eclipse.jdt.core.codeComplete.localSuffixes=
-org.eclipse.jdt.core.codeComplete.staticFieldPrefixes=
-org.eclipse.jdt.core.codeComplete.staticFieldSuffixes=
-org.eclipse.jdt.core.codeComplete.staticFinalFieldPrefixes=
-org.eclipse.jdt.core.codeComplete.staticFinalFieldSuffixes=
-org.eclipse.jdt.core.compiler.annotation.inheritNullAnnotations=enabled
-org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore
-org.eclipse.jdt.core.compiler.annotation.nonnull=org.eclipse.jdt.annotation.NonNull
-org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=org.eclipse.jdt.annotation.NonNullByDefault
-org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nullable
-org.eclipse.jdt.core.compiler.annotation.nullanalysis=enabled
-org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
-org.eclipse.jdt.core.compiler.codegen.methodParameters=do not generate
-org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
-org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
-org.eclipse.jdt.core.compiler.compliance=1.7
-org.eclipse.jdt.core.compiler.debug.lineNumber=generate
-org.eclipse.jdt.core.compiler.debug.localVariable=generate
-org.eclipse.jdt.core.compiler.debug.sourceFile=generate
-org.eclipse.jdt.core.compiler.doc.comment.support=enabled
-org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=error
-org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
-org.eclipse.jdt.core.compiler.problem.autoboxing=ignore
-org.eclipse.jdt.core.compiler.problem.comparingIdentical=error
-org.eclipse.jdt.core.compiler.problem.deadCode=error
-org.eclipse.jdt.core.compiler.problem.deprecation=error
-org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled
-org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=enabled
-org.eclipse.jdt.core.compiler.problem.discouragedReference=warning
-org.eclipse.jdt.core.compiler.problem.emptyStatement=error
-org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
-org.eclipse.jdt.core.compiler.problem.explicitlyClosedAutoCloseable=error
-org.eclipse.jdt.core.compiler.problem.fallthroughCase=error
-org.eclipse.jdt.core.compiler.problem.fatalOptionalError=disabled
-org.eclipse.jdt.core.compiler.problem.fieldHiding=error
-org.eclipse.jdt.core.compiler.problem.finalParameterBound=error
-org.eclipse.jdt.core.compiler.problem.finallyBlockNotCompletingNormally=error
-org.eclipse.jdt.core.compiler.problem.forbiddenReference=error
-org.eclipse.jdt.core.compiler.problem.hiddenCatchBlock=error
-org.eclipse.jdt.core.compiler.problem.includeNullInfoFromAsserts=disabled
-org.eclipse.jdt.core.compiler.problem.incompatibleNonInheritedInterfaceMethod=error
-org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch=error
-org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=error
-org.eclipse.jdt.core.compiler.problem.invalidJavadoc=warning
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTags=enabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsDeprecatedRef=enabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsNotVisibleRef=enabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsVisibility=protected
-org.eclipse.jdt.core.compiler.problem.localVariableHiding=error
-org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=error
-org.eclipse.jdt.core.compiler.problem.missingDefaultCase=error
-org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=error
-org.eclipse.jdt.core.compiler.problem.missingEnumCaseDespiteDefault=enabled
-org.eclipse.jdt.core.compiler.problem.missingHashCodeMethod=error
-org.eclipse.jdt.core.compiler.problem.missingJavadocComments=warning
-org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsOverriding=disabled
-org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsVisibility=protected
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagDescription=all_standard_tags
-org.eclipse.jdt.core.compiler.problem.missingJavadocTags=warning
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagsMethodTypeParameters=disabled
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagsOverriding=disabled
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagsVisibility=protected
-org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotation=error
-org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotationForInterfaceMethodImplementation=enabled
-org.eclipse.jdt.core.compiler.problem.missingSerialVersion=error
-org.eclipse.jdt.core.compiler.problem.missingSynchronizedOnInheritedMethod=error
-org.eclipse.jdt.core.compiler.problem.noEffectAssignment=error
-org.eclipse.jdt.core.compiler.problem.noImplicitStringConversion=error
-org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=warning
-org.eclipse.jdt.core.compiler.problem.nonnullParameterAnnotationDropped=warning
-org.eclipse.jdt.core.compiler.problem.nullAnnotationInferenceConflict=warning
-org.eclipse.jdt.core.compiler.problem.nullReference=error
-org.eclipse.jdt.core.compiler.problem.nullSpecViolation=error
-org.eclipse.jdt.core.compiler.problem.nullUncheckedConversion=warning
-org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=error
-org.eclipse.jdt.core.compiler.problem.parameterAssignment=error
-org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=error
-org.eclipse.jdt.core.compiler.problem.potentialNullReference=error
-org.eclipse.jdt.core.compiler.problem.potentiallyUnclosedCloseable=warning
-org.eclipse.jdt.core.compiler.problem.rawTypeReference=warning
-org.eclipse.jdt.core.compiler.problem.redundantNullAnnotation=warning
-org.eclipse.jdt.core.compiler.problem.redundantNullCheck=error
-org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=error
-org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=error
-org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore
-org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=error
-org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled
-org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=error
-org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=disabled
-org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled
-org.eclipse.jdt.core.compiler.problem.syntacticNullAnalysisForFields=enabled
-org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=ignore
-org.eclipse.jdt.core.compiler.problem.typeParameterHiding=error
-org.eclipse.jdt.core.compiler.problem.unavoidableGenericTypeProblems=disabled
-org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=warning
-org.eclipse.jdt.core.compiler.problem.unclosedCloseable=error
-org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=ignore
-org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=error
-org.eclipse.jdt.core.compiler.problem.unnecessaryElse=error
-org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=error
-org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=warning
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionExemptExceptionAndThrowable=disabled
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionIncludeDocCommentReference=disabled
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverriding=disabled
-org.eclipse.jdt.core.compiler.problem.unusedExceptionParameter=ignore
-org.eclipse.jdt.core.compiler.problem.unusedImport=error
-org.eclipse.jdt.core.compiler.problem.unusedLabel=error
-org.eclipse.jdt.core.compiler.problem.unusedLocal=error
-org.eclipse.jdt.core.compiler.problem.unusedObjectAllocation=ignore
-org.eclipse.jdt.core.compiler.problem.unusedParameter=error
-org.eclipse.jdt.core.compiler.problem.unusedParameterIncludeDocCommentReference=enabled
-org.eclipse.jdt.core.compiler.problem.unusedParameterWhenImplementingAbstract=disabled
-org.eclipse.jdt.core.compiler.problem.unusedParameterWhenOverridingConcrete=disabled
-org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=error
-org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=error
-org.eclipse.jdt.core.compiler.problem.unusedWarningToken=error
-org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=error
-org.eclipse.jdt.core.compiler.source=1.7
-org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_call=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression=16
-org.eclipse.jdt.core.formatter.alignment_for_assignment=0
-org.eclipse.jdt.core.formatter.alignment_for_binary_expression=16
-org.eclipse.jdt.core.formatter.alignment_for_compact_if=16
-org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=80
-org.eclipse.jdt.core.formatter.alignment_for_enum_constants=0
-org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=16
-org.eclipse.jdt.core.formatter.alignment_for_method_declaration=0
-org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16
-org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=80
-org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation=0
-org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_constructor_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_method_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_union_type_in_multicatch=16
-org.eclipse.jdt.core.formatter.blank_lines_after_imports=1
-org.eclipse.jdt.core.formatter.blank_lines_after_package=1
-org.eclipse.jdt.core.formatter.blank_lines_before_field=0
-org.eclipse.jdt.core.formatter.blank_lines_before_first_class_body_declaration=0
-org.eclipse.jdt.core.formatter.blank_lines_before_imports=1
-org.eclipse.jdt.core.formatter.blank_lines_before_member_type=1
-org.eclipse.jdt.core.formatter.blank_lines_before_method=1
-org.eclipse.jdt.core.formatter.blank_lines_before_new_chunk=1
-org.eclipse.jdt.core.formatter.blank_lines_before_package=0
-org.eclipse.jdt.core.formatter.blank_lines_between_import_groups=1
-org.eclipse.jdt.core.formatter.blank_lines_between_type_declarations=1
-org.eclipse.jdt.core.formatter.brace_position_for_annotation_type_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_array_initializer=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_block=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_block_in_case=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_constructor_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_enum_constant=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_enum_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_method_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_switch=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_type_declaration=end_of_line
-org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_block_comment=false
-org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_javadoc_comment=false
-org.eclipse.jdt.core.formatter.comment.format_block_comments=true
-org.eclipse.jdt.core.formatter.comment.format_header=false
-org.eclipse.jdt.core.formatter.comment.format_html=true
-org.eclipse.jdt.core.formatter.comment.format_javadoc_comments=true
-org.eclipse.jdt.core.formatter.comment.format_line_comments=true
-org.eclipse.jdt.core.formatter.comment.format_source_code=true
-org.eclipse.jdt.core.formatter.comment.indent_parameter_description=true
-org.eclipse.jdt.core.formatter.comment.indent_root_tags=true
-org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags=insert
-org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter=insert
-org.eclipse.jdt.core.formatter.comment.line_length=80
-org.eclipse.jdt.core.formatter.comment.new_lines_at_block_boundaries=true
-org.eclipse.jdt.core.formatter.comment.new_lines_at_javadoc_boundaries=true
-org.eclipse.jdt.core.formatter.comment.preserve_white_space_between_code_and_line_comments=false
-org.eclipse.jdt.core.formatter.compact_else_if=true
-org.eclipse.jdt.core.formatter.continuation_indentation=2
-org.eclipse.jdt.core.formatter.continuation_indentation_for_array_initializer=2
-org.eclipse.jdt.core.formatter.disabling_tag=@formatter\:off
-org.eclipse.jdt.core.formatter.enabling_tag=@formatter\:on
-org.eclipse.jdt.core.formatter.format_guardian_clause_on_one_line=false
-org.eclipse.jdt.core.formatter.format_line_comment_starting_on_first_column=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_annotation_declaration_header=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_constant_header=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_declaration_header=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_type_header=true
-org.eclipse.jdt.core.formatter.indent_breaks_compare_to_cases=true
-org.eclipse.jdt.core.formatter.indent_empty_lines=false
-org.eclipse.jdt.core.formatter.indent_statements_compare_to_block=true
-org.eclipse.jdt.core.formatter.indent_statements_compare_to_body=true
-org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_cases=true
-org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_switch=false
-org.eclipse.jdt.core.formatter.indentation.size=4
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_field=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_local_variable=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_method=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_package=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_parameter=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_type=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_label=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_opening_brace_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_at_end_of_file_if_missing=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_finally_in_try_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_while_in_do_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_annotation_declaration=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_anonymous_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_block=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter=insert
-org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_binary_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_paren_in_cast=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_assert=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_case=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_labeled_statement=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_allocation_expression=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_annotation=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_throws=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_constant_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_declarations=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_explicitconstructorcall_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_increments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_inits=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_throws=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_invocation_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_field_declarations=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_local_declarations=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_parameterized_type_reference=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_superinterfaces=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_ellipsis=insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_brace_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_cast=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_catch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_for=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_if=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_parenthesized_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_switch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_synchronized=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_try=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_while=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_try_resources=insert
-org.eclipse.jdt.core.formatter.insert_space_after_unary_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter=insert
-org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_binary_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_brace_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_cast=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_catch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_for=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_if=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_parenthesized_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_switch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_synchronized=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_try=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_while=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_assert=insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_case=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_default=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_labeled_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_throws=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_constant_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_declarations=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_explicitconstructorcall_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_increments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_inits=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_throws=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_invocation_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_field_declarations=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_local_declarations=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_superinterfaces=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_ellipsis=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_annotation_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_anonymous_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_block=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_constructor_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_constant=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_method_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_switch=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation_type_member_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_catch=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_if=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_parenthesized_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_switch=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_synchronized=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_try=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_while=insert
-org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_return=insert
-org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_throw=insert
-org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_semicolon=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_try_resources=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_unary_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_brackets_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_annotation_type_member_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.join_lines_in_comments=true
-org.eclipse.jdt.core.formatter.join_wrapped_lines=false
-org.eclipse.jdt.core.formatter.keep_else_statement_on_same_line=false
-org.eclipse.jdt.core.formatter.keep_empty_array_initializer_on_one_line=false
-org.eclipse.jdt.core.formatter.keep_imple_if_on_one_line=false
-org.eclipse.jdt.core.formatter.keep_then_statement_on_same_line=false
-org.eclipse.jdt.core.formatter.lineSplit=250
-org.eclipse.jdt.core.formatter.never_indent_block_comments_on_first_column=false
-org.eclipse.jdt.core.formatter.never_indent_line_comments_on_first_column=false
-org.eclipse.jdt.core.formatter.number_of_blank_lines_at_beginning_of_method_body=0
-org.eclipse.jdt.core.formatter.number_of_empty_lines_to_preserve=1
-org.eclipse.jdt.core.formatter.put_empty_statement_on_new_line=true
-org.eclipse.jdt.core.formatter.tabulation.char=space
-org.eclipse.jdt.core.formatter.tabulation.size=4
-org.eclipse.jdt.core.formatter.use_on_off_tags=false
-org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false
-org.eclipse.jdt.core.formatter.wrap_before_binary_operator=true
-org.eclipse.jdt.core.formatter.wrap_before_or_operator_multicatch=true
-org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/.settings/org.eclipse.jdt.ui.prefs b/org.eclipse.tracecompass.lttng2.control.ui/.settings/org.eclipse.jdt.ui.prefs
deleted file mode 100644 (file)
index 232a3fd..0000000
+++ /dev/null
@@ -1,60 +0,0 @@
-eclipse.preferences.version=1
-editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true
-formatter_profile=_tmf-style
-formatter_settings_version=12
-org.eclipse.jdt.ui.exception.name=e
-org.eclipse.jdt.ui.gettersetter.use.is=true
-org.eclipse.jdt.ui.keywordthis=false
-org.eclipse.jdt.ui.overrideannotation=true
-sp_cleanup.add_default_serial_version_id=true
-sp_cleanup.add_generated_serial_version_id=false
-sp_cleanup.add_missing_annotations=false
-sp_cleanup.add_missing_deprecated_annotations=true
-sp_cleanup.add_missing_methods=false
-sp_cleanup.add_missing_nls_tags=false
-sp_cleanup.add_missing_override_annotations=true
-sp_cleanup.add_missing_override_annotations_interface_methods=true
-sp_cleanup.add_serial_version_id=false
-sp_cleanup.always_use_blocks=true
-sp_cleanup.always_use_parentheses_in_expressions=false
-sp_cleanup.always_use_this_for_non_static_field_access=false
-sp_cleanup.always_use_this_for_non_static_method_access=false
-sp_cleanup.convert_to_enhanced_for_loop=false
-sp_cleanup.correct_indentation=false
-sp_cleanup.format_source_code=false
-sp_cleanup.format_source_code_changes_only=false
-sp_cleanup.make_local_variable_final=false
-sp_cleanup.make_parameters_final=false
-sp_cleanup.make_private_fields_final=true
-sp_cleanup.make_type_abstract_if_missing_method=false
-sp_cleanup.make_variable_declarations_final=false
-sp_cleanup.never_use_blocks=false
-sp_cleanup.never_use_parentheses_in_expressions=true
-sp_cleanup.on_save_use_additional_actions=true
-sp_cleanup.organize_imports=false
-sp_cleanup.qualify_static_field_accesses_with_declaring_class=false
-sp_cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=true
-sp_cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=true
-sp_cleanup.qualify_static_member_accesses_with_declaring_class=false
-sp_cleanup.qualify_static_method_accesses_with_declaring_class=false
-sp_cleanup.remove_private_constructors=true
-sp_cleanup.remove_trailing_whitespaces=true
-sp_cleanup.remove_trailing_whitespaces_all=true
-sp_cleanup.remove_trailing_whitespaces_ignore_empty=false
-sp_cleanup.remove_unnecessary_casts=false
-sp_cleanup.remove_unnecessary_nls_tags=false
-sp_cleanup.remove_unused_imports=false
-sp_cleanup.remove_unused_local_variables=false
-sp_cleanup.remove_unused_private_fields=true
-sp_cleanup.remove_unused_private_members=false
-sp_cleanup.remove_unused_private_methods=true
-sp_cleanup.remove_unused_private_types=true
-sp_cleanup.sort_members=false
-sp_cleanup.sort_members_all=false
-sp_cleanup.use_blocks=true
-sp_cleanup.use_blocks_only_for_return_and_throw=false
-sp_cleanup.use_parentheses_in_expressions=false
-sp_cleanup.use_this_for_non_static_field_access=false
-sp_cleanup.use_this_for_non_static_field_access_only_if_necessary=true
-sp_cleanup.use_this_for_non_static_method_access=false
-sp_cleanup.use_this_for_non_static_method_access_only_if_necessary=true
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/.settings/org.eclipse.pde.api.tools.prefs b/org.eclipse.tracecompass.lttng2.control.ui/.settings/org.eclipse.pde.api.tools.prefs
deleted file mode 100644 (file)
index acc3abd..0000000
+++ /dev/null
@@ -1,97 +0,0 @@
-ANNOTATION_ELEMENT_TYPE_ADDED_METHOD_WITHOUT_DEFAULT_VALUE=Error
-ANNOTATION_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-ANNOTATION_ELEMENT_TYPE_REMOVED_FIELD=Error
-ANNOTATION_ELEMENT_TYPE_REMOVED_METHOD=Error
-ANNOTATION_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_API_TYPE=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_API_TYPE=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_TYPE=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_TYPE=Error
-API_USE_SCAN_FIELD_SEVERITY=Error
-API_USE_SCAN_METHOD_SEVERITY=Error
-API_USE_SCAN_TYPE_SEVERITY=Error
-CLASS_ELEMENT_TYPE_ADDED_METHOD=Error
-CLASS_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
-CLASS_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-CLASS_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
-CLASS_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-CLASS_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
-CLASS_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
-CLASS_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-CLASS_ELEMENT_TYPE_REMOVED_CONSTRUCTOR=Error
-CLASS_ELEMENT_TYPE_REMOVED_FIELD=Error
-CLASS_ELEMENT_TYPE_REMOVED_METHOD=Error
-CLASS_ELEMENT_TYPE_REMOVED_SUPERCLASS=Error
-CLASS_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-CLASS_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-CONSTRUCTOR_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-CONSTRUCTOR_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-CONSTRUCTOR_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
-CONSTRUCTOR_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-ENUM_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
-ENUM_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-ENUM_ELEMENT_TYPE_REMOVED_ENUM_CONSTANT=Error
-ENUM_ELEMENT_TYPE_REMOVED_FIELD=Error
-ENUM_ELEMENT_TYPE_REMOVED_METHOD=Error
-ENUM_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-FIELD_ELEMENT_TYPE_ADDED_VALUE=Error
-FIELD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-FIELD_ELEMENT_TYPE_CHANGED_FINAL_TO_NON_FINAL_STATIC_CONSTANT=Error
-FIELD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
-FIELD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
-FIELD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
-FIELD_ELEMENT_TYPE_CHANGED_TYPE=Error
-FIELD_ELEMENT_TYPE_CHANGED_VALUE=Error
-FIELD_ELEMENT_TYPE_REMOVED_TYPE_ARGUMENT=Error
-FIELD_ELEMENT_TYPE_REMOVED_VALUE=Error
-ILLEGAL_EXTEND=Warning
-ILLEGAL_IMPLEMENT=Warning
-ILLEGAL_INSTANTIATE=Warning
-ILLEGAL_OVERRIDE=Warning
-ILLEGAL_REFERENCE=Warning
-INTERFACE_ELEMENT_TYPE_ADDED_FIELD=Error
-INTERFACE_ELEMENT_TYPE_ADDED_METHOD=Error
-INTERFACE_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
-INTERFACE_ELEMENT_TYPE_ADDED_SUPER_INTERFACE_WITH_METHODS=Error
-INTERFACE_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-INTERFACE_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
-INTERFACE_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_FIELD=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_METHOD=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-INVALID_JAVADOC_TAG=Warning
-INVALID_REFERENCE_IN_SYSTEM_LIBRARIES=Warning
-LEAK_EXTEND=Warning
-LEAK_FIELD_DECL=Warning
-LEAK_IMPLEMENT=Warning
-LEAK_METHOD_PARAM=Warning
-LEAK_METHOD_RETURN_TYPE=Warning
-METHOD_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
-METHOD_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-METHOD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-METHOD_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
-METHOD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
-METHOD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
-METHOD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
-METHOD_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
-METHOD_ELEMENT_TYPE_REMOVED_ANNOTATION_DEFAULT_VALUE=Error
-METHOD_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-MISSING_EE_DESCRIPTIONS=Ignore
-TYPE_PARAMETER_ELEMENT_TYPE_ADDED_CLASS_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_ADDED_INTERFACE_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_CLASS_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_INTERFACE_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_CLASS_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_INTERFACE_BOUND=Error
-UNUSED_PROBLEM_FILTERS=Warning
-automatically_removed_unused_problem_filters=false
-eclipse.preferences.version=1
-incompatible_api_component_version=Error
-incompatible_api_component_version_include_major_without_breaking_change=Disabled
-incompatible_api_component_version_include_minor_without_api_change=Disabled
-invalid_since_tag_version=Error
-malformed_since_tag=Error
-missing_since_tag=Error
-report_api_breakage_when_major_version_incremented=Disabled
-report_resolution_errors_api_component=Warning
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/.settings/org.eclipse.pde.prefs b/org.eclipse.tracecompass.lttng2.control.ui/.settings/org.eclipse.pde.prefs
deleted file mode 100644 (file)
index d92b94f..0000000
+++ /dev/null
@@ -1,32 +0,0 @@
-compilers.f.unresolved-features=1
-compilers.f.unresolved-plugins=1
-compilers.incompatible-environment=1
-compilers.p.build=1
-compilers.p.build.bin.includes=1
-compilers.p.build.encodings=2
-compilers.p.build.java.compiler=2
-compilers.p.build.java.compliance=1
-compilers.p.build.missing.output=2
-compilers.p.build.output.library=1
-compilers.p.build.source.library=1
-compilers.p.build.src.includes=1
-compilers.p.deprecated=1
-compilers.p.discouraged-class=1
-compilers.p.internal=1
-compilers.p.missing-packages=1
-compilers.p.missing-version-export-package=2
-compilers.p.missing-version-import-package=2
-compilers.p.missing-version-require-bundle=2
-compilers.p.no-required-att=0
-compilers.p.not-externalized-att=1
-compilers.p.unknown-attribute=1
-compilers.p.unknown-class=1
-compilers.p.unknown-element=1
-compilers.p.unknown-identifier=1
-compilers.p.unknown-resource=1
-compilers.p.unresolved-ex-points=0
-compilers.p.unresolved-import=0
-compilers.s.create-docs=false
-compilers.s.doc-folder=doc
-compilers.s.open-tags=1
-eclipse.preferences.version=1
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/META-INF/MANIFEST.MF b/org.eclipse.tracecompass.lttng2.control.ui/META-INF/MANIFEST.MF
deleted file mode 100644 (file)
index cbbf7aa..0000000
+++ /dev/null
@@ -1,37 +0,0 @@
-Manifest-Version: 1.0
-Bundle-ManifestVersion: 2
-Bundle-Name: %Bundle-Name
-Bundle-Vendor: %Bundle-Vendor
-Bundle-Version: 1.0.0.qualifier
-Bundle-Localization: plugin
-Bundle-SymbolicName: org.eclipse.tracecompass.lttng2.control.ui;singleton:=true
-Bundle-Activator: org.eclipse.tracecompass.internal.lttng2.control.ui.Activator
-Bundle-ActivationPolicy: lazy
-Bundle-RequiredExecutionEnvironment: JavaSE-1.7
-Require-Bundle: org.eclipse.ui,
- org.eclipse.ui.ide,
- org.eclipse.core.expressions,
- org.eclipse.core.resources,
- org.eclipse.core.runtime,
- org.eclipse.tracecompass.common.core,
- org.eclipse.tracecompass.lttng2.control.core,
- org.eclipse.tracecompass.tmf.core,
- org.eclipse.tracecompass.tmf.ui,
- org.eclipse.tracecompass.tmf.ctf.core,
- org.eclipse.remote.core;bundle-version="2.0.0",
- org.eclipse.remote.ui;bundle-version="2.0.0",
- org.eclipse.tracecompass.tmf.remote.core,
- org.eclipse.core.filesystem
-Export-Package: org.eclipse.tracecompass.internal.lttng2.control.ui;x-friends:="org.eclipse.tracecompass.lttng2.control.ui.tests",
- org.eclipse.tracecompass.internal.lttng2.control.ui.relayd;x-internal:=true,
- org.eclipse.tracecompass.internal.lttng2.control.ui.views;x-friends:="org.eclipse.tracecompass.lttng2.kernel.ui,org.eclipse.tracecompass.lttng2.control.ui.tests,org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests",
- org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;x-friends:="org.eclipse.tracecompass.lttng2.control.ui.tests",
- org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;x-internal:=true,
- org.eclipse.tracecompass.internal.lttng2.control.ui.views.logging;x-friends:="org.eclipse.tracecompass.lttng2.control.ui.tests",
- org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages;x-internal:=true,
- org.eclipse.tracecompass.internal.lttng2.control.ui.views.model;x-friends:="org.eclipse.tracecompass.lttng2.control.ui.tests",
- org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl;x-friends:="org.eclipse.tracecompass.lttng2.control.ui.tests",
- org.eclipse.tracecompass.internal.lttng2.control.ui.views.preferences;x-friends:="org.eclipse.tracecompass.lttng2.control.ui.tests",
- org.eclipse.tracecompass.internal.lttng2.control.ui.views.property;x-friends:="org.eclipse.tracecompass.lttng2.control.ui.tests",
- org.eclipse.tracecompass.internal.lttng2.control.ui.views.service;x-friends:="org.eclipse.tracecompass.lttng2.control.ui.tests"
-Import-Package: com.google.common.collect
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/about.html b/org.eclipse.tracecompass.lttng2.control.ui/about.html
deleted file mode 100644 (file)
index c258ef5..0000000
+++ /dev/null
@@ -1,28 +0,0 @@
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
-    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml">
-<head>
-<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"/>
-<title>About</title>
-</head>
-<body lang="EN-US">
-<h2>About This Content</h2>
-<p>June 5, 2006</p>    
-<h3>License</h3>
-
-<p>The Eclipse Foundation makes available all content in this plug-in (&quot;Content&quot;).  Unless otherwise 
-indicated below, the Content is provided to you under the terms and conditions of the
-Eclipse Public License Version 1.0 (&quot;EPL&quot;).  A copy of the EPL is available 
-at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>.
-For purposes of the EPL, &quot;Program&quot; will mean the Content.</p>
-
-<p>If you did not receive this Content directly from the Eclipse Foundation, the Content is 
-being redistributed by another party (&quot;Redistributor&quot;) and different terms and conditions may
-apply to your use of any object code in the Content.  Check the Redistributor's license that was 
-provided with the Content.  If no such license exists, contact the Redistributor.  Unless otherwise
-indicated below, the terms and conditions of the EPL still apply to any source code in the Content
-and such source code may be obtained at <a href="http://www.eclipse.org/">http://www.eclipse.org</a>.</p>
-
-</body>
-</html>
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/build.properties b/org.eclipse.tracecompass.lttng2.control.ui/build.properties
deleted file mode 100644 (file)
index 13e8d04..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-###############################################################################
-# Copyright (c) 2013, 2014 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:
-#     Ericsson - Initial API and implementation
-###############################################################################
-
-source.. = src/
-output.. = bin/
-bin.includes = META-INF/,\
-               .,\
-               plugin.xml,\
-               icons/,\
-               about.html,\
-               plugin.properties
-src.includes = about.html
-additional.bundles = org.eclipse.jdt.annotation
-jars.extra.classpath = platform:/plugin/org.eclipse.jdt.annotation
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/add-context.gif b/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/add-context.gif
deleted file mode 100644 (file)
index 030eade..0000000
Binary files a/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/add-context.gif and /dev/null differ
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/add_button.gif b/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/add_button.gif
deleted file mode 100644 (file)
index 252d7eb..0000000
Binary files a/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/add_button.gif and /dev/null differ
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/calibrate.gif b/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/calibrate.gif
deleted file mode 100644 (file)
index c984fba..0000000
Binary files a/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/calibrate.gif and /dev/null differ
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/connect.gif b/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/connect.gif
deleted file mode 100644 (file)
index 866ad33..0000000
Binary files a/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/connect.gif and /dev/null differ
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/delete_trace.gif b/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/delete_trace.gif
deleted file mode 100644 (file)
index b6922ac..0000000
Binary files a/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/delete_trace.gif and /dev/null differ
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/disable.gif b/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/disable.gif
deleted file mode 100644 (file)
index f6b9f8a..0000000
Binary files a/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/disable.gif and /dev/null differ
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/disable_event.gif b/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/disable_event.gif
deleted file mode 100644 (file)
index 2966a28..0000000
Binary files a/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/disable_event.gif and /dev/null differ
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/disconnect.gif b/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/disconnect.gif
deleted file mode 100644 (file)
index ec8a8b0..0000000
Binary files a/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/disconnect.gif and /dev/null differ
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/edit.gif b/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/edit.gif
deleted file mode 100644 (file)
index feb8e94..0000000
Binary files a/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/edit.gif and /dev/null differ
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/enable.gif b/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/enable.gif
deleted file mode 100644 (file)
index 9cacb96..0000000
Binary files a/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/enable.gif and /dev/null differ
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/enable_event.gif b/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/enable_event.gif
deleted file mode 100644 (file)
index 06d0079..0000000
Binary files a/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/enable_event.gif and /dev/null differ
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/import_trace.gif b/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/import_trace.gif
deleted file mode 100644 (file)
index d38085a..0000000
Binary files a/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/import_trace.gif and /dev/null differ
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/pause_trace.gif b/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/pause_trace.gif
deleted file mode 100644 (file)
index 161e3f5..0000000
Binary files a/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/pause_trace.gif and /dev/null differ
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/refresh.gif b/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/refresh.gif
deleted file mode 100644 (file)
index 3ca04d0..0000000
Binary files a/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/refresh.gif and /dev/null differ
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/snapshot.gif b/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/snapshot.gif
deleted file mode 100644 (file)
index 176830a..0000000
Binary files a/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/snapshot.gif and /dev/null differ
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/start_trace.gif b/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/start_trace.gif
deleted file mode 100644 (file)
index d6b3bdc..0000000
Binary files a/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/start_trace.gif and /dev/null differ
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/stop_trace.gif b/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/stop_trace.gif
deleted file mode 100644 (file)
index dc47edf..0000000
Binary files a/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/stop_trace.gif and /dev/null differ
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/target_add.gif b/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/target_add.gif
deleted file mode 100644 (file)
index 114b964..0000000
Binary files a/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/target_add.gif and /dev/null differ
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/target_delete.gif b/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/target_delete.gif
deleted file mode 100644 (file)
index b853d62..0000000
Binary files a/org.eclipse.tracecompass.lttng2.control.ui/icons/elcl16/target_delete.gif and /dev/null differ
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/icons/eview16/control_view.gif b/org.eclipse.tracecompass.lttng2.control.ui/icons/eview16/control_view.gif
deleted file mode 100644 (file)
index 0dc862c..0000000
Binary files a/org.eclipse.tracecompass.lttng2.control.ui/icons/eview16/control_view.gif and /dev/null differ
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/channel.gif b/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/channel.gif
deleted file mode 100644 (file)
index e8efe69..0000000
Binary files a/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/channel.gif and /dev/null differ
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/channel_disabled.gif b/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/channel_disabled.gif
deleted file mode 100644 (file)
index 413c1b9..0000000
Binary files a/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/channel_disabled.gif and /dev/null differ
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/domain.gif b/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/domain.gif
deleted file mode 100644 (file)
index c4a8af4..0000000
Binary files a/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/domain.gif and /dev/null differ
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/event_disabled.gif b/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/event_disabled.gif
deleted file mode 100644 (file)
index 2966a28..0000000
Binary files a/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/event_disabled.gif and /dev/null differ
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/event_enabled.gif b/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/event_enabled.gif
deleted file mode 100644 (file)
index 11d3d8d..0000000
Binary files a/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/event_enabled.gif and /dev/null differ
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/garland16.png b/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/garland16.png
deleted file mode 100644 (file)
index 74f9751..0000000
Binary files a/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/garland16.png and /dev/null differ
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/providers.gif b/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/providers.gif
deleted file mode 100644 (file)
index 885b8a6..0000000
Binary files a/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/providers.gif and /dev/null differ
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/session_active.gif b/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/session_active.gif
deleted file mode 100644 (file)
index 57a42bc..0000000
Binary files a/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/session_active.gif and /dev/null differ
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/session_destroyed.gif b/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/session_destroyed.gif
deleted file mode 100644 (file)
index b0adbc3..0000000
Binary files a/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/session_destroyed.gif and /dev/null differ
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/session_inactive.gif b/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/session_inactive.gif
deleted file mode 100644 (file)
index b6774cb..0000000
Binary files a/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/session_inactive.gif and /dev/null differ
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/sessions.gif b/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/sessions.gif
deleted file mode 100644 (file)
index c695884..0000000
Binary files a/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/sessions.gif and /dev/null differ
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/systemlttng2-live.gif b/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/systemlttng2-live.gif
deleted file mode 100755 (executable)
index 57c522d..0000000
Binary files a/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/systemlttng2-live.gif and /dev/null differ
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/systemlttng2.gif b/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/systemlttng2.gif
deleted file mode 100755 (executable)
index fd7b311..0000000
Binary files a/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/systemlttng2.gif and /dev/null differ
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/target_connected.gif b/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/target_connected.gif
deleted file mode 100644 (file)
index def312a..0000000
Binary files a/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/target_connected.gif and /dev/null differ
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/target_disconnected.gif b/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/target_disconnected.gif
deleted file mode 100644 (file)
index 2104ab4..0000000
Binary files a/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/target_disconnected.gif and /dev/null differ
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/targets.gif b/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/targets.gif
deleted file mode 100644 (file)
index c1e4ee3..0000000
Binary files a/org.eclipse.tracecompass.lttng2.control.ui/icons/obj16/targets.gif and /dev/null differ
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/plugin.properties b/org.eclipse.tracecompass.lttng2.control.ui/plugin.properties
deleted file mode 100644 (file)
index 44c24c6..0000000
+++ /dev/null
@@ -1,142 +0,0 @@
-###############################################################################
-# Copyright (c) 2013, 2015 Ericsson and others.
-#
-# 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:
-#     Ericsson - Initial API and implementation
-###############################################################################
-
-Bundle-Vendor = Eclipse Trace Compass
-Bundle-Name = Trace Compass LTTng Control UI Plug-in
-
-views.category.name = LTTng
-control.view.name = Control
-events.view.name = Events
-timeframe.view.name = Time Frame
-controlflow.view.name = Control Flow
-resources.view.name = Resources
-statistics.view.name = Statistics
-histogram.view.name = Histogram
-latency.view.name = Latency View
-
-project.new.category.name = LTTng
-project.new.wizard.name = LTTng Project
-project.new.wizard.description = Create a new LTTng project
-
-project.propertyPage.tracelibPath = LTTng Trace Library Path
-action.set.label = LTTng Action Set
-action.set.description = LTTng Action Set
-
-tracetype.category.lttng= LTTng
-tracetype.type.kernel = Kernel Trace
-
-#Commands and Menus
-commands.trace.category.name = LTTng Trace Commands
-commands.trace.category.description = LTTng Trace Commands
-commands.trace.import = Import Trace
-commands.trace.import.description = Import an LTTng Trace
-commands.trace.open = Open Trace
-commands.trace.open.description = Open an LTTng Trace
-commands.trace.rename = Rename Trace
-commands.trace.rename.description = Rename an LTTng Trace
-commands.trace.delete = Delete Trace
-commands.trace.delete.description = Delete an LTTng Trace
-commands.trace.selectparser = Select Parser
-
-commands.experiment.category.name = LTTng Experiment Commands
-commands.experiment.category.description = LTTng Experiment Commands
-commands.experiment.new = New Experiment
-commands.experiment.new.description = Create a new LTTng Experiment
-commands.experiment.selecttraces = Select Traces
-commands.experiment.selecttraces.description = Select LTTng Traces
-commands.experiment.open = Open Experiment
-commands.experiment.open.description = Open an LTTng Experiment
-commands.experiment.rename = Rename Experiment
-commands.experiment.rename.description = Rename an LTTng Experiment
-commands.experiment.delete = Delete Experiment
-commands.experiment.delete.description = Delete an LTTng Experiment
-
-# LTTng 2.0 trace control commands
-commands.control.category=LTTng Trace Control Commands
-commands.control.category.description=LTTng Trace Control Commands
-
-commands.control.new=New Connection...
-commands.control.new.description=New Connection to Target Node
-
-commands.control.connect=Connect
-commands.control.connect.description=Connect to Target Node
-
-commands.control.disconnect=Disconnect
-commands.control.disconnect.description=Disconnect to Target Node
-
-commands.control.refresh=Refresh
-commands.control.refresh.description=Refresh Node Configuration
-
-commands.control.delete=Delete
-commands.control.delete.description=Delete Target Node
-
-commands.control.create.session=Create Session...
-commands.control.create.session.description=Create a Trace Session
-
-commands.control.execute.command.script=Execute Command Script...
-commands.control.execute.command.script.description=Execute Command Script
-
-commands.control.destroy.session=Destroy Session...
-commands.control.destroy.session.description=Destroy a Trace Session
-
-commands.control.enable.channelOnSession=Enable Channel...
-commands.control.enable.channelOnSession.description=Enable a Trace Channel
-
-commands.control.enable.channelOnDomain=Enable Channel...
-commands.control.enable.channelOnDomain.description=Enable a Trace Channel
-
-commands.control.enable.channel=Enable Channel
-commands.control.enable.channel.description=Enable a Trace Channel
-
-commands.control.disable.channel=Disable Channel
-commands.control.disable.channel.description=Disable a Trace Channel
-
-commands.control.start=Start
-commands.control.start.description=Start Trace Session
-
-commands.control.stop=Stop
-commands.control.stop.description=Stop Trace Session
-
-commands.control.assign.event=Enable Event...
-commands.control.assign.event.description=Assign Event to Session and Channel and Enable Event 
-
-commands.control.enable.event=Enable Event
-commands.control.enable.event.description=Enable Event
-
-commands.control.enable.eventOnChannel=Enable Event...
-commands.control.enable.eventOnChannel.description=Enable Event
-
-commands.control.enable.eventOnDomain=Enable Event (default channel)...
-commands.control.enable.eventOnDomain.description=Enable Event on Default Channel
-
-commands.control.enable.eventOnSession=Enable Event (default channel)...
-commands.control.enable.eventOnSession.description=Enable Event on Default Channel
-
-commands.control.disable.event=Disable Event
-commands.control.disable.event.description=Disable Event
-
-commands.control.add.context=Add Context...
-commands.control.add.context.description=Add Context to Channel(s) and/or Event(s)
-
-commands.control.import=Import...
-commands.control.import.description=Import Traces to LTTng Project
-
-commands.control.calibrate=Calibrate
-commands.control.calibrate.description=Quantify LTTng overhead
-
-commands.control.snapshot=Record Snapshot
-commands.control.snapshot.description=Record a snapshot
-
-preference.page.control.name=LTTng Tracer Control Preferences
-
-commandParameter.remoteServicesId.name = Remote Services ID
-commandParameter.connectionName.name = Connection Name
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/plugin.xml b/org.eclipse.tracecompass.lttng2.control.ui/plugin.xml
deleted file mode 100644 (file)
index 2da1f5e..0000000
+++ /dev/null
@@ -1,1273 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<?eclipse version="3.4"?>
-<plugin>
-   <extension
-         id="org.eclipse.linuxtools.lttng2.ui.views"
-         point="org.eclipse.ui.views">
-      <category
-            id="org.eclipse.linuxtools.lttng2.ui.views.category"
-            name="%views.category.name">
-      </category>
-      <view
-            allowMultiple="false"
-            category="org.eclipse.linuxtools.lttng2.ui.views.category"
-            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView"
-            icon="icons/eview16/control_view.gif"
-            id="org.eclipse.linuxtools.internal.lttng2.ui.views.control"
-            name="%control.view.name"
-            restorable="true">
-      </view>
-   </extension>
-   
-      <extension
-         point="org.eclipse.ui.commands">
-      <category
-            description="%commands.control.category.description"
-            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
-            name="%commands.control.category">
-      </category>
-      <command
-            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
-            description="%commands.control.new.description"
-            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.newConnection"
-            name="%commands.control.new">
-         <commandParameter
-               id="org.eclipse.linuxtools.lttng2.control.ui.remoteServicesIdParameter"
-               name="%commandParameter.remoteServicesId.name"
-               optional="true">
-         </commandParameter>
-         <commandParameter
-               id="org.eclipse.linuxtools.lttng2.control.ui.connectionNameParameter"
-               name="%commandParameter.connectionName.name"
-               optional="true">
-         </commandParameter>
-      </command>
-      <command
-            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
-            description="%commands.control.connect.description"
-            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.connect"
-            name="%commands.control.connect">
-      </command>
-      <command
-            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
-            description="%commands.control.disconnect.description"
-            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.disconnect"
-            name="%commands.control.disconnect">
-      </command>
-      <command
-            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
-            description="%commands.control.refresh.description"
-            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.refresh"
-            name="%commands.control.refresh">
-      </command>
-      <command
-            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
-            description="%commands.control.delete.description"
-            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.delete"
-            name="%commands.control.delete">
-      </command>
-      <command
-            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
-            description="%commands.control.create.session.description"
-            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.createSession"
-            name="%commands.control.create.session">
-      </command>
-      <command
-            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
-            description="%commands.control.execute.command.script.description"
-            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.executeScript"
-            name="%commands.control.execute.command.script">
-      </command>
-      <command
-            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
-            description="%commands.control.destroy.session.description"
-            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.destroySession"
-            name="%commands.control.destroy.session">
-      </command>
-      <command
-            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
-            description="%commands.control.import.description"
-            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.import"
-            name="%commands.control.import">
-      </command>
-      <command
-            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
-            description="%commands.control.enable.channelOnSession.description"
-            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.enableChannelOnSession"
-            name="%commands.control.enable.channelOnSession">
-      </command>
-      <command
-            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
-            description="%commands.control.enable.channelOnDomain.description"
-            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.enableChannelOnDomain"
-            name="%commands.control.enable.channelOnDomain">
-      </command>
-      <command
-            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
-            description="%commands.control.enable.channel.description"
-            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.enableChannel"
-            name="%commands.control.enable.channel">
-      </command>
-      <command
-            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
-            description="%commands.control.disable.channel.description"
-            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.disableChannel"
-            name="%commands.control.disable.channel">
-      </command>
-      <command
-            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
-            description="%commands.control.start.description"
-            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.start"
-            name="%commands.control.start">
-      </command>
-      <command
-            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
-            description="%commands.control.stop.description"
-            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.stop"
-            name="%commands.control.stop">
-      </command>
-      <command
-            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
-            description="%commands.control.assign.event.description"
-            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.assign.event"
-            name="%commands.control.assign.event">
-      </command>
-      <command
-            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
-            description="%commands.control.enable.event.description"
-            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.enableEvent"
-            name="%commands.control.enable.event">
-      </command>
-      <command
-            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
-            description="%commands.control.disable.event.description"
-            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.disableEvent"
-            name="%commands.control.disable.event">
-      </command>
-      <command
-            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
-            description="%commands.control.enable.eventOnChannel.description"
-            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.enableEventOnChannel"
-            name="%commands.control.enable.eventOnChannel">
-      </command>
-      <command
-            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
-            description="%commands.control.enable.eventOnDomain.description"
-            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.enableEventOnDomain"
-            name="%commands.control.enable.eventOnDomain">
-      </command>
-      <command
-            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
-            description="%commands.control.enable.eventOnSession.description"
-            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.enableEventOnSession"
-            name="%commands.control.enable.eventOnSession">
-      </command>
-
-      <command
-            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
-            description="%commands.control.add.context.description"
-            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.addContextOnDomain"
-            name="%commands.control.add.context">
-      </command>
-
-      <command
-            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
-            description="%commands.control.add.context.description"
-            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.addContextOnChannel"
-            name="%commands.control.add.context">
-      </command>
-
-      <command
-            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
-            description="%commands.control.add.context.description"
-            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.addContextOnEvent"
-            name="%commands.control.add.context">
-      </command>
-
-      <command
-            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
-            description="%commands.control.import.description"
-            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.import"
-            name="%commands.control.import">
-      </command>
-
-      <command
-            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
-            description="%commands.control.calibrate.description"
-            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.calibrate"
-            name="%commands.control.calibrate">
-      </command>
-
-      <command
-            categoryId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.category"
-            description="%commands.control.snapshot.description"
-            id="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.snapshot"
-            name="%commands.control.snapshot">
-      </command>
-
-   </extension>
-   <extension
-         point="org.eclipse.ui.menus">
-      <menuContribution
-            allPopups="false"
-            locationURI="toolbar:org.eclipse.linuxtools.internal.lttng2.ui.views.control">
-         <command
-               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.newConnection"
-               icon="icons/elcl16/target_add.gif"
-               label="%commands.control.new"
-               style="push">
-         </command>
-         <command
-               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.connect"
-               icon="icons/elcl16/connect.gif"
-               label="%commands.control.connect"
-               style="push">
-         </command>
-         <command
-               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.disconnect"
-               icon="icons/elcl16/disconnect.gif"
-               label="%commands.control.disconnect"
-               style="push">
-         </command>
-         <command
-               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.refresh"
-               icon="icons/elcl16/refresh.gif"
-               label="%commands.control.refresh"
-               style="push">
-         </command>
-         <command
-               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.delete"
-               icon="icons/elcl16/target_delete.gif"
-               label="%commands.control.delete"
-               style="push">
-         </command>
-         <separator
-               name="org.eclipse.linuxtools.internal.lttng2.ui.views.control.toolbar.separator1"
-               visible="true">
-         </separator>
-         <command
-               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.start"
-               icon="icons/elcl16/start_trace.gif"
-               label="%commands.control.start"
-               style="push">
-         </command>
-         <command
-               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.stop"
-               icon="icons/elcl16/pause_trace.gif"
-               label="%commands.control.stop"
-               style="push">
-         </command>
-         <command
-               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.destroySession"
-               icon="icons/elcl16/delete_trace.gif"
-               label="%commands.control.destroy.session"
-               style="push">
-         </command>
-         <separator
-               name="org.eclipse.linuxtools.internal.lttng2.ui.views.control.toolbar.separator2"
-               visible="true">
-         </separator>
-         <command
-               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.snapshot"
-               icon="icons/elcl16/snapshot.gif"
-               label="%commands.control.snapshot"
-               style="push">
-         </command>
-         <separator
-               name="org.eclipse.linuxtools.internal.lttng2.ui.views.control.toolbar.separator3"
-               visible="true">
-         </separator>
-         <command
-               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.import"
-               icon="icons/elcl16/import_trace.gif"
-               label="%commands.control.import"
-               style="push">
-         </command>
-         
-      </menuContribution>
-      <menuContribution
-            allPopups="false"
-            locationURI="popup:org.eclipse.linuxtools.internal.lttng2.ui.views.control">
-         <command
-               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.connect"
-               icon="icons/elcl16/connect.gif"
-               label="%commands.control.connect"
-               style="push">
-            <visibleWhen
-                  checkEnabled="false">
-               <with
-                     variable="activeMenuSelection">
-                  <iterate
-                        operator="or">
-                     <instanceof
-                           value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent">
-                     </instanceof>
-                  </iterate>
-               </with>
-            </visibleWhen>
-         </command>
-         <command
-               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.disconnect"
-               icon="icons/elcl16/disconnect.gif"
-               label="%commands.control.disconnect"
-               style="push">
-            <visibleWhen
-                  checkEnabled="false">
-               <with
-                     variable="activeMenuSelection">
-                  <iterate
-                        operator="or">
-                     <instanceof
-                           value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent">
-                     </instanceof>
-                  </iterate>
-               </with>
-            </visibleWhen>
-         </command>
-         <command
-               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.refresh"
-               icon="icons/elcl16/refresh.gif"
-               label="%commands.control.refresh"
-               style="push">
-            <visibleWhen
-                  checkEnabled="false">
-               <with
-                     variable="activeMenuSelection">
-                  <iterate
-                        operator="or">
-                     <instanceof
-                           value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceControlComponent">
-                     </instanceof>
-                  </iterate>
-               </with>
-            </visibleWhen>
-         </command>
-         <command
-               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.delete"
-               icon="icons/elcl16/target_delete.gif"
-               label="%commands.control.delete"
-               style="push">
-            <visibleWhen
-                  checkEnabled="false">
-               <with
-                     variable="activeMenuSelection">
-                  <iterate
-                        operator="or">
-                     <instanceof
-                           value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent">
-                     </instanceof>
-                  </iterate>
-               </with>
-            </visibleWhen>
-         </command>
-         <command
-               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.createSession"
-               icon="icons/elcl16/add_button.gif"
-               label="%commands.control.create.session"
-               style="push">
-            <visibleWhen
-                  checkEnabled="false">
-               <with
-                     variable="activeMenuSelection">
-                  <iterate
-                        operator="or">
-                     <instanceof
-                           value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionGroup">
-                     </instanceof>
-                  </iterate>
-               </with>
-            </visibleWhen>
-         </command>
-         <command
-               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.executeScript"
-               icon="icons/elcl16/add_button.gif"
-               label="%commands.control.execute.command.script"
-               style="push">
-            <visibleWhen
-                  checkEnabled="false">
-               <with
-                     variable="activeMenuSelection">
-                  <iterate
-                        operator="or">
-                     <instanceof
-                           value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionGroup">
-                     </instanceof>
-                  </iterate>
-               </with>
-            </visibleWhen>
-         </command>
-         <command
-               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.start"
-               icon="icons/elcl16/start_trace.gif"
-               label="%commands.control.start"
-               style="push">
-            <visibleWhen
-                  checkEnabled="false">
-               <with
-                     variable="activeMenuSelection">
-                  <iterate
-                        operator="or">
-                     <instanceof
-                           value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent">
-                     </instanceof>
-                  </iterate>
-               </with>
-            </visibleWhen>
-         </command>
-         <command
-               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.stop"
-               icon="icons/elcl16/pause_trace.gif"
-               label="%commands.control.stop"
-               style="push">
-            <visibleWhen
-                  checkEnabled="false">
-               <with
-                     variable="activeMenuSelection">
-                  <iterate
-                        operator="or">
-                     <instanceof
-                           value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent">
-                     </instanceof>
-                  </iterate>
-               </with>
-            </visibleWhen>
-         </command>
-         <command
-               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.destroySession"
-               icon="icons/elcl16/delete_trace.gif"
-               label="%commands.control.destroy.session"
-               style="push">
-            <visibleWhen
-                  checkEnabled="false">
-               <with
-                     variable="activeMenuSelection">
-                  <iterate
-                        operator="or">
-                     <instanceof
-                           value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent">
-                     </instanceof>
-                  </iterate>
-               </with>
-            </visibleWhen>
-         </command>
-         <separator
-               name="org.eclipse.linuxtools.internal.lttng2.ui.views.control.popup.separator1"
-               visible="true">
-         </separator>
-         <command
-               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.import"
-               icon="icons/elcl16/import_trace.gif"
-               label="%commands.control.import"
-               style="push">
-            <visibleWhen
-                  checkEnabled="false">
-               <with
-                     variable="activeMenuSelection">
-                  <and>
-                    <iterate
-                         operator="or">
-                         <instanceof
-                               value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent">
-                         </instanceof>
-                      </iterate>
-                      <count
-                           value="1">
-                      </count>
-                  </and>   
-               </with>
-            </visibleWhen>
-         </command>
-         <separator
-               name="org.eclipse.linuxtools.internal.lttng2.ui.views.control.popup.separator2"
-               visible="true">
-         </separator>
-         <command
-               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.enableChannelOnSession"
-               icon="icons/elcl16/add_button.gif"
-               label="%commands.control.enable.channelOnSession"
-               style="push">
-            <visibleWhen
-                  checkEnabled="false">
-               <with
-                     variable="activeMenuSelection">
-                  <and>
-                     <iterate
-                           operator="or">
-                        <instanceof
-                              value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent">
-                        </instanceof>
-                     </iterate>
-                     <not>
-                        <iterate
-                              operator="or">
-                           <instanceof
-                                 value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent">
-                           </instanceof>
-                        </iterate>
-                     </not>
-                     <count
-                           value="1">
-                     </count>
-                  </and>
-               </with>
-            </visibleWhen>
-         </command>
-         <command
-               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.enableEventOnSession"
-               icon="icons/obj16/event_enabled.gif"
-               label="%commands.control.enable.eventOnDomain"
-               style="push">
-            <visibleWhen
-                  checkEnabled="false">
-               <with
-                     variable="activeMenuSelection">
-                  <and>
-                     <iterate
-                           operator="or">
-                        <instanceof
-                              value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent">
-                        </instanceof>
-                     </iterate>
-                     <count
-                           value="1">
-                     </count>
-                  </and>
-               </with>
-            </visibleWhen>
-         </command>
-         <command
-               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.enableChannelOnDomain"
-               icon="icons/elcl16/add_button.gif"
-               label="%commands.control.enable.channelOnDomain"
-               style="push">
-            <visibleWhen
-                  checkEnabled="false">
-               <with
-                     variable="activeMenuSelection">
-                  <and>
-                     <iterate
-                           operator="or">
-                        <instanceof
-                              value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent">
-                        </instanceof>
-                     </iterate>
-                        <not>
-                           <iterate
-                                 operator="or">
-                              <instanceof
-                                    value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent">
-                              </instanceof>
-                           </iterate>
-                        </not>
-                        <count
-                              value="1">
-                        </count>
-                  </and>
-               </with>
-               </visibleWhen>
-         </command>
-         <command
-               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.enableEventOnDomain"
-               icon="icons/elcl16/enable_event.gif"
-               label="%commands.control.enable.eventOnDomain"
-               style="push">
-            <visibleWhen
-                  checkEnabled="false">
-               <with
-                     variable="activeMenuSelection">
-                  <and>
-                     <iterate
-                           operator="or">
-                        <instanceof
-                              value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent">
-                        </instanceof>
-                     </iterate>
-                     <count
-                           value="1">
-                     </count>
-                  </and>
-               </with>
-            </visibleWhen>
-         </command>
-         <command
-               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.enableChannel"
-               icon="icons/elcl16/enable.gif"
-               label="%commands.control.enable.channel"
-               style="push">
-            <visibleWhen
-                  checkEnabled="false">
-               <with
-                     variable="activeMenuSelection">
-                  <iterate
-                        operator="or">
-                     <instanceof
-                           value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent">
-                     </instanceof>
-                  </iterate>
-               </with>
-            </visibleWhen>
-         </command>
-         <command
-               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.disableChannel"
-               icon="icons/elcl16/disable.gif"
-               label="%commands.control.disable.channel"
-               style="push">
-            <visibleWhen
-                  checkEnabled="false">
-               <with
-                     variable="activeMenuSelection">
-                  <iterate
-                        operator="or">
-                     <instanceof
-                           value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent">
-                     </instanceof>
-                  </iterate>
-               </with>
-            </visibleWhen>
-         </command>
-
-         <command
-               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.assign.event"
-               icon="icons/elcl16/enable_event.gif"
-               label="%commands.control.assign.event"
-               style="push">
-            <visibleWhen
-                  checkEnabled="false">
-               <with
-                     variable="activeMenuSelection">
-                  <iterate
-                        operator="or">
-                     <instanceof
-                           value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.BaseEventComponent">
-                     </instanceof>
-                  </iterate>
-               </with>
-            </visibleWhen>
-         </command>
-
-         <command
-               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.enableEvent"
-               icon="icons/elcl16/enable_event.gif"
-               label="%commands.control.enable.event"
-               style="push">
-            <visibleWhen
-                  checkEnabled="false">
-               <with
-                     variable="activeMenuSelection">
-                  <iterate
-                        operator="or">
-                     <instanceof
-                           value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceEventComponent">
-                     </instanceof>
-                  </iterate>
-               </with>
-            </visibleWhen>
-         </command>
-
-         <command
-               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.disableEvent"
-               icon="icons/elcl16/disable_event.gif"
-               label="%commands.control.disable.event"
-               style="push">
-            <visibleWhen
-                  checkEnabled="false">
-               <with
-                     variable="activeMenuSelection">
-                  <iterate
-                        operator="or">
-                     <instanceof
-                           value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceEventComponent">
-                     </instanceof>
-                  </iterate>
-               </with>
-            </visibleWhen>
-         </command>
-         <command
-               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.enableEventOnChannel"
-               icon="icons/elcl16/enable_event.gif"
-               label="%commands.control.enable.eventOnChannel"
-               style="push">
-            <visibleWhen
-                  checkEnabled="false">
-               <with
-                     variable="activeMenuSelection">
-                  <and>
-                     <iterate
-                           operator="or">
-                        <instanceof
-                              value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent">
-                        </instanceof>
-                     </iterate>
-                     <count
-                           value="1">
-                     </count>
-                  </and>
-               </with>
-            </visibleWhen>
-         </command>
-         <command
-               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.addContextOnDomain"
-               icon="icons/elcl16/add-context.gif"
-               label="%commands.control.add.context"
-               style="push">
-            <visibleWhen
-                  checkEnabled="false">
-               <with
-                     variable="activeMenuSelection">
-                  <and>
-                     <iterate
-                           operator="or">
-                        <instanceof
-                              value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent">
-                        </instanceof>
-                     </iterate>
-                     <count
-                           value="1">
-                     </count>
-                  </and>
-               </with>
-            </visibleWhen>
-         </command>
-         <command
-               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.addContextOnChannel"
-               icon="icons/elcl16/add-context.gif"
-               label="%commands.control.add.context"
-               style="push">
-            <visibleWhen
-                  checkEnabled="false">
-               <with
-                     variable="activeMenuSelection">
-                  <and>
-                     <iterate
-                           operator="or">
-                        <instanceof
-                              value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent">
-                        </instanceof>
-                     </iterate>
-                     <count
-                           value="1">
-                     </count>
-                  </and>
-               </with>
-            </visibleWhen>
-         </command>
-         <command
-               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.addContextOnEvent"
-               icon="icons/elcl16/add-context.gif"
-               label="%commands.control.add.context"
-               style="push">
-            <visibleWhen
-                  checkEnabled="false">
-               <with
-                     variable="activeMenuSelection">
-                  <and>
-                     <count
-                           value="1">
-                     </count>
-                     <iterate
-                           ifEmpty="false"
-                           operator="and">
-                        <and>
-                           <or>
-                              <instanceof
-                                    value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceEventComponent">
-                              </instanceof>
-                           </or>
-                           <test
-                                 forcePluginActivation="true"
-                                 property="org.eclipse.linuxtools.internal.lttng2.ui.views.control.model.isAddContextOnEventSupported">
-                           </test>
-                        </and>
-                     </iterate>
-                  </and>
-               </with>
-            </visibleWhen>
-         </command>
-         <command
-               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.calibrate"
-               icon="icons/elcl16/calibrate.gif"
-               label="%commands.control.calibrate"
-               style="push">
-            <visibleWhen
-                  checkEnabled="false">
-               <with
-                     variable="activeMenuSelection">
-                  <and>
-                     <iterate
-                           operator="or">
-                        <instanceof
-                              value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent">
-                        </instanceof>
-                     </iterate>
-                     <count
-                           value="1">
-                     </count>
-                  </and>
-               </with>
-            </visibleWhen>
-         </command>
-
-         <command
-               commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.snapshot"
-               icon="icons/elcl16/snapshot.gif"
-               label="%commands.control.snapshot"
-               style="push">
-            <visibleWhen
-                  checkEnabled="false">
-               <with
-                     variable="activeMenuSelection">
-                  <and>
-                     <iterate
-                           operator="or">
-                        <instanceof
-                              value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent">
-                        </instanceof>
-                     </iterate>
-                     <count
-                           value="1">
-                     </count>
-                  </and>
-               </with>
-            </visibleWhen>
-         </command>
-
-      </menuContribution>
-      
-   </extension>
-   <extension
-         point="org.eclipse.ui.handlers">
-      <handler
-            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.NewConnectionHandler"
-            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.newConnection">
-         <activeWhen>
-            <with
-                  variable="activePart">
-               <instanceof
-                     value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView">
-               </instanceof>
-            </with>
-         </activeWhen>
-      </handler>
-      <handler
-            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.ConnectHandler"
-            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.connect">
-         <activeWhen>
-            <with
-                  variable="selection">
-               <iterate
-                     operator="or">
-                  <instanceof
-                        value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent">
-                  </instanceof>
-               </iterate>
-            </with>
-         </activeWhen>
-      </handler>
-      <handler
-            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.DisconnectHandler"
-            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.disconnect">
-         <activeWhen>
-            <with
-                  variable="selection">
-               <iterate
-                     operator="or">
-                  <instanceof
-                        value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent">
-                  </instanceof>
-               </iterate>
-            </with>
-         </activeWhen>
-      </handler>
-      <handler
-            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.RefreshHandler"
-            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.refresh">
-         <activeWhen>
-            <with
-                  variable="selection">
-               <iterate
-                     operator="or">
-                  <instanceof
-                        value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceControlComponent">
-                  </instanceof>
-               </iterate>
-            </with>
-         </activeWhen>
-      </handler>
-      <handler
-            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.DeleteHandler"
-            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.delete">
-         <activeWhen>
-            <with
-                  variable="selection">
-               <iterate
-                     operator="or">
-                  <instanceof
-                        value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent">
-                  </instanceof>
-               </iterate>
-            </with>
-         </activeWhen>
-      </handler>
-      <handler
-            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.CreateSessionHandler"
-            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.createSession">
-         <activeWhen>
-            <with
-                  variable="selection">
-               <iterate
-                     operator="or">
-                  <instanceof
-                        value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionGroup">
-                  </instanceof>
-               </iterate>
-            </with>
-         </activeWhen>
-      </handler>
-      <handler
-            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.ExecuteCommandScriptHandler"
-            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.executeScript">
-         <activeWhen>
-            <with
-                  variable="selection">
-               <iterate
-                     operator="or">
-                  <instanceof
-                        value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionGroup">
-                  </instanceof>
-               </iterate>
-            </with>
-         </activeWhen>
-      </handler>
-      <handler
-            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.DestroySessionHandler"
-            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.destroySession">
-         <activeWhen>
-            <with
-                  variable="selection">
-               <iterate
-                     operator="or">
-                  <instanceof
-                        value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent">
-                  </instanceof>
-               </iterate>
-            </with>
-         </activeWhen>
-      </handler>
-      <handler
-            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.ImportHandler"
-            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.import">
-         <activeWhen>
-            <with
-                  variable="selection">
-               <and>   
-                  <iterate
-                        operator="or">
-                     <instanceof
-                           value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent">
-                     </instanceof>
-                  </iterate>
-                  <count
-                        value="1">
-                  </count>
-               </and>
-            </with>
-         </activeWhen>
-      </handler>
-      <handler
-            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.EnableChannelOnSessionHandler"
-            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.enableChannelOnSession">
-         <activeWhen>
-            <with
-                  variable="selection">
-               <iterate
-                     operator="or">
-                  <instanceof
-                        value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent">
-                  </instanceof>
-               </iterate>
-            </with>
-         </activeWhen>
-      </handler>
-      <handler
-            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.EnableChannelOnDomainHandler"
-            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.enableChannelOnDomain">
-         <activeWhen>
-            <with
-                  variable="selection">
-               <iterate
-                     operator="or">
-                  <instanceof
-                        value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent">
-                  </instanceof>
-               </iterate>
-            </with>
-         </activeWhen>
-      </handler>
-      <handler
-            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.EnableChannelHandler"
-            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.enableChannel">
-         <activeWhen>
-            <with
-                  variable="selection">
-               <iterate
-                     operator="or">
-                  <instanceof
-                        value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent">
-                  </instanceof>
-               </iterate>
-            </with>
-         </activeWhen>
-      </handler>
-      <handler
-            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.DisableChannelHandler"
-            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.disableChannel">
-         <activeWhen>
-            <with
-                  variable="selection">
-               <iterate
-                     operator="or">
-                  <instanceof
-                        value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent">
-                  </instanceof>
-               </iterate>
-            </with>
-         </activeWhen>
-      </handler>
-      
-      <handler
-            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.StartHandler"
-            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.start">
-         <activeWhen>
-            <with
-                  variable="selection">
-               <iterate
-                     operator="or">
-                  <instanceof
-                        value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent">
-                  </instanceof>
-               </iterate>
-            </with>
-         </activeWhen>
-      </handler>
-
-      <handler
-            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.StopHandler"
-            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.stop">
-         <activeWhen>
-            <with
-                  variable="selection">
-               <iterate
-                     operator="or">
-                  <instanceof
-                        value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent">
-                  </instanceof>
-               </iterate>
-            </with>
-         </activeWhen>
-      </handler>
-
-      <handler
-            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.SnaphshotHandler"
-            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.snapshot">
-         <activeWhen>
-            <with
-                  variable="selection">
-               <iterate
-                     operator="or">
-                  <instanceof
-                        value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent">
-                  </instanceof>
-               </iterate>
-            </with>
-         </activeWhen>
-      </handler>
-
-
-      <handler
-            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.AssignEventHandler"
-            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.assign.event">
-         <activeWhen>
-            <with
-                  variable="selection">
-               <iterate
-                     operator="or">
-                  <instanceof
-                        value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.BaseEventComponent">
-                  </instanceof>
-               </iterate>
-            </with>
-         </activeWhen>
-      </handler>
-
-      <handler
-            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.EnableEventHandler"
-            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.enableEvent">
-         <activeWhen>
-            <with
-                  variable="selection">
-               <iterate
-                     operator="or">
-                  <instanceof
-                        value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceEventComponent">
-                  </instanceof>
-               </iterate>
-            </with>
-         </activeWhen>
-      </handler>
-
-      <handler
-            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.DisableEventHandler"
-            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.disableEvent">
-         <activeWhen>
-            <with
-                  variable="selection">
-               <iterate
-                     operator="or">
-                  <instanceof
-                        value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceEventComponent">
-                  </instanceof>
-               </iterate>
-            </with>
-         </activeWhen>
-      </handler>
-
-      <handler
-            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.EnableEventOnChannelHandler"
-            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.enableEventOnChannel">
-         <activeWhen>
-            <with
-                  variable="selection">
-               <iterate
-                     operator="or">
-                  <instanceof
-                        value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent">
-                  </instanceof>
-               </iterate>
-            </with>
-         </activeWhen>
-      </handler>
-
-      <handler
-            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.EnableEventOnDomainHandler"
-            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.enableEventOnDomain">
-         <activeWhen>
-            <with
-                  variable="selection">
-               <iterate
-                     operator="or">
-                  <instanceof
-                        value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent">
-                  </instanceof>
-               </iterate>
-            </with>
-         </activeWhen>
-      </handler>
-      <handler
-            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.EnableEventOnSessionHandler"
-            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.enableEventOnSession">
-         <activeWhen>
-            <with
-                  variable="selection">
-               <iterate
-                     operator="or">
-                  <instanceof
-                        value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent">
-                  </instanceof>
-               </iterate>
-            </with>
-         </activeWhen>
-      </handler>
-      
-      <handler
-            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.AddContextOnDomainHandler"
-            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.addContextOnDomain">
-         <activeWhen>
-            <with
-                  variable="selection">
-               <iterate
-                     operator="or">
-                  <instanceof
-                        value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent">
-                  </instanceof>
-               </iterate>
-            </with>
-         </activeWhen>
-      </handler>
-
-      <handler
-            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.CalibrateHandler"
-            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.calibrate">
-         <activeWhen>
-            <with
-                  variable="selection">
-               <iterate
-                     operator="or">
-                  <instanceof
-                        value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent">
-                  </instanceof>
-               </iterate>
-            </with>
-         </activeWhen>
-      </handler>
-
-      <handler
-            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.AddContextOnChannelHandler"
-            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.addContextOnChannel">
-         <activeWhen>
-            <with
-                  variable="selection">
-               <iterate
-                     operator="or">
-                  <instanceof
-                        value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent">
-                  </instanceof>
-               </iterate>
-            </with>
-         </activeWhen>
-      </handler>
-
-      <handler
-            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.AddContextOnEventHandler"
-            commandId="org.eclipse.linuxtools.internal.lttng2.ui.commands.control.addContextOnEvent">
-         <activeWhen>
-            <with
-                  variable="selection">
-               <iterate
-                     operator="or">
-                  <instanceof
-                        value="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceEventComponent">
-                  </instanceof>
-               </iterate>
-            </with>
-         </activeWhen>
-      </handler>
-      
-   </extension>
-   <extension
-         point="org.eclipse.ui.preferencePages">
-      <page
-            category="org.eclipse.linuxtools.tmf.ui.TmfTracingPreferences"
-            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.preferences.ControlPreferencePage"
-            id="org.eclipse.linuxtools.internal.lttng2.ui.views.control.preferences"
-            name="%preference.page.control.name">
-      </page>
-   </extension>
-   <extension
-         point="org.eclipse.core.runtime.preferences">
-      <initializer
-            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.preferences.ControlPreferenceInitializer">
-      </initializer>
-   </extension>
-   <extension
-         point="org.eclipse.core.expressions.propertyTesters">
-      <propertyTester
-            class="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceControlPropertyTester"
-            id="org.eclipse.linuxtools.internal.lttng2.ui.views.control.model.propertyTester"
-            namespace="org.eclipse.linuxtools.internal.lttng2.ui.views.control.model"
-            properties="isAddContextOnEventSupported"
-            type="org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceControlComponent">
-      </propertyTester>
-   </extension>
-   
-   
-</plugin>
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/pom.xml b/org.eclipse.tracecompass.lttng2.control.ui/pom.xml
deleted file mode 100644 (file)
index e112cd5..0000000
+++ /dev/null
@@ -1,36 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-   Copyright (C) 2011, Red Hat, Inc.
-
-   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
--->
-<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>
-    <artifactId>org.eclipse.tracecompass</artifactId>
-    <groupId>org.eclipse.tracecompass</groupId>
-    <version>1.0.0-SNAPSHOT</version>
-  </parent>
-
-  <artifactId>org.eclipse.tracecompass.lttng2.control.ui</artifactId>
-  <version>1.0.0-SNAPSHOT</version>
-  <packaging>eclipse-plugin</packaging>
-
-  <name>Trace Compass LTTng Control UI Plug-in</name>
-
- <build>
-    <plugins>
-      <plugin>
-        <groupId>org.eclipse.tycho</groupId>
-        <artifactId>tycho-source-plugin</artifactId>
-      </plugin>
-    </plugins>
-  </build>
-
- <groupId>org.eclipse.tracecompass</groupId>
-</project>
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/Activator.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/Activator.java
deleted file mode 100644 (file)
index 24f54ac..0000000
+++ /dev/null
@@ -1,210 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2012, 2015 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:
- *   Francois Chouinard - Initial API and implementation
- *   Bernd Hufmann - Add Utility to get a OSGI service
- *******************************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.ui;
-
-import java.net.URL;
-
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.jface.resource.ImageDescriptor;
-import org.eclipse.jface.resource.ImageRegistry;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.relayd.LttngRelaydConnectionManager;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.preferences.ControlPreferences;
-import org.eclipse.ui.plugin.AbstractUIPlugin;
-import org.osgi.framework.BundleContext;
-
-/**
- * The activator class controls the plug-in life cycle
- */
-public class Activator extends AbstractUIPlugin {
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-
-    /**
-     *  The plug-in ID
-     */
-    public static final String PLUGIN_ID = "org.eclipse.tracecompass.lttng2.control.ui"; //$NON-NLS-1$
-
-    /**
-     *  The shared instance
-     */
-    private static Activator plugin;
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-
-    /**
-     * The constructor
-     */
-    public Activator() {
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    /**
-     * Returns the shared instance
-     *
-     * @return the shared instance
-     */
-    public static Activator getDefault() {
-        return plugin;
-    }
-
-    // ------------------------------------------------------------------------
-    // AbstractUIPlugin
-    // ------------------------------------------------------------------------
-
-    @Override
-    public void start(BundleContext context) throws Exception {
-        super.start(context);
-        plugin = this;
-        ControlPreferences.getInstance().init(getPreferenceStore());
-        // This registers the connection manager with the signal manager
-        LttngRelaydConnectionManager.getInstance();
-    }
-
-    @Override
-    public void stop(BundleContext context) throws Exception {
-        ControlPreferences.getInstance().dispose();
-        LttngRelaydConnectionManager.getInstance().dispose();
-        plugin = null;
-        super.stop(context);
-    }
-
-    @Override
-    protected void initializeImageRegistry(ImageRegistry reg) {
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    /**
-     * Gets an image object using given path within plug-in.
-     *
-     * @param path path to image file
-     *
-     * @return image object
-     */
-    public Image getImageFromPath(String path) {
-        return getImageDescripterFromPath(path).createImage();
-    }
-
-    /**
-     * Gets an image descriptor using given path within plug-in.
-     *
-     * @param path path to image file
-     *
-     * @return image descriptor object
-     */
-    public ImageDescriptor getImageDescripterFromPath(String path) {
-        return AbstractUIPlugin.imageDescriptorFromPlugin(PLUGIN_ID, path);
-    }
-
-    /**
-     * Gets a image object from the image registry based on the given path.
-     * If the image is not in the registry it will be registered.
-     *
-     * @param path to the image file
-     * @return image object
-     */
-    public Image getImageFromImageRegistry(String path) {
-        Image icon = getImageRegistry().get(path);
-        if (icon == null) {
-            icon = getImageDescripterFromPath(path).createImage();
-            plugin.getImageRegistry().put(path, icon);
-        }
-        return icon;
-    }
-
-    /**
-     * Loads the image in the plug-ins image registry (if necessary) and returns the image
-     * @param url - URL relative to the Bundle
-     * @return  the image
-     */
-    public Image loadIcon(String url) {
-        String key = plugin.getBundle().getSymbolicName() + "/" + url; //$NON-NLS-1$
-        Image icon = plugin.getImageRegistry().get(key);
-        if (icon == null) {
-            URL imageURL = plugin.getBundle().getResource(url);
-            ImageDescriptor descriptor = ImageDescriptor.createFromURL(imageURL);
-            icon = descriptor.createImage();
-            plugin.getImageRegistry().put(key, icon);
-        }
-        return icon;
-    }
-
-    /**
-     * Logs a message with severity INFO in the runtime log of the plug-in.
-     *
-     * @param message A message to log
-     */
-    public void logInfo(String message) {
-        getLog().log(new Status(IStatus.INFO, PLUGIN_ID, message));
-    }
-
-    /**
-     * Logs a message and exception with severity INFO in the runtime log of the plug-in.
-     *
-     * @param message A message to log
-     * @param exception A exception to log
-     */
-    public void logInfo(String message, Throwable exception) {
-        getLog().log(new Status(IStatus.INFO, PLUGIN_ID, message, exception));
-    }
-
-    /**
-     * Logs a message and exception with severity WARNING in the runtime log of the plug-in.
-     *
-     * @param message A message to log
-     */
-    public void logWarning(String message) {
-        getLog().log(new Status(IStatus.WARNING, PLUGIN_ID, message));
-    }
-
-    /**
-     * Logs a message and exception with severity WARNING in the runtime log of the plug-in.
-     *
-     * @param message A message to log
-     * @param exception A exception to log
-     */
-    public void logWarning(String message, Throwable exception) {
-        getLog().log(new Status(IStatus.WARNING, PLUGIN_ID, message, exception));
-    }
-
-    /**
-     * Logs a message and exception with severity ERROR in the runtime log of the plug-in.
-     *
-     * @param message A message to log
-     */
-    public void logError(String message) {
-        getLog().log(new Status(IStatus.ERROR, PLUGIN_ID, message));
-    }
-
-    /**
-     * Logs a message and exception with severity ERROR in the runtime log of the plug-in.
-     *
-     * @param message A message to log
-     * @param exception A exception to log
-     */
-    public void logError(String message, Throwable exception) {
-        getLog().log(new Status(IStatus.ERROR, PLUGIN_ID, message, exception));
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/relayd/LttngRelaydConnectionInfo.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/relayd/LttngRelaydConnectionInfo.java
deleted file mode 100644 (file)
index 1f435a8..0000000
+++ /dev/null
@@ -1,110 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014 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:
- *   Marc-Andre Laperle - Initial implementation
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.ui.relayd;
-
-/**
- * A class that holds information about the relayd connection.
- *
- * @author Marc-Andre Laperle
- */
-public final class LttngRelaydConnectionInfo {
-
-    private final String fHost;
-    private final int fPort;
-    private final String fSessionName;
-
-    /**
-     * Constructs a connection information.
-     *
-     * @param host
-     *            the host string
-     * @param port
-     *            the port number
-     * @param sessionName
-     *            the session name
-     */
-    public LttngRelaydConnectionInfo(String host, int port, String sessionName) {
-        fHost = host;
-        fPort = port;
-        fSessionName = sessionName;
-    }
-
-    /**
-     * Get the host string.
-     *
-     * @return the host string
-     */
-    public String getHost() {
-        return fHost;
-    }
-
-    /**
-     * Get the port number.
-     *
-     * @return the port number
-     */
-    public int getPort() {
-        return fPort;
-    }
-
-    /**
-     * Get the session name.
-     *
-     * @return the session name
-     */
-    public String getSessionName() {
-        return fSessionName;
-    }
-
-    @Override
-    public int hashCode() {
-        final int prime = 31;
-        int result = 1;
-        result = prime * result + ((fHost == null) ? 0 : fHost.hashCode());
-        result = prime * result + fPort;
-        result = prime * result + ((fSessionName == null) ? 0 : fSessionName.hashCode());
-        return result;
-    }
-
-    @Override
-    public boolean equals(final Object obj) {
-        if (this == obj) {
-            return true;
-        }
-        if (obj == null) {
-            return false;
-        }
-        if (getClass() != obj.getClass()) {
-            return false;
-        }
-        LttngRelaydConnectionInfo other = (LttngRelaydConnectionInfo) obj;
-        if (fHost == null) {
-            if (other.fHost != null) {
-                return false;
-            }
-        } else if (!fHost.equals(other.fHost)) {
-            return false;
-        }
-        if (fPort != other.fPort) {
-            return false;
-        }
-        if (fSessionName == null) {
-            if (other.fSessionName != null) {
-                return false;
-            }
-        } else if (!fSessionName.equals(other.fSessionName)) {
-            return false;
-        }
-        return true;
-    }
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/relayd/LttngRelaydConnectionManager.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/relayd/LttngRelaydConnectionManager.java
deleted file mode 100644 (file)
index 178e865..0000000
+++ /dev/null
@@ -1,148 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014 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:
- *   Marc-Andre Laperle - Initial implementation
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.ui.relayd;
-
-import java.util.HashMap;
-import java.util.Map;
-
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.jface.dialogs.ErrorDialog;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
-import org.eclipse.tracecompass.tmf.core.signal.TmfSignalHandler;
-import org.eclipse.tracecompass.tmf.core.signal.TmfSignalManager;
-import org.eclipse.tracecompass.tmf.core.signal.TmfTraceClosedSignal;
-import org.eclipse.tracecompass.tmf.core.signal.TmfTraceOpenedSignal;
-import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace;
-import org.eclipse.tracecompass.tmf.ctf.core.CtfConstants;
-import org.eclipse.tracecompass.tmf.ctf.core.trace.CtfTmfTrace;
-import org.eclipse.ui.PlatformUI;
-
-/**
- * Manages relayd connections. When a trace is opened, it creates a connection
- * if the trace was started with live support. When a trace is closed, is closes
- * the connection.
- *
- * @author Marc-Andre Laperle
- */
-public final class LttngRelaydConnectionManager {
-    private static LttngRelaydConnectionManager fConnectionManager;
-    private Map<LttngRelaydConnectionInfo, LttngRelaydConsumer> fConnections = new HashMap<>();
-
-    /**
-     * Get an instance of the trace manager.
-     *
-     * @return The trace manager
-     */
-    public static synchronized LttngRelaydConnectionManager getInstance() {
-        if (fConnectionManager == null) {
-            fConnectionManager = new LttngRelaydConnectionManager();
-            TmfSignalManager.register(fConnectionManager);
-        }
-        return fConnectionManager;
-    }
-
-    /**
-     * Get the cosumer for the given relayd connection information.
-     *
-     * @param connectionInfo
-     *            the connection information
-     *
-     * @return the consumer
-     */
-    public LttngRelaydConsumer getConsumer(final LttngRelaydConnectionInfo connectionInfo) {
-        if (!fConnections.containsKey(connectionInfo)) {
-            LttngRelaydConsumer lttngRelaydConsumer = new LttngRelaydConsumer(connectionInfo);
-            fConnections.put(connectionInfo, lttngRelaydConsumer);
-            return lttngRelaydConsumer;
-        }
-
-        return fConnections.get(connectionInfo);
-    }
-
-    private static LttngRelaydConnectionInfo getEntry(final ITmfTrace trace) throws CoreException {
-        if (trace instanceof CtfTmfTrace) {
-            CtfTmfTrace ctfTmfTrace = (CtfTmfTrace) trace;
-            if (!ctfTmfTrace.isComplete()) {
-                IResource resource = ctfTmfTrace.getResource();
-                String host = resource.getPersistentProperty(CtfConstants.LIVE_HOST);
-                String port = resource.getPersistentProperty(CtfConstants.LIVE_PORT);
-                String sessionName = resource.getPersistentProperty(CtfConstants.LIVE_SESSION_NAME);
-                if (host != null && port != null && sessionName != null && !sessionName.isEmpty()) {
-                    LttngRelaydConnectionInfo entry = new LttngRelaydConnectionInfo(host, Integer.parseInt(port), sessionName);
-                    return entry;
-                }
-            }
-        }
-
-        return null;
-    }
-
-    /**
-     * Listen to trace opened so that we can start the relayd job if necessary.
-     *
-     * @param signal
-     *            the signal to be processed
-     */
-    @TmfSignalHandler
-    public void traceOpened(final TmfTraceOpenedSignal signal) {
-
-        try {
-            LttngRelaydConnectionInfo entry = getEntry(signal.getTrace());
-            if (entry != null) {
-                LttngRelaydConsumer consumer = getConsumer(entry);
-                consumer.connect();
-                consumer.run((CtfTmfTrace) signal.getTrace());
-            }
-        } catch (CoreException e) {
-            Activator.getDefault().logError(Messages.LttngRelaydConnectionManager_ConnectionError, e);
-            ErrorDialog.openError(PlatformUI.getWorkbench().getActiveWorkbenchWindow().getShell(), null, Messages.LttngRelaydConnectionManager_ConnectionError, new Status(IStatus.WARNING,
-                    Activator.PLUGIN_ID, e.getLocalizedMessage(), e));
-        }
-    }
-
-    /**
-     * Listen to trace closed so that we can stop the relayd job.
-     *
-     * @param signal
-     *            the signal to be processed
-     */
-    @TmfSignalHandler
-    public void traceClosed(final TmfTraceClosedSignal signal) {
-        LttngRelaydConnectionInfo entry;
-        try {
-            entry = getEntry(signal.getTrace());
-            if (entry != null) {
-                LttngRelaydConsumer comsumer = getConsumer(entry);
-                if (comsumer != null) {
-                    comsumer.dispose();
-                }
-                fConnections.remove(entry);
-            }
-        } catch (CoreException e) {
-            // Something went wrong with the resource. That's OK, the trace is
-            // getting closed anyway.
-        }
-    }
-
-    /**
-     * Dispose of all the manager's resources (i.e. its connections).
-     */
-    public void dispose() {
-        for (LttngRelaydConsumer consumer : fConnections.values()) {
-            consumer.dispose();
-        }
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/relayd/LttngRelaydConsumer.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/relayd/LttngRelaydConsumer.java
deleted file mode 100644 (file)
index 2cc064b..0000000
+++ /dev/null
@@ -1,264 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014, 2015 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:
- *   Matthew Khouzam - Initial implementation
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.ui.relayd;
-
-import java.io.IOException;
-import java.io.UnsupportedEncodingException;
-import java.net.Socket;
-import java.util.List;
-import java.util.regex.Matcher;
-import java.util.regex.Pattern;
-
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.core.runtime.jobs.Job;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.ILttngRelaydConnector;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.LttngRelaydConnectorFactory;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.AttachReturnCode;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.AttachSessionResponse;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.CreateSessionResponse;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.CreateSessionReturnCode;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.IndexResponse;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.NextIndexReturnCode;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.SessionResponse;
-import org.eclipse.tracecompass.internal.lttng2.control.core.relayd.commands.StreamResponse;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
-import org.eclipse.tracecompass.tmf.core.signal.TmfTraceRangeUpdatedSignal;
-import org.eclipse.tracecompass.tmf.core.timestamp.TmfNanoTimestamp;
-import org.eclipse.tracecompass.tmf.core.timestamp.TmfTimeRange;
-import org.eclipse.tracecompass.tmf.ctf.core.trace.CtfTmfTrace;
-
-/**
- * Consumer of the relay d.
- *
- * @author Matthew Khouzam
- */
-public final class LttngRelaydConsumer {
-
-    private static final Pattern PROTOCOL_HOST_PATTERN = Pattern.compile("(\\S+://)*(\\d+\\.\\d+\\.\\d+\\.\\d+)"); //$NON-NLS-1$
-    private static final int SIGNAL_THROTTLE_NANOSEC = 10_000_000;
-    private static final String ENCODING_UTF_8 = "UTF-8"; //$NON-NLS-1$
-
-    private Job fConsumerJob;
-    private CtfTmfTrace fCtfTmfTrace;
-    private long fTimestampEnd;
-    private AttachSessionResponse fSession;
-    private Socket fConnection;
-    private ILttngRelaydConnector fRelayd;
-    private String fTracePath;
-    private long fLastSignal = 0;
-    private final LttngRelaydConnectionInfo fConnectionInfo;
-
-    /**
-     * Start a lttng consumer.
-     *
-     * @param address
-     *            the ip address in string format
-     * @param port
-     *            the port, an integer
-     * @param sessionName
-     *            the session name
-     * @param project
-     *            the default project
-     */
-    LttngRelaydConsumer(final LttngRelaydConnectionInfo connectionInfo) {
-        fConnectionInfo = connectionInfo;
-        fTimestampEnd = 0;
-    }
-
-    /**
-     * Connects to the relayd at the given address and port then attaches to the
-     * given session name.
-     *
-     * @throws CoreException
-     *             If something goes wrong during the connection
-     *             <ul>
-     *             <li>
-     *             Connection could not be established (Socket could not be
-     *             opened, etc)</li>
-     *             <li>
-     *             Connection timeout</li>
-     *             <li>
-     *             The session was not found</li>
-     *             <li>
-     *             Could not create viewer session</li>
-     *             <li>
-     *             Invalid trace (no metadata, no streams)</li>
-     *             </ul>
-     */
-    public void connect() throws CoreException {
-        if (fConnection != null) {
-            return;
-        }
-
-        try {
-            Matcher matcher = PROTOCOL_HOST_PATTERN.matcher(fConnectionInfo.getHost());
-            String host = null;
-            if (matcher.matches()) {
-                host = matcher.group(2);
-            }
-
-            if (host == null || host.isEmpty()) {
-                throw new CoreException(new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.LttngRelaydConsumer_ErrorConnecting));
-            }
-
-            fConnection = new Socket(host, fConnectionInfo.getPort());
-            fRelayd = LttngRelaydConnectorFactory.getNewConnector(fConnection);
-            List<SessionResponse> sessions = fRelayd.getSessions();
-            SessionResponse selectedSession = null;
-            for (SessionResponse session : sessions) {
-                String asessionName = nullTerminatedByteArrayToString(session.getSessionName().getBytes());
-
-                if (asessionName.equals(fConnectionInfo.getSessionName())) {
-                    selectedSession = session;
-                    break;
-                }
-            }
-
-            if (selectedSession == null) {
-                throw new CoreException(new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.LttngRelaydConsumer_SessionNotFound));
-            }
-
-            CreateSessionResponse createSession = fRelayd.createSession();
-            if (createSession.getStatus() != CreateSessionReturnCode.LTTNG_VIEWER_CREATE_SESSION_OK) {
-                throw new CoreException(new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.LttngRelaydConsumer_CreateViewerSessionError + createSession.getStatus().toString()));
-            }
-
-            AttachSessionResponse attachedSession = fRelayd.attachToSession(selectedSession);
-            if (attachedSession.getStatus() != AttachReturnCode.VIEWER_ATTACH_OK) {
-                throw new CoreException(new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.LttngRelaydConsumer_AttachSessionError + attachedSession.getStatus().toString()));
-            }
-
-            String metadata = fRelayd.getMetadata(attachedSession);
-            if (metadata == null) {
-                throw new CoreException(new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.LttngRelaydConsumer_NoMetadata));
-            }
-
-            List<StreamResponse> attachedStreams = attachedSession.getStreamList();
-            if (attachedStreams.isEmpty()) {
-                throw new CoreException(new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.LttngRelaydConsumer_NoStreams));
-            }
-
-            fTracePath = nullTerminatedByteArrayToString(attachedStreams.get(0).getPathName().getBytes());
-
-            fSession = attachedSession;
-        } catch (IOException e) {
-            throw new CoreException(new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.LttngRelaydConsumer_ErrorConnecting + (e.getMessage() != null ? e.getMessage() : ""))); //$NON-NLS-1$
-        }
-    }
-
-    /**
-     * Run the consumer operation for a give trace.
-     *
-     * @param trace
-     *            the trace
-     */
-    public void run(final CtfTmfTrace trace) {
-        if (fSession == null) {
-            return;
-        }
-
-        fCtfTmfTrace = trace;
-        fConsumerJob = new Job("RelayD consumer") { //$NON-NLS-1$
-
-            @Override
-            protected IStatus run(final IProgressMonitor monitor) {
-                try {
-                    while (!monitor.isCanceled()) {
-                        List<StreamResponse> attachedStreams = fSession.getStreamList();
-                        for (StreamResponse stream : attachedStreams) {
-                            if (stream.getMetadataFlag() != 1) {
-                                IndexResponse indexReply = fRelayd.getNextIndex(stream);
-                                if (indexReply.getStatus() == NextIndexReturnCode.VIEWER_INDEX_OK) {
-                                    long nanoTimeStamp = fCtfTmfTrace.timestampCyclesToNanos(indexReply.getTimestampEnd());
-                                    if (nanoTimeStamp > fTimestampEnd) {
-                                        TmfNanoTimestamp endTime = new TmfNanoTimestamp(nanoTimeStamp);
-                                        TmfTimeRange range = new TmfTimeRange(fCtfTmfTrace.getStartTime(), endTime);
-
-                                        long currentTime = System.nanoTime();
-                                        if (currentTime - fLastSignal > SIGNAL_THROTTLE_NANOSEC) {
-                                            TmfTraceRangeUpdatedSignal signal = new TmfTraceRangeUpdatedSignal(LttngRelaydConsumer.this, fCtfTmfTrace, range);
-                                            fCtfTmfTrace.broadcastAsync(signal);
-                                            fLastSignal = currentTime;
-                                        }
-                                        fTimestampEnd = nanoTimeStamp;
-                                    }
-                                } else if (indexReply.getStatus() == NextIndexReturnCode.VIEWER_INDEX_HUP) {
-                                    // The trace is now complete because the trace session was destroyed
-                                    fCtfTmfTrace.setComplete(true);
-                                    TmfTraceRangeUpdatedSignal signal = new TmfTraceRangeUpdatedSignal(LttngRelaydConsumer.this, fCtfTmfTrace, new TmfTimeRange(fCtfTmfTrace.getStartTime(), new TmfNanoTimestamp(fTimestampEnd)));
-                                    fCtfTmfTrace.broadcastAsync(signal);
-                                    return Status.OK_STATUS;
-                                }
-                            }
-                        }
-                    }
-                } catch (IOException e) {
-                    Activator.getDefault().logError("Error during live trace reading", e); //$NON-NLS-1$
-                    return new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.LttngRelaydConsumer_ErrorLiveReading + (e.getMessage() != null ? e.getMessage() : "")); //$NON-NLS-1$
-                }
-
-                return Status.OK_STATUS;
-            }
-        };
-        fConsumerJob.setSystem(true);
-        fConsumerJob.schedule();
-    }
-
-    /**
-     * Dispose the consumer and it's resources (sockets, etc).
-     */
-    public void dispose() {
-        try {
-            if (fConsumerJob != null) {
-                fConsumerJob.cancel();
-                fConsumerJob.join();
-            }
-            if (fConnection != null) {
-                fConnection.close();
-            }
-            if (fRelayd != null) {
-                fRelayd.close();
-            }
-        } catch (IOException e) {
-            // Ignore
-        } catch (InterruptedException e) {
-            // Ignore
-        }
-    }
-
-    /**
-     * Once the consumer is connected to the relayd session, it knows the trace
-     * path. This can be useful to know exactly where the trace is so that it
-     * can be imported into the workspace and it can be opened.
-     *
-     * @return the trace path
-     */
-    public String getTracePath() {
-        return fTracePath;
-    }
-
-    private static String nullTerminatedByteArrayToString(final byte[] byteArray) throws UnsupportedEncodingException {
-        // Find length of null terminated string
-        int length = 0;
-        while (length < byteArray.length && byteArray[length] != 0) {
-            length++;
-        }
-
-        String asessionName = new String(byteArray, 0, length, ENCODING_UTF_8);
-        return asessionName;
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/relayd/Messages.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/relayd/Messages.java
deleted file mode 100644 (file)
index 9632cd5..0000000
+++ /dev/null
@@ -1,71 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014 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:
- *   Marc-Andre Laperle - Initial implementation
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.ui.relayd;
-
-import org.eclipse.osgi.util.NLS;
-
-/**
- * Messages for the relayd connection.
- *
- * @author Marc-Andre Laperle
- */
-public final class Messages extends NLS {
-    private static final String BUNDLE_NAME = "org.eclipse.tracecompass.internal.lttng2.control.ui.relayd.messages"; //$NON-NLS-1$
-
-    /**
-     * Error occurred establishing the connection.
-     */
-    public static String LttngRelaydConnectionManager_ConnectionError;
-
-    /**
-     * Error occurred attaching to the session.
-     */
-    public static String LttngRelaydConsumer_AttachSessionError;
-
-    /**
-     * Error occurred creating the viewer session.
-     */
-    public static String LttngRelaydConsumer_CreateViewerSessionError;
-
-    /**
-     * Error occurred connecting to the relayd.
-     */
-    public static String LttngRelaydConsumer_ErrorConnecting;
-
-    /**
-     * Error (generic) during live reading.
-     */
-    public static String LttngRelaydConsumer_ErrorLiveReading;
-
-    /**
-     * No metadata for this trace session.
-     */
-    public static String LttngRelaydConsumer_NoMetadata;
-
-    /**
-     * No streams for this trace session.
-     */
-    public static String LttngRelaydConsumer_NoStreams;
-
-    /**
-     * The session was not found by the relayd.
-     */
-    public static String LttngRelaydConsumer_SessionNotFound;
-    static {
-        // initialize resource bundle
-        NLS.initializeMessages(BUNDLE_NAME, Messages.class);
-    }
-
-    private Messages() {
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/relayd/messages.properties b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/relayd/messages.properties
deleted file mode 100644 (file)
index e76b1d2..0000000
+++ /dev/null
@@ -1,20 +0,0 @@
-###############################################################################
-# Copyright (c) 2014 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:
-#   Marc-Andre Laperle - initial API and implementation
-###############################################################################
-
-LttngRelaydConnectionManager_ConnectionError=The connection to the relayd could not be established. The trace cannot be opened in Live mode.
-LttngRelaydConsumer_AttachSessionError=Error, could not attach to session, error code: 
-LttngRelaydConsumer_CreateViewerSessionError=Error, could not create viewer session, error code: 
-LttngRelaydConsumer_ErrorConnecting=Error connecting to live trace session.
-LttngRelaydConsumer_ErrorLiveReading=Error during live trace reading.
-LttngRelaydConsumer_NoMetadata=Error, trace has no metadata.
-LttngRelaydConsumer_NoStreams=Error, has no streams.
-LttngRelaydConsumer_SessionNotFound=Error, live session not found
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/ControlView.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/ControlView.java
deleted file mode 100644 (file)
index a25d4cf..0000000
+++ /dev/null
@@ -1,247 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2009, 2015 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:
- *   Francois Chouinard - Initial API and implementation
- *   Bernd Hufmann - Filled with content
- *   Markus Schorn - Bug 448058: Use org.eclipse.remote in favor of RSE
- *******************************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.jface.action.MenuManager;
-import org.eclipse.jface.viewers.ColumnViewerToolTipSupport;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.jface.viewers.TreeViewer;
-import org.eclipse.remote.core.IRemoteConnection;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Menu;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponentChangedListener;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceControlContentProvider;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceControlLabelProvider;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceControlRoot;
-import org.eclipse.tracecompass.tmf.remote.core.proxy.TmfRemoteConnectionFactory;
-import org.eclipse.ui.IMemento;
-import org.eclipse.ui.IViewSite;
-import org.eclipse.ui.PartInitException;
-import org.eclipse.ui.part.ViewPart;
-import org.eclipse.ui.progress.UIJob;
-
-/**
- * <p>
- * View implementation for Trace Control.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class ControlView extends ViewPart implements ITraceControlComponentChangedListener {
-
-    // ------------------------------------------------------------------------
-    // Constants
-    // ------------------------------------------------------------------------
-
-    /**
-     * View ID.
-     */
-    public static final String ID = "org.eclipse.linuxtools.internal.lttng2.ui.views.control"; //$NON-NLS-1$
-
-    private static final String KEY_REMOTE_CONNECTION_NAME = "rc_name_"; //$NON-NLS-1$
-    private static final String KEY_REMOTE_PROVIDER = "rc_id_"; //$NON-NLS-1$
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-
-    /**
-     * The tree viewer.
-     */
-    private TreeViewer fTreeViewer = null;
-
-    /**
-     * The trace control root node. This provides access to the whole model.
-     */
-    private ITraceControlComponent fRoot = null;
-
-    private List<IRemoteConnection> fInitialConnections;
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    /**
-     * Returns the trace control tree node (model)
-     *
-     * @return the trace control tree node (model).
-     */
-    public ITraceControlComponent getTraceControlRoot() {
-        return fRoot;
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    public void createPartControl(Composite parent) {
-        // Create tree viewer
-        fTreeViewer = new TreeViewer(parent, SWT.MULTI | SWT.H_SCROLL | SWT.V_SCROLL);
-        ColumnViewerToolTipSupport.enableFor(fTreeViewer);
-
-        fTreeViewer.setContentProvider(new TraceControlContentProvider());
-        fTreeViewer.setLabelProvider(new TraceControlLabelProvider());
-
-        // Create model root
-        fRoot = new TraceControlRoot();
-        fRoot.addComponentListener(this);
-        if (fInitialConnections != null) {
-            for (IRemoteConnection rc : fInitialConnections) {
-                TargetNodeComponent node = new TargetNodeComponent(rc.getName(), fRoot, rc);
-                fRoot.addChild(node);
-            }
-            fInitialConnections = null;
-        }
-        fTreeViewer.setInput(fRoot);
-
-        // Create context menu for the tree viewer
-        createContextMenu();
-
-        getSite().setSelectionProvider(fTreeViewer);
-    }
-
-    @Override
-    public void saveState(IMemento memento) {
-        int i = 0;
-        for (ITraceControlComponent cmp : fRoot.getChildren()) {
-            if (cmp instanceof TargetNodeComponent) {
-                IRemoteConnection rc = ((TargetNodeComponent) cmp).getRemoteSystemProxy().getRemoteConnection();
-                memento.putString(KEY_REMOTE_PROVIDER + i, rc.getConnectionType().getId());
-                memento.putString(KEY_REMOTE_CONNECTION_NAME + i, rc.getName());
-                i++;
-            }
-        }
-        super.saveState(memento);
-    }
-
-
-    @Override
-    public void init(IViewSite site, IMemento memento) throws PartInitException {
-        super.init(site, memento);
-        if (memento != null) {
-            fInitialConnections = new ArrayList<>();
-            for(int i = 0; ; i++) {
-                String id = memento.getString(KEY_REMOTE_PROVIDER + i);
-                String name = memento.getString(KEY_REMOTE_CONNECTION_NAME + i);
-                if ((id == null) || (name == null)) {
-                    break;
-                }
-                IRemoteConnection conn = TmfRemoteConnectionFactory.getRemoteConnection(id, name);
-                if (conn != null) {
-                    fInitialConnections.add(conn);
-                }
-            }
-        }
-    }
-
-    @Override
-    public void setFocus() {
-        fTreeViewer.getControl().setFocus();
-    }
-
-    @Override
-    public void componentAdded(ITraceControlComponent parent, ITraceControlComponent component) {
-        componentChanged(parent);
-    }
-
-    @Override
-    public void componentRemoved(ITraceControlComponent parent, ITraceControlComponent component) {
-        componentChanged(parent);
-    }
-
-    @Override
-    public void componentChanged(final ITraceControlComponent component) {
-        if (fTreeViewer.getTree().isDisposed()) {
-            return;
-        }
-
-        UIJob myJob = new UIJob("Refresh") { //$NON-NLS-1$
-            @Override
-            public IStatus runInUIThread(IProgressMonitor monitor) {
-                if (fTreeViewer.getTree().isDisposed()) {
-                    return Status.OK_STATUS;
-                }
-
-                fTreeViewer.refresh(component);
-
-                // Change selection needed
-                final ISelection sel = fTreeViewer.getSelection();
-                fTreeViewer.setSelection(null);
-                fTreeViewer.setSelection(sel);
-
-                // Show component that was changed
-                fTreeViewer.reveal(component);
-
-                return Status.OK_STATUS;
-            }
-        };
-        myJob.setUser(false);
-        myJob.setSystem(true);
-        myJob.schedule();
-    }
-
-    /**
-     * Sets the selected component in the tree
-     * @param component - component to select
-     */
-    public void setSelection(ITraceControlComponent component) {
-        ITraceControlComponent[] components = new ITraceControlComponent[1];
-        components[0] = component;
-        setSelection(components);
-    }
-
-    /**
-     * Sets the selected components in the tree
-     * @param components - array of components to select
-     */
-    public void setSelection(ITraceControlComponent[] components) {
-        final StructuredSelection selection = new StructuredSelection(components);
-        UIJob myJob = new UIJob("Select") { //$NON-NLS-1$
-            @Override
-            public IStatus runInUIThread(IProgressMonitor monitor) {
-                fTreeViewer.setSelection(selection);
-                return Status.OK_STATUS;
-            }
-        };
-        myJob.setUser(false);
-        myJob.schedule();
-    }
-
-    // ------------------------------------------------------------------------
-    // Helper methods
-    // ------------------------------------------------------------------------
-    /**
-     * Creates the context sensitive menu.
-     */
-    private void createContextMenu() {
-        // First we create a menu Manager
-        final MenuManager menuManager = new MenuManager();
-        final Menu menu = menuManager.createContextMenu(fTreeViewer.getTree());
-        // Set the MenuManager
-        fTreeViewer.getTree().setMenu(menu);
-        getSite().registerContextMenu(menuManager, fTreeViewer);
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/AddContextDialog.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/AddContextDialog.java
deleted file mode 100644 (file)
index 7e2fa71..0000000
+++ /dev/null
@@ -1,420 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
-
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.jface.dialogs.Dialog;
-import org.eclipse.jface.dialogs.IDialogConstants;
-import org.eclipse.jface.viewers.CheckStateChangedEvent;
-import org.eclipse.jface.viewers.CheckboxTreeViewer;
-import org.eclipse.jface.viewers.ColumnLabelProvider;
-import org.eclipse.jface.viewers.ICheckStateListener;
-import org.eclipse.jface.viewers.ITreeContentProvider;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.graphics.Point;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Group;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
-
-/**
- * <p>
- * Dialog box for collecting information about contexts to be added to channels/events.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class AddContextDialog extends Dialog implements IAddContextDialog  {
-
-    // ------------------------------------------------------------------------
-    // Constants
-    // ------------------------------------------------------------------------
-
-    /**
-     * The icon file for this dialog box.
-     */
-    public static final String ADD_CONTEXT_ICON_FILE = "icons/elcl16/add-context.gif"; //$NON-NLS-1$
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-
-    /**
-     * A tree viewer for displaying and selection of available contexts.
-     */
-    private CheckboxTreeViewer fContextsViewer;
-
-    /**
-     * A Tree model for the checkbox tree viewer.
-     */
-    private final ContextModel fContextModel = new ContextModel();
-
-    /**
-     * The contexts to add.
-     */
-    private final List<String> fSelectedContexts = new ArrayList<>();
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-
-    /**
-     * Constructor
-     * @param shell - a shell for the display of the dialog
-     */
-    public AddContextDialog(Shell shell) {
-        super(shell);
-        setShellStyle(SWT.RESIZE | getShellStyle());
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    @Override
-    public void setAvalibleContexts(List<String> contexts) {
-        fContextModel.setAvalibleContexts(contexts);
-    }
-
-    @Override
-    public List<String> getContexts() {
-        List<String> ret = new ArrayList<>();
-        ret.addAll(fSelectedContexts);
-        return ret;
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    protected void configureShell(Shell newShell) {
-        super.configureShell(newShell);
-        newShell.setText(Messages.TraceControl_AddContextDialogTitle);
-        newShell.setImage(Activator.getDefault().loadIcon(ADD_CONTEXT_ICON_FILE));
-    }
-
-    @Override
-    protected Control createDialogArea(Composite parent) {
-
-        // Main dialog panel
-        Composite dialogComposite = new Composite(parent, SWT.NONE);
-        GridLayout layout = new GridLayout(1, true);
-        dialogComposite.setLayout(layout);
-        dialogComposite.setLayoutData(new GridData(GridData.FILL_BOTH));
-
-        // Contexts list
-        Group contextGroup = new Group(dialogComposite, SWT.SHADOW_NONE);
-        contextGroup.setText(Messages.TraceControl_AddContextAvailableContextsLabel);
-        layout = new GridLayout(1, true);
-        contextGroup.setLayout(layout);
-        contextGroup.setLayoutData(new GridData(GridData.FILL_BOTH));
-
-        fContextsViewer = new CheckboxTreeViewer(contextGroup, SWT.MULTI | SWT.H_SCROLL | SWT.V_SCROLL);
-        fContextsViewer.getTree().setToolTipText(Messages.TraceControl_AddContextAvailableContextsTooltip);
-
-        fContextsViewer.setContentProvider(new ContextsContentProvider());
-        fContextsViewer.setLabelProvider(new ContextsLabelProvider());
-        fContextsViewer.addCheckStateListener(new ContextCheckListener());
-        fContextsViewer.setInput(fContextModel);
-        fContextsViewer.getTree().setLayoutData(new GridData(GridData.FILL_BOTH));
-
-        getShell().setMinimumSize(new Point(500, 450));
-
-        return dialogComposite;
-    }
-
-    @Override
-    protected void createButtonsForButtonBar(Composite parent) {
-        createButton(parent, IDialogConstants.CANCEL_ID, "&Cancel", true); //$NON-NLS-1$
-        createButton(parent, IDialogConstants.OK_ID, "&Ok", true); //$NON-NLS-1$
-    }
-
-    @Override
-    protected void okPressed() {
-        fSelectedContexts.clear();
-
-        Object[] checkedElements = fContextsViewer.getCheckedElements();
-        for (int i = 0; i < checkedElements.length; i++) {
-            IContextModelComponent component = (IContextModelComponent)checkedElements[i];
-            if (!Messages.TraceControl_AddContextAllLabel.equals(component.getName())) {
-                fSelectedContexts.add(component.getName());
-            }
-        }
-
-        // validation successful -> call super.okPressed()
-        super.okPressed();
-    }
-
-    // ------------------------------------------------------------------------
-    // Helper classes and methods
-    // ------------------------------------------------------------------------
-    /**
-     * Content provider for the contexts tree
-     */
-    public static final class ContextsContentProvider implements ITreeContentProvider {
-
-        @Override
-        public void dispose() {
-        }
-
-        @Override
-        public void inputChanged(Viewer viewer, Object oldInput, Object newInput) {
-        }
-
-        @Override
-        public Object[] getElements(Object inputElement) {
-            return getChildren(inputElement);
-        }
-
-        @Override
-        public Object[] getChildren(Object parentElement) {
-            if (parentElement instanceof IContextModelComponent) {
-                return ((IContextModelComponent)parentElement).getChildren();
-            }
-            return null;
-        }
-
-        @Override
-        public Object getParent(Object element) {
-            if (element instanceof IContextModelComponent) {
-                return ((IContextModelComponent)element).getParent();
-            }
-            return null;
-        }
-
-        @Override
-        public boolean hasChildren(Object element) {
-            if (element instanceof IContextModelComponent) {
-                return ((IContextModelComponent)element).hasChildren();
-            }
-            return false;
-        }
-    }
-
-    /**
-     * Label provider for the contexts tree
-     */
-    public static final class ContextsLabelProvider extends ColumnLabelProvider {
-        @Override
-        public String getText(Object element) {
-
-            if ((element != null) && (element instanceof IContextModelComponent)) {
-                return ((IContextModelComponent)element).getName();
-            }
-
-            return "";//$NON-NLS-1$
-        }
-    }
-
-    /**
-     * Check state listener for the contexts tree.
-     */
-    public final class ContextCheckListener implements ICheckStateListener {
-        @Override
-        public void checkStateChanged(CheckStateChangedEvent event) {
-          if (event.getChecked()) {
-              if (event.getElement() instanceof AllContexts) {
-                  fContextsViewer.setSubtreeChecked(event.getElement(), true);
-              }
-          } else {
-              if (event.getElement() instanceof AllContexts) {
-                  fContextsViewer.setSubtreeChecked(event.getElement(), false);
-              } else {
-                  IContextModelComponent component = (IContextModelComponent) event.getElement();
-                  fContextsViewer.setChecked(component.getParent(), false);
-              }
-          }
-        }
-    }
-
-    /**
-     * Model for the context tree viewer (root component)
-     */
-    public static class ContextModel implements IContextModelComponent {
-
-        private final AllContexts fAllContexts;
-
-        /**
-         * Constructor
-         */
-        public ContextModel() {
-            fAllContexts = new AllContexts(this);
-        }
-
-        /**
-         * Sets the available contexts
-         *
-         * @param contexts
-         *            The contexts to set
-         */
-        public void setAvalibleContexts(List<String> contexts) {
-            fAllContexts.setAvalibleContexts(contexts);
-        }
-
-        @Override
-        public String getName() {
-            return "root"; //$NON-NLS-1$
-        }
-
-        @Override
-        public Object getParent() {
-            return null;
-        }
-
-        @Override
-        public Object[] getChildren() {
-            Object[] ret = new Object[1];
-            ret[0] = fAllContexts;
-            return ret;
-        }
-
-        @Override
-        public boolean hasChildren() {
-            return true;
-        }
-    }
-
-    /**
-     * Model element (to select/deselect) all contexts) for the context tree viewer
-     */
-    public static class AllContexts implements IContextModelComponent {
-        /**
-         * The available list of contexts.
-         */
-        private List<Context> fAvailableContexts;
-
-        private final IContextModelComponent fParent;
-
-        /**
-         * Constructor
-         *
-         * @param parent
-         *            The parent component
-         */
-        public AllContexts(IContextModelComponent parent) {
-            fParent = parent;
-        }
-
-        /**
-         * Sets the available contexts
-         *
-         * @param contexts
-         *            The contexts to set
-         */
-        public void setAvalibleContexts(List<String> contexts) {
-            fAvailableContexts = new ArrayList<>();
-            if (contexts != null) {
-                for (Iterator<String> iterator = contexts.iterator(); iterator.hasNext();) {
-                    String name = iterator.next();
-                    fAvailableContexts.add(new Context(this, name));
-                }
-            }
-        }
-
-        @Override
-        public String getName() {
-            return Messages.TraceControl_AddContextAllLabel;
-        }
-
-        @Override
-        public Object[] getChildren() {
-            return fAvailableContexts.toArray();
-        }
-
-        @Override
-        public Object getParent() {
-            return fParent;
-        }
-
-        @Override
-        public boolean hasChildren() {
-            return true;
-        }
-    }
-
-    /**
-     * Model element (the context) for the context tree viewer
-     */
-    public static class Context implements IContextModelComponent {
-
-        private final String fContextName;
-        private final IContextModelComponent fParent;
-
-        /**
-         * Constructor
-         *
-         * @param parent
-         *            The parent component
-         * @param name
-         *            The name of this context
-         */
-        public Context(IContextModelComponent parent, String name) {
-            fParent = parent;
-            fContextName = name;
-        }
-
-        @Override
-        public String getName() {
-            return fContextName;
-        }
-
-        @Override
-        public Object getParent() {
-            return fParent;
-        }
-
-        @Override
-        public Object[] getChildren() {
-            return null;
-        }
-
-        @Override
-        public boolean hasChildren() {
-            return false;
-        }
-    }
-
-    /**
-     * Interface for the tree model used for the context tree viewer.
-     */
-    public interface IContextModelComponent {
-
-        /**
-         * @return The name of this component
-         */
-        String getName();
-
-        /**
-         * @return The parent component
-         */
-        Object getParent();
-
-        /**
-         * @return The array of children of this component
-         */
-        Object[] getChildren();
-
-        /**
-         * @return If this component has children or not
-         */
-        boolean hasChildren();
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/ConfirmDialog.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/ConfirmDialog.java
deleted file mode 100644 (file)
index e665de5..0000000
+++ /dev/null
@@ -1,36 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
-
-
-import org.eclipse.jface.dialogs.MessageDialog;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
-
-/**
- * <p>
- * Confirmation dialog implementation.
- * </p>
- *
- * @author Bernd Hufmann
- */
-
-public class ConfirmDialog implements IConfirmDialog {
-
-    @Override
-    public boolean openConfirm(Shell parent, String title, String message) {
-        return MessageDialog.openConfirm(parent,
-                Messages.TraceControl_DestroyConfirmationTitle,
-                Messages.TraceControl_DestroyConfirmationMessage);
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/CreateSessionDialog.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/CreateSessionDialog.java
deleted file mode 100644 (file)
index 39b0c8a..0000000
+++ /dev/null
@@ -1,1027 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2015 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
- *   Marc-Andre Laperle - Support for creating a live session
- *   Markus Schorn - Bug 448058: Use org.eclipse.remote in favor of RSE
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
-
-import org.eclipse.core.filesystem.IFileInfo;
-import org.eclipse.core.filesystem.IFileStore;
-import org.eclipse.jface.dialogs.IDialogConstants;
-import org.eclipse.jface.dialogs.TitleAreaDialog;
-import org.eclipse.remote.core.IRemoteFileService;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.custom.CCombo;
-import org.eclipse.swt.events.FocusEvent;
-import org.eclipse.swt.events.FocusListener;
-import org.eclipse.swt.events.ModifyEvent;
-import org.eclipse.swt.events.ModifyListener;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.events.VerifyEvent;
-import org.eclipse.swt.events.VerifyListener;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Group;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.swt.widgets.Text;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISessionInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.SessionInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionGroup;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.service.LTTngControlServiceConstants;
-import org.eclipse.tracecompass.tmf.remote.core.proxy.RemoteSystemProxy;
-
-/**
- * <p>
- * Dialog box for collecting session creation information.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class CreateSessionDialog extends TitleAreaDialog implements ICreateSessionDialog {
-
-    // ------------------------------------------------------------------------
-    // Constants
-    // ------------------------------------------------------------------------
-    /**
-     * The icon file for this dialog box.
-     */
-    public static final String CREATE_SESSION_ICON_FILE = "icons/elcl16/add_button.gif"; //$NON-NLS-1$
-
-    /**
-     *  To indicate that the default value will be used for this field
-     */
-    private static final String DEFAULT_TEXT = "<" + Messages.EnableChannelDialog_DefaultMessage + ">"; //$NON-NLS-1$ //$NON-NLS-2$
-
-    /**
-     * Supported network protocols for streaming
-     */
-    private enum StreamingProtocol {
-        /** Default network protocol for IPv4 (TCP)*/
-        net,
-        /** Default network protocol for IPv6 (TCP)*/
-        net6,
-        /** File */
-        file,
-   }
-
-    /**
-     * Supported network protocols for Live tracing
-     */
-    private enum LiveProtocol {
-        /** Default network protocol for IPv4 (TCP)*/
-        net,
-        /** Default network protocol for IPv6 (TCP)*/
-        net6
-   }
-
-    private enum StreamingProtocol2 {
-        /** Default network protocol for IPv4 (TCP)*/
-        net,
-        /** Default network protocol for IPv6 (TCP)*/
-        net6,
-        /** TCP network protocol for IPv4*/
-        tcp,
-        /** TCP network protocol for IPv6*/
-        tcp6 }
-
-    /**
-     * Index of last supported streaming protocol for common URL configuration.
-     */
-    private static final int COMMON_URL_LAST_INDEX = 1;
-    /**
-     *  Index of default streaming protocol.
-     */
-    private static final int DEFAULT_URL_INDEX = 0;
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-    /**
-     * The dialog composite.
-     */
-    private Composite fDialogComposite = null;
-    /**
-     * The text widget for the session name
-     */
-    private Text fSessionNameText = null;
-    /**
-     * The label widget for the session path.
-     */
-    private Label fSessionPathLabel = null;
-    /**
-     * The text widget for the session path.
-     */
-    private Text fSessionPathText = null;
-    /**
-     * The button widget to select a normal session
-     */
-    private Button fNormalModeButton = null;
-    /**
-     * The button widget to select a snapshot session
-     */
-    private Button fSnapshotButton = null;
-    /**
-     * The group that contains the mutually exclusive mode buttons
-     */
-    private Group fModeButtonGroup = null;
-    /**
-     * The button widget to select a live session
-     */
-    private Button fLiveButton = null;
-
-    /**
-     * The text widget to set a live delay
-     */
-    private Text fLiveDelayText = null;
-    /**
-     * The Group for advanced configuration.
-     */
-    private Group fAdvancedGroup = null;
-    /**
-     * The button to show advanced options.
-     */
-    private Button fAdvancedButton = null;
-    /**
-     * The composite with streaming configuration parameter.
-     */
-    private Composite fStreamingComposite = null;
-    /**
-     * The text widget for the trace path.
-     */
-    private Text fTracePathText = null;
-    /**
-     * The button to link data protocol/Address with control protocol.
-     */
-    private Button fLinkDataWithControlButton = null;
-    /**
-     * The Combo box for channel protocol selection.
-     */
-     private CCombo fControlProtocolCombo = null;
-    /**
-     * A selection listener that copies the protocol from control to data when being linked.
-     */
-    private ControlProtocolSelectionListener fCopyProtocolSelectionListener;
-    /**
-     * A selection listener updates the control port text depending on the control protocol selected.
-     */
-    private ProtocolComboSelectionListener fControlProtocolSelectionListener;
-    /**
-     * A selection listener updates the data port text depending on the data protocol selected.
-     */
-    private ProtocolComboSelectionListener fDataProtocolSelectionListener;
-    /**
-     * The text box for the host/IP address of the control channel.
-     */
-    private Text fControlHostAddressText = null;
-    /**
-     * A key listener that copies the host address from control to data when being linked.
-     */
-    private CopyModifyListener fControlUrlKeyListener;
-    /**
-     * A modify listener that updates the enablement of the dialog.
-     */
-    private UpdateEnablementModifyListener fUpdateEnablementModifyListener;
-    /**
-     * The text box for the control port.
-     */
-    private Text fControlPortText = null;
-    /**
-     * The Combo box for data protocol selection.
-     */
-     private CCombo fDataProtocolCombo = null;
-    /**
-     * The text box for the host/IP address of the data channel.
-     */
-    private Text fDataHostAddressText = null;
-    /**
-     * The text box for the data port.
-     */
-    private Text fDataPortText = null;
-    /**
-     * The parent where the new node should be added.
-     */
-    private TraceSessionGroup fParent = null;
-    /**
-     * The session name string.
-     */
-    private String fSessionName = ""; //$NON-NLS-1$;
-    /**
-     * The  session path string.
-     */
-    private String fSessionPath = null;
-    /**
-     * Flag whether the session is snapshot or not
-     */
-    private boolean fIsSnapshot = false;
-    /**
-     * Flag whether the session is live or not
-     */
-    private boolean fIsLive = false;
-    /**
-     * The text box for the live address (relayd).
-     */
-    private Text fLiveHostAddressText = null;
-    /**
-     * The text box for the live port (relayd).
-     */
-    private Text fLivePortText = null;
-    /**
-     * The live delay
-     */
-    private Long fLiveDelay = 0L;
-    /**
-     * The live url.
-     */
-    private String fLiveUrl = null;
-    /**
-     * The live port.
-     */
-    private Integer fLivePort = 0;
-    /**
-     * Flag whether default location (path) shall be used or not
-     */
-    private boolean fIsDefaultPath = true;
-    /**
-     * Flag whether the advanced options are enabled or not
-     */
-    private boolean fIsAdvancedEnabled = false;
-    /**
-     * The network URL in case control and data is configured together.
-     * If set, fControlUrl and fDataUrl will be null.
-     */
-    private String fNetworkUrl = null;
-    /**
-     * The control URL in case control and data is configured separately.
-     * If set, fDataUrl will be set too and fNetworkUrl will be null.
-     */
-    private String fControlUrl = null;
-    /**
-     * The data URL in case control and data is configured separately.
-     * If set, fControlUrl will be set too and fNetworkUrl will be null.
-     */
-    private String fDataUrl = null;
-    /**
-     * The trace path string.
-     */
-    private String fTracePath = null;
-    /**
-     * The Group for advanced configuration of Live mode.
-     */
-    private Group fLiveGroup = null;
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-    /**
-     * Constructor
-     * @param shell - a shell for the display of the dialog
-     */
-    public CreateSessionDialog(Shell shell) {
-        super(shell);
-        setShellStyle(SWT.RESIZE | getShellStyle());
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    @Override
-    public void initialize(TraceSessionGroup group) {
-       fParent = group;
-       fStreamingComposite = null;
-       fLiveGroup = null;
-       fLiveButton = null;
-       fIsLive = false;
-       fSnapshotButton = null;
-       fSessionName = ""; //$NON-NLS-1$
-       fSessionPath = null;
-       fIsSnapshot = false;
-       fIsDefaultPath = true;
-       fIsAdvancedEnabled = false;
-       fNetworkUrl = null;
-       fControlUrl = null;
-       fDataUrl = null;
-    }
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    protected void configureShell(Shell newShell) {
-        super.configureShell(newShell);
-        newShell.setText(Messages.TraceControl_CreateSessionDialogTitle);
-        newShell.setImage(Activator.getDefault().loadIcon(CREATE_SESSION_ICON_FILE));
-    }
-
-    @Override
-    protected Control createDialogArea(Composite parent) {
-        Composite dialogAreaa = (Composite) super.createDialogArea(parent);
-        setTitle(Messages.TraceControl_CreateSessionDialogTitle);
-        setMessage(Messages.TraceControl_CreateSessionDialogMessage);
-
-        // Main dialog panel
-        fDialogComposite = new Composite(dialogAreaa, SWT.NONE);
-        GridLayout layout = new GridLayout(1, true);
-        fDialogComposite.setLayout(layout);
-        fDialogComposite.setLayoutData(new GridData(GridData.FILL_BOTH));
-
-        Group sessionGroup = new Group(fDialogComposite, SWT.SHADOW_NONE);
-        sessionGroup.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        sessionGroup.setLayout(new GridLayout(4, true));
-
-        fUpdateEnablementModifyListener = new UpdateEnablementModifyListener();
-
-        Label sessionNameLabel = new Label(sessionGroup, SWT.RIGHT);
-        sessionNameLabel.setText(Messages.TraceControl_CreateSessionNameLabel);
-        fSessionNameText = new Text(sessionGroup, SWT.NONE);
-        fSessionNameText.setToolTipText(Messages.TraceControl_CreateSessionNameTooltip);
-        fSessionNameText.addModifyListener(fUpdateEnablementModifyListener);
-        GridData data = new GridData(GridData.FILL_HORIZONTAL);
-        data.horizontalSpan = 3;
-        fSessionNameText.setLayoutData(data);
-
-        fSessionPathLabel = new Label(sessionGroup, SWT.RIGHT);
-        fSessionPathLabel.setText(Messages.TraceControl_CreateSessionPathLabel);
-        fSessionPathText = new Text(sessionGroup, SWT.NONE);
-        fSessionPathText.setToolTipText(Messages.TraceControl_CreateSessionPathTooltip);
-        data = new GridData(GridData.FILL_HORIZONTAL);
-        data.horizontalSpan = 3;
-        fSessionPathText.setLayoutData(data);
-        fSessionPathText.addModifyListener(fUpdateEnablementModifyListener);
-
-        if (fParent.isSnapshotSupported() || fParent.isLiveSupported()) {
-            fModeButtonGroup = new Group(sessionGroup, SWT.NONE);
-            data = new GridData(GridData.FILL_HORIZONTAL);
-            data.horizontalSpan = 4;
-            fModeButtonGroup.setLayoutData(data);
-            fModeButtonGroup.setLayout(new GridLayout(3, true));
-
-            SelectionAdapter modeChangedListener = new SelectionAdapter() {
-                @Override
-                public void widgetSelected(SelectionEvent e) {
-                    if (fLiveButton != null) {
-                        if (fLiveButton.getSelection()) {
-                            createAdvancedLiveGroup();
-                            updateSessionPathEnablement();
-                            updateProtocolComboItems();
-                        } else {
-                            disposeLiveGroup();
-                            updateSessionPathEnablement();
-                            updateProtocolComboItems();
-                        }
-                    }
-                    updateEnablement();
-                }
-            };
-
-            fNormalModeButton = new Button(fModeButtonGroup, SWT.RADIO);
-            fNormalModeButton.setText(Messages.TraceControl_CreateSessionNormalLabel);
-            fNormalModeButton.setToolTipText(Messages.TraceControl_CreateSessionNormalTooltip);
-            fNormalModeButton.setSelection(true);
-            fNormalModeButton.addSelectionListener(modeChangedListener);
-
-            if (fParent.isSnapshotSupported()) {
-                fSnapshotButton = new Button(fModeButtonGroup, SWT.RADIO);
-                fSnapshotButton.setText(Messages.TraceControl_CreateSessionSnapshotLabel);
-                fSnapshotButton.setToolTipText(Messages.TraceControl_CreateSessionSnapshotTooltip);
-                fSnapshotButton.addSelectionListener(modeChangedListener);
-            }
-
-            if (fParent.isLiveSupported()) {
-                fLiveButton = new Button(fModeButtonGroup, SWT.RADIO);
-                fLiveButton.setText(Messages.TraceControl_CreateSessionLiveLabel);
-                fLiveButton.setToolTipText(Messages.TraceControl_CreateSessionLiveTooltip);
-                fLiveButton.addSelectionListener(modeChangedListener);
-            }
-        }
-
-        if (fParent.isNetworkStreamingSupported() || fParent.isLiveSupported()) {
-            createAdvancedOptionsComposite();
-        }
-
-        return fDialogComposite;
-    }
-
-    private void createAdvancedOptionsComposite() {
-
-        fAdvancedGroup = new Group(fDialogComposite, SWT.SHADOW_NONE);
-        fAdvancedGroup.setLayoutData(new GridData(GridData.FILL_BOTH));
-        fAdvancedGroup.setLayout(new GridLayout(1, true));
-
-        fAdvancedButton = new Button(fAdvancedGroup, SWT.PUSH);
-        fAdvancedButton.setText(Messages.TraceControl_CreateSessionConfigureStreamingButtonText + " >>>"); //$NON-NLS-1$
-        fAdvancedButton.setToolTipText(Messages.TraceControl_CreateSessionConfigureStreamingButtonTooltip);
-        fAdvancedButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                if (fIsAdvancedEnabled) {
-                    fIsAdvancedEnabled = false;
-                    fAdvancedButton.setText(">>> " + Messages.TraceControl_CreateSessionConfigureStreamingButtonText); //$NON-NLS-1$
-                    fAdvancedButton.setToolTipText(Messages.TraceControl_CreateSessionConfigureStreamingButtonTooltip);
-
-                    if (fParent.isNetworkStreamingSupported()) {
-                        updateSessionPathEnablement();
-                        disposeConfigureStreamingComposite();
-                    }
-
-                    if (fParent.isLiveSupported()) {
-                        disposeLiveGroup();
-                    }
-                } else {
-                    fIsAdvancedEnabled = true;
-                    fAdvancedButton.setText("<<< " + Messages.TraceControl_CreateSessionNoStreamingButtonText); //$NON-NLS-1$
-                    fAdvancedButton.setToolTipText(Messages.TraceControl_CreateSessionNoStreamingButtonTooltip);
-
-                    if (fParent.isNetworkStreamingSupported()) {
-                        updateSessionPathEnablement();
-                        createConfigureStreamingComposite();
-                    }
-                    if (fLiveButton != null && fLiveButton.getSelection()) {
-                        createAdvancedLiveGroup();
-                    }
-                }
-
-                updateEnablement();
-                getShell().pack();
-            }
-        });
-    }
-
-    private void updateSessionPathEnablement() {
-        if (fIsAdvancedEnabled || fIsLive) {
-            fSessionPathText.setEnabled(false);
-            fSessionPathText.setText(""); //$NON-NLS-1$
-            fSessionPathLabel.setText(""); //$NON-NLS-1$
-        } else {
-            fSessionPathText.setEnabled(true);
-            fSessionPathLabel.setText(Messages.TraceControl_CreateSessionPathLabel);
-        }
-    }
-
-    private void updateProtocolComboItems() {
-        if (fControlProtocolCombo == null || fControlProtocolCombo.isDisposed()) {
-            return;
-        }
-
-        int currentSelection = fControlProtocolCombo.getSelectionIndex() <= COMMON_URL_LAST_INDEX ?
-                fControlProtocolCombo.getSelectionIndex() : DEFAULT_URL_INDEX;
-
-        fControlProtocolCombo.removeAll();
-        Enum<? extends Enum<?>>[] values;
-        if (fIsLive) {
-            values = LiveProtocol.values();
-        } else if (fLinkDataWithControlButton.getSelection()) {
-            values = StreamingProtocol.values();
-        } else {
-            values = StreamingProtocol2.values();
-        }
-
-        String[] controlItems = new String[values.length];
-        for (int i = 0; i < controlItems.length; i++) {
-            controlItems[i] = values[i].name();
-        }
-        fControlProtocolCombo.setItems(controlItems);
-        fDataProtocolCombo.setItems(controlItems);
-
-        // Set selection
-        if (currentSelection != -1) {
-            fControlProtocolCombo.select(currentSelection);
-            fDataProtocolCombo.select(currentSelection);
-        }
-    }
-
-    private void createConfigureStreamingComposite() {
-        if (fStreamingComposite == null) {
-            fStreamingComposite = new Group(fAdvancedGroup, SWT.SHADOW_NONE);
-            GridLayout layout = new GridLayout(1, true);
-            fStreamingComposite.setLayout(layout);
-            fStreamingComposite.setLayoutData(new GridData(GridData.FILL_BOTH));
-
-            layout = new GridLayout(7, true);
-            fStreamingComposite.setLayout(layout);
-            fStreamingComposite.setLayoutData(new GridData(GridData.FILL_BOTH));
-
-            Label tracePathLabel = new Label(fStreamingComposite, SWT.RIGHT);
-            tracePathLabel.setText(Messages.TraceControl_CreateSessionTracePathText);
-            fTracePathText = new Text(fStreamingComposite, SWT.NONE);
-            fTracePathText.setToolTipText(Messages.TraceControl_CreateSessionTracePathTooltip);
-
-            // layout widgets
-            GridData data = new GridData(GridData.FILL_HORIZONTAL);
-            data.horizontalSpan = 6;
-            fTracePathText.setLayoutData(data);
-            fTracePathText.addModifyListener(fUpdateEnablementModifyListener);
-
-            fLinkDataWithControlButton = new Button(fStreamingComposite, SWT.CHECK);
-            fLinkDataWithControlButton.setText(Messages.TraceControl_CreateSessionLinkButtonText);
-            fLinkDataWithControlButton.setToolTipText(Messages.TraceControl_CreateSessionLinkButtonTooltip);
-            data = new GridData(GridData.FILL_HORIZONTAL);
-            data.horizontalSpan = 7;
-            fLinkDataWithControlButton.setLayoutData(data);
-            fLinkDataWithControlButton.setSelection(true);
-
-            Label label = new Label(fStreamingComposite, SWT.NONE);
-            data = new GridData(GridData.FILL_HORIZONTAL);
-            data.horizontalSpan = 1;
-            label.setLayoutData(data);
-
-            label = new Label(fStreamingComposite, SWT.NONE);
-            label.setText(Messages.TraceControl_CreateSessionProtocolLabelText);
-            data = new GridData(GridData.FILL_HORIZONTAL);
-            data.horizontalSpan = 1;
-            label.setLayoutData(data);
-
-            label = new Label(fStreamingComposite, SWT.NONE);
-            label.setText(Messages.TraceControl_CreateSessionAddressLabelText);
-            data = new GridData(GridData.FILL_HORIZONTAL);
-            data.horizontalSpan = 4;
-            label.setLayoutData(data);
-
-            label = new Label(fStreamingComposite, SWT.NONE);
-            label.setText(Messages.TraceControl_CreateSessionPortLabelText);
-            data = new GridData(GridData.FILL_HORIZONTAL);
-            data.horizontalSpan = 1;
-            label.setLayoutData(data);
-
-            label = new Label(fStreamingComposite, SWT.RIGHT);
-            label.setText(Messages.TraceControl_CreateSessionControlUrlLabel);
-            data = new GridData(GridData.FILL_HORIZONTAL);
-            data.horizontalSpan = 1;
-            label.setLayoutData(data);
-
-            fControlProtocolCombo = new CCombo(fStreamingComposite, SWT.READ_ONLY);
-            fControlProtocolCombo.setToolTipText(Messages.TraceControl_CreateSessionCommonProtocolTooltip);
-            data = new GridData(GridData.FILL_HORIZONTAL);
-            data.horizontalSpan = 1;
-            fControlProtocolCombo.setLayoutData(data);
-            fControlProtocolCombo.addModifyListener(fUpdateEnablementModifyListener);
-
-            fControlHostAddressText = new Text(fStreamingComposite, SWT.NONE);
-            fControlHostAddressText.setToolTipText(Messages.TraceControl_CreateSessionControlAddressTooltip);
-            data = new GridData(GridData.FILL_HORIZONTAL);
-            data.horizontalSpan = 4;
-            fControlHostAddressText.setLayoutData(data);
-            fControlHostAddressText.addModifyListener(fUpdateEnablementModifyListener);
-
-            fControlPortText = new Text(fStreamingComposite, SWT.NONE);
-            fControlPortText.setToolTipText(Messages.TraceControl_CreateSessionControlPortTooltip);
-            data = new GridData(GridData.FILL_HORIZONTAL);
-            data.horizontalSpan = 1;
-            fControlPortText.setLayoutData(data);
-            fControlPortText.addModifyListener(fUpdateEnablementModifyListener);
-
-            label = new Label(fStreamingComposite, SWT.RIGHT);
-            label.setText(Messages.TraceControl_CreateSessionDataUrlLabel);
-            data = new GridData(GridData.FILL_HORIZONTAL);
-            data.horizontalSpan = 1;
-            label.setLayoutData(data);
-
-            fDataProtocolCombo = new CCombo(fStreamingComposite, SWT.READ_ONLY);
-            fDataProtocolCombo.setEnabled(false);
-            fDataProtocolCombo.setToolTipText(Messages.TraceControl_CreateSessionProtocolTooltip);
-            data = new GridData(GridData.FILL_HORIZONTAL);
-            data.horizontalSpan = 1;
-            fDataProtocolCombo.setLayoutData(data);
-            fDataProtocolCombo.addModifyListener(fUpdateEnablementModifyListener);
-
-            updateProtocolComboItems();
-
-            fDataHostAddressText = new Text(fStreamingComposite, SWT.NONE);
-            fDataHostAddressText.setEnabled(false);
-            fDataHostAddressText.setToolTipText(Messages.TraceControl_CreateSessionDataAddressTooltip);
-            data = new GridData(GridData.FILL_HORIZONTAL);
-            data.horizontalSpan = 4;
-            fDataHostAddressText.setLayoutData(data);
-            fDataHostAddressText.addModifyListener(fUpdateEnablementModifyListener);
-
-            fDataPortText = new Text(fStreamingComposite, SWT.NONE);
-            fDataPortText.setEnabled(true);
-            fDataPortText.setToolTipText(Messages.TraceControl_CreateSessionDataPortTooltip);
-            data = new GridData(GridData.FILL_HORIZONTAL);
-            data.horizontalSpan = 1;
-            fDataPortText.setLayoutData(data);
-            fDataPortText.addModifyListener(fUpdateEnablementModifyListener);
-
-            fCopyProtocolSelectionListener = new ControlProtocolSelectionListener();
-            fControlProtocolSelectionListener = new ProtocolComboSelectionListener(fControlProtocolCombo, fControlPortText);
-            fDataProtocolSelectionListener = new ProtocolComboSelectionListener(fDataProtocolCombo, fDataPortText);
-
-            fControlProtocolCombo.addSelectionListener(fCopyProtocolSelectionListener);
-
-            fControlUrlKeyListener = new CopyModifyListener(fControlHostAddressText, fDataHostAddressText);
-            fControlHostAddressText.addModifyListener(fControlUrlKeyListener);
-
-            fControlProtocolCombo.select(DEFAULT_URL_INDEX);
-            fDataProtocolCombo.select(DEFAULT_URL_INDEX);
-
-            fLinkDataWithControlButton.addSelectionListener(new SelectionAdapter() {
-                @Override
-                public void widgetSelected(SelectionEvent e) {
-                    if (fLinkDataWithControlButton.getSelection()) {
-                        // Set enablement control data channel inputs
-                        fDataProtocolCombo.setEnabled(false);
-                        fDataHostAddressText.setEnabled(false);
-                        fControlPortText.setEnabled(true);
-                        fDataPortText.setEnabled(true);
-
-                        // Update listeners
-                        fControlProtocolCombo.removeSelectionListener(fControlProtocolSelectionListener);
-                        fDataProtocolCombo.removeSelectionListener(fDataProtocolSelectionListener);
-                        fControlProtocolCombo.addSelectionListener(fCopyProtocolSelectionListener);
-                        fControlHostAddressText.addModifyListener(fControlUrlKeyListener);
-
-                        updateProtocolComboItems();
-
-                        fDataHostAddressText.setText(fControlHostAddressText.getText());
-
-                        // Update tool tips
-                        fControlProtocolCombo.setToolTipText(Messages.TraceControl_CreateSessionCommonProtocolTooltip);
-                    } else {
-                        // Enable data channel inputs
-                        fDataProtocolCombo.setEnabled(true);
-                        fDataHostAddressText.setEnabled(true);
-
-                        // Update listeners
-                        fControlProtocolCombo.removeSelectionListener(fCopyProtocolSelectionListener);
-                        fControlProtocolCombo.addSelectionListener(fControlProtocolSelectionListener);
-                        fDataProtocolCombo.addSelectionListener(fDataProtocolSelectionListener);
-                        fControlHostAddressText.removeModifyListener(fControlUrlKeyListener);
-
-                        updateProtocolComboItems();
-
-                        // Update tool tips
-                        fDataProtocolCombo.setToolTipText(Messages.TraceControl_CreateSessionProtocolTooltip);
-                        fControlProtocolCombo.setToolTipText(Messages.TraceControl_CreateSessionProtocolTooltip);
-
-                        // Update control/data port enablement and input
-                        if (fControlProtocolCombo.getItem(fControlProtocolCombo.getSelectionIndex()).equals(StreamingProtocol.net.name()) ||
-                                fControlProtocolCombo.getItem(fControlProtocolCombo.getSelectionIndex()).equals(StreamingProtocol.net6.name())) {
-                            fControlPortText.setText(""); //$NON-NLS-1$
-                            fControlPortText.setEnabled(false);
-                        } else {
-                            fControlPortText.setEnabled(true);
-                        }
-
-                        if (fDataProtocolCombo.getItem(fDataProtocolCombo.getSelectionIndex()).equals(StreamingProtocol.net.name()) ||
-                                fDataProtocolCombo.getItem(fDataProtocolCombo.getSelectionIndex()).equals(StreamingProtocol.net6.name())) {
-                            fDataPortText.setText(""); //$NON-NLS-1$
-                            fDataPortText.setEnabled(false);
-                        } else {
-                            fDataPortText.setEnabled(true);
-                        }
-                    }
-                }
-            });
-        }
-    }
-
-    private void createAdvancedLiveGroup() {
-        if (fLiveGroup == null && fIsAdvancedEnabled) {
-            GridLayout layout = new GridLayout(7, true);
-            fLiveGroup = new Group(fAdvancedGroup, SWT.NONE);
-            fLiveGroup.setLayout(layout);
-            GridData layoutData = new GridData(GridData.FILL_BOTH);
-            fLiveGroup.setLayoutData(layoutData);
-
-            Label label = new Label(fLiveGroup, SWT.NONE);
-            label.setText(Messages.TraceControl_CreateSessionLiveConnectionLabel);
-            layoutData = new GridData(GridData.FILL_HORIZONTAL);
-            layoutData.horizontalSpan = 2;
-            label.setLayoutData(layoutData);
-
-            fLiveHostAddressText = new Text(fLiveGroup, SWT.NONE);
-            fLiveHostAddressText.setText(SessionInfo.DEFAULT_LIVE_NETWORK_URL);
-            fLiveHostAddressText.setEnabled(false);
-            fLiveHostAddressText.setToolTipText(Messages.TraceControl_CreateSessionLiveConnectionUrlTooltip);
-            layoutData = new GridData(GridData.FILL_HORIZONTAL);
-            layoutData.horizontalSpan = 4;
-            fLiveHostAddressText.setLayoutData(layoutData);
-
-            fLivePortText = new Text(fLiveGroup, SWT.NONE);
-            fLivePortText.setText(Integer.toString(SessionInfo.DEFAULT_LIVE_PORT));
-            fLivePortText.setToolTipText(Messages.TraceControl_CreateSessionLiveConnectionPortTooltip);
-            layoutData = new GridData(GridData.FILL_HORIZONTAL);
-            fLivePortText.setLayoutData(layoutData);
-
-            Label liveDelayLabel = new Label(fLiveGroup, SWT.NONE);
-            layoutData = new GridData(GridData.FILL_HORIZONTAL);
-            liveDelayLabel.setText(Messages.TraceControl_CreateSessionLiveDelayLabel);
-            liveDelayLabel.setLayoutData(layoutData);
-            fLiveDelayText = new Text(fLiveGroup, SWT.NONE);
-            fLiveDelayText.setText(DEFAULT_TEXT);
-            fLiveDelayText.setForeground(getShell().getDisplay().getSystemColor(SWT.COLOR_GRAY));
-            fLiveDelayText.setToolTipText(Messages.TraceControl_CreateSessionLiveDelayTooltip);
-            fLiveDelayText.addVerifyListener(new VerifyListener() {
-                @Override
-                public void verifyText(VerifyEvent e) {
-                    // only numbers and default are allowed.
-                    e.doit = e.text.matches("[0-9]*") || e.text.matches(DEFAULT_TEXT); //$NON-NLS-1$
-                    updateEnablement();
-                }
-            });
-            fLiveDelayText.addModifyListener(new ModifyListener() {
-                @Override
-                public void modifyText(ModifyEvent event) {
-                    updateEnablement();
-                }
-            });
-
-            fLiveDelayText.addFocusListener(new FocusListener() {
-
-                @Override
-                public void focusLost(FocusEvent e) {
-                    Text focusLostWidget = (Text) e.widget;
-                    if (focusLostWidget.getText().isEmpty()) {
-                        focusLostWidget.setText(DEFAULT_TEXT);
-                        focusLostWidget.setForeground(getShell().getDisplay().getSystemColor(SWT.COLOR_GRAY));
-                    }
-                }
-
-                @Override
-                public void focusGained(FocusEvent e) {
-                    Text focusGainedWidget = (Text) e.widget;
-                    if (focusGainedWidget.getText().equals(DEFAULT_TEXT)) {
-                        focusGainedWidget.setText(""); //$NON-NLS-1$
-                        focusGainedWidget.setForeground(getShell().getDisplay().getSystemColor(SWT.COLOR_BLACK));
-                    }
-                }
-            });
-
-            layoutData = new GridData(GridData.FILL_HORIZONTAL);
-            layoutData.grabExcessHorizontalSpace = true;
-            layoutData.horizontalSpan = 6;
-            fLiveDelayText.setLayoutData(layoutData);
-            getShell().pack();
-        }
-    }
-
-    private void disposeLiveGroup() {
-        if (fLiveGroup != null) {
-            fLiveGroup.dispose();
-            fLiveGroup = null;
-            getShell().pack();
-        }
-    }
-
-    private void disposeConfigureStreamingComposite() {
-        if (fStreamingComposite != null) {
-            fStreamingComposite.dispose();
-            fStreamingComposite = null;
-        }
-    }
-
-    @Override
-    protected void createButtonsForButtonBar(Composite parent) {
-        createButton(parent, IDialogConstants.CANCEL_ID, "&Cancel", true); //$NON-NLS-1$
-        createButton(parent, IDialogConstants.OK_ID, "&Ok", true); //$NON-NLS-1$
-    }
-
-    private void updateEnablement() {
-        validate();
-        getButton(IDialogConstants.OK_ID).setEnabled(getErrorMessage() == null);
-    }
-
-    private void validate() {
-        // Validate input data
-        fSessionName = fSessionNameText.getText();
-        fSessionPath = fSessionPathText.getText();
-        setErrorMessage(null);
-
-        if (fParent.isLiveSupported() && fLiveButton != null) {
-            fIsLive = fLiveButton.getSelection();
-            fLiveDelay = Long.valueOf(LTTngControlServiceConstants.UNUSED_VALUE);
-            fLiveUrl = SessionInfo.DEFAULT_LIVE_NETWORK_URL;
-            fLivePort = SessionInfo.DEFAULT_LIVE_PORT;
-        }
-
-        if (!"".equals(fSessionPath)) { //$NON-NLS-1$
-            // validate sessionPath
-            if (!fIsAdvancedEnabled && !fIsLive) {
-                TargetNodeComponent node = (TargetNodeComponent)fParent.getParent();
-                RemoteSystemProxy proxy = node.getRemoteSystemProxy();
-                IRemoteFileService fsss = proxy.getRemoteConnection().getService(IRemoteFileService.class);
-                if (fsss != null) {
-                    IFileStore remoteFolder = fsss.getResource(fSessionPath);
-                    if (remoteFolder == null) {
-                        setErrorMessage(Messages.TraceControl_InvalidSessionPathError + " (" + fSessionPath + ") \n"); //$NON-NLS-1$ //$NON-NLS-2$
-                        return;
-                    }
-                    IFileInfo fileInfo = remoteFolder.fetchInfo();
-                    if (fileInfo.exists()) {
-                        setErrorMessage(Messages.TraceControl_SessionPathAlreadyExistsError + " (" + fSessionPath + ") \n"); //$NON-NLS-1$ //$NON-NLS-2$
-                        return;
-                    }
-                }
-            }
-            fIsDefaultPath = false;
-        }
-
-        if (fParent.isSnapshotSupported()) {
-            fIsSnapshot = fSnapshotButton.getSelection();
-        }
-
-        fNetworkUrl = null;
-        fControlUrl = null;
-        fDataUrl = null;
-
-        if (fIsAdvancedEnabled && fStreamingComposite != null) {
-            // Validate input data
-
-            if (fIsLive && fLiveGroup != null) {
-                String liveDelayText = fLiveDelayText.getText();
-                try {
-                    fLiveDelay = liveDelayText.equals(DEFAULT_TEXT) ? LTTngControlServiceConstants.UNUSED_VALUE : Long.valueOf(liveDelayText);
-                    fLivePort = Integer.valueOf(fLivePortText.getText());
-                    fLiveUrl = fLiveHostAddressText.getText();
-                } catch (NumberFormatException e) {
-                    setErrorMessage(Messages.TraceControl_InvalidLiveDelayError);
-                    return;
-                }
-            }
-
-            fTracePath = fTracePathText.getText();
-
-            if (fControlProtocolCombo.getSelectionIndex() < 0) {
-                setErrorMessage("Control Protocol Text is empty\n");  //$NON-NLS-1$
-                return;
-            }
-
-            if ("".equals(fControlHostAddressText.getText())) { //$NON-NLS-1$
-                setErrorMessage("Control Address Text is empty\n");  //$NON-NLS-1$
-                return;
-            }
-
-            if (!fLinkDataWithControlButton.getSelection()) {
-                if (fDataProtocolCombo.getSelectionIndex() < 0) {
-                    setErrorMessage("Data Protocol Text is empty\n");  //$NON-NLS-1$
-                    return;
-                }
-
-                if ("".equals(fDataHostAddressText.getText())) { //$NON-NLS-1$
-                    setErrorMessage("Data Address Text is empty\n");  //$NON-NLS-1$
-                    return;
-                }
-
-                fControlUrl = getUrlString(fControlProtocolCombo.getItem(fControlProtocolCombo.getSelectionIndex()),
-                        fControlHostAddressText.getText(),
-                        fControlPortText.getText(),
-                        null,
-                        fTracePath);
-
-                fDataUrl = getUrlString(fDataProtocolCombo.getItem(fDataProtocolCombo.getSelectionIndex()),
-                        fDataHostAddressText.getText(),
-                        null,
-                        fDataPortText.getText(),
-                        fTracePath);
-            } else {
-                fNetworkUrl = getUrlString(fControlProtocolCombo.getItem(fControlProtocolCombo.getSelectionIndex()),
-                        fControlHostAddressText.getText(),
-                        fControlPortText.getText(),
-                        fDataPortText.getText(),
-                        fTracePath);
-            }
-        }
-
-        if (fIsLive && fNetworkUrl == null && fControlUrl == null && fDataUrl == null) {
-            fNetworkUrl = SessionInfo.DEFAULT_LIVE_NETWORK_URL;
-        }
-
-        // Check for invalid names
-        if (!"".equals(fSessionName) && !fSessionName.matches("^[a-zA-Z0-9\\-\\_]{1,}$")) { //$NON-NLS-1$ //$NON-NLS-2$
-            setErrorMessage(Messages.TraceControl_InvalidSessionNameError + " (" + fSessionName + ") \n");  //$NON-NLS-1$ //$NON-NLS-2$
-            return;
-        }
-
-        // Check if node with name already exists in parent
-        if(fParent.containsChild(fSessionName)) {
-            setErrorMessage(Messages.TraceControl_SessionAlreadyExistsError + " (" + fSessionName + ")");  //$NON-NLS-1$ //$NON-NLS-2$
-            return;
-        }
-    }
-
-    private static String getUrlString(String proto, String host, String ctrlPort, String dataPort, String sessionPath) {
-        //proto://[HOST|IP][:PORT1[:PORT2]][/TRACE_PATH]
-        StringBuilder stringBuilder = new StringBuilder();
-        stringBuilder.append(proto);
-        stringBuilder.append("://"); //$NON-NLS-1$
-        stringBuilder.append(host);
-
-        if ((ctrlPort != null) && (!"".equals(ctrlPort))) { //$NON-NLS-1$
-            stringBuilder.append(":"); //$NON-NLS-1$
-            stringBuilder.append(ctrlPort);
-        }
-
-        if ((dataPort != null) && (!"".equals(dataPort))) { //$NON-NLS-1$
-            stringBuilder.append(":"); //$NON-NLS-1$
-            stringBuilder.append(dataPort);
-        }
-
-        if ((sessionPath != null) && (!"".equals(sessionPath))) { //$NON-NLS-1$
-            stringBuilder.append("/"); //$NON-NLS-1$
-            stringBuilder.append(sessionPath);
-        }
-        return stringBuilder.toString();
-    }
-
-    private static class CopyModifyListener implements ModifyListener {
-        private Text fSource;
-        private Text fDestination;
-
-        public CopyModifyListener(Text source, Text destination) {
-            fSource = source;
-            fDestination = destination;
-        }
-
-        @Override
-        public void modifyText(ModifyEvent e) {
-            fDestination.setText(fSource.getText());
-        }
-    }
-
-    private class ControlProtocolSelectionListener extends SelectionAdapter {
-
-        @Override
-        public void widgetSelected(SelectionEvent e) {
-            fDataProtocolCombo.select(fControlProtocolCombo.getSelectionIndex());
-            if (fControlProtocolCombo.getItem(fControlProtocolCombo.getSelectionIndex()).equals(StreamingProtocol.file.name())) {
-                fControlPortText.setText(""); //$NON-NLS-1$
-                fDataPortText.setText(""); //$NON-NLS-1$
-                fControlPortText.setEnabled(false);
-                fDataPortText.setEnabled(false);
-            } else {
-                fControlPortText.setEnabled(true);
-                fDataPortText.setEnabled(true);
-            }
-        }
-    }
-
-    private class ProtocolComboSelectionListener extends SelectionAdapter {
-
-        private CCombo fCombo;
-        private Text fPortText;
-
-        public ProtocolComboSelectionListener(CCombo combo, Text portText) {
-            fCombo = combo;
-            fPortText = portText;
-        }
-
-        @Override
-        public void widgetSelected(SelectionEvent e) {
-            if (fCombo.getItem(fCombo.getSelectionIndex()).equals(StreamingProtocol.net.name()) ||
-                    fCombo.getItem(fCombo.getSelectionIndex()).equals(StreamingProtocol.net6.name())) {
-                fPortText.setText(""); //$NON-NLS-1$
-                fPortText.setEnabled(false);
-            } else {
-                fPortText.setEnabled(true);
-            }
-        }
-    }
-
-    @Override
-    public ISessionInfo getParameters() {
-        ISessionInfo sessionInfo = new SessionInfo(fSessionName);
-
-        boolean isStreaming = (fIsAdvancedEnabled && fStreamingComposite != null) || fIsLive;
-        if (isStreaming) {
-            sessionInfo.setNetworkUrl(fNetworkUrl);
-            sessionInfo.setControlUrl(fControlUrl);
-            sessionInfo.setDataUrl(fDataUrl);
-            sessionInfo.setStreamedTrace(true);
-        } else if (!fIsDefaultPath) {
-            sessionInfo.setSessionPath(fSessionPath);
-        }
-
-        sessionInfo.setLive(fIsLive);
-        sessionInfo.setLiveUrl(fLiveUrl);
-        sessionInfo.setLivePort(fLivePort);
-        sessionInfo.setLiveDelay(fLiveDelay);
-        sessionInfo.setSnapshot(fIsSnapshot);
-
-        return sessionInfo;
-    }
-
-    private final class UpdateEnablementModifyListener implements ModifyListener {
-        @Override
-        public void modifyText(ModifyEvent e) {
-            updateEnablement();
-        }
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/EnableChannelDialog.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/EnableChannelDialog.java
deleted file mode 100644 (file)
index 5a41940..0000000
+++ /dev/null
@@ -1,595 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Simon Delisle - Updated for support of LTTng Tools 2.2
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
-
-import org.eclipse.jface.dialogs.Dialog;
-import org.eclipse.jface.dialogs.IDialogConstants;
-import org.eclipse.jface.dialogs.MessageDialog;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.FocusEvent;
-import org.eclipse.swt.events.FocusListener;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.events.VerifyEvent;
-import org.eclipse.swt.events.VerifyListener;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Group;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.swt.widgets.Text;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IChannelInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.BufferType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.ChannelInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.service.LTTngControlServiceConstants;
-
-/**
- * <p>
- * Dialog box for collecting channel information when enabling a channel (which will be created).
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class EnableChannelDialog extends Dialog implements IEnableChannelDialog {
-
-    // ------------------------------------------------------------------------
-    // Constants
-    // ------------------------------------------------------------------------
-    /**
-     * The icon file for this dialog box.
-     */
-    public static final String ENABLE_CHANNEL_ICON_FILE = "icons/elcl16/add_button.gif"; //$NON-NLS-1$
-
-    /**
-     *  To indicate that the default value will be used for this field
-     */
-    private static final String DEFAULT_TEXT = "<" + Messages.EnableChannelDialog_DefaultMessage + ">"; //$NON-NLS-1$ //$NON-NLS-2$
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-    /**
-     * The text widget for the channel name
-     */
-    private Text fChannelNameText = null;
-    /**
-     * The discard mode of the channel.
-     */
-    private Button fDiscardModeButton = null;
-    /**
-     * The overwrite mode of the channel.
-     */
-    private Button fOverwriteModeButton = null;
-    /**
-     * The sub-buffer size of the channel.
-     */
-    private Text fSubBufferSizeText = null;
-    /**
-     * The number of sub-buffers of the channel.
-     */
-    private Text fNumberOfSubBuffersText = null;
-    /**
-     * The switch timer interval of the channel.
-     */
-    private Text fSwitchTimerText = null;
-    /**
-     * The read timer interval of the channel.
-     */
-    private Text fReadTimerText = null;
-    /**
-     * Radio button for selecting kernel domain.
-     */
-    private Button fKernelButton = null;
-    /**
-     * Radio button for selecting UST domain.
-     */
-    private Button fUstButton = null;
-    /**
-     * The parent domain component where the channel node should be added.
-     * Null in case of creation on session level.
-     */
-    private TraceDomainComponent fDomain = null;
-    /**
-     * The target node component
-     */
-    private TargetNodeComponent fTargetNodeComponent = null;
-    /**
-     * Common verify listener for numeric text input.
-     */
-    private VerifyListener fVerifyListener = null;
-    /**
-     * Common focus listener
-     */
-    private FocusListener fFocusListener = null;
-    /**
-     * Output channel information.
-     */
-    private IChannelInfo fChannelInfo = null;
-    /**
-     * Output domain information. True in case of Kernel domain. False for UST.
-     */
-    private boolean fIsKernel;
-    /**
-     *  Flag which indicates whether Kernel domain is available or not
-     */
-    private boolean fHasKernel;
-    /**
-     * Maximum size of trace files of the channel.
-     */
-    private Text fMaxSizeTraceText = null;
-    /**
-     * Maximum number of trace files of the channel.
-     */
-    private Text fMaxNumberTraceText = null;
-    /**
-     * CheckBox for selecting shared buffers (kernel onlyu).
-     */
-    private Button fSharedBuffersButton = null;
-    /**
-     * CheckBox for selecting per UID buffers.
-     */
-    private Button fPIDBuffersButton = null;
-    /**
-     * CheckBox for selecting per UID buffers.
-     */
-    private Button fUIDBuffersButton = null;
-    /**
-     * CheckBox to configure metadata channel
-     */
-    private Button fMetadataChannelButton = null;
-    /**
-     * Previous channel name
-     */
-    private String fPreviousChannelName = null;
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-
-    /**
-     * Constructor
-     * @param shell - a shell for the display of the dialog
-     */
-    public EnableChannelDialog(Shell shell) {
-       super(shell);
-       fIsKernel = true;
-
-        // Common verify listener
-        fVerifyListener = new VerifyListener() {
-            @Override
-            public void verifyText(VerifyEvent e) {
-                // only numbers and default are allowed.
-                e.doit = e.text.matches("[0-9]*") || e.text.matches(DEFAULT_TEXT); //$NON-NLS-1$
-            }
-        };
-
-        // Common focus listener
-        fFocusListener = new FocusListener() {
-
-            @Override
-            public void focusLost(FocusEvent e) {
-                Text focusLostWidget = (Text) e.widget;
-                if (focusLostWidget.getText().isEmpty()) {
-                    focusLostWidget.setText(DEFAULT_TEXT);
-                    focusLostWidget.setForeground(getShell().getDisplay().getSystemColor(SWT.COLOR_GRAY));
-                }
-            }
-
-            @Override
-            public void focusGained(FocusEvent e) {
-                Text focusGainedWidget = (Text) e.widget;
-                if (focusGainedWidget.getText().equals(DEFAULT_TEXT)) {
-                    focusGainedWidget.setText(""); //$NON-NLS-1$
-                    focusGainedWidget.setForeground(getShell().getDisplay().getSystemColor(SWT.COLOR_BLACK));
-                }
-            }
-        };
-
-        setShellStyle(SWT.RESIZE | getShellStyle());
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    @Override
-    public IChannelInfo getChannelInfo() {
-        return fChannelInfo;
-    }
-
-    @Override
-    public void setDomainComponent(TraceDomainComponent domain) {
-        fDomain = domain;
-        if (fDomain != null) {
-            fIsKernel = fDomain.isKernel();
-        } else {
-            fIsKernel = true;
-        }
-    }
-
-    @Override
-    public boolean isKernel() {
-        return fIsKernel;
-    }
-
-    @Override
-    public void setHasKernel(boolean hasKernel) {
-        if (fDomain != null) {
-            fIsKernel = fDomain.isKernel();
-        } else {
-            fIsKernel = hasKernel;
-        }
-
-        fHasKernel = hasKernel;
-    }
-
-    @Override
-    public void setTargetNodeComponent(TargetNodeComponent node) {
-        fTargetNodeComponent = node;
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    protected void configureShell(Shell newShell) {
-        super.configureShell(newShell);
-        newShell.setText(Messages.TraceControl_EnableChannelDialogTitle);
-        newShell.setImage(Activator.getDefault().loadIcon(ENABLE_CHANNEL_ICON_FILE));
-    }
-
-    @Override
-    protected Control createDialogArea(Composite parent) {
-
-        int numColumn = 2;
-        if (fTargetNodeComponent.isBufferTypeConfigSupported()) {
-            numColumn = 3;
-        }
-
-        // Main dialog panel
-        Composite dialogComposite = new Composite(parent, SWT.NONE);
-        GridLayout layout = new GridLayout(1, true);
-        dialogComposite.setLayout(layout);
-
-        Composite commonModeGroup = new Composite(dialogComposite, SWT.NONE);
-        layout = new GridLayout(3, true);
-        commonModeGroup.setLayout(layout);
-
-        Label channelNameLabel = new Label(commonModeGroup, SWT.RIGHT);
-        channelNameLabel.setText(Messages.TraceControl_EnableChannelNameLabel);
-        fChannelNameText = new Text(commonModeGroup, SWT.NONE);
-        fChannelNameText.setToolTipText(Messages.TraceControl_EnableChannelNameTooltip);
-
-        Label subBufferSizeLabel = new Label(commonModeGroup, SWT.RIGHT);
-        subBufferSizeLabel.setText(Messages.TraceControl_SubBufferSizePropertyName);
-        fSubBufferSizeText = new Text(commonModeGroup, SWT.NONE);
-        fSubBufferSizeText.setToolTipText(Messages.TraceControl_EnableChannelSubBufferSizeTooltip);
-        fSubBufferSizeText.addVerifyListener(fVerifyListener);
-        fSubBufferSizeText.addFocusListener(fFocusListener);
-        fSubBufferSizeText.setForeground(getShell().getDisplay().getSystemColor(SWT.COLOR_GRAY));
-
-        Label numSubBufferLabel = new Label(commonModeGroup, SWT.RIGHT);
-        numSubBufferLabel.setText(Messages.TraceControl_NbSubBuffersPropertyName);
-        fNumberOfSubBuffersText = new Text(commonModeGroup, SWT.NONE);
-        fNumberOfSubBuffersText.setToolTipText(Messages.TraceControl_EnableChannelNbSubBuffersTooltip);
-        fNumberOfSubBuffersText.addVerifyListener(fVerifyListener);
-        fNumberOfSubBuffersText.addFocusListener(fFocusListener);
-
-        Label switchTimerLabel = new Label(commonModeGroup, SWT.RIGHT);
-        switchTimerLabel.setText(Messages.TraceControl_SwitchTimerPropertyName);
-        fSwitchTimerText = new Text(commonModeGroup, SWT.NONE);
-        fSwitchTimerText.setToolTipText(Messages.TraceControl_EnableChannelSwitchTimerTooltip);
-        fSwitchTimerText.addVerifyListener(fVerifyListener);
-        fSwitchTimerText.addFocusListener(fFocusListener);
-
-        Label readTimerLabel = new Label(commonModeGroup, SWT.RIGHT);
-        readTimerLabel.setText(Messages.TraceControl_ReadTimerPropertyName);
-        fReadTimerText = new Text(commonModeGroup, SWT.NONE);
-        fReadTimerText.setToolTipText(Messages.TraceControl_EnableChannelReadTimerTooltip);
-        fReadTimerText.addVerifyListener(fVerifyListener);
-        fReadTimerText.addFocusListener(fFocusListener);
-
-        if (fTargetNodeComponent.isTraceFileRotationSupported()) {
-            Label maxSizeTraceFilesLabel = new Label(commonModeGroup, SWT.RIGHT);
-            maxSizeTraceFilesLabel.setText(Messages.TraceControl_MaxSizeTraceFilesPropertyName);
-            fMaxSizeTraceText = new Text(commonModeGroup, SWT.NONE);
-            fMaxSizeTraceText.setToolTipText(Messages.TraceControl_EnbleChannelMaxSizeTraceFilesTooltip);
-            fMaxSizeTraceText.addVerifyListener(fVerifyListener);
-            fMaxSizeTraceText.addFocusListener(fFocusListener);
-
-            Label maxNumTraceFilesLabel = new Label(commonModeGroup, SWT.RIGHT);
-            maxNumTraceFilesLabel.setText(Messages.TraceControl_MaxNumTraceFilesPropertyName);
-            fMaxNumberTraceText = new Text(commonModeGroup, SWT.NONE);
-            fMaxNumberTraceText.setToolTipText(Messages.TraceControl_EnbleChannelMaxNumTraceFilesTooltip);
-            fMaxNumberTraceText.addVerifyListener(fVerifyListener);
-            fMaxNumberTraceText.addFocusListener(fFocusListener);
-        }
-
-        if (fTargetNodeComponent.isPeriodicalMetadataFlushSupported()) {
-            fMetadataChannelButton = new Button(commonModeGroup, SWT.CHECK);
-            fMetadataChannelButton.setText(Messages.TraceControl_ConfigureMetadataChannelName);
-            fMetadataChannelButton.setSelection(false);
-
-            fMetadataChannelButton.addSelectionListener(new SelectionAdapter() {
-                @Override
-                public void widgetSelected(SelectionEvent e) {
-                    if (fMetadataChannelButton.getSelection()) {
-                        fPreviousChannelName = fChannelNameText.getText();
-                        fChannelNameText.setText("metadata"); //$NON-NLS-1$
-                        fChannelNameText.setEnabled(false);
-                    } else {
-                        fChannelNameText.setText(fPreviousChannelName);
-                        fChannelNameText.setEnabled(true);
-                    }
-                }
-            });
-        }
-        Group discardModeGroup = new Group(dialogComposite, SWT.SHADOW_NONE);
-        discardModeGroup.setText(Messages.TraceControl_EnableChannelDiscardModeGroupName);
-        layout = new GridLayout(numColumn, true);
-        discardModeGroup.setLayout(layout);
-
-        fDiscardModeButton = new  Button(discardModeGroup, SWT.RADIO);
-        fDiscardModeButton.setText(Messages.TraceControl_EnableChannelDiscardModeLabel);
-        fDiscardModeButton.setToolTipText(Messages.TraceControl_EnableChannelDiscardModeTooltip);
-        fDiscardModeButton.setSelection(true);
-
-        fOverwriteModeButton = new Button(discardModeGroup, SWT.RADIO);
-        fOverwriteModeButton.setText(Messages.TraceControl_EnableChannelOverwriteModeLabel);
-        fOverwriteModeButton.setToolTipText(Messages.TraceControl_EnableChannelOverwriteModeTooltip);
-        fOverwriteModeButton.setSelection(false);
-
-        Group domainGroup = new Group(dialogComposite, SWT.SHADOW_NONE);
-        domainGroup.setText(Messages.TraceControl_DomainDisplayName);
-        layout = new GridLayout(numColumn, true);
-        domainGroup.setLayout(layout);
-
-        fKernelButton = new Button(domainGroup, SWT.RADIO);
-        fKernelButton.setText(Messages.TraceControl_KernelDomainDisplayName);
-        fKernelButton.setSelection(fIsKernel);
-        fUstButton = new Button(domainGroup, SWT.RADIO);
-        fUstButton.setText(Messages.TraceControl_UstDisplayName);
-        fUstButton.setSelection(!fIsKernel);
-
-        if (fTargetNodeComponent.isBufferTypeConfigSupported()) {
-            Group bufferTypeGroup = new Group(dialogComposite, SWT.SHADOW_NONE);
-            bufferTypeGroup.setText(Messages.TraceControl_BufferTypeDisplayName);
-            layout = new GridLayout(numColumn, true);
-            bufferTypeGroup.setLayout(layout);
-
-            GridData data = new GridData(GridData.FILL, GridData.BEGINNING, false, false);
-            data.horizontalSpan = 3;
-            bufferTypeGroup.setLayoutData(data);
-
-            fSharedBuffersButton = new Button(bufferTypeGroup, SWT.RADIO);
-            fSharedBuffersButton.setText(Messages.TraceControl_SharedBuffersDisplayName);
-            fSharedBuffersButton.setSelection(fIsKernel);
-            fSharedBuffersButton.setEnabled(false);
-
-            fPIDBuffersButton = new Button(bufferTypeGroup, SWT.RADIO);
-            fPIDBuffersButton.setText(Messages.TraceControl_PerPidBuffersDisplayName);
-            fPIDBuffersButton.setToolTipText(Messages.TraceControl_PerPidBuffersTooltip);
-            fPIDBuffersButton.setSelection(false);
-
-            fUIDBuffersButton = new Button(bufferTypeGroup, SWT.RADIO);
-            fUIDBuffersButton.setText(Messages.TraceControl_PerUidBuffersDisplayName);
-            fUIDBuffersButton.setToolTipText(Messages.TraceControl_PerPidBuffersTooltip);
-            fUIDBuffersButton.setSelection(false);
-
-            fUIDBuffersButton.setEnabled(!fIsKernel);
-            fPIDBuffersButton.setEnabled(!fIsKernel);
-
-            // Update buffers type buttons depending on UST or Kernel
-            fUstButton.addSelectionListener(new SelectionAdapter() {
-                @Override
-                public void widgetSelected(SelectionEvent e) {
-                    if (fUstButton.getSelection()) {
-                        fSharedBuffersButton.setSelection(false);
-                        fPIDBuffersButton.setSelection(false);
-                        fUIDBuffersButton.setSelection(false);
-                        fPIDBuffersButton.setEnabled(true);
-                        fUIDBuffersButton.setEnabled(true);
-                    } else {
-                        fSharedBuffersButton.setSelection(true);
-                        fPIDBuffersButton.setSelection(false);
-                        fUIDBuffersButton.setSelection(false);
-                        fPIDBuffersButton.setEnabled(false);
-                        fUIDBuffersButton.setEnabled(false);
-                    }
-                }
-            });
-        }
-
-        if ((fDomain != null) || (!fHasKernel)) {
-            fKernelButton.setEnabled(false);
-            fUstButton.setEnabled(false);
-
-            if (fTargetNodeComponent.isBufferTypeConfigSupported()) {
-                fSharedBuffersButton.setEnabled(false);
-                fUIDBuffersButton.setEnabled(!fHasKernel);
-                fPIDBuffersButton.setEnabled(!fHasKernel);
-                setBufferTypeButtonSelection();
-            }
-        }
-
-        // layout widgets
-        GridData data = new GridData(GridData.FILL, GridData.BEGINNING, false, false);
-        data.horizontalSpan = 3;
-        discardModeGroup.setLayoutData(data);
-        data = new GridData(SWT.BEGINNING, SWT.BEGINNING, true, true);
-        fDiscardModeButton.setLayoutData(data);
-        data = new GridData(SWT.BEGINNING, SWT.BEGINNING, true, true);
-        fOverwriteModeButton.setLayoutData(data);
-
-        data = new GridData(GridData.FILL, GridData.BEGINNING, false, false);
-        data.horizontalSpan = 3;
-        domainGroup.setLayoutData(data);
-
-        data = new GridData(SWT.BEGINNING, SWT.BEGINNING, true, true);
-        fKernelButton.setLayoutData(data);
-        data = new GridData(SWT.BEGINNING, SWT.BEGINNING, true, true);
-        fUstButton.setLayoutData(data);
-        if (fTargetNodeComponent.isBufferTypeConfigSupported()) {
-            data = new GridData(SWT.BEGINNING, SWT.BEGINNING, true, true);
-            fSharedBuffersButton.setLayoutData(data);
-            data = new GridData(SWT.BEGINNING, SWT.BEGINNING, true, true);
-            fPIDBuffersButton.setLayoutData(data);
-            data = new GridData(SWT.BEGINNING, SWT.BEGINNING, true, true);
-            fUIDBuffersButton.setLayoutData(data);
-        }
-
-        if (fTargetNodeComponent.isPeriodicalMetadataFlushSupported()) {
-            data = new GridData(SWT.BEGINNING, SWT.BEGINNING, true, true);
-            data.horizontalSpan = numColumn;
-            fMetadataChannelButton.setLayoutData(data);
-        }
-
-        data = new GridData(GridData.FILL_HORIZONTAL);
-        data.horizontalSpan = 2;
-
-        fChannelNameText.setLayoutData(data);
-        fSubBufferSizeText.setLayoutData(data);
-        fNumberOfSubBuffersText.setLayoutData(data);
-        fSwitchTimerText.setLayoutData(data);
-        fReadTimerText.setLayoutData(data);
-        if (fTargetNodeComponent.isTraceFileRotationSupported()) {
-            fMaxNumberTraceText.setLayoutData(data);
-            fMaxSizeTraceText.setLayoutData(data);
-        }
-
-        setDefaults();
-
-        return dialogComposite;
-    }
-
-    @Override
-    protected void createButtonsForButtonBar(Composite parent) {
-        createButton(parent, IDialogConstants.DETAILS_ID, "&Default", true); //$NON-NLS-1$
-        createButton(parent, IDialogConstants.CANCEL_ID, "&Cancel", true); //$NON-NLS-1$
-        createButton(parent, IDialogConstants.OK_ID, "&Ok", true); //$NON-NLS-1$
-    }
-
-    @Override
-    protected void okPressed() {
-        // Set channel information
-        ChannelInfo channelInfo = new ChannelInfo(fChannelNameText.getText());
-        channelInfo.setSubBufferSize(fSubBufferSizeText.getText().equals(DEFAULT_TEXT) ? LTTngControlServiceConstants.UNUSED_VALUE : Long.parseLong(fSubBufferSizeText.getText()));
-        channelInfo.setNumberOfSubBuffers(fNumberOfSubBuffersText.getText().equals(DEFAULT_TEXT) ? LTTngControlServiceConstants.UNUSED_VALUE : Integer.parseInt(fNumberOfSubBuffersText.getText()));
-        channelInfo.setSwitchTimer(fSwitchTimerText.getText().equals(DEFAULT_TEXT) ? LTTngControlServiceConstants.UNUSED_VALUE : Long.parseLong(fSwitchTimerText.getText()));
-        channelInfo.setReadTimer(fReadTimerText.getText().equals(DEFAULT_TEXT) ? LTTngControlServiceConstants.UNUSED_VALUE : Long.parseLong(fReadTimerText.getText()));
-        channelInfo.setOverwriteMode(fOverwriteModeButton.getSelection());
-        if (fTargetNodeComponent.isTraceFileRotationSupported()) {
-            channelInfo.setMaxSizeTraceFiles(fMaxSizeTraceText.getText().equals(DEFAULT_TEXT) ? LTTngControlServiceConstants.UNUSED_VALUE : Integer.parseInt(fMaxSizeTraceText.getText()));
-            channelInfo.setMaxNumberTraceFiles(fMaxNumberTraceText.getText().equals(DEFAULT_TEXT) ? LTTngControlServiceConstants.UNUSED_VALUE : Integer.parseInt(fMaxNumberTraceText.getText()));
-        }
-        if (fTargetNodeComponent.isBufferTypeConfigSupported()) {
-            if (fSharedBuffersButton.getSelection()) {
-                channelInfo.setBufferType(BufferType.BUFFER_SHARED);
-            } else if (fPIDBuffersButton.getSelection()) {
-                channelInfo.setBufferType(BufferType.BUFFER_PER_PID);
-            } else if (fUIDBuffersButton.getSelection()) {
-                channelInfo.setBufferType(BufferType.BUFFER_PER_UID);
-            } else {
-                channelInfo.setBufferType(BufferType.BUFFER_TYPE_UNKNOWN);
-            }
-        }
-
-        fIsKernel = fKernelButton.getSelection();
-
-        // Check for invalid names
-        if (!channelInfo.getName().matches("^[a-zA-Z0-9\\-\\_]{1,}$")) { //$NON-NLS-1$
-            MessageDialog.openError(getShell(),
-                  Messages.TraceControl_EnableChannelDialogTitle,
-                  Messages.TraceControl_InvalidChannelNameError + " (" + channelInfo.getName() + ") \n");  //$NON-NLS-1$ //$NON-NLS-2$
-            return;
-        }
-
-        // Check for duplicate names
-        if (fDomain != null && fDomain.containsChild(channelInfo.getName())) {
-            MessageDialog.openError(getShell(),
-                    Messages.TraceControl_EnableChannelDialogTitle,
-                    Messages.TraceControl_ChannelAlreadyExistsError + " (" + channelInfo.getName() + ") \n");  //$NON-NLS-1$ //$NON-NLS-2$
-            return;
-        }
-
-        fChannelInfo = channelInfo;
-
-        // validation successful -> call super.okPressed()
-        super.okPressed();
-    }
-
-    @Override
-    protected void buttonPressed(int buttonId) {
-        if (buttonId == IDialogConstants.DETAILS_ID) {
-            setDefaults();
-            return;
-        }
-        super.buttonPressed(buttonId);
-    }
-
-    // ------------------------------------------------------------------------
-    // Helper methods
-    // ------------------------------------------------------------------------
-
-    /**
-     * Sets default value depending on Kernel or UST
-     */
-    private void setDefaults() {
-        fSwitchTimerText.setText(DEFAULT_TEXT);
-        fSwitchTimerText.setForeground(getShell().getDisplay().getSystemColor(SWT.COLOR_GRAY));
-        fReadTimerText.setText(DEFAULT_TEXT);
-        fReadTimerText.setForeground(getShell().getDisplay().getSystemColor(SWT.COLOR_GRAY));
-        fOverwriteModeButton.setSelection(IChannelInfo.DEFAULT_OVERWRITE_MODE);
-        if (fTargetNodeComponent.isTraceFileRotationSupported()) {
-            fMaxSizeTraceText.setText(DEFAULT_TEXT);
-            fMaxSizeTraceText.setForeground(getShell().getDisplay().getSystemColor(SWT.COLOR_GRAY));
-            fMaxNumberTraceText.setText(DEFAULT_TEXT);
-            fMaxNumberTraceText.setForeground(getShell().getDisplay().getSystemColor(SWT.COLOR_GRAY));
-        }
-        fSubBufferSizeText.setText(DEFAULT_TEXT);
-        fSubBufferSizeText.setForeground(getShell().getDisplay().getSystemColor(SWT.COLOR_GRAY));
-        fNumberOfSubBuffersText.setText(DEFAULT_TEXT);
-        fNumberOfSubBuffersText.setForeground(getShell().getDisplay().getSystemColor(SWT.COLOR_GRAY));
-        if (fTargetNodeComponent.isBufferTypeConfigSupported()) {
-            setBufferTypeButtonSelection();
-        }
-    }
-
-    private void setBufferTypeButtonSelection() {
-        if ((fDomain != null) && fDomain.getBufferType() != null) {
-            switch (fDomain.getBufferType()) {
-            case BUFFER_PER_PID:
-                fPIDBuffersButton.setSelection(true);
-                break;
-            case BUFFER_PER_UID:
-                fUIDBuffersButton.setSelection(true);
-                break;
-            case BUFFER_SHARED:
-                fSharedBuffersButton.setSelection(true);
-                break;
-                //$CASES-OMITTED$
-            default:
-                break;
-            }
-        }
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/EnableEventsDialog.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/EnableEventsDialog.java
deleted file mode 100644 (file)
index e7f89b7..0000000
+++ /dev/null
@@ -1,436 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
-
-import java.util.List;
-
-import org.eclipse.jface.dialogs.Dialog;
-import org.eclipse.jface.dialogs.IDialogConstants;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.graphics.Point;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Group;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.LogLevelType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceProviderGroup;
-
-/**
- * <p>
- * Dialog box for collecting information events to be enabled.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class EnableEventsDialog extends Dialog implements IEnableEventsDialog  {
-
-    // ------------------------------------------------------------------------
-    // Constants
-    // ------------------------------------------------------------------------
-
-    /**
-     * The icon file for this dialog box.
-     */
-    public static final String ENABLE_EVENT_ICON_FILE = "icons/elcl16/enable_event.gif"; //$NON-NLS-1$
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-    /**
-     * The dialog composite.
-     */
-    private Composite fDialogComposite;
-    /**
-     * The composite with widgets for collecting information about kernel events.
-     */
-    private EnableKernelEventComposite fKernelComposite;
-    /**
-     * The composite with widgets for collecting information about UST events.
-     */
-    private EnableUstEventsComposite fUstComposite;
-    /**
-     * Radio button for selecting kernel domain.
-     */
-    private Button fKernelButton;
-    /**
-     * Radio button for selecting UST domain.
-     */
-    private Button fUstButton;
-    /**
-     * The referenced trace provider group containing the kernel provider and UST
-     * provider component which contains a list of available tracepoints.
-     */
-    private TraceProviderGroup fProviderGroup;
-    /**
-     * The parent domain component where the channel node should be added.
-     * Null in case the domain is not known (i.e. on session level).
-     */
-    private TraceDomainComponent fDomain;
-    /**
-     * Output domain information. True in case of Kernel domain. False for UST.
-     */
-    private boolean fIsKernel;
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-    /**
-     * Constructor
-     * @param shell - a shell for the display of the dialog
-     */
-    public EnableEventsDialog(Shell shell) {
-        super(shell);
-        setShellStyle(SWT.RESIZE | getShellStyle());
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    @Override
-    public boolean isTracepoints() {
-        if (fIsKernel) {
-            return fKernelComposite.isTracepoints();
-        }
-        return fUstComposite.isTracepoints();
-    }
-
-    @Override
-    public boolean isAllTracePoints() {
-        if (fIsKernel) {
-            return fKernelComposite.isAllTracePoints();
-        }
-        return fUstComposite.isAllTracePoints();
-    }
-
-    @Override
-    public boolean isSysCalls() {
-        if (fIsKernel) {
-            return fKernelComposite.isSysCalls();
-        }
-        return false;
-    }
-
-    @Override
-    public boolean isAllSysCalls() {
-        if (fIsKernel) {
-            return fKernelComposite.isSysCalls();
-        }
-        return false;
-    }
-
-    @Override
-    public List<String> getEventNames() {
-        if (fIsKernel) {
-            return fKernelComposite.getEventNames();
-        }
-        return fUstComposite.getEventNames();
-    }
-
-    @Override
-    public boolean isDynamicProbe() {
-        if (fIsKernel) {
-            return fKernelComposite.isDynamicProbe();
-        }
-        return false;
-    }
-
-    @Override
-    public String getProbeName() {
-        if (fIsKernel) {
-            return fKernelComposite.getProbeName();
-        }
-        return null;
-    }
-
-    @Override
-    public String getProbeEventName() {
-        if (fIsKernel) {
-            return fKernelComposite.getProbeEventName();
-        }
-        return null;
-    }
-
-    @Override
-    public boolean isDynamicFunctionProbe() {
-        if (fIsKernel) {
-            return fKernelComposite.isDynamicFunctionProbe();
-        }
-        return false;
-    }
-
-    @Override
-    public String getFunctionEventName() {
-        if (fIsKernel) {
-            return fKernelComposite.getFunctionEventName();
-        }
-        return null;
-    }
-
-    @Override
-    public String getFunction() {
-        if (fIsKernel) {
-            return fKernelComposite.getFunction();
-        }
-        return null;
-    }
-
-    @Override
-    public boolean isWildcard() {
-        if (!fIsKernel) {
-            return fUstComposite.isWildcard();
-        }
-        return false;
-    }
-
-    @Override
-    public String getWildcard() {
-        if (!fIsKernel) {
-            return fUstComposite.getWildcard();
-        }
-        return null;
-    }
-
-    @Override
-    public boolean isLogLevel() {
-        if (!fIsKernel) {
-            return fUstComposite.isLogLevel();
-        }
-        return false;
-    }
-
-    @Override
-    public LogLevelType getLogLevelType() {
-        if (!fIsKernel) {
-            return fUstComposite.getLogLevelType();
-        }
-        return null;
-    }
-
-    @Override
-    public TraceLogLevel getLogLevel() {
-        if (!fIsKernel) {
-            return fUstComposite.getLogLevel();
-        }
-        return null;
-    }
-
-    @Override
-    public String getLogLevelEventName() {
-        if (!fIsKernel) {
-            return fUstComposite.getLogLevelEventName();
-        }
-        return null;
-    }
-
-    @Override
-    public boolean isKernel() {
-        return fIsKernel;
-    }
-
-    @Override
-    public void setTraceProviderGroup(TraceProviderGroup providerGroup) {
-        fProviderGroup = providerGroup;
-    }
-
-    @Override
-    public void setTraceDomainComponent(TraceDomainComponent domain) {
-        fDomain = domain;
-        if (fDomain != null) {
-            fIsKernel = fDomain.isKernel();
-        } else {
-            fIsKernel = fProviderGroup != null ? fProviderGroup.hasKernelProvider() : true;
-        }
-    }
-
-    @Override
-    public String getFilterExpression() {
-        if (!fIsKernel) {
-            return fUstComposite.getFilterExpression();
-        }
-        return null;
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    protected void configureShell(Shell newShell) {
-        super.configureShell(newShell);
-        newShell.setText(Messages.TraceControl_EnableEventsDialogTitle);
-        newShell.setImage(Activator.getDefault().loadIcon(ENABLE_EVENT_ICON_FILE));
-    }
-
-    @Override
-    protected Control createDialogArea(Composite parent) {
-
-        // Main dialog panel
-        fDialogComposite = new Composite(parent, SWT.NONE);
-        GridLayout layout = new GridLayout(1, true);
-        fDialogComposite.setLayout(layout);
-        fDialogComposite.setLayoutData(new GridData(GridData.FILL_BOTH));
-
-        // ------------------------------------------------------------------------
-        // Domain Group
-        // ------------------------------------------------------------------------
-        Group domainGroup = new Group(fDialogComposite, SWT.SHADOW_NONE);
-        domainGroup.setText(Messages.TraceControl_DomainDisplayName);
-        layout = new GridLayout(2, true);
-        domainGroup.setLayout(layout);
-
-        fKernelButton = new Button(domainGroup, SWT.RADIO);
-        fKernelButton.setText(Messages.TraceControl_KernelDomainDisplayName);
-        fKernelButton.setSelection(fIsKernel);
-        fUstButton = new Button(domainGroup, SWT.RADIO);
-        fUstButton.setText(Messages.TraceControl_UstDisplayName);
-        fUstButton.setSelection(!fIsKernel);
-
-        if ((fDomain != null) || ((fProviderGroup != null) && (!fProviderGroup.hasKernelProvider()))) {
-            fKernelButton.setEnabled(false);
-            fUstButton.setEnabled(false);
-        }
-
-        // layout widgets
-        GridData data = new GridData(GridData.FILL_HORIZONTAL);
-        domainGroup.setLayoutData(data);
-
-        data = new GridData(SWT.BEGINNING, SWT.BEGINNING, true, true);
-        fKernelButton.setLayoutData(data);
-        data = new GridData(SWT.BEGINNING, SWT.BEGINNING, true, true);
-        fUstButton.setLayoutData(data);
-
-        // ------------------------------------------------------------------------
-        // Kernel or UST event data group
-        // ------------------------------------------------------------------------
-        fUstComposite = null;
-        fKernelComposite = null;
-        if (fIsKernel) {
-            createKernelComposite();
-            fUstComposite = null;
-        } else {
-            createUstComposite();
-        }
-
-        fKernelButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                if (fKernelButton.getSelection()) {
-                    disposeUstComposite();
-                    createKernelComposite();
-                    fDialogComposite.layout();
-                }
-            }
-        });
-
-        fUstButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                if (fUstButton.getSelection()) {
-                    disposeKernelComposite();
-                    createUstComposite();
-                    fDialogComposite.layout();
-                }
-            }
-        });
-
-        getShell().setMinimumSize(new Point(500, 650));
-
-        return fDialogComposite;
-    }
-
-    @Override
-    protected void createButtonsForButtonBar(Composite parent) {
-        createButton(parent, IDialogConstants.CANCEL_ID, "&Cancel", true); //$NON-NLS-1$
-        createButton(parent, IDialogConstants.OK_ID, "&Ok", true); //$NON-NLS-1$
-    }
-
-    @Override
-    protected void okPressed() {
-        fIsKernel = fKernelButton.getSelection();
-
-        // Validate kernel composite in case of kernel domain
-        if (fKernelComposite != null && !fKernelComposite.isValid()) {
-            return;
-        }
-
-     // Validate UST composite in case of UST domain
-        if (fUstComposite != null && !fUstComposite.isValid()) {
-            return;
-        }
-
-        // validation successful -> call super.okPressed()
-        super.okPressed();
-    }
-
-    // ------------------------------------------------------------------------
-    // Helper methods
-    // ------------------------------------------------------------------------
-
-    /**
-     * Creates the kernel composite (if not existing)
-     */
-    private void createKernelComposite() {
-        if (fKernelComposite == null) {
-            fKernelComposite = new EnableKernelEventComposite(fDialogComposite, SWT.NONE, fProviderGroup);
-            GridLayout layout = new GridLayout(1, true);
-            fKernelComposite.setLayout(layout);
-            fKernelComposite.setLayoutData(new GridData(GridData.FILL_BOTH));
-
-            fKernelComposite.createContent();
-        }
-    }
-
-    /**
-     * Disposes the kernel composite (if existing)
-     */
-    private void disposeKernelComposite() {
-        if (fKernelComposite != null) {
-            fKernelComposite.dispose();
-            fKernelComposite = null;
-        }
-    }
-
-    /**
-     * Creates the UST composite (if not existing)
-     */
-    private void createUstComposite() {
-        if (fUstComposite == null) {
-            fUstComposite = new EnableUstEventsComposite(fDialogComposite, SWT.NONE, fProviderGroup);
-            GridLayout layout = new GridLayout(1, true);
-            fUstComposite.setLayout(layout);
-            fUstComposite.setLayoutData(new GridData(GridData.FILL_BOTH));
-
-            fUstComposite.createContent();
-        }
-    }
-
-    /**
-     * Disposes the UST composite (if existing)
-     */
-    private void disposeUstComposite() {
-        if (fUstComposite != null) {
-            fUstComposite.dispose();
-            fUstComposite = null;
-        }
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/EnableKernelEventComposite.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/EnableKernelEventComposite.java
deleted file mode 100644 (file)
index 483bbee..0000000
+++ /dev/null
@@ -1,605 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Marc-Andre Laperle - Add filtering textbox
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.jface.dialogs.MessageDialog;
-import org.eclipse.jface.viewers.CheckStateChangedEvent;
-import org.eclipse.jface.viewers.CheckboxTreeViewer;
-import org.eclipse.jface.viewers.ICheckStateListener;
-import org.eclipse.jface.viewers.TreeViewer;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Group;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Text;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.BaseEventComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.KernelProviderComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceControlContentProvider;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceControlLabelProvider;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceProviderGroup;
-import org.eclipse.ui.dialogs.FilteredTree;
-import org.eclipse.ui.dialogs.PatternFilter;
-
-/**
- * <p>
- * A composite for collecting information about kernel events to be enabled.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class EnableKernelEventComposite extends Composite implements IEnableKernelEvents {
-
-    // ------------------------------------------------------------------------
-    // Constants
-    // ------------------------------------------------------------------------
-    private enum KernelGroupEnum { TRACEPOINTS, SYSCALLS, PROBE, FUNCTION }
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-
-    /**
-     * A button to enable/disable the tracepoints group
-     */
-    private Button fTracepointsActivateButton;
-    /**
-     * A tree viewer for displaying and selection of available tracepoints.
-     */
-    private CheckboxTreeViewer fTracepointsViewer;
-    /**
-     * A button to enable/disable the syscalls group
-     */
-    private Button fSysCallsActivateButton;
-    /**
-     * A button to enable or disable the dynamic probe group.
-     */
-    private Button fProbeActivateButton;
-    /**
-     * The text field for the event name for the dynamic probe.
-     */
-    private Text fProbeEventNameText;
-    /**
-     * The text field for the dynamic probe.
-     */
-    private Text fProbeText;
-    /**
-     * A button to enable or disable the dynamic function probe group.
-     */
-    private Button fFunctionActivateButton;
-    /**
-     * The text field for the event name for the dynamic probe.
-     */
-    private Text fFunctionEventNameText;
-    /**
-     * The text field for the dynamic function entry/return probe.
-     */
-    private Text fFunctionText;
-    /**
-     * The referenced trace provider group containing the kernel provider
-     * component which contains a list of available tracepoints.
-     */
-    private final TraceProviderGroup fProviderGroup;
-    /**
-     * The flag indicating that tracepoints are selected.
-     */
-    private boolean fIsTracepoints;
-    /**
-     * The flag indicating that all tracepoints are selected.
-     */
-    private boolean fIsAllTracepoints;
-    /**
-     * The flag indicating that syscalls are selected.
-     */
-    private boolean fIsSysCalls;
-    /**
-     * The list of tracepoints to be enabled.
-     */
-    private List<String> fSelectedEvents;
-    /**
-     * The flag indicating that dynamic probe is selected.
-     */
-    private boolean fIsDynamicProbe;
-    /**
-     *  The event name of the dynamic probe.
-     */
-    private String fProbeEventName;
-    /**
-     * The dynamic probe.
-     */
-    private String fProbeString;
-    /**
-     * The flag indicating that the dynamic function probe is selected.
-     */
-    private boolean fIsDynamicFunctionProbe;
-    /**
-     * The event name of the dynamic function entry/return probe.
-     */
-    private String fFunctionEventName;
-    /**
-     * The dynamic function entry/return probe.
-     */
-    private String fFunctionString;
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-
-    /**
-     * Constructor
-     *
-     * @param parent
-     *            The parent composite
-     * @param style
-     *            The index of the style for this event composite
-     * @param providerGroup
-     *            The trace provider group
-     */
-    public EnableKernelEventComposite(Composite parent, int style, TraceProviderGroup providerGroup) {
-        super(parent, style);
-        fProviderGroup = providerGroup;
-    }
-
-    // ------------------------------------------------------------------------
-    // Acessors
-    // ------------------------------------------------------------------------
-
-    @Override
-    public boolean isTracepoints() {
-        return fIsTracepoints;
-    }
-
-    @Override
-    public boolean isAllTracePoints() {
-        return fIsAllTracepoints;
-    }
-
-    @Override
-    public boolean isSysCalls() {
-        return fIsSysCalls;
-    }
-
-    @Override
-    public boolean isAllSysCalls() {
-        return fIsSysCalls;
-    }
-
-    @Override
-    public List<String> getEventNames() {
-        return new ArrayList<>(fSelectedEvents);
-    }
-
-    @Override
-    public boolean isDynamicProbe() {
-        return fIsDynamicProbe;
-    }
-
-    @Override
-    public String getProbeName() {
-        return fProbeString;
-    }
-
-    @Override
-    public String getProbeEventName() {
-        return fProbeEventName;
-    }
-
-    @Override
-    public boolean isDynamicFunctionProbe() {
-        return fIsDynamicFunctionProbe;
-    }
-
-    @Override
-    public String getFunctionEventName() {
-        return fFunctionEventName;
-    }
-
-    @Override
-    public String getFunction() {
-        return fFunctionString;
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    /**
-     * Creates the composite content
-     */
-    public void createContent() {
-
-        // Tracepoints Group
-        createTracepointsGroup();
-
-        // Syscalls Group
-        createSysCallsGroup();
-
-        // Dynamic Probe Group
-        createDynamicProbeGroup();
-
-        // Dynamic Function Probe Group
-        createDynamicFunctionPropeGroup();
-
-        // Set default enablements
-        setKernelEnablements(KernelGroupEnum.TRACEPOINTS);
-    }
-
-    /**
-     * Validates the kernel composite input data.
-     * @return true if configured data is valid and can be retrieved.
-     */
-    public boolean isValid() {
-        fIsTracepoints = fTracepointsActivateButton.getSelection();
-        fIsSysCalls = fSysCallsActivateButton.getSelection();
-        fIsDynamicProbe = fProbeActivateButton.getSelection();
-        fIsDynamicFunctionProbe = fFunctionActivateButton.getSelection();
-
-        // initialize tracepoint fields
-        fIsAllTracepoints = false;
-        fSelectedEvents = new ArrayList<>();
-
-        if (fIsTracepoints) {
-            Object[] checkedElements = fTracepointsViewer.getCheckedElements();
-            for (int i = 0; i < checkedElements.length; i++) {
-                ITraceControlComponent component = (ITraceControlComponent)checkedElements[i];
-                if (component instanceof BaseEventComponent) {
-                    fSelectedEvents.add(component.getName());
-                }
-            }
-            // verify if all events are selected
-            int nbEvents = 0;
-            List<ITraceControlComponent> comps = fProviderGroup.getChildren(KernelProviderComponent.class);
-            for (ITraceControlComponent comp : comps) {
-                nbEvents += comp.getChildren().length;
-            }
-            fIsAllTracepoints = (nbEvents == fSelectedEvents.size());
-        }
-
-        if (fIsDynamicProbe) {
-            String temp = fProbeEventNameText.getText();
-            if (temp.isEmpty() ||
-                fProbeText.getText().matches("\\s*") || //$NON-NLS-1$
-                (!temp.matches("^[\\s]{0,}$") && !temp.matches("^[a-zA-Z0-9\\-\\_]{1,}$"))) { //$NON-NLS-1$ //$NON-NLS-2$
-                MessageDialog.openError(getShell(),
-                        Messages.TraceControl_EnableEventsDialogTitle,
-                        Messages.TraceControl_InvalidProbeNameError + " (" + temp + ") \n");  //$NON-NLS-1$ //$NON-NLS-2$
-
-                return false;
-            }
-
-            fProbeEventName = temp;
-            // fProbeString will be validated by lttng-tools
-            fProbeString = fProbeText.getText();
-        }
-
-        // initialize function string
-        fFunctionEventName = null;
-        fFunctionString = null;
-        if (fIsDynamicFunctionProbe) {
-            String functionTemp = fFunctionEventNameText.getText();
-            if (functionTemp.isEmpty() ||
-                functionTemp.matches("\\s*") || //$NON-NLS-1$
-                (!functionTemp.matches("^[\\s]{0,}$") && !functionTemp.matches("^[a-zA-Z0-9\\-\\_]{1,}$"))) { //$NON-NLS-1$ //$NON-NLS-2$
-                MessageDialog.openError(getShell(),
-                        Messages.TraceControl_EnableEventsDialogTitle,
-                        Messages.TraceControl_InvalidProbeNameError + " (" + functionTemp + ") \n");  //$NON-NLS-1$ //$NON-NLS-2$
-
-                return false;
-            }
-
-            fFunctionEventName = functionTemp;
-            // fFunctionString will be validated by lttng-tools
-            fFunctionString = fFunctionText.getText();
-        }
-
-        return true;
-    }
-
-    /**
-     * Creates tracepoints group.
-     */
-    private void createTracepointsGroup() {
-
-        GridLayout layout;
-        GridData data;
-        Group tpMainGroup = new Group(this, SWT.SHADOW_NONE);
-        tpMainGroup.setText(Messages.TraceControl_EnableEventsTracepointGroupName);
-        layout = new GridLayout(2, false);
-        tpMainGroup.setLayout(layout);
-        data = new GridData(GridData.FILL_BOTH);
-        tpMainGroup.setLayoutData(data);
-
-        Composite buttonComposite = new Composite(tpMainGroup, SWT.NONE);
-        layout = new GridLayout(1, true);
-        buttonComposite.setLayout(layout);
-        data = new GridData(SWT.BEGINNING, SWT.CENTER, false, true);
-        buttonComposite.setLayoutData(data);
-
-        fTracepointsActivateButton = new Button(buttonComposite, SWT.RADIO);
-        fTracepointsActivateButton.setText(Messages.TraceControl_EnableGroupSelectionName);
-        data = new GridData(GridData.FILL_HORIZONTAL);
-        fTracepointsActivateButton.setLayoutData(data);
-        fTracepointsActivateButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                setKernelEnablements(KernelGroupEnum.TRACEPOINTS);
-            }
-        });
-
-        Group tracepointsGroup = new Group(tpMainGroup, SWT.SHADOW_NONE);
-        layout = new GridLayout(1, true);
-        tracepointsGroup.setLayout(layout);
-        data = new GridData(GridData.FILL_BOTH);
-        tracepointsGroup.setLayoutData(data);
-
-        new FilteredTree(tracepointsGroup, SWT.MULTI | SWT.H_SCROLL | SWT.V_SCROLL | SWT.BORDER, new PatternFilter(), true) {
-            @Override
-            protected TreeViewer doCreateTreeViewer(Composite aparent, int style) {
-                fTracepointsViewer = new CheckboxTreeViewer(aparent, SWT.MULTI | SWT.H_SCROLL | SWT.V_SCROLL);
-                fTracepointsViewer.getTree().setToolTipText(Messages.TraceControl_EnableEventsTracepointTreeTooltip);
-
-                fTracepointsViewer.setContentProvider(new KernelContentProvider());
-                fTracepointsViewer.setLabelProvider(new KernelLabelProvider());
-                fTracepointsViewer.addCheckStateListener(new KernelCheckListener());
-                fTracepointsViewer.setInput(fProviderGroup);
-
-                fTracepointsViewer.getTree().setLayoutData(new GridData(GridData.FILL_BOTH));
-                return fTracepointsViewer;
-            }
-        };
-    }
-
-    /**
-     * Creates syscalls group.
-     */
-    private void createSysCallsGroup() {
-        GridLayout layout;
-        GridData data;
-        Group sysCallsMainGroup = new Group(this, SWT.SHADOW_NONE);
-        sysCallsMainGroup.setText(Messages.TraceControl_EnableEventsSyscallName);
-        sysCallsMainGroup.setToolTipText(Messages.TraceControl_EnableEventsSyscallTooltip);
-        layout = new GridLayout(2, false);
-        sysCallsMainGroup.setLayout(layout);
-        data = new GridData(GridData.FILL_HORIZONTAL);
-        sysCallsMainGroup.setLayoutData(data);
-
-        Composite buttonComposite = new Composite(sysCallsMainGroup, SWT.NONE);
-        layout = new GridLayout(1, false);
-        buttonComposite.setLayout(layout);
-        data = new GridData(SWT.BEGINNING, SWT.CENTER, false, true);
-        buttonComposite.setLayoutData(data);
-
-        fSysCallsActivateButton = new Button(buttonComposite, SWT.RADIO);
-        fSysCallsActivateButton.setText(Messages.TraceControl_EnableGroupSelectionName);
-        fSysCallsActivateButton.setToolTipText(Messages.TraceControl_EnableEventsSyscallTooltip);
-        fSysCallsActivateButton.setSelection(false);
-        data = new GridData(GridData.FILL_HORIZONTAL);
-        fSysCallsActivateButton.setLayoutData(data);
-        fSysCallsActivateButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                setKernelEnablements(KernelGroupEnum.SYSCALLS);
-            }
-        });
-    }
-
-    /**
-     * Creates dynamic probe group.
-     */
-    private void createDynamicProbeGroup() {
-        GridLayout layout;
-        GridData data;
-        Group probeMainGroup = new Group(this, SWT.SHADOW_NONE);
-        probeMainGroup.setText(Messages.TraceControl_EnableEventsProbeGroupName);
-        layout = new GridLayout(2, false);
-        probeMainGroup.setLayout(layout);
-        data = new GridData(GridData.FILL_HORIZONTAL);
-        probeMainGroup.setLayoutData(data);
-
-        Composite buttonComposite = new Composite(probeMainGroup, SWT.NONE);
-        layout = new GridLayout(1, false);
-        buttonComposite.setLayout(layout);
-        data = new GridData(SWT.BEGINNING, SWT.CENTER, false, true);
-        buttonComposite.setLayoutData(data);
-
-        fProbeActivateButton = new Button(buttonComposite, SWT.RADIO);
-        fProbeActivateButton.setText(Messages.TraceControl_EnableGroupSelectionName);
-        fProbeActivateButton.setSelection(false);
-        data = new GridData(GridData.FILL_HORIZONTAL);
-        fProbeActivateButton.setLayoutData(data);
-        fProbeActivateButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                setKernelEnablements(KernelGroupEnum.PROBE);
-            }
-        });
-
-        Group probeGroup = new Group(probeMainGroup, SWT.SHADOW_NONE);
-        layout = new GridLayout(4, true);
-        probeGroup.setLayout(layout);
-        probeGroup.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-
-        Label probeNameLabel = new Label(probeGroup, SWT.LEFT);
-        probeNameLabel.setText(Messages.TraceControl_EnableEventsEventNameLabel);
-        data = new GridData(GridData.FILL_BOTH);
-        data.horizontalSpan = 1;
-        probeNameLabel.setLayoutData(data);
-
-        fProbeEventNameText = new Text(probeGroup, SWT.LEFT);
-        fProbeEventNameText.setToolTipText(Messages.TraceControl_EnableEventsProbeEventNameTooltip);
-
-        data = new GridData(GridData.FILL_BOTH);
-        data.horizontalSpan = 3;
-        fProbeEventNameText.setLayoutData(data);
-
-        Label probeLabel = new Label(probeGroup, SWT.LEFT);
-        probeLabel.setText(Messages.TraceControl_EnableEventsProbeNameLabel);
-        data = new GridData(GridData.FILL_BOTH);
-        data.horizontalSpan = 1;
-        probeLabel.setLayoutData(data);
-
-        fProbeText = new Text(probeGroup, SWT.LEFT);
-        fProbeText.setToolTipText(Messages.TraceControl_EnableEventsProbeNameTooltip);
-        data = new GridData(GridData.FILL_BOTH);
-        data.horizontalSpan = 3;
-        fProbeText.setLayoutData(data);
-    }
-
-    /**
-     * Creates dynamic function entry/return probe group.
-     */
-    private void createDynamicFunctionPropeGroup() {
-        GridLayout layout;
-        GridData data;
-        Group functionMainGroup = new Group(this, SWT.SHADOW_NONE);
-        functionMainGroup.setText(Messages.TraceControl_EnableEventsFucntionGroupName);
-        layout = new GridLayout(2, false);
-        functionMainGroup.setLayout(layout);
-        data = new GridData(GridData.FILL_HORIZONTAL);
-        functionMainGroup.setLayoutData(data);
-
-        Composite buttonComposite = new Composite(functionMainGroup, SWT.NONE);
-        layout = new GridLayout(1, false);
-        buttonComposite.setLayout(layout);
-        data = new GridData(SWT.BEGINNING, SWT.CENTER, false, true);
-        buttonComposite.setLayoutData(data);
-
-        fFunctionActivateButton = new Button(buttonComposite, SWT.RADIO);
-        fFunctionActivateButton.setText(Messages.TraceControl_EnableGroupSelectionName);
-        fFunctionActivateButton.setSelection(false);
-        data = new GridData(GridData.FILL_HORIZONTAL);
-        fFunctionActivateButton.setLayoutData(data);
-        fFunctionActivateButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                setKernelEnablements(KernelGroupEnum.FUNCTION);
-            }
-        });
-
-        Group functionGroup = new Group(functionMainGroup, SWT.SHADOW_NONE);
-        layout = new GridLayout(4, true);
-        functionGroup.setLayout(layout);
-        functionGroup.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-
-        Label functionNameLabel = new Label(functionGroup, SWT.LEFT);
-        functionNameLabel.setText(Messages.TraceControl_EnableEventsEventNameLabel);
-        data = new GridData(GridData.FILL_BOTH);
-        data.horizontalSpan = 1;
-        functionNameLabel.setLayoutData(data);
-
-        fFunctionEventNameText = new Text(functionGroup, SWT.LEFT);
-        fFunctionEventNameText.setToolTipText(Messages.TraceControl_EnableEventsFunctionEventNameTooltip);
-        data = new GridData(GridData.FILL_BOTH);
-        data.horizontalSpan = 3;
-        fFunctionEventNameText.setLayoutData(data);
-
-        Label functionLabel = new Label(functionGroup, SWT.LEFT);
-        functionLabel.setText(Messages.TraceControl_EnableEventsFunctionNameLabel);
-        data = new GridData(GridData.FILL_BOTH);
-        data.horizontalSpan = 1;
-        functionLabel.setLayoutData(data);
-
-        fFunctionText = new Text(functionGroup, SWT.LEFT);
-        fFunctionText.setToolTipText(Messages.TraceControl_EnableEventsProbeNameTooltip);
-        data = new GridData(GridData.FILL_BOTH);
-        data.horizontalSpan = 3;
-        fFunctionText.setLayoutData(data);
-    }
-
-    /**
-     * Enable/selects widgets depending on the group specified.
-     * @param group - group to enable.
-     */
-    private void setKernelEnablements(KernelGroupEnum group) {
-        fTracepointsActivateButton.setSelection(group == KernelGroupEnum.TRACEPOINTS);
-        fTracepointsViewer.getTree().setEnabled(group == KernelGroupEnum.TRACEPOINTS);
-
-        fSysCallsActivateButton.setSelection(group == KernelGroupEnum.SYSCALLS);
-
-        fProbeActivateButton.setSelection(group == KernelGroupEnum.PROBE);
-        fProbeEventNameText.setEnabled(group == KernelGroupEnum.PROBE);
-        fProbeText.setEnabled(group == KernelGroupEnum.PROBE);
-
-        fFunctionActivateButton.setSelection(group == KernelGroupEnum.FUNCTION);
-        fFunctionEventNameText.setEnabled(group == KernelGroupEnum.FUNCTION);
-        fFunctionText.setEnabled(group == KernelGroupEnum.FUNCTION);
-    }
-
-    // ------------------------------------------------------------------------
-    // Local classes
-    // ------------------------------------------------------------------------
-    /**
-     * Content provider for the tracepoints tree.
-     */
-    public static final class KernelContentProvider extends TraceControlContentProvider {
-        @Override
-        public Object[] getChildren(Object parentElement) {
-            if (parentElement instanceof TraceProviderGroup) {
-                List<ITraceControlComponent> children = ((ITraceControlComponent)parentElement).getChildren(KernelProviderComponent.class);
-                return children.toArray(new ITraceControlComponent[children.size()]);
-            }
-            if (parentElement instanceof ITraceControlComponent) {
-                return ((ITraceControlComponent)parentElement).getChildren();
-            }
-            return new Object[0];
-        }
-    }
-
-    /**
-     * Content label for the tracepoints tree.
-     */
-    public static final class KernelLabelProvider extends TraceControlLabelProvider {
-        @Override
-        public Image getImage(Object element) {
-            return null;
-        }
-        @Override
-        public String getText(Object element) {
-            if ((element != null) && (element instanceof KernelProviderComponent)) {
-                return Messages.TraceControl_EnableEventsTracepointTreeAllLabel;
-            }
-            return super.getText(element);
-        }
-    }
-
-    /**
-     * Check state listener for the tracepoints tree.
-     */
-    public final class KernelCheckListener implements ICheckStateListener {
-        @Override
-        public void checkStateChanged(CheckStateChangedEvent event) {
-          if (event.getChecked()) {
-              if (event.getElement() instanceof KernelProviderComponent) {
-                  fTracepointsViewer.setSubtreeChecked(event.getElement(), true);
-              }
-          } else {
-              if (event.getElement() instanceof KernelProviderComponent) {
-                  fTracepointsViewer.setSubtreeChecked(event.getElement(), false);
-              } else {
-                  ITraceControlComponent component = (ITraceControlComponent) event.getElement();
-                  fTracepointsViewer.setChecked(component.getParent(), false);
-              }
-          }
-        }
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/EnableUstEventsComposite.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/EnableUstEventsComposite.java
deleted file mode 100644 (file)
index 637aca8..0000000
+++ /dev/null
@@ -1,649 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2015 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
- *   Marc-Andre Laperle - Add filtering textbox
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
-
-import java.util.ArrayList;
-import java.util.HashSet;
-import java.util.List;
-import java.util.Set;
-
-import org.eclipse.jface.dialogs.MessageDialog;
-import org.eclipse.jface.viewers.CheckStateChangedEvent;
-import org.eclipse.jface.viewers.CheckboxTreeViewer;
-import org.eclipse.jface.viewers.ICheckStateListener;
-import org.eclipse.jface.viewers.TreeViewer;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.custom.CCombo;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Group;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Text;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.LogLevelType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.BaseEventComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceControlContentProvider;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceControlLabelProvider;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceProviderGroup;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.UstProviderComponent;
-import org.eclipse.ui.dialogs.FilteredTree;
-import org.eclipse.ui.dialogs.PatternFilter;
-
-/**
- * <p>
- * A composite for collecting information about UST events to be enabled.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class EnableUstEventsComposite extends Composite implements IEnableUstEvents  {
-
-    // ------------------------------------------------------------------------
-    // Constants
-    // ------------------------------------------------------------------------
-
-    private enum GroupEnum { TRACEPOINTS, WILDCARD, LOGLEVEL }
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-
-    /**
-     * A button to enable/disable the tracepoints group
-     */
-    private Button fTracepointsActivateButton;
-    /**
-     * A tree viewer for diplaying and selection of available tracepoints.
-     */
-    private CheckboxTreeViewer fTracepointsViewer;
-    /**
-     * A button to enable/disable the wildcard group
-     */
-    private Button fWildcardActivateButton;
-    /**
-     * A Text field for the event's wildcard.
-     */
-    private Text fWildcardText;
-    /**
-     * A button to enable/disable the log level group
-     */
-    private Button fLogLevelActivateButton;
-    /**
-     * A Text field for the event name for the log level enablement.
-     */
-    private Text fLogLevelEventNameText;
-    /**
-     * A Combo box for selecting the log level.
-     */
-    private CCombo fLogLevelCombo;
-    /**
-     * A button for selecting the log level (range 0 to level).
-     */
-    private Button fLogLevelButton;
-    /**
-     * A button for selecting the specified log level only.
-     */
-    private Button fLogLevelOnlyButton;
-    /**
-     * The filter text
-     */
-    private Text fFilterText;
-
-    /**
-     * The referenced trace provider group containing the UST providers
-     * component which contains a list of available tracepoints.
-     */
-    private final TraceProviderGroup fProviderGroup;
-    /**
-     * The flag indicating that tracepoints are selected.
-     */
-    private boolean fIsTracepoints;
-    /**
-     * The flag indicating that all tracepoints (across providers) are selected.
-     */
-    private boolean fIsAllTracepoints;
-    /**
-     * The list of tracepoints to be enabled.
-     */
-    private List<String> fSelectedEvents;
-    /**
-     * The flag indicating that all wildcard are selected..
-     */
-    private boolean fIsWildcard;
-    /**
-     * The wildcard if wildcard is selected.
-     */
-    private String fWildcard;
-    /**
-     *The flag indicating that all log level are selected.
-     */
-    private boolean fIsLogLevel;
-    /**
-     * The event name for the log level enablement.
-     */
-    private String fLogLevelEventName;
-    /**
-     * The type of the log level (loglevel or loglevel-only)
-     */
-    private LogLevelType fLogLevelType;
-    /**
-     * The actual selected log level.
-     */
-    private TraceLogLevel fLogLevel;
-    /**
-     * The filter expression
-     */
-    private String fFilterExpression;
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-    /**
-     * Constructor
-     * @param parent - a parent composite
-     * @param style - a composite style
-     * @param providerGroup - the trace provider group
-     */
-    public EnableUstEventsComposite(Composite parent, int style, TraceProviderGroup providerGroup) {
-        super(parent, style);
-        fProviderGroup = providerGroup;
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    @Override
-    public boolean isTracepoints() {
-        return fIsTracepoints;
-    }
-
-    @Override
-    public boolean isAllTracePoints() {
-        return fIsAllTracepoints;
-    }
-
-    @Override
-    public List<String> getEventNames() {
-        return new ArrayList<>(fSelectedEvents);
-    }
-
-    @Override
-    public boolean isWildcard() {
-        return fIsWildcard;
-    }
-
-    @Override
-    public String getWildcard() {
-        return fWildcard;
-    }
-
-    @Override
-    public boolean isLogLevel() {
-        return fIsLogLevel;
-    }
-
-    @Override
-    public LogLevelType getLogLevelType() {
-        return fLogLevelType;
-    }
-
-    @Override
-    public TraceLogLevel getLogLevel() {
-        return fLogLevel;
-    }
-
-    @Override
-    public String getLogLevelEventName() {
-        return fLogLevelEventName;
-    }
-
-    @Override
-    public String getFilterExpression() {
-        return fFilterExpression;
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    /**
-     * Create the contents of this event composite
-     */
-    public void createContent() {
-
-        // Tracepoints Group
-        createTracepointsGroup();
-
-        // Wildcard Group
-        createWildCardGroup();
-
-        // Log Level Group
-        createLogLevelGroup();
-
-        // Filter Group
-        createFilterGroup();
-
-        // Set default enablements
-        setEnablements(GroupEnum.TRACEPOINTS);
-    }
-
-    /**
-     * Validates the UST composite input data.
-     *
-     * @return true if configured data is valid and can be retrieved.
-     */
-    public boolean isValid() {
-
-        fIsTracepoints = fTracepointsActivateButton.getSelection();
-        fIsWildcard = fWildcardActivateButton.getSelection();
-        fIsLogLevel = fLogLevelActivateButton.getSelection();
-
-        // initialize tracepoint fields
-        fIsAllTracepoints = false;
-        fSelectedEvents = new ArrayList<>();
-        if (fIsTracepoints) {
-            Set<String> set = new HashSet<>();
-            Object[] checkedElements = fTracepointsViewer.getCheckedElements();
-            int totalNbEvents = 0;
-            for (int i = 0; i < checkedElements.length; i++) {
-                ITraceControlComponent component = (ITraceControlComponent) checkedElements[i];
-                if (component instanceof BaseEventComponent) {
-                    totalNbEvents++;
-                    if (!set.contains(component.getName())) {
-                        set.add(component.getName());
-                        fSelectedEvents.add(component.getName());
-                    }
-                }
-
-            }
-
-            // verify if all events are selected
-            int nbUstEvents = 0;
-            List<ITraceControlComponent> comps = fProviderGroup.getChildren(UstProviderComponent.class);
-            for (ITraceControlComponent comp : comps) {
-                nbUstEvents += comp.getChildren().length;
-            }
-            fIsAllTracepoints = (nbUstEvents == totalNbEvents);
-        }
-
-        // initialize log level event name string
-        fLogLevelType = LogLevelType.LOGLEVEL_NONE;
-        fLogLevelEventName = null;
-
-        if (fIsLogLevel) {
-            if (fLogLevelButton.getSelection()) {
-                fLogLevelType = LogLevelType.LOGLEVEL;
-            } else if (fLogLevelOnlyButton.getSelection()) {
-                fLogLevelType = LogLevelType.LOGLEVEL_ONLY;
-            }
-
-            String temp = fLogLevelEventNameText.getText();
-            if (temp.isEmpty() ||
-                temp.matches("\\s*") || //$NON-NLS-1$
-                (!temp.matches("^[\\s]{0,}$") && !temp.matches("^[a-zA-Z0-9\\-\\_]{1,}$"))) { //$NON-NLS-1$ //$NON-NLS-2$
-                MessageDialog.openError(getShell(),
-                        Messages.TraceControl_EnableEventsDialogTitle,
-                        Messages.TraceControl_InvalidLogLevelEventNameError + " (" + temp + ") \n");  //$NON-NLS-1$ //$NON-NLS-2$
-
-                return false;
-            }
-
-            fLogLevelEventName = temp;
-
-            TraceLogLevel[] levels = TraceLogLevel.values();
-            int id = fLogLevelCombo.getSelectionIndex();
-
-            if (id < 0) {
-                MessageDialog.openError(getShell(),
-                        Messages.TraceControl_EnableEventsDialogTitle,
-                        Messages.TraceControl_InvalidLogLevel + " (" + temp + ") \n");  //$NON-NLS-1$ //$NON-NLS-2$
-
-                return false;
-            }
-            fLogLevel = levels[id];
-        }
-
-        // initialize wildcard with null
-        fWildcard = null;
-        if (fIsWildcard) {
-            String tempWildcard = fWildcardText.getText();
-            if (tempWildcard.isEmpty() ||
-                tempWildcard.matches("\\s*") || //$NON-NLS-1$
-                (!tempWildcard.matches("^[\\s]{0,}$") && !tempWildcard.matches("^[a-zA-Z0-9\\-\\_\\*\\\\\\']{1,}$"))) { //$NON-NLS-1$ //$NON-NLS-2$
-                MessageDialog.openError(getShell(),
-                        Messages.TraceControl_EnableEventsDialogTitle,
-                        Messages.TraceControl_InvalidWildcardError + " (" + tempWildcard + ") \n");  //$NON-NLS-1$ //$NON-NLS-2$
-
-                return false;
-            }
-
-            fWildcard = tempWildcard;
-        }
-
-        // initialize filter with null
-        fFilterExpression = null;
-        if (fProviderGroup.isEventFilteringSupported()) {
-            String tempFilter = fFilterText.getText();
-
-            if(!tempFilter.isEmpty() && !tempFilter.matches("\\s*")) { //$NON-NLS-1$
-                fFilterExpression = tempFilter;
-            }
-        }
-
-        // validation successful -> call super.okPressed()
-        return true;
-    }
-
-    // ------------------------------------------------------------------------
-    // Helper methods
-    // ------------------------------------------------------------------------
-
-    /**
-     * Creates tracepoints group.
-     */
-    private void createTracepointsGroup() {
-        Group tpMainGroup = new Group(this, SWT.SHADOW_NONE);
-        tpMainGroup.setText(Messages.TraceControl_EnableEventsTracepointGroupName);
-        GridLayout layout = new GridLayout(2, false);
-        tpMainGroup.setLayout(layout);
-        GridData data = new GridData(GridData.FILL_BOTH);
-        tpMainGroup.setLayoutData(data);
-
-        Composite buttonComposite = new Composite(tpMainGroup, SWT.NONE);
-        layout = new GridLayout(1, true);
-        buttonComposite.setLayout(layout);
-        data = new GridData(SWT.BEGINNING, SWT.CENTER, false, true);
-        buttonComposite.setLayoutData(data);
-
-        fTracepointsActivateButton = new Button(buttonComposite, SWT.RADIO);
-        fTracepointsActivateButton.setText(Messages.TraceControl_EnableGroupSelectionName);
-        data = new GridData(GridData.FILL_HORIZONTAL);
-        fTracepointsActivateButton.setLayoutData(data);
-        fTracepointsActivateButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                setEnablements(GroupEnum.TRACEPOINTS);
-            }
-        });
-
-        Group tpGroup = new Group(tpMainGroup, SWT.SHADOW_NONE);
-        layout = new GridLayout(1, true);
-        tpGroup.setLayout(layout);
-        data = new GridData(GridData.FILL_BOTH);
-        tpGroup.setLayoutData(data);
-        new FilteredTree(tpGroup, SWT.MULTI | SWT.H_SCROLL | SWT.V_SCROLL | SWT.BORDER, new PatternFilter(), true) {
-            @Override
-            protected TreeViewer doCreateTreeViewer(Composite aparent, int style) {
-                fTracepointsViewer = new CheckboxTreeViewer(aparent, SWT.MULTI | SWT.H_SCROLL | SWT.V_SCROLL);
-                fTracepointsViewer.getTree().setToolTipText(Messages.TraceControl_EnableEventsTracepointTreeTooltip);
-                fTracepointsViewer.setContentProvider(new UstContentProvider());
-
-                fTracepointsViewer.setLabelProvider(new UstLabelProvider());
-                fTracepointsViewer.addCheckStateListener(new UstCheckStateListener());
-
-                fTracepointsViewer.setInput(fProviderGroup.getParent());
-                fTracepointsViewer.getTree().setLayoutData(new GridData(GridData.FILL_BOTH));
-                return fTracepointsViewer;
-            }
-        };
-    }
-
-    /**
-     * Creates wildcard group.
-     */
-    private void createWildCardGroup() {
-        Group wildcardMainGroup = new Group(this, SWT.SHADOW_NONE);
-        wildcardMainGroup.setText(Messages.TraceControl_EnableEventsWildcardGroupName);
-        GridLayout layout = new GridLayout(2, false);
-        wildcardMainGroup.setLayout(layout);
-        GridData data = new GridData(GridData.FILL_HORIZONTAL);
-        wildcardMainGroup.setLayoutData(data);
-
-        Composite buttonComposite = new Composite(wildcardMainGroup, SWT.NONE);
-        layout = new GridLayout(1, false);
-        buttonComposite.setLayout(layout);
-        data = new GridData(SWT.BEGINNING, SWT.CENTER, false, true);
-        buttonComposite.setLayoutData(data);
-
-        fWildcardActivateButton = new Button(buttonComposite, SWT.RADIO);
-        fWildcardActivateButton.setText(Messages.TraceControl_EnableGroupSelectionName);
-        fWildcardActivateButton.setSelection(false);
-        data = new GridData(GridData.FILL_HORIZONTAL);
-        fWildcardActivateButton.setLayoutData(data);
-        fWildcardActivateButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                setEnablements(GroupEnum.WILDCARD);
-            }
-        });
-
-        Group wildcardGroup = new Group(wildcardMainGroup, SWT.SHADOW_NONE);
-        layout = new GridLayout(3, true);
-        wildcardGroup.setLayout(layout);
-        data = new GridData(GridData.FILL_HORIZONTAL);
-        wildcardGroup.setLayoutData(data);
-
-        Label wildcardLabel = new Label(wildcardGroup, SWT.LEFT);
-        wildcardLabel.setText(Messages.TraceControl_EnableEventsWildcardLabel);
-        data = new GridData(GridData.FILL_HORIZONTAL);
-        data.horizontalSpan = 1;
-        wildcardLabel.setLayoutData(data);
-
-        fWildcardText = new Text(wildcardGroup, SWT.LEFT);
-        fWildcardText.setToolTipText(Messages.TraceControl_EnableEventsWildcardTooltip);
-        data = new GridData(GridData.FILL_HORIZONTAL);
-        data.horizontalSpan = 2;
-        fWildcardText.setLayoutData(data);
-    }
-
-    /**
-     * Creates log level group.
-     */
-    private void createLogLevelGroup() {
-        Group logLevelMainGroup = new Group(this, SWT.SHADOW_NONE);
-        logLevelMainGroup.setText(Messages.TraceControl_EnableEventsLogLevelGroupName);
-        GridLayout layout = new GridLayout(2, false);
-        logLevelMainGroup.setLayout(layout);
-        GridData data = new GridData(GridData.FILL_HORIZONTAL);
-        logLevelMainGroup.setLayoutData(data);
-
-        Composite buttonComposite = new Composite(logLevelMainGroup, SWT.NONE);
-        layout = new GridLayout(1, false);
-        buttonComposite.setLayout(layout);
-        data = new GridData(SWT.BEGINNING, SWT.CENTER, false, true);
-        buttonComposite.setLayoutData(data);
-
-        fLogLevelActivateButton = new Button(buttonComposite, SWT.RADIO);
-        fLogLevelActivateButton.setText(Messages.TraceControl_EnableGroupSelectionName);
-        fLogLevelActivateButton.setSelection(false);
-        data = new GridData(GridData.FILL_HORIZONTAL);
-        fLogLevelActivateButton.setLayoutData(data);
-        fLogLevelActivateButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                setEnablements(GroupEnum.LOGLEVEL);
-            }
-        });
-
-        Group logLevelGroup = new Group(logLevelMainGroup, SWT.SHADOW_NONE);
-        layout = new GridLayout(3, true);
-        logLevelGroup.setLayout(layout);
-        logLevelGroup.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-
-        Label logLevelEventNameLabel = new Label(logLevelGroup, SWT.LEFT);
-        logLevelEventNameLabel.setText(Messages.TraceControl_EnableEventsEventNameLabel);
-
-        data = new GridData(GridData.FILL_BOTH);
-        data.horizontalSpan = 1;
-        logLevelEventNameLabel.setLayoutData(data);
-
-        fLogLevelEventNameText = new Text(logLevelGroup, SWT.LEFT);
-        fLogLevelEventNameText.setToolTipText(Messages.TraceControl_EnableEventsLoglevelEventNameTooltip);
-        data = new GridData(GridData.FILL_BOTH);
-        data.horizontalSpan = 2;
-        fLogLevelEventNameText.setLayoutData(data);
-
-        TraceLogLevel[] levels = TraceLogLevel.values();
-
-        String[] levelNames = new String[levels.length - 1];
-        int k = 0;
-        for (int i = 0; i < levels.length; i++) {
-            if (levels[i] != TraceLogLevel.LEVEL_UNKNOWN) {
-                levelNames[k++] = levels[i].getInName();
-            }
-        }
-
-        fLogLevelCombo = new CCombo(logLevelGroup, SWT.READ_ONLY);
-        fLogLevelCombo.setItems(levelNames);
-        fLogLevelCombo.setToolTipText(Messages.TraceControl_EnableEventsLogLevelTooltip);
-        data = new GridData(GridData.FILL_HORIZONTAL);
-        data.horizontalSpan = 4;
-        fLogLevelCombo.setLayoutData(data);
-
-        fLogLevelButton = new Button(logLevelGroup, SWT.RADIO);
-        fLogLevelButton.setText(Messages.TraceControl_EnableEventsLogLevelTypeName);
-        fLogLevelButton.setToolTipText(Messages.TraceControl_EnableEventsLogLevelTypeTooltip);
-        data = new GridData(GridData.FILL_BOTH);
-        fLogLevelButton.setLayoutData(data);
-        fLogLevelButton.setSelection(true);
-
-        fLogLevelOnlyButton = new Button(logLevelGroup, SWT.RADIO);
-        fLogLevelOnlyButton.setText(Messages.TraceControl_EnableEventsLogLevelOnlyTypeName);
-        fLogLevelOnlyButton.setToolTipText(Messages.TraceControl_EnableEventsLogLevelOnlyTypeTooltip);
-        data = new GridData(GridData.FILL_BOTH);
-        fLogLevelButton.setLayoutData(data);
-    }
-
-    void createFilterGroup() {
-        if (fProviderGroup.isEventFilteringSupported()) {
-            Group filterMainGroup = new Group(this, SWT.SHADOW_NONE);
-            filterMainGroup.setText(Messages.TraceControl_EnableEventsFilterGroupName);
-            GridLayout layout = new GridLayout(3, false);
-            filterMainGroup.setLayout(layout);
-            GridData data = new GridData(GridData.FILL_HORIZONTAL);
-            filterMainGroup.setLayoutData(data);
-
-            fFilterText = new Text(filterMainGroup, SWT.LEFT);
-            fFilterText.setToolTipText(Messages.TraceControl_EnableEventsFilterTooltip);
-            data = new GridData(GridData.FILL_HORIZONTAL);
-            fFilterText.setLayoutData(data);
-        }
-    }
-
-    /**
-     * Enable/selects widgets depending on the group specified.
-     * @param group - group to enable.
-     */
-    private void setEnablements(GroupEnum group) {
-
-        // Enable/disable trace point items
-        fTracepointsActivateButton.setSelection(group == GroupEnum.TRACEPOINTS);
-        fTracepointsViewer.getTree().setEnabled(group == GroupEnum.TRACEPOINTS);
-
-        // Enable/disable wildcard items
-        fWildcardActivateButton.setSelection(group == GroupEnum.WILDCARD);
-        fWildcardText.setEnabled(group == GroupEnum.WILDCARD);
-
-        // Enable/disable log level items
-        fLogLevelActivateButton.setSelection(group == GroupEnum.LOGLEVEL);
-        fLogLevelEventNameText.setEnabled(group == GroupEnum.LOGLEVEL);
-        fLogLevelCombo.setEnabled(group == GroupEnum.LOGLEVEL);
-        fLogLevelButton.setEnabled(group == GroupEnum.LOGLEVEL);
-        fLogLevelOnlyButton.setEnabled(group == GroupEnum.LOGLEVEL);
-    }
-
-    // ------------------------------------------------------------------------
-    // Local classes
-    // ------------------------------------------------------------------------
-    /**
-     * Content provider for the tracepoints tree.
-     */
-    public static final class UstContentProvider extends TraceControlContentProvider {
-        @Override
-        public Object[] getChildren(Object parentElement) {
-            if (parentElement instanceof TargetNodeComponent) {
-                List<ITraceControlComponent> children = ((ITraceControlComponent)parentElement).getChildren(TraceProviderGroup.class);
-                return children.toArray(new ITraceControlComponent[children.size()]);
-            }
-            if (parentElement instanceof TraceProviderGroup) {
-                List<ITraceControlComponent> children = ((ITraceControlComponent)parentElement).getChildren(UstProviderComponent.class);
-                return children.toArray(new ITraceControlComponent[children.size()]);
-            }
-            if (parentElement instanceof ITraceControlComponent) {
-                return ((ITraceControlComponent)parentElement).getChildren();
-            }
-            return new Object[0];
-        }
-    }
-
-    /**
-     * Content label for the tracepoints tree.
-     */
-    public static final class UstLabelProvider extends TraceControlLabelProvider {
-        @Override
-        public Image getImage(Object element) {
-            return null;
-        }
-        @Override
-        public String getText(Object element) {
-            if ((element != null) && (element instanceof TraceProviderGroup)) {
-                return Messages.TraceControl_EnableEventsTracepointTreeAllLabel;
-            }
-
-            if ((element != null) && (element instanceof UstProviderComponent)) {
-                return Messages.TraceControl_EnableEventsTracepointTreeAllLabel + " - " + ((UstProviderComponent)element).getName(); //$NON-NLS-1$
-            }
-            return super.getText(element);
-        }
-    }
-
-    /**
-     * Check state listener for the tracepoints tree.
-     */
-    public final class UstCheckStateListener implements ICheckStateListener {
-        @Override
-        public void checkStateChanged(CheckStateChangedEvent event) {
-            if (event.getChecked()) {
-                if (event.getElement() instanceof TraceProviderGroup) {
-                    fTracepointsViewer.setSubtreeChecked(event.getElement(), true);
-                }
-                if (event.getElement() instanceof UstProviderComponent) {
-                    fTracepointsViewer.setSubtreeChecked(event.getElement(), true);
-                }
-            } else {
-                if (event.getElement() instanceof TraceProviderGroup) {
-                    fTracepointsViewer.setSubtreeChecked(event.getElement(), true);
-                }
-                if (event.getElement() instanceof UstProviderComponent) {
-                    ITraceControlComponent component = (ITraceControlComponent) event.getElement();
-                    fTracepointsViewer.setSubtreeChecked(event.getElement(), false);
-                    fTracepointsViewer.setChecked(component.getParent(), false);
-                } else {
-                    ITraceControlComponent component = (ITraceControlComponent) event.getElement();
-                    fTracepointsViewer.setChecked(component.getParent(), false);
-                    fTracepointsViewer.setChecked(component.getParent().getParent(), false);
-                }
-            }
-        }
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/GetEventInfoDialog.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/GetEventInfoDialog.java
deleted file mode 100644 (file)
index 88c156a..0000000
+++ /dev/null
@@ -1,281 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
-
-import java.util.Arrays;
-
-import org.eclipse.jface.dialogs.Dialog;
-import org.eclipse.jface.dialogs.IDialogConstants;
-import org.eclipse.jface.dialogs.MessageDialog;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.custom.CCombo;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.events.SelectionListener;
-import org.eclipse.swt.graphics.Point;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Group;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.swt.widgets.Text;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
-
-/**
- * <p>
- * Dialog box for collecting information about the events to enable.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class GetEventInfoDialog extends Dialog implements IGetEventInfoDialog {
-
-    // ------------------------------------------------------------------------
-    // Constants
-    // ------------------------------------------------------------------------
-    /**
-     * The icon file for this dialog box.
-     */
-    public static final String TARGET_NEW_CONNECTION_ICON_FILE = "icons/elcl16/enable_event.gif"; //$NON-NLS-1$
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-    /**
-     * The session combo box.
-     */
-    private CCombo fSessionsCombo = null;
-    /**
-     * The channel combo box.
-     */
-    private CCombo fChannelsCombo = null;
-    /**
-     * The filter text
-     */
-    private Text fFilterText;
-    /**
-     * The list of available sessions.
-     */
-    private TraceSessionComponent[] fSessions;
-    /**
-     * True for kernel, false for UST.
-     */
-    private boolean fIsKernel;
-    /**
-     * Index in session array (selected session).
-     */
-    private int fSessionIndex = 0;
-    /**
-     * The Channel where the events should be enabled.
-     */
-    private TraceChannelComponent fChannel;
-    /**
-     * List of available channels of the selected session.
-     */
-    private TraceChannelComponent[] fChannels;
-    /**
-     * The filter expression
-     */
-    private String fFilterExpression;
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-    /**
-     * Constructor of dialog box.
-     * @param shell - the shell for the dialog box
-     */
-    public GetEventInfoDialog(Shell shell) {
-        super(shell);
-        setShellStyle(SWT.RESIZE | getShellStyle());
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    @Override
-    public TraceSessionComponent getSession() {
-        return fSessions[fSessionIndex];
-    }
-
-    @Override
-    public TraceChannelComponent getChannel() {
-        return fChannel;
-    }
-
-    @Override
-    public void setIsKernel(boolean isKernel) {
-        fIsKernel = isKernel;
-    }
-
-    @Override
-    public void setSessions(TraceSessionComponent[] sessions) {
-        fSessions = Arrays.copyOf(sessions, sessions.length);
-    }
-
-    @Override
-    public String getFilterExpression() {
-       return fFilterExpression;
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    protected void configureShell(Shell newShell) {
-        super.configureShell(newShell);
-        newShell.setText(Messages.TraceControl_EnableEventsDialogTitle);
-        newShell.setImage(Activator.getDefault().loadIcon(TARGET_NEW_CONNECTION_ICON_FILE));
-    }
-
-    @Override
-    protected Control createDialogArea(Composite parent) {
-
-        // Main dialog panel
-        Composite dialogComposite = new Composite(parent, SWT.NONE);
-        GridLayout layout = new GridLayout(1, true);
-        dialogComposite.setLayout(layout);
-        dialogComposite.setLayoutData(new GridData(GridData.FILL_BOTH));
-
-        Group sessionsGroup = new Group(dialogComposite, SWT.SHADOW_NONE);
-        sessionsGroup.setText(Messages.TraceControl_EnableEventsSessionGroupName);
-        layout = new GridLayout(1, true);
-        sessionsGroup.setLayout(layout);
-        GridData data = new GridData(GridData.FILL_HORIZONTAL);
-        sessionsGroup.setLayoutData(data);
-
-        fSessionsCombo = new CCombo(sessionsGroup, SWT.READ_ONLY);
-        fSessionsCombo.setToolTipText(Messages.TraceControl_EnableEventsSessionsTooltip);
-        fSessionsCombo.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-
-        String items[] = new String[fSessions.length];
-        for (int i = 0; i < items.length; i++) {
-            items[i] = String.valueOf(fSessions[i].getName());
-        }
-
-        fSessionsCombo.setItems(items);
-        fSessionsCombo.setEnabled(fSessions.length > 0);
-
-        Group channelsGroup = new Group(dialogComposite, SWT.SHADOW_NONE);
-        channelsGroup.setText(Messages.TraceControl_EnableEventsChannelGroupName);
-        layout = new GridLayout(1, true);
-        channelsGroup.setLayout(layout);
-        data = new GridData(GridData.FILL_HORIZONTAL);
-        channelsGroup.setLayoutData(data);
-
-        fChannelsCombo = new CCombo(channelsGroup, SWT.READ_ONLY);
-        fChannelsCombo.setToolTipText(Messages.TraceControl_EnableEventsChannelsTooltip);
-        fChannelsCombo.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        fChannelsCombo.setEnabled(false);
-
-        fSessionsCombo.addSelectionListener(new SelectionListener() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                fSessionIndex = fSessionsCombo.getSelectionIndex();
-
-                if (fSessionIndex >= 0) {
-                    TraceDomainComponent domain = null;
-                    TraceDomainComponent[] domains = fSessions[fSessionIndex].getDomains();
-                    for (int i = 0; i < domains.length; i++) {
-
-                        if (domains[i].isKernel() == fIsKernel) {
-                            domain = domains[i];
-                            break;
-                        }
-                    }
-
-                    if (domain != null) {
-                        fChannels = domain.getChannels();
-                        String selectionItems[] = new String[fChannels.length];
-                        for (int i = 0; i < selectionItems.length; i++) {
-                            selectionItems[i] = String.valueOf(fChannels[i].getName());
-                        }
-                        fChannelsCombo.setItems(selectionItems);
-                        fChannelsCombo.setEnabled(fChannels.length > 0);
-                    } else {
-                        fChannelsCombo.setItems(new String[0]);
-                        fChannelsCombo.setEnabled(false);
-                        fChannels = null;
-                   }
-                   fChannelsCombo.getParent().getParent().layout();
-                }
-            }
-
-            @Override
-            public void widgetDefaultSelected(SelectionEvent e) {
-            }
-        });
-
-        // take first session to test whether events filtering is supported or not
-        if (fSessions[0].isEventFilteringSupported() && !fIsKernel) {
-            Group filterMainGroup = new Group(dialogComposite, SWT.SHADOW_NONE);
-            filterMainGroup.setText(Messages.TraceControl_EnableEventsFilterGroupName);
-            layout = new GridLayout(2, false);
-            filterMainGroup.setLayout(layout);
-            data = new GridData(GridData.FILL_HORIZONTAL);
-            filterMainGroup.setLayoutData(data);
-
-            fFilterText = new Text(filterMainGroup, SWT.LEFT);
-            fFilterText.setToolTipText(Messages.TraceControl_EnableEventsFilterTooltip);
-            data = new GridData(GridData.FILL_HORIZONTAL);
-            fFilterText.setLayoutData(data);
-        }
-
-        getShell().setMinimumSize(new Point(300, 200));
-
-        return dialogComposite;
-    }
-
-    @Override
-    protected void createButtonsForButtonBar(Composite parent) {
-        createButton(parent, IDialogConstants.CANCEL_ID, "&Cancel", true); //$NON-NLS-1$
-        createButton(parent, IDialogConstants.OK_ID, "&Ok", true); //$NON-NLS-1$
-    }
-
-    @Override
-    protected void okPressed() {
-
-        if (fSessionsCombo.getSelectionIndex() < 0) {
-            MessageDialog.openError(getShell(),
-                  Messages.TraceControl_EnableEventsDialogTitle,
-                  Messages.TraceControl_EnableEventsNoSessionError);
-            return;
-        }
-
-        fSessionIndex = fSessionsCombo.getSelectionIndex();
-
-        // if no channel is available or no channel is selected use default channel indicated by fChannel=null
-        fChannel = null;
-        if ((fChannels != null) && (fChannelsCombo.getSelectionIndex() >= 0)) {
-            fChannel = fChannels[fChannelsCombo.getSelectionIndex()];
-        }
-
-        // initialize filter with null
-        fFilterExpression = null;
-        if (fSessions[0].isEventFilteringSupported() && !fIsKernel) {
-            String tempFilter = fFilterText.getText();
-
-            if(!tempFilter.isEmpty() && !tempFilter.matches("\\s*")) { //$NON-NLS-1$
-                fFilterExpression = tempFilter;
-            }
-        }
-
-        super.okPressed();
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IAddContextDialog.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IAddContextDialog.java
deleted file mode 100644 (file)
index 97b007f..0000000
+++ /dev/null
@@ -1,47 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
-
-import java.util.List;
-
-/**
- * <p>
- * Interface for providing information about contexts to be added to channels/events.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public interface IAddContextDialog {
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    /**
-     * Sets the available contexts to choose from.
-     * @param contexts - a list of available contexts.
-     */
-    void setAvalibleContexts(List<String> contexts);
-
-    /**
-     * @return array of contexts to be added
-     */
-    List<String> getContexts();
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-    /**
-     * @return returns the open return value
-     */
-    int open();
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IConfirmDialog.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IConfirmDialog.java
deleted file mode 100644 (file)
index 2ecd326..0000000
+++ /dev/null
@@ -1,38 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
-
-import org.eclipse.swt.widgets.Shell;
-
-/**
- * <p>
- * Interface for a confirmation dialog.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public interface IConfirmDialog {
-
-    /**
-     * Open a confirmation dialog
-     *
-     * @param parent
-     *            The parent shell
-     * @param title
-     *            The title of the dialog window
-     * @param message
-     *            The message in the dialog window
-     * @return If the user clicked OK (true) or Cancel (false)
-     */
-    boolean openConfirm(Shell parent, String title, String message);
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/ICreateSessionDialog.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/ICreateSessionDialog.java
deleted file mode 100644 (file)
index 833c868..0000000
+++ /dev/null
@@ -1,52 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
-
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISessionInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionGroup;
-
-/**
- * <p>
- * Interface for create session dialog.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public interface ICreateSessionDialog {
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    /**
-     * Get the parameters necessary for the creation of a LTTng session
-     *
-     * @return the parameters
-     */
-    ISessionInfo getParameters();
-
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-    /**
-     * Initializes the dialog box.
-     * @param group - the session group
-     */
-    void initialize(TraceSessionGroup group);
-
-    /**
-     * @return the open return value
-     */
-    int open();
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IEnableChannelDialog.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IEnableChannelDialog.java
deleted file mode 100644 (file)
index d23174d..0000000
+++ /dev/null
@@ -1,65 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
-
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IChannelInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent;
-
-/**
- * <p>
- * Interface for the enable channel dialog when domain is known.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public interface IEnableChannelDialog {
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-    /**
-     * @return the configuration info for the new channel.
-     */
-    IChannelInfo getChannelInfo();
-
-    /**
-     * Sets the domain component
-     * @param domain - the trace domain component
-     */
-    void setDomainComponent(TraceDomainComponent domain);
-
-    /**
-     * Set the targent node component
-     * @param node - the node component
-     */
-    void setTargetNodeComponent(TargetNodeComponent node);
-
-    /**
-     * @return true for Kernel domain. False for UST.
-     */
-    boolean isKernel();
-
-    /**
-     * Sets the whether dialog is for Kernel or UST
-     * @param isKernel true for kernel domain else UST
-     */
-    void setHasKernel(boolean isKernel);
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-    /**
-     * @return the open return value
-     */
-    int open();
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IEnableEventsDialog.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IEnableEventsDialog.java
deleted file mode 100644 (file)
index f34837e..0000000
+++ /dev/null
@@ -1,53 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
-
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceProviderGroup;
-
-/**
- * <p>
- * Interface for providing information about Kernel or UST events to be enabled.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public interface IEnableEventsDialog extends IEnableKernelEvents, IEnableUstEvents {
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-    /**
-     * @return the session the events shall be enabled.
-     */
-    boolean isKernel();
-
-    /**
-     * Sets the trace provider group.
-     * @param providerGroup -  a trace provider group
-     */
-    void setTraceProviderGroup(TraceProviderGroup providerGroup);
-
-    /**
-     * Sets the trace domain component.
-     * @param domain - a domain of the events (null if not known)
-     */
-    void setTraceDomainComponent(TraceDomainComponent domain);
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-    /**
-     * @return returns the open return value
-     */
-    int open();
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IEnableKernelEvents.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IEnableKernelEvents.java
deleted file mode 100644 (file)
index 86adb6e..0000000
+++ /dev/null
@@ -1,84 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
-
-import java.util.List;
-
-/**
- * <p>
- * Interface for providing information about kernel events to be enabled.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public interface IEnableKernelEvents {
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    /**
-     * @return a flag whether the tracepoints shall be configured.
-     */
-    boolean isTracepoints();
-
-    /**
-     * @return a flag indicating whether all tracepoints shall be enabled or not.
-     */
-    boolean isAllTracePoints();
-
-    /**
-     * @return a flag whether the syscalls shall be configured.
-     */
-    boolean isSysCalls();
-
-    /**
-     * @return a flag indicating whether syscalls shall be enabled or not.
-     */
-    boolean isAllSysCalls();
-
-    /**
-     * @return a list of event names to be enabled.
-     */
-    List<String> getEventNames();
-
-    /**
-     * @return a flag whether the dynamic probe shall be configured.
-     */
-    boolean isDynamicProbe();
-
-    /**
-     * @return event name of the dynamic probe (or null if no dynamic probe).
-     */
-    String getProbeEventName();
-
-    /**
-     * @return the dynamic probe (or null if no dynamic probe).
-     */
-    String getProbeName();
-
-    /**
-     * @return a flag whether the dynamic function entry/return probe shall be configured.
-     */
-    boolean isDynamicFunctionProbe();
-
-    /**
-     * @return event name of the dynamic function entry/exit probe (or null if no dynamic probe).
-     */
-    String getFunctionEventName();
-
-    /**
-     * @return the dynamic function entry/exit probe (or null if no dynamic probe).
-     */
-    String getFunction();
-
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IEnableUstEvents.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IEnableUstEvents.java
deleted file mode 100644 (file)
index 2b06bcc..0000000
+++ /dev/null
@@ -1,83 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
-
-import java.util.List;
-
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.LogLevelType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
-
-/**
- * <p>
- * Interface for providing information about UST events to be enabled.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public interface IEnableUstEvents {
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    /**
-     * @return a flag whether the tracepoints shall be configured.
-     */
-    boolean isTracepoints();
-
-    /**
-     * @return a flag indicating whether all tracepoints shall be enabled or not.
-     */
-    boolean isAllTracePoints();
-
-    /**
-     * @return a list of event names to be enabled.
-     */
-    List<String> getEventNames();
-
-    /**
-     * @return a flag whether events using wildcards should be enabled
-     */
-    boolean isWildcard();
-
-    /**
-     * @return a wildcard
-     */
-    String getWildcard();
-
-    /**
-     * @return a flag whether events using log levels should be enabled
-     */
-    boolean isLogLevel();
-
-    /**
-     * @return a log level type (loglevel or loglevel-only)
-     */
-    LogLevelType getLogLevelType();
-
-    /**
-     * @return a log level
-     */
-    TraceLogLevel getLogLevel();
-
-    /**
-     * @return a event name for the log level enable action
-     */
-    String getLogLevelEventName();
-
-    /**
-     * @return a filter expression
-     */
-    String getFilterExpression();
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IGetEventInfoDialog.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IGetEventInfoDialog.java
deleted file mode 100644 (file)
index 77c3c22..0000000
+++ /dev/null
@@ -1,65 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
-
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
-
-/**
- * <p>
- * Interface for a dialog box for collecting information about the events to enable.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public interface IGetEventInfoDialog {
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-    /**
-     * @return the session the events shall be enabled.
-     */
-    TraceSessionComponent getSession();
-
-    /**
-     * @return the channel the events shall be enabled. Null for default channel.
-     */
-    TraceChannelComponent getChannel();
-
-    /**
-     * Sets flag about domain.
-     * @param isKernel - true for kernel, false for UST
-     */
-    void setIsKernel(boolean isKernel);
-
-    /**
-     * Sets available session.
-     * @param sessions - a array of available sessions.
-     */
-    void setSessions(TraceSessionComponent[] sessions);
-
-    /**
-     * Returns the filter expression.
-     * @return the filter expression or null for no filtering
-     */
-    String getFilterExpression();
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-    /**
-     * @return returns the open return value
-     */
-    int open();
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IImportConfirmationDialog.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IImportConfirmationDialog.java
deleted file mode 100644 (file)
index 1ed0847..0000000
+++ /dev/null
@@ -1,49 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
-
-/**
- * <p>
- * Interface for dialog box for updating file import information.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public interface IImportConfirmationDialog {
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-    /**
-     * @param name old trace name.
-     */
-    void setTraceName(String name);
-
-    /**
-     * @return the new trace name if not overwrite.
-     */
-    String getNewTraceName();
-
-    /**
-     *
-     * @return true to overwrite existing trace.
-     */
-    boolean isOverwrite();
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-    /**
-     * @return the open return value
-     */
-    int open();
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IImportDialog.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/IImportDialog.java
deleted file mode 100644 (file)
index 8b92a40..0000000
+++ /dev/null
@@ -1,63 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
-
-import java.util.List;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
-
-/**
- * <p>
- * Interface for import traces dialog.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public interface IImportDialog {
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-    /**
-     * @return a list of trace paths to import.
-     */
-    List<ImportFileInfo> getTracePathes();
-
-    /**
-     * @return the project to import the traces to
-     */
-    IProject getProject();
-
-    /**
-     * Sets the session containing the traces to import
-     * @param session The trace session
-     */
-    void setSession(TraceSessionComponent session);
-
-    /**
-     * Sets the default project name to use
-     *
-     * @param defaultProject
-     *            the name of the default project to use
-     */
-    void setDefaultProject(String defaultProject);
-
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-    /**
-     * @return the open return value
-     */
-    int open();
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/INewConnectionDialog.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/INewConnectionDialog.java
deleted file mode 100644 (file)
index 5c3678d..0000000
+++ /dev/null
@@ -1,43 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Markus Schorn - Bug 448058: Use org.eclipse.remote in favor of RSE
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
-
-import org.eclipse.remote.core.IRemoteConnection;
-
-/**
- * <p>
- * Interface for connection information dialog.
- * </p>
- *
- *  @author Bernd Hufmann
- */
-public interface INewConnectionDialog {
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    /**
-     * Returns the selected connection.
-     * @return the selected connection, or <code>null</code>.
-     */
-    IRemoteConnection getConnection();
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-    /**
-     * @return returns the open return value
-     */
-    int open();
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/ISelectCommandScriptDialog.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/ISelectCommandScriptDialog.java
deleted file mode 100644 (file)
index 808845e..0000000
+++ /dev/null
@@ -1,32 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
-
-import java.util.List;
-
-/**
- * Interface for dialog for selecting a command script.
- *
- * @author Bernd Hufmann
- *
- */
-public interface ISelectCommandScriptDialog {
-    /**
-     * @return a list of command
-     */
-    List<String> getCommands();
-
-    /**
-     * @return the open return value
-     */
-    int open();
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/ImportConfirmationDialog.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/ImportConfirmationDialog.java
deleted file mode 100644 (file)
index d3125ce..0000000
+++ /dev/null
@@ -1,200 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
-
-import org.eclipse.jface.dialogs.Dialog;
-import org.eclipse.jface.dialogs.IDialogConstants;
-import org.eclipse.jface.dialogs.MessageDialog;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.graphics.Point;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.swt.widgets.Text;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
-
-/**
- * <p>
- * Dialog box for collecting session creation information.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class ImportConfirmationDialog extends Dialog implements IImportConfirmationDialog {
-
-    // ------------------------------------------------------------------------
-    // Constants
-    // ------------------------------------------------------------------------
-    /**
-     * The icon file for this dialog box.
-     */
-    public static final String IMPORT_ICON_FILE = "icons/elcl16/import_trace.gif"; //$NON-NLS-1$
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-    /**
-     * The radio button for selecting the overwrite action
-     */
-    private Button fOverwriteButton = null;
-    /**
-     * The radio button for selecting the renaming action
-     */
-    private Button fRenameButton = null;
-    /**
-     * The text widget for the session name
-     */
-    private Text fNewTraceNameText = null;
-    /**
-     * The trace name which already exists in the project
-     */
-    private String fTraceName = null;
-    /**
-     * The session name string.
-     */
-    private String fNewTraceName = null;
-    /**
-     * Flag whether default location (path) shall be used or not
-     */
-    private boolean fIsOverride = true;
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-    /**
-     * Constructor
-     * @param shell - a shell for the display of the dialog
-     */
-    public ImportConfirmationDialog(Shell shell) {
-        super(shell);
-        setShellStyle(SWT.RESIZE | getShellStyle());
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    @Override
-    public void setTraceName(String name) {
-        fTraceName = name;
-    }
-
-    @Override
-    public String getNewTraceName() {
-        return fNewTraceName;
-    }
-
-    @Override
-    public boolean isOverwrite() {
-        return fIsOverride;
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    protected void configureShell(Shell newShell) {
-        super.configureShell(newShell);
-        newShell.setText(Messages.TraceControl_ImportDialogConfirmationTitle);
-        newShell.setImage(Activator.getDefault().loadIcon(IMPORT_ICON_FILE));
-    }
-
-    @Override
-    protected Control createDialogArea(Composite parent) {
-
-        // Main dialog panel
-       Composite dialogComposite = new Composite(parent, SWT.NONE);
-        GridLayout layout = new GridLayout(1, true);
-        dialogComposite.setLayout(layout);
-        dialogComposite.setLayoutData(new GridData(GridData.FILL_BOTH));
-
-        Label sessionNameLabel = new Label(dialogComposite, SWT.RIGHT);
-        sessionNameLabel.setText(Messages.TraceControl_ImportDialogTraceAlreadyExistError + ": " + fTraceName); //$NON-NLS-1$
-
-        fOverwriteButton = new Button(dialogComposite, SWT.RADIO);
-        fOverwriteButton.setText(Messages.TraceControl_ImportDialogConfirmationOverwriteLabel);
-
-        fOverwriteButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                fNewTraceNameText.setEnabled(false);
-                fNewTraceNameText.setText(fTraceName);
-            }
-        });
-
-        fRenameButton = new Button(dialogComposite, SWT.RADIO);
-        fRenameButton.setText(Messages.TraceControl_ImportDialogConfirmationRenameLabel);
-
-        fRenameButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                fNewTraceNameText.setEnabled(true);
-            }
-        });
-
-        fNewTraceNameText = new Text(dialogComposite, SWT.NONE);
-        fNewTraceNameText.setToolTipText(Messages.TraceControl_ImportDialogConfirmationNewNameLabel);
-        fNewTraceNameText.setText(fTraceName);
-
-        // Default
-        fOverwriteButton.setSelection(true);
-        fNewTraceNameText.setEnabled(false);
-
-
-        // layout widgets
-        GridData data = new GridData(GridData.FILL_HORIZONTAL);
-
-        fNewTraceNameText.setLayoutData(data);
-
-        getShell().setMinimumSize(new Point(300, 150));
-
-        return dialogComposite;
-    }
-
-    @Override
-    protected void createButtonsForButtonBar(Composite parent) {
-        createButton(parent, IDialogConstants.CANCEL_ID, "&Cancel", true); //$NON-NLS-1$
-        createButton(parent, IDialogConstants.OK_ID, "&Ok", true); //$NON-NLS-1$
-    }
-
-    @Override
-    protected void okPressed() {
-
-        fIsOverride = fOverwriteButton.getSelection();
-
-        if (fIsOverride) {
-            // new name is old name
-            fNewTraceName = fTraceName;
-        } else {
-            fNewTraceName = fNewTraceNameText.getText();
-        }
-
-        // Check for invalid names
-        if (!fNewTraceName.matches("^[a-zA-Z0-9\\-\\_]{1,}$")) { //$NON-NLS-1$
-            MessageDialog.openError(getShell(),
-                    Messages.TraceControl_ImportDialogConfirmationTitle,
-                    Messages.TraceControl_InvalidTraceNameError + " (" + fNewTraceName + ") \n");  //$NON-NLS-1$ //$NON-NLS-2$
-            return;
-        }
-
-        // validation successful -> call super.okPressed()
-        super.okPressed();
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/ImportDialog.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/ImportDialog.java
deleted file mode 100644 (file)
index 9562d06..0000000
+++ /dev/null
@@ -1,509 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2015 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Bernd Hufmann - Added handling of streamed traces
- *   Marc-Andre Laperle - Use common method to get opened tmf projects
- *   Markus Schorn - Bug 448058: Use org.eclipse.remote in favor of RSE
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.core.filesystem.EFS;
-import org.eclipse.core.filesystem.IFileInfo;
-import org.eclipse.core.filesystem.IFileStore;
-import org.eclipse.core.resources.IFolder;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.core.runtime.NullProgressMonitor;
-import org.eclipse.core.runtime.Path;
-import org.eclipse.jface.dialogs.Dialog;
-import org.eclipse.jface.dialogs.IDialogConstants;
-import org.eclipse.jface.dialogs.MessageDialog;
-import org.eclipse.jface.viewers.CheckStateChangedEvent;
-import org.eclipse.jface.viewers.CheckboxTreeViewer;
-import org.eclipse.jface.viewers.ICheckStateListener;
-import org.eclipse.jface.viewers.ITreeContentProvider;
-import org.eclipse.jface.viewers.LabelProvider;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.jface.window.Window;
-import org.eclipse.remote.core.IRemoteFileService;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.custom.CCombo;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.graphics.Point;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Group;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.swt.widgets.Text;
-import org.eclipse.swt.widgets.Tree;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
-import org.eclipse.tracecompass.tmf.remote.core.proxy.RemoteSystemProxy;
-import org.eclipse.tracecompass.tmf.ui.project.model.TmfTracesFolder;
-import org.eclipse.tracecompass.tmf.ui.project.model.TraceUtils;
-import org.eclipse.ui.ISharedImages;
-import org.eclipse.ui.PlatformUI;
-
-/**
- * <p>
- * Dialog box for collecting trace import information.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class ImportDialog extends Dialog implements IImportDialog {
-
-    // ------------------------------------------------------------------------
-    // Constants
-    // ------------------------------------------------------------------------
-    /** The icon file for this dialog box. */
-    public static final String IMPORT_ICON_FILE = "icons/elcl16/import_trace.gif"; //$NON-NLS-1$
-
-    /** Parent directory for UST traces */
-    public static final String UST_PARENT_DIRECTORY = "ust"; //$NON-NLS-1$
-
-    /** Name of metadata file of trace */
-    public static final String METADATA_FILE_NAME = "metadata"; //$NON-NLS-1$
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-    /**
-     * The dialog composite.
-     */
-    private Composite fDialogComposite = null;
-    /**
-     * The checkbox tree viewer for selecting available traces
-     */
-    private CheckboxTreeViewer fFolderViewer;
-    /**
-     * The combo box for selecting a project.
-     */
-    private CCombo fCombo;
-    /**
-     * The overwrite button
-     */
-    private Button fOverwriteButton;
-    /**
-     * List of available LTTng 2.0 projects
-     */
-    private List<IProject> fProjects;
-    /**
-     * The parent where the new node should be added.
-     */
-    private TraceSessionComponent fSession = null;
-    /**
-     * The name of the default project name
-     */
-    private String fDefaultProjectName = null;
-    /**
-     * List of traces to import
-     */
-    private final List<ImportFileInfo> fTraces = new ArrayList<>();
-    /**
-     * Selection index in project combo box.
-     */
-    private int fProjectIndex;
-    /**
-     * Flag to indicate that something went wrong when creating the dialog box.
-     */
-    private boolean fIsError = false;
-    /**
-     * Children of the remote folder (can be null)
-     */
-    private Object[] fFolderChildren = null;
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-    /**
-     * Constructor
-     *
-     * @param shell
-     *            - a shell for the display of the dialog
-     */
-    public ImportDialog(Shell shell) {
-        super(shell);
-        setShellStyle(SWT.RESIZE | getShellStyle());
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    @Override
-    public List<ImportFileInfo> getTracePathes() {
-        List<ImportFileInfo> retList = new ArrayList<>();
-        retList.addAll(fTraces);
-        return retList;
-    }
-
-    @Override
-    public IProject getProject() {
-        return fProjects.get(fProjectIndex);
-    }
-
-    @Override
-    public void setSession(TraceSessionComponent session) {
-        fSession = session;
-    }
-
-    @Override
-    public void setDefaultProject(String defaultProject) {
-        fDefaultProjectName = defaultProject;
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    protected void configureShell(Shell newShell) {
-        super.configureShell(newShell);
-        newShell.setText(Messages.TraceControl_ImportDialogTitle);
-        newShell.setImage(Activator.getDefault().loadIcon(IMPORT_ICON_FILE));
-    }
-
-    @Override
-    protected Control createDialogArea(Composite parent) {
-
-        // Main dialog panel
-        fDialogComposite = new Composite(parent, SWT.NONE);
-        GridLayout layout = new GridLayout(1, true);
-        fDialogComposite.setLayout(layout);
-        fDialogComposite.setLayoutData(new GridData(GridData.FILL_BOTH));
-
-        try {
-            createRemoteComposite();
-        } catch (CoreException e) {
-            createErrorComposite(parent, e.fillInStackTrace());
-            return fDialogComposite;
-        }
-        return fDialogComposite;
-    }
-
-    @Override
-    protected void createButtonsForButtonBar(Composite parent) {
-        Button selectAllButton = createButton(parent, IDialogConstants.SELECT_ALL_ID, Messages.TraceControl_ImportDialog_SelectAll, true);
-        selectAllButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                setFolderChildrenChecked(true);
-            }
-        });
-
-        Button deselectAllButton = createButton(parent, IDialogConstants.DESELECT_ALL_ID, Messages.TraceControl_ImportDialog_DeselectAll, true);
-        deselectAllButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                setFolderChildrenChecked(false);
-            }
-        });
-        createButton(parent, IDialogConstants.CANCEL_ID, IDialogConstants.CANCEL_LABEL, true);
-        createButton(parent, IDialogConstants.OK_ID, IDialogConstants.OK_LABEL, true);
-        updateOKButtonEnablement();
-    }
-
-    @Override
-    protected void okPressed() {
-        if (!fIsError) {
-
-            // Validate input data
-            fTraces.clear();
-
-            fProjectIndex = fCombo.getSelectionIndex();
-
-            if (fProjectIndex < 0) {
-                MessageDialog.openError(getShell(),
-                        Messages.TraceControl_ImportDialogTitle,
-                        Messages.TraceControl_ImportDialogNoProjectSelectedError);
-                return;
-            }
-
-            IProject project = fProjects.get(fProjectIndex);
-            IFolder traceFolder = project.getFolder(TmfTracesFolder.TRACES_FOLDER_NAME);
-
-            if (!traceFolder.exists()) {
-                // Invalid LTTng 2.0 project
-                MessageDialog.openError(getShell(),
-                        Messages.TraceControl_ImportDialogTitle,
-                        Messages.TraceControl_ImportDialogInvalidTracingProject + " (" + TmfTracesFolder.TRACES_FOLDER_NAME + ")"); //$NON-NLS-1$//$NON-NLS-2$
-                return;
-            }
-
-            boolean overwriteAll = fOverwriteButton.getSelection();
-
-            Object[] checked = fFolderViewer.getCheckedElements();
-            for (int i = 0; i < checked.length; i++) {
-                IFileStore file = (IFileStore) checked[i];
-                if (!file.fetchInfo().isDirectory() && file.getName().equals(METADATA_FILE_NAME)) {
-                    IFileStore trace = file.getParent();
-                    IFileStore parent = trace.getParent();
-
-                    String path = fSession.isSnapshotSession() ? fSession.getSnapshotInfo().getSnapshotPath() : fSession.getSessionPath();
-                    path = getUnifiedPath(path);
-                    IPath sessionParentPath = new Path(path).removeLastSegments(1);
-                    IPath traceParentPath = new Path(parent.toURI().getPath());
-
-                    IPath relativeTracePath = traceParentPath.makeRelativeTo(sessionParentPath);
-
-                    IFolder destinationFolder = traceFolder.getFolder(new Path(relativeTracePath.toOSString()));
-
-                    ImportFileInfo info = new ImportFileInfo(trace, trace.getName(), destinationFolder, overwriteAll);
-                    IFolder folder = destinationFolder.getFolder(trace.getName());
-
-                    // Verify if trace directory already exists (and not
-                    // overwrite)
-                    if (folder.exists() && !overwriteAll) {
-
-                        // Ask user for overwrite or new name
-                        IImportConfirmationDialog conf = TraceControlDialogFactory.getInstance().getImportConfirmationDialog();
-                        conf.setTraceName(trace.getName());
-
-                        // Don't add trace to list if dialog was cancelled.
-                        if (conf.open() == Window.OK) {
-                            info.setOverwrite(conf.isOverwrite());
-                            if (!conf.isOverwrite()) {
-                                info.setLocalTraceName(conf.getNewTraceName());
-                            }
-                            fTraces.add(info);
-                        }
-                    } else {
-                        fTraces.add(info);
-                    }
-                }
-            }
-
-            if (fTraces.isEmpty()) {
-                MessageDialog.openError(getShell(),
-                        Messages.TraceControl_ImportDialogTitle,
-                        Messages.TraceControl_ImportDialogNoTraceSelectedError);
-                return;
-            }
-        }
-
-        // validation successful -> call super.okPressed()
-        super.okPressed();
-    }
-
-    // ------------------------------------------------------------------------
-    // Helper methods and classes
-    // ------------------------------------------------------------------------
-
-    private final class FolderCheckStateListener implements ICheckStateListener {
-        @Override
-        public void checkStateChanged(CheckStateChangedEvent event) {
-            Object elem = event.getElement();
-            if (elem instanceof IFileStore) {
-                IFileStore element = (IFileStore) elem;
-                IFileInfo info = element.fetchInfo();
-                if (!info.isDirectory()) {
-                    // A trick to keep selection of a file in sync with the
-                    // directory
-                    boolean p = fFolderViewer.getChecked((element.getParent()));
-                    fFolderViewer.setChecked(element, p);
-                } else {
-                    fFolderViewer.setSubtreeChecked(event.getElement(), event.getChecked());
-                    if (!event.getChecked()) {
-                        fFolderViewer.setChecked(element.getParent(), false);
-                    }
-                }
-                updateOKButtonEnablement();
-            }
-        }
-    }
-
-    /**
-     * Helper class for the contents of a folder in a tracing project
-     *
-     * @author Bernd Hufmann
-     */
-    public static class FolderContentProvider implements ITreeContentProvider {
-        @Override
-        public Object[] getChildren(Object o) {
-            try {
-                IFileStore store = (IFileStore) o;
-                if (store.fetchInfo().isDirectory()) {
-                    return store.childStores(EFS.NONE, new NullProgressMonitor());
-                }
-            } catch (CoreException e) {
-                Activator.getDefault().logError(e.getMessage(), e);
-            }
-            return new Object[0];
-        }
-
-        @Override
-        public Object getParent(Object element) {
-            return ((IFileStore) element).getParent();
-        }
-
-        @Override
-        public void dispose() {
-        }
-
-        @Override
-        public void inputChanged(Viewer viewer, Object oldInput, Object newInput) {
-        }
-
-        @Override
-        public Object[] getElements(Object inputElement) {
-            return getChildren(inputElement);
-        }
-
-        @Override
-        public boolean hasChildren(Object element) {
-            return ((IFileStore) element).fetchInfo().isDirectory();
-        }
-    }
-
-    /**
-     * Creates a dialog composite with an error message which can be used when
-     * an exception occurred during creation time of the dialog box.
-     *
-     * @param parent
-     *            - a parent composite
-     * @param e
-     *            - a error causing exception
-     */
-    private void createErrorComposite(Composite parent, Throwable e) {
-        fIsError = true;
-        fDialogComposite.dispose();
-
-        fDialogComposite = new Composite(parent, SWT.NONE);
-        GridLayout layout = new GridLayout(1, true);
-        fDialogComposite.setLayout(layout);
-        fDialogComposite.setLayoutData(new GridData(GridData.FILL_BOTH));
-
-        Text errorText = new Text(fDialogComposite, SWT.MULTI);
-        StringBuffer error = new StringBuffer();
-        error.append(Messages.TraceControl_ImportDialogCreationError);
-        error.append(System.getProperty("line.separator")); //$NON-NLS-1$
-        error.append(System.getProperty("line.separator")); //$NON-NLS-1$
-        error.append(e.toString());
-        errorText.setText(error.toString());
-        errorText.setLayoutData(new GridData(GridData.FILL_BOTH));
-    }
-
-    private void createRemoteComposite() throws CoreException {
-        Group contextGroup = new Group(fDialogComposite, SWT.SHADOW_NONE);
-        contextGroup.setText(Messages.TraceControl_ImportDialogTracesGroupName);
-        GridLayout layout = new GridLayout(1, true);
-        contextGroup.setLayout(layout);
-        contextGroup.setLayoutData(new GridData(GridData.FILL_BOTH));
-
-        RemoteSystemProxy proxy = fSession.getTargetNode().getRemoteSystemProxy();
-
-        IRemoteFileService fsss = proxy.getRemoteConnection().getService(IRemoteFileService.class);
-
-        if (fsss == null) {
-            return;
-        }
-
-        final String path = fSession.isSnapshotSession() ? fSession.getSnapshotInfo().getSnapshotPath() : fSession.getSessionPath();
-        final IFileStore remoteFolder = fsss.getResource(path);
-
-        fFolderViewer = new CheckboxTreeViewer(contextGroup, SWT.BORDER | SWT.V_SCROLL | SWT.H_SCROLL);
-        GridData data = new GridData(GridData.FILL_BOTH);
-        Tree tree = fFolderViewer.getTree();
-        tree.setLayoutData(data);
-        tree.setFont(fDialogComposite.getFont());
-        tree.setToolTipText(Messages.TraceControl_ImportDialogTracesTooltip);
-
-        fFolderViewer.setContentProvider(new FolderContentProvider());
-        fFolderViewer.setLabelProvider(new LabelProvider() {
-            @Override
-            public String getText(Object element) {
-                return ((IFileStore) element).getName();
-            }
-
-            @Override
-            public Image getImage(Object element) {
-                if (((IFileStore) element).fetchInfo().isDirectory()) {
-                    return PlatformUI.getWorkbench().getSharedImages().getImage(ISharedImages.IMG_OBJ_FOLDER);
-                }
-                return PlatformUI.getWorkbench().getSharedImages().getImage(ISharedImages.IMG_OBJ_FILE);
-            }
-        });
-
-        fFolderViewer.addCheckStateListener(new FolderCheckStateListener());
-        fFolderViewer.setInput(remoteFolder);
-
-        fFolderChildren = remoteFolder.childStores(EFS.NONE, new NullProgressMonitor());
-        // children can be null if there the path doesn't exist. This happens
-        // when a trace
-        // session hadn't been started and no output was created.
-        setFolderChildrenChecked(true);
-
-        Group projectGroup = new Group(fDialogComposite, SWT.SHADOW_NONE);
-        projectGroup.setText(Messages.TraceControl_ImportDialogProjectsGroupName);
-        layout = new GridLayout(1, true);
-        projectGroup.setLayout(layout);
-        projectGroup.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-
-        fProjects = new ArrayList<>();
-        List<String> projectNames = new ArrayList<>();
-
-        for (IProject project : TraceUtils.getOpenedTmfProjects()) {
-            fProjects.add(project);
-            projectNames.add(project.getName());
-        }
-
-        fCombo = new CCombo(projectGroup, SWT.READ_ONLY);
-        fCombo.setToolTipText(Messages.TraceControl_ImportDialogProjectsTooltip);
-        fCombo.setLayoutData(new GridData(GridData.FILL, GridData.CENTER, true, false, 1, 1));
-        fCombo.setItems(projectNames.toArray(new String[projectNames.size()]));
-
-        if (fDefaultProjectName != null) {
-            int select = projectNames.indexOf(fDefaultProjectName);
-            fCombo.select(select);
-        }
-
-        Group overrideGroup = new Group(fDialogComposite, SWT.SHADOW_NONE);
-        layout = new GridLayout(1, true);
-        overrideGroup.setLayout(layout);
-        overrideGroup.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-
-        fOverwriteButton = new Button(overrideGroup, SWT.CHECK);
-        fOverwriteButton.setText(Messages.TraceControl_ImportDialogOverwriteButtonText);
-        getShell().setMinimumSize(new Point(500, 400));
-    }
-
-    private void setFolderChildrenChecked(boolean isChecked) {
-        if (fFolderChildren != null) {
-            for (Object child : fFolderChildren) {
-                fFolderViewer.setSubtreeChecked(child, isChecked);
-            }
-        }
-        updateOKButtonEnablement();
-    }
-
-    private void updateOKButtonEnablement() {
-        Object[] checked = fFolderViewer.getCheckedElements();
-        Button okButton = getButton(IDialogConstants.OK_ID);
-        if (okButton != null) {
-            okButton.setEnabled(checked.length > 0);
-        }
-    }
-
-    private static String getUnifiedPath(String path) {
-        // Use Path class to remove unnecessary slashes
-        return new Path(path).removeTrailingSeparator().toString();
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/ImportFileInfo.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/ImportFileInfo.java
deleted file mode 100644 (file)
index 5e586d1..0000000
+++ /dev/null
@@ -1,128 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Markus Schorn - Bug 448058: Use org.eclipse.remote in favor of RSE
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
-
-import org.eclipse.core.filesystem.IFileStore;
-import org.eclipse.core.resources.IFolder;
-
-/**
- * <p>
- * Helper class for storing information about a remote file to import.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class ImportFileInfo {
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-    /**
-     * Remote file reference
-     */
-    private IFileStore fRemoteFile;
-    /**
-     * Local Trace Name
-     */
-    private String fLocalTraceName;
-    /**
-     * Global overwrite flag
-     */
-    private boolean fIsOverwrite;
-    /**
-     * Destination folder to import the trace to (full workspace path)
-     */
-    private IFolder fDestinationFolder;
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-    /**
-     * Standard constructor
-     *
-     * @param file
-     *            A remote file reference
-     * @param traceName
-     *            A trace name
-     * @param destinationFolder
-     *            The destination folder (full workspace path)
-     * @param isOverwrite
-     *            global overwrite flag
-     */
-    public ImportFileInfo(IFileStore file, String traceName, IFolder destinationFolder, boolean isOverwrite) {
-        fRemoteFile = file;
-        fLocalTraceName = traceName;
-        fDestinationFolder = destinationFolder;
-        fIsOverwrite = isOverwrite;
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-    /**
-     * @return name of traces after importing
-     */
-    public String getLocalTraceName() {
-        return fLocalTraceName;
-    }
-
-    /**
-     * Sets the local trace name
-     *
-     * @param importTraceName
-     *            - local name of trace to set (name after importing)
-     */
-    public void setLocalTraceName(String importTraceName) {
-        this.fLocalTraceName = importTraceName;
-    }
-    /**
-     * @return true if local trace should be overwritten if a trace with the same name already exists.
-     */
-    public boolean isOverwrite() {
-        return fIsOverwrite;
-    }
-    /**
-     * Sets the overwrite flag.
-     * @param isOverwrite If the Overwrite checkbox is checked or not
-     */
-    public void setOverwrite(boolean isOverwrite) {
-        this.fIsOverwrite = isOverwrite;
-    }
-
-    /**
-     * @return the remote file implementation.
-     */
-    public IFileStore getImportFile() {
-        return fRemoteFile;
-    }
-
-    /**
-     * Sets the remote file implementation
-     *
-     * @param remoteFile
-     *            The remote file implementation.
-     */
-    public void setRemoteFile(IFileStore remoteFile) {
-        fRemoteFile = remoteFile;
-    }
-
-    /**
-     * Returns the destination folder to import the trace to (full workspace path).
-     *
-     * @return destination folder
-     */
-    public IFolder getDestinationFolder() {
-        return fDestinationFolder;
-    }
-}
-
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/NewConnectionDialog.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/NewConnectionDialog.java
deleted file mode 100644 (file)
index 1f30749..0000000
+++ /dev/null
@@ -1,399 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2015 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Markus Schorn - Bug 448058: Use org.eclipse.remote in favor of RSE
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
-
-import static java.text.MessageFormat.format;
-
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.Comparator;
-import java.util.List;
-
-import org.eclipse.jface.dialogs.Dialog;
-import org.eclipse.jface.dialogs.IDialogConstants;
-import org.eclipse.jface.viewers.DoubleClickEvent;
-import org.eclipse.jface.viewers.IDoubleClickListener;
-import org.eclipse.jface.viewers.ISelectionChangedListener;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.viewers.ITreeContentProvider;
-import org.eclipse.jface.viewers.LabelProvider;
-import org.eclipse.jface.viewers.SelectionChangedEvent;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.jface.viewers.TreeViewer;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.remote.core.IRemoteConnection;
-import org.eclipse.remote.core.IRemoteConnectionHostService;
-import org.eclipse.remote.core.IRemoteConnectionType;
-import org.eclipse.remote.core.IRemoteConnectionWorkingCopy;
-import org.eclipse.remote.core.IRemoteServicesManager;
-import org.eclipse.remote.core.exception.RemoteConnectionException;
-import org.eclipse.remote.ui.IRemoteUIConnectionService;
-import org.eclipse.remote.ui.IRemoteUIConnectionWizard;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
-import org.eclipse.tracecompass.tmf.remote.core.proxy.TmfRemoteConnectionFactory;
-
-/**
- * <p>
- * Dialog box for connection information.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class NewConnectionDialog extends Dialog implements INewConnectionDialog {
-
-    private static final int BUTTONS_NUMBER_OF_COLUMNS = 3;
-    private static final int LABEL_WIDTH_CHARS = 4;
-    private static final int CONNECTIONTREE_HEIGHT_CHARS = 10;
-    private static final int CONNECTIONTREE_WIDTH_CHARS = 40;
-    // ------------------------------------------------------------------------
-    // Constants
-    // ------------------------------------------------------------------------
-    private static final String TARGET_NEW_CONNECTION_ICON_FILE = "icons/elcl16/target_add.gif"; //$NON-NLS-1$
-    private static final String PROVIDERS_ICON_FILE = "icons/obj16/providers.gif"; //$NON-NLS-1$
-    private static final String CONNECTION_ICON_FILE = "icons/obj16/target_connected.gif"; //$NON-NLS-1$
-
-    private final class ConnectionTreeLabelProvider extends LabelProvider {
-        @Override
-        public String getText(Object element) {
-            if (element instanceof IRemoteConnection) {
-                IRemoteConnection rc = (IRemoteConnection) element;
-                return getConnectionLabel(rc);
-            } else if (element instanceof IRemoteConnectionType) {
-                IRemoteConnectionType rs = (IRemoteConnectionType) element;
-                return rs.getName();
-            }
-            return Messages.TraceControl_UnknownNode;
-        }
-
-        @Override
-        public Image getImage(Object element) {
-            if (element instanceof IRemoteConnection) {
-                return Activator.getDefault().loadIcon(CONNECTION_ICON_FILE);
-            }
-            return Activator.getDefault().loadIcon(PROVIDERS_ICON_FILE);
-        }
-    }
-
-    private static final class ConnectionContentProvider implements ITreeContentProvider {
-        private static final Object[] NO_CHILDREN = {};
-
-        @Override
-        public void inputChanged(Viewer viewer, Object oldInput, Object newInput) {
-        }
-
-        @Override
-        public void dispose() {
-        }
-
-        @Override
-        public Object[] getElements(Object inputElement) {
-            List<Object> children = new ArrayList<>();
-            IRemoteServicesManager manager = TmfRemoteConnectionFactory.getService(IRemoteServicesManager.class);
-            if (manager != null) {
-                children.addAll(manager.getAllConnectionTypes());
-            }
-            return children.toArray();
-        }
-
-        @Override
-        public Object[] getChildren(Object parentElement) {
-            if (parentElement instanceof IRemoteConnectionType) {
-                return getConnections((IRemoteConnectionType) parentElement);
-            }
-            return NO_CHILDREN;
-        }
-
-        private static IRemoteConnection[] getConnections(IRemoteConnectionType parentElement) {
-            List<IRemoteConnection> connectionList = parentElement.getConnections();
-            IRemoteConnection[] result = connectionList.toArray(new IRemoteConnection[connectionList.size()]);
-            Arrays.sort(result, new Comparator<IRemoteConnection>() {
-                @Override
-                public int compare(IRemoteConnection o1, IRemoteConnection o2) {
-                    return getConnectionLabel(o1).compareTo(getConnectionLabel(o2));
-                }
-            });
-            return result;
-        }
-
-        @Override
-        public Object getParent(Object element) {
-            if (element instanceof IRemoteConnection) {
-                return ((IRemoteConnection) element).getConnectionType();
-            }
-            return null;
-        }
-
-        @Override
-        public boolean hasChildren(Object element) {
-            return getChildren(element).length > 0;
-        }
-
-    }
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-    /**
-     * The host combo box.
-     */
-    private TreeViewer fConnectionTree = null;
-    /**
-     * The push button for creating a new connection.
-     */
-    private Button fNewButton = null;
-    /**
-     * The push button for editing a connection.
-     */
-    private Button fEditButton = null;
-
-    private IRemoteConnection fConnection;
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-    /**
-     * Constructor
-     *
-     * @param shell
-     *            The shell
-     */
-    public NewConnectionDialog(Shell shell) {
-        super(shell);
-        setShellStyle(SWT.RESIZE | getShellStyle());
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    protected void configureShell(Shell newShell) {
-        super.configureShell(newShell);
-        newShell.setText(Messages.TraceControl_NewDialogTitle);
-        newShell.setImage(Activator.getDefault().loadIcon(TARGET_NEW_CONNECTION_ICON_FILE));
-    }
-
-    @Override
-    protected Control createContents(Composite parent) {
-        Control result = super.createContents(parent);
-        fConnectionTree.setAutoExpandLevel(2);
-        fConnectionTree.setInput(this);
-
-        IRemoteServicesManager manager = TmfRemoteConnectionFactory.getService(IRemoteServicesManager.class);
-        if (manager == null) {
-            return result;
-        }
-        List<IRemoteConnectionType> providers = manager.getAllConnectionTypes();
-        if (!providers.isEmpty()) {
-            IRemoteConnectionType provider = providers.get(0);
-            IRemoteConnection[] connections = ConnectionContentProvider.getConnections(provider);
-            if (connections.length > 0) {
-                fConnectionTree.setSelection(new StructuredSelection(connections[0]));
-            } else {
-                fConnectionTree.setSelection(new StructuredSelection(provider));
-            }
-        } else {
-            onSelectionChanged();
-        }
-        return result;
-    }
-
-    @Override
-    protected Control createDialogArea(Composite parent) {
-        // Main dialog panel
-        GridData gd;
-        Composite dialogComposite = new Composite(parent, SWT.NONE);
-        GridLayout layout = new GridLayout(1, true);
-        dialogComposite.setLayout(layout);
-        dialogComposite.setLayoutData(new GridData(GridData.FILL_BOTH));
-
-        Label label = new Label(dialogComposite, SWT.NONE);
-        label.setText(Messages.TraceControl_NewNodeExistingConnectionGroupName);
-        gd = new GridData();
-        label.setLayoutData(gd );
-        gd.widthHint = label.computeSize(-1, -1).x + convertWidthInCharsToPixels(LABEL_WIDTH_CHARS);
-        // Existing connections group
-        fConnectionTree = new TreeViewer(dialogComposite);
-        gd = new GridData(SWT.FILL, SWT.FILL, true, true);
-        fConnectionTree.getTree().setLayoutData(gd);
-        gd.widthHint = convertWidthInCharsToPixels(CONNECTIONTREE_WIDTH_CHARS);
-        gd.heightHint = convertHeightInCharsToPixels(CONNECTIONTREE_HEIGHT_CHARS);
-        fConnectionTree.setLabelProvider(new ConnectionTreeLabelProvider());
-        fConnectionTree.setContentProvider(new ConnectionContentProvider());
-        fConnectionTree.addSelectionChangedListener(new ISelectionChangedListener() {
-            @Override
-            public void selectionChanged(SelectionChangedEvent event) {
-                onSelectionChanged();
-            }
-        });
-        fConnectionTree.addDoubleClickListener(new IDoubleClickListener() {
-            @Override
-            public void doubleClick(DoubleClickEvent event) {
-                okPressed();
-            }
-        });
-
-        Composite buttons = new Composite(dialogComposite, SWT.NONE);
-        layout = new GridLayout(BUTTONS_NUMBER_OF_COLUMNS, true);
-        layout.marginHeight = 0;
-        layout.marginWidth = 0;
-        buttons.setLayout(layout);
-        buttons.setLayoutData(new GridData(SWT.END, SWT.CENTER, false, false));
-
-        new Label(buttons, SWT.NONE);
-
-        fEditButton = new Button(buttons, SWT.PUSH);
-        fEditButton.setText(Messages.TraceControl_NewNodeEditButtonName);
-        setButtonLayoutData(fEditButton);
-        fEditButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                onEditConnection();
-            }
-        });
-
-        fNewButton = new Button(buttons, SWT.PUSH);
-        fNewButton.setText(Messages.TraceControl_NewNodeCreateButtonText);
-        setButtonLayoutData(fNewButton);
-        fNewButton.addSelectionListener(new SelectionAdapter() {
-            @Override
-            public void widgetSelected(SelectionEvent e) {
-                onNewConnection();
-            }
-        });
-
-        return dialogComposite;
-    }
-
-    private void onSelectionChanged() {
-        setConnection();
-        getButton(OK).setEnabled(fConnection != null);
-        fEditButton.setEnabled(canEdit(fConnection));
-        fNewButton.setEnabled(getServiceForCreation() != null);
-    }
-
-    private IRemoteConnectionType getServiceForCreation() {
-        Object o = ((IStructuredSelection) fConnectionTree.getSelection()).getFirstElement();
-        IRemoteConnectionType result = null;
-        if (o instanceof IRemoteConnectionType) {
-            result = (IRemoteConnectionType) o;
-        } else if (o instanceof IRemoteConnection) {
-            result = ((IRemoteConnection) o).getConnectionType();
-        } else {
-            return null;
-        }
-
-        if (!result.canAdd()) {
-            return null;
-        }
-
-        return result;
-    }
-
-    private static boolean canEdit(IRemoteConnection conn) {
-        if (conn == null) {
-            return false;
-        }
-        return conn.getConnectionType().canEdit();
-    }
-
-    private void onNewConnection() {
-        IRemoteConnectionType rs = getServiceForCreation();
-        if (rs != null) {
-            IRemoteUIConnectionService uiService = rs.getService(IRemoteUIConnectionService.class);
-            if (uiService != null) {
-                IRemoteUIConnectionWizard wiz = uiService.getConnectionWizard(getShell());
-                if (wiz != null) {
-                    IRemoteConnectionWorkingCopy wc = wiz.open();
-                    if (wc != null) {
-                        IRemoteConnection conn = null;
-                        try {
-                            conn = wc.save();
-                        } catch (RemoteConnectionException e) {
-                            Activator.getDefault().logWarning("Connection configuration could not be saved for " + fConnection.getName() , e); //$NON-NLS-1$
-                        }
-                        if (conn != null) {
-                            fConnectionTree.refresh();
-                            fConnectionTree.setSelection(new StructuredSelection(conn), true);
-                        }
-                    }
-                }
-            }
-        }
-    }
-
-    private void onEditConnection() {
-        setConnection();
-        if (fConnection != null) {
-            IRemoteUIConnectionService ui = fConnection.getConnectionType().getService(IRemoteUIConnectionService.class);
-            if (ui != null) {
-                    IRemoteUIConnectionWizard wiz = ui.getConnectionWizard(getShell());
-                    wiz.setConnection(fConnection.getWorkingCopy());
-                    IRemoteConnectionWorkingCopy result = wiz.open();
-                    if (result != null) {
-                        try {
-                            result.save();
-                        } catch (RemoteConnectionException e) {
-                            Activator.getDefault().logWarning("Connection configuration could not be saved for " + fConnection.getName() , e); //$NON-NLS-1$
-                        }
-                        fConnectionTree.refresh();
-                    }
-            }
-        }
-    }
-
-    @Override
-    protected void createButtonsForButtonBar(Composite parent) {
-        createButton(parent, IDialogConstants.CANCEL_ID, "&Cancel", true); //$NON-NLS-1$
-        createButton(parent, IDialogConstants.OK_ID, "&Ok", true); //$NON-NLS-1$
-    }
-
-    @Override
-    protected void okPressed() {
-        setConnection();
-        if (fConnection != null) {
-            super.okPressed();
-        }
-    }
-
-    private void setConnection() {
-        Object o = ((IStructuredSelection) fConnectionTree.getSelection()).getFirstElement();
-        fConnection = o instanceof IRemoteConnection ? (IRemoteConnection) o : null;
-    }
-
-    @Override
-    public IRemoteConnection getConnection() {
-        return fConnection;
-    }
-
-    private static String getConnectionLabel(IRemoteConnection rc) {
-        StringBuffer label = new StringBuffer();
-        label.append(rc.getName());
-        if (rc.hasService(IRemoteConnectionHostService.class)) {
-            label.append(format(" [{0}]", rc.getService(IRemoteConnectionHostService.class).getHostname())); //$NON-NLS-1$
-        }
-        return label.toString();
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/OpenCommandScriptDialog.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/OpenCommandScriptDialog.java
deleted file mode 100644 (file)
index bd648f5..0000000
+++ /dev/null
@@ -1,269 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
-
-import java.io.IOException;
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.List;
-
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.jdt.annotation.NonNull;
-import org.eclipse.jface.dialogs.Dialog;
-import org.eclipse.jface.dialogs.ErrorDialog;
-import org.eclipse.jface.dialogs.IDialogConstants;
-import org.eclipse.jface.dialogs.IDialogSettings;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.graphics.Point;
-import org.eclipse.swt.graphics.Rectangle;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Combo;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Event;
-import org.eclipse.swt.widgets.FileDialog;
-import org.eclipse.swt.widgets.Group;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Listener;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
-import org.eclipse.tracecompass.tmf.core.io.BufferedRandomAccessFile;
-
-import com.google.common.collect.ImmutableList;
-
-/**
- * <p>
- * Dialog box for selecting a command script. It parses the script and
- * provides a list of shell commands to be executed.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class OpenCommandScriptDialog extends Dialog implements ISelectCommandScriptDialog {
-
-    // ------------------------------------------------------------------------
-    // Constants
-    // ------------------------------------------------------------------------
-    /**
-     * The icon file for this dialog box.
-     */
-    public static final String CREATE_SESSION_ICON_FILE = "icons/elcl16/add_button.gif"; //$NON-NLS-1$
-
-    // Dialog settings constants
-    private static final String DIALOG_SETTINGS_SECTION = "OpenCommandScriptDialog"; //$NON-NLS-1$
-    private static final String FILE_NAME_ID = "STORE_FILE_NAME_ID"; //$NON-NLS-1$
-    private static final int COMBO_HISTORY_LENGTH = 5;
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-
-    // Dialog attributes
-    private Control fControl = null;
-    private Composite fDialogComposite = null;
-    private Button fBrowseButton;
-    private Label fFileNameLabel = null;
-    private Combo fFileNameCombo = null;
-
-    // Output list of commands
-    private List<String> fCommands = null;
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-    /**
-     * Constructor
-     * @param shell - a shell for the display of the dialog
-     */
-    public OpenCommandScriptDialog(Shell shell) {
-        super(shell);
-        setShellStyle(SWT.RESIZE | getShellStyle());
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    @Override
-    @NonNull public List<String> getCommands() {
-        if (fCommands != null) {
-            return fCommands;
-        }
-        return new ArrayList<>();
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    protected Control createContents(Composite parent) {
-        fControl = super.createContents(parent);
-
-        /* set the shell minimum size */
-        Point clientArea = fControl.computeSize(SWT.DEFAULT, SWT.DEFAULT);
-        Rectangle trim = getShell().computeTrim(0, 0, clientArea.x, clientArea.y);
-        getShell().setMinimumSize(trim.width, trim.height);
-
-        return fControl;
-    }
-
-    @Override
-    protected void configureShell(Shell newShell) {
-        super.configureShell(newShell);
-        newShell.setText(Messages.TraceControl_ExecuteScriptDialogTitle);
-        newShell.setImage(Activator.getDefault().loadIcon(CREATE_SESSION_ICON_FILE));
-    }
-
-    @Override
-    protected Control createDialogArea(Composite parent) {
-
-        // Main dialog panel
-        fDialogComposite = new Composite(parent, SWT.NONE);
-        GridLayout layout = new GridLayout(1, true);
-        fDialogComposite.setLayout(layout);
-        fDialogComposite.setLayoutData(new GridData(GridData.FILL_BOTH));
-
-        Group sessionGroup = new Group(fDialogComposite, SWT.SHADOW_NONE);
-        sessionGroup.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
-        sessionGroup.setLayout(new GridLayout(6, true));
-
-        fFileNameLabel = new Label(sessionGroup, SWT.RIGHT);
-        fFileNameLabel.setText(Messages.TraceControl_ExecuteScriptSelectLabel);
-        fFileNameCombo = new Combo(sessionGroup, SWT.BORDER);
-
-        fBrowseButton = new Button(sessionGroup, SWT.PUSH);
-        fBrowseButton.setText(Messages.TraceControl_ExecuteScriptBrowseText);
-        fBrowseButton.addListener(SWT.Selection, new Listener() {
-            @Override
-            public void handleEvent(Event event) {
-                handleFilePathBrowseButtonPressed(SWT.OPEN);
-            }
-        });
-
-        // layout widgets
-        GridData data = new GridData(GridData.FILL_HORIZONTAL);
-        data.horizontalSpan = 1;
-        data.grabExcessHorizontalSpace = false;
-        fFileNameLabel.setLayoutData(data);
-
-        data = new GridData(GridData.FILL_HORIZONTAL);
-        data.horizontalSpan = 4;
-        fFileNameCombo.setLayoutData(data);
-
-        data = new GridData(GridData.FILL_HORIZONTAL);
-        data.horizontalSpan = 1;
-
-        // Initialize a empty list
-        fCommands = new ArrayList<>();
-
-        restoreWidgetValues();
-
-        return fDialogComposite;
-    }
-
-    private void restoreWidgetValues() {
-        IDialogSettings workbenchSettings = Activator.getDefault().getDialogSettings();
-        IDialogSettings settings = workbenchSettings.getSection(DIALOG_SETTINGS_SECTION);
-        if (settings == null) {
-            settings = workbenchSettings.addNewSection(DIALOG_SETTINGS_SECTION);
-        }
-        String[] fileNames = settings.getArray(FILE_NAME_ID);
-        if ((fileNames != null) && (fileNames.length != 0)) {
-            for (int i = 0; i < fileNames.length; i++) {
-                fFileNameCombo.add(fileNames[i]);
-            }
-        }
-    }
-
-    private void saveWidgetValues() {
-        IDialogSettings workbenchSettings = Activator.getDefault().getDialogSettings();
-        IDialogSettings settings = workbenchSettings.getSection(DIALOG_SETTINGS_SECTION);
-        if (settings != null) {
-            // update file names history
-            String[] fileNames = settings.getArray(FILE_NAME_ID);
-            if (fileNames == null) {
-                fileNames = new String[0];
-            }
-
-            fileNames = addToHistory(fileNames, fFileNameCombo.getText().trim());
-            settings.put(FILE_NAME_ID, fileNames);
-        }
-    }
-
-    /**
-     * Adds an entry to a history, while taking care of duplicate history items
-     * and excessively long histories.  The assumption is made that all histories
-     * should be of length <code>COMBO_HISTORY_LENGTH</code>.
-     *
-     * @param history the current history
-     * @param newEntry the entry to add to the history
-     */
-    private static String[] addToHistory(String[] history, String newEntry) {
-        List<String> list = new ArrayList<>(Arrays.asList(history));
-        list.remove(newEntry);
-        list.add(0, newEntry);
-
-        // since only one new item was added, we can be over the limit
-        // by at most one item
-        if (list.size() > COMBO_HISTORY_LENGTH) {
-            list.remove(COMBO_HISTORY_LENGTH);
-        }
-        String[] r = new String[list.size()];
-        list.toArray(r);
-        return r;
-    }
-
-    private void handleFilePathBrowseButtonPressed(int fileDialogStyle) {
-        FileDialog dialog = new FileDialog(getShell(), fileDialogStyle | SWT.SHEET);
-        dialog.setFilterExtensions(new String[] { "*.*", "*.*" }); //$NON-NLS-1$ //$NON-NLS-2$
-        dialog.setText(Messages.TraceControl_ExecuteScriptDialogTitle);
-        String selectedFileName = dialog.open();
-        if (selectedFileName != null) {
-            fFileNameCombo.setText(selectedFileName);
-        }
-    }
-
-    @Override
-    protected void createButtonsForButtonBar(Composite parent) {
-        createButton(parent, IDialogConstants.CANCEL_ID, IDialogConstants.CANCEL_LABEL, true);
-        createButton(parent, IDialogConstants.OK_ID, IDialogConstants.OK_LABEL, true);
-    }
-
-    @Override
-    protected void okPressed() {
-        // Validate input data
-        String sessionPath = fFileNameCombo.getText();
-
-        if (!"".equals(sessionPath)) { //$NON-NLS-1$
-
-            ImmutableList.Builder<String> builder = new ImmutableList.Builder<>();
-            try (BufferedRandomAccessFile rafile = new BufferedRandomAccessFile(sessionPath, "r")) { //$NON-NLS-1$
-                String line = rafile.getNextLine();
-                while (line != null) {
-                    builder.add(line);
-                    line = rafile.getNextLine();
-                }
-            } catch (IOException e) {
-                ErrorDialog.openError(getShell(), null, null, new Status(IStatus.ERROR, Activator.PLUGIN_ID, IStatus.ERROR, e.getLocalizedMessage(), e));
-                return;
-            }
-            saveWidgetValues();
-            fCommands = builder.build();
-            super.okPressed();
-        }
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/TraceControlDialogFactory.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/dialogs/TraceControlDialogFactory.java
deleted file mode 100644 (file)
index 78ec998..0000000
+++ /dev/null
@@ -1,282 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs;
-
-import org.eclipse.ui.PlatformUI;
-
-/**
- * <p>
- * Factory for generating dialog boxes. It allows to overwrite the dialog implementation.
- * Useful also for testing purposes.
- * </p>
- *
- * @author Bernd Hufmann
- *
- */
-public final class TraceControlDialogFactory {
-
-    // ------------------------------------------------------------------------
-    // Members
-    // ------------------------------------------------------------------------
-
-    /**
-     * The factory instance.
-     */
-    private static TraceControlDialogFactory fInstance;
-
-    /**
-     * The new connection dialog reference.
-     */
-    private INewConnectionDialog fNewConnectionDialog;
-
-    /**
-     * The enable channel dialog
-     */
-    private IEnableChannelDialog fEnableChannelDialog;
-
-    /**
-     * The create session dialog.
-     */
-    private ICreateSessionDialog fCreateSessionDialog;
-
-    /**
-     * The command script selection dialog.
-     */
-    private ISelectCommandScriptDialog fCommandScriptDialog;
-
-    /**
-     * The enable events dialog.
-     */
-    private IEnableEventsDialog fEnableEventsDialog;
-
-    /**
-     * The get event info dialog.
-     */
-    private IGetEventInfoDialog fGetEventInfoDialog;
-
-    /**
-     * The confirmation dialog implementation.
-     */
-    private IConfirmDialog fConfirmDialog;
-
-    /**
-     * The add context dialog implementation.
-     */
-    private IAddContextDialog fAddContextDialog;
-
-    /**
-     * The import dialog implementation.
-     */
-    private IImportDialog fImportDialog;
-
-    /**
-     * The import confirmation dialog.
-     */
-    private IImportConfirmationDialog fImportConfirmationDialog;
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-
-    /**
-     * Constructor for R4EUIDialogFactory.
-     */
-    private TraceControlDialogFactory() {
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    /**
-     * @return TraceControlDialogFactory instance
-     */
-    public static synchronized TraceControlDialogFactory getInstance() {
-        if (fInstance == null) {
-            fInstance = new TraceControlDialogFactory();
-        }
-        return fInstance;
-    }
-
-    /**
-     * @return new connection dialog
-     */
-    public INewConnectionDialog getNewConnectionDialog() {
-        if (fNewConnectionDialog == null) {
-            fNewConnectionDialog = new NewConnectionDialog(PlatformUI.getWorkbench().getActiveWorkbenchWindow().getShell());
-        }
-        return fNewConnectionDialog;
-    }
-
-    /**
-     * Sets a new connection dialog implementation.
-     * @param newConnectionDialog - new connection dialog implementation
-     */
-    public void setNewConnectionDialog(INewConnectionDialog newConnectionDialog) {
-        fNewConnectionDialog = newConnectionDialog;
-    }
-
-    /**
-     * @return enable channel dialog
-     */
-    public IEnableChannelDialog getEnableChannelDialog() {
-        if (fEnableChannelDialog == null) {
-            fEnableChannelDialog = new EnableChannelDialog(PlatformUI.getWorkbench().getActiveWorkbenchWindow().getShell());
-        }
-        return fEnableChannelDialog;
-    }
-
-    /**
-     * Sets a enable channel dialog implementation.
-     * @param createEnableDialog - a create channel dialog implementation
-     */
-    public void setEnableChannelDialog(IEnableChannelDialog createEnableDialog) {
-        fEnableChannelDialog = createEnableDialog;
-    }
-
-    /**
-     * @return create session dialog implementation
-     */
-    public ICreateSessionDialog getCreateSessionDialog() {
-        if (fCreateSessionDialog == null) {
-            fCreateSessionDialog = new CreateSessionDialog(PlatformUI.getWorkbench().getActiveWorkbenchWindow().getShell());
-        }
-        return fCreateSessionDialog;
-    }
-
-    /**
-     * @return command script selection dialog implementation
-     */
-    public ISelectCommandScriptDialog getCommandScriptDialog() {
-        if (fCommandScriptDialog == null) {
-            fCommandScriptDialog = new OpenCommandScriptDialog(PlatformUI.getWorkbench().getActiveWorkbenchWindow().getShell());
-        }
-        return fCommandScriptDialog;
-    }
-
-    /**
-     * Sets a create session dialog implementation.
-     * @param createSessionDialog - a create session implementation.
-     */
-    public void setCreateSessionDialog(ICreateSessionDialog createSessionDialog) {
-        fCreateSessionDialog = createSessionDialog;
-    }
-
-    /**
-     * @return enable events dialog implementation.
-     */
-    public IEnableEventsDialog getEnableEventsDialog() {
-        if (fEnableEventsDialog == null) {
-            fEnableEventsDialog = new EnableEventsDialog(PlatformUI.getWorkbench().getActiveWorkbenchWindow().getShell());
-        }
-        return fEnableEventsDialog;
-    }
-
-    /**
-     * Sets a enable events dialog implementation.
-     * @param enableEventsDialog - a enable events dialog implementation.
-     */
-    public void setEnableEventsDialog(IEnableEventsDialog enableEventsDialog) {
-        fEnableEventsDialog = enableEventsDialog;
-    }
-
-    /**
-     * @return get events info dialog implementation.
-     */
-    public IGetEventInfoDialog getGetEventInfoDialog() {
-        if (fGetEventInfoDialog == null) {
-            fGetEventInfoDialog = new GetEventInfoDialog(PlatformUI.getWorkbench().getActiveWorkbenchWindow().getShell());
-        }
-        return fGetEventInfoDialog;
-    }
-
-    /**
-     * Sets a get events info dialog implementation.
-     * @param getEventInfoDialog - a get events info dialog implementation
-     */
-    public void setGetEventInfoDialog(IGetEventInfoDialog getEventInfoDialog) {
-        fGetEventInfoDialog = getEventInfoDialog;
-    }
-
-    /**
-     * @return the confirmation dialog implementation
-     */
-    public IConfirmDialog getConfirmDialog() {
-        if (fConfirmDialog == null) {
-            fConfirmDialog = new ConfirmDialog();
-        }
-        return fConfirmDialog;
-    }
-
-    /**
-     * Sets the confirmation dialog implementation
-     * @param confirmDialog - a confirmation dialog implementation
-     */
-    public void setConfirmDialog(IConfirmDialog confirmDialog) {
-        fConfirmDialog = confirmDialog;
-    }
-
-    /**
-     * @return the add context dialog implementation
-     */
-    public IAddContextDialog getAddContextDialog() {
-        if (fAddContextDialog == null) {
-            fAddContextDialog = new AddContextDialog(PlatformUI.getWorkbench().getActiveWorkbenchWindow().getShell());
-        }
-        return fAddContextDialog;
-    }
-
-    /**
-     * Sets the add context dialog information
-     * @param addContextDialog - a add context dialog implementation
-     */
-    public void setAddContextDialog(IAddContextDialog addContextDialog) {
-        fAddContextDialog = addContextDialog;
-    }
-
-    /**
-     * @return the import dialog implementation
-     */
-    public IImportDialog getImportDialog() {
-        if (fImportDialog == null) {
-            fImportDialog = new ImportDialog(PlatformUI.getWorkbench().getActiveWorkbenchWindow().getShell());
-        }
-        return fImportDialog;
-    }
-
-    /**
-     * Sets the import dialog implementation.
-     * @param importDialog - a import dialog implementation
-     */
-    public void setImportDialog(IImportDialog importDialog) {
-        fImportDialog = importDialog;
-    }
-
-    /**
-     * @return the import confirmation dialog implementation.
-     */
-    public IImportConfirmationDialog getImportConfirmationDialog() {
-        if (fImportConfirmationDialog == null) {
-            fImportConfirmationDialog = new ImportConfirmationDialog(PlatformUI.getWorkbench().getActiveWorkbenchWindow().getShell());
-        }
-        return fImportConfirmationDialog;
-    }
-
-    /**
-     * Sets the import confirmation dialog implementation.
-     * @param confirmDialog - a import confirmation dialog implementation.
-     */
-    public void setImportConfirmationDialog(IImportConfirmationDialog confirmDialog) {
-        fImportConfirmationDialog = confirmDialog;
-    }
-}
-
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/AddContextOnChannelHandler.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/AddContextOnChannelHandler.java
deleted file mode 100644 (file)
index a68ce68..0000000
+++ /dev/null
@@ -1,90 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
-
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
-import org.eclipse.ui.IWorkbenchPage;
-
-/**
- * <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
-    // ------------------------------------------------------------------------
-
-    @Override
-    public void addContexts(CommandParameter param, List<String> contextNames, IProgressMonitor monitor) throws ExecutionException {
-        if (param instanceof ChannelCommandParameter) {
-            TraceChannelComponent channel = ((ChannelCommandParameter)param).getChannel();
-            channel.addContexts(contextNames, monitor);
-        }
-    }
-
-    @Override
-    public boolean isEnabled() {
-        // Get workbench page for the Control View
-        IWorkbenchPage page = getWorkbenchPage();
-        if (page == null) {
-            return false;
-        }
-
-        TraceChannelComponent channel = null;
-        TraceSessionComponent session = null;
-        ISelection selection = page.getSelection(ControlView.ID);
-        if (selection instanceof StructuredSelection) {
-            StructuredSelection structered = ((StructuredSelection) selection);
-            for (Iterator<?> iterator = structered.iterator(); iterator.hasNext();) {
-                Object element = iterator.next();
-                if (element instanceof TraceChannelComponent) {
-                    // Add only if corresponding TraceSessionComponents is inactive and not destroyed
-                    TraceChannelComponent tmpChannel = (TraceChannelComponent) element;
-                    session = tmpChannel.getSession();
-                    if(session.getSessionState() == TraceSessionState.INACTIVE && !session.isDestroyed()) {
-                        channel = tmpChannel;
-                    }
-                }
-            }
-        }
-
-        boolean isEnabled = (channel != null);
-        fLock.lock();
-        try {
-            fParam = null;
-            if(isEnabled) {
-                fParam = new ChannelCommandParameter(session, channel);
-            }
-        } finally {
-            fLock.unlock();
-        }
-        return isEnabled;
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/AddContextOnDomainHandler.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/AddContextOnDomainHandler.java
deleted file mode 100644 (file)
index d7051e0..0000000
+++ /dev/null
@@ -1,98 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
-
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
-import org.eclipse.ui.IWorkbenchPage;
-
-/**
- * <p>
- * Command handler implementation to add contexts to all channels and all events.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class AddContextOnDomainHandler extends BaseAddContextHandler {
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    public void addContexts(CommandParameter param, List<String> contextNames, IProgressMonitor monitor) throws ExecutionException {
-        if (param instanceof DomainCommandParameter) {
-            TraceDomainComponent domain = ((DomainCommandParameter)param).getDomain();
-            domain.addContexts(contextNames, monitor);
-        }
-    }
-
-    @Override
-    public boolean isEnabled() {
-
-        // Get workbench page for the Control View
-        IWorkbenchPage page = getWorkbenchPage();
-        if (page == null) {
-            return false;
-        }
-
-        TraceDomainComponent domain = null;
-        TraceSessionComponent session = null;
-
-        // Check if one domain is selected
-        ISelection selection = page.getSelection(ControlView.ID);
-        if (selection instanceof StructuredSelection) {
-            StructuredSelection structered = ((StructuredSelection) selection);
-            for (Iterator<?> iterator = structered.iterator(); iterator.hasNext();) {
-                Object element = iterator.next();
-                if (element instanceof TraceDomainComponent) {
-                    TraceDomainComponent tmpDomain = (TraceDomainComponent) element;
-                    session = (TraceSessionComponent) tmpDomain.getParent();
-
-                    // Add only TraceDomainComponent whose TraceSessionComponent parent is inactive and not destroyed
-                    if ((session.getSessionState() == TraceSessionState.INACTIVE) && (!session.isDestroyed())) {
-                        domain = tmpDomain;
-                    }
-                }
-            }
-        }
-
-        boolean isEnabled = domain != null;
-
-        fLock.lock();
-        try {
-            fParam = null;
-            if (isEnabled) {
-                fParam = new DomainCommandParameter(session, domain);
-            }
-        } finally {
-            fLock.unlock();
-        }
-
-        return isEnabled;
-    }
-
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/AddContextOnEventHandler.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/AddContextOnEventHandler.java
deleted file mode 100644 (file)
index 253d52e..0000000
+++ /dev/null
@@ -1,90 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
-
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceEventComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
-import org.eclipse.ui.IWorkbenchPage;
-
-/**
- * <p>
- * Command handler implementation to add contexts to a given event.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class AddContextOnEventHandler extends BaseAddContextHandler {
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    public void addContexts(CommandParameter param, List<String> contextNames, IProgressMonitor monitor) throws ExecutionException {
-        if (param instanceof EventCommandParameter) {
-            TraceEventComponent event = ((EventCommandParameter)param).getEvent();
-            event.addContexts(contextNames, monitor);
-        }
-    }
-
-    @Override
-    public boolean isEnabled() {
-        // Get workbench page for the Control View
-        IWorkbenchPage page = getWorkbenchPage();
-        if (page == null) {
-            return false;
-        }
-
-        TraceEventComponent event = null;
-        TraceSessionComponent session = null;
-        ISelection selection = page.getSelection(ControlView.ID);
-        if (selection instanceof StructuredSelection) {
-            StructuredSelection structered = ((StructuredSelection) selection);
-            for (Iterator<?> iterator = structered.iterator(); iterator.hasNext();) {
-                Object element = iterator.next();
-                if (element instanceof TraceEventComponent) {
-                    // Add only if corresponding TraceSessionComponents is inactive and not destroyed
-                    TraceEventComponent tmpEvent = (TraceEventComponent) element;
-                    session = tmpEvent.getSession();
-                    if(session.getSessionState() == TraceSessionState.INACTIVE && !session.isDestroyed()) {
-                        event = tmpEvent;
-                    }
-                }
-            }
-        }
-
-        boolean isEnabled = (event != null);
-        fLock.lock();
-        try {
-            fParam = null;
-            if(isEnabled) {
-                fParam = new EventCommandParameter(session, event);
-            }
-        } finally {
-            fLock.unlock();
-        }
-        return isEnabled;
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/AssignEventHandler.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/AssignEventHandler.java
deleted file mode 100644 (file)
index 36032f4..0000000
+++ /dev/null
@@ -1,253 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
-
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.core.commands.ExecutionEvent;
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.core.runtime.jobs.Job;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.jface.window.Window;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.IGetEventInfoDialog;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.TraceControlDialogFactory;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.BaseEventComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.KernelProviderComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.UstProviderComponent;
-import org.eclipse.ui.IWorkbenchPage;
-
-/**
- * <p>
- * Command handler implementation to assign events to a session and channel and enable/configure them.
- * This is done on the trace provider level.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class AssignEventHandler extends BaseControlViewHandler {
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-
-    /**
-     * The command execution parameter.
-     */
-    private Parameter fParam;
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    public Object execute(ExecutionEvent event) throws ExecutionException {
-
-        fLock.lock();
-        try {
-            // Make a copy for thread safety
-            final Parameter param = new Parameter(fParam);
-
-            // Open dialog box to retrieve the session and channel where the events should be enabled in.
-            final IGetEventInfoDialog dialog = TraceControlDialogFactory.getInstance().getGetEventInfoDialog();
-            dialog.setIsKernel(param.isKernel());
-            dialog.setSessions(param.getSessions());
-
-            if (dialog.open() != Window.OK) {
-                return null;
-            }
-
-            Job job = new Job(Messages.TraceControl_EnableEventsJob) {
-                @Override
-                protected IStatus run(IProgressMonitor monitor) {
-
-                    Exception error = null;
-
-                    try {
-                        List<String> eventNames = new ArrayList<>();
-                        List<BaseEventComponent> events = param.getEvents();
-                        // Create list of event names
-                        for (Iterator<BaseEventComponent> iterator = events.iterator(); iterator.hasNext();) {
-                            BaseEventComponent baseEvent = iterator.next();
-                            eventNames.add(baseEvent.getName());
-                        }
-
-                        TraceChannelComponent channel = dialog.getChannel();
-                        if (channel == null) {
-                            // enable events on default channel (which will be created by lttng-tools)
-                            dialog.getSession().enableEvents(eventNames, param.isKernel(), dialog.getFilterExpression(), monitor);
-                        } else {
-                            channel.enableEvents(eventNames, dialog.getFilterExpression(), monitor);
-                        }
-
-                    } catch (ExecutionException e) {
-                        error = e;
-                    }
-
-                    // refresh in all cases
-                    refresh(new CommandParameter(dialog.getSession()));
-
-                    if (error != null) {
-                        return new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.TraceControl_EnableEventsFailure, error);
-                    }
-                    return Status.OK_STATUS;
-                }
-            };
-            job.setUser(true);
-            job.schedule();
-        } finally {
-            fLock.unlock();
-        }
-
-        return null;
-    }
-
-    @Override
-    public boolean isEnabled() {
-        ArrayList<BaseEventComponent> events = new ArrayList<>();
-        TraceSessionComponent[] sessions = null;
-        Boolean isKernel = null;
-
-        // Get workbench page for the Control View
-        IWorkbenchPage page = getWorkbenchPage();
-        if (page == null) {
-            return false;
-        }
-
-        // Check if one or more session are selected
-        ISelection selection = page.getSelection(ControlView.ID);
-        if (selection instanceof StructuredSelection) {
-
-            StructuredSelection structered = ((StructuredSelection) selection);
-            for (Iterator<?> iterator = structered.iterator(); iterator.hasNext();) {
-                Object element = iterator.next();
-                if (element instanceof BaseEventComponent) {
-                    BaseEventComponent event = (BaseEventComponent) element;
-                    ITraceControlComponent provider = event.getParent();
-
-                    // check for kernel or UST provider
-                    boolean temp = false;
-                    if (provider instanceof KernelProviderComponent) {
-                        temp = true;
-                    } else if (provider instanceof UstProviderComponent) {
-                        temp = false;
-                    } else {
-                        return false;
-                    }
-                    if (isKernel == null) {
-                        isKernel = Boolean.valueOf(temp);
-                    } else {
-                        // don't mix events from Kernel and UST provider
-                        if (isKernel.booleanValue() != temp) {
-                            return false;
-                        }
-                    }
-
-                    // Add BaseEventComponents
-                    events.add(event);
-
-                    if (sessions == null) {
-                        TargetNodeComponent  root = (TargetNodeComponent)event.getParent().getParent().getParent();
-                        sessions = root.getSessions();
-                    }
-                }
-            }
-        }
-
-        boolean isEnabled = ((!events.isEmpty()) && (sessions != null) && (sessions.length > 0));
-
-        // To avoid compiler warnings check for null even if isKernel is always not null when used below
-        if (isKernel == null) {
-            return false;
-        }
-
-        fLock.lock();
-        try {
-            fParam = null;
-            if(isEnabled) {
-                fParam = new Parameter(sessions, events, isKernel);
-            }
-        } finally {
-            fLock.unlock();
-        }
-        return isEnabled;
-    }
-
-    /**
-     *  Class containing parameter for the command execution.
-     */
-    private static final class Parameter {
-
-        /**
-         * The list of event components the command is to be executed on.
-         */
-        private final List<BaseEventComponent> fEvents;
-
-        /**
-         * The list of available sessions.
-         */
-        private final TraceSessionComponent[] fSessions;
-
-        /**
-         * Flag for indicating Kernel or UST.
-         */
-        private final boolean fIsKernel;
-
-        /**
-         * Constructor
-         *
-         * @param sessions - a array of trace sessions
-         * @param events - a lists of events to enable
-         * @param isKernel - domain (true for kernel or UST)
-         */
-        public Parameter(TraceSessionComponent[] sessions, List<BaseEventComponent> events, boolean isKernel) {
-            fSessions = Arrays.copyOf(sessions, sessions.length);
-            fEvents = new ArrayList<>();
-            fEvents.addAll(events);
-            fIsKernel = isKernel;
-        }
-
-        /**
-         * Copy constructor
-         * @param other - a parameter to copy
-         */
-        public Parameter(Parameter other) {
-            this(other.fSessions, other.fEvents, other.fIsKernel);
-        }
-
-        public TraceSessionComponent[] getSessions() {
-            return fSessions;
-        }
-
-        public List<BaseEventComponent> getEvents() {
-            return fEvents;
-        }
-
-        public boolean isKernel() {
-            return fIsKernel;
-        }
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/BaseAddContextHandler.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/BaseAddContextHandler.java
deleted file mode 100644 (file)
index 35d1052..0000000
+++ /dev/null
@@ -1,132 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
-
-import java.util.List;
-
-import org.eclipse.core.commands.ExecutionEvent;
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.core.runtime.jobs.Job;
-import org.eclipse.jface.window.Window;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.IAddContextDialog;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.TraceControlDialogFactory;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
-import org.eclipse.ui.IWorkbenchWindow;
-import org.eclipse.ui.PlatformUI;
-import org.eclipse.ui.progress.UIJob;
-
-/**
- * <p>
- * Base command handler implementation to add contexts.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public abstract class BaseAddContextHandler extends BaseControlViewHandler {
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-
-    /**
-     * The command execution parameter.
-     */
-    protected CommandParameter fParam = null;
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    /**
-     * Adds contexts to channel(s) and/or event(s)
-     *
-     * @param param
-     *            - a parameter instance with data for the command execution
-     * @param contextNames
-     *            - list contexts to add
-     * @param monitor
-     *            - a progress monitor
-     * @throws ExecutionException
-     *             If something goes wrong
-     */
-    public abstract void addContexts(CommandParameter param, List<String> contextNames, IProgressMonitor monitor) throws ExecutionException;
-
-    @Override
-    public Object execute(ExecutionEvent event) throws ExecutionException {
-
-        final IWorkbenchWindow window = PlatformUI.getWorkbench().getActiveWorkbenchWindow();
-
-        if (window == null) {
-            return false;
-        }
-        fLock.lock();
-        try {
-            // Make a copy for thread safety
-            final CommandParameter param = fParam.clone();
-
-            UIJob getJob = new UIJob(Messages.TraceControl_GetContextJob) {
-                @Override
-                public IStatus runInUIThread(IProgressMonitor monitor) {
-
-                    try {
-                        final List<String> availableContexts = param.getSession().getContextList(monitor);
-                        final IAddContextDialog dialog = TraceControlDialogFactory.getInstance().getAddContextDialog();
-                        dialog.setAvalibleContexts(availableContexts);
-
-                        if ((dialog.open() != Window.OK) || (dialog.getContexts().isEmpty())) {
-                            return Status.OK_STATUS;
-                        }
-
-                        Job addJob = new Job(Messages.TraceControl_AddContextJob) {
-                            @Override
-                            protected IStatus run(IProgressMonitor monitor2) {
-                                Exception error = null;
-
-                                try {
-                                    List<String> contextNames = dialog.getContexts();
-                                    addContexts(param, contextNames, monitor2);
-
-                                } catch (ExecutionException e) {
-                                    error = e;
-                                }
-
-                                // get session configuration in all cases
-                                refresh(param);
-
-                                if (error != null) {
-                                    return new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.TraceControl_AddContextFailure, error);
-                                }
-                                return Status.OK_STATUS;
-                            }
-                        };
-                        addJob.setUser(true);
-                        addJob.schedule();
-                    } catch (ExecutionException e) {
-                        return new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.TraceControl_GetContextFailure, e);
-                    }
-
-                    return Status.OK_STATUS;
-                }
-            };
-            getJob.setUser(false);
-            getJob.schedule();
-
-        } finally {
-            fLock.unlock();
-        }
-        return null;
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/BaseControlViewHandler.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/BaseControlViewHandler.java
deleted file mode 100644 (file)
index 8e50191..0000000
+++ /dev/null
@@ -1,94 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
-
-import java.util.concurrent.locks.ReentrantLock;
-
-import org.eclipse.core.commands.AbstractHandler;
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.core.runtime.jobs.Job;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
-import org.eclipse.ui.IWorkbenchPage;
-import org.eclipse.ui.IWorkbenchPart;
-import org.eclipse.ui.IWorkbenchWindow;
-import org.eclipse.ui.PlatformUI;
-
-/**
- * <p>
- * Abstract Command handler implementation for all control view handlers.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public abstract class BaseControlViewHandler extends AbstractHandler {
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-    /**
-     * The synchronization lock.
-     */
-    protected final ReentrantLock fLock = new ReentrantLock();
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-    /**
-     * @return returns the workbench page for the Control View
-     */
-    protected IWorkbenchPage getWorkbenchPage() {
-        // Check if we are closing down
-        IWorkbenchWindow window = PlatformUI.getWorkbench().getActiveWorkbenchWindow();
-        if (window == null) {
-            return null;
-        }
-
-        // Check if we are in the Project View
-        IWorkbenchPage page = window.getActivePage();
-        if (page == null) {
-            return null;
-        }
-
-        IWorkbenchPart part = page.getActivePart();
-        if (!(part instanceof ControlView)) {
-            return null;
-        }
-        return page;
-    }
-
-    /**
-     * Refreshes the session information based on given session (in CommandParameter)
-     * @param param - command parameter containing the session to refresh
-     */
-    protected void refresh(final CommandParameter param) {
-        Job job = new Job(Messages.TraceControl_RetrieveNodeConfigurationJob) {
-
-            @Override
-            protected IStatus run(IProgressMonitor monitor) {
-                try {
-                    param.getSession().getConfigurationFromNode(monitor);
-                } catch (ExecutionException e) {
-                    return new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.TraceControl_ListSessionFailure, e);
-                }
-                return Status.OK_STATUS;
-            }
-        };
-        job.setUser(true);
-        job.schedule();
-    }
-
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/BaseEnableChannelHandler.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/BaseEnableChannelHandler.java
deleted file mode 100644 (file)
index 413739a..0000000
+++ /dev/null
@@ -1,124 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.core.commands.ExecutionEvent;
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.core.runtime.jobs.Job;
-import org.eclipse.jface.window.Window;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IChannelInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.IEnableChannelDialog;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.TraceControlDialogFactory;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent;
-
-/**
- * <p>
- * Base implementation of a command handler to enable a trace channel.
- * </p>
- *
- * @author Bernd Hufmann
- */
-abstract class BaseEnableChannelHandler extends BaseControlViewHandler {
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-    protected CommandParameter fParam;
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    /**
-     * Enables channels with given names which are part of this domain. If a
-     * given channel doesn't exists it creates a new channel with the given
-     * parameters (or default values if given parameter is null).
-     *
-     * @param param
-     *            - a parameter instance with data for the command execution
-     * @param channelNames
-     *            - a list of channel names to enable on this domain
-     * @param info
-     *            - channel information to set for the channel (use null for
-     *            default)
-     * @param isKernel
-     *            - a flag for indicating kernel or UST.
-     * @param monitor
-     *            - a progress monitor
-     * @throws ExecutionException
-     *             If something goes wrong when enabling the channel
-     */
-    public abstract void enableChannel(CommandParameter param,
-            List<String> channelNames, IChannelInfo info, boolean isKernel,
-            IProgressMonitor monitor) throws ExecutionException;
-
-    /**
-     * @param param - a parameter instance with data for the command execution
-     * @return returns the relevant domain (null if domain is not known)
-     */
-    public abstract TraceDomainComponent getDomain(CommandParameter param);
-
-    @Override
-    public Object execute(ExecutionEvent event) throws ExecutionException {
-        fLock.lock();
-        try {
-            final CommandParameter param = fParam.clone();
-
-            final IEnableChannelDialog dialog =  TraceControlDialogFactory.getInstance().getEnableChannelDialog();
-            dialog.setTargetNodeComponent(param.getSession().getTargetNode());
-            dialog.setDomainComponent(getDomain(param));
-            dialog.setHasKernel(param.getSession().hasKernelProvider());
-
-            if (dialog.open() != Window.OK) {
-                return null;
-            }
-
-            Job job = new Job(Messages.TraceControl_CreateChannelStateJob) {
-                @Override
-                protected IStatus run(IProgressMonitor monitor) {
-                    Exception error = null;
-
-                    List<String> channelNames = new ArrayList<>();
-                    channelNames.add(dialog.getChannelInfo().getName());
-
-                    try {
-                        enableChannel(param, channelNames, dialog.getChannelInfo(), dialog.isKernel(), monitor);
-                    } catch (ExecutionException e) {
-                        error = e;
-                    }
-
-                    // refresh in all cases
-                    refresh(param);
-
-                    if (error != null) {
-                        return new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.TraceControl_CreateChannelStateFailure, error);
-                    }
-                    return Status.OK_STATUS;
-                }
-            };
-            job.setUser(true);
-            job.schedule();
-        } finally {
-            fLock.unlock();
-        }
-        return null;
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/BaseEnableEventHandler.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/BaseEnableEventHandler.java
deleted file mode 100644 (file)
index 45a3349..0000000
+++ /dev/null
@@ -1,227 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
-
-import java.util.List;
-
-import org.eclipse.core.commands.ExecutionEvent;
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.core.runtime.jobs.Job;
-import org.eclipse.jface.window.Window;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.LogLevelType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.IEnableEventsDialog;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.TraceControlDialogFactory;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceProviderGroup;
-import org.eclipse.ui.IWorkbenchWindow;
-import org.eclipse.ui.PlatformUI;
-
-/**
- * <p>
- * Base command handler implementation to enable events.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public abstract class BaseEnableEventHandler extends BaseControlViewHandler {
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-    /**
-     * The command execution parameter.
-     */
-    protected CommandParameter fParam = null;
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    /**
-     * Enables a list of events for given parameters.
-     *
-     * @param param
-     *            - a parameter instance with data for the command execution
-     * @param eventNames
-     *            - list of event names
-     * @param isKernel
-     *            - true if kernel domain else false
-     * @param filterExpression
-     *            - a filter expression
-     * @param monitor
-     *            - a progress monitor
-     * @throws ExecutionException
-     *             If the command fails for some reason
-     */
-    public abstract void enableEvents(CommandParameter param, List<String> eventNames, boolean isKernel, String filterExpression, IProgressMonitor monitor) throws ExecutionException;
-
-    /**
-     * Enables all syscall events.
-     *
-     * @param param
-     *            - a parameter instance with data for the command execution
-     * @param monitor
-     *            - a progress monitor
-     * @throws ExecutionException
-     *             If the command fails for some reason
-     */
-    public abstract void enableSyscalls(CommandParameter param, IProgressMonitor monitor) throws ExecutionException;
-
-    /**
-     * Enables a dynamic probe.
-     *
-     * @param param
-     *            - a parameter instance with data for the command execution
-     * @param eventName
-     *            - a event name
-     * @param isFunction
-     *            - true for dynamic function entry/return probe else false
-     * @param probe
-     *            - a dynamic probe information
-     * @param monitor
-     *            - a progress monitor
-     * @throws ExecutionException
-     *             If the command fails for some reason
-     */
-    public abstract void enableProbe(CommandParameter param, String eventName, boolean isFunction, String probe, IProgressMonitor monitor) throws ExecutionException;
-
-    /**
-     * Enables events using log level
-     *
-     * @param param
-     *            - a parameter instance with data for the command execution
-     * @param eventName
-     *            - a event name
-     * @param logLevelType
-     *            - a log level type
-     * @param level
-     *            - a log level
-     * @param filterExpression
-     *            - a filter expression
-     * @param monitor
-     *            - a progress monitor
-     * @throws ExecutionException
-     *             If the command fails for some reason
-     */
-    public abstract void enableLogLevel(CommandParameter param, String eventName, LogLevelType logLevelType, TraceLogLevel level, String filterExpression, IProgressMonitor monitor) throws ExecutionException;
-
-    /**
-     * @param param
-     *            - a parameter instance with data for the command execution
-     * @return returns the relevant domain (null if domain is not known)
-     */
-    public abstract TraceDomainComponent getDomain(CommandParameter param);
-
-    @Override
-    public Object execute(ExecutionEvent event) throws ExecutionException {
-
-        final IWorkbenchWindow window = PlatformUI.getWorkbench().getActiveWorkbenchWindow();
-
-        if (window == null) {
-            return false;
-        }
-        fLock.lock();
-        try {
-            // Make a copy for thread safety
-            final CommandParameter param = fParam.clone();
-
-            TargetNodeComponent node = param.getSession().getTargetNode();
-            List<ITraceControlComponent> providers = node.getChildren(TraceProviderGroup.class);
-
-            final IEnableEventsDialog dialog = TraceControlDialogFactory.getInstance().getEnableEventsDialog();
-            dialog.setTraceProviderGroup((TraceProviderGroup)providers.get(0));
-            dialog.setTraceDomainComponent(getDomain(param));
-
-            if (dialog.open() != Window.OK) {
-                return null;
-            }
-
-            Job job = new Job(Messages.TraceControl_ChangeEventStateJob) {
-                @Override
-                protected IStatus run(IProgressMonitor monitor) {
-                    Exception error = null;
-
-                    try {
-                        String filter = dialog.getFilterExpression();
-
-                        // Enable tracepoint events
-                        if (dialog.isTracepoints()) {
-                            if (dialog.isAllTracePoints()) {
-                                enableEvents(param, null, dialog.isKernel(), filter, monitor);
-                            } else {
-                                List<String> eventNames = dialog.getEventNames();
-                                if (!eventNames.isEmpty()) {
-                                    enableEvents(param, eventNames, dialog.isKernel(), filter, monitor);
-                                }
-                            }
-                        }
-
-                        // Enable syscall events
-                        if (dialog.isAllSysCalls()) {
-                            enableSyscalls(param, monitor);
-                        }
-
-                        // Enable dynamic probe
-                        if (dialog.isDynamicProbe() && (dialog.getProbeEventName() != null) && (dialog.getProbeName() != null)) {
-                            enableProbe(param, dialog.getProbeEventName(), false, dialog.getProbeName(), monitor);
-                        }
-
-                        // Enable dynamic function probe
-                        if (dialog.isDynamicFunctionProbe() && (dialog.getFunctionEventName() != null) && (dialog.getFunction() != null)) {
-                            enableProbe(param, dialog.getFunctionEventName(), true, dialog.getFunction(), monitor);
-                        }
-
-                        // Enable event using a wildcard
-                        if (dialog.isWildcard()) {
-                            List<String> eventNames = dialog.getEventNames();
-                            eventNames.add(dialog.getWildcard());
-
-                            if (!eventNames.isEmpty()) {
-                                enableEvents(param, eventNames, dialog.isKernel(), filter, monitor);
-                            }
-                        }
-
-                        // Enable events using log level
-                        if (dialog.isLogLevel()) {
-                            enableLogLevel(param, dialog.getLogLevelEventName(), dialog.getLogLevelType(), dialog.getLogLevel(), filter, monitor);
-                        }
-
-                    } catch (ExecutionException e) {
-                        error = e;
-                    }
-
-                    // refresh in all cases
-                    refresh(param);
-
-                    if (error != null) {
-                        return new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.TraceControl_ChangeEventStateFailure, error);
-                    }
-                    return Status.OK_STATUS;
-                }
-            };
-            job.setUser(true);
-            job.schedule();
-        } finally {
-            fLock.unlock();
-        }
-        return null;
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/BaseNodeHandler.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/BaseNodeHandler.java
deleted file mode 100644 (file)
index 90bf62e..0000000
+++ /dev/null
@@ -1,70 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
-
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent;
-import org.eclipse.ui.IWorkbenchPage;
-
-/**
- * <p>
- * Command handler implementation to delete a target host.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public abstract class BaseNodeHandler extends BaseControlViewHandler {
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-    /**
-     * The target node component the command is to be executed on.
-     */
-    protected TargetNodeComponent fTargetNode = null;
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    public boolean isEnabled() {
-
-        // Get workbench page for the Control View
-        IWorkbenchPage page = getWorkbenchPage();
-        if (page == null) {
-            return false;
-        }
-
-        TargetNodeComponent node = null;
-        // Check if the node component is selected
-        ISelection selection = page.getSelection(ControlView.ID);
-        if (selection instanceof StructuredSelection) {
-            Object element = ((StructuredSelection) selection).getFirstElement();
-            node = (element instanceof TargetNodeComponent) ? (TargetNodeComponent) element : null;
-        }
-        boolean isEnabled = node != null;
-        fLock.lock();
-        try {
-            if (isEnabled) {
-                fTargetNode = node;
-            }
-        } finally {
-            fLock.unlock();
-        }
-        return isEnabled;
-    }
-
-
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/CalibrateHandler.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/CalibrateHandler.java
deleted file mode 100644 (file)
index b55a3b9..0000000
+++ /dev/null
@@ -1,132 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
-
-import java.util.Iterator;
-
-import org.eclipse.core.commands.ExecutionEvent;
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.core.runtime.jobs.Job;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
-import org.eclipse.ui.IWorkbenchPage;
-import org.eclipse.ui.IWorkbenchWindow;
-import org.eclipse.ui.PlatformUI;
-
-/**
- * <p>
- * Command handler implementation to execute command calibrate to quantify LTTng overhead.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class CalibrateHandler extends BaseControlViewHandler {
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-    /**
-     * The command execution parameter.
-     */
-    protected DomainCommandParameter fParam = null;
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    public Object execute(ExecutionEvent event) throws ExecutionException {
-
-        final IWorkbenchWindow window = PlatformUI.getWorkbench().getActiveWorkbenchWindow();
-
-        if (window == null) {
-            return false;
-        }
-        fLock.lock();
-        try {
-            // Make a copy for thread safety
-            final DomainCommandParameter param = fParam.clone();
-
-            Job addJob = new Job(Messages.TraceControl_AddCalibrateJob) {
-                @Override
-                protected IStatus run(IProgressMonitor monitor) {
-                    try {
-                        param.getDomain().calibrate(monitor);
-                    } catch (ExecutionException e) {
-                        return new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.TraceControl_AddCalibrateFailure, e);
-                    }
-
-                    return Status.OK_STATUS;
-                }
-            };
-            addJob.setUser(true);
-            addJob.schedule();
-
-        } finally {
-            fLock.unlock();
-        }
-        return Status.OK_STATUS;
-    }
-
-    @Override
-    public boolean isEnabled() {
-
-        // Get workbench page for the Control View
-        IWorkbenchPage page = getWorkbenchPage();
-        if (page == null) {
-            return false;
-        }
-
-        TraceDomainComponent domain = null;
-        TraceSessionComponent session = null;
-
-        // Check if one domain is selected
-        ISelection selection = page.getSelection(ControlView.ID);
-        if (selection instanceof StructuredSelection) {
-            StructuredSelection structered = ((StructuredSelection) selection);
-            for (Iterator<?> iterator = structered.iterator(); iterator.hasNext();) {
-                Object element = iterator.next();
-                if (element instanceof TraceDomainComponent) {
-                    TraceDomainComponent tmpDomain = (TraceDomainComponent) element;
-                    session = (TraceSessionComponent) tmpDomain.getParent();
-
-                    // Add only TraceDomainComponent whose TraceSessionComponent parent is not destroyed
-                    if ((!session.isDestroyed())) {
-                        domain = tmpDomain;
-                    }
-                }
-            }
-        }
-
-        boolean isEnabled = domain != null;
-
-        fLock.lock();
-        try {
-            fParam = null;
-            if (isEnabled) {
-                fParam = new DomainCommandParameter(session, domain);
-            }
-        } finally {
-            fLock.unlock();
-        }
-
-        return isEnabled;
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/ChangeChannelStateHandler.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/ChangeChannelStateHandler.java
deleted file mode 100644 (file)
index 98789be..0000000
+++ /dev/null
@@ -1,303 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
-
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.core.commands.ExecutionEvent;
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.core.runtime.jobs.Job;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEnablement;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
-import org.eclipse.ui.IWorkbenchPage;
-import org.eclipse.ui.IWorkbenchWindow;
-import org.eclipse.ui.PlatformUI;
-
-/**
- * <p>
- * Abstract command handler implementation to enable or disabling a trace channel.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public abstract class ChangeChannelStateHandler extends BaseControlViewHandler {
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-    /**
-     * The command execution parameter.
-     */
-    protected Parameter fParam;
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-    /**
-     * @return the new state to set
-     */
-    protected abstract TraceEnablement getNewState();
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-    /**
-     * Changes the state of the given channels.
-     * @param domain - the domain of the channels.
-     * @param channelNames - a list of channel names
-     * @param monitor - a progress monitor
-     * @throws ExecutionException If the command fails
-     */
-    protected abstract void changeState(TraceDomainComponent domain, List<String> channelNames, IProgressMonitor monitor) throws ExecutionException;
-
-    @Override
-    public Object execute(ExecutionEvent event) throws ExecutionException {
-
-        fLock.lock();
-        try {
-            IWorkbenchWindow window = PlatformUI.getWorkbench().getActiveWorkbenchWindow();
-
-            if (window == null) {
-                return false;
-            }
-
-            final Parameter param = new Parameter(fParam);
-
-            Job job = new Job(Messages.TraceControl_ChangeChannelStateJob) {
-                @Override
-                protected IStatus run(IProgressMonitor monitor) {
-                    Exception error = null;
-
-                    TraceSessionComponent session = null;
-
-                    try {
-                        TraceDomainComponent kernelDomain = param.getKernelDomain();
-                        List<TraceChannelComponent> kernelChannels = param.getKernelChannels();
-
-                        if (kernelDomain != null) {
-                            session = (TraceSessionComponent)kernelDomain.getParent();
-                            List<String> channelNames = new ArrayList<>();
-                            for (Iterator<TraceChannelComponent> iterator = kernelChannels.iterator(); iterator.hasNext();) {
-                                // Enable all selected channels which are disabled
-                                TraceChannelComponent channel = iterator.next();
-                                channelNames.add(channel.getName());
-                            }
-
-                            changeState(kernelDomain, channelNames, monitor);
-
-                            for (Iterator<TraceChannelComponent> iterator = kernelChannels.iterator(); iterator.hasNext();) {
-                                // Enable all selected channels which are disabled
-                                TraceChannelComponent channel = iterator.next();
-                                channel.setState(getNewState());
-                            }
-                        }
-
-                        TraceDomainComponent ustDomain = param.getUstDomain();
-                        List<TraceChannelComponent> ustChannels = param.getUstChannels();
-                        if (ustDomain != null) {
-                            if (session == null) {
-                                session = (TraceSessionComponent)ustDomain.getParent();
-                            }
-
-                            List<String> channelNames = new ArrayList<>();
-                            for (Iterator<TraceChannelComponent> iterator = ustChannels.iterator(); iterator.hasNext();) {
-                                // Enable all selected channels which are disabled
-                                TraceChannelComponent channel = iterator.next();
-                                channelNames.add(channel.getName());
-                            }
-
-                            changeState(ustDomain, channelNames, monitor);
-
-                            for (Iterator<TraceChannelComponent> iterator = ustChannels.iterator(); iterator.hasNext();) {
-                                // Enable all selected channels which are disabled
-                                TraceChannelComponent channel = iterator.next();
-                                channel.setState(getNewState());
-                            }
-                        }
-                    } catch (ExecutionException e) {
-                        error = e;
-                    }
-
-                    // In all cases notify listeners
-                    if (session != null) {
-                        session.fireComponentChanged(session);
-                    }
-
-                    if (error != null) {
-                        return new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.TraceControl_ChangeChannelStateFailure, error);
-                    }
-
-                    return Status.OK_STATUS;
-                }
-            };
-            job.setUser(true);
-            job.schedule();
-        } finally {
-            fLock.unlock();
-        }
-
-        return null;
-    }
-
-    @Override
-    public boolean isEnabled() {
-
-        // Get workbench page for the Control View
-        IWorkbenchPage page = getWorkbenchPage();
-        if (page == null) {
-            return false;
-        }
-
-        TraceDomainComponent kernelDomain = null;
-        TraceDomainComponent ustDomain = null;
-        List<TraceChannelComponent> kernelChannels = new ArrayList<>();
-        List<TraceChannelComponent> ustChannels = new ArrayList<>();
-
-        // Check if one or more session are selected
-        ISelection selection = page.getSelection(ControlView.ID);
-        if (selection instanceof StructuredSelection) {
-            StructuredSelection structered = ((StructuredSelection) selection);
-            String sessionName = null;
-            for (Iterator<?> iterator = structered.iterator(); iterator.hasNext();) {
-                Object element = iterator.next();
-
-                if (element instanceof TraceChannelComponent) {
-
-                    // Add only TraceChannelComponents that are disabled
-                    TraceChannelComponent channel = (TraceChannelComponent) element;
-                    if (sessionName == null) {
-                        sessionName = String.valueOf(channel.getSessionName());
-                    }
-
-                    // Enable command only for channels of same session
-                    if (!sessionName.equals(channel.getSessionName())) {
-                        kernelChannels.clear();
-                        ustChannels.clear();
-                        break;
-                    }
-
-                    if ((channel.getState() != getNewState())) {
-                        if (channel.isKernel()) {
-                            kernelChannels.add(channel);
-                            if (kernelDomain == null) {
-                                kernelDomain = (TraceDomainComponent) channel.getParent();
-                            }
-                        } else {
-                            ustChannels.add(channel);
-                            if (ustDomain == null) {
-                                ustDomain = (TraceDomainComponent) channel.getParent();
-                            }
-                        }
-                    }
-                }
-            }
-        }
-
-        boolean isEnabled = (!kernelChannels.isEmpty() || !ustChannels.isEmpty());
-        fLock.lock();
-        try {
-            if (isEnabled) {
-                fParam = new Parameter(kernelDomain, ustDomain, kernelChannels, ustChannels);
-            }
-        } finally {
-            fLock.unlock();
-        }
-
-        return isEnabled;
-    }
-
-    /**
-     *  Class containing parameter for the command execution.
-     */
-    protected static class Parameter {
-        /**
-         * Kernel domain component reference.
-         */
-        protected final TraceDomainComponent fKernelDomain;
-        /**
-         * UST domain component reference.
-         */
-        protected final TraceDomainComponent fUstDomain;
-        /**
-         * The list of kernel channel components the command is to be executed on.
-         */
-        protected final List<TraceChannelComponent> fKernelChannels;
-        /**
-         * The list of UST channel components the command is to be executed on.
-         */
-        protected final List<TraceChannelComponent> fUstChannels;
-
-        /**
-         * Constructor
-         * @param kernelDomain - a kernel domain component
-         * @param ustDomain - a UST domain component
-         * @param kernelChannels - list of available kernel channels
-         * @param ustChannels - list of available UST channels
-         */
-        public Parameter(TraceDomainComponent kernelDomain, TraceDomainComponent ustDomain, List<TraceChannelComponent> kernelChannels, List<TraceChannelComponent> ustChannels) {
-            fKernelDomain = kernelDomain;
-            fUstDomain = ustDomain;
-            fKernelChannels = new ArrayList<>();
-            fKernelChannels.addAll(kernelChannels);
-            fUstChannels = new ArrayList<>();
-            fUstChannels.addAll(ustChannels);
-        }
-
-        /**
-         * Copy constructor
-         * @param other a parameter to copy
-         */
-        public Parameter(Parameter other) {
-            this(other.fKernelDomain, other.fUstDomain, other.fKernelChannels, other.fUstChannels);
-        }
-
-        /**
-         * @return the kernel domain component.
-         */
-        public TraceDomainComponent getKernelDomain() {
-            return fKernelDomain;
-        }
-
-        /**
-         * @return the UST domain component.
-         */
-        public TraceDomainComponent getUstDomain() {
-            return fUstDomain;
-        }
-
-        /**
-         * @return the list of kernel channel components.
-         */
-        public List<TraceChannelComponent> getKernelChannels() {
-            return fKernelChannels;
-        }
-
-        /**
-         * @return the list of UST channel components.
-         */
-        public List<TraceChannelComponent> getUstChannels() {
-            return fUstChannels;
-        }
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/ChangeEventStateHandler.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/ChangeEventStateHandler.java
deleted file mode 100644 (file)
index 4037640..0000000
+++ /dev/null
@@ -1,261 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
-
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.core.commands.ExecutionEvent;
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.core.runtime.jobs.Job;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEnablement;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceEventComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
-import org.eclipse.ui.IWorkbenchPage;
-import org.eclipse.ui.IWorkbenchWindow;
-import org.eclipse.ui.PlatformUI;
-
-/**
- * <p>
- * Base Command handler implementation to enable or disabling a trace channel.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public abstract class ChangeEventStateHandler extends BaseControlViewHandler {
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-    /**
-     * The command execution parameter.
-     */
-    protected Parameter fParam;
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-    /**
-     * @return the new state to set
-     */
-    protected abstract TraceEnablement getNewState();
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-    /**
-     * Change the state
-     * @param channel - channel of events to be enabled
-     * @param eventNames - list event names
-     * @param monitor - a progress monitor
-     * @throws ExecutionException If the command fails
-     */
-    protected abstract void changeState(TraceChannelComponent channel, List<String> eventNames, IProgressMonitor monitor) throws ExecutionException;
-
-    @Override
-    public Object execute(ExecutionEvent event) throws ExecutionException {
-
-        IWorkbenchWindow window = PlatformUI.getWorkbench().getActiveWorkbenchWindow();
-
-        if (window == null) {
-            return false;
-        }
-
-        fLock.lock();
-        try {
-
-            final Parameter param = new Parameter(fParam);
-
-            Job job = new Job(Messages.TraceControl_ChangeChannelStateJob) {
-                @Override
-                protected IStatus run(IProgressMonitor monitor) {
-                    Exception error = null;
-
-                    TraceSessionComponent session = null;
-
-                    try {
-                        boolean isAll = false;
-                        if (param.getChannel() != null) {
-                            session = param.getChannel().getSession();
-                            List<String> eventNames = new ArrayList<>();
-                            List<TraceEventComponent> events = param.getEvents();
-
-                            for (Iterator<TraceEventComponent> iterator = events.iterator(); iterator.hasNext();) {
-                                // Enable/disable all selected channels which are disabled
-                                TraceEventComponent traceEvent = iterator.next();
-
-                                // Workaround for wildcard handling in lttng-tools
-                                if ("*".equals(traceEvent.getName())) { //$NON-NLS-1$
-                                    isAll = true;
-                                } else {
-                                    eventNames.add(traceEvent.getName());
-                                }
-                            }
-                            if (isAll) {
-                                changeState(param.getChannel(), null, monitor);
-                            }
-
-                            if (!eventNames.isEmpty()) {
-                                changeState(param.getChannel(), eventNames, monitor);
-                            }
-
-                            for (Iterator<TraceEventComponent> iterator = events.iterator(); iterator.hasNext();) {
-                                // Enable all selected channels which are disabled
-                                TraceEventComponent ev = iterator.next();
-                                ev.setState(getNewState());
-                            }
-                        }
-                    } catch (ExecutionException e) {
-                        error = e;
-                    }
-
-                    if (session != null) {
-                        // In all cases notify listeners
-                        session.fireComponentChanged(session);
-                    }
-
-                    if (error != null) {
-                        return new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.TraceControl_ChangeEventStateFailure, error);
-                    }
-
-                    return Status.OK_STATUS;
-                }
-            };
-            job.setUser(true);
-            job.schedule();
-        } finally {
-            fLock.unlock();
-        }
-        return null;
-    }
-
-    @Override
-    public boolean isEnabled() {
-        // Get workbench page for the Control View
-        IWorkbenchPage page = getWorkbenchPage();
-        if (page == null) {
-            return false;
-        }
-
-        // Check if one or more session are selected
-        ISelection selection = page.getSelection(ControlView.ID);
-
-        TraceChannelComponent channel = null;
-        List<TraceEventComponent> events = new ArrayList<>();
-
-        if (selection instanceof StructuredSelection) {
-            StructuredSelection structered = ((StructuredSelection) selection);
-            String sessionName = null;
-            String channelName = null;
-
-            for (Iterator<?> iterator = structered.iterator(); iterator.hasNext();) {
-                Object element = iterator.next();
-
-                if (element instanceof TraceEventComponent) {
-
-                    TraceEventComponent event = (TraceEventComponent) element;
-                    if (sessionName == null) {
-                        sessionName = String.valueOf(event.getSessionName());
-                    }
-
-                    if (channel == null) {
-                        channel = (TraceChannelComponent)event.getParent();
-                    }
-
-                    if (channelName == null) {
-                        channelName = event.getChannelName();
-                    }
-
-                    // Enable command only for events of same session, same channel and domain
-                    if ((!sessionName.equals(event.getSessionName())) ||
-                        (!channelName.equals(event.getChannelName())) ||
-                        (channel.isKernel() != event.isKernel())) {
-                        events.clear();
-                        break;
-                    }
-
-                    if ((event.getState() != getNewState())) {
-                        events.add(event);
-                    }
-                }
-            }
-        }
-        boolean isEnabled = !events.isEmpty();
-
-        fLock.lock();
-        try {
-            fParam = null;
-            if (isEnabled) {
-                fParam = new Parameter(channel, events);
-            }
-        } finally {
-            fLock.unlock();
-        }
-        return isEnabled;
-    }
-
-    /**
-     *  Class containing parameter for the command execution.
-     */
-    protected static class Parameter {
-        /**
-         * Channel component reference.
-         */
-        private final TraceChannelComponent fChannel;
-        /**
-         * The list of kernel channel components the command is to be executed on.
-         */
-        private final List<TraceEventComponent> fEvents = new ArrayList<>();
-
-        /**
-         * Constructor
-         * @param channel - a channel component
-         * @param events - a list of event components
-         */
-        public Parameter(TraceChannelComponent channel, List<TraceEventComponent> events) {
-            fChannel = channel;
-            fEvents.addAll(events);
-        }
-
-        /**
-         * Copy constructor
-         * @param other - a parameter to copy
-         */
-        public Parameter(Parameter other) {
-            this(other.fChannel, other.fEvents);
-        }
-
-        /**
-         * @return the trace channel component.
-         */
-        public TraceChannelComponent getChannel() {
-            return fChannel;
-        }
-
-        /**
-         * @return a list of trace event components.
-         */
-        public List<TraceEventComponent> getEvents() {
-            return fEvents;
-        }
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/ChangeSessionStateHandler.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/ChangeSessionStateHandler.java
deleted file mode 100644 (file)
index 52ae259..0000000
+++ /dev/null
@@ -1,157 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
-
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.core.commands.ExecutionEvent;
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.core.runtime.jobs.Job;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
-import org.eclipse.ui.IWorkbenchPage;
-import org.eclipse.ui.IWorkbenchWindow;
-import org.eclipse.ui.PlatformUI;
-
-/**
- * <p>
- * Abstract command handler implementation to start or stop one or more trace sessions.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public abstract class ChangeSessionStateHandler extends BaseControlViewHandler {
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-    /**
-     * The list of session components the command is to be executed on.
-     */
-    protected List<TraceSessionComponent> fSessions = new ArrayList<>();
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    /**
-     * @return new required state.
-     */
-    public abstract TraceSessionState getNewState();
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    /**
-     * Performs the state change on given session.
-     *
-     * @param session
-     *            - a session which state is to be changed
-     * @param monitor
-     *            - a progress monitor
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    public abstract void changeState(TraceSessionComponent session, IProgressMonitor monitor) throws ExecutionException;
-
-    @Override
-    public Object execute(ExecutionEvent event) throws ExecutionException {
-
-        IWorkbenchWindow window = PlatformUI.getWorkbench().getActiveWorkbenchWindow();
-
-        if (window == null) {
-            return false;
-        }
-
-        fLock.lock();
-        try {
-
-            final List<TraceSessionComponent> sessions = new ArrayList<>();
-            sessions.addAll(fSessions);
-
-            Job job = new Job(Messages.TraceControl_ChangeSessionStateJob) {
-                @Override
-                protected IStatus run(IProgressMonitor monitor) {
-                    try {
-                        for (Iterator<TraceSessionComponent> iterator = sessions.iterator(); iterator.hasNext();) {
-
-                            // Start all selected sessions
-                            TraceSessionComponent session = iterator.next();
-                            changeState(session, monitor);
-
-                            // Set Session state
-                            session.setSessionState(getNewState());
-                            session.fireComponentChanged(session);
-                        }
-                    } catch (ExecutionException e) {
-                        return new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.TraceControl_ChangeSessionStateFailure, e);
-                    }
-                    return Status.OK_STATUS;
-                }
-            };
-            job.setUser(true);
-            job.schedule();
-        } finally {
-            fLock.unlock();
-        }
-        return null;
-    }
-
-    @Override
-    public boolean isEnabled() {
-        // Get workbench page for the Control View
-        IWorkbenchPage page = getWorkbenchPage();
-        if (page == null) {
-            return false;
-        }
-
-        List<TraceSessionComponent> sessions = new ArrayList<>(0);
-
-        // Check if one or more session are selected
-        ISelection selection = page.getSelection(ControlView.ID);
-        if (selection instanceof StructuredSelection) {
-            StructuredSelection structered = ((StructuredSelection) selection);
-            for (Iterator<?> iterator = structered.iterator(); iterator.hasNext();) {
-                Object element = iterator.next();
-                if (element instanceof TraceSessionComponent) {
-                    // Add only TraceSessionComponents that are inactive and not destroyed
-                    TraceSessionComponent session = (TraceSessionComponent) element;
-                    if ((session.getSessionState() != getNewState()) && (!session.isDestroyed())) {
-                        sessions.add(session);
-                    }
-                }
-            }
-        }
-        boolean isEnabled = !sessions.isEmpty();
-        fLock.lock();
-        try {
-            fSessions = null;
-            if (isEnabled) {
-                fSessions = sessions;
-            }
-        } finally {
-            fLock.unlock();
-        }
-        return isEnabled;
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/ChannelCommandParameter.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/ChannelCommandParameter.java
deleted file mode 100644 (file)
index 655dde3..0000000
+++ /dev/null
@@ -1,66 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
-
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
-
-/**
- * Class containing parameter for the command execution.
- *
- * @author Bernd Hufmann
- */
-public class ChannelCommandParameter extends CommandParameter {
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-
-    private TraceChannelComponent fChannel;
-
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-
-    /**
-     * Constructor
-     * @param session - a trace session component.
-     * @param channel - a trace channel component
-     */
-    public ChannelCommandParameter(TraceSessionComponent session, TraceChannelComponent channel) {
-        super(session);
-        fChannel = channel;
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    /**
-     * @return the trace channel component
-     */
-    public TraceChannelComponent getChannel() {
-        return fChannel;
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    public ChannelCommandParameter clone() {
-        ChannelCommandParameter clone = (ChannelCommandParameter) super.clone();
-        clone.fChannel = fChannel;
-        return clone;
-    }
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/CommandParameter.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/CommandParameter.java
deleted file mode 100644 (file)
index 69c15b9..0000000
+++ /dev/null
@@ -1,69 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
-
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
-
-/**
- * Class containing parameter for the command execution.
- *
- * @author Bernd Hufmann
- */
-public class CommandParameter implements Cloneable {
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-
-    /**
-     * The trace session component.
-     */
-    private TraceSessionComponent fSession;
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-
-    /**
-     * Constructor
-     * @param session a trace session component.
-     */
-    public CommandParameter(TraceSessionComponent session) {
-        fSession = session;
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    /**
-     * @return the session component.
-     */
-    public TraceSessionComponent getSession() {
-        return fSession;
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    public CommandParameter clone() {
-        CommandParameter clone = null;
-        try {
-            clone = (CommandParameter) super.clone();
-            clone.fSession = fSession;
-        } catch (CloneNotSupportedException e) {
-        }
-        return clone;
-    }
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/ConnectHandler.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/ConnectHandler.java
deleted file mode 100644 (file)
index 22fcc66..0000000
+++ /dev/null
@@ -1,53 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
-
-import org.eclipse.core.commands.ExecutionEvent;
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TargetNodeState;
-
-/**
- * <p>
- * Command handler implementation to connect to a target host.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class ConnectHandler extends BaseNodeHandler {
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    public Object execute(ExecutionEvent event) throws ExecutionException {
-        fLock.lock();
-        try {
-            fTargetNode.connect();
-        } finally {
-            fLock.unlock();
-        }
-        return null;
-    }
-
-    @Override
-    public boolean isEnabled() {
-        boolean isEnabled = false;
-        fLock.lock();
-        try {
-           isEnabled = (super.isEnabled() && (fTargetNode.getTargetNodeState() == TargetNodeState.DISCONNECTED));
-        } finally {
-            fLock.unlock();
-        }
-        return isEnabled;
-     }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/CreateSessionHandler.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/CreateSessionHandler.java
deleted file mode 100644 (file)
index e76e31b..0000000
+++ /dev/null
@@ -1,118 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
-
-import org.eclipse.core.commands.ExecutionEvent;
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.core.runtime.jobs.Job;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.jface.window.Window;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.ICreateSessionDialog;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.TraceControlDialogFactory;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionGroup;
-import org.eclipse.ui.IWorkbenchPage;
-
-/**
- * <p>
- * Command handler implementation to create a trace session.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class CreateSessionHandler extends BaseControlViewHandler {
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-
-    /**
-     * The trace session group the command is to be executed on.
-     */
-    private TraceSessionGroup fSessionGroup = null;
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    public Object execute(ExecutionEvent event) throws ExecutionException {
-
-        fLock.lock();
-        try {
-            final TraceSessionGroup sessionGroup = fSessionGroup;
-
-            // Open dialog box for the node name and address
-            final ICreateSessionDialog dialog = TraceControlDialogFactory.getInstance().getCreateSessionDialog();
-            dialog.initialize(sessionGroup);
-
-            if (dialog.open() != Window.OK) {
-                return null;
-            }
-
-            Job job = new Job(Messages.TraceControl_CreateSessionJob) {
-                @Override
-                protected IStatus run(IProgressMonitor monitor) {
-                    try {
-                        sessionGroup.createSession(dialog.getParameters(), monitor);
-                    } catch (ExecutionException e) {
-                        return new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.TraceControl_CreateSessionFailure, e);
-                    }
-                    return Status.OK_STATUS;
-                }
-            };
-            job.setUser(true);
-            job.schedule();
-        } finally {
-            fLock.unlock();
-        }
-        return null;
-    }
-
-    @Override
-    public boolean isEnabled() {
-
-        // Get workbench page for the Control View
-        IWorkbenchPage page = getWorkbenchPage();
-        if (page == null) {
-            return false;
-        }
-
-        TraceSessionGroup sessionGroup = null;
-
-        // Check if the session group project is selected
-        ISelection selection = page.getSelection(ControlView.ID);
-        if (selection instanceof StructuredSelection) {
-            Object element = ((StructuredSelection) selection).getFirstElement();
-            sessionGroup = (element instanceof TraceSessionGroup) ? (TraceSessionGroup) element : null;
-        }
-
-        boolean isEnabled = sessionGroup != null;
-        fLock.lock();
-        try {
-            fSessionGroup = null;
-            if(isEnabled) {
-                fSessionGroup = sessionGroup;
-            }
-        } finally {
-            fLock.unlock();
-        }
-        return isEnabled;
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/DeleteHandler.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/DeleteHandler.java
deleted file mode 100644 (file)
index 3687c50..0000000
+++ /dev/null
@@ -1,56 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
-
-import org.eclipse.core.commands.ExecutionEvent;
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TargetNodeState;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
-
-/**
- * <p>
- * Command handler implementation to delete a target host.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class DeleteHandler extends BaseNodeHandler {
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    public Object execute(ExecutionEvent event) throws ExecutionException {
-        fLock.lock();
-        try {
-            ITraceControlComponent root = fTargetNode.getParent();
-            fTargetNode.removeAllChildren();
-            root.removeChild(fTargetNode);
-        } finally {
-            fLock.unlock();
-        }
-        return null;
-    }
-
-    @Override
-    public boolean isEnabled() {
-        boolean isEnabled = false;
-        fLock.lock();
-        try {
-           isEnabled = (super.isEnabled() && (fTargetNode.getTargetNodeState() == TargetNodeState.DISCONNECTED));
-        } finally {
-            fLock.unlock();
-        }
-        return isEnabled;
-     }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/DestroySessionHandler.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/DestroySessionHandler.java
deleted file mode 100644 (file)
index b9c040a..0000000
+++ /dev/null
@@ -1,129 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
-
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.core.commands.ExecutionEvent;
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.core.runtime.jobs.Job;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.IConfirmDialog;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.TraceControlDialogFactory;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionGroup;
-import org.eclipse.ui.IWorkbenchPage;
-import org.eclipse.ui.IWorkbenchWindow;
-import org.eclipse.ui.PlatformUI;
-
-/**
- * <p>
- * Command handler implementation to destroy one or more trace sessions.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class DestroySessionHandler extends BaseControlViewHandler {
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-    /**
-     * The list of session components the command is to be executed on.
-     */
-    private final List<TraceSessionComponent> fSessions = new ArrayList<>();
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    public Object execute(ExecutionEvent event) throws ExecutionException {
-
-        IWorkbenchWindow window = PlatformUI.getWorkbench().getActiveWorkbenchWindow();
-
-        if (window == null) {
-            return false;
-        }
-        // Get user confirmation
-        IConfirmDialog dialog = TraceControlDialogFactory.getInstance().getConfirmDialog();
-        if (!dialog.openConfirm(window.getShell(),
-                Messages.TraceControl_DestroyConfirmationTitle,
-                Messages.TraceControl_DestroyConfirmationMessage)) {
-
-            return null;
-        }
-
-        Job job = new Job(Messages.TraceControl_DestroySessionJob) {
-            @Override
-            protected IStatus run(IProgressMonitor monitor) {
-                try {
-                    // Make a copy of the list of sessions to avoid ConcurrentModificationException when iterating
-                    // over fSessions, since fSessions is modified in another thread triggered by the tree viewer refresh
-                    // after removing a session.
-                    TraceSessionComponent[] sessions = fSessions.toArray(new TraceSessionComponent[fSessions.size()]);
-
-                    for (int i = 0; i < sessions.length; i++) {
-                        // Destroy all selected sessions
-                        TraceSessionComponent session = sessions[i];
-                        TraceSessionGroup sessionGroup = (TraceSessionGroup)session.getParent();
-                        sessionGroup.destroySession(session, monitor);
-                    }
-                } catch (ExecutionException e) {
-                    return new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.TraceControl_DestroySessionFailure, e);
-                }
-                return Status.OK_STATUS;
-            }
-        };
-        job.setUser(true);
-        job.schedule();
-
-        return null;
-    }
-
-    @Override
-    public boolean isEnabled() {
-        // Get workbench page for the Control View
-        IWorkbenchPage page = getWorkbenchPage();
-        if (page == null) {
-            return false;
-        }
-        fSessions.clear();
-
-        // Check if one or more session are selected
-        ISelection selection = page.getSelection(ControlView.ID);
-        if (selection instanceof StructuredSelection) {
-            StructuredSelection structered = ((StructuredSelection) selection);
-            for (Iterator<?> iterator = structered.iterator(); iterator.hasNext();) {
-                Object element = iterator.next();
-                if (element instanceof TraceSessionComponent) {
-                    // Add only TraceSessionComponents that are inactive and not destroyed
-                    TraceSessionComponent session = (TraceSessionComponent) element;
-                    if ((session.getSessionState() == TraceSessionState.INACTIVE) && (!session.isDestroyed())) {
-                        fSessions.add((TraceSessionComponent)element);
-                    }
-                }
-            }
-        }
-        return !fSessions.isEmpty();
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/DisableChannelHandler.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/DisableChannelHandler.java
deleted file mode 100644 (file)
index c7a821b..0000000
+++ /dev/null
@@ -1,47 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
-
-import java.util.List;
-
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEnablement;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent;
-
-/**
- * <p>
- * Command handler implementation to disable one or more trace channels per session and domain.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class DisableChannelHandler extends ChangeChannelStateHandler {
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    @Override
-    protected TraceEnablement getNewState() {
-        return TraceEnablement.DISABLED;
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    protected void changeState(TraceDomainComponent domain, List<String> channelNames, IProgressMonitor monitor) throws ExecutionException {
-        domain.disableChannels(channelNames, monitor);
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/DisableEventHandler.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/DisableEventHandler.java
deleted file mode 100644 (file)
index 8071eba..0000000
+++ /dev/null
@@ -1,47 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
-
-import java.util.List;
-
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEnablement;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent;
-
-/**
- * <p>
- * Command handler implementation to disable one or more events session, domain and channel.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class DisableEventHandler extends ChangeEventStateHandler {
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    @Override
-    protected TraceEnablement getNewState() {
-        return TraceEnablement.DISABLED;
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    protected void changeState(TraceChannelComponent channel, List<String> eventNames, IProgressMonitor monitor) throws ExecutionException{
-        channel.disableEvent(eventNames, monitor);
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/DisconnectHandler.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/DisconnectHandler.java
deleted file mode 100644 (file)
index b3d6d66..0000000
+++ /dev/null
@@ -1,53 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
-
-import org.eclipse.core.commands.ExecutionEvent;
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TargetNodeState;
-
-/**
- * <p>
- * Command handler implementation to disconnect from a target host.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class DisconnectHandler extends BaseNodeHandler {
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    public Object execute(ExecutionEvent event) throws ExecutionException {
-        fLock.lock();
-        try {
-            fTargetNode.disconnect();
-        } finally {
-            fLock.unlock();
-        }
-        return null;
-    }
-
-    @Override
-    public boolean isEnabled() {
-        boolean isEnabled = false;
-        fLock.lock();
-        try {
-           isEnabled = super.isEnabled() && (fTargetNode.getTargetNodeState() == TargetNodeState.CONNECTED);
-        } finally {
-            fLock.unlock();
-        }
-        return isEnabled;
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/DomainCommandParameter.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/DomainCommandParameter.java
deleted file mode 100644 (file)
index 270006b..0000000
+++ /dev/null
@@ -1,66 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
-
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
-
-/**
- * Class containing parameter for the command execution.
- *
- *  @author Bernd Hufmann
- */
-public class DomainCommandParameter extends CommandParameter {
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-
-    private TraceDomainComponent fDomain;
-
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-
-    /**
-     * Constructor
-     * @param session - a trace session component.
-     * @param domain - a trace domain component
-     */
-    public DomainCommandParameter(TraceSessionComponent session, TraceDomainComponent domain) {
-        super(session);
-        fDomain = domain;
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    /**
-     * @return the trace domain component
-     */
-    public TraceDomainComponent getDomain() {
-        return fDomain;
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    public DomainCommandParameter clone() {
-        DomainCommandParameter clone = (DomainCommandParameter) super.clone();
-        clone.fDomain = fDomain;
-        return clone;
-    }
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/EnableChannelHandler.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/EnableChannelHandler.java
deleted file mode 100644 (file)
index 97d050d..0000000
+++ /dev/null
@@ -1,47 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
-
-import java.util.List;
-
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEnablement;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent;
-
-/**
- * <p>
- * Command handler implementation to enable one or more trace channels per session and domain.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class EnableChannelHandler extends ChangeChannelStateHandler {
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    @Override
-    protected TraceEnablement getNewState() {
-        return TraceEnablement.ENABLED;
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    protected void changeState(TraceDomainComponent domain, List<String> channelNames, IProgressMonitor monitor) throws ExecutionException {
-        domain.enableChannels(channelNames, null, monitor);
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/EnableChannelOnDomainHandler.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/EnableChannelOnDomainHandler.java
deleted file mode 100644 (file)
index 4d65480..0000000
+++ /dev/null
@@ -1,105 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
-
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IChannelInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
-import org.eclipse.ui.IWorkbenchPage;
-
-/**
- * <p>
- * Command handler implementation to enable a trace channel for known domain.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class EnableChannelOnDomainHandler extends BaseEnableChannelHandler {
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    public void enableChannel(CommandParameter param, List<String> channelNames, IChannelInfo info, boolean isKernel, IProgressMonitor monitor) throws ExecutionException {
-        if (param instanceof DomainCommandParameter) {
-            ((DomainCommandParameter)param).getDomain().enableChannels(channelNames, info, monitor);
-        }
-    }
-
-    @Override
-    public TraceDomainComponent getDomain(CommandParameter param) {
-        if (param instanceof DomainCommandParameter) {
-            return ((DomainCommandParameter)param).getDomain();
-        }
-        return null;
-    }
-
-    @Override
-    public boolean isEnabled() {
-
-        // Get workbench page for the Control View
-        IWorkbenchPage page = getWorkbenchPage();
-        if (page == null) {
-            return false;
-        }
-
-        TraceDomainComponent domain = null;
-        TraceSessionComponent session = null;
-
-        // Check if one domain is selected
-        ISelection selection = page.getSelection(ControlView.ID);
-        if (selection instanceof StructuredSelection) {
-            StructuredSelection structered = ((StructuredSelection) selection);
-            for (Iterator<?> iterator = structered.iterator(); iterator.hasNext();) {
-                Object element = iterator.next();
-                if (element instanceof TraceDomainComponent) {
-                    TraceDomainComponent tmpDomain = (TraceDomainComponent) element;
-                    session = (TraceSessionComponent) tmpDomain.getParent();
-
-                    // Add only TraceDomainComponent whose TraceSessionComponent parent is inactive and not destroyed
-                    if ((session.getSessionState() == TraceSessionState.INACTIVE) && (!session.isDestroyed())) {
-                        domain = tmpDomain;
-                    }
-                }
-            }
-        }
-
-        boolean isEnabled = domain != null;
-
-        fLock.lock();
-        try {
-            fParam = null;
-            if (isEnabled) {
-                fParam = new DomainCommandParameter(session, domain);
-            }
-        } finally {
-            fLock.unlock();
-        }
-
-        return isEnabled;
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/EnableChannelOnSessionHandler.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/EnableChannelOnSessionHandler.java
deleted file mode 100644 (file)
index 8620945..0000000
+++ /dev/null
@@ -1,94 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
-
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IChannelInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
-import org.eclipse.ui.IWorkbenchPage;
-
-/**
- * <p>
- * Command handler implementation to enable a trace channel for unknown domain
- * (on session level).
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class EnableChannelOnSessionHandler extends BaseEnableChannelHandler {
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-
-    @Override
-    public void enableChannel(CommandParameter param, List<String> channelNames, IChannelInfo info, boolean isKernel, IProgressMonitor monitor) throws ExecutionException {
-        param.getSession().enableChannels(channelNames, info, isKernel, monitor);
-    }
-
-    @Override
-    public TraceDomainComponent getDomain(CommandParameter param) {
-        return null;
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    public boolean isEnabled() {
-        // Get workbench page for the Control View
-        IWorkbenchPage page = getWorkbenchPage();
-        if (page == null) {
-            return false;
-        }
-
-        TraceSessionComponent session = null;
-        // Check if one session is selected
-        ISelection selection = page.getSelection(ControlView.ID);
-        if (selection instanceof StructuredSelection) {
-            StructuredSelection structered = ((StructuredSelection) selection);
-            for (Iterator<?> iterator = structered.iterator(); iterator.hasNext();) {
-                Object element = iterator.next();
-                if (element instanceof TraceSessionComponent) {
-                    // Add only TraceSessionComponents that are inactive and not destroyed
-                    TraceSessionComponent tmpSession = (TraceSessionComponent) element;
-                    if ((tmpSession.getSessionState() == TraceSessionState.INACTIVE) && (!tmpSession.isDestroyed())) {
-                        session = tmpSession;
-                    }
-                }
-            }
-        }
-        boolean isEnabled = session != null;
-
-        fLock.lock();
-        try {
-            fParam = null;
-            if (isEnabled) {
-                fParam = new CommandParameter(session);
-            }
-        } finally {
-            fLock.unlock();
-        }
-
-        return isEnabled;
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/EnableEventHandler.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/EnableEventHandler.java
deleted file mode 100644 (file)
index 6d2cda0..0000000
+++ /dev/null
@@ -1,47 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
-
-import java.util.List;
-
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEnablement;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent;
-
-/**
- * <p>
- * Command handler implementation to enable one or more events session, domain and channel.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class EnableEventHandler extends ChangeEventStateHandler {
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    @Override
-    protected TraceEnablement getNewState() {
-        return TraceEnablement.ENABLED;
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    protected void changeState(TraceChannelComponent channel, List<String> eventNames, IProgressMonitor monitor) throws ExecutionException{
-        channel.enableEvents(eventNames, monitor);
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/EnableEventOnChannelHandler.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/EnableEventOnChannelHandler.java
deleted file mode 100644 (file)
index 9da2dc0..0000000
+++ /dev/null
@@ -1,122 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
-
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.LogLevelType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
-import org.eclipse.ui.IWorkbenchPage;
-
-/**
- * <p>
- * Command handler implementation to enable events for a known channel.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class EnableEventOnChannelHandler extends BaseEnableEventHandler {
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    public void enableEvents(CommandParameter param, List<String> eventNames, boolean isKernel, String filterExression, IProgressMonitor monitor) throws ExecutionException {
-        if (param instanceof ChannelCommandParameter) {
-            ((ChannelCommandParameter)param).getChannel().enableEvents(eventNames, filterExression, monitor);
-        }
-    }
-
-    @Override
-    public void enableSyscalls(CommandParameter param, IProgressMonitor monitor) throws ExecutionException {
-        if (param instanceof ChannelCommandParameter) {
-            ((ChannelCommandParameter)param).getChannel().enableSyscalls(monitor);
-        }
-    }
-
-    @Override
-    public void enableProbe(CommandParameter param, String eventName, boolean isFunction, String probe, IProgressMonitor monitor) throws ExecutionException {
-        if (param instanceof ChannelCommandParameter) {
-            ((ChannelCommandParameter)param).getChannel().enableProbe(eventName, isFunction, probe, monitor);
-        }
-    }
-
-    @Override
-    public void enableLogLevel(CommandParameter param, String eventName, LogLevelType logLevelType, TraceLogLevel level, String filterExression, IProgressMonitor monitor) throws ExecutionException {
-        if (param instanceof ChannelCommandParameter) {
-            ((ChannelCommandParameter)param).getChannel().enableLogLevel(eventName, logLevelType, level, filterExression, monitor);
-        }
-    }
-
-    @Override
-    public TraceDomainComponent getDomain(CommandParameter param) {
-        if (param instanceof ChannelCommandParameter) {
-            return (TraceDomainComponent) ((ChannelCommandParameter)param).getChannel().getParent();
-        }
-        return null;
-    }
-
-    @Override
-    public boolean isEnabled() {
-        // Get workbench page for the Control View
-        IWorkbenchPage page = getWorkbenchPage();
-        if (page == null) {
-            return false;
-        }
-
-        TraceChannelComponent channel = null;
-        TraceSessionComponent session = null;
-        ISelection selection = page.getSelection(ControlView.ID);
-        if (selection instanceof StructuredSelection) {
-            StructuredSelection structered = ((StructuredSelection) selection);
-            for (Iterator<?> iterator = structered.iterator(); iterator.hasNext();) {
-                Object element = iterator.next();
-                if (element instanceof TraceChannelComponent) {
-                    // Add only if corresponding TraceSessionComponents is inactive and not destroyed
-                    TraceChannelComponent tmpChannel = (TraceChannelComponent) element;
-                    session = tmpChannel.getSession();
-                    if(!session.isDestroyed()) {
-                        channel = tmpChannel;
-                    }
-                }
-            }
-        }
-
-        boolean isEnabled = (channel != null);
-        fLock.lock();
-        try {
-            fParam = null;
-            if(isEnabled) {
-                fParam = new ChannelCommandParameter(session, channel);
-            }
-        } finally {
-            fLock.unlock();
-        }
-        return isEnabled;
-    }
-}
-
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/EnableEventOnDomainHandler.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/EnableEventOnDomainHandler.java
deleted file mode 100644 (file)
index b766ebb..0000000
+++ /dev/null
@@ -1,118 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
-
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.LogLevelType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
-import org.eclipse.ui.IWorkbenchPage;
-
-/**
- * <p>
- * Command handler implementation to enable events for a known domain and default channel 'channel0'
- * (which will be created if doesn't exist).
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class EnableEventOnDomainHandler extends BaseEnableEventHandler {
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    public void enableEvents(CommandParameter param, List<String> eventNames, boolean isKernel, String filterExression, IProgressMonitor monitor) throws ExecutionException {
-        if (param instanceof DomainCommandParameter) {
-            ((DomainCommandParameter)param).getDomain().enableEvents(eventNames, monitor);
-        }
-    }
-
-    @Override
-    public void enableSyscalls(CommandParameter param, IProgressMonitor monitor) throws ExecutionException {
-        if (param instanceof DomainCommandParameter) {
-            ((DomainCommandParameter)param).getDomain().enableSyscalls(monitor);
-        }
-    }
-
-    @Override
-    public void enableProbe(CommandParameter param, String eventName, boolean isFunction, String probe, IProgressMonitor monitor) throws ExecutionException {
-        if (param instanceof DomainCommandParameter) {
-            ((DomainCommandParameter)param).getDomain().enableProbe(eventName, isFunction, probe, monitor);
-        }
-    }
-
-    @Override
-    public void enableLogLevel(CommandParameter param, String eventName, LogLevelType logLevelType, TraceLogLevel level, String filterExression, IProgressMonitor monitor) throws ExecutionException {
-        if (param instanceof DomainCommandParameter) {
-            ((DomainCommandParameter)param).getDomain().enableLogLevel(eventName, logLevelType, level, filterExression, monitor);
-        }
-    }
-
-    @Override
-    public TraceDomainComponent getDomain(CommandParameter param) {
-        if (param instanceof DomainCommandParameter) {
-            return ((DomainCommandParameter)param).getDomain();
-        }
-        return null;
-    }
-
-    @Override
-    public boolean isEnabled() {
-        // Get workbench page for the Control View
-        IWorkbenchPage page = getWorkbenchPage();
-        if (page == null) {
-            return false;
-        }
-
-        TraceDomainComponent domain = null;
-        TraceSessionComponent session = null;
-        ISelection selection = page.getSelection(ControlView.ID);
-        if (selection instanceof StructuredSelection) {
-            StructuredSelection structered = ((StructuredSelection) selection);
-            for (Iterator<?> iterator = structered.iterator(); iterator.hasNext();) {
-                Object element = iterator.next();
-                if (element instanceof TraceDomainComponent) {
-                    // Add only if corresponding TraceSessionComponents is inactive and not destroyed
-                    TraceDomainComponent tmpDomain = (TraceDomainComponent) element;
-                    session = tmpDomain.getSession();
-                    if(session.getSessionState() == TraceSessionState.INACTIVE && !session.isDestroyed()) {
-                        domain = tmpDomain;
-                    }
-                }
-            }
-        }
-
-        boolean isEnabled = (domain != null);
-        fLock.lock();
-        try {
-            fParam = null;
-            if(isEnabled) {
-                fParam = new DomainCommandParameter(session, domain);
-            }
-        } finally {
-            fLock.unlock();
-        }
-        return isEnabled;
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/EnableEventOnSessionHandler.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/EnableEventOnSessionHandler.java
deleted file mode 100644 (file)
index c28578c..0000000
+++ /dev/null
@@ -1,109 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
-
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.LogLevelType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
-import org.eclipse.ui.IWorkbenchPage;
-
-/**
- * <p>
- * Command handler implementation to enable events for a known session and default channel 'channel0'
- * (which will be created if doesn't exist).
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class EnableEventOnSessionHandler extends BaseEnableEventHandler {
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-
-    //-------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    public void enableEvents(CommandParameter param, List<String> eventNames, boolean isKernel, String filterExpression, IProgressMonitor monitor) throws ExecutionException {
-        param.getSession().enableEvents(eventNames, isKernel, filterExpression, monitor);
-    }
-
-    @Override
-    public void enableSyscalls(CommandParameter param, IProgressMonitor monitor) throws ExecutionException {
-        param.getSession().enableSyscalls(monitor);
-    }
-
-    @Override
-    public void enableProbe(CommandParameter param, String eventName, boolean isFunction, String probe, IProgressMonitor monitor) throws ExecutionException {
-        param.getSession().enableProbe(eventName, isFunction, probe, monitor);
-    }
-
-    @Override
-    public void enableLogLevel(CommandParameter param, String eventName, LogLevelType logLevelType, TraceLogLevel level, String filterExpression, IProgressMonitor monitor) throws ExecutionException {
-        param.getSession().enableLogLevel(eventName, logLevelType, level, filterExpression, monitor);
-    }
-
-    @Override
-    public TraceDomainComponent getDomain(CommandParameter param) {
-        return null;
-    }
-
-    @Override
-    public boolean isEnabled() {
-        // Get workbench page for the Control View
-        IWorkbenchPage page = getWorkbenchPage();
-        if (page == null) {
-            return false;
-        }
-
-        TraceSessionComponent session = null;
-        // Check if one session is selected
-        ISelection selection = page.getSelection(ControlView.ID);
-        if (selection instanceof StructuredSelection) {
-            StructuredSelection structered = ((StructuredSelection) selection);
-            for (Iterator<?> iterator = structered.iterator(); iterator.hasNext();) {
-                Object element = iterator.next();
-                if (element instanceof TraceSessionComponent) {
-                    // Add only if corresponding TraceSessionComponents is inactive and not destroyed
-                    TraceSessionComponent tmpSession = (TraceSessionComponent) element;
-                    if(tmpSession.getSessionState() == TraceSessionState.INACTIVE && !tmpSession.isDestroyed()) {
-                        session = tmpSession;
-                    }
-                }
-            }
-        }
-        boolean isEnabled = (session != null);
-        fLock.lock();
-        try {
-            fParam = null;
-            if(isEnabled) {
-                fParam = new CommandParameter(session);
-            }
-        } finally {
-            fLock.unlock();
-        }
-        return isEnabled;
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/EventCommandParameter.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/EventCommandParameter.java
deleted file mode 100644 (file)
index df00f23..0000000
+++ /dev/null
@@ -1,65 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
-
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceEventComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
-
-/**
- * Class containing parameter for a command execution.
- *
- * @author Bernd Hufmann
- */
-public class EventCommandParameter extends CommandParameter {
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-
-    private TraceEventComponent fEvent;
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-
-    /**
-     * Constructor
-     * @param session - a trace session component.
-     * @param event - a trace event component
-     */
-    public EventCommandParameter(TraceSessionComponent session, TraceEventComponent event) {
-        super(session);
-        fEvent = event;
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    /**
-     * @return the trace event component
-     */
-    public TraceEventComponent getEvent() {
-        return fEvent;
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    public EventCommandParameter clone() {
-        EventCommandParameter clone = (EventCommandParameter) super.clone();
-        clone.fEvent = fEvent;
-        return clone;
-    }
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/ExecuteCommandScriptHandler.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/ExecuteCommandScriptHandler.java
deleted file mode 100644 (file)
index 03de199..0000000
+++ /dev/null
@@ -1,116 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
-
-import org.eclipse.core.commands.ExecutionEvent;
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.core.runtime.jobs.Job;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.jface.window.Window;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.ISelectCommandScriptDialog;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.TraceControlDialogFactory;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionGroup;
-import org.eclipse.ui.IWorkbenchPage;
-
-/**
- * <p>
- * Command handler implementation to execute commands of a command script.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class ExecuteCommandScriptHandler extends BaseControlViewHandler {
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-
-    /**
-     * The trace session group the command is to be executed on.
-     */
-    private TraceSessionGroup fSessionGroup = null;
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    public Object execute(ExecutionEvent event) throws ExecutionException {
-
-        fLock.lock();
-        try {
-            final TraceSessionGroup sessionGroup = fSessionGroup;
-
-            // Open dialog box for the node name and address
-            final ISelectCommandScriptDialog dialog = TraceControlDialogFactory.getInstance().getCommandScriptDialog();
-
-            if (dialog.open() != Window.OK) {
-                return null;
-            }
-
-            Job job = new Job(Messages.TraceControl_ExecuteScriptJob) {
-                @Override
-                protected IStatus run(IProgressMonitor monitor) {
-                    try {
-                        sessionGroup.executeCommands(monitor, dialog.getCommands());
-                    } catch (ExecutionException e) {
-                        return new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.TraceControl_CreateSessionFailure, e);
-                    }
-                    return Status.OK_STATUS;
-                }
-            };
-            job.setUser(true);
-            job.schedule();
-        } finally {
-            fLock.unlock();
-        }
-        return null;
-    }
-
-    @Override
-    public boolean isEnabled() {
-
-        // Get workbench page for the Control View
-        IWorkbenchPage page = getWorkbenchPage();
-        if (page == null) {
-            return false;
-        }
-
-        TraceSessionGroup sessionGroup = null;
-
-        // Check if the session group project is selected
-        ISelection selection = page.getSelection(ControlView.ID);
-        if (selection instanceof StructuredSelection) {
-            Object element = ((StructuredSelection) selection).getFirstElement();
-            sessionGroup = (element instanceof TraceSessionGroup) ? (TraceSessionGroup) element : null;
-        }
-
-        boolean isEnabled = sessionGroup != null;
-        fLock.lock();
-        try {
-            fSessionGroup = null;
-            if(isEnabled) {
-                fSessionGroup = sessionGroup;
-            }
-        } finally {
-            fLock.unlock();
-        }
-        return isEnabled;
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/ImportHandler.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/ImportHandler.java
deleted file mode 100644 (file)
index 2673c43..0000000
+++ /dev/null
@@ -1,410 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Bernd Hufmann - Updated for support of streamed traces
- *   Patrick Tasse - Add support for source location
- *   Markus Schorn - Bug 448058: Use org.eclipse.remote in favor of RSE
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
-
-import java.io.FileOutputStream;
-import java.io.IOException;
-import java.io.InputStream;
-import java.io.OutputStream;
-import java.net.URI;
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.core.commands.ExecutionEvent;
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.core.filesystem.EFS;
-import org.eclipse.core.filesystem.IFileInfo;
-import org.eclipse.core.filesystem.IFileStore;
-import org.eclipse.core.resources.IFolder;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.resources.ResourcesPlugin;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.MultiStatus;
-import org.eclipse.core.runtime.NullProgressMonitor;
-import org.eclipse.core.runtime.Path;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.core.runtime.SubMonitor;
-import org.eclipse.core.runtime.URIUtil;
-import org.eclipse.core.runtime.jobs.Job;
-import org.eclipse.jface.dialogs.MessageDialogWithToggle;
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.jface.window.Window;
-import org.eclipse.jface.wizard.WizardDialog;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.relayd.LttngRelaydConnectionInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.relayd.LttngRelaydConnectionManager;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.relayd.LttngRelaydConsumer;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.IImportDialog;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.ImportFileInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.TraceControlDialogFactory;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
-import org.eclipse.tracecompass.internal.tmf.ui.project.wizards.importtrace.ImportTraceWizard;
-import org.eclipse.tracecompass.tmf.core.TmfCommonConstants;
-import org.eclipse.tracecompass.tmf.core.project.model.TmfTraceImportException;
-import org.eclipse.tracecompass.tmf.core.project.model.TraceTypeHelper;
-import org.eclipse.tracecompass.tmf.ctf.core.CtfConstants;
-import org.eclipse.tracecompass.tmf.ui.project.model.TmfOpenTraceHelper;
-import org.eclipse.tracecompass.tmf.ui.project.model.TmfProjectElement;
-import org.eclipse.tracecompass.tmf.ui.project.model.TmfProjectRegistry;
-import org.eclipse.tracecompass.tmf.ui.project.model.TmfTraceElement;
-import org.eclipse.tracecompass.tmf.ui.project.model.TmfTraceFolder;
-import org.eclipse.tracecompass.tmf.ui.project.model.TmfTraceTypeUIUtils;
-import org.eclipse.tracecompass.tmf.ui.project.model.TmfTracesFolder;
-import org.eclipse.tracecompass.tmf.ui.project.model.TraceUtils;
-import org.eclipse.ui.IWorkbenchPage;
-import org.eclipse.ui.IWorkbenchWindow;
-import org.eclipse.ui.PlatformUI;
-
-/**
- * <p>
- * Command handler implementation to import traces from a (remote) session to a
- * tracing project.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class ImportHandler extends BaseControlViewHandler {
-
-    private static final int BUFFER_IN_KB = 16;
-
-    private static final int BYTES_PER_KB = 1024;
-
-    // ------------------------------------------------------------------------
-    // Constants
-    // ------------------------------------------------------------------------
-    /** Name of default project to import traces to */
-    public static final String DEFAULT_REMOTE_PROJECT_NAME = "Remote"; //$NON-NLS-1$
-
-    /** The preference key to remeber whether or not the user wants the notification shown next time **/
-    private static final String NOTIFY_IMPORT_STREAMED_PREF_KEY = "NOTIFY_IMPORT_STREAMED"; //$NON-NLS-1$
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-
-    /**
-     * The command parameter
-     */
-    protected CommandParameter fParam;
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    public Object execute(ExecutionEvent event) throws ExecutionException {
-
-        IWorkbenchWindow window = PlatformUI.getWorkbench().getActiveWorkbenchWindow();
-
-        if (window == null) {
-            return false;
-        }
-
-        fLock.lock();
-        try {
-            final CommandParameter param = fParam.clone();
-
-            // create default project
-            IProject project = TmfProjectRegistry.createProject(DEFAULT_REMOTE_PROJECT_NAME, null, null);
-
-            if (param.getSession().isLiveTrace()) {
-                importLiveTrace(new LttngRelaydConnectionInfo(param.getSession().getLiveUrl(), param.getSession().getLivePort(), param.getSession().getName()), project);
-                return null;
-            } else if (param.getSession().isStreamedTrace()) {
-
-                IPreferenceStore store = Activator.getDefault().getPreferenceStore();
-                String notify = store.getString(NOTIFY_IMPORT_STREAMED_PREF_KEY);
-                if (!MessageDialogWithToggle.ALWAYS.equals(notify)) {
-                    MessageDialogWithToggle.openInformation(window.getShell(), null, Messages.TraceControl_ImportDialogStreamedTraceNotification, Messages.TraceControl_ImportDialogStreamedTraceNotificationToggle, false, store, NOTIFY_IMPORT_STREAMED_PREF_KEY);
-                }
-
-                // Streamed trace
-                TmfProjectElement projectElement = TmfProjectRegistry.getProject(project, true);
-                TmfTraceFolder traceFolder = projectElement.getTracesFolder();
-
-                ImportTraceWizard wizard = new ImportTraceWizard();
-                wizard.init(PlatformUI.getWorkbench(), new StructuredSelection(traceFolder));
-                WizardDialog dialog = new WizardDialog(window.getShell(), wizard);
-                dialog.open();
-                return null;
-            }
-
-            // Remote trace
-            final IImportDialog dialog = TraceControlDialogFactory.getInstance().getImportDialog();
-            dialog.setSession(param.getSession());
-            dialog.setDefaultProject(DEFAULT_REMOTE_PROJECT_NAME);
-
-            if (dialog.open() != Window.OK) {
-                return null;
-            }
-
-            Job job = new Job(Messages.TraceControl_ImportJob) {
-                @Override
-                protected IStatus run(IProgressMonitor monitor) {
-
-                    MultiStatus status = new MultiStatus(Activator.PLUGIN_ID, IStatus.OK, Messages.TraceControl_ImportFailure, null);
-                    List<ImportFileInfo> traces = dialog.getTracePathes();
-                    IProject selectedProject = dialog.getProject();
-                    for (Iterator<ImportFileInfo> iterator = traces.iterator(); iterator.hasNext();) {
-                        try {
-
-                            if (monitor.isCanceled()) {
-                                status.add(Status.CANCEL_STATUS);
-                                break;
-                            }
-
-                            ImportFileInfo remoteFile = iterator.next();
-
-                            downloadTrace(remoteFile, selectedProject, monitor);
-
-                            // Set trace type
-                            IFolder traceFolder = remoteFile.getDestinationFolder();
-
-                            IResource file = traceFolder.findMember(remoteFile.getLocalTraceName());
-
-                            if (file != null) {
-                                TraceTypeHelper helper = null;
-
-                                try {
-                                    helper = TmfTraceTypeUIUtils.selectTraceType(file.getLocation().toOSString(), null, null);
-                                } catch (TmfTraceImportException e) {
-                                    // the trace did not match any trace type
-                                }
-
-                                if (helper != null) {
-                                    status.add(TmfTraceTypeUIUtils.setTraceType(file, helper));
-                                }
-
-                                URI uri = remoteFile.getImportFile().toURI();
-                                String sourceLocation = URIUtil.toUnencodedString(uri);
-                                file.setPersistentProperty(TmfCommonConstants.SOURCE_LOCATION, sourceLocation);
-                            }
-                        } catch (ExecutionException e) {
-                            status.add(new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.TraceControl_ImportFailure, e));
-                        } catch (CoreException e) {
-                            status.add(new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.TraceControl_ImportFailure, e));
-                        }
-                    }
-                    return status;
-                }
-            };
-            job.setUser(true);
-            job.schedule();
-        } finally {
-            fLock.unlock();
-        }
-        return null;
-    }
-
-    @Override
-    public boolean isEnabled() {
-        // Get workbench page for the Control View
-        IWorkbenchPage page = getWorkbenchPage();
-        if (page == null) {
-            return false;
-        }
-
-        // Check if one or more session are selected
-        ISelection selection = page.getSelection(ControlView.ID);
-        TraceSessionComponent session = null;
-        if (selection instanceof StructuredSelection) {
-            StructuredSelection structered = ((StructuredSelection) selection);
-            for (Iterator<?> iterator = structered.iterator(); iterator.hasNext();) {
-                Object element = iterator.next();
-                if (element instanceof TraceSessionComponent) {
-                    // Add only TraceSessionComponents that are inactive and not
-                    // destroyed
-                    TraceSessionComponent tmpSession = (TraceSessionComponent) element;
-                    if ((tmpSession.isSnapshotSession() || tmpSession.isLiveTrace() || (tmpSession.getSessionState() == TraceSessionState.INACTIVE)) && (!tmpSession.isDestroyed())) {
-                        session = tmpSession;
-                    }
-                }
-            }
-        }
-        boolean isEnabled = session != null;
-
-        fLock.lock();
-        try {
-            fParam = null;
-            if (isEnabled) {
-                fParam = new CommandParameter(session);
-            }
-        } finally {
-            fLock.unlock();
-        }
-        return isEnabled;
-    }
-
-    // ------------------------------------------------------------------------
-    // Helper methods
-    // ------------------------------------------------------------------------
-
-    /**
-     * Downloads a trace from the remote host to the given project.
-     *
-     * @param trace
-     *            - trace information of trace to import
-     * @param project
-     *            - project to import to
-     * @param monitor
-     *            - a progress monitor
-     * @throws ExecutionException
-     */
-    private static void downloadTrace(ImportFileInfo trace, IProject project, IProgressMonitor monitor)
-            throws ExecutionException {
-        try {
-            IFileStore importRoot = trace.getImportFile();
-
-            IFolder traceFolder = project.getFolder(TmfTracesFolder.TRACES_FOLDER_NAME);
-            if (!traceFolder.exists()) {
-                throw new ExecutionException(Messages.TraceControl_ImportDialogInvalidTracingProject + " (" + TmfTracesFolder.TRACES_FOLDER_NAME + ")"); //$NON-NLS-1$//$NON-NLS-2$
-            }
-
-            IFolder destinationFolder = trace.getDestinationFolder();
-            TraceUtils.createFolder(destinationFolder, monitor);
-
-            String traceName = trace.getLocalTraceName();
-            IFolder folder = destinationFolder.getFolder(traceName);
-            if (folder.exists()) {
-                if (!trace.isOverwrite()) {
-                    throw new ExecutionException(Messages.TraceControl_ImportDialogTraceAlreadyExistError + ": " + traceName); //$NON-NLS-1$
-                }
-            } else {
-                folder.create(true, true, null);
-            }
-
-            IFileStore[] sources = importRoot.childStores(EFS.NONE, new NullProgressMonitor());
-            SubMonitor subMonitor = SubMonitor.convert(monitor, sources.length);
-            subMonitor.beginTask(Messages.TraceControl_DownloadTask, sources.length);
-
-            for (IFileStore source : sources) {
-                if (subMonitor.isCanceled()) {
-                    monitor.setCanceled(true);
-                    return;
-                }
-                SubMonitor childMonitor = subMonitor.newChild(1);
-                IFileInfo info = source.fetchInfo();
-                if (!info.isDirectory()) {
-                    IPath destination = folder.getLocation().addTrailingSeparator().append(source.getName());
-                    subMonitor.setTaskName(Messages.TraceControl_DownloadTask + ' ' + traceName + '/' + source.getName());
-                    try (InputStream in = source.openInputStream(EFS.NONE, new NullProgressMonitor())) {
-                        copy(in, destination, childMonitor, info.getLength());
-                    }
-                }
-            }
-        } catch (IOException e) {
-            throw new ExecutionException(e.toString(), e);
-        } catch (CoreException e) {
-            throw new ExecutionException(e.toString(), e);
-        }
-    }
-
-    private static void copy(InputStream in, IPath destination, SubMonitor monitor, long length) throws IOException {
-        try (OutputStream out = new FileOutputStream(destination.toFile())) {
-            monitor.setWorkRemaining((int) (length / BYTES_PER_KB));
-            byte[] buf = new byte[BYTES_PER_KB * BUFFER_IN_KB];
-            int counter = 0;
-            for (;;) {
-                int n = in.read(buf);
-                if (n <= 0) {
-                    return;
-                }
-                out.write(buf, 0, n);
-                counter = (counter % BYTES_PER_KB) + n;
-                monitor.worked(counter / BYTES_PER_KB);
-            }
-        }
-    }
-
-    private static void importLiveTrace(final LttngRelaydConnectionInfo connectionInfo, final IProject project) {
-        Job job = new Job(Messages.TraceControl_ImportJob) {
-
-            @Override
-            protected IStatus run(final IProgressMonitor monitor) {
-                try {
-                    // We initiate the connection first so that we can retrieve the trace path
-                    LttngRelaydConsumer lttngRelaydConsumer = LttngRelaydConnectionManager.getInstance().getConsumer(connectionInfo);
-                    try {
-                        lttngRelaydConsumer.connect();
-                    } catch (CoreException e) {
-                        return new Status(IStatus.ERROR, Activator.PLUGIN_ID, org.eclipse.tracecompass.internal.lttng2.control.ui.relayd.Messages.LttngRelaydConnectionManager_ConnectionError, e);
-                    }
-                    initializeTraceResource(connectionInfo, lttngRelaydConsumer.getTracePath(), project);
-                    return Status.OK_STATUS;
-                } catch (CoreException | TmfTraceImportException e) {
-                    return new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.ImportHandler_LiveTraceInitError, e);
-                }
-            }
-
-        };
-        job.setSystem(true);
-        job.schedule();
-    }
-
-
-    private static void initializeTraceResource(final LttngRelaydConnectionInfo connectionInfo, final String tracePath, final IProject project) throws CoreException, TmfTraceImportException {
-        IFolder folder = project.getFolder(TmfTracesFolder.TRACES_FOLDER_NAME);
-        IFolder traceFolder = folder.getFolder(connectionInfo.getSessionName());
-        Path location = new Path(tracePath);
-        IStatus result = ResourcesPlugin.getWorkspace().validateLinkLocation(folder, location);
-        if (result.isOK()) {
-            traceFolder.createLink(location, IResource.REPLACE, new NullProgressMonitor());
-        } else {
-            throw new CoreException(new Status(IStatus.ERROR, Activator.PLUGIN_ID, result.getMessage()));
-        }
-
-        TraceTypeHelper selectedTraceType = TmfTraceTypeUIUtils.selectTraceType(location.toOSString(), null, null);
-        // No trace type was determined.
-        TmfTraceTypeUIUtils.setTraceType(traceFolder, selectedTraceType);
-
-        final TmfProjectElement projectElement = TmfProjectRegistry.getProject(project, true);
-        final TmfTraceFolder tracesFolder = projectElement.getTracesFolder();
-        final List<TmfTraceElement> traces = tracesFolder.getTraces();
-        TmfTraceElement found = null;
-        for (TmfTraceElement candidate : traces) {
-            if (candidate.getName().equals(connectionInfo.getSessionName())) {
-                found = candidate;
-            }
-        }
-
-        if (found == null) {
-            throw new CoreException(new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.ImportHandler_LiveTraceElementError));
-        }
-
-        // Properties used to be able to reopen a trace in live mode
-        traceFolder.setPersistentProperty(CtfConstants.LIVE_HOST, connectionInfo.getHost());
-        traceFolder.setPersistentProperty(CtfConstants.LIVE_PORT, Integer.toString(connectionInfo.getPort()));
-        traceFolder.setPersistentProperty(CtfConstants.LIVE_SESSION_NAME, connectionInfo.getSessionName());
-
-        final TmfTraceElement finalTrace = found;
-        Display.getDefault().syncExec(new Runnable() {
-
-            @Override
-            public void run() {
-                TmfOpenTraceHelper.openTraceFromElement(finalTrace);
-            }
-        });
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/NewConnectionHandler.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/NewConnectionHandler.java
deleted file mode 100644 (file)
index 79dfdef..0000000
+++ /dev/null
@@ -1,149 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2015 Ericsson and others
- *
- * 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:
- *   Bernd Hufmann               - Initial API and implementation
- *   Anna Dushistova(Montavista) - [382684] Allow reusing already defined connections that have Files and Shells subsystems
- *   Markus Schorn - Bug 448058: Use org.eclipse.remote in favor of RSE
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
-
-import static org.eclipse.tracecompass.common.core.NonNullUtils.checkNotNull;
-
-import java.util.Map;
-
-import org.eclipse.core.commands.ExecutionEvent;
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.jface.window.Window;
-import org.eclipse.remote.core.IRemoteConnection;
-import org.eclipse.remote.core.IRemoteConnectionType;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.INewConnectionDialog;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.TraceControlDialogFactory;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent;
-import org.eclipse.tracecompass.tmf.remote.core.proxy.TmfRemoteConnectionFactory;
-import org.eclipse.ui.IWorkbenchPage;
-import org.eclipse.ui.IWorkbenchPart;
-import org.eclipse.ui.IWorkbenchWindow;
-import org.eclipse.ui.PlatformUI;
-
-/**
- * <p>
- * Command handler for creation of a new connection for trace control.
- * <br> By supplying arguments for the parameters with id {@link #PARAMETER_REMOTE_SERVICES_ID} and
- * {@link #PARAMETER_CONNECTION_NAME}, the caller can specify the remote connection that will
- * be added to the trace control. In case one of the optional arguments is not supplied, the handler
- * opens a dialog for selecting a remote connection.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class NewConnectionHandler extends BaseControlViewHandler {
-
-    /**
-     * Id of the parameter for the remote services id.
-     * @see NewConnectionHandler
-     * @see IRemoteConnectionType#getId()
-     */
-    public static final String PARAMETER_REMOTE_SERVICES_ID = "org.eclipse.linuxtools.lttng2.control.ui.remoteServicesIdParameter"; //$NON-NLS-1$
-    /**
-     * Id of the parameter for the name of the remote connection.
-     * @see NewConnectionHandler
-     * @see IRemoteConnection#getName()
-     */
-    public static final String PARAMETER_CONNECTION_NAME = "org.eclipse.linuxtools.lttng2.control.ui.connectionNameParameter"; //$NON-NLS-1$
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-
-    /**
-     * The parent trace control component the new node will be added to.
-     */
-    private ITraceControlComponent fRoot = null;
-
-    @Override
-    public Object execute(ExecutionEvent event) throws ExecutionException {
-        assert (fRoot != null);
-
-        IWorkbenchWindow window = PlatformUI.getWorkbench().getActiveWorkbenchWindow();
-        if (window == null) {
-            return false;
-        }
-
-        IRemoteConnection connection = getConnection(event.getParameters());
-        if (connection != null) {
-            fLock.lock();
-            try {
-                // successful creation of host
-                TargetNodeComponent node = null;
-                if (!fRoot.containsChild(connection.getName())) {
-                    node = new TargetNodeComponent(connection.getName(), fRoot, connection);
-                    fRoot.addChild(node);
-                } else {
-                    node = (TargetNodeComponent)fRoot.getChild(connection.getName());
-                }
-
-                node.connect();
-            } finally {
-                fLock.unlock();
-            }
-        }
-        return null;
-    }
-
-    private static IRemoteConnection getConnection(Map<?,?> parameters) {
-        // First check whether arguments have been supplied
-        Object remoteServicesId = parameters.get(PARAMETER_REMOTE_SERVICES_ID);
-        Object connectionName = parameters.get(PARAMETER_CONNECTION_NAME);
-        if ((remoteServicesId != null) && (connectionName != null)) {
-            return TmfRemoteConnectionFactory.getRemoteConnection(
-                    checkNotNull(remoteServicesId.toString()),
-                    checkNotNull(connectionName.toString()));
-        }
-
-        // Without the arguments, open dialog box for the node name and address
-        final INewConnectionDialog dialog = TraceControlDialogFactory.getInstance().getNewConnectionDialog();
-        if (dialog.open() == Window.OK) {
-            return dialog.getConnection();
-        }
-
-        return null;
-    }
-
-    @Override
-    public boolean isEnabled() {
-
-        // Get workbench page for the Control View
-        IWorkbenchPage page = getWorkbenchPage();
-        if (page == null) {
-            return false;
-        }
-
-        ITraceControlComponent root = null;
-
-        // no need to verify part because it has been already done in getWorkbenchPage()
-        IWorkbenchPart part = page.getActivePart();
-        root = ((ControlView) part).getTraceControlRoot();
-
-        boolean isEnabled = root != null;
-
-        fLock.lock();
-        try {
-            fRoot = null;
-            if (isEnabled) {
-                fRoot = root;
-            }
-        } finally {
-            fLock.unlock();
-        }
-
-        return isEnabled;
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/RefreshHandler.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/RefreshHandler.java
deleted file mode 100644 (file)
index 228acf4..0000000
+++ /dev/null
@@ -1,105 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
-
-import java.util.Iterator;
-
-import org.eclipse.core.commands.ExecutionEvent;
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TargetNodeState;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceControlComponent;
-import org.eclipse.ui.IWorkbenchPage;
-
-/**
- * <p>
- * Command handler implementation to refresh node configuration.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class RefreshHandler extends BaseControlViewHandler {
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-
-    /**
-     * The node component reference.
-     */
-    private TargetNodeComponent fNode;
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    public Object execute(ExecutionEvent event) throws ExecutionException {
-        fLock.lock();
-        try {
-            fNode.refresh();
-        } finally {
-            fLock.unlock();
-        }
-        return null;
-    }
-
-    @Override
-    public boolean isEnabled() {
-
-        // Get workbench page for the Control View
-        IWorkbenchPage page = getWorkbenchPage();
-        if (page == null) {
-            return false;
-        }
-
-        TargetNodeComponent node = null;
-        // Check if one or more session are selected
-        ISelection selection = page.getSelection(ControlView.ID);
-        if (selection instanceof StructuredSelection) {
-
-            StructuredSelection structered = ((StructuredSelection) selection);
-            for (Iterator<?> iterator = structered.iterator(); iterator.hasNext();) {
-                Object element = iterator.next();
-                if (element instanceof TraceControlComponent) {
-                    TraceControlComponent component = (TraceControlComponent) element;
-                    boolean isConnected = component.getTargetNodeState() == TargetNodeState.CONNECTED;
-                    if (isConnected) {
-                        while ((component != null) && component.getClass() != TargetNodeComponent.class) {
-                            component = (TraceControlComponent) component.getParent();
-                        }
-                        if (component != null) {
-                            node = (TargetNodeComponent) component;
-                        }
-                    }
-                }
-            }
-        }
-
-        boolean isEnabled = node != null;
-
-        fLock.lock();
-        try {
-            fNode = null;
-            if (isEnabled) {
-                fNode = node;
-            }
-        } finally {
-            fLock.unlock();
-        }
-
-        return isEnabled;
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/SnaphshotHandler.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/SnaphshotHandler.java
deleted file mode 100644 (file)
index 753b29e..0000000
+++ /dev/null
@@ -1,130 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2013, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
-
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.core.commands.ExecutionEvent;
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.MultiStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.core.runtime.jobs.Job;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
-import org.eclipse.ui.IWorkbenchPage;
-
-/**
- * <p>
- * Command handler implementation to record a snapshot.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class SnaphshotHandler extends BaseControlViewHandler {
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-    /**
-     * The list of session components the command is to be executed on.
-     */
-    protected List<TraceSessionComponent> fSessions = new ArrayList<>();
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    public Object execute(ExecutionEvent event) throws ExecutionException {
-        fLock.lock();
-        try {
-            // Make a copy for thread safety
-            final List<TraceSessionComponent> sessions = new ArrayList<>();
-            sessions.addAll(fSessions);
-
-            Job job = new Job(Messages.TraceControl_RecordSnapshotJob) {
-                @Override
-                protected IStatus run(IProgressMonitor monitor) {
-                    MultiStatus status = new MultiStatus(Activator.PLUGIN_ID, IStatus.OK, null, null);
-                    for (Iterator<TraceSessionComponent> iterator = sessions.iterator(); iterator.hasNext();) {
-                        try {
-                            // record snapshot for all selected sessions sequentially
-                            TraceSessionComponent session = iterator.next();
-                            session.recordSnapshot(monitor);
-                            if (monitor.isCanceled()) {
-                                status.add(Status.CANCEL_STATUS);
-                                break;
-                            }
-                        } catch (ExecutionException e) {
-                            status.add(new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.TraceControl_RecordSnapshotFailure, e));
-                        }
-                    }
-                    return status;
-                }
-            };
-            job.setUser(true);
-            job.schedule();
-        } finally {
-            fLock.unlock();
-        }
-        return null;
-    }
-
-    @Override
-    public boolean isEnabled() {
-        // Get workbench page for the Control View
-        IWorkbenchPage page = getWorkbenchPage();
-        if (page == null) {
-            return false;
-        }
-
-        List<TraceSessionComponent> sessions = new ArrayList<>(0);
-
-        // Check if one session is selected
-        ISelection selection = page.getSelection(ControlView.ID);
-        if (selection instanceof StructuredSelection) {
-            StructuredSelection structered = ((StructuredSelection) selection);
-            for (Iterator<?> iterator = structered.iterator(); iterator.hasNext();) {
-                Object element = iterator.next();
-                if (element instanceof TraceSessionComponent) {
-                    // Add only if corresponding TraceSessionComponent is an active snapshot session and not destroyed
-                    TraceSessionComponent session = (TraceSessionComponent) element;
-                    if(session.isSnapshotSession() &&
-                            session.getSessionState() == TraceSessionState.ACTIVE &&
-                            !session.isDestroyed()) {
-                        sessions.add(session);
-                    }
-                }
-            }
-        }
-        boolean isEnabled = !sessions.isEmpty();
-        fLock.lock();
-        try {
-            fSessions = null;
-            if (isEnabled) {
-                fSessions = sessions;
-            }
-        } finally {
-            fLock.unlock();
-        }
-        return isEnabled;
-    }
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/StartHandler.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/StartHandler.java
deleted file mode 100644 (file)
index f818d0d..0000000
+++ /dev/null
@@ -1,45 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
-
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
-
-/**
- * <p>
- * Command handler implementation to start one or more trace sessions.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class StartHandler extends ChangeSessionStateHandler {
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    @Override
-    public TraceSessionState getNewState() {
-        return TraceSessionState.ACTIVE;
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    public void changeState(TraceSessionComponent session, IProgressMonitor monitor) throws ExecutionException {
-        session.startSession(monitor);
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/StopHandler.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/StopHandler.java
deleted file mode 100644 (file)
index 7b15839..0000000
+++ /dev/null
@@ -1,45 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
-
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
-
-/**
- * <p>
- * Command handler implementation to stop one or more trace sessions.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class StopHandler extends ChangeSessionStateHandler {
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    @Override
-    public TraceSessionState getNewState() {
-        return TraceSessionState.INACTIVE;
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    public void changeState(TraceSessionComponent session, IProgressMonitor monitor) throws ExecutionException {
-        session.stopSession(monitor);
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/XmlMiValidationErrorHandler.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/handlers/XmlMiValidationErrorHandler.java
deleted file mode 100644 (file)
index 524368b..0000000
+++ /dev/null
@@ -1,49 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014 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:
- *   Jonathan Rajotte - Initial implementation
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers;
-
-import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.service.LTTngControlServiceMI;
-import org.xml.sax.ErrorHandler;
-import org.xml.sax.SAXException;
-import org.xml.sax.SAXParseException;
-
-/**
- * <p>
- * Error handler for xml xsd validation while using machine interface mode
- * in {@link LTTngControlServiceMI}.
- * </p>
- *
- * @author Jonathan Rajotte
- */
-public class XmlMiValidationErrorHandler implements ErrorHandler {
-
-    @Override
-    public void error(SAXParseException e) throws SAXException {
-        Activator.getDefault().logError(Messages.TraceControl_XmlValidationError, e);
-        throw new SAXException(Messages.TraceControl_XmlValidationError, e);
-    }
-
-    @Override
-    public void fatalError(SAXParseException e) throws SAXException {
-        Activator.getDefault().logError(Messages.TraceControl_XmlValidationError, e);
-        throw new SAXException(Messages.TraceControl_XmlValidationError, e);
-    }
-
-    @Override
-    public void warning(SAXParseException e) throws SAXException {
-        Activator.getDefault().logWarning(Messages.TraceControl_XmlValidationWarning, e);
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/logging/ControlCommandLogger.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/logging/ControlCommandLogger.java
deleted file mode 100644 (file)
index fef7567..0000000
+++ /dev/null
@@ -1,117 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.logging;
-
-import java.io.BufferedWriter;
-import java.io.FileWriter;
-import java.io.IOException;
-
-import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
-
-/**
- * <p>
- * Class to log control commands.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public final class ControlCommandLogger {
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-    /**
-     * The bufferd writer reference
-     */
-    private static BufferedWriter fTraceLog = null;
-
-    // ------------------------------------------------------------------------
-    // Constructor
-    // ------------------------------------------------------------------------
-    private ControlCommandLogger() {
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-    /**
-     * Initializes the logger class and opens the log file with the given parameter.
-     * @param filename - file name of logger output
-     * @param append - true to open log file in append mode else false (overwrite)
-     */
-    public static void init(String filename, boolean append) {
-        if (fTraceLog != null) {
-            close();
-        }
-        fTraceLog = openLogFile(filename, append);
-    }
-
-    /**
-     * Closes the log file if open.
-     */
-    public static void close() {
-        if (fTraceLog == null) {
-            return;
-        }
-
-        try {
-            fTraceLog.close();
-            fTraceLog = null;
-        } catch (IOException e) {
-            Activator.getDefault().logWarning("Can't close log file of the trace control", e); //$NON-NLS-1$
-        }
-    }
-
-    /**
-     * Logs a message to the log file.
-     * @param msg - message (e.g. command or command result) to log
-     */
-    @SuppressWarnings("nls")
-    public static void log(String msg) {
-        long currentTime = System.currentTimeMillis();
-        StringBuilder message = new StringBuilder("[");
-        message.append(currentTime / 1000);
-        message.append(".");
-        message.append(String.format("%1$03d", currentTime % 1000));
-        message.append("] ");
-        message.append(msg);
-        if (fTraceLog != null) {
-            try {
-                fTraceLog.write(message.toString());
-                fTraceLog.newLine();
-                fTraceLog.flush();
-            } catch (IOException e) {
-                Activator.getDefault().logError("Can't log message in log file of the tracer control", e); //$NON-NLS-1$
-            }
-        }
-    }
-
-    // ------------------------------------------------------------------------
-    // Helper methods
-    // ------------------------------------------------------------------------
-    /**
-     * Opens the trace log file with given name in the workspace root directory
-     * @param filename - file name of logger output
-     * @param append - true to open log file in append mode else false (overwrite)
-     * @return the buffer writer class or null if not successful
-     */
-    private static BufferedWriter openLogFile(String filename, boolean append) {
-        BufferedWriter outfile = null;
-        try {
-            outfile = new BufferedWriter(new FileWriter(filename, append));
-        } catch (IOException e) {
-            Activator.getDefault().logError("Can't open log file for logging of tracer control commands: " + filename, e); //$NON-NLS-1$
-        }
-        return outfile;
-    }
-}
-
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/messages/Messages.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/messages/Messages.java
deleted file mode 100644 (file)
index 5944aba..0000000
+++ /dev/null
@@ -1,346 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2012, 2015 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
- *   Jonathan Rajotte - Updated for basic support of LTTng 2.6 machine interface
- *   Markus Schorn - Bug 448058: Use org.eclipse.remote in favor of RSE
- *******************************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages;
-
-import org.eclipse.osgi.util.NLS;
-
-/**
- * Messages file for the trace control package.
- *
- * @author Bernd Hufmann
- */
-@SuppressWarnings("javadoc")
-public final class Messages extends NLS {
-
-    private static final String BUNDLE_NAME = "org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.messages"; //$NON-NLS-1$
-
-    public static String EnableChannelDialog_DefaultMessage;
-
-    public static String ImportHandler_LiveTraceElementError;
-
-    public static String ImportHandler_LiveTraceInitError;
-
-    // Failures
-    public static String TraceControl_ConnectionFailure;
-    public static String TraceControl_DisconnectionFailure;
-
-    public static String TraceControl_CommandError;
-    public static String TraceControl_UnexpectedCommandOutputFormat;
-    public static String TraceControl_UnexpectedNameError;
-    public static String TraceControl_UnexpectedPathError;
-    public static String TraceControl_UnexpectedNumberOfElementError;
-    public static String TraceControl_UnexpectedValueError;
-
-    public static String TraceControl_UnsupportedVersionError;
-    public static String TraceControl_GettingVersionError;
-
-    // Xml parsing related failures
-    public static String TraceControl_InvalidSchemaError;
-    public static String TraceControl_XmlDocumentBuilderError;
-    public static String TraceControl_XmlParsingError;
-    public static String TraceControl_XmlValidationError;
-    public static String TraceControl_XmlValidationWarning;
-
-    // Xml machine interface failures
-    public static String TraceControl_MiInvalidNumberOfElementError;
-    public static String TraceControl_MiInvalidProviderError;
-    public static String TraceControl_MiMissingRequiredError;
-    public static String TraceControl_MiInvalidElementError;
-    public static String TraceControl_MiIllegalValueError;
-
-    // Commands
-    public static String TraceControl_ErrorTitle;
-    public static String TraceControl_RetrieveNodeConfigurationJob;
-    public static String TraceControl_RetrieveNodeConfigurationFailure;
-    public static String TraceControl_ListSessionFailure;
-    public static String TraceControl_EclipseCommandFailure;
-    public static String TraceControl_NewNodeCreateButtonText;
-
-    public static String TraceControl_NewNodeCreationFailure;
-    public static String TraceControl_CreateSessionJob;
-    public static String TraceControl_CreateSessionFailure;
-
-    public static String TraceControl_DestroySessionJob;
-    public static String TraceControl_DestroySessionFailure;
-    public static String TraceControl_DestroyConfirmationTitle;
-    public static String TraceControl_DestroyConfirmationMessage;
-
-    public static String TraceControl_ImportJob;
-    public static String TraceControl_DownloadTask;
-    public static String TraceControl_ImportFailure;
-
-    public static String TraceControl_ChangeSessionStateJob;
-    public static String TraceControl_ChangeSessionStateFailure;
-
-    public static String TraceControl_CreateChannelStateJob;
-    public static String TraceControl_CreateChannelStateFailure;
-
-    public static String TraceControl_ChangeChannelStateJob;
-    public static String TraceControl_ChangeChannelStateFailure;
-    public static String TraceControl_ChangeEventStateJob;
-    public static String TraceControl_ChangeEventStateFailure;
-
-    public static String TraceControl_EnableEventsJob;
-    public static String TraceControl_EnableEventsFailure;
-    public static String TraceControl_DisableEventsJob;
-
-    public static String TraceControl_GetContextJob;
-    public static String TraceControl_GetContextFailure;
-
-    public static String TraceControl_AddContextJob;
-    public static String TraceControl_AddContextFailure;
-
-    public static String TraceControl_AddCalibrateJob;
-    public static String TraceControl_AddCalibrateFailure;
-
-    public static String TraceControl_RecordSnapshotJob;
-    public static String TraceControl_RecordSnapshotFailure;
-
-    // Dialogs
-    public static String TraceControl_NewDialogTitle;
-    public static String TraceControl_NewNodeExistingConnectionGroupName;
-    public static String TraceControl_NewNodeEditButtonName;
-    public static String TraceControl_NewNodeComboToolTip;
-    public static String TraceControl_NewNodeConnectionNameLabel;
-    public static String TraceControl_NewNodeConnectionNameTooltip;
-    public static String TraceControl_NewNodeHostNameLabel;
-    public static String TraceControl_NewNodeHostNameTooltip;
-    public static String TraceControl_NewNodePortLabel;
-    public static String TraceControl_NewNodePortTooltip;
-    public static String TraceControl_AlreadyExistsError;
-
-    public static String TraceControl_CreateSessionDialogTitle;
-    public static String TraceControl_CreateSessionDialogMessage;
-    public static String TraceControl_CreateSessionNameLabel;
-    public static String TraceControl_CreateSessionNameTooltip;
-    public static String TraceControl_CreateSessionPathLabel;
-    public static String TraceControl_CreateSessionPathTooltip;
-    public static String TraceControl_CreateSessionNormalLabel;
-    public static String TraceControl_CreateSessionNormalTooltip;
-    public static String TraceControl_CreateSessionSnapshotLabel;
-    public static String TraceControl_CreateSessionSnapshotTooltip;
-    public static String TraceControl_CreateSessionLiveLabel;
-    public static String TraceControl_CreateSessionLiveTooltip;
-
-    public static String TraceControl_CreateSessionConfigureStreamingButtonText;
-    public static String TraceControl_CreateSessionConfigureStreamingButtonTooltip;
-    public static String TraceControl_CreateSessionNoStreamingButtonText;
-    public static String TraceControl_CreateSessionNoStreamingButtonTooltip;
-    public static String TraceControl_CreateSessionTracePathText;
-    public static String TraceControl_CreateSessionTracePathTooltip;
-    public static String TraceControl_CreateSessionLinkButtonText;
-    public static String TraceControl_CreateSessionLinkButtonTooltip;
-    public static String TraceControl_CreateSessionProtocolLabelText;
-    public static String TraceControl_CreateSessionAddressLabelText;
-    public static String TraceControl_CreateSessionPortLabelText;
-    public static String TraceControl_CreateSessionControlUrlLabel;
-    public static String TraceControl_CreateSessionDataUrlLabel;
-    public static String TraceControl_CreateSessionCommonProtocolTooltip;
-    public static String TraceControl_CreateSessionControlAddressTooltip;
-    public static String TraceControl_CreateSessionControlPortTooltip;
-    public static String TraceControl_CreateSessionProtocolTooltip;
-    public static String TraceControl_CreateSessionDataAddressTooltip;
-    public static String TraceControl_CreateSessionDataPortTooltip;
-    public static String TraceControl_CreateSessionNoConsumertText;
-    public static String TraceControl_CreateSessionNoConsumertTooltip;
-    public static String TraceControl_CreateSessionDisableConsumertText;
-    public static String TraceControl_CreateSessionDisableConsumertTooltip;
-    public static String TraceControl_CreateSessionLiveConnectionLabel;
-    public static String TraceControl_CreateSessionLiveConnectionUrlTooltip;
-    public static String TraceControl_CreateSessionLiveConnectionPortTooltip;
-    public static String TraceControl_CreateSessionLiveDelayLabel;
-    public static String TraceControl_CreateSessionLiveDelayTooltip;
-
-    public static String TraceControl_InvalidSessionNameError;
-    public static String TraceControl_SessionAlreadyExistsError;
-    public static String TraceControl_SessionPathAlreadyExistsError;
-    public static String TraceControl_InvalidSessionPathError;
-    public static String TraceControl_InvalidLiveDelayError;
-    public static String TraceControl_FileSubSystemError;
-
-    public static String TraceControl_EnableChannelDialogTitle;
-    public static String TraceControl_EnableChannelNameLabel;
-    public static String TraceControl_EnableChannelNameTooltip;
-    public static String TraceControl_EnableChannelSubBufferSizeTooltip;
-    public static String TraceControl_EnableChannelNbSubBuffersTooltip;
-    public static String TraceControl_EnableChannelSwitchTimerTooltip;
-    public static String TraceControl_EnableChannelReadTimerTooltip;
-    public static String TraceControl_EnableChannelOutputTypeTooltip;
-    public static String TraceControl_EnableChannelDiscardModeGroupName;
-    public static String TraceControl_EnableChannelDiscardModeLabel;
-    public static String TraceControl_EnableChannelDiscardModeTooltip;
-    public static String TraceControl_EnableChannelOverwriteModeLabel;
-    public static String TraceControl_EnableChannelOverwriteModeTooltip;
-    public static String TraceControl_EnbleChannelMaxSizeTraceFilesTooltip;
-    public static String TraceControl_EnbleChannelMaxNumTraceFilesTooltip;
-
-    public static String TraceControl_InvalidChannelNameError;
-    public static String TraceControl_ChannelAlreadyExistsError;
-
-    public static String TraceControl_EnableEventsDialogTitle;
-    public static String TraceControl_EnableEventsSessionGroupName;
-    public static String TraceControl_EnableEventsChannelGroupName;
-    public static String TraceControl_EnableEventsSessionsTooltip;
-    public static String TraceControl_EnableEventsChannelsTooltip;
-    public static String TraceControl_EnableEventsNoSessionError;
-    public static String TraceControl_EnableEventsNoChannelError;
-
-    public static String TraceControl_EnableGroupSelectionName;
-    public static String TraceControl_EnableEventsTracepointGroupName;
-    public static String TraceControl_EnableEventsTracepointTreeTooltip;
-    public static String TraceControl_EnableEventsTracepointTreeAllLabel;
-    public static String TraceControl_EnableEventsSyscallName;
-    public static String TraceControl_EnableEventsSyscallTooltip;
-    public static String TraceControl_EnableEventsProbeGroupName;
-    public static String TraceControl_EnableEventsEventNameLabel;
-    public static String TraceControl_EnableEventsProbeEventNameTooltip;
-    public static String TraceControl_EnableEventsProbeNameLabel;
-    public static String TraceControl_EnableEventsProbeNameTooltip;
-    public static String TraceControl_EnableEventsFucntionGroupName;
-    public static String TraceControl_EnableEventsFunctionEventNameTooltip;
-    public static String TraceControl_EnableEventsFunctionNameLabel;
-
-    public static String TraceControl_EnableEventsWildcardGroupName;
-    public static String TraceControl_EnableEventsWildcardLabel;
-    public static String TraceControl_EnableEventsWildcardTooltip;
-    public static String TraceControl_EnableEventsLogLevelGroupName;
-    public static String TraceControl_EnableEventsLogLevelTypeName;
-    public static String TraceControl_EnableEventsLogLevelTypeTooltip;
-    public static String TraceControl_EnableEventsLogLevelOnlyTypeName;
-    public static String TraceControl_EnableEventsLogLevelOnlyTypeTooltip;
-    public static String TraceControl_EnableEventsLogLevelTooltip;
-    public static String TraceControl_EnableEventsLoglevelEventNameTooltip;
-    public static String TraceControl_EnableEventsFilterGroupName;
-    public static String TraceControl_EnableEventsFilterTooltip;
-
-    public static String TraceControl_InvalidProbeNameError;
-    public static String TraceControl_InvalidWildcardError;
-    public static String TraceControl_InvalidLogLevelEventNameError;
-    public static String TraceControl_InvalidLogLevel;
-
-    public static String TraceControl_AddContextDialogTitle;
-    public static String TraceControl_AddContextAvailableContextsLabel;
-    public static String TraceControl_AddContextAvailableContextsTooltip;
-    public static String TraceControl_AddContextAllLabel;
-
-    public static String TraceControl_ImportDialogStreamedTraceNotification;
-    public static String TraceControl_ImportDialogStreamedTraceNotificationToggle;
-    public static String TraceControl_ImportDialogTitle;
-    public static String TraceControl_ImportDialogTracesGroupName;
-    public static String TraceControl_ImportDialogTracesTooltip;
-    public static String TraceControl_ImportDialogProjectsGroupName;
-    public static String TraceControl_ImportDialogProjectsTooltip;
-    public static String TraceControl_ImportDialogOverwriteButtonText;
-    public static String TraceControl_ImportDialogCreationError;
-    public static String TraceControl_ImportDialogNoProjectSelectedError;
-    public static String TraceControl_ImportDialogInvalidTracingProject;
-    public static String TraceControl_ImportDialogNoTraceSelectedError;
-    public static String TraceControl_ImportDialog_SelectAll;
-    public static String TraceControl_ImportDialog_DeselectAll;
-
-    public static String TraceControl_ImportDialogConfirmationTitle;
-    public static String TraceControl_ImportDialogConfirmationOverwriteLabel;
-    public static String TraceControl_ImportDialogConfirmationRenameLabel;
-    public static String TraceControl_ImportDialogConfirmationNewNameLabel;
-    public static String TraceControl_InvalidTraceNameError;
-    public static String TraceControl_ImportDialogTraceAlreadyExistError;
-
-    // Tree structure strings
-    public static String TraceControl_KernelDomainDisplayName;
-    public static String TraceControl_UstDisplayName;
-    public static String TraceControl_UstGlobalDomainDisplayName;
-    public static String TraceControl_UnknownDomainDisplayName;
-    public static String TraceControl_JULDomainDisplayName;
-    public static String TraceControl_AllSessionsDisplayName;
-    public static String TraceControl_SessionDisplayName;
-    public static String TraceControl_DomainDisplayName;
-    public static String TraceControl_BufferTypeDisplayName;
-    public static String TraceControl_ChannelDisplayName;
-    public static String TraceControl_EventDisplayName;
-    public static String TraceControl_ProviderDisplayName;
-    public static String TraceControl_KernelProviderDisplayName;
-    public static String TraceControl_SharedBuffersDisplayName;
-    public static String TraceControl_PerPidBuffersDisplayName;
-    public static String TraceControl_PerPidBuffersTooltip;
-    public static String TraceControl_PerUidBuffersDisplayName;
-    public static String TraceControl_PerUidBuffersTooltip;
-
-    // Property names
-    public static String TraceControl_SessionNamePropertyName;
-    public static String TraceControl_EventNamePropertyName;
-    public static String TraceControl_EventTypePropertyName;
-    public static String TraceControl_LogLevelPropertyName;
-    public static String TraceControl_FieldsPropertyName;
-    public static String TraceControl_FilterPropertyName;
-    public static String TraceControl_StatePropertyName;
-    public static String TraceControl_VersionPropertyName;
-    public static String TraceControl_DomainNamePropertyName;
-    public static String TraceControl_BufferTypePropertyName;
-    public static String TraceControl_ChannelNamePropertyName;
-    public static String TraceControl_OpenConnectionTo;
-
-    public static String TraceControl_OverwriteModePropertyName;
-    public static String TraceControl_SubBufferSizePropertyName;
-    public static String TraceControl_NbSubBuffersPropertyName;
-    public static String TraceControl_SwitchTimerPropertyName;
-    public static String TraceControl_ReadTimerPropertyName;
-    public static String TraceControl_OutputTypePropertyName;
-    public static String TraceControl_TraceFileCountPropertyName;
-    public static String TraceControl_TraceFileSizePropertyName;
-    public static String TraceControl_HostNamePropertyName;
-    public static String TraceControl_HostAddressPropertyName;
-    public static String TraceControl_SessionPathPropertyName;
-    public static String TraceControl_SnapshotPathPropertyName;
-    public static String TraceControl_SnapshotNamePropertyName;
-    public static String TraceControl_SnapshotIdPropertyName;
-    public static String TraceControl_ProviderNamePropertyName;
-    public static String TraceControl_ProcessIdPropertyName;
-    public static String TraceControl_ProbeAddressPropertyName;
-    public static String TraceControl_ProbeOffsetPropertyName;
-    public static String TraceControl_ProbeSymbolPropertyName;
-    public static String TraceControl_MaxSizeTraceFilesPropertyName;
-    public static String TraceControl_MaxNumTraceFilesPropertyName;
-    public static String TraceControl_ConfigureMetadataChannelName;
-
-    // Preferences
-    public static String TraceControl_TracingGroupPreference;
-    public static String TraceControl_LoggingPreference;
-    public static String TraceControl_LogfilePath;
-    public static String TraceControl_AppendLogfilePreference;
-
-    public static String TraceControl_VerboseLevelsPreference;
-    public static String TraceControl_VerboseLevelNonePreference;
-    public static String TraceControl_VerboseLevelVerbosePreference;
-    public static String TraceControl_VerboseLevelVeryVerbosePreference;
-    public static String TraceControl_VerboseLevelVeryVeryVerbosePreference;
-
-    public static String TraceControl_ExecuteScriptJob;
-    public static String TraceControl_ExecuteScriptError;
-
-    public static String TraceControl_ExecuteScriptDialogTitle;
-    public static String TraceControl_ExecuteScriptBrowseText;
-    public static String TraceControl_ExecuteScriptSelectLabel;
-
-    public static String TraceControl_UnknownNode;
-
-    static {
-        // initialize resource bundle
-        NLS.initializeMessages(BUNDLE_NAME, Messages.class);
-    }
-
-    private Messages() {
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/messages/messages.properties b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/messages/messages.properties
deleted file mode 100644 (file)
index 7ac5155..0000000
+++ /dev/null
@@ -1,321 +0,0 @@
-###############################################################################
-# Copyright (c) 2012, 2015 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:
-# Bernd Hufmann - initial API and implementation
-# Jonathan Rajotte - updated for basic support of LTTng 2.6 machine interface
-###############################################################################
-
-EnableChannelDialog_DefaultMessage=Default
-ImportHandler_LiveTraceElementError=Could not find trace element
-ImportHandler_LiveTraceInitError=Error initializing live trace.
-TraceControl_ConnectionFailure=Connecting to host failed 
-TraceControl_DisconnectionFailure=Disconnection from host failed
-TraceControl_CommandError=Command failed! Command: 
-
-TraceControl_UnexpectedCommandOutputFormat=Unexpected command output
-TraceControl_UnexpectedNameError=Unexpected session name returned
-TraceControl_UnexpectedPathError=Unexpected session path returned
-TraceControl_UnexpectedNumberOfElementError=Unexpected number of elements {0} returned
-TraceControl_UnexpectedValueError=Unexpected value. Returned {0} Expected: {1}
-
-TraceControl_UnsupportedVersionError=Unsupported LTTng Tracer Control version
-TraceControl_GettingVersionError=Could not get version of LTTng Tracer Control
-
-# Xml parsing related failures
-TraceControl_InvalidSchemaError=Could not open/validate xsd Schema
-TraceControl_XmlDocumentBuilderError=Unable to create the xml document builder
-TraceControl_XmlParsingError=Unable to parse the xml document
-TraceControl_XmlValidationError=Could not validate the xml response
-TraceControl_XmlValidationWarning=Xml validation warning
-
-# Xml machine interface failures
-TraceControl_MiInvalidNumberOfElementError=Invalid number of element
-TraceControl_MiInvalidProviderError=Invalid provider data
-TraceControl_MiMissingRequiredError=Missing required data
-TraceControl_MiIllegalValueError=Invalid value
-
-# Commands
-TraceControl_MiInvalidElementError=Invalid xml data
-
-TraceControl_ErrorTitle=Error
-TraceControl_ListSessionFailure=List sessions failed
-TraceControl_RetrieveNodeConfigurationJob=Retrieving Target Node Configuration...
-TraceControl_RetrieveNodeConfigurationFailure=Error retrieving node configuration
-TraceControl_EclipseCommandFailure=Command failed
-TraceControl_NewNodeCreateButtonText=Create...
-TraceControl_NewNodeCreationFailure=Creation of new connection failed
-TraceControl_CreateSessionJob=Creating Session...
-TraceControl_CreateSessionFailure=Command to create session failed
-
-TraceControl_DestroySessionJob=Destroying Session...
-TraceControl_DestroySessionFailure=Command to destroy session failed
-TraceControl_DestroyConfirmationTitle=Destroy Confirmation
-TraceControl_DestroyConfirmationMessage=Do you want to delete all selected sessions?
-
-TraceControl_ImportJob=Importing Traces...
-TraceControl_DownloadTask=Downloading
-TraceControl_ImportFailure=Command to import traces failed
-
-TraceControl_ChangeSessionStateJob=Changing Session State...
-TraceControl_ChangeSessionStateFailure=Command to change session state failed...
-
-TraceControl_CreateChannelStateJob=Enabling (creating) channel... 
-TraceControl_CreateChannelStateFailure=Command to enable channel failed
-
-TraceControl_ChangeChannelStateJob=Changing State of Channels...
-TraceControl_ChangeChannelStateFailure=Command to change state of channels failed
-TraceControl_ChangeEventStateJob=Changing State of Events...
-TraceControl_ChangeEventStateFailure=Command to change state of events failed
-
-TraceControl_EnableEventsJob=Enabling Events...
-TraceControl_EnableEventsFailure=Command to enable events failed
-TraceControl_DisableEventsJob=Disabling Events...
-
-TraceControl_GetContextJob=Getting Available Contexts...
-TraceControl_GetContextFailure=Command to get available contexts failed
-
-TraceControl_AddContextJob=Adding Contexts...
-TraceControl_AddContextFailure=Command to add contexts failed
-
-TraceControl_AddCalibrateJob=Calibrating...
-TraceControl_AddCalibrateFailure=Command to calibrate failed
-
-TraceControl_RecordSnapshotJob=Record snapshot...
-TraceControl_RecordSnapshotFailure=Command to snapshot record failed
-
-# Dialogs
-TraceControl_NewDialogTitle=New Connection
-TraceControl_NewNodeExistingConnectionGroupName=Select an existing connection, or use a provider to create a new one:
-TraceControl_NewNodeEditButtonName=Edit...
-TraceControl_NewNodeComboToolTip=List of existing connections (connection name - host name)
-TraceControl_NewNodeConnectionNameLabel=Connection Name
-TraceControl_NewNodeConnectionNameTooltip=Alias to be displayed for node to connect to. 
-TraceControl_NewNodeHostNameLabel=Host Name
-TraceControl_NewNodeHostNameTooltip=IP Address or DNS name of node to connect to.
-TraceControl_NewNodePortLabel=Port Number
-TraceControl_NewNodePortTooltip=IP Port Number to be used for the connection. Leave empty for default port.
-TraceControl_AlreadyExistsError=Node name already exists in Control View
-
-TraceControl_CreateSessionDialogTitle=Create Session
-TraceControl_CreateSessionDialogMessage=Configure the new tracing session
-TraceControl_CreateSessionNameLabel=Session Name
-TraceControl_CreateSessionNameTooltip=The name of the session to be created.
-TraceControl_CreateSessionPathLabel=Session Path
-TraceControl_CreateSessionPathTooltip=The session path (keep empty for default location)
-TraceControl_CreateSessionNormalLabel=Normal Mode
-TraceControl_CreateSessionNormalTooltip=Configure session in normal mode
-TraceControl_CreateSessionSnapshotLabel=Snapshot Mode
-TraceControl_CreateSessionSnapshotTooltip=Configure session in snapshot mode
-TraceControl_CreateSessionLiveLabel=Live Mode
-TraceControl_CreateSessionLiveTooltip=Configure session in live mode
-
-
-TraceControl_CreateSessionConfigureStreamingButtonText=Advanced
-TraceControl_CreateSessionConfigureStreamingButtonTooltip=Configure advanced options
-TraceControl_CreateSessionNoStreamingButtonText=Basic
-TraceControl_CreateSessionNoStreamingButtonTooltip=Use basic options
-TraceControl_CreateSessionTracePathText=Trace Path
-TraceControl_CreateSessionTracePathTooltip=The trace path (keep empty for default location)
-TraceControl_CreateSessionLinkButtonText=Use same protocol and address for data and control
-TraceControl_CreateSessionLinkButtonTooltip=Use the same protocol and address for the data and control connection
-TraceControl_CreateSessionProtocolLabelText=Protocol
-TraceControl_CreateSessionAddressLabelText=Address
-TraceControl_CreateSessionPortLabelText=Port
-TraceControl_CreateSessionControlUrlLabel=Control URL
-TraceControl_CreateSessionDataUrlLabel=Data URL
-TraceControl_CreateSessionCommonProtocolTooltip=file - Local file system full path\n\
-net or net6 - Default network transport layer which is TCP for both control and data channel.
-TraceControl_CreateSessionControlAddressTooltip=IP Address or DNS name used for control channel.\n\
-NOTE: IPv6 address MUST be enclosed in brackets '[]' (rfc2732)
-TraceControl_CreateSessionControlPortTooltip=The control port (default: 5342).
-TraceControl_CreateSessionProtocolTooltip=file - Local file system full path\n\
-net or net6 - Default network transport layer which is TCP\n\
-tcp or tcp6 - TCP network transport
-TraceControl_CreateSessionDataAddressTooltip=IP Address or DNS name used for data channel.\n\
-NOTE: IPv6 address MUST be enclosed in brackets '[]' (rfc2732)
-TraceControl_CreateSessionDataPortTooltip=The data port (default: 5343).
-TraceControl_CreateSessionNoConsumertText=No Consumer
-TraceControl_CreateSessionNoConsumertTooltip=Don't activate a consumer for this session.
-TraceControl_CreateSessionDisableConsumertText=Disable Consumer
-TraceControl_CreateSessionDisableConsumertTooltip=Disable consumer for this session.
-TraceControl_CreateSessionLiveConnectionLabel=Live Connection
-TraceControl_CreateSessionLiveDelayLabel=Live Delay
-TraceControl_CreateSessionLiveDelayTooltip=The delay in micro seconds before the data is flushed and streamed
-TraceControl_CreateSessionLiveConnectionUrlTooltip=The URL for the live connection (Relayd)
-TraceControl_CreateSessionLiveConnectionPortTooltip=The port for the live connection (Relayd)
-
-TraceControl_InvalidSessionNameError=The session name is invalid
-TraceControl_SessionAlreadyExistsError=The session name already exists
-TraceControl_SessionPathAlreadyExistsError=Session path already exists
-TraceControl_InvalidSessionPathError=The session path is invalid
-TraceControl_InvalidLiveDelayError=Live Delay must be a valid positive number
-TraceControl_FileSubSystemError=File subsystem error in session creation dialog.
-
-TraceControl_EnableChannelDialogTitle=Enable Channel
-TraceControl_EnableChannelNameLabel=Channel Name
-TraceControl_EnableChannelNameTooltip=The name of the channel to be enabled.
-TraceControl_EnableChannelSubBufferSizeTooltip=The sub-buffers size of the channel. Needs to be a power of 2 for kernel and ust tracers (Only for versions prior to 2.2.0).
-TraceControl_EnableChannelNbSubBuffersTooltip=The number of sub-buffers of the channel. Needs to be a power of 2 for kernel and ust tracers (Only for versions prior to 2.2.0).
-TraceControl_EnableChannelSwitchTimerTooltip=The Switch subbuffer timer interval in usec (default: 0). Needs to be a power of 2 for kernel and ust tracers (Only for versions prior to 2.2.0).
-TraceControl_EnableChannelReadTimerTooltip=The Read timer interval in usec.
-TraceControl_EnableChannelOutputTypeTooltip=The output type of the channel.
-TraceControl_EnableChannelDiscardModeGroupName=Discard Mode
-TraceControl_EnableChannelDiscardModeLabel=Discard
-TraceControl_EnableChannelDiscardModeTooltip=Discard event when subbuffers are full
-TraceControl_EnableChannelOverwriteModeLabel=Overwrite
-TraceControl_EnableChannelOverwriteModeTooltip=Flight recorder mode : overwrites events when subbuffers are full
-TraceControl_EnbleChannelMaxSizeTraceFilesTooltip=Maximum size of each tracefile within a stream (in bytes). 0 means unlimited
-TraceControl_EnbleChannelMaxNumTraceFilesTooltip=Used in conjunction with the maximum size of trace files option, this will limit the number of files created to the specified count. 0 means unlimited
-
-TraceControl_InvalidChannelNameError=The channel name is invalid or empty
-TraceControl_ChannelAlreadyExistsError=Channel already exists
-
-TraceControl_EnableEventsDialogTitle=Enable Events
-TraceControl_EnableEventsSessionGroupName=Session List
-TraceControl_EnableEventsChannelGroupName=Channel List
-TraceControl_EnableEventsSessionsTooltip=List of available sessions.
-TraceControl_EnableEventsChannelsTooltip=List of available channels of selected session.\nIf no channel is available default channel will be created.
-TraceControl_EnableEventsNoSessionError=No session from session list is selected.
-TraceControl_EnableEventsNoChannelError=No channel from channel list is selected.
-
-TraceControl_EnableGroupSelectionName=Select
-TraceControl_EnableEventsTracepointGroupName=Tracepoint Events
-TraceControl_EnableEventsTracepointTreeTooltip=List of available kernel tracepoint events
-TraceControl_EnableEventsTracepointTreeAllLabel=All
-TraceControl_EnableEventsSyscallName=All Syscalls
-TraceControl_EnableEventsSyscallTooltip=Enable all Syscalls
-TraceControl_EnableEventsProbeGroupName=Dynamic Probe
-TraceControl_EnableEventsEventNameLabel=Event Name
-TraceControl_EnableEventsProbeEventNameTooltip=The name of the event for enabling a dynamic probe
-TraceControl_EnableEventsProbeNameLabel=Probe
-TraceControl_EnableEventsProbeNameTooltip=[addr | symbol | symbol+offset]\nAddr and offset can be octal (0NNN...),\ndecimal (NNN...) or hexadecimal (0xNNN...)
-TraceControl_EnableEventsFucntionGroupName=Dynamic Function Entry/Return Probe
-TraceControl_EnableEventsFunctionEventNameTooltip=The name of the event for enabling a dynamic function entry/return probe
-TraceControl_EnableEventsFunctionNameLabel=Function
-
-TraceControl_EnableEventsWildcardGroupName=Wildcard
-TraceControl_EnableEventsWildcardLabel=Wildcard
-TraceControl_EnableEventsWildcardTooltip=The wild card string of event names
-TraceControl_EnableEventsLogLevelGroupName=Log Level
-TraceControl_EnableEventsLogLevelTypeName=loglevel
-TraceControl_EnableEventsLogLevelTypeTooltip=The tracepoint log level range from 0 to loglevel
-TraceControl_EnableEventsLogLevelOnlyTypeName=loglevel-only
-TraceControl_EnableEventsLogLevelOnlyTypeTooltip=The tracepoint log level (only this loglevel)
-TraceControl_EnableEventsLogLevelTooltip=The available log levels
-TraceControl_EnableEventsLoglevelEventNameTooltip=Event name for enabling log levels
-TraceControl_EnableEventsFilterGroupName=Filter Expression
-TraceControl_EnableEventsFilterTooltip=Filter expression on event field.
-
-TraceControl_InvalidProbeNameError=The probe name is invalid or empty 
-TraceControl_InvalidWildcardError=The wild card name is invalid or empty
-TraceControl_InvalidLogLevelEventNameError=The event name for log level is invalid or empty
-TraceControl_InvalidLogLevel=No log level selected
-
-TraceControl_AddContextDialogTitle=Add Contexts
-TraceControl_AddContextAvailableContextsLabel=Contexts
-TraceControl_AddContextAvailableContextsTooltip=Available Contexts
-TraceControl_AddContextAllLabel=All Contexts
-
-TraceControl_ImportDialogStreamedTraceNotification=You are importing a trace generated by a streamed session. By default the traces will be outputed to ~/lttng-traces/hostname/sessionname but the location can vary.
-TraceControl_ImportDialogStreamedTraceNotificationToggle=Do not warn me again
-TraceControl_ImportDialogTitle=Import Traces
-TraceControl_ImportDialogTracesGroupName=Available Traces
-TraceControl_ImportDialogTracesTooltip=The available traces of current session to import
-TraceControl_ImportDialogProjectsGroupName=Available Projects
-TraceControl_ImportDialogProjectsTooltip=The available projects to select from
-TraceControl_ImportDialogOverwriteButtonText=Overwrite existing trace without warning
-TraceControl_ImportDialogCreationError=Dialog box cannot be created
-TraceControl_ImportDialogNoProjectSelectedError=No tracing project selected or available
-TraceControl_ImportDialogInvalidTracingProject=Invalid tracing project. Missing directory
-TraceControl_ImportDialogNoTraceSelectedError=No trace selected or available
-
-TraceControl_ImportDialogConfirmationTitle=Import Confirmation Dialog
-TraceControl_ImportDialogConfirmationOverwriteLabel=Overwrite
-TraceControl_ImportDialogConfirmationRenameLabel=Rename
-TraceControl_ImportDialogConfirmationNewNameLabel=New Trace Name
-TraceControl_InvalidTraceNameError=Invalid trace name
-TraceControl_ImportDialogTraceAlreadyExistError=Trace already exists in project
-TraceControl_ImportDialog_SelectAll=Select All
-TraceControl_ImportDialog_DeselectAll=Deselect All
-
-
-# Tree structure strings
-TraceControl_KernelDomainDisplayName=Kernel
-TraceControl_JULDomainDisplayName=JUL
-TraceControl_UstGlobalDomainDisplayName=UST global
-TraceControl_UstDisplayName=UST
-TraceControl_UnknownDomainDisplayName=Unknown domain
-TraceControl_AllSessionsDisplayName=Sessions
-TraceControl_SessionDisplayName=Session
-TraceControl_DomainDisplayName=Domain
-TraceControl_BufferTypeDisplayName = Buffer Type
-TraceControl_ChannelDisplayName=Channel
-TraceControl_EventDisplayName=Event
-TraceControl_ProviderDisplayName=Provider
-TraceControl_KernelProviderDisplayName=Kernel
-TraceControl_SharedBuffersDisplayName=Global shared buffers
-TraceControl_PerPidBuffersDisplayName=Per PID buffers
-TraceControl_PerPidBuffersTooltip=Configure per PID buffers (UST only)
-TraceControl_PerUidBuffersDisplayName=Per UID buffers
-TraceControl_PerUidBuffersTooltip=Configure per UID buffers (UST only)
-
-# Property names
-TraceControl_SessionNamePropertyName=Session Name
-TraceControl_EventNamePropertyName=Event Name
-TraceControl_EventTypePropertyName=Event Type
-TraceControl_LogLevelPropertyName=Log Level
-TraceControl_FieldsPropertyName=Fields
-TraceControl_FilterPropertyName=Filter
-TraceControl_StatePropertyName=State
-TraceControl_VersionPropertyName=Version
-TraceControl_DomainNamePropertyName=Domain Name
-TraceControl_BufferTypePropertyName=Buffer type
-TraceControl_ChannelNamePropertyName=Channel Name
-TraceControl_OpenConnectionTo=Opening connection to ''{0}''
-TraceControl_OverwriteModePropertyName=Overwrite Mode
-TraceControl_SubBufferSizePropertyName=Sub Buffer Size
-TraceControl_NbSubBuffersPropertyName=Number of Sub Buffers
-TraceControl_SwitchTimerPropertyName=Switch Timer Interval
-TraceControl_ReadTimerPropertyName=Read Timer Interval
-TraceControl_OutputTypePropertyName=Output Type
-TraceControl_TraceFileCountPropertyName=Trace File Count
-TraceControl_TraceFileSizePropertyName=Trace File Size
-TraceControl_HostNamePropertyName=Connection Name
-TraceControl_HostAddressPropertyName=Host Name
-TraceControl_SessionPathPropertyName=Session Path
-TraceControl_SnapshotPathPropertyName=Snapshot Path
-TraceControl_SnapshotNamePropertyName=Snapshot Name
-TraceControl_SnapshotIdPropertyName=Snapshot ID
-TraceControl_ProviderNamePropertyName=Provider Name
-TraceControl_ProcessIdPropertyName=Process ID
-TraceControl_ProbeAddressPropertyName=Address
-TraceControl_ProbeOffsetPropertyName=Offset
-TraceControl_ProbeSymbolPropertyName=Symbol
-TraceControl_MaxSizeTraceFilesPropertyName=Maximum size of trace files
-TraceControl_MaxNumTraceFilesPropertyName=Maximum number of trace files
-TraceControl_ConfigureMetadataChannelName=Configure metadata channel
-
-# Preferences
-TraceControl_TracingGroupPreference=&Tracing Group
-TraceControl_LoggingPreference=&Logging
-TraceControl_LogfilePath=Log file
-TraceControl_AppendLogfilePreference=&Append
-TraceControl_VerboseLevelsPreference=&Verbose Level
-TraceControl_VerboseLevelNonePreference=None
-TraceControl_VerboseLevelVerbosePreference=Level 1
-TraceControl_VerboseLevelVeryVerbosePreference=Level 2
-TraceControl_VerboseLevelVeryVeryVerbosePreference=Level 3
-
-TraceControl_ExecuteScriptJob=Executing command script
-TraceControl_ExecuteScriptError=Error executing command script
-
-TraceControl_ExecuteScriptDialogTitle=Select command script
-TraceControl_ExecuteScriptBrowseText=Browse...
-TraceControl_ExecuteScriptSelectLabel=Select Script
-TraceControl_UnknownNode=<unknown>
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/ITraceControlComponent.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/ITraceControlComponent.java
deleted file mode 100644 (file)
index 3c8fc75..0000000
+++ /dev/null
@@ -1,192 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.model;
-
-import java.util.List;
-
-import org.eclipse.core.runtime.IAdaptable;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TargetNodeState;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.service.ILttngControlService;
-
-/**
- * <p>
- * Interface for trace control components that can be displayed in the
- * trace control tree viewer.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public interface ITraceControlComponent extends IAdaptable {
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    /**
-     * @return the name of the component
-     */
-    String getName();
-    /**
-     * Sets the name of the component to the given value.
-     * @param name - name to set
-     */
-    void setName(String name);
-
-    /**
-     * @return the image representing the component.
-     */
-    Image getImage();
-    /**
-     * Sets the image path of the component.
-     * @param path - path to the image location
-     */
-    void setImage(String path);
-    /**
-     * Sets the image the component.
-     * @param image - image to the image location
-     */
-    void setImage(Image image);
-
-    /**
-     * @return tool tip with information about the component.
-     */
-    String getToolTip();
-    /**
-     * Sets the tool tip with information about the component.
-     * @param toolTip - the tool tip to set.
-     */
-    void setToolTip(String toolTip);
-
-    /**
-     * @return the node's connection state
-     */
-    TargetNodeState getTargetNodeState();
-    /**
-     * Sets the node's connection state.
-     * @param state - the state to set
-     */
-    void setTargetNodeState(TargetNodeState state);
-
-    /**
-     * @return returns the parent component.
-     */
-    ITraceControlComponent getParent();
-    /**
-     * Sets the parent component.
-     * @param parent - the parent to set.
-     */
-    void setParent(ITraceControlComponent parent);
-
-    /**
-     * @return the children components
-     */
-    ITraceControlComponent[] getChildren();
-    /**
-     * Sets the children components.
-     * @param children - the children to set.
-     */
-    void setChildren(List<ITraceControlComponent> children);
-    /**
-     * Returns the child component with given name.
-     * @param name - name of child to find.
-     * @return child component or null.
-     */
-    ITraceControlComponent getChild(String name);
-    /**
-     * Gets children for given class type.
-     * @param clazz - a class type to get
-     * @return list of trace control components matching given class type.
-     */
-    List<ITraceControlComponent> getChildren(Class<? extends ITraceControlComponent> clazz);
-
-    /**
-     * @return the LTTng control service implementation.
-     */
-    ILttngControlService getControlService();
-
-    /**
-     * Sets the LTTng control service implementation.
-     * @param service - the service to set.
-     */
-    void setControlService(ILttngControlService service);
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-    /**
-     * Dispose any resource.
-     */
-    void dispose();
-
-    /**
-     * Adds a child component.
-     * @param component - child to add.
-     */
-    void addChild(ITraceControlComponent component);
-
-    /**
-     * Removes the given child component.
-     * @param component - the child to remove.
-     */
-    void removeChild(ITraceControlComponent component);
-
-    /**
-     * Removes all children.
-     */
-    void removeAllChildren();
-
-    /**
-     * Checks if child with given name exists.
-     * @param name - child name to search for.
-     * @return - true if exists else false.
-     */
-    boolean containsChild(String name);
-
-    /**
-     * Checks for children.
-     * @return true if one or more children exist else false
-     */
-    boolean hasChildren();
-
-    /**
-     * Adds a component listener for notification of component changes.
-     * @param listener - listener interface implementation to add.
-     */
-    void addComponentListener(ITraceControlComponentChangedListener listener);
-
-    /**
-     * Removes a component listener for notification of component changes.
-     * @param listener - listener interface implementation to remove.
-     */
-    void removeComponentListener(ITraceControlComponentChangedListener listener);
-
-    /**
-     * Notifies listeners about the addition of a child.
-     * @param parent - the parent where the child was added.
-     * @param component - the child that was added.
-     */
-    void fireComponentAdded(ITraceControlComponent parent, ITraceControlComponent component);
-
-    /**
-     * Notifies listeners about the removal of a child.
-     * @param parent - the parent where the child was removed.
-     * @param component - the child that was removed.
-     */
-    void fireComponentRemoved(ITraceControlComponent parent, ITraceControlComponent component);
-
-    /**
-     * Notifies listeners about the change of a component.
-     * @param component - the component that was changed.
-     */
-    void fireComponentChanged(ITraceControlComponent component);
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/ITraceControlComponentChangedListener.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/ITraceControlComponentChangedListener.java
deleted file mode 100644 (file)
index 385c300..0000000
+++ /dev/null
@@ -1,42 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.model;
-
-/**
- * <p>
- * Listener interface a class can implement to be notified about changes
- * of components
- * </p>
- *
- * @author Bernd Hufmann
- */
-public interface ITraceControlComponentChangedListener {
-    /**
-     * Interface for notifications about the addition of a component.
-     * @param parent - the parent where the child was added.
-     * @param component - the child that was added.
-     */
-    void componentAdded(ITraceControlComponent parent, ITraceControlComponent component);
-
-    /**
-     * Interface for notifications about the removal of a child.
-     * @param parent - the parent where the child was removed.
-     * @param component - the child that was removed.
-     */
-    void componentRemoved(ITraceControlComponent parent, ITraceControlComponent component);
-    /**
-     * NInterface for notifications about the change of a component.
-     * @param component - the component that was changed.
-     */
-    void componentChanged(ITraceControlComponent component);
-}
-
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/BaseEventComponent.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/BaseEventComponent.java
deleted file mode 100644 (file)
index 71253d2..0000000
+++ /dev/null
@@ -1,165 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl;
-
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IBaseEventInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IFieldInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEventType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.EventInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.property.BaseEventPropertySource;
-import org.eclipse.ui.views.properties.IPropertySource;
-
-/**
- * <p>
- * Implementation of the base trace event component.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class BaseEventComponent extends TraceControlComponent {
-    // ------------------------------------------------------------------------
-    // Constants
-    // ------------------------------------------------------------------------
-    /**
-     * Path to icon file for this component.
-     */
-    public static final String TRACE_EVENT_ICON_FILE_ENABLED = "icons/obj16/event_enabled.gif"; //$NON-NLS-1$
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-    /**
-     * The Event information implementation.
-     */
-    private IBaseEventInfo fEventInfo;
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-
-    /**
-     * Constructor
-     * @param name - the name of the component.
-     * @param parent - the parent of this component.
-     */
-    public BaseEventComponent(String name, ITraceControlComponent parent) {
-        super(name, parent);
-        setImage(TRACE_EVENT_ICON_FILE_ENABLED);
-        fEventInfo = new EventInfo(name);
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-    /**
-     * Sets the event information.
-     * @param eventInfo - the event info to set.
-     */
-    public void setEventInfo(IBaseEventInfo eventInfo) {
-        fEventInfo = eventInfo;
-    }
-
-    /**
-     * @return the event type.
-     */
-    public TraceEventType getEventType() {
-        return fEventInfo.getEventType();
-    }
-
-    /**
-     * Sets the event type to the given value.
-     * @param type - type to set.
-     */
-    public void setEventType(TraceEventType type) {
-        fEventInfo.setEventType(type);
-    }
-
-    /**
-     * Sets the event type to the value specified by the give name.
-     * @param typeName - the type name.
-     */
-    public void setEventType(String typeName) {
-        fEventInfo.setEventType(typeName);
-    }
-
-    /**
-     * @return the trace event log level
-     */
-    public TraceLogLevel getLogLevel() {
-        return fEventInfo.getLogLevel();
-    }
-
-    /**
-     * Sets the trace event log level to the given level
-     * @param level - event log level to set
-     */
-    public void setLogLevel(TraceLogLevel level) {
-        fEventInfo.setLogLevel(level);
-    }
-
-    /**
-     * Sets the trace event log level to the level specified by the given name.
-     * @param levelName - event log level name
-     */
-    public void setLogLevel(String levelName) {
-        fEventInfo.setLogLevel(levelName);
-    }
-
-    /**
-     * @return a String containing pairs if field name and data type
-     */
-    public String getFieldString() {
-        IFieldInfo[] fields = fEventInfo.getFields();
-        if ((fields != null) && (fields.length > 0)) {
-            StringBuffer buffer = new StringBuffer();
-            for (int i = 0; i < fields.length; i++) {
-                buffer.append(fields[i].getName());
-                buffer.append("="); //$NON-NLS-1$
-                buffer.append(fields[i].getFieldType());
-                if (i != fields.length-1) {
-                    buffer.append(";"); //$NON-NLS-1$
-                }
-            }
-            return buffer.toString();
-        }
-        return null;
-    }
-
-    @Override
-    public Object getAdapter(Class adapter) {
-        if (adapter == IPropertySource.class) {
-            return new BaseEventPropertySource(this);
-        }
-        return null;
-    }
-
-    /**
-     * @return target node component.
-     */
-    public TargetNodeComponent getTargetNode() {
-        return (TargetNodeComponent) getParent().getParent();
-    }
-
-    /**
-     * @return if provider kernel or UST
-     */
-    public boolean isKernel() {
-        return getParent() instanceof KernelProviderComponent;
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/KernelProviderComponent.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/KernelProviderComponent.java
deleted file mode 100644 (file)
index 76370b5..0000000
+++ /dev/null
@@ -1,82 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl;
-
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IBaseEventInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.property.KernelProviderPropertySource;
-import org.eclipse.ui.views.properties.IPropertySource;
-
-/**
- * <p>
- * Implementation of the Kernel provider component.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class KernelProviderComponent extends TraceControlComponent {
-
-    // ------------------------------------------------------------------------
-    // Constants
-    // ------------------------------------------------------------------------
-
-    /**
-     * Path to icon file for this component.
-     */
-    public static final String KERNEL_PROVIDER_ICON_FILE = "icons/obj16/targets.gif"; //$NON-NLS-1$
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-
-    /**
-     * Constructor
-     * @param name - the name of the component.
-     * @param parent - the parent of this component.
-     */
-    public KernelProviderComponent(String name, ITraceControlComponent parent) {
-        super(name, parent);
-        setToolTip(Messages.TraceControl_ProviderDisplayName);
-        setImage(KERNEL_PROVIDER_ICON_FILE);
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    /**
-     * Sets the events information for this component.
-     * @param eventInfos - events information to set.
-     */
-    public void setEventInfo(List<IBaseEventInfo> eventInfos) {
-        for (Iterator<IBaseEventInfo> iterator = eventInfos.iterator(); iterator.hasNext();) {
-            IBaseEventInfo baseEventInfo = iterator.next();
-            BaseEventComponent component = new BaseEventComponent(baseEventInfo.getName(), this);
-            component.setEventInfo(baseEventInfo);
-            addChild(component);
-        }
-    }
-
-    @Override
-    public Object getAdapter(Class adapter) {
-        if (adapter == IPropertySource.class) {
-            return new KernelProviderPropertySource(this);
-        }
-        return null;
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/NullControlService.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/NullControlService.java
deleted file mode 100644 (file)
index bbb1af3..0000000
+++ /dev/null
@@ -1,145 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2014, 2015 Wind River Systems, Inc. and others
- *
- * 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:
- *   Markus Schorn - Initial API and implementation
- *   Bernd Hufmann - Update for null safety
- *******************************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl;
-
-import static org.eclipse.tracecompass.common.core.NonNullUtils.checkNotNull;
-
-import java.util.Collections;
-import java.util.List;
-
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IBaseEventInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IChannelInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISessionInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISnapshotInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IUstProviderInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.LogLevelType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.service.ILttngControlService;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.service.LttngVersion;
-
-class NullControlService implements ILttngControlService {
-
-    @Override
-    public LttngVersion getVersion() {
-        return LttngVersion.NULL_VERSION;
-    }
-
-    @Override
-    public String getVersionString() {
-        return checkNotNull(LttngVersion.NULL_VERSION.toString());
-    }
-
-    @Override
-    public boolean isVersionSupported(String version) {
-        return false;
-    }
-
-    @Override
-    public List<String> getSessionNames(IProgressMonitor monitor) throws ExecutionException {
-        return checkNotNull(Collections.EMPTY_LIST);
-    }
-
-    @Override
-    public ISessionInfo getSession(String sessionName, IProgressMonitor monitor) throws ExecutionException {
-        return null;
-    }
-
-    @Override
-    public ISnapshotInfo getSnapshotInfo(String sessionName, IProgressMonitor monitor) throws ExecutionException {
-        return null;
-    }
-
-    @Override
-    public List<IBaseEventInfo> getKernelProvider(IProgressMonitor monitor) throws ExecutionException {
-        return checkNotNull(Collections.EMPTY_LIST);
-    }
-
-    @Override
-    public List<IUstProviderInfo> getUstProvider() throws ExecutionException {
-        return checkNotNull(Collections.EMPTY_LIST);
-    }
-
-    @Override
-    public List<IUstProviderInfo> getUstProvider(IProgressMonitor monitor) throws ExecutionException {
-        return checkNotNull(Collections.EMPTY_LIST);
-    }
-
-    @Override
-    public ISessionInfo createSession(ISessionInfo sessionInfo, IProgressMonitor monitor) throws ExecutionException {
-        return null;
-    }
-
-    @Override
-    public void destroySession(String sessionName, IProgressMonitor monitor) throws ExecutionException {
-    }
-
-    @Override
-    public void startSession(String sessionName, IProgressMonitor monitor) throws ExecutionException {
-    }
-
-    @Override
-    public void stopSession(String sessionName, IProgressMonitor monitor) throws ExecutionException {
-    }
-
-    @Override
-    public void enableChannels(String sessionName, List<String> channelNames, boolean isKernel, IChannelInfo info, IProgressMonitor monitor) throws ExecutionException {
-    }
-
-    @Override
-    public void disableChannels(String sessionName, List<String> channelNames, boolean isKernel, IProgressMonitor monitor) throws ExecutionException {
-    }
-
-    @Override
-    public void enableEvents(String sessionName, String channelName, List<String> eventNames, boolean isKernel, String filterExpression, IProgressMonitor monitor) throws ExecutionException {
-    }
-
-    @Override
-    public void enableSyscalls(String sessionName, String channelName, IProgressMonitor monitor) throws ExecutionException {
-    }
-
-    @Override
-    public void enableProbe(String sessionName, String channelName, String eventName, boolean isFunction, String probe, IProgressMonitor monitor) throws ExecutionException {
-    }
-
-    @Override
-    public void enableLogLevel(String sessionName, String channelName, String eventName, LogLevelType logLevelType, TraceLogLevel level, String filterExpression, IProgressMonitor monitor) throws ExecutionException {
-    }
-
-    @Override
-    public void disableEvent(String sessionName, String channelName, List<String> eventNames, boolean isKernel, IProgressMonitor monitor) throws ExecutionException {
-    }
-
-    @Override
-    public List<String> getContextList(IProgressMonitor monitor) throws ExecutionException {
-        return checkNotNull(Collections.EMPTY_LIST);
-    }
-
-    @Override
-    public void addContexts(String sessionName, String channelName, String eventName, boolean isKernel, List<String> contexts, IProgressMonitor monitor) throws ExecutionException {
-    }
-
-    @Override
-    public void calibrate(boolean isKernel, IProgressMonitor monitor) throws ExecutionException {
-    }
-
-    @Override
-    public void recordSnapshot(String sessionName, IProgressMonitor monitor) throws ExecutionException {
-    }
-
-    @Override
-    public void runCommands(IProgressMonitor monitor, List<String> commands) throws ExecutionException {
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TargetNodeComponent.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TargetNodeComponent.java
deleted file mode 100644 (file)
index 8991cde..0000000
+++ /dev/null
@@ -1,486 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2015 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
- *   Markus Schorn - Bug 448058: Use org.eclipse.remote in favor of RSE
- *   Bernd Hufmann - Update to org.eclipse.remote API 2.0
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl;
-
-import static java.text.MessageFormat.format;
-import static org.eclipse.tracecompass.common.core.NonNullUtils.checkNotNull;
-
-import java.util.List;
-
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.core.runtime.jobs.IJobChangeEvent;
-import org.eclipse.core.runtime.jobs.Job;
-import org.eclipse.core.runtime.jobs.JobChangeAdapter;
-import org.eclipse.jdt.annotation.NonNull;
-import org.eclipse.jface.dialogs.ErrorDialog;
-import org.eclipse.remote.core.IRemoteConnection;
-import org.eclipse.remote.core.IRemoteConnectionChangeListener;
-import org.eclipse.remote.core.RemoteConnectionChangeEvent;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TargetNodeState;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.property.TargetNodePropertySource;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.service.ILttngControlService;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.service.LTTngControlServiceFactory;
-import org.eclipse.tracecompass.tmf.remote.core.proxy.RemoteSystemProxy;
-import org.eclipse.tracecompass.tmf.remote.core.shell.ICommandShell;
-import org.eclipse.ui.PlatformUI;
-import org.eclipse.ui.views.properties.IPropertySource;
-
-/**
- * <p>
- * Implementation of the trace node component.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class TargetNodeComponent extends TraceControlComponent implements IRemoteConnectionChangeListener {
-
-    // ------------------------------------------------------------------------
-    // Constants
-    // ------------------------------------------------------------------------
-
-    /**
-     * Path to icon file for this component (state connected).
-     */
-    public static final String TARGET_NODE_CONNECTED_ICON_FILE = "icons/obj16/target_connected.gif"; //$NON-NLS-1$
-    /**
-     * Path to icon file for this component (state disconnected).
-     */
-    public static final String TARGET_NODE_DISCONNECTED_ICON_FILE = "icons/obj16/target_disconnected.gif"; //$NON-NLS-1$
-
-    private static final ILttngControlService NULL_CONTROL_SERVICE = new NullControlService();
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-
-    /**
-     * The node connection state.
-     */
-    private TargetNodeState fState = TargetNodeState.DISCONNECTED;
-    /**
-     * The image to be displayed in state disconnected.
-     */
-    private Image fDisconnectedImage = null;
-    /**
-     * The remote proxy implementation.
-     */
-    private @NonNull RemoteSystemProxy fRemoteProxy;
-    /**
-     * The control service for LTTng specific commands.
-     */
-    private ILttngControlService fService = null;
-    /**
-     * The command shell for issuing commands.
-     */
-    private ICommandShell fShell = null;
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-
-    /**
-     * Constructor
-     *
-     * @param name
-     *            the name of the component
-     * @param parent
-     *            the parent of the component
-     * @param proxy
-     *            the remote proxy implementation
-     */
-    public TargetNodeComponent(String name, ITraceControlComponent parent, @NonNull RemoteSystemProxy proxy) {
-        super(name, parent);
-        setImage(TARGET_NODE_CONNECTED_ICON_FILE);
-        fDisconnectedImage = Activator.getDefault().loadIcon(TARGET_NODE_DISCONNECTED_ICON_FILE);
-        fRemoteProxy = proxy;
-        fRemoteProxy.getRemoteConnection().addConnectionChangeListener(this);
-        setToolTip(fRemoteProxy.getRemoteConnection().getName());
-    }
-
-    /**
-     * Constructor (using default proxy)
-     *
-     * @param name
-     *            the name of the component
-     * @param parent
-     *            the parent of the component
-     * @param host
-     *            the host connection implementation
-     */
-    public TargetNodeComponent(String name, ITraceControlComponent parent, @NonNull IRemoteConnection host) {
-        this(name, parent, new RemoteSystemProxy(host));
-    }
-
-    @Override
-    public void dispose() {
-        fRemoteProxy.getRemoteConnection().removeConnectionChangeListener(this);
-        fRemoteProxy.dispose();
-        disposeControlService();
-    }
-
-    private void disposeControlService() {
-        fService = null;
-        final ICommandShell shell = fShell;
-        if (shell != null) {
-            shell.dispose();
-            fShell = null;
-        }
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    @Override
-    public Image getImage() {
-        if (fState == TargetNodeState.CONNECTED) {
-            return super.getImage();
-        }
-        return fDisconnectedImage;
-    }
-
-    @Override
-    public TargetNodeState getTargetNodeState() {
-        return fState;
-    }
-
-    @Override
-    public void setTargetNodeState(TargetNodeState state) {
-        fState = state;
-        fireComponentChanged(TargetNodeComponent.this);
-    }
-
-    @Override
-    public ILttngControlService getControlService() {
-        return fService == null ? NULL_CONTROL_SERVICE : fService;
-    }
-
-    @Override
-    public void setControlService(ILttngControlService service) {
-        fService = service;
-    }
-
-    @Override
-    public Object getAdapter(Class adapter) {
-        if (adapter == IPropertySource.class) {
-            return new TargetNodePropertySource(this);
-        }
-        return null;
-    }
-
-    /**
-     * @return remote system proxy implementation
-     */
-    public @NonNull RemoteSystemProxy getRemoteSystemProxy() {
-        return fRemoteProxy;
-    }
-
-    /**
-     * @return all available sessions.
-     */
-    public TraceSessionComponent[] getSessions() {
-        List<ITraceControlComponent> compenents = getChildren(TraceSessionGroup.class);
-        if (compenents.size() > 0) {
-            TraceSessionGroup group = (TraceSessionGroup)compenents.get(0);
-            List<ITraceControlComponent> sessions = group.getChildren(TraceSessionComponent.class);
-            return sessions.toArray(new TraceSessionComponent[sessions.size()]);
-        }
-        return new TraceSessionComponent[0];
-    }
-
-    /**
-     * @return node version
-     */
-    public String getNodeVersion() {
-        // Control service is null during connection to node
-        if (getControlService() != NULL_CONTROL_SERVICE) {
-            return getControlService().getVersionString();
-        }
-        return ""; //$NON-NLS-1$
-    }
-
-    /**
-     * Returns if node supports filtering of events
-     * @return <code>true</code> if node supports filtering else <code>false</code>
-     */
-    public boolean isEventFilteringSupported() {
-        return getControlService().isVersionSupported("2.1.0"); //$NON-NLS-1$
-    }
-
-    /**
-     * Returns if node supports networks streaming or not
-     * @return <code>true</code> if node supports filtering else <code>false</code>
-     *
-     */
-    public boolean isNetworkStreamingSupported() {
-        return getControlService().isVersionSupported("2.1.0"); //$NON-NLS-1$
-    }
-
-    /**
-     * Returns if node supports configuring buffer type  or not
-     * @return <code>true</code> if node supports buffer type configuration else <code>false</code>
-     */
-    public boolean isBufferTypeConfigSupported() {
-        return getControlService().isVersionSupported("2.2.0"); //$NON-NLS-1$
-    }
-
-    /**
-     * Returns if node supports trace file rotation or not
-     * @return <code>true</code> if node supports trace file rotation else <code>false</code>
-     */
-    public boolean isTraceFileRotationSupported() {
-        return getControlService().isVersionSupported("2.2.0"); //$NON-NLS-1$
-    }
-
-    /**
-     * Returns if node supports periodical flush for metadata or not
-     * @return <code>true</code> if node supports periodical flush for metadata else <code>false</code>
-     */
-    public boolean isPeriodicalMetadataFlushSupported() {
-        return getControlService().isVersionSupported("2.2.0"); //$NON-NLS-1$
-    }
-    /**
-     * Returns if node supports snapshots or not
-     * @return <code>true</code> if it supports snapshots else <code>false</code>
-     *
-     */
-    public boolean isSnapshotSupported() {
-        return getControlService().isVersionSupported("2.3.0"); //$NON-NLS-1$
-    }
-    /**
-     * Returns if node supports live or not
-     * @return <code>true</code> if it supports live else <code>false</code>
-     *
-     */
-    public boolean isLiveSupported() {
-        return getControlService().isVersionSupported("2.4.0"); //$NON-NLS-1$;
-    }
-    /**
-     * Returns if node supports adding contexts on event
-     * @return <code>true</code> if it supports adding contexts on events else <code>false</code>
-     *
-     */
-    public boolean isContextOnEventSupported() {
-        return !getControlService().isVersionSupported("2.2.0"); //$NON-NLS-1$
-    }
-
-    /**
-     * Checks if given version is supported by this ILTTngControlService implementation.
-     *
-     * @param version The version to check
-     * @return <code>true</code> if version is supported else <code>false</code>
-     */
-    public boolean isVersionSupported(String version) {
-        return getControlService().isVersionSupported(version);
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    public void connectionChanged(RemoteConnectionChangeEvent e) {
-        if (fState == TargetNodeState.CONNECTING) {
-            return;
-        }
-
-        switch (e.getType()) {
-        case RemoteConnectionChangeEvent.CONNECTION_CLOSED:
-        case RemoteConnectionChangeEvent.CONNECTION_ABORTED:
-            handleDisconnected();
-            break;
-        case RemoteConnectionChangeEvent.CONNECTION_OPENED:
-            handleConnected();
-            break;
-        default:
-            break;
-        }
-    }
-
-    /**
-     * Method to connect this node component to the remote target node.
-     */
-    public void connect() {
-        if (fState == TargetNodeState.DISCONNECTED) {
-            try {
-                setTargetNodeState(TargetNodeState.CONNECTING);
-                Job job = new Job(format(Messages.TraceControl_OpenConnectionTo, getName())) {
-                    @Override
-                    protected IStatus run(IProgressMonitor monitor) {
-                        try {
-                            fRemoteProxy.connect(checkNotNull(monitor));
-                            return Status.OK_STATUS;
-                        } catch (Exception e) {
-                            return new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.TraceControl_ConnectionFailure, e);
-                        }
-                    }
-                };
-                job.addJobChangeListener(new JobChangeAdapter() {
-                    @Override
-                    public void done(IJobChangeEvent event) {
-                        IStatus status = event.getResult();
-                        if (status.isOK()) {
-                            handleConnected();
-                        } else {
-                            handleDisconnected();
-                            if (status.getSeverity() != IStatus.CANCEL) {
-                                Activator.getDefault().getLog().log(status);
-                            }
-                        }
-                    }
-                });
-                job.schedule();
-            } catch (Exception e) {
-                setTargetNodeState(TargetNodeState.DISCONNECTED);
-                Activator.getDefault().logError(Messages.TraceControl_ConnectionFailure + " (" + getName() + "). \n", e); //$NON-NLS-1$ //$NON-NLS-2$
-            }
-        }
-    }
-
-    /**
-     * Method to disconnect this node component to the remote target node.
-     */
-    public void disconnect() {
-        if (fState == TargetNodeState.CONNECTED) {
-            try {
-                setTargetNodeState(TargetNodeState.DISCONNECTING);
-                fRemoteProxy.disconnect();
-            } catch (Exception e) {
-                Activator.getDefault().logError(Messages.TraceControl_DisconnectionFailure + " (" + getName() + "). \n", e); //$NON-NLS-1$ //$NON-NLS-2$
-            } finally {
-                handleDisconnected();
-            }
-        }
-    }
-
-    /**
-     * Retrieves the trace configuration from the target node and populates the
-     * information in the tree model. The execution is done in a own job.
-     */
-    public void getConfigurationFromNode() {
-        Job job = new Job(Messages.TraceControl_RetrieveNodeConfigurationJob) {
-            @Override
-            protected IStatus run(IProgressMonitor monitor) {
-
-                try {
-                    // Get provider information from node
-                    TraceProviderGroup providerGroup = new TraceProviderGroup(Messages.TraceControl_ProviderDisplayName, TargetNodeComponent.this);
-                    addChild(providerGroup);
-
-                    // Get session information from node
-                    TraceSessionGroup sessionGroup = new TraceSessionGroup(Messages.TraceControl_AllSessionsDisplayName, TargetNodeComponent.this);
-                    addChild(sessionGroup);
-
-                    providerGroup.getProviderFromNode(monitor);
-                    sessionGroup.getSessionsFromNode(monitor);
-                } catch (ExecutionException e) {
-                    removeAllChildren();
-                    return new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.TraceControl_RetrieveNodeConfigurationFailure, e);
-                }
-
-                return Status.OK_STATUS;
-            }
-        };
-        job.setUser(true);
-        job.schedule();
-    }
-
-    /**
-     * Refresh the node configuration
-     */
-    public void refresh() {
-        removeAllChildren();
-        getConfigurationFromNode();
-    }
-
-    // ------------------------------------------------------------------------
-    // Helper function
-    // ------------------------------------------------------------------------
-
-    /**
-     * @return returns the control service for LTTng specific commands.
-     * @throws ExecutionException
-     */
-    private ILttngControlService createControlService() throws ExecutionException {
-        if (fService == null) {
-            try {
-                ICommandShell shell = fRemoteProxy.createCommandShell();
-                fShell = shell;
-                fService = LTTngControlServiceFactory.getLttngControlService(shell);
-            } catch (ExecutionException e) {
-                disposeControlService();
-                throw e;
-            }
-        }
-        return fService;
-    }
-
-    /**
-     * Handles the connected event.
-     */
-    private void handleConnected() {
-        try {
-            createControlService();
-            getConfigurationFromNode();
-            // Set connected only after the control service has been created and the jobs for creating the
-            // sub-nodes are scheduled.
-            setTargetNodeState(TargetNodeState.CONNECTED);
-        } catch (final ExecutionException e) {
-            // Disconnect only if no control service, otherwise stay connected.
-            if (getControlService() == NULL_CONTROL_SERVICE) {
-                fState = TargetNodeState.CONNECTED;
-                disconnect();
-            }
-
-            // Notify user
-            Display.getDefault().asyncExec(new Runnable() {
-                @Override
-                public void run() {
-                    ErrorDialog er = new ErrorDialog(PlatformUI.getWorkbench().getActiveWorkbenchWindow().getShell(),
-                            Messages.TraceControl_ErrorTitle, Messages.TraceControl_RetrieveNodeConfigurationFailure,
-                            new Status(IStatus.ERROR, Activator.PLUGIN_ID, e.getMessage(), e),
-                            IStatus.ERROR);
-                    er.open();
-                }
-            });
-            Activator.getDefault().logError(Messages.TraceControl_RetrieveNodeConfigurationFailure + " (" + getName() + "). \n", e); //$NON-NLS-1$ //$NON-NLS-2$
-        }
-    }
-
-    /**
-     * Handles the disconnected event.
-     */
-    private void handleDisconnected() {
-        disposeControlService();
-        setTargetNodeState(TargetNodeState.DISCONNECTED);
-        removeAllChildren();
-    }
-
-    @Override
-    public void addChild(ITraceControlComponent component) {
-        if (getTargetNodeState() == TargetNodeState.DISCONNECTED) {
-            return;
-        }
-        super.addChild(component);
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceChannelComponent.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceChannelComponent.java
deleted file mode 100644 (file)
index bfdf766..0000000
+++ /dev/null
@@ -1,400 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2015 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IChannelInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IEventInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.LogLevelType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceChannelOutputType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEnablement;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.ChannelInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.ProbeEventInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.property.TraceChannelPropertySource;
-import org.eclipse.ui.views.properties.IPropertySource;
-
-
-/**
- * <p>
- * Implementation of the trace channel component.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class TraceChannelComponent extends TraceControlComponent {
-
-    // ------------------------------------------------------------------------
-    // Constants
-    // ------------------------------------------------------------------------
-
-    /**
-     * Path to icon file for this component (state enabled).
-     */
-    public static final String TRACE_CHANNEL_ICON_FILE_ENABLED = "icons/obj16/channel.gif"; //$NON-NLS-1$
-    /**
-     * Path to icon file for this component (state disabled).
-     */
-    public static final String TRACE_CHANNEL_ICON_FILE_DISABLED = "icons/obj16/channel_disabled.gif"; //$NON-NLS-1$
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-
-    /**
-     * The channel information.
-     */
-    private IChannelInfo fChannelInfo = null;
-    /**
-     * The image to be displayed in disabled state.
-     */
-    private Image fDisabledImage = null;
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-
-    /**
-     * Constructor
-     * @param name - the name of the component.
-     * @param parent - the parent of this component.
-     */
-    public TraceChannelComponent(String name, ITraceControlComponent parent) {
-        super(name, parent);
-        setImage(TRACE_CHANNEL_ICON_FILE_ENABLED);
-        setToolTip(Messages.TraceControl_ChannelDisplayName);
-        fChannelInfo = new ChannelInfo(name);
-        fDisabledImage = Activator.getDefault().loadIcon(TRACE_CHANNEL_ICON_FILE_DISABLED);
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    @Override
-    public Image getImage() {
-        if (fChannelInfo.getState() == TraceEnablement.DISABLED) {
-            return fDisabledImage;
-        }
-        return super.getImage();
-    }
-
-    /**
-     * Sets the channel information.
-     *
-     * @param channelInfo
-     *            The channel info to assign to this component
-     */
-    public void setChannelInfo(IChannelInfo channelInfo) {
-        fChannelInfo = channelInfo;
-        IEventInfo[] events = fChannelInfo.getEvents();
-        List<ITraceControlComponent> eventComponents = new ArrayList<>();
-        for (int i = 0; i < events.length; i++) {
-            TraceEventComponent event = null;
-            if (events[i].getClass() == ProbeEventInfo.class) {
-                event = new TraceProbeEventComponent(events[i].getName(), this);
-            } else {
-                event = new TraceEventComponent(events[i].getName(), this);
-            }
-
-            eventComponents.add(event);
-            event.setEventInfo(events[i]);
-        }
-        if (!eventComponents.isEmpty()) {
-            setChildren(eventComponents);
-        }
-    }
-
-    /**
-     * @return the overwrite mode value.
-     */
-    public boolean isOverwriteMode() {
-        return fChannelInfo.isOverwriteMode();
-    }
-    /**
-     * Sets the overwrite mode value to the given mode.
-     * @param mode - mode to set.
-     */
-    public void setOverwriteMode(boolean mode){
-        fChannelInfo.setOverwriteMode(mode);
-    }
-    /**
-     * @return the sub-buffer size.
-     */
-    public long getSubBufferSize() {
-        return fChannelInfo.getSubBufferSize();
-    }
-    /**
-     * Sets the sub-buffer size to the given value.
-     * @param bufferSize - size to set to set.
-     */
-    public void setSubBufferSize(long bufferSize) {
-        fChannelInfo.setSubBufferSize(bufferSize);
-    }
-    /**
-     * @return the number of sub-buffers.
-     */
-    public int getNumberOfSubBuffers() {
-        return fChannelInfo.getNumberOfSubBuffers();
-    }
-    /**
-     * Sets the number of sub-buffers to the given value.
-     * @param numberOfSubBuffers - value to set.
-     */
-    public void setNumberOfSubBuffers(int numberOfSubBuffers) {
-        fChannelInfo.setNumberOfSubBuffers(numberOfSubBuffers);
-    }
-    /**
-     * @return the switch timer interval.
-     */
-    public long getSwitchTimer() {
-        return fChannelInfo.getSwitchTimer();
-    }
-    /**
-     * Sets the switch timer interval to the given value.
-     * @param timer - timer value to set.
-     */
-    public void setSwitchTimer(long timer) {
-        fChannelInfo.setSwitchTimer(timer);
-    }
-    /**
-     * @return the read timer interval.
-     */
-    public long getReadTimer() {
-        return fChannelInfo.getReadTimer();
-    }
-    /**
-     * Sets the read timer interval to the given value.
-     * @param timer - timer value to set..
-     */
-    public void setReadTimer(long timer) {
-        fChannelInfo.setReadTimer(timer);
-    }
-    /**
-     * @return the output type.
-     */
-    public TraceChannelOutputType getOutputType() {
-        return fChannelInfo.getOutputType();
-    }
-    /**
-     * Sets the output type to the given value.
-     * @param type - type to set.
-     */
-    public void setOutputType(TraceChannelOutputType type) {
-        fChannelInfo.setOutputType(type);
-    }
-    /**
-     * Sets the output type to the given value.
-     * @param type - type to set.
-     */
-    public void setOutputType(String type) {
-        fChannelInfo.setOutputType(type);
-    }
-
-    /**
-     * @return the channel state (enabled or disabled).
-     */
-    public TraceEnablement getState() {
-        return fChannelInfo.getState();
-    }
-    /**
-     * Sets the channel state (enablement) to the given value.
-     * @param state - state to set.
-     */
-    public void setState(TraceEnablement state) {
-        fChannelInfo.setState(state);
-    }
-    /**
-     * Sets the channel state (enablement) to the value specified by the given name.
-     * @param stateName - state to set.
-     */
-    public void setState(String stateName) {
-        fChannelInfo.setState(stateName);
-    }
-
-    /**
-     * @return maximum size of trace files
-     */
-    public long getMaxSizeTraceFiles() {
-        return fChannelInfo.getMaxSizeTraceFiles();
-    }
-    /**
-     * @return maximum number of trace files
-     */
-    public int getMaxNumberTraceFiles() {
-        return fChannelInfo.getMaxNumberTraceFiles();
-    }
-
-    @Override
-    public Object getAdapter(Class adapter) {
-        if (adapter == IPropertySource.class) {
-            return new TraceChannelPropertySource(this);
-        }
-        return null;
-    }
-
-    /**
-     * @return session name from parent
-     */
-    public String getSessionName() {
-       return ((TraceDomainComponent)getParent()).getSessionName();
-    }
-
-    /**
-     * @return session from parent
-     */
-    public TraceSessionComponent getSession() {
-       return ((TraceDomainComponent)getParent()).getSession();
-    }
-
-    /**
-     * @return if domain is kernel or UST
-     */
-    public boolean isKernel() {
-        return ((TraceDomainComponent)getParent()).isKernel();
-    }
-
-    /**
-     * @return the parent target node
-     */
-    public TargetNodeComponent getTargetNode() {
-        return ((TraceDomainComponent)getParent()).getTargetNode();
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    /**
-     * Enables a list of events with no additional parameters.
-     *
-     * @param eventNames
-     *            - a list of event names to enabled.
-     * @param monitor
-     *            - a progress monitor
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    public void enableEvents(List<String> eventNames, IProgressMonitor monitor) throws ExecutionException {
-        enableEvents(eventNames, null,  monitor);
-    }
-
-    /**
-     * Enables a list of events with no additional parameters.
-     *
-     * @param eventNames
-     *            - a list of event names to enabled.
-     * @param filterExpression
-     *            - a filter expression
-     * @param monitor
-     *            - a progress monitor
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    public void enableEvents(List<String> eventNames, String filterExpression, IProgressMonitor monitor) throws ExecutionException {
-        getControlService().enableEvents(getSessionName(), getName(), eventNames, isKernel(), filterExpression,  monitor);
-    }
-
-    /**
-     * Enables all syscalls (for kernel domain)
-     *
-     * @param monitor
-     *            - a progress monitor
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    public void enableSyscalls(IProgressMonitor monitor) throws ExecutionException {
-        getControlService().enableSyscalls(getSessionName(), getName(), monitor);
-    }
-
-    /**
-     * Enables a dynamic probe (for kernel domain)
-     *
-     * @param eventName
-     *            - event name for probe
-     * @param isFunction
-     *            - true for dynamic function entry/return probe else false
-     * @param probe
-     *            - the actual probe
-     * @param monitor
-     *            - a progress monitor
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    public void enableProbe(String eventName, boolean isFunction, String probe,
-            IProgressMonitor monitor) throws ExecutionException {
-        getControlService().enableProbe(getSessionName(), getName(), eventName, isFunction, probe, monitor);
-    }
-
-    /**
-     * Enables events using log level.
-     *
-     * @param eventName
-     *            - a event name
-     * @param logLevelType
-     *            - a log level type
-     * @param level
-     *            - a log level
-     * @param filterExpression
-     *            - a filter expression
-     * @param monitor
-     *            - a progress monitor
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    public void enableLogLevel(String eventName, LogLevelType logLevelType,
-            TraceLogLevel level, String filterExpression, IProgressMonitor monitor)
-            throws ExecutionException {
-        getControlService().enableLogLevel(getSessionName(), getName(), eventName, logLevelType, level, filterExpression, monitor);
-    }
-
-    /**
-     * Enables a list of events with no additional parameters.
-     *
-     * @param eventNames
-     *            - a list of event names to enabled.
-     * @param monitor
-     *            - a progress monitor
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    public void disableEvent(List<String> eventNames, IProgressMonitor monitor)
-            throws ExecutionException {
-        getControlService().disableEvent(getParent().getParent().getName(),
-                getName(), eventNames, isKernel(), monitor);
-    }
-
-    /**
-     * Add contexts to given channels and or events
-     *
-     * @param contexts
-     *            - a list of contexts to add
-     * @param monitor
-     *            - a progress monitor
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    public void addContexts(List<String> contexts, IProgressMonitor monitor)
-            throws ExecutionException {
-        getControlService().addContexts(getSessionName(), getName(), null,
-                isKernel(), contexts, monitor);
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceControlComponent.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceControlComponent.java
deleted file mode 100644 (file)
index f1ddf76..0000000
+++ /dev/null
@@ -1,333 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl;
-
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.core.runtime.ListenerList;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TargetNodeState;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponentChangedListener;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.service.ILttngControlService;
-
-/**
- * <p>
- * Base implementation for trace control component.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class TraceControlComponent implements ITraceControlComponent {
-
-    // ------------------------------------------------------------------------
-    // Constants
-    // ------------------------------------------------------------------------
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-    /**
-     * The name of the component
-     */
-    private String fName = ""; //$NON-NLS-1$
-    /**
-     * The image to be displayed for the component.
-     */
-    private Image fImage = null;
-    /**
-     * The tool tip to be displayed for the component.
-     */
-    private String fToolTip = null;
-    /**
-     * The parent component.
-     */
-    private ITraceControlComponent fParent = null;
-    /**
-     * The list if children components.
-     */
-    private final List<ITraceControlComponent> fChildren = new ArrayList<>();
-    /**
-     * The list of listeners to be notified about changes.
-     */
-    private final ListenerList fListeners = new ListenerList();
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-
-    /**
-     * Constructor
-     * @param name - the name of the component.
-     */
-    public TraceControlComponent(String name) {
-        this(name, null);
-    }
-
-    /**
-     * Constructor
-     * @param name - the name of the component.
-     * @param parent - the parent component.
-     */
-    public TraceControlComponent(String name, ITraceControlComponent parent) {
-        fName = name;
-        fParent = parent;
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    @Override
-    public String getName() {
-        return fName;
-    }
-
-    @Override
-    public void setName(String name) {
-        fName = name;
-    }
-
-    @Override
-    public Image getImage() {
-        return fImage;
-    }
-
-    @Override
-    public void setImage(String path) {
-        fImage = Activator.getDefault().loadIcon(path);
-    }
-
-    @Override
-    public void setImage(Image image) {
-        fImage = image;
-    }
-
-    @Override
-    public String getToolTip() {
-        return fToolTip;
-    }
-
-    @Override
-    public void setToolTip(String toolTip) {
-        fToolTip = toolTip;
-    }
-
-    @Override
-    public TargetNodeState getTargetNodeState() {
-        if (getParent() != null) {
-            return getParent().getTargetNodeState();
-        }
-        return TargetNodeState.DISCONNECTED;
-    }
-
-    @Override
-    public void setTargetNodeState(TargetNodeState state) {
-        if (getParent() != null) {
-            getParent().setTargetNodeState(state);
-        }
-    }
-
-    @Override
-    public ITraceControlComponent getParent() {
-        return fParent;
-    }
-
-    @Override
-    public void setParent(ITraceControlComponent parent) {
-        fParent = parent;
-    }
-
-    @Override
-    public ITraceControlComponent[] getChildren() {
-        return fChildren.toArray(new ITraceControlComponent[fChildren.size()]);
-    }
-
-    @Override
-    public void setChildren(List<ITraceControlComponent> children) {
-        for (Iterator<ITraceControlComponent> iterator = children.iterator(); iterator.hasNext();) {
-            ITraceControlComponent traceControlComponent = iterator.next();
-            fChildren.add(traceControlComponent);
-            fireComponentChanged(this);
-        }
-    }
-
-    @Override
-    public ITraceControlComponent getChild(String name) {
-        ITraceControlComponent child = null;
-        for (int i = 0; i < fChildren.size(); i++) {
-            if (fChildren.get(i).getName().equals(name)) {
-                child = fChildren.get(i);
-                break;
-            }
-        }
-        return child;
-    }
-
-    @Override
-    public List<ITraceControlComponent> getChildren(Class<? extends ITraceControlComponent> clazz) {
-       List<ITraceControlComponent> list = new ArrayList<>();
-
-       for (Iterator<ITraceControlComponent> iterator = fChildren.iterator(); iterator.hasNext();) {
-           ITraceControlComponent child = iterator.next();
-           if (child.getClass() == clazz) {
-               list.add(child);
-           }
-       }
-       return list;
-    }
-
-    @Override
-    public ILttngControlService getControlService() {
-        if (getParent() != null) {
-            return getParent().getControlService();
-        }
-        return null;
-    }
-
-    @Override
-    public void setControlService(ILttngControlService service) {
-        if (getParent() != null) {
-            getParent().setControlService(service);
-        }
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    public void dispose() {
-        // default implementation
-    }
-
-    @Override
-    public void addChild(ITraceControlComponent component) {
-        if (component != null) {
-            fChildren.add(component);
-        }
-        fireComponentAdded(this, component);
-    }
-
-    @Override
-    public void removeChild(ITraceControlComponent component) {
-        if (component != null) {
-            fChildren.remove(component);
-            component.dispose();
-        }
-        fireComponentRemoved(this, component);
-    }
-
-    @Override
-    public void removeAllChildren() {
-        for (Iterator<ITraceControlComponent> iterator = fChildren.iterator(); iterator.hasNext();) {
-            ITraceControlComponent child = iterator.next();
-            child.removeAllChildren();
-        }
-        fChildren.clear();
-//        fireCompenentChanged(this);
-    }
-
-    @Override
-    public boolean containsChild(String name) {
-        boolean retValue = false;
-        for (int i = 0; i < fChildren.size(); i++) {
-            if (fChildren.get(i).getName().equals(name)) {
-                retValue = true;
-                break;
-            }
-        }
-        return retValue;
-    }
-
-    @Override
-    public boolean hasChildren() {
-        return !fChildren.isEmpty();
-    }
-
-    @Override
-    public void addComponentListener(ITraceControlComponentChangedListener listener) {
-        if (fParent != null) {
-            fParent.addComponentListener(listener);
-        } else {
-            fListeners.add(listener);
-        }
-    }
-
-    @Override
-    public void removeComponentListener(ITraceControlComponentChangedListener listener) {
-        if (fParent != null) {
-            fParent.removeComponentListener(listener);
-        } else {
-            fListeners.remove(listener);
-        }
-    }
-
-    @Override
-    public void fireComponentAdded(ITraceControlComponent parent, ITraceControlComponent component) {
-        if (component == null) {
-            return;
-        }
-
-        if (fParent != null) {
-            fParent.fireComponentAdded(parent, component);
-        } else {
-            Object[] listeners = fListeners.getListeners();
-            for (int i = 0; i < listeners.length; i++) {
-                ITraceControlComponentChangedListener listener = (ITraceControlComponentChangedListener) listeners[i];
-                listener.componentAdded(parent, component);
-            }
-        }
-    }
-
-    @Override
-    public void fireComponentRemoved(ITraceControlComponent parent, ITraceControlComponent component) {
-        if (component == null) {
-            return;
-        }
-
-        if (fParent != null) {
-            fParent.fireComponentRemoved(parent, component);
-        } else {
-            Object[] listeners = fListeners.getListeners();
-            for (int i = 0; i < listeners.length; i++) {
-                ITraceControlComponentChangedListener listener = (ITraceControlComponentChangedListener) listeners[i];
-                listener.componentRemoved(parent, component);
-            }
-        }
-    }
-
-    @Override
-    public void fireComponentChanged(ITraceControlComponent component) {
-        if (component == null) {
-            return;
-        }
-
-        if (fParent != null) {
-            fParent.fireComponentChanged(component);
-        } else {
-            Object[] listeners = fListeners.getListeners();
-            for (int i = 0; i < listeners.length; i++) {
-                ITraceControlComponentChangedListener listener = (ITraceControlComponentChangedListener) listeners[i];
-                listener.componentChanged(component);
-            }
-        }
-    }
-
-    @Override
-    public Object getAdapter(Class adapter) {
-        return null;
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceControlContentProvider.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceControlContentProvider.java
deleted file mode 100644 (file)
index db9d145..0000000
+++ /dev/null
@@ -1,68 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl;
-
-import org.eclipse.jface.viewers.ITreeContentProvider;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
-
-/**
- * <p>
- * Tree content provider implementation for trace control view.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class TraceControlContentProvider implements ITreeContentProvider {
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    public void dispose() {
-    }
-
-    @Override
-    public void inputChanged(Viewer viewer, Object oldInput, Object newInput) {
-    }
-
-    @Override
-    public Object[] getElements(Object inputElement) {
-        return getChildren(inputElement);
-    }
-
-    @Override
-    public Object[] getChildren(Object parentElement) {
-
-        if (parentElement instanceof ITraceControlComponent) {
-            return ((ITraceControlComponent)parentElement).getChildren();
-        }
-        return new Object[0];
-    }
-
-    @Override
-    public Object getParent(Object element) {
-        if (element instanceof ITraceControlComponent) {
-            return ((ITraceControlComponent)element).getParent();
-        }
-        return null;
-    }
-
-    @Override
-    public boolean hasChildren(Object element) {
-        if (element instanceof ITraceControlComponent) {
-            return ((ITraceControlComponent)element).hasChildren();
-        }
-        return false;
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceControlLabelProvider.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceControlLabelProvider.java
deleted file mode 100644 (file)
index dbfceee..0000000
+++ /dev/null
@@ -1,54 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl;
-
-import org.eclipse.jface.viewers.ColumnLabelProvider;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
-
-/**
- * <p>
- * Label provider for trace control tree viewer.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class TraceControlLabelProvider extends ColumnLabelProvider {
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    public Image getImage(Object element) {
-        if ((element != null) && (element instanceof ITraceControlComponent)) {
-            return ((ITraceControlComponent) element).getImage();
-        }
-        return null;
-    }
-
-    @Override
-    public String getText(Object element) {
-        if ((element != null) && (element instanceof ITraceControlComponent)) {
-            return ((ITraceControlComponent) element).getName();
-        }
-        return "";//$NON-NLS-1$
-    }
-
-    @Override
-    public String getToolTipText(Object element) {
-        if ((element != null) && (element instanceof ITraceControlComponent)) {
-            return ((ITraceControlComponent) element).getToolTip();
-        }
-        return null;
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceControlPropertyTester.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceControlPropertyTester.java
deleted file mode 100644 (file)
index 5c38085..0000000
+++ /dev/null
@@ -1,44 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2013, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl;
-
-import org.eclipse.core.expressions.PropertyTester;
-
-/**
- *
- * Property Tester Implementation for Trace Control Components.
- *
- * @author Bernd Hufmann
- */
-public class TraceControlPropertyTester extends PropertyTester {
-
-    // ------------------------------------------------------------------------
-    // Constants
-    // ------------------------------------------------------------------------
-    private static final String ADD_CONTEXT_SUPPORT_PROPERTY = "isAddContextOnEventSupported"; //$NON-NLS-1$
-
-
-    @Override
-    public boolean test(Object receiver, String property, Object[] args, Object expectedValue) {
-
-        // Check if node supports adding contexts on event level.
-        if (ADD_CONTEXT_SUPPORT_PROPERTY.equals(property)) {
-            if ((receiver != null) && (receiver instanceof TraceEventComponent)) {
-                TraceEventComponent event = (TraceEventComponent) receiver;
-                TargetNodeComponent node = event.getTargetNode();
-                return node.isContextOnEventSupported();
-            }
-        }
-        return false;
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceControlRoot.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceControlRoot.java
deleted file mode 100644 (file)
index efdda45..0000000
+++ /dev/null
@@ -1,42 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl;
-
-
-/**
- * <p>
- * Root element in trace control tree.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class TraceControlRoot extends TraceControlComponent {
-
-    // ------------------------------------------------------------------------
-    // Constants
-    // ------------------------------------------------------------------------
-    /**
-     * The name of the root component
-     */
-    public static final String TRACE_CONTROL_ROOT_NAME = "trace_control_root"; //$NON-NLS-1$
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-    /**
-     * Default constructor
-     */
-    public TraceControlRoot() {
-        super(TRACE_CONTROL_ROOT_NAME);
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceDomainComponent.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceDomainComponent.java
deleted file mode 100644 (file)
index 70cb154..0000000
+++ /dev/null
@@ -1,299 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl;
-
-import java.util.List;
-
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IChannelInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IDomainInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.LogLevelType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.BufferType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.DomainInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.property.TraceDomainPropertySource;
-import org.eclipse.ui.views.properties.IPropertySource;
-
-/**
- * <p>
- * Implementation of the trace domain component.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class TraceDomainComponent extends TraceControlComponent {
-    // ------------------------------------------------------------------------
-    // Constants
-    // ------------------------------------------------------------------------
-    /**
-     * Path to icon file for this component.
-     */
-    public static final String TRACE_DOMAIN_ICON_FILE = "icons/obj16/domain.gif"; //$NON-NLS-1$
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-    /**
-     * The domain information.
-     */
-    private IDomainInfo fDomainInfo = null;
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-    /**
-     * Constructor
-     * @param name - the name of the component.
-     * @param parent - the parent of this component.
-     */
-    public TraceDomainComponent(String name, ITraceControlComponent parent) {
-        super(name, parent);
-        setImage(TRACE_DOMAIN_ICON_FILE);
-        setToolTip(Messages.TraceControl_DomainDisplayName);
-        fDomainInfo = new DomainInfo(name);
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-    /**
-     * Sets the domain information.
-     * @param domainInfo - the domain information to set.
-     */
-    public void setDomainInfo(IDomainInfo domainInfo) {
-        fDomainInfo = domainInfo;
-        IChannelInfo[] channels = fDomainInfo.getChannels();
-        for (int i = 0; i < channels.length; i++) {
-            TraceChannelComponent channel = new TraceChannelComponent(channels[i].getName(), this);
-            channel.setChannelInfo(channels[i]);
-            addChild(channel);
-        }
-    }
-
-    @Override
-    public Object getAdapter(Class adapter) {
-        if (adapter == IPropertySource.class) {
-            return new TraceDomainPropertySource(this);
-        }
-        return null;
-    }
-
-    /**
-     * @return session name from parent
-     */
-    public String getSessionName() {
-        return ((TraceSessionComponent)getParent()).getName();
-    }
-
-    /**
-     * @return session from parent
-     */
-    public TraceSessionComponent getSession() {
-       return (TraceSessionComponent)getParent();
-    }
-
-    /**
-     * @return true if domain is kernel, false for UST
-     */
-    public boolean isKernel() {
-        return fDomainInfo.isKernel();
-    }
-
-    /**
-     * Sets whether domain is  Kernel domain or UST
-     * @param isKernel true for kernel, false for UST
-     */
-    public void setIsKernel(boolean isKernel) {
-        fDomainInfo.setIsKernel(isKernel);
-    }
-
-    /**
-     * @return returns all available channels for this domain.
-     */
-    public TraceChannelComponent[] getChannels() {
-        List<ITraceControlComponent> channels = getChildren(TraceChannelComponent.class);
-        return channels.toArray(new TraceChannelComponent[channels.size()]);
-    }
-
-    /**
-     * @return the parent target node
-     */
-    public TargetNodeComponent getTargetNode() {
-        return ((TraceSessionComponent)getParent()).getTargetNode();
-    }
-
-    /**
-     * @return the buffer type
-     */
-    public BufferType getBufferType(){
-        return fDomainInfo.getBufferType();
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    /**
-     * Retrieves the session configuration from the node.
-     *
-     * @param monitor
-     *            - a progress monitor
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    public void getConfigurationFromNode(IProgressMonitor monitor) throws ExecutionException {
-        TraceSessionComponent session = (TraceSessionComponent) getParent();
-        session.getConfigurationFromNode(monitor);
-    }
-
-    /**
-     * Enables channels with given names which are part of this domain. If a
-     * given channel doesn't exists it creates a new channel with the given
-     * parameters (or default values if given parameter is null).
-     *
-     * @param channelNames
-     *            - a list of channel names to enable on this domain
-     * @param info
-     *            - channel information to set for the channel (use null for
-     *            default)
-     * @param monitor
-     *            - a progress monitor
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    public void enableChannels(List<String> channelNames, IChannelInfo info,
-            IProgressMonitor monitor) throws ExecutionException {
-        getControlService().enableChannels(getParent().getName(), channelNames,
-                isKernel(), info, monitor);
-    }
-
-    /**
-     * Disables channels with given names which are part of this domain.
-     *
-     * @param channelNames
-     *            - a list of channel names to enable on this domain
-     * @param monitor
-     *            - a progress monitor
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    public void disableChannels(List<String> channelNames,
-            IProgressMonitor monitor) throws ExecutionException {
-        getControlService().disableChannels(getParent().getName(),
-                channelNames, isKernel(), monitor);
-    }
-
-    /**
-     * Enables a list of events with no additional parameters.
-     *
-     * @param eventNames
-     *            - a list of event names to enabled.
-     * @param monitor
-     *            - a progress monitor
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    public void enableEvents(List<String> eventNames, IProgressMonitor monitor)
-            throws ExecutionException {
-        getControlService().enableEvents(getSessionName(), null, eventNames,
-                isKernel(), null, monitor);
-    }
-
-    /**
-     * Enables all syscalls (for kernel domain)
-     *
-     * @param monitor
-     *            - a progress monitor
-     * @throws ExecutionException
-     *             If the command fails
-     */
-
-    public void enableSyscalls(IProgressMonitor monitor)
-            throws ExecutionException {
-        getControlService().enableSyscalls(getSessionName(), null, monitor);
-    }
-
-    /**
-     * Enables a dynamic probe (for kernel domain)
-     *
-     * @param eventName
-     *            - event name for probe
-     * @param isFunction
-     *            - true for dynamic function entry/return probe else false
-     * @param probe
-     *            - the actual probe
-     * @param monitor
-     *            - a progress monitor
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    public void enableProbe(String eventName, boolean isFunction, String probe,
-            IProgressMonitor monitor) throws ExecutionException {
-        getControlService().enableProbe(getSessionName(), null, eventName,
-                isFunction, probe, monitor);
-    }
-
-    /**
-     * Enables events using log level.
-     *
-     * @param eventName
-     *            - a event name
-     * @param logLevelType
-     *            - a log level type
-     * @param level
-     *            - a log level
-     * @param filterExpression
-     *            - a filter expression
-     * @param monitor
-     *            - a progress monitor
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    public void enableLogLevel(String eventName, LogLevelType logLevelType,
-            TraceLogLevel level, String filterExpression, IProgressMonitor monitor)
-            throws ExecutionException {
-        getControlService().enableLogLevel(getSessionName(), null, eventName,
-                logLevelType, level, filterExpression, monitor);
-    }
-
-    /**
-     * Add contexts to given channels and or events
-     *
-     * @param contexts
-     *            - a list of contexts to add
-     * @param monitor
-     *            - a progress monitor
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    public void addContexts(List<String> contexts, IProgressMonitor monitor)
-            throws ExecutionException {
-        getControlService().addContexts(getSessionName(), null, null,
-                isKernel(), contexts, monitor);
-    }
-
-    /**
-     * Executes calibrate command to quantify LTTng overhead.
-     *
-     * @param monitor
-     *            - a progress monitor
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    public void calibrate(IProgressMonitor monitor) throws ExecutionException {
-        getControlService().calibrate(isKernel(), monitor);
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceEventComponent.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceEventComponent.java
deleted file mode 100644 (file)
index c38c3d9..0000000
+++ /dev/null
@@ -1,264 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl;
-
-import java.util.List;
-
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IEventInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.LogLevelType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEnablement;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEventType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.EventInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.property.TraceEventPropertySource;
-import org.eclipse.ui.views.properties.IPropertySource;
-
-
-/**
- * <p>
- * Implementation of the trace channel component.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class TraceEventComponent extends TraceControlComponent {
-    // ------------------------------------------------------------------------
-    // Constants
-    // ------------------------------------------------------------------------
-    /**
-     * Path to icon file for this component (enabled state).
-     */
-    public static final String TRACE_EVENT_ICON_FILE_ENABLED = "icons/obj16/event_enabled.gif"; //$NON-NLS-1$
-    /**
-     * Path to icon file for this component (disabled state).
-     */
-    public static final String TRACE_EVENT_ICON_FILE_DISABLED = "icons/obj16/event_disabled.gif"; //$NON-NLS-1$
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-    /**
-     * The event information.
-     */
-    protected IEventInfo fEventInfo = null;
-    /**
-     * The image to be displayed when in disabled state.
-     */
-    private Image fDisabledImage = null;
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-    /**
-     * Constructor
-     * @param name - the name of the component.
-     * @param parent - the parent of this component.
-     */
-    public TraceEventComponent(String name, ITraceControlComponent parent) {
-        super(name, parent);
-        setImage(TRACE_EVENT_ICON_FILE_ENABLED);
-        setToolTip(Messages.TraceControl_EventDisplayName);
-        fEventInfo = new EventInfo(name);
-        fDisabledImage = Activator.getDefault().loadIcon(TRACE_EVENT_ICON_FILE_DISABLED);
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    @Override
-    public Image getImage() {
-        if (fEventInfo.getState() == TraceEnablement.DISABLED) {
-            return fDisabledImage;
-        }
-        return super.getImage();
-    }
-
-    /**
-     * Sets the event information.
-     * @param eventInfo - the event information to set.
-     */
-    public void setEventInfo(IEventInfo eventInfo) {
-        fEventInfo = eventInfo;
-    }
-
-    /**
-     * @return the trace event type
-     */
-    public TraceEventType getEventType() {
-        return fEventInfo.getEventType();
-    }
-
-    /**
-     * Sets the trace event type to the given type
-     * @param type - type to set
-     */
-    public void setEventType(TraceEventType type) {
-        fEventInfo.setEventType(type);
-    }
-
-    /**
-     * Sets the trace event type to the type specified by the given name.
-     * @param typeName - event type name
-     */
-    public void setEventType(String typeName) {
-        fEventInfo.setEventType(typeName);
-    }
-
-    /**
-     * @return the event state (enabled or disabled).
-     */
-    public TraceEnablement getState() {
-        return fEventInfo.getState();
-    }
-
-    /**
-     * Sets the event state (enablement) to the given value.
-     * @param state - state to set.
-     */
-    public void setState(TraceEnablement state) {
-        fEventInfo.setState(state);
-    }
-
-    /**
-     * Sets the event state (enablement) to the value specified by the given name.
-     * @param stateName - state to set.
-     */
-    public void setState(String stateName) {
-        fEventInfo.setState(stateName);
-    }
-
-    /**
-     * @return the trace event log level
-     */
-    public TraceLogLevel getLogLevel() {
-        return fEventInfo.getLogLevel();
-    }
-
-    /**
-     * Sets the trace event log level to the given level
-     * @param level - event log level to set
-     */
-    public void setLogLevel(TraceLogLevel level) {
-        fEventInfo.setLogLevel(level);
-    }
-
-    /**
-     * Sets the trace event log level to the level specified by the given name.
-     * @param levelName - event log level name
-     */
-    public void setLogLevel(String levelName) {
-        fEventInfo.setLogLevel(levelName);
-    }
-
-    /**
-     * Returns filter expression.
-     * @return filter expression
-     */
-    public String getFilterExpression() {
-        return fEventInfo.getFilterExpression();
-    }
-
-    /**
-     * Sets the filter expression.
-     * @param filter The filter expression to set
-     */
-    public void setFilterExpression(String filter) {
-        fEventInfo.setFilterExpression(filter);
-    }
-
-    /**
-     * Returns the log level type
-     * @return event log level type
-     */
-    public LogLevelType getLogLevelType() {
-        return fEventInfo.getLogLevelType();
-    }
-
-    /**
-     * Sets the trace event log level type to the given level type
-     * @param levelType - event log level type to set
-     */
-    public void setLogLevelType(LogLevelType levelType) {
-        fEventInfo.setLogLevelType(levelType);
-    }
-
-    @Override
-    public Object getAdapter(Class adapter) {
-        if (adapter == IPropertySource.class) {
-            return new TraceEventPropertySource(this);
-        }
-        return null;
-    }
-
-    /**
-     * @return target node component.
-     */
-    public TargetNodeComponent getTargetNode() {
-        return ((TraceChannelComponent)getParent()).getTargetNode();
-    }
-
-    /**
-     * @return session name from parent
-     */
-    public String getSessionName() {
-       return ((TraceChannelComponent)getParent()).getSessionName();
-    }
-
-    /**
-     * @return session from parent
-     */
-    public TraceSessionComponent getSession() {
-       return ((TraceChannelComponent)getParent()).getSession();
-    }
-
-    /**
-     * @return channel name from parent
-     */
-    public String getChannelName() {
-        return getParent().getName();
-    }
-
-    /**
-     * @return if domain is kernel or UST
-     */
-    public boolean isKernel() {
-        return ((TraceChannelComponent)getParent()).isKernel();
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    /**
-     * Add contexts to given channels and or events
-     *
-     * @param contexts
-     *            - a list of contexts to add
-     * @param monitor
-     *            - a progress monitor
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    public void addContexts(List<String> contexts, IProgressMonitor monitor)
-            throws ExecutionException {
-        getControlService().addContexts(getSessionName(), getChannelName(),
-                getName(), isKernel(), contexts, monitor);
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceProbeEventComponent.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceProbeEventComponent.java
deleted file mode 100644 (file)
index 1ad0685..0000000
+++ /dev/null
@@ -1,121 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl;
-
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IEventInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.ProbeEventInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.property.TraceProbeEventPropertySource;
-import org.eclipse.ui.views.properties.IPropertySource;
-
-
-/**
- * <p>
- * Implementation of the trace channel component.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class TraceProbeEventComponent extends TraceEventComponent {
-    // ------------------------------------------------------------------------
-    // Constants
-    // ------------------------------------------------------------------------
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-    /**
-     * Constructor
-     * @param name - the name of the component.
-     * @param parent - the parent of this component.
-     */
-    public TraceProbeEventComponent(String name, ITraceControlComponent parent) {
-        super(name, parent);
-        fEventInfo = new ProbeEventInfo(name);
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    /**
-     * Sets the event information.
-     * @param eventInfo - the event information to set.
-     */
-    @Override
-    public void setEventInfo(IEventInfo eventInfo) {
-        if (eventInfo instanceof ProbeEventInfo) {
-            fEventInfo = eventInfo;
-            return;
-        }
-        throw new IllegalArgumentException("Invalid type passed. Only class of type ProbeEventInfo allowed:\n" + eventInfo.getClass()); //$NON-NLS-1$
-    }
-
-    @Override
-    public Object getAdapter(Class adapter) {
-        if (adapter == IPropertySource.class) {
-            return new TraceProbeEventPropertySource(this);
-        }
-        return null;
-    }
-    /**
-     * @return the address of the probe. (null if Symbol is used)
-     */
-    public String getAddress() {
-        return getEventInfo().getAddress();
-    }
-    /**
-     * Sets the address of the probe.
-     * @param address - a address
-     */
-    public void setAddress(String address) {
-        getEventInfo().setAddress(address);
-    }
-    /**
-     * @return the offset applied to the symbol.
-     */
-    public String getOffset() {
-        return getEventInfo().getOffset();
-    }
-    /**
-     * Sets the offset applied to the symbol. (valid if symbol is used)
-     * @param offset - a offset
-     */
-    public void setOffset(String offset) {
-        getEventInfo().setOffset(offset);
-    }
-    /**
-     * @return the symbol name. (null if address is used)
-     */
-    public String getSymbol() {
-        return getEventInfo().getSymbol();
-    }
-    /**
-     * Sets the symbol name.
-     * @param symbol - a symbol name (null if address is used)
-     */
-    public void setSymbol(String symbol) {
-        getEventInfo().setSymbol(symbol);
-    }
-
-    // ------------------------------------------------------------------------
-    // Helper methods
-    // ------------------------------------------------------------------------
-    private ProbeEventInfo getEventInfo() {
-        return (ProbeEventInfo) fEventInfo;
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceProviderGroup.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceProviderGroup.java
deleted file mode 100644 (file)
index 83659bd..0000000
+++ /dev/null
@@ -1,108 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl;
-
-import java.util.Iterator;
-import java.util.List;
-
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IBaseEventInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IUstProviderInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
-
-/**
- * <p>
- * Implementation of the trace provider group.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class TraceProviderGroup extends TraceControlComponent {
-    // ------------------------------------------------------------------------
-    // Constants
-    // ------------------------------------------------------------------------
-    /**
-     * Path to icon file for this component.
-     */
-    public static final String TRACE_PROVIDERS_ICON_FILE = "icons/obj16/providers.gif"; //$NON-NLS-1$
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-    /**
-     * Constructor
-     * @param name - the name of the component.
-     * @param parent - the parent of this component.
-     */
-    public TraceProviderGroup(String name, ITraceControlComponent parent) {
-        super(name, parent);
-        setImage(TRACE_PROVIDERS_ICON_FILE);
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    /**
-     * Gets the provider information from the target node.
-     * @param monitor - a progress monitor
-     * @throws ExecutionException If the command fails
-     */
-    public void getProviderFromNode(IProgressMonitor monitor) throws ExecutionException {
-
-        List<IBaseEventInfo> eventInfos = getControlService().getKernelProvider(monitor);
-
-        if (!eventInfos.isEmpty()) {
-            KernelProviderComponent component = new KernelProviderComponent(Messages.TraceControl_KernelProviderDisplayName, this);
-            addChild(component);
-            component.setEventInfo(eventInfos);
-        }
-
-        List<IUstProviderInfo> allProviders = getControlService().getUstProvider(monitor);
-
-        for (Iterator<IUstProviderInfo> iterator = allProviders.iterator(); iterator.hasNext();) {
-            IUstProviderInfo ustProviderInfo = iterator.next();
-            UstProviderComponent ustComponent = new UstProviderComponent(ustProviderInfo.getName(), this);
-            addChild(ustComponent);
-            ustComponent.setUstProvider(ustProviderInfo);
-        }
-    }
-
-    /**
-     * Returns whether the kernel provider is available or not
-     * @return <code>true</code> if kernel provide is available or <code>false</code>
-     */
-    public boolean hasKernelProvider() {
-        List<ITraceControlComponent> kernelList = getChildren(KernelProviderComponent.class);
-        return !kernelList.isEmpty();
-    }
-
-    /**
-     * Returns if node supports filtering of events
-     * @return <code>true</code> if node supports filtering else <code>false</code>
-     */
-    public boolean isEventFilteringSupported() {
-        return ((TargetNodeComponent)getParent()).isEventFilteringSupported();
-    }
-}
-
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceSessionComponent.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceSessionComponent.java
deleted file mode 100644 (file)
index 5a6fa47..0000000
+++ /dev/null
@@ -1,478 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
- *   Marc-Andre Laperle - Support for opening a live session
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl;
-
-import java.util.List;
-
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IChannelInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IDomainInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISessionInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISnapshotInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.LogLevelType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceSessionState;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.SessionInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.Activator;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.property.TraceSessionPropertySource;
-import org.eclipse.ui.views.properties.IPropertySource;
-
-/**
- * <p>
- * Implementation of the trace session component.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class TraceSessionComponent extends TraceControlComponent {
-
-    // ------------------------------------------------------------------------
-    // Constants
-    // ------------------------------------------------------------------------
-    /**
-     * Path to icon file for this component (inactive state).
-     */
-    public static final String TRACE_SESSION_ICON_FILE_INACTIVE = "icons/obj16/session_inactive.gif"; //$NON-NLS-1$
-    /**
-     * Path to icon file for this component (active state).
-     */
-    public static final String TRACE_SESSION_ICON_FILE_ACTIVE = "icons/obj16/session_active.gif"; //$NON-NLS-1$
-    /**
-     * Path to icon file for this component (destroyed state).
-     */
-    public static final String TRACE_SESSION_ICON_FILE_DESTROYED = "icons/obj16/session_destroyed.gif"; //$NON-NLS-1$
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-    /**
-     * The session information.
-     */
-    private ISessionInfo fSessionInfo = null;
-    /**
-     * A flag to indicate if session has been destroyed.
-     */
-    private boolean fIsDestroyed = false;
-    /**
-     * The image to be displayed in state active.
-     */
-    private Image fActiveImage = null;
-    /**
-     * The image to be displayed in state destroyed
-     */
-    private Image fDestroyedImage = null;
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-    /**
-     * Constructor
-     * @param name - the name of the component.
-     * @param parent - the parent of this component.
-     */
-    public TraceSessionComponent(String name, ITraceControlComponent parent) {
-        super(name, parent);
-        setImage(TRACE_SESSION_ICON_FILE_INACTIVE);
-        setToolTip(Messages.TraceControl_SessionDisplayName);
-        fSessionInfo = new SessionInfo(name);
-        fActiveImage = Activator.getDefault().loadIcon(TRACE_SESSION_ICON_FILE_ACTIVE);
-        fDestroyedImage = Activator.getDefault().loadIcon(TRACE_SESSION_ICON_FILE_DESTROYED);
-    }
-
-    /**
-     * Constructor
-     *
-     * @param sessionInfo
-     *            the session information used to create the session
-     * @param parent
-     *            the parent of this component.
-     */
-    public TraceSessionComponent(ISessionInfo sessionInfo, ITraceControlComponent parent) {
-        this(sessionInfo.getName(), parent);
-        copyLiveInfo(sessionInfo);
-    }
-
-    private void copyLiveInfo(ISessionInfo sessionInfo) {
-        // Since we can't retrieve this information from the node, we copy it over
-        if (sessionInfo.getLivePort() != null) {
-            fSessionInfo.setLivePort(sessionInfo.getLivePort());
-        }
-        if (sessionInfo.getLiveUrl() != null) {
-            fSessionInfo.setLiveUrl(sessionInfo.getLiveUrl());
-        }
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    @Override
-    public Image getImage() {
-        if (fIsDestroyed) {
-            return fDestroyedImage;
-        }
-
-        if (fSessionInfo.getSessionState() == TraceSessionState.INACTIVE) {
-            return super.getImage();
-        }
-
-        return fActiveImage;
-    }
-
-    /**
-     * @return the whether the session is destroyed or not.
-     */
-    public boolean isDestroyed() {
-        return fIsDestroyed;
-    }
-
-    /**
-     * Sets the session destroyed state to the given value.
-     * @param destroyed - value to set.
-     */
-    public void setDestroyed(boolean destroyed) {
-        fIsDestroyed = destroyed;
-    }
-
-    /**
-     * @return the session state state (active or inactive).
-     */
-    public TraceSessionState getSessionState() {
-        return fSessionInfo.getSessionState();
-    }
-
-    /**
-     * Sets the session state  to the given value.
-     * @param state - state to set.
-     */
-    public void setSessionState(TraceSessionState state) {
-        fSessionInfo.setSessionState(state);
-    }
-
-    /**
-     * Sets the event state to the value specified by the given name.
-     * @param stateName - state to set.
-     */
-    public void setSessionState(String stateName) {
-        fSessionInfo.setSessionState(stateName);
-    }
-
-    /**
-     * @return path string where session is located.
-     */
-    public String getSessionPath() {
-        return fSessionInfo.getSessionPath();
-    }
-
-    /**
-     * Sets the path string (where session is located) to the given value.
-     * @param sessionPath - session path to set.
-     */
-    public void setSessionPath(String sessionPath) {
-        fSessionInfo.setSessionPath(sessionPath);
-    }
-
-    /**
-     * Returns if session is streamed over network
-     * @return <code>true</code> if streamed over network else <code>false</code>
-     */
-    public boolean isStreamedTrace() {
-        return fSessionInfo.isStreamedTrace();
-    }
-
-    /**
-     * Sets whether the trace is streamed or not
-     * @param isStreamedTrace <code>true</code> if streamed over network else <code>false</code>
-     */
-    public void setIsStreamedTrace(boolean isStreamedTrace) {
-        fSessionInfo.setStreamedTrace(isStreamedTrace);
-    }
-
-    /**
-     * Returns whether the session is snapshot session or not
-     * @return <code>true</code> if it is snapshot session else <code>false</code>
-     */
-    public boolean isSnapshotSession() {
-        return fSessionInfo.isSnapshotSession();
-    }
-
-    /**
-     * Gets the snapshot information if available whether the session is a snapshot session or not
-     * @return the snapshot information or null if it is not a snapshot session
-     */
-    public ISnapshotInfo getSnapshotInfo() {
-        return fSessionInfo.getSnapshotInfo();
-    }
-
-    @Override
-    public Object getAdapter(Class adapter) {
-        if (adapter == IPropertySource.class) {
-            return new TraceSessionPropertySource(this);
-        }
-        return null;
-    }
-
-    /**
-     * @return all available domains of this session.
-     */
-    public TraceDomainComponent[] getDomains() {
-        List<ITraceControlComponent> sessions = getChildren(TraceDomainComponent.class);
-        return sessions.toArray(new TraceDomainComponent[sessions.size()]);
-    }
-
-    /**
-     * @return the parent target node
-     */
-    public TargetNodeComponent getTargetNode() {
-        return ((TraceSessionGroup)getParent()).getTargetNode();
-    }
-
-    /**
-     * Returns whether the kernel provider is available or not
-     * @return <code>true</code> if kernel provide is available or <code>false</code>
-     */
-    public boolean hasKernelProvider() {
-        List<ITraceControlComponent> providerGroups = getTargetNode().getChildren(TraceProviderGroup.class);
-        return (!providerGroups.isEmpty() ? ((TraceProviderGroup) providerGroups.get(0)).hasKernelProvider() : false);
-    }
-
-    /**
-     * Returns if node supports filtering of events
-     * @return <code>true</code> if node supports filtering else <code>false</code>
-     */
-    public boolean isEventFilteringSupported() {
-        return ((TargetNodeComponent)getParent().getParent()).isEventFilteringSupported();
-    }
-
-    /**
-     * Returns if node supports snapshots or not
-     * @return <code>true</code> if it supports snapshots else <code>false</code>
-     *
-     */
-    public boolean isSnapshotSupported() {
-        return ((TargetNodeComponent)getParent().getParent()).isSnapshotSupported();
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    /**
-     * Retrieves the session configuration from the node.
-     *
-     * @param monitor
-     *            - a progress monitor
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    public void getConfigurationFromNode(IProgressMonitor monitor)
-            throws ExecutionException {
-        removeAllChildren();
-        ISessionInfo newInfo = getControlService().getSession(getName(), monitor);
-        if (newInfo != null) {
-            ISessionInfo oldSessionInfo = fSessionInfo;
-            fSessionInfo = newInfo;
-            copyLiveInfo(oldSessionInfo);
-
-            IDomainInfo[] domains = fSessionInfo.getDomains();
-            for (int i = 0; i < domains.length; i++) {
-                TraceDomainComponent domainComponent = new TraceDomainComponent(
-                        domains[i].getName(), this);
-                addChild(domainComponent);
-                domainComponent.setDomainInfo(domains[i]);
-            }
-        }
-    }
-
-    /**
-     * Starts the session.
-     *
-     * @param monitor
-     *            - a progress monitor
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    public void startSession(IProgressMonitor monitor)
-            throws ExecutionException {
-        getControlService().startSession(getName(), monitor);
-    }
-
-    /**
-     * Starts the session.
-     *
-     * @param monitor
-     *            - a progress monitor
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    public void stopSession(IProgressMonitor monitor) throws ExecutionException {
-        getControlService().stopSession(getName(), monitor);
-    }
-
-    /**
-     * Enables channels with given names which are part of this domain. If a
-     * given channel doesn't exists it creates a new channel with the given
-     * parameters (or default values if given parameter is null).
-     *
-     * @param channelNames
-     *            - a list of channel names to enable on this domain
-     * @param info
-     *            - channel information to set for the channel (use null for
-     *            default)
-     * @param isKernel
-     *            - a flag for indicating kernel or UST.
-     * @param monitor
-     *            - a progress monitor
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    public void enableChannels(List<String> channelNames, IChannelInfo info,
-            boolean isKernel, IProgressMonitor monitor)
-            throws ExecutionException {
-        getControlService().enableChannels(getName(), channelNames, isKernel,
-                info, monitor);
-    }
-
-    /**
-     * Enables a list of events with no additional parameters.
-     *
-     * @param eventNames
-     *            - a list of event names to enabled.
-     * @param isKernel
-     *            - a flag for indicating kernel or UST.
-     * @param filterExpression
-     *            - a filter expression
-     * @param monitor
-     *            - a progress monitor
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    public void enableEvents(List<String> eventNames, boolean isKernel,
-            String filterExpression, IProgressMonitor monitor) throws ExecutionException {
-        getControlService().enableEvents(getName(), null, eventNames, isKernel,
-                filterExpression, monitor);
-    }
-
-    /**
-     * Enables all syscalls (for kernel domain)
-     *
-     * @param monitor
-     *            - a progress monitor
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    public void enableSyscalls(IProgressMonitor monitor)
-            throws ExecutionException {
-        getControlService().enableSyscalls(getName(), null, monitor);
-    }
-
-    /**
-     * Enables a dynamic probe (for kernel domain)
-     *
-     * @param eventName
-     *            - event name for probe
-     * @param isFunction
-     *            - true for dynamic function entry/return probe else false
-     * @param probe
-     *            - the actual probe
-     * @param monitor
-     *            - a progress monitor
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    public void enableProbe(String eventName, boolean isFunction, String probe,
-            IProgressMonitor monitor) throws ExecutionException {
-        getControlService().enableProbe(getName(), null, eventName, isFunction,
-                probe, monitor);
-    }
-
-    /**
-     * Enables events using log level.
-     *
-     * @param eventName
-     *            - a event name
-     * @param logLevelType
-     *            - a log level type
-     * @param level
-     *            - a log level
-     * @param filterExpression
-     *            - a filter expression
-     * @param monitor
-     *            - a progress monitor
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    public void enableLogLevel(String eventName, LogLevelType logLevelType,
-            TraceLogLevel level, String filterExpression, IProgressMonitor monitor)
-            throws ExecutionException {
-        getControlService().enableLogLevel(getName(), null, eventName,
-                logLevelType, level, null, monitor);
-    }
-
-    /**
-     * Gets all available contexts to be added to channels/events.
-     *
-     * @param monitor
-     *            The monitor that will indicate the progress
-     * @return the list of available contexts
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    public List<String> getContextList(IProgressMonitor monitor)
-            throws ExecutionException {
-        return getControlService().getContextList(monitor);
-    }
-
-    /**
-     * Records a snapshot.
-     *
-     * @param monitor
-     *            - a progress monitor
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    public void recordSnapshot(IProgressMonitor monitor) throws ExecutionException {
-        getControlService().recordSnapshot(getName(), monitor);
-    }
-
-    /**
-     * Returns if session is live.
-     * @return <code>true</code> if session if live else <code>false</code>
-     */
-    public boolean isLiveTrace() {
-        return fSessionInfo.isLive();
-    }
-
-    /**
-     * Get the live URL.
-     *
-     * @return the live URL
-     */
-    public String getLiveUrl() {
-        return fSessionInfo.getLiveUrl();
-    }
-
-    /**
-     * Get the live port.
-     *
-     * @return the live port
-     */
-    public Integer getLivePort() {
-        return fSessionInfo.getLivePort();
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceSessionGroup.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/TraceSessionGroup.java
deleted file mode 100644 (file)
index ca91f58..0000000
+++ /dev/null
@@ -1,174 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl;
-
-import java.util.List;
-
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.NullProgressMonitor;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISessionInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
-
-/**
- * <p>
- * Implementation of the trace session group.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class TraceSessionGroup extends TraceControlComponent {
-    // ------------------------------------------------------------------------
-    // Constants
-    // ------------------------------------------------------------------------
-    /**
-     * Path to icon file for this component.
-     */
-    public static final String TRACE_SESSIONS_ICON_FILE = "icons/obj16/sessions.gif"; //$NON-NLS-1$
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-    /**
-     * Constructor
-     * @param name - the name of the component.
-     * @param parent - the parent of this component.
-     */
-    public TraceSessionGroup(String name, ITraceControlComponent parent) {
-        super(name, parent);
-        setImage(TRACE_SESSIONS_ICON_FILE);
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    /**
-     * @return the parent target node
-     */
-    public TargetNodeComponent getTargetNode() {
-        return (TargetNodeComponent)getParent();
-    }
-
-    /**
-     * Returns if node supports networks streaming or not
-     * @return <code>true</code> if node supports filtering else <code>false</code>
-     */
-    public boolean isNetworkStreamingSupported() {
-        return getTargetNode().isNetworkStreamingSupported();
-    }
-    /**
-     * Returns if node supports snapshots or not
-     * @return <code>true</code> if it supports snapshots else <code>false</code>
-     *
-     */    public boolean isSnapshotSupported() {
-        return getTargetNode().isSnapshotSupported();
-    }
-
-    /**
-     * Returns if node supports live or not
-     *
-     * @return <code>true</code> if it supports live else <code>false</code>
-     */
-    public boolean isLiveSupported() {
-        return getTargetNode().isLiveSupported();
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-    /**
-     * Retrieves the sessions information from the node.
-     *
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    public void getSessionsFromNode() throws ExecutionException {
-        getSessionsFromNode(new NullProgressMonitor());
-    }
-
-    /**
-     * Retrieves the sessions information from the node.
-     *
-     * @param monitor
-     *            - a progress monitor
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    public void getSessionsFromNode(IProgressMonitor monitor)
-            throws ExecutionException {
-        List<String> sessionNames = getControlService().getSessionNames(monitor);
-        for (String sessionName : sessionNames) {
-            TraceSessionComponent session =
-                    new TraceSessionComponent(sessionName, this);
-            addChild(session);
-            session.getConfigurationFromNode(monitor);
-        }
-    }
-
-    /**
-     * Creates a session with given session name and location.
-     *
-     * @param sessionInf
-     *            the session information used to create the session
-     *
-     * @param monitor
-     *            - a progress monitor
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    public void createSession(ISessionInfo sessionInf, IProgressMonitor monitor) throws ExecutionException {
-        ISessionInfo sessionInfo = getControlService().createSession(sessionInf, monitor);
-
-        if (sessionInfo != null) {
-            TraceSessionComponent session = new TraceSessionComponent(sessionInfo, TraceSessionGroup.this);
-            addChild(session);
-            session.getConfigurationFromNode(monitor);
-        }
-    }
-
-    /**
-     * Command to execute a list of commands
-     * @param monitor
-     *            - a progress monitor
-     * @param commands
-     *            - a list of commands to execute
-     * @throws ExecutionException
-     *            If the command fails
-     */
-    public void executeCommands(IProgressMonitor monitor, List<String> commands) throws ExecutionException {
-        getControlService().runCommands(monitor, commands);
-        getTargetNode().refresh();
-    }
-
-    /**
-     * Destroys a session with given session name.
-     *
-     * @param session
-     *            - a session component to destroy
-     * @param monitor
-     *            - a progress monitor
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    public void destroySession(TraceSessionComponent session,
-            IProgressMonitor monitor) throws ExecutionException {
-        getControlService().destroySession(session.getName(), monitor);
-        session.removeAllChildren();
-        removeChild(session);
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/UstProviderComponent.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/model/impl/UstProviderComponent.java
deleted file mode 100644 (file)
index 0d167ea..0000000
+++ /dev/null
@@ -1,104 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl;
-
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IBaseEventInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IUstProviderInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.UstProviderInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.ITraceControlComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.property.UstProviderPropertySource;
-import org.eclipse.ui.views.properties.IPropertySource;
-
-/**
- * <p>
- * Implementation of the UST provider component.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class UstProviderComponent extends TraceControlComponent {
-
-    // ------------------------------------------------------------------------
-    // Constants
-    // ------------------------------------------------------------------------
-    /**
-     * Path to icon file for this component.
-     */
-    public static final String USTL_PROVIDER_ICON_FILE = "icons/obj16/targets.gif"; //$NON-NLS-1$
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-    /**
-     * The UST provider information.
-     */
-    private IUstProviderInfo fProviderInfo = null;
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-    /**
-     * Constructor
-     * @param name - the name of the component.
-     * @param parent - the parent of this component.
-     */
-    public UstProviderComponent(String name, ITraceControlComponent parent) {
-        super(name, parent);
-        setImage(USTL_PROVIDER_ICON_FILE);
-        setToolTip(Messages.TraceControl_ProviderDisplayName);
-        fProviderInfo = new UstProviderInfo(name);
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-    /**
-     * Sets the UST provider information to the given value.
-     * @param providerInfo - the provider information to set
-     */
-    public void setUstProvider(IUstProviderInfo providerInfo) {
-        fProviderInfo = providerInfo;
-        IBaseEventInfo[] events = providerInfo.getEvents();
-        for (int i = 0; i < events.length; i++) {
-            BaseEventComponent component  = new BaseEventComponent(events[i].getName(), this);
-            component.setEventInfo(events[i]);
-            addChild(component);
-        }
-        setName(getName() + " [PID=" + fProviderInfo.getPid() + "]"); //$NON-NLS-1$ //$NON-NLS-2$
-    }
-
-    /**
-     * @return the process ID of the UST provider.
-     */
-    public int getPid() {
-        return fProviderInfo.getPid();
-    }
-
-    /**
-     * Sets the process ID of the UST provider to the given value.
-     * @param pid - process ID to set
-     */
-    public void setPid(int pid) {
-        fProviderInfo.setPid(pid);
-    }
-
-    @Override
-    public Object getAdapter(Class adapter) {
-        if (adapter == IPropertySource.class) {
-            return new UstProviderPropertySource(this);
-        }
-        return null;
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/preferences/ControlPreferenceInitializer.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/preferences/ControlPreferenceInitializer.java
deleted file mode 100644 (file)
index 9ad4333..0000000
+++ /dev/null
@@ -1,37 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.preferences;
-
-import org.eclipse.core.runtime.preferences.AbstractPreferenceInitializer;
-import org.eclipse.jface.preference.IPreferenceStore;
-
-/**
- * <p>
- * A class to initialize the preferences.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class ControlPreferenceInitializer extends AbstractPreferenceInitializer {
-
-    @Override
-    public void initializeDefaultPreferences() {
-        final IPreferenceStore store = ControlPreferences.getInstance().getPreferenceStore();
-
-        //Set default User ID if none already stored in preferences
-        store.setDefault(ControlPreferences.TRACE_CONTROL_TRACING_GROUP_PREF, ControlPreferences.TRACE_CONTROL_DEFAULT_TRACING_GROUP);
-        store.setDefault(ControlPreferences.TRACE_CONTROL_LOG_APPEND_PREF, false);
-        store.setDefault(ControlPreferences.TRACE_CONTROL_LOG_FILE_PATH_PREF, ControlPreferences.TRACE_CONTROL_DEFAULT_LOG_PATH);
-        store.setDefault(ControlPreferences.TRACE_CONTROL_LOG_COMMANDS_PREF, false);
-        store.setDefault(ControlPreferences.TRACE_CONTROL_VERBOSE_LEVEL_PREF, ControlPreferences.TRACE_CONTROL_VERBOSE_LEVEL_NONE);
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/preferences/ControlPreferencePage.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/preferences/ControlPreferencePage.java
deleted file mode 100644 (file)
index d587382..0000000
+++ /dev/null
@@ -1,147 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.preferences;
-
-import org.eclipse.jface.preference.BooleanFieldEditor;
-import org.eclipse.jface.preference.FieldEditor;
-import org.eclipse.jface.preference.FieldEditorPreferencePage;
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.jface.preference.RadioGroupFieldEditor;
-import org.eclipse.jface.preference.StringFieldEditor;
-import org.eclipse.jface.util.PropertyChangeEvent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.logging.ControlCommandLogger;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
-import org.eclipse.ui.IWorkbench;
-import org.eclipse.ui.IWorkbenchPreferencePage;
-
-/**
- * <p>
- * Preference page implementation for configuring LTTng tracer control preferences.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class ControlPreferencePage extends FieldEditorPreferencePage implements IWorkbenchPreferencePage {
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-    private RadioGroupFieldEditor fVerboseLevel;
-    private BooleanFieldEditor  fIsAppend;
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-
-    /**
-     * Constructor
-     */
-    public ControlPreferencePage() {
-        super(FieldEditorPreferencePage.GRID);
-
-        // Set the preference store for the preference page.
-        IPreferenceStore store = ControlPreferences.getInstance().getPreferenceStore();
-        setPreferenceStore(store);
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    public void init(IWorkbench workbench) {
-    }
-
-    @Override
-    protected void createFieldEditors() {
-
-        StringFieldEditor tracingGroup = new StringFieldEditor(ControlPreferences.TRACE_CONTROL_TRACING_GROUP_PREF, Messages.TraceControl_TracingGroupPreference, getFieldEditorParent());
-        addField(tracingGroup);
-
-        BooleanFieldEditor logCommand = new BooleanFieldEditor(ControlPreferences.TRACE_CONTROL_LOG_COMMANDS_PREF, Messages.TraceControl_LoggingPreference, getFieldEditorParent());
-        addField(logCommand);
-
-        StringFieldEditor logfile = new StringFieldEditor(ControlPreferences.TRACE_CONTROL_LOG_FILE_PATH_PREF, Messages.TraceControl_LogfilePath, getFieldEditorParent());
-        addField(logfile);
-
-        fIsAppend = new BooleanFieldEditor(ControlPreferences.TRACE_CONTROL_LOG_APPEND_PREF, Messages.TraceControl_AppendLogfilePreference, getFieldEditorParent());
-        addField(fIsAppend);
-
-        fVerboseLevel = new RadioGroupFieldEditor (
-                ControlPreferences.TRACE_CONTROL_VERBOSE_LEVEL_PREF,
-                Messages.TraceControl_VerboseLevelsPreference,
-                4,
-                new String[][] {
-                    {
-                        Messages.TraceControl_VerboseLevelNonePreference,
-                        ControlPreferences.TRACE_CONTROL_VERBOSE_LEVEL_NONE,
-                    },
-                    {
-                        Messages.TraceControl_VerboseLevelVerbosePreference,
-                        ControlPreferences.TRACE_CONTROL_VERBOSE_LEVEL_VERBOSE
-                    },
-                    {
-                        Messages.TraceControl_VerboseLevelVeryVerbosePreference,
-                        ControlPreferences.TRACE_CONTROL_VERBOSE_LEVEL_V_VERBOSE
-                    },
-                    {
-                        Messages.TraceControl_VerboseLevelVeryVeryVerbosePreference,
-                        ControlPreferences.TRACE_CONTROL_VERBOSE_LEVEL_V_V_VERBOSE
-                    }
-                },
-                getFieldEditorParent(),
-                true);
-
-        addField(fVerboseLevel);
-
-        Boolean enabled = ControlPreferences.getInstance().isLoggingEnabled();
-        fVerboseLevel.setEnabled(enabled, getFieldEditorParent());
-        fIsAppend.setEnabled(enabled, getFieldEditorParent());
-        logfile.setEnabled(false, getFieldEditorParent());
-
-    }
-
-    @Override
-    public void propertyChange(PropertyChangeEvent event) {
-
-        if (event.getProperty().equals(FieldEditor.VALUE)) {
-            if (event.getSource() instanceof FieldEditor) {
-                FieldEditor editor = (FieldEditor) event.getSource();
-                if (editor.getPreferenceName().equals(ControlPreferences.TRACE_CONTROL_LOG_COMMANDS_PREF)) {
-                    Boolean enabled = (Boolean)event.getNewValue();
-                    fVerboseLevel.setEnabled(enabled, getFieldEditorParent());
-                    fIsAppend.setEnabled(enabled, getFieldEditorParent());
-                }
-            }
-        }
-        super.propertyChange(event);
-    }
-
-    @Override
-    protected void performDefaults() {
-        super.performDefaults();
-        fVerboseLevel.setEnabled(false, getFieldEditorParent());
-        fIsAppend.setEnabled(false, getFieldEditorParent());
-    }
-
-    @Override
-    public boolean performOk() {
-        boolean ret =  super.performOk();
-        // open or close log file
-        if (ControlPreferences.getInstance().isLoggingEnabled()) {
-            ControlCommandLogger.init(ControlPreferences.getInstance().getLogfilePath(), ControlPreferences.getInstance().isAppend());
-        } else {
-            ControlCommandLogger.close();
-        }
-        return ret;
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/preferences/ControlPreferences.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/preferences/ControlPreferences.java
deleted file mode 100644 (file)
index 9d88d22..0000000
+++ /dev/null
@@ -1,203 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.preferences;
-
-import java.io.File;
-
-import org.eclipse.jface.preference.IPreferenceStore;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.logging.ControlCommandLogger;
-
-/**
- * <p>
- * Singleton class to access LTTng tracer control preferences.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class ControlPreferences {
-
-    // ------------------------------------------------------------------------
-    // Constants
-    // ------------------------------------------------------------------------
-    /**
-     * Trace control log file
-     */
-    public static final String TRACE_CONTROL_LOG_FILENAME = "lttng_tracer_control.log"; //$NON-NLS-1$
-
-    // Preference strings
-    /**
-     * The tracing group preference
-     */
-    public static final String TRACE_CONTROL_TRACING_GROUP_PREF = "trace.control.tracing.group"; //$NON-NLS-1$
-    /**
-     * The log commands preference
-     */
-    public static final String TRACE_CONTROL_LOG_COMMANDS_PREF = "trace.control.log.commands"; //$NON-NLS-1$
-    /**
-     * The log append preference
-     */
-    public static final String TRACE_CONTROL_LOG_APPEND_PREF = "trace.control.log.append"; //$NON-NLS-1$
-    /**
-     * The log file path preference
-     */
-    public static final String TRACE_CONTROL_LOG_FILE_PATH_PREF = "trace.control.log.path"; //$NON-NLS-1$
-    /**
-     * The verbose level preference
-     */
-    public static final String TRACE_CONTROL_VERBOSE_LEVEL_PREF = "trace.control.verbose.level"; //$NON-NLS-1$
-    /**
-     * The verbose level value for none
-     */
-    public static final String TRACE_CONTROL_VERBOSE_LEVEL_NONE = "trace.control.verbose.level.none"; //$NON-NLS-1$
-    /**
-     * The verbose level value for level 1 (-v)
-     */
-    public static final String TRACE_CONTROL_VERBOSE_LEVEL_VERBOSE = "trace.control.verbose.level.v"; //$NON-NLS-1$
-    /**
-     * The verbose level value for level 2 (-vv)
-     */
-    public static final String TRACE_CONTROL_VERBOSE_LEVEL_V_VERBOSE = "trace.control.verbose.level.vv"; //$NON-NLS-1$
-    /**
-     * The verbose level value for level 3 (-vvv)
-     */
-    public static final String TRACE_CONTROL_VERBOSE_LEVEL_V_V_VERBOSE = "trace.control.verbose.level.vvv"; //$NON-NLS-1$
-    /**
-     * The default tracing group
-     */
-    public static final String TRACE_CONTROL_DEFAULT_TRACING_GROUP = "tracing"; //$NON-NLS-1$
-    /**
-     * The default tracing log file name with absolute path
-     */
-    public static final String TRACE_CONTROL_DEFAULT_LOG_PATH = System.getProperty("user.home") + File.separator + TRACE_CONTROL_LOG_FILENAME; //$NON-NLS-1$
-    /**
-     * Default timeout value used for executing commands, in seconds
-     */
-    public static final int TRACE_CONTROL_DEFAULT_TIMEOUT_VALUE = 15;
-    /**
-     * Minimum timeout value used for executing commands, in seconds
-     */
-    public static final int TRACE_CONTROL_MIN_TIMEOUT_VALUE = 5;
-    /**
-     * Maximum timeout value used for executing commands, in seconds
-     */
-    public static final int TRACE_CONTROL_MAX_TIMEOUT_VALUE = 600;
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-    /**
-     * The trace control preferences singleton instance.
-     */
-    private static ControlPreferences fInstance = null;
-    /**
-     * The preference store reference
-     */
-    private IPreferenceStore fPreferenceStore = null;
-
-    // ------------------------------------------------------------------------
-    // Constructor
-    // ------------------------------------------------------------------------
-    /**
-     * Private constructor
-     */
-    private ControlPreferences() {
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-    /**
-     * Returns the trace control preferences singleton instance
-     *
-     * @return the trace control preferences singleton instance
-     */
-    public static synchronized ControlPreferences getInstance() {
-        if (fInstance == null) {
-            fInstance = new ControlPreferences();
-        }
-        return fInstance;
-    }
-
-    /**
-     * @return the preference store
-     */
-    public IPreferenceStore getPreferenceStore() {
-        return fPreferenceStore;
-    }
-
-    /**
-     * @return true if tracing group is set to default
-     */
-    public boolean isDefaultTracingGroup() {
-        return fPreferenceStore.getString(TRACE_CONTROL_TRACING_GROUP_PREF).equals(fPreferenceStore.getDefaultString(TRACE_CONTROL_TRACING_GROUP_PREF));
-    }
-
-    /**
-     * @return value of tracing group preference
-     */
-    public String getTracingGroup() {
-        return fPreferenceStore.getString(TRACE_CONTROL_TRACING_GROUP_PREF);
-    }
-
-    /**
-     * @return whether is logging is enabled
-     */
-    public boolean isLoggingEnabled() {
-        return fPreferenceStore.getBoolean(TRACE_CONTROL_LOG_COMMANDS_PREF);
-    }
-
-    /**
-     * @return whether an existing log file will appended or not
-     */
-    public boolean isAppend() {
-        return fPreferenceStore.getBoolean(ControlPreferences.TRACE_CONTROL_LOG_APPEND_PREF);
-    }
-
-    /**
-     * @return verbose level preference
-     */
-    public String getVerboseLevel() {
-        return fPreferenceStore.getString(TRACE_CONTROL_VERBOSE_LEVEL_PREF);
-    }
-
-    /**
-     * @return absolute log file path
-     */
-    public String getLogfilePath() {
-        return fPreferenceStore.getString(TRACE_CONTROL_LOG_FILE_PATH_PREF);
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    /**
-     * Initializes the control preferences (e.g. enable open log file)
-     *
-     * @param preferenceStore
-     *            The preference store to assign
-     */
-    public void init(IPreferenceStore preferenceStore) {
-        fPreferenceStore = preferenceStore;
-
-        if (fPreferenceStore.getBoolean(ControlPreferences.TRACE_CONTROL_LOG_COMMANDS_PREF)) {
-            ControlCommandLogger.init(getLogfilePath(), isAppend());
-        }
-    }
-
-    /**
-     * Disposes any resource (e.g. close log file).
-     */
-    public void dispose() {
-        ControlCommandLogger.close();
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/BaseEventPropertySource.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/BaseEventPropertySource.java
deleted file mode 100644 (file)
index 8e2ba7a..0000000
+++ /dev/null
@@ -1,124 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *     Bernd Hufmann - Initial API and implementation
- *     Bernd Hufmann - Updated for support of LTTng Tools 2.1
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.property;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.BaseEventComponent;
-import org.eclipse.tracecompass.tmf.ui.properties.ReadOnlyTextPropertyDescriptor;
-import org.eclipse.ui.views.properties.IPropertyDescriptor;
-
-/**
- * <p>
- * Property source implementation for the base event component.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class BaseEventPropertySource extends BasePropertySource {
-
-    // ------------------------------------------------------------------------
-    // Constants
-    // ------------------------------------------------------------------------
-
-    /**
-     * The base event 'name' property ID.
-     */
-    public static final String BASE_EVENT_NAME_PROPERTY_ID = "base.event.name"; //$NON-NLS-1$
-    /**
-     * The base event 'type' property ID.
-     */
-    public static final String BASE_EVENT_TYPE_PROPERTY_ID = "base.event.type"; //$NON-NLS-1$
-    /**
-     * The base event 'log level' property ID.
-     */
-    public static final String BASE_EVENT_LOGLEVEL_PROPERTY_ID = "base.event.loglevel"; //$NON-NLS-1$
-    /**
-     * The base event 'fields' property ID.
-     */
-    public static final String BASE_EVENT_FIELDS_PROPERTY_ID = "base.event.fields"; //$NON-NLS-1$
-    /**
-     *  The base event 'name' property name.
-     */
-    public static final String BASE_EVENT_NAME_PROPERTY_NAME = Messages.TraceControl_EventNamePropertyName;
-    /**
-     * The base event 'type' property name.
-     */
-    public static final String BASE_EVENT_TYPE_PROPERTY_NAME = Messages.TraceControl_EventTypePropertyName;
-    /**
-     * The base event 'log level' property name.
-     */
-    public static final String BASE_EVENT_LOGLEVEL_PROPERTY_NAME = Messages.TraceControl_LogLevelPropertyName;
-    /**
-     * The base event 'fields' property name.
-     */
-    public static final String BASE_EVENT_FIELDS_PROPERTY_NAME = Messages.TraceControl_FieldsPropertyName;
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-    /**
-     * The base event component which this property source is for.
-     */
-    private final BaseEventComponent fBaseEvent;
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-    /**
-     * Constructor
-     * @param component - the base event component
-     */
-    public BaseEventPropertySource(BaseEventComponent component) {
-        fBaseEvent = component;
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    public IPropertyDescriptor[] getPropertyDescriptors() {
-        List<IPropertyDescriptor> list = new ArrayList<> ();
-        list.add(new ReadOnlyTextPropertyDescriptor(BASE_EVENT_NAME_PROPERTY_ID, BASE_EVENT_NAME_PROPERTY_NAME));
-        list.add(new ReadOnlyTextPropertyDescriptor(BASE_EVENT_TYPE_PROPERTY_ID, BASE_EVENT_TYPE_PROPERTY_NAME));
-        if (fBaseEvent.getLogLevel() != TraceLogLevel.LEVEL_UNKNOWN) {
-            list.add(new ReadOnlyTextPropertyDescriptor(BASE_EVENT_LOGLEVEL_PROPERTY_ID, BASE_EVENT_LOGLEVEL_PROPERTY_NAME));
-        }
-        if (fBaseEvent.getFieldString() != null) {
-            list.add(new ReadOnlyTextPropertyDescriptor(BASE_EVENT_FIELDS_PROPERTY_ID, BASE_EVENT_FIELDS_PROPERTY_NAME));
-        }
-        return list.toArray(new IPropertyDescriptor[list.size()]);
-    }
-
-    @Override
-    public Object getPropertyValue(Object id) {
-        if(BASE_EVENT_NAME_PROPERTY_ID.equals(id)) {
-            return fBaseEvent.getName();
-        }
-        if (BASE_EVENT_TYPE_PROPERTY_ID.equals(id)) {
-            return fBaseEvent.getEventType().name();
-        }
-        if (BASE_EVENT_LOGLEVEL_PROPERTY_ID.equals(id)) {
-            return fBaseEvent.getLogLevel().name();
-        }
-        if (BASE_EVENT_FIELDS_PROPERTY_ID.equals(id)) {
-            return fBaseEvent.getFieldString();
-        }
-        return null;
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/BasePropertySource.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/BasePropertySource.java
deleted file mode 100644 (file)
index 5670b82..0000000
+++ /dev/null
@@ -1,53 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.property;
-
-import org.eclipse.ui.views.properties.IPropertyDescriptor;
-import org.eclipse.ui.views.properties.IPropertySource;
-
-/**
- * <p>
- * Base property source implementation.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public abstract class BasePropertySource implements IPropertySource {
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    public Object getEditableValue() {
-        return null;
-    }
-
-    @Override
-    public abstract IPropertyDescriptor[] getPropertyDescriptors();
-
-    @Override
-    public abstract Object getPropertyValue(Object id);
-
-    @Override
-    public boolean isPropertySet(Object id) {
-        return false;
-    }
-
-    @Override
-    public void resetPropertyValue(Object id) {
-    }
-
-    @Override
-    public void setPropertyValue(Object id, Object value) {
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/KernelProviderPropertySource.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/KernelProviderPropertySource.java
deleted file mode 100644 (file)
index 254ec6f..0000000
+++ /dev/null
@@ -1,80 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *     Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.property;
-
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.KernelProviderComponent;
-import org.eclipse.tracecompass.tmf.ui.properties.ReadOnlyTextPropertyDescriptor;
-import org.eclipse.ui.views.properties.IPropertyDescriptor;
-
-/**
- * <p>
- * Property source implementation for the kernl provider component.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class KernelProviderPropertySource extends BasePropertySource {
-
-    // ------------------------------------------------------------------------
-    // Constants
-    // ------------------------------------------------------------------------
-
-    /**
-     * The kernel provider 'name' property ID.
-     */
-    public static final String KERNEL_PROVIDER_NAME_PROPERTY_ID = "ust.provider.name"; //$NON-NLS-1$
-    /**
-     *  The kernel provider 'name' property name.
-     */
-    public static final String KERNEL_PROVIDER_NAME_PROPERTY_NAME = Messages.TraceControl_ProviderNamePropertyName;
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-
-    /**
-     * The kernel provider component which this property source is for.
-     */
-    private KernelProviderComponent fProvider;
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-
-    /**
-     * Constructor
-     * @param component - the kernel provider component
-     */
-    public KernelProviderPropertySource(KernelProviderComponent component) {
-        fProvider = component;
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    public IPropertyDescriptor[] getPropertyDescriptors() {
-        return new IPropertyDescriptor[] {
-                new ReadOnlyTextPropertyDescriptor(KERNEL_PROVIDER_NAME_PROPERTY_ID, KERNEL_PROVIDER_NAME_PROPERTY_NAME)};
-    }
-
-    @Override
-    public Object getPropertyValue(Object id) {
-        if(KERNEL_PROVIDER_NAME_PROPERTY_ID.equals(id)) {
-            return fProvider.getName();
-        }
-        return null;
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/TargetNodePropertySource.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/TargetNodePropertySource.java
deleted file mode 100644 (file)
index b2850d6..0000000
+++ /dev/null
@@ -1,126 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2015 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Markus Schorn - Bug 448058: Use org.eclipse.remote in favor of RSE
- *   Bernd Hufmann - Update to org.eclipse.remote API 2.0
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.property;
-
-import org.eclipse.remote.core.IRemoteConnectionHostService;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TargetNodeComponent;
-import org.eclipse.tracecompass.tmf.remote.core.proxy.RemoteSystemProxy;
-import org.eclipse.tracecompass.tmf.ui.properties.ReadOnlyTextPropertyDescriptor;
-import org.eclipse.ui.views.properties.IPropertyDescriptor;
-
-/**
- * <p>
- * Property source implementation for the target node component.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class TargetNodePropertySource extends BasePropertySource {
-
-    // ------------------------------------------------------------------------
-    // Constants
-    // ------------------------------------------------------------------------
-    /**
-     * The node name property ID.
-     */
-    public static final String TARGET_NODE_NAME_PROPERTY_ID = "target.node.name"; //$NON-NLS-1$
-    /**
-     * The node address property ID.
-     */
-    public static final String TARGET_NODE_ADDRESS_PROPERTY_ID = "target.node.address"; //$NON-NLS-1$
-    /**
-     * The state property ID.
-     */
-    public static final String TARGET_NODE_STATE_PROPERTY_ID = "target.node.state"; //$NON-NLS-1$
-    /**
-     * The node version property ID.
-     */
-    public static final String TARGET_NODE_VERSION_PROPERTY_ID = "target.node.version"; //$NON-NLS-1$
-
-    /**
-     *  The node name property name.
-     */
-    public static final String TARGET_NODE_NAME_PROPERTY_NAME = Messages.TraceControl_HostNamePropertyName;
-    /**
-     * The node address property name.
-     */
-    public static final String TARGET_NODE_ADDRESS_PROPERTY_NAME = Messages.TraceControl_HostAddressPropertyName;
-    /**
-     * The state address property name.
-     */
-    public static final String TARGET_NODE_STATE_PROPERTY_NAME = Messages.TraceControl_StatePropertyName;
-    /**
-     * The node version property name.
-     */
-    public static final String TARGET_NODE_VERSION_PROPERTY_NAME = Messages.TraceControl_VersionPropertyName;
-
-    /**
-     * The name of the address for local host
-     */
-    private static final String LOCAL_CONNECTION_HOST_NAME = "localhost"; //$NON-NLS-1$
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-    /**
-     * The node component which this property source is for.
-     */
-    private final TargetNodeComponent fTargetNode;
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-    /**
-     * Constructor
-     * @param component - the node component
-     */
-    public TargetNodePropertySource(TargetNodeComponent component) {
-        fTargetNode = component;
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    public IPropertyDescriptor[] getPropertyDescriptors() {
-        return new IPropertyDescriptor[] {
-                new ReadOnlyTextPropertyDescriptor(TARGET_NODE_NAME_PROPERTY_ID, TARGET_NODE_NAME_PROPERTY_NAME),
-                new ReadOnlyTextPropertyDescriptor(TARGET_NODE_ADDRESS_PROPERTY_ID, TARGET_NODE_ADDRESS_PROPERTY_NAME),
-                new ReadOnlyTextPropertyDescriptor(TARGET_NODE_STATE_PROPERTY_ID, TARGET_NODE_STATE_PROPERTY_NAME),
-                new ReadOnlyTextPropertyDescriptor(TARGET_NODE_VERSION_PROPERTY_ID, TARGET_NODE_VERSION_PROPERTY_NAME)};
-    }
-
-    @Override
-    public Object getPropertyValue(Object id) {
-        if(TARGET_NODE_NAME_PROPERTY_ID.equals(id)) {
-            return fTargetNode.getName();
-        }
-        if (TARGET_NODE_ADDRESS_PROPERTY_ID.equals(id)) {
-            RemoteSystemProxy proxy = fTargetNode.getRemoteSystemProxy();
-            if (proxy.getRemoteConnection().hasService(IRemoteConnectionHostService.class)) {
-                return proxy.getRemoteConnection().getService(IRemoteConnectionHostService.class).getHostname();
-            }
-            return LOCAL_CONNECTION_HOST_NAME;
-        }
-        if (TARGET_NODE_STATE_PROPERTY_ID.equals(id)) {
-            return fTargetNode.getTargetNodeState().name();
-        }
-        if (TARGET_NODE_VERSION_PROPERTY_ID.equals(id)) {
-            return fTargetNode.getNodeVersion();
-        }
-        return null;
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/TraceChannelPropertySource.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/TraceChannelPropertySource.java
deleted file mode 100644 (file)
index 786c1ce..0000000
+++ /dev/null
@@ -1,191 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2015 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:
- *     Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.property;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent;
-import org.eclipse.tracecompass.tmf.ui.properties.ReadOnlyTextPropertyDescriptor;
-import org.eclipse.ui.views.properties.IPropertyDescriptor;
-
-/**
- * <p>
- * Property source implementation for the trace channel component.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class TraceChannelPropertySource extends BasePropertySource {
-
-    // ------------------------------------------------------------------------
-    // Constants
-    // ------------------------------------------------------------------------
-    /**
-     * The trace channel 'name' property ID.
-     */
-    public static final String TRACE_CHANNEL_NAME_PROPERTY_ID = "trace.channel.name"; //$NON-NLS-1$
-    /**
-     * The trace channel 'state' ID.
-     */
-    public static final String TRACE_CHANNEL_STATE_PROPERTY_ID = "trace.channel.state"; //$NON-NLS-1$
-    /**
-     * The trace channel 'overwrite mode' property ID.
-     */
-    public static final String TRACE_CHANNEL_OVERWRITE_MODE_PROPERTY_ID = "trace.channel.overwrite.mode"; //$NON-NLS-1$
-    /**
-     * The trace channel 'sub-buffer size' property ID.
-     */
-    public static final String TRACE_CHANNEL_SUBBUFFER_SIZE_PROPERTY_ID = "trace.channel.subbuffer.size"; //$NON-NLS-1$
-    /**
-     * The trace channel 'number of sub-buffers' property ID.
-     */
-    public static final String TRACE_CHANNEL_NO_SUBBUFFERS_PROPERTY_ID = "trace.channel.no.subbuffers"; //$NON-NLS-1$
-    /**
-     * The trace channel 'switch timer interval' property ID.
-     */
-    public static final String TRACE_CHANNEL_SWITCH_TIMER_PROPERTY_ID = "trace.channel.switch.timer"; //$NON-NLS-1$
-    /**
-     * The trace channel 'read timer interval' property ID.
-     */
-    public static final String TRACE_CHANNEL_READ_TIMER_PROPERTY_ID = "trace.channel.read.timer"; //$NON-NLS-1$
-    /**
-     * The trace channel 'output type' property ID.
-     */
-    public static final String TRACE_CHANNEL_OUTPUT_TYPE_PROPERTY_ID = "trace.channel.output.type"; //$NON-NLS-1$
-    /**
-     * The trace channel 'trace file count' property ID.
-     */
-    public static final String TRACE_CHANNEL_TRACE_FILE_COUNT_PROPERTY_ID = "trace.channel.trace.file.count"; //$NON-NLS-1$
-    /**
-     * The trace channel 'trace file size' property ID.
-     */
-    public static final String TRACE_CHANNEL_TRACE_FILE_SIZE_PROPERTY_ID = "trace.channel.trace.file.size"; //$NON-NLS-1$
-    /**
-     *  The trace channel 'name' property name.
-     */
-    public static final String TRACE_CHANNEL_NAME_PROPERTY_NAME = Messages.TraceControl_ChannelNamePropertyName;
-    /**
-     * The trace channel 'state' property name.
-     */
-    public static final String TRACE_CHANNEL_STATE_PROPERTY_NAME = Messages.TraceControl_StatePropertyName;
-    /**
-     *  The trace channel 'overwrite mode' property name.
-     */
-    public static final String TRACE_CHANNEL_OVERWRITE_MODE_PROPERTY_NAME = Messages.TraceControl_OverwriteModePropertyName;
-    /**
-     *  The trace channel 'sub-buffer size' property name.
-     */
-    public static final String TRACE_CHANNEL_SUBBUFFER_SIZE_PROPERTY_NAME = Messages.TraceControl_SubBufferSizePropertyName;
-    /**
-     *  The trace channel 'sub-buffer size' property name.
-     */
-    public static final String TRACE_CHANNEL_NO_SUBBUFFERS_PROPERTY_NAME = Messages.TraceControl_NbSubBuffersPropertyName;
-    /**
-     *  The trace channel 'switch timer interval' property name.
-     */
-    public static final String TRACE_CHANNEL_SWITCH_TIMER_PROPERTY_NAME = Messages.TraceControl_SwitchTimerPropertyName;
-    /**
-     *  The trace channel 'read timer interval' property name.
-     */
-    public static final String TRACE_CHANNEL_READ_TIMER_PROPERTY_NAME = Messages.TraceControl_ReadTimerPropertyName;
-    /**
-     *  The trace channel 'output type' property name.
-     */
-    public static final String TRACE_CHANNEL_OUTPUT_TYPEPROPERTY_NAME = Messages.TraceControl_OutputTypePropertyName;
-    /**
-     * The trace channel 'trace file count' property name.
-     */
-    public static final String TRACE_CHANNEL_TRACE_FILE_COUNT_PROPERTY_NAME = Messages.TraceControl_TraceFileCountPropertyName;
-    /**
-     * The trace channel 'trace file size' property name.
-     */
-    public static final String TRACE_CHANNEL_TRACE_FILE_SIZE_PROPERTY_NAME = Messages.TraceControl_TraceFileSizePropertyName;
-
-    // Attributes
-    // ------------------------------------------------------------------------
-    /**
-     * The channel component which this property source is for.
-     */
-    private final TraceChannelComponent fChannel;
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-    /**
-     * Constructor
-     * @param component - the channel component
-     */
-    public TraceChannelPropertySource(TraceChannelComponent component) {
-        fChannel = component;
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    public IPropertyDescriptor[] getPropertyDescriptors() {
-        List<IPropertyDescriptor> properties = new ArrayList<>();
-        properties.add(new ReadOnlyTextPropertyDescriptor(TRACE_CHANNEL_NAME_PROPERTY_ID, TRACE_CHANNEL_NAME_PROPERTY_NAME));
-        properties.add(new ReadOnlyTextPropertyDescriptor(TRACE_CHANNEL_STATE_PROPERTY_ID, TRACE_CHANNEL_STATE_PROPERTY_NAME));
-        properties.add(new ReadOnlyTextPropertyDescriptor(TRACE_CHANNEL_OVERWRITE_MODE_PROPERTY_ID, TRACE_CHANNEL_OVERWRITE_MODE_PROPERTY_NAME));
-        properties.add(new ReadOnlyTextPropertyDescriptor(TRACE_CHANNEL_SUBBUFFER_SIZE_PROPERTY_ID, TRACE_CHANNEL_SUBBUFFER_SIZE_PROPERTY_NAME));
-        properties.add(new ReadOnlyTextPropertyDescriptor(TRACE_CHANNEL_NO_SUBBUFFERS_PROPERTY_ID, TRACE_CHANNEL_NO_SUBBUFFERS_PROPERTY_NAME));
-        properties.add(new ReadOnlyTextPropertyDescriptor(TRACE_CHANNEL_SWITCH_TIMER_PROPERTY_ID, TRACE_CHANNEL_SWITCH_TIMER_PROPERTY_NAME));
-        properties.add(new ReadOnlyTextPropertyDescriptor(TRACE_CHANNEL_READ_TIMER_PROPERTY_ID, TRACE_CHANNEL_READ_TIMER_PROPERTY_NAME));
-        properties.add(new ReadOnlyTextPropertyDescriptor(TRACE_CHANNEL_OUTPUT_TYPE_PROPERTY_ID, TRACE_CHANNEL_OUTPUT_TYPEPROPERTY_NAME));
-
-        if (fChannel.getTargetNode().isVersionSupported("2.5.0")) { //$NON-NLS-1$
-            properties.add(new ReadOnlyTextPropertyDescriptor(TRACE_CHANNEL_TRACE_FILE_COUNT_PROPERTY_ID, TRACE_CHANNEL_TRACE_FILE_COUNT_PROPERTY_NAME));
-            properties.add(new ReadOnlyTextPropertyDescriptor(TRACE_CHANNEL_TRACE_FILE_SIZE_PROPERTY_ID, TRACE_CHANNEL_TRACE_FILE_SIZE_PROPERTY_NAME));
-        }
-        return properties.toArray(new IPropertyDescriptor[0]);
-    }
-
-    @Override
-    public Object getPropertyValue(Object id) {
-        if(TRACE_CHANNEL_NAME_PROPERTY_ID.equals(id)) {
-            return fChannel.getName();
-        }
-        if (TRACE_CHANNEL_STATE_PROPERTY_ID.equals(id)) {
-            return fChannel.getState().name();
-        }
-        if(TRACE_CHANNEL_OVERWRITE_MODE_PROPERTY_ID.equals(id)) {
-            return String.valueOf(fChannel.isOverwriteMode());
-        }
-        if(TRACE_CHANNEL_SUBBUFFER_SIZE_PROPERTY_ID.equals(id)) {
-            return String.valueOf(fChannel.getSubBufferSize());
-        }
-        if(TRACE_CHANNEL_NO_SUBBUFFERS_PROPERTY_ID.equals(id)) {
-            return String.valueOf(fChannel.getNumberOfSubBuffers());
-        }
-        if(TRACE_CHANNEL_SWITCH_TIMER_PROPERTY_ID.equals(id)) {
-            return String.valueOf(fChannel.getSwitchTimer());
-        }
-        if(TRACE_CHANNEL_READ_TIMER_PROPERTY_ID.equals(id)) {
-            return String.valueOf(fChannel.getReadTimer());
-        }
-        if(TRACE_CHANNEL_OUTPUT_TYPE_PROPERTY_ID.equals(id)) {
-            return fChannel.getOutputType().getInName();
-        }
-        if (TRACE_CHANNEL_TRACE_FILE_COUNT_PROPERTY_ID.equals(id)) {
-            return fChannel.getMaxNumberTraceFiles();
-        }
-        if (TRACE_CHANNEL_TRACE_FILE_SIZE_PROPERTY_ID.equals(id)) {
-            return fChannel.getMaxSizeTraceFiles();
-        }
-        return null;
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/TraceDomainPropertySource.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/TraceDomainPropertySource.java
deleted file mode 100644 (file)
index 799a821..0000000
+++ /dev/null
@@ -1,99 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *     Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.property;
-
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.BufferType;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceDomainComponent;
-import org.eclipse.tracecompass.tmf.ui.properties.ReadOnlyTextPropertyDescriptor;
-import org.eclipse.ui.views.properties.IPropertyDescriptor;
-
-/**
- * <p>
- * Property source implementation for the trace domain component.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class TraceDomainPropertySource extends BasePropertySource {
-
-    // ------------------------------------------------------------------------
-    // Constants
-    // ------------------------------------------------------------------------
-
-    /**
-     * The trace domain 'name' property ID.
-     */
-    public static final String TRACE_DOMAIN_NAME_PROPERTY_ID = "trace.domain.name"; //$NON-NLS-1$
-    /**
-     *  The trace domain 'name' property name.
-     */
-    public static final String TRACE_DOMAIN_NAME_PROPERTY_NAME = Messages.TraceControl_DomainNamePropertyName;
-    /**
-     * The domain 'buffer type' property ID.
-     */
-    public static final String BUFFER_TYPE_PROPERTY_ID = "trace.domain.bufferType"; //$NON-NLS-1$
-    /**
-     * The domain 'buffer type' property name.
-     */
-    public static final String BUFER_TYPE_PROPERTY_NAME = Messages.TraceControl_BufferTypePropertyName;
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-
-    /**
-     * The trace domain component which this property source is for.
-     */
-    private final TraceDomainComponent fDomain;
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-
-    /**
-     * Constructor
-     * @param component - the trace domain component
-     */
-    public TraceDomainPropertySource(TraceDomainComponent component) {
-        fDomain = component;
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    public IPropertyDescriptor[] getPropertyDescriptors() {
-        if (fDomain.getBufferType() == BufferType.BUFFER_TYPE_UNKNOWN) {
-            return new IPropertyDescriptor[] {
-                    new ReadOnlyTextPropertyDescriptor(TRACE_DOMAIN_NAME_PROPERTY_ID, TRACE_DOMAIN_NAME_PROPERTY_NAME) };
-        }
-
-        return new IPropertyDescriptor[] {
-                new ReadOnlyTextPropertyDescriptor(TRACE_DOMAIN_NAME_PROPERTY_ID, TRACE_DOMAIN_NAME_PROPERTY_NAME),
-                new ReadOnlyTextPropertyDescriptor(BUFFER_TYPE_PROPERTY_ID, BUFER_TYPE_PROPERTY_NAME) };
-    }
-
-    @Override
-    public Object getPropertyValue(Object id) {
-        if(BUFFER_TYPE_PROPERTY_ID.equals(id)){
-            return fDomain.getBufferType().getInName();
-        }
-
-        if(TRACE_DOMAIN_NAME_PROPERTY_ID.equals(id)) {
-            return fDomain.getName();
-        }
-        return null;
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/TraceEventPropertySource.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/TraceEventPropertySource.java
deleted file mode 100644 (file)
index 4867206..0000000
+++ /dev/null
@@ -1,145 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *     Bernd Hufmann - Initial API and implementation
- *     Bernd Hufmann - Updated for support of LTTng Tools 2.1
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.property;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.LogLevelType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceEventComponent;
-import org.eclipse.tracecompass.tmf.ui.properties.ReadOnlyTextPropertyDescriptor;
-import org.eclipse.ui.views.properties.IPropertyDescriptor;
-
-/**
- * <p>
- * Property source implementation for the trace event component.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class TraceEventPropertySource extends BasePropertySource {
-
-    // ------------------------------------------------------------------------
-    // Constants
-    // ------------------------------------------------------------------------
-    /**
-     * The trace event 'name' property ID.
-     */
-    public static final String TRACE_EVENT_NAME_PROPERTY_ID = "trace.event.name"; //$NON-NLS-1$
-    /**
-     * The trace event 'type' property ID.
-     */
-    public static final String TRACE_EVENT_TYPE_PROPERTY_ID = "trace.event.type"; //$NON-NLS-1$
-    /**
-     * The trace event 'log level' property ID.
-     */
-    public static final String TRACE_EVENT_LOGLEVEL_PROPERTY_ID = "trace.event.loglevel"; //$NON-NLS-1$
-    /**
-     * The trace event 'state' property ID.
-     */
-    public static final String TRACE_EVENT_STATE_PROPERTY_ID = "trace.event.state"; //$NON-NLS-1$
-    /**
-     * The trace event 'filter' property ID.
-     */
-    public static final String TRACE_EVENT_FILTER_PROPERTY_ID = "trace.event.filter"; //$NON-NLS-1$
-
-    /**
-     *  The trace event 'name' property name.
-     */
-    public static final String TRACE_EVENT_NAME_PROPERTY_NAME = Messages.TraceControl_EventNamePropertyName;
-    /**
-     * The trace event 'type' property name.
-     */
-    public static final String TRACE_EVENT_TYPE_PROPERTY_NAME = Messages.TraceControl_EventTypePropertyName;
-    /**
-     * The trace event 'log level' property name.
-     */
-    public static final String TRACE_EVENT_LOGLEVEL_PROPERTY_NAME = Messages.TraceControl_LogLevelPropertyName;
-    /**
-     * The trace event 'state' property name.
-     */
-    public static final String TRACE_EVENT_STATE_PROPERTY_NAME = Messages.TraceControl_StatePropertyName;
-    /**
-     * The trace event 'filter' property name.
-     */
-    public static final String TRACE_EVENT_FILTER_PROPERTY_NAME = Messages.TraceControl_FilterPropertyName;
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-
-    /**
-     * The event component which this property source is for.
-     */
-    protected final TraceEventComponent fEvent;
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-
-    /**
-     * Constructor
-     * @param component - the base event component
-     */
-    public TraceEventPropertySource(TraceEventComponent component) {
-        fEvent = component;
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    public IPropertyDescriptor[] getPropertyDescriptors() {
-        List<IPropertyDescriptor> list = new ArrayList<> ();
-        list.add(new ReadOnlyTextPropertyDescriptor(TRACE_EVENT_NAME_PROPERTY_ID, TRACE_EVENT_NAME_PROPERTY_NAME));
-        list.add(new ReadOnlyTextPropertyDescriptor(TRACE_EVENT_TYPE_PROPERTY_ID, TRACE_EVENT_TYPE_PROPERTY_NAME));
-        list.add( new ReadOnlyTextPropertyDescriptor(TRACE_EVENT_STATE_PROPERTY_ID, TRACE_EVENT_STATE_PROPERTY_NAME));
-        if (fEvent.getLogLevel() != TraceLogLevel.LEVEL_UNKNOWN) {
-            list.add(new ReadOnlyTextPropertyDescriptor(TRACE_EVENT_LOGLEVEL_PROPERTY_ID, TRACE_EVENT_LOGLEVEL_PROPERTY_NAME));
-        }
-        if (fEvent.getFilterExpression() != null) {
-            list.add(new ReadOnlyTextPropertyDescriptor(TRACE_EVENT_FILTER_PROPERTY_ID, TRACE_EVENT_FILTER_PROPERTY_NAME));
-        }
-        return list.toArray(new IPropertyDescriptor[list.size()]);
-    }
-
-    @Override
-    public Object getPropertyValue(Object id) {
-        if(TRACE_EVENT_NAME_PROPERTY_ID.equals(id)) {
-            return fEvent.getName();
-        }
-        if (TRACE_EVENT_TYPE_PROPERTY_ID.equals(id)) {
-            return fEvent.getEventType().name();
-        }
-        if (TRACE_EVENT_LOGLEVEL_PROPERTY_ID.equals(id)) {
-            StringBuffer buffer = new StringBuffer();
-            if (fEvent.getLogLevelType() != LogLevelType.LOGLEVEL_NONE) {
-                buffer.append(fEvent.getLogLevelType().getShortName()).append(' ');
-            }
-            buffer.append(fEvent.getLogLevel().name());
-            return buffer.toString();
-        }
-        if (TRACE_EVENT_STATE_PROPERTY_ID.equals(id)) {
-            return fEvent.getState().name();
-        }
-        if (TRACE_EVENT_FILTER_PROPERTY_ID.equals(id)) {
-            return fEvent.getFilterExpression();
-        }
-
-        return null;
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/TraceProbeEventPropertySource.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/TraceProbeEventPropertySource.java
deleted file mode 100644 (file)
index 22f2e1a..0000000
+++ /dev/null
@@ -1,124 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *     Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.property;
-
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.List;
-
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceEventComponent;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceProbeEventComponent;
-import org.eclipse.tracecompass.tmf.ui.properties.ReadOnlyTextPropertyDescriptor;
-import org.eclipse.ui.views.properties.IPropertyDescriptor;
-
-/**
- * <p>
- * Property source implementation for the trace probe event component.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class TraceProbeEventPropertySource extends TraceEventPropertySource {
-
-    // ------------------------------------------------------------------------
-    // Constants
-    // ------------------------------------------------------------------------
-    /**
-     * The trace event 'probe address' property ID.
-     */
-    public static final String TRACE_EVENT_PROBE_ADDRESS_PROPERTY_ID = "trace.event.probe.address"; //$NON-NLS-1$
-    /**
-     * The trace event 'probe offset' property ID.
-     */
-    public static final String TRACE_EVENT_PROBE_OFFSET_PROPERTY_ID = "trace.event.probe.offset"; //$NON-NLS-1$
-    /**
-     * The trace event 'probe symbol' property ID.
-     */
-    public static final String TRACE_EVENT_PROBE_SYMBOL_PROPERTY_ID = "trace.event.probe.symbol"; //$NON-NLS-1$
-    /**
-     * The trace event 'probe address' property name.
-     */
-    public static final String TRACE_EVENT_PROBE_ADDRESS_PROPERTY_NAME = Messages.TraceControl_ProbeAddressPropertyName;
-    /**
-     * The trace event 'probe offset' property ID.
-     */
-    public static final String TRACE_EVENT_PROBE_OFFSET_PROPERTY_NAME = Messages.TraceControl_ProbeOffsetPropertyName;
-    /**
-     * The trace event 'probe symbol' property ID.
-     */
-    public static final String TRACE_EVENT_PROBE_SYMBOL_PROPERTY_NAME = Messages.TraceControl_ProbeSymbolPropertyName;
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-
-    /**
-     * Constructor
-     *
-     * @param component
-     *            A trace event component
-     */
-    public TraceProbeEventPropertySource(TraceEventComponent component) {
-        super(component);
-        if (component.getClass() != TraceProbeEventComponent.class) {
-            throw new IllegalArgumentException("Invalid type passed. Only class of type TraceProbeEventComponent allowed:\n" + component.getClass()); //$NON-NLS-1$
-        }
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    public IPropertyDescriptor[] getPropertyDescriptors() {
-        IPropertyDescriptor[] superProperties = super.getPropertyDescriptors();
-
-        List<IPropertyDescriptor> superList = Arrays.asList(superProperties);
-        ArrayList<IPropertyDescriptor> list = new ArrayList<>();
-        list.addAll(superList);
-
-        if (fEvent instanceof TraceProbeEventComponent) {
-            TraceProbeEventComponent event = (TraceProbeEventComponent) fEvent;
-            if (event.getAddress() != null) {
-                list.add(new ReadOnlyTextPropertyDescriptor(TRACE_EVENT_PROBE_ADDRESS_PROPERTY_ID, TRACE_EVENT_PROBE_ADDRESS_PROPERTY_NAME));
-            }
-
-            if (event.getOffset() != null) {
-                list.add(new ReadOnlyTextPropertyDescriptor(TRACE_EVENT_PROBE_OFFSET_PROPERTY_ID, TRACE_EVENT_PROBE_OFFSET_PROPERTY_NAME));
-            }
-
-            if (event.getSymbol() != null) {
-                list.add(new ReadOnlyTextPropertyDescriptor(TRACE_EVENT_PROBE_SYMBOL_PROPERTY_ID, TRACE_EVENT_PROBE_SYMBOL_PROPERTY_NAME));
-            }
-        }
-        return list.toArray(new IPropertyDescriptor[list.size()]);
-    }
-
-    @Override
-    public Object getPropertyValue(Object id) {
-        if(TRACE_EVENT_PROBE_ADDRESS_PROPERTY_ID.equals(id)) {
-            return ((TraceProbeEventComponent)fEvent).getAddress();
-        }
-        if (TRACE_EVENT_PROBE_OFFSET_PROPERTY_ID.equals(id)) {
-            return ((TraceProbeEventComponent)fEvent).getOffset();
-        }
-        if (TRACE_EVENT_PROBE_SYMBOL_PROPERTY_ID.equals(id)) {
-            return ((TraceProbeEventComponent)fEvent).getSymbol();
-        }
-        return super.getPropertyValue(id);
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/TraceSessionPropertySource.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/TraceSessionPropertySource.java
deleted file mode 100644 (file)
index 0d4310a..0000000
+++ /dev/null
@@ -1,147 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *     Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.property;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
-import org.eclipse.tracecompass.tmf.ui.properties.ReadOnlyTextPropertyDescriptor;
-import org.eclipse.ui.views.properties.IPropertyDescriptor;
-
-/**
- * <p>
- * Property source implementation for the trace session component.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class TraceSessionPropertySource extends BasePropertySource {
-
-    // ------------------------------------------------------------------------
-    // Constants
-    // ------------------------------------------------------------------------
-    /**
-     * The trace session name property ID.
-     */
-    public static final String TRACE_SESSION_NAME_PROPERTY_ID = "trace.session.name"; //$NON-NLS-1$
-    /**
-     * The trace session path property ID.
-     */
-    public static final String TRACE_SESSION_PATH_PROPERTY_ID = "trace.session.path"; //$NON-NLS-1$
-    /**
-     * The trace session state ID.
-     */
-    public static final String TRACE_SESSION_STATE_PROPERTY_ID = "trace.session.state"; //$NON-NLS-1$
-    /**
-     * The trace snapshot path property ID.
-     */
-    public static final String TRACE_SNAPSHOT_PATH_PROPERTY_ID = "trace.snapshot.path"; //$NON-NLS-1$
-    /**
-     * The snapshot name property.
-     */
-    public static final String TRACE_SNAPSHOT_NAME_PROPERTY_ID = "trace.snapshot.name"; //$NON-NLS-1$
-    /**
-     * The snapshot ID property.
-     */
-    public static final String TRACE_SNAPSHOT_ID_PROPERTY_ID = "trace.snapshot.id"; //$NON-NLS-1$
-
-    /**
-     *  The trace session name property name.
-     */
-    public static final String TRACE_SESSION_NAME_PROPERTY_NAME = Messages.TraceControl_SessionNamePropertyName;
-    /**
-     *  The trace session path property name.
-     */
-    public static final String TRACE_SESSION_PATH_PROPERTY_NAME = Messages.TraceControl_SessionPathPropertyName;
-    /**
-     * The trace session state property name.
-     */
-    public static final String TRACE_SESSION_STATE_PROPERTY_NAME = Messages.TraceControl_StatePropertyName;
-    /**
-     *  The snapshot path property name.
-     */
-    public static final String TRACE_SNAPSHOT_PATH_PROPERTY_NAME = Messages.TraceControl_SnapshotPathPropertyName;
-    /**
-     * The trace snapshot name property name.
-     */
-    public static final String TRACE_SNAPSHOT_NAME_PROPERTY_NAME = Messages.TraceControl_SnapshotNamePropertyName;
-    /**
-     * The trace snapshot ID property name.
-     */
-    public static final String TRACE_SNAPSHOT_ID_PROPERTY_NAME = Messages.TraceControl_SnapshotIdPropertyName;
-
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-
-    /**
-     * The session component which this property source is for.
-     */
-    private final TraceSessionComponent fSession;
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-
-    /**
-     * Constructor
-     * @param component - the session component
-     */
-    public TraceSessionPropertySource(TraceSessionComponent component) {
-        fSession = component;
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    public IPropertyDescriptor[] getPropertyDescriptors() {
-        List<IPropertyDescriptor> list = new ArrayList<>();
-        list.add(new ReadOnlyTextPropertyDescriptor(TRACE_SESSION_NAME_PROPERTY_ID, TRACE_SESSION_NAME_PROPERTY_NAME));
-        list.add(new ReadOnlyTextPropertyDescriptor(TRACE_SESSION_STATE_PROPERTY_ID, TRACE_SESSION_STATE_PROPERTY_NAME));
-        if (fSession.isSnapshotSession()) {
-            list.add(new ReadOnlyTextPropertyDescriptor(TRACE_SNAPSHOT_NAME_PROPERTY_ID, TRACE_SNAPSHOT_NAME_PROPERTY_NAME));
-            list.add(new ReadOnlyTextPropertyDescriptor(TRACE_SNAPSHOT_PATH_PROPERTY_ID, TRACE_SNAPSHOT_PATH_PROPERTY_NAME));
-            list.add(new ReadOnlyTextPropertyDescriptor(TRACE_SNAPSHOT_ID_PROPERTY_ID, TRACE_SNAPSHOT_ID_PROPERTY_NAME));
-        } else {
-            list.add(new ReadOnlyTextPropertyDescriptor(TRACE_SESSION_PATH_PROPERTY_ID, TRACE_SESSION_PATH_PROPERTY_NAME));
-        }
-        return(list.toArray(new IPropertyDescriptor[list.size()]));
-    }
-
-    @Override
-    public Object getPropertyValue(Object id) {
-        if(TRACE_SESSION_NAME_PROPERTY_ID.equals(id)) {
-            return fSession.getName();
-        }
-        if(TRACE_SESSION_PATH_PROPERTY_ID.equals(id)) {
-            return fSession.getSessionPath();
-        }
-        if (TRACE_SESSION_STATE_PROPERTY_ID.equals(id)) {
-            return fSession.getSessionState().name();
-        }
-        if (TRACE_SNAPSHOT_PATH_PROPERTY_ID.equals(id)) {
-            return (fSession.isSnapshotSession() ? fSession.getSnapshotInfo().getSnapshotPath() : ""); //$NON-NLS-1$
-        }
-        if (TRACE_SNAPSHOT_NAME_PROPERTY_ID.equals(id)) {
-            return (fSession.isSnapshotSession() ? fSession.getSnapshotInfo().getName() : ""); //$NON-NLS-1$
-        }
-        if (TRACE_SNAPSHOT_ID_PROPERTY_ID.equals(id)) {
-            return (fSession.isSnapshotSession() ? fSession.getSnapshotInfo().getId() : ""); //$NON-NLS-1$
-        }
-        return null;
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/UstProviderPropertySource.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/property/UstProviderPropertySource.java
deleted file mode 100644 (file)
index 908a791..0000000
+++ /dev/null
@@ -1,91 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *     Bernd Hufmann - Initial API and implementation
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.property;
-
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.UstProviderComponent;
-import org.eclipse.tracecompass.tmf.ui.properties.ReadOnlyTextPropertyDescriptor;
-import org.eclipse.ui.views.properties.IPropertyDescriptor;
-
-/**
- * <p>
- * Property source implementation for the UST provider component.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class UstProviderPropertySource extends BasePropertySource {
-
-    // ------------------------------------------------------------------------
-    // Constants
-    // ------------------------------------------------------------------------
-    /**
-     * The UST provider 'name' property ID.
-     */
-    public static final String UST_PROVIDER_NAME_PROPERTY_ID = "ust.provider.name"; //$NON-NLS-1$
-    /**
-     * The UST provider 'PID' property ID.
-     */
-    public static final String UST_PROVIDER_PID_PROPERTY_ID = "ust.provider.pid"; //$NON-NLS-1$
-    /**
-     *  The UST provider 'name' property name.
-     */
-    public static final String UST_PROVIDER_NAME_PROPERTY_NAME = Messages.TraceControl_ProviderNamePropertyName;
-    /**
-     * The UST provider 'type' property name.
-     */
-    public static final String UST_PROVIDER_PID_PROPERTY_NAME = Messages.TraceControl_ProcessIdPropertyName;
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-
-    /**
-     * The UST provider component which this property source is for.
-     */
-    private UstProviderComponent fUstProvider;
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-
-    /**
-     * Constructor
-     * @param component - the UST provider component
-     */
-    public UstProviderPropertySource(UstProviderComponent component) {
-        fUstProvider = component;
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    public IPropertyDescriptor[] getPropertyDescriptors() {
-        return new IPropertyDescriptor[] {
-                new ReadOnlyTextPropertyDescriptor(UST_PROVIDER_NAME_PROPERTY_ID, UST_PROVIDER_NAME_PROPERTY_NAME),
-                new ReadOnlyTextPropertyDescriptor(UST_PROVIDER_PID_PROPERTY_ID, UST_PROVIDER_PID_PROPERTY_NAME)};
-    }
-
-    @Override
-    public Object getPropertyValue(Object id) {
-        if(UST_PROVIDER_NAME_PROPERTY_ID.equals(id)) {
-            return fUstProvider.getName();
-        }
-        if (UST_PROVIDER_PID_PROPERTY_ID.equals(id)) {
-            return String.valueOf(fUstProvider.getPid());
-        }
-        return null;
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/service/ILttngControlService.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/service/ILttngControlService.java
deleted file mode 100644 (file)
index 81d9bd5..0000000
+++ /dev/null
@@ -1,403 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.service;
-
-import java.util.List;
-
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.jdt.annotation.NonNull;
-import org.eclipse.jdt.annotation.Nullable;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IBaseEventInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IChannelInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISessionInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISnapshotInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IUstProviderInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.LogLevelType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
-
-
-/**
-* <p>
-* Interface for LTTng trace control command service.
-* </p>
-*
-* @author Bernd Hufmann
-*/
-public interface ILttngControlService {
-
-    /**
-     * @return the LTTng version object
-     */
-    @NonNull LttngVersion getVersion();
-
-    /**
-     * @return the version string
-     */
-    @NonNull String getVersionString();
-
-    /**
-     * Checks if given version is supported by this ILTTngControlService implementation.
-     *
-     * @param version The version to check
-     * @return <code>true</code> if version is supported else <code>false</code>
-     */
-    boolean isVersionSupported(String version);
-
-    /**
-     * Retrieves the existing sessions names from the node.
-     *
-     * @param monitor
-     *            - a progress monitor
-     * @return a list of session names.
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    @NonNull List<String> getSessionNames(IProgressMonitor monitor) throws ExecutionException;
-
-    /**
-     * Retrieves the session information with the given name the node.
-     *
-     * @param sessionName
-     *            - the session name
-     * @param monitor
-     *            - a progress monitor
-     * @return session information
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    @Nullable ISessionInfo getSession(String sessionName, IProgressMonitor monitor)
-            throws ExecutionException;
-
-    /**
-     * Retrieves the snapshot output information from the node
-     * @param sessionName
-     *            - the session name
-     * @param monitor
-     *            - a progress monitor
-     * @return snapshot output information
-     * @throws ExecutionException
-     *          if command fails
-     */
-    @Nullable ISnapshotInfo getSnapshotInfo(String sessionName, IProgressMonitor monitor)
-            throws ExecutionException;
-
-    /**
-     * Retrieves the kernel provider information (i.e. the kernel events)
-     *
-     * @param monitor
-     *            - a progress monitor
-     * @return the list of existing kernel events.
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    @NonNull List<IBaseEventInfo> getKernelProvider(IProgressMonitor monitor)
-            throws ExecutionException;
-
-    /**
-     * Retrieves the UST provider information from the node.
-     *
-     * @return - the UST provider information.
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    @NonNull public List<IUstProviderInfo> getUstProvider() throws ExecutionException;
-
-    /**
-     * Retrieves the UST provider information from the node.
-     *
-     * @param monitor
-     *            - a progress monitor
-     * @return the UST provider information.
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    @NonNull List<IUstProviderInfo> getUstProvider(IProgressMonitor monitor)
-            throws ExecutionException;
-
-    /**
-     * Creates a session with given session name and location.
-     *
-     * @param sessionInfo
-     *            the session information used to create the session
-     * @param monitor
-     *            - a progress monitor
-     *
-     * @return the session information
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    @Nullable ISessionInfo createSession(ISessionInfo sessionInfo, IProgressMonitor monitor) throws ExecutionException;
-
-    /**
-     * Destroys a session with given session name.
-     *
-     * @param sessionName
-     *            - a session name to destroy
-     * @param monitor
-     *            - a progress monitor
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    void destroySession(String sessionName, IProgressMonitor monitor)
-            throws ExecutionException;
-
-    /**
-     * Starts a session with given session name.
-     *
-     * @param sessionName
-     *            - a session name to start
-     * @param monitor
-     *            - a progress monitor
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    void startSession(String sessionName, IProgressMonitor monitor)
-            throws ExecutionException;
-
-    /**
-     * Stops a session with given session name.
-     *
-     * @param sessionName
-     *            - a session name to stop
-     * @param monitor
-     *            - a progress monitor
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    void stopSession(String sessionName, IProgressMonitor monitor)
-            throws ExecutionException;
-
-    /**
-     * Enables a list of channels for given session and given channel
-     * information (configuration).
-     *
-     * @param sessionName
-     *            - a session name to create
-     * @param channelNames
-     *            - a list of channel names to be enabled
-     * @param isKernel
-     *            - a flag to indicate Kernel or UST (true for Kernel, false for
-     *            UST)
-     * @param info
-     *            - channel information used for creation of a channel (or null
-     *            for default)
-     * @param monitor
-     *            - a progress monitor
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    void enableChannels(String sessionName, List<String> channelNames,
-            boolean isKernel, IChannelInfo info, IProgressMonitor monitor)
-            throws ExecutionException;
-
-    /**
-     * Disables a list of channels for given session and given channel
-     * information (configuration).
-     *
-     * @param sessionName
-     *            - a session name to create
-     * @param channelNames
-     *            - a list of channel names to be enabled
-     * @param isKernel
-     *            - a flag to indicate Kernel or UST (true for Kernel, false for
-     *            UST)
-     * @param monitor
-     *            - a progress monitor
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    void disableChannels(String sessionName, List<String> channelNames,
-            boolean isKernel, IProgressMonitor monitor)
-            throws ExecutionException;
-
-    /**
-     * Enables a list of events with no additional parameters.
-     *
-     * @param sessionName
-     *            - a session name
-     * @param channelName
-     *            - a channel name or null for default channel
-     * @param eventNames
-     *            - a list of event names to be enabled, or null (list of size =
-     *            0)for all events .
-     * @param isKernel
-     *            - a flag for indicating kernel or UST.
-     * @param filterExpression
-     *            - a filter expression
-     * @param monitor
-     *            - a progress monitor
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    void enableEvents(String sessionName, String channelName,
-            List<String> eventNames, boolean isKernel, String filterExpression,
-            IProgressMonitor monitor)
-            throws ExecutionException;
-
-
-    /**
-     * Enables all syscall events.
-     *
-     * @param sessionName
-     *            - a session name
-     * @param channelName
-     *            - a channel name or null for default channel
-     * @param monitor
-     *            - a progress monitor
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    void enableSyscalls(String sessionName, String channelName,
-            IProgressMonitor monitor) throws ExecutionException;
-
-    /**
-     * Enables a dynamic probe or dynamic function entry/return probe.
-     *
-     * @param sessionName
-     *            - a session name
-     * @param channelName
-     *            - a channel name or null for default channel
-     * @param eventName
-     *            - a event name
-     * @param isFunction
-     *            - true for dynamic function entry/return probe else false
-     * @param probe
-     *            - a dynamic probe information
-     * @param monitor
-     *            - a progress monitor
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    void enableProbe(String sessionName, String channelName,
-            String eventName, boolean isFunction, String probe,
-            IProgressMonitor monitor) throws ExecutionException;
-
-    /**
-     * Enables events using log level
-     *
-     * @param sessionName
-     *            - a session name
-     * @param channelName
-     *            - a channel name (null for default channel)
-     * @param eventName
-     *            - a event name
-     * @param logLevelType
-     *            - a log level type
-     * @param level
-     *            - a log level
-     * @param filterExpression
-     *            - a filter expression
-     * @param monitor
-     *            - a progress monitor
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    void enableLogLevel(String sessionName, String channelName,
-            String eventName, LogLevelType logLevelType, TraceLogLevel level,
-            String filterExpression,
-            IProgressMonitor monitor) throws ExecutionException;
-
-    /**
-     * Disables a list of events with no additional parameters.
-     *
-     * @param sessionName
-     *            - a session name
-     * @param channelName
-     *            - a channel name (null for default channel)
-     * @param eventNames
-     *            - a list of event names to enabled.
-     * @param isKernel
-     *            - a flag for indicating kernel or UST.
-     * @param monitor
-     *            - a progress monitor
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    void disableEvent(String sessionName, String channelName,
-            List<String> eventNames, boolean isKernel, IProgressMonitor monitor)
-            throws ExecutionException;
-
-    /**
-     * Gets all available context names to be added to channels/events.
-     *
-     * @param monitor
-     *            The progress monitor
-     * @return the list of available contexts
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    @NonNull List<String> getContextList(IProgressMonitor monitor)
-            throws ExecutionException;
-
-    /**
-     * Add contexts to given channels and or events
-     *
-     * @param sessionName
-     *            - a session name
-     * @param channelName
-     *            - a channel name (null for all channels)
-     * @param eventName
-     *            - a event name (null for all events)
-     * @param isKernel
-     *            - a flag for indicating kernel or UST.
-     * @param contexts
-     *            - a list of name of contexts to add
-     * @param monitor
-     *            - a progress monitor
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    void addContexts(String sessionName, String channelName,
-            String eventName, boolean isKernel, List<String> contexts,
-            IProgressMonitor monitor) throws ExecutionException;
-
-    /**
-     * Executes calibrate command to quantify LTTng overhead.
-     *
-     * @param isKernel
-     *            - a flag for indicating kernel or UST.
-     * @param monitor
-     *            - a progress monitor
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    void calibrate(boolean isKernel, IProgressMonitor monitor)
-            throws ExecutionException;
-
-    /**
-     * Records a snapshot.
-     *
-     * @param sessionName
-     *            - a session name
-     * @param monitor
-     *            - a progress monitor
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    void recordSnapshot(String sessionName, IProgressMonitor monitor)
-            throws ExecutionException;
-
-    /**
-     * Executes a list of commands
-     *
-     * @param monitor
-     *      - a progress monitor
-     * @param commands
-     *      - array of commands
-     * @throws ExecutionException
-     *      If a command fails
-     */
-    void runCommands(IProgressMonitor monitor, List<String> commands)
-            throws ExecutionException;
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/service/LTTngControlService.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/service/LTTngControlService.java
deleted file mode 100644 (file)
index ba3f323..0000000
+++ /dev/null
@@ -1,1538 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2015 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
- *   Simon Delisle - Updated for support of LTTng Tools 2.2
- *   Marc-Andre Laperle - Support for creating a live session
- *   Markus Schorn - Bug 448058: Use org.eclipse.remote in favor of RSE
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.service;
-
-import static org.eclipse.tracecompass.common.core.NonNullUtils.checkNotNull;
-import static org.eclipse.tracecompass.common.core.NonNullUtils.nullToEmptyString;
-
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.Iterator;
-import java.util.List;
-import java.util.regex.Matcher;
-import java.util.regex.Pattern;
-
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.NullProgressMonitor;
-import org.eclipse.jdt.annotation.NonNull;
-import org.eclipse.jdt.annotation.Nullable;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IBaseEventInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IChannelInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IDomainInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IEventInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IFieldInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IProbeEventInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISessionInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISnapshotInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IUstProviderInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.LogLevelType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEventType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.BaseEventInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.BufferType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.ChannelInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.DomainInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.EventInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.FieldInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.ProbeEventInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.SessionInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.SnapshotInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.UstProviderInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.logging.ControlCommandLogger;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.preferences.ControlPreferences;
-import org.eclipse.tracecompass.tmf.remote.core.shell.ICommandInput;
-import org.eclipse.tracecompass.tmf.remote.core.shell.ICommandResult;
-import org.eclipse.tracecompass.tmf.remote.core.shell.ICommandShell;
-
-/**
- * <p>
- * Service for sending LTTng trace control commands to remote host.
- * </p>
- *
- * @author Bernd Hufmann
- */
-public class LTTngControlService implements ILttngControlService {
-
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-    /**
-     * The command shell implementation
-     */
-    private final @NonNull ICommandShell fCommandShell;
-
-    /**
-     * The version string.
-     */
-    private @NonNull LttngVersion fVersion = LttngVersion.NULL_VERSION;
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-
-    /**
-     * Constructor
-     *
-     * @param shell
-     *            - the command shell implementation to use
-     */
-    public LTTngControlService(@NonNull ICommandShell shell) {
-        fCommandShell = shell;
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    @Override
-    public String getVersionString() {
-        return nullToEmptyString(fVersion.toString());
-    }
-
-    @Override
-    public LttngVersion getVersion() {
-        return fVersion;
-    }
-
-    /**
-     * Sets the version of the LTTng 2.0 control service.
-     *
-     * @param version
-     *            - a version to set
-     */
-    public void setVersion(@Nullable String version) {
-        if (version != null) {
-            fVersion = new LttngVersion(version);
-        }
-    }
-
-    /**
-     * Sets the version of the LTTng 2.x control service.
-     *
-     * @param version
-     *            - a version to set
-     */
-    public void setVersion(LttngVersion version) {
-        if (version != null) {
-            fVersion = version;
-        }
-    }
-
-    @Override
-    public boolean isVersionSupported(String version) {
-        LttngVersion tmp = new LttngVersion(version);
-        return (fVersion.compareTo(tmp) >= 0) ? true : false;
-    }
-
-    /**
-     * Returns the command shell implementation.
-     *
-     * @return the command shell implementation
-     */
-    protected ICommandShell getCommandShell() {
-        return fCommandShell;
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    @Override
-    public List<String> getSessionNames(IProgressMonitor monitor) throws ExecutionException {
-        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_LIST);
-
-        ICommandResult result = executeCommand(command, monitor);
-
-        // Output:
-        // Available tracing sessions:
-        // 1) mysession1 (/home/user/lttng-traces/mysession1-20120123-083928)
-        // [inactive]
-        // 2) mysession (/home/user/lttng-traces/mysession-20120123-083318)
-        // [inactive]
-        //
-        // Use lttng list <session_name> for more details
-
-        ArrayList<String> retArray = new ArrayList<>();
-        for (String line : result.getOutput()) {
-            Matcher matcher = LTTngControlServiceConstants.SESSION_PATTERN.matcher(line);
-            if (matcher.matches()) {
-                retArray.add(matcher.group(2).trim());
-            }
-        }
-        return retArray;
-    }
-
-    /**
-     * Check if there is a pattern to be ignored into a sequence of string
-     *
-     * @param input
-     *            an input list of Strings
-     * @param pattern
-     *            the pattern to search for
-     * @return if the pattern exist in the array of string
-     */
-    protected boolean ignoredPattern(List<String> input, Pattern pattern) {
-        for (String line : input) {
-            Matcher matcher = pattern.matcher(line);
-            if (matcher.matches()) {
-                return true;
-            }
-        }
-        return false;
-    }
-
-    @Override
-    public ISessionInfo getSession(String sessionName, IProgressMonitor monitor) throws ExecutionException {
-        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_LIST, sessionName);
-        ICommandResult result = executeCommand(command, monitor);
-
-        int index = 0;
-
-        // Output:
-        // Tracing session mysession2: [inactive]
-        // Trace path: /home/eedbhu/lttng-traces/mysession2-20120123-110330
-        ISessionInfo sessionInfo = new SessionInfo(sessionName);
-
-        while (index < result.getOutput().size()) {
-            // Tracing session mysession2: [inactive]
-            // Trace path: /home/eedbhu/lttng-traces/mysession2-20120123-110330
-            //
-            // === Domain: Kernel ===
-            //
-            String line = result.getOutput().get(index);
-            Matcher matcher = LTTngControlServiceConstants.TRACE_SESSION_PATTERN.matcher(line);
-            if (matcher.matches()) {
-                sessionInfo.setSessionState(matcher.group(2));
-                index++;
-                continue;
-            }
-
-            matcher = LTTngControlServiceConstants.TRACE_SNAPSHOT_SESSION_PATTERN.matcher(line);
-            if (matcher.matches()) {
-                sessionInfo.setSessionState(matcher.group(2));
-                // real name will be set later
-                ISnapshotInfo snapshotInfo = new SnapshotInfo(""); //$NON-NLS-1$
-                sessionInfo.setSnapshotInfo(snapshotInfo);
-                index++;
-                continue;
-            }
-
-            if (!sessionInfo.isSnapshotSession()) {
-                matcher = LTTngControlServiceConstants.TRACE_NETWORK_PATH_PATTERN.matcher(line);
-                if (matcher.matches()) {
-                    sessionInfo.setStreamedTrace(true);
-                }
-
-                matcher = LTTngControlServiceConstants.TRACE_SESSION_PATH_PATTERN.matcher(line);
-                if (matcher.matches()) {
-                    sessionInfo.setSessionPath(matcher.group(1).trim());
-                    index++;
-                    continue;
-                }
-            }
-
-            matcher = LTTngControlServiceConstants.DOMAIN_KERNEL_PATTERN.matcher(line);
-            if (matcher.matches()) {
-                // Create Domain
-                IDomainInfo domainInfo = new DomainInfo(Messages.TraceControl_KernelDomainDisplayName);
-
-                // set kernel flag
-                domainInfo.setIsKernel(true);
-
-                // in domain kernel
-                ArrayList<IChannelInfo> channels = new ArrayList<>();
-                index = parseDomain(result.getOutput(), index, channels, domainInfo);
-
-                if (channels.size() > 0) {
-                    // add domain
-                    sessionInfo.addDomain(domainInfo);
-
-                    // set channels
-                    domainInfo.setChannels(channels);
-                }
-                continue;
-            }
-
-            matcher = LTTngControlServiceConstants.DOMAIN_UST_GLOBAL_PATTERN.matcher(line);
-            if (matcher.matches()) {
-                IDomainInfo domainInfo = new DomainInfo(Messages.TraceControl_UstGlobalDomainDisplayName);
-
-                // set kernel flag
-                domainInfo.setIsKernel(false);
-
-                // in domain UST
-                ArrayList<IChannelInfo> channels = new ArrayList<>();
-                index = parseDomain(result.getOutput(), index, channels, domainInfo);
-
-                if (channels.size() > 0) {
-                    // add domain
-                    sessionInfo.addDomain(domainInfo);
-
-                    // set channels
-                    domainInfo.setChannels(channels);
-                }
-                continue;
-            }
-            matcher = LTTngControlServiceConstants.LIST_LIVE_TIMER_INTERVAL_PATTERN.matcher(line);
-            if (matcher.matches()) {
-                long liveDelay = Long.parseLong(matcher.group(1));
-                if ((liveDelay > 0) && (liveDelay <= LTTngControlServiceConstants.MAX_LIVE_TIMER_INTERVAL)) {
-                    sessionInfo.setLive(true);
-                    sessionInfo.setLiveUrl(SessionInfo.DEFAULT_LIVE_NETWORK_URL);
-                    sessionInfo.setLivePort(SessionInfo.DEFAULT_LIVE_PORT);
-                    sessionInfo.setLiveDelay(liveDelay);
-                }
-                index++;
-                continue;
-            }
-
-            index++;
-        }
-
-        if (sessionInfo.isSnapshotSession()) {
-            ISnapshotInfo snapshot = getSnapshotInfo(sessionName, monitor);
-            sessionInfo.setSnapshotInfo(snapshot);
-        }
-
-        return sessionInfo;
-    }
-
-    @Override
-    public ISnapshotInfo getSnapshotInfo(String sessionName, IProgressMonitor monitor) throws ExecutionException {
-        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_SNAPSHOT, LTTngControlServiceConstants.COMMAND_LIST_SNAPSHOT_OUTPUT, LTTngControlServiceConstants.OPTION_SESSION, sessionName);
-        ICommandResult result = executeCommand(command, monitor);
-
-        int index = 0;
-
-        // Output:
-        // [1] snapshot-1: /home/user/lttng-traces/my-20130909-114431
-        // or
-        // [3] snapshot-3: net4://172.0.0.1/
-        ISnapshotInfo snapshotInfo = new SnapshotInfo(""); //$NON-NLS-1$
-
-        while (index < result.getOutput().size()) {
-            String line = result.getOutput().get(index);
-            Matcher matcher = LTTngControlServiceConstants.LIST_SNAPSHOT_OUTPUT_PATTERN.matcher(line);
-            if (matcher.matches()) {
-                snapshotInfo.setId(Integer.valueOf(matcher.group(1)));
-                snapshotInfo.setName(matcher.group(2));
-                snapshotInfo.setSnapshotPath(matcher.group(3));
-
-                Matcher matcher2 = LTTngControlServiceConstants.SNAPSHOT_NETWORK_PATH_PATTERN.matcher(snapshotInfo.getSnapshotPath());
-                if (matcher2.matches()) {
-                    snapshotInfo.setStreamedSnapshot(true);
-                }
-
-                index++;
-                break;
-            }
-            index++;
-        }
-
-        return snapshotInfo;
-    }
-
-    @Override
-    public List<IBaseEventInfo> getKernelProvider(IProgressMonitor monitor) throws ExecutionException {
-        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_LIST, LTTngControlServiceConstants.OPTION_KERNEL);
-        ICommandResult result = executeCommand(command, monitor, false);
-
-        List<IBaseEventInfo> events = new ArrayList<>();
-
-        // Ignore the following 2 cases:
-        // Spawning a session daemon
-        // Error: Unable to list kernel events
-        // or:
-        // Error: Unable to list kernel events
-        //
-        if (ignoredPattern(result.getErrorOutput(), LTTngControlServiceConstants.LIST_KERNEL_NO_KERNEL_PROVIDER_PATTERN)) {
-            return events;
-        }
-
-        if (isError(result)) {
-            throw new ExecutionException(Messages.TraceControl_CommandError + " " + command.toString() + "\n" + result.toString()); //$NON-NLS-1$ //$NON-NLS-2$
-        }
-
-        // Kernel events:
-        // -------------
-        // sched_kthread_stop (type: tracepoint)
-        getProviderEventInfo(result.getOutput(), 0, events);
-        return events;
-    }
-
-    @Override
-    public List<IUstProviderInfo> getUstProvider() throws ExecutionException {
-        return getUstProvider(new NullProgressMonitor());
-    }
-
-    @Override
-    public List<IUstProviderInfo> getUstProvider(IProgressMonitor monitor) throws ExecutionException {
-        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_LIST, LTTngControlServiceConstants.OPTION_UST);
-
-        if (isVersionSupported("2.1.0")) { //$NON-NLS-1$
-            command.add(LTTngControlServiceConstants.OPTION_FIELDS);
-        }
-
-        ICommandResult result = executeCommand(command, monitor, false);
-        List<IUstProviderInfo> allProviders = new ArrayList<>();
-
-        // Workaround for versions 2.0.x which causes a segmentation fault for
-        // this command
-        // if LTTng Tools is compiled without UST support.
-        if (!isVersionSupported("2.1.0") && (result.getResult() != 0)) { //$NON-NLS-1$
-            return allProviders;
-        }
-
-        // Ignore the following 2 cases:
-        // Spawning a session daemon
-        // Error: Unable to list UST events: Listing UST events failed
-        // or:
-        // Error: Unable to list UST events: Listing UST events failed
-        //
-        if (ignoredPattern(result.getErrorOutput(), LTTngControlServiceConstants.LIST_UST_NO_UST_PROVIDER_PATTERN)) {
-            return allProviders;
-        }
-
-        if (isError(result)) {
-            throw new ExecutionException(Messages.TraceControl_CommandError + " " + command.toString() + "\n" + result.toString()); //$NON-NLS-1$ //$NON-NLS-2$
-        }
-
-        // Note that field print-outs exists for version >= 2.1.0
-        //
-        // UST events:
-        // -------------
-        //
-        // PID: 3635 - Name:
-        // /home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello
-        // ust_tests_hello:tptest_sighandler (loglevel: TRACE_EMERG0) (type:
-        // tracepoint)
-        // ust_tests_hello:tptest (loglevel: TRACE_EMERG0) (type: tracepoint)
-        // field: doublefield (float)
-        // field: floatfield (float)
-        // field: stringfield (string)
-        //
-        // PID: 6459 - Name:
-        // /home/user/git/lttng-ust/tests/hello.cxx/.libs/lt-hello
-        // ust_tests_hello:tptest_sighandler (loglevel: TRACE_EMERG0) (type:
-        // tracepoint)
-        // ust_tests_hello:tptest (loglevel: TRACE_EMERG0) (type: tracepoint)
-        // field: doublefield (float)
-        // field: floatfield (float)
-        // field: stringfield (string)
-
-        IUstProviderInfo provider = null;
-
-        int index = 0;
-        while (index < result.getOutput().size()) {
-            String line = result.getOutput().get(index);
-            Matcher matcher = LTTngControlServiceConstants.UST_PROVIDER_PATTERN.matcher(line);
-            if (matcher.matches()) {
-                provider = new UstProviderInfo(matcher.group(2).trim());
-                provider.setPid(Integer.valueOf(matcher.group(1).trim()));
-                List<IBaseEventInfo> events = new ArrayList<>();
-                index = getProviderEventInfo(result.getOutput(), ++index, events);
-                provider.setEvents(events);
-                allProviders.add(provider);
-            } else {
-                index++;
-            }
-        }
-        return allProviders;
-    }
-
-    @Override
-    public ISessionInfo createSession(ISessionInfo sessionInfo, IProgressMonitor monitor) throws ExecutionException {
-        if (sessionInfo.isStreamedTrace()) {
-            return createStreamedSession(sessionInfo, monitor);
-        }
-
-        ICommandInput command = prepareSessionCreationCommand(sessionInfo);
-
-        ICommandResult result = executeCommand(command, monitor);
-
-        // Session myssession2 created.
-        // Traces will be written in
-        // /home/user/lttng-traces/myssession2-20120209-095418
-        List<String> output = result.getOutput();
-
-        // Get and session name and path
-        String name = null;
-        String path = null;
-
-        for (String line : output) {
-            Matcher nameMatcher = LTTngControlServiceConstants.CREATE_SESSION_NAME_PATTERN.matcher(line);
-            Matcher pathMatcher = LTTngControlServiceConstants.CREATE_SESSION_PATH_PATTERN.matcher(line);
-            if (nameMatcher.matches()) {
-                name = String.valueOf(nameMatcher.group(1).trim());
-            } else if (pathMatcher.matches()) {
-                path = String.valueOf(pathMatcher.group(1).trim());
-            }
-        }
-
-        // Verify session name
-        if ((name == null) || (!"".equals(sessionInfo.getName()) && !name.equals(sessionInfo.getName()))) { //$NON-NLS-1$
-            // Unexpected name returned
-            throw new ExecutionException(Messages.TraceControl_CommandError + " " + command.toString() + "\n" + //$NON-NLS-1$ //$NON-NLS-2$
-                    Messages.TraceControl_UnexpectedNameError + ": " + name); //$NON-NLS-1$
-        }
-
-        sessionInfo.setName(name);
-        // Verify session path
-        if (!sessionInfo.isSnapshotSession() &&
-                ((path == null) || ((sessionInfo.getSessionPath() != null) && (!path.contains(sessionInfo.getSessionPath()))))) {
-            // Unexpected path
-            throw new ExecutionException(Messages.TraceControl_CommandError + " " + command.toString() + "\n" + //$NON-NLS-1$ //$NON-NLS-2$
-                    Messages.TraceControl_UnexpectedPathError + ": " + name); //$NON-NLS-1$
-        }
-
-        if (sessionInfo.isSnapshotSession()) {
-            // Make it a snapshot session - content of snapshot info need to
-            // set afterwards using getSession() or getSnapshotInfo()
-            sessionInfo.setSnapshotInfo(new SnapshotInfo("")); //$NON-NLS-1$
-        } else {
-            sessionInfo.setSessionPath(path);
-        }
-
-        return sessionInfo;
-
-    }
-
-    /**
-     * Basic generation of command for session creation
-     *
-     * @param sessionInfo
-     *            the session to create
-     * @return the basic command for command creation
-     */
-    protected @NonNull ICommandInput prepareSessionCreationCommand(ISessionInfo sessionInfo) {
-        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_CREATE_SESSION);
-        if (!sessionInfo.getName().isEmpty()) {
-            command.add(sessionInfo.getName());
-        }
-
-        String newPath = sessionInfo.getSessionPath();
-        if (newPath != null && !"".equals(newPath)) { //$NON-NLS-1$
-            command.add(LTTngControlServiceConstants.OPTION_OUTPUT_PATH);
-            command.add(newPath);
-        }
-
-        if (sessionInfo.isSnapshotSession()) {
-            command.add(LTTngControlServiceConstants.OPTION_SNAPSHOT);
-        }
-        return command;
-    }
-
-    private @NonNull ISessionInfo createStreamedSession(ISessionInfo sessionInfo, IProgressMonitor monitor) throws ExecutionException {
-
-        ICommandInput command = prepareStreamedSessionCreationCommand(sessionInfo);
-
-        ICommandResult result = executeCommand(command, monitor);
-
-        // Verify output
-        List<String> output = result.getOutput();
-
-        // Get and session name and path
-        String name = null;
-        String path = null;
-
-        for (String line : output) {
-            Matcher nameMatcher = LTTngControlServiceConstants.CREATE_SESSION_NAME_PATTERN.matcher(line);
-            Matcher pathMatcher = LTTngControlServiceConstants.CREATE_SESSION_PATH_PATTERN.matcher(line);
-
-            if (nameMatcher.matches()) {
-                name = String.valueOf(nameMatcher.group(1).trim());
-            } else if (pathMatcher.matches() && (sessionInfo.getNetworkUrl() != null)) {
-                path = String.valueOf(pathMatcher.group(1).trim());
-            }
-        }
-
-        // Verify session name
-        if ((name == null) || (!"".equals(sessionInfo.getName()) && !name.equals(sessionInfo.getName()))) { //$NON-NLS-1$
-            // Unexpected name returned
-            throw new ExecutionException(Messages.TraceControl_CommandError + " " + command.toString() + "\n" + //$NON-NLS-1$ //$NON-NLS-2$
-                    Messages.TraceControl_UnexpectedNameError + ": " + name); //$NON-NLS-1$
-        }
-
-        sessionInfo.setName(name);
-
-        sessionInfo.setStreamedTrace(true);
-
-        // Verify session path
-        if (sessionInfo.getNetworkUrl() != null) {
-            if (!sessionInfo.isSnapshotSession() && (path == null)) {
-                // Unexpected path
-                throw new ExecutionException(Messages.TraceControl_CommandError + " " + command.toString() + "\n" + //$NON-NLS-1$ //$NON-NLS-2$
-                        Messages.TraceControl_UnexpectedPathError + ": " + name); //$NON-NLS-1$
-            }
-
-            if (sessionInfo.isSnapshotSession()) {
-                sessionInfo.setStreamedTrace(false);
-            } else {
-                sessionInfo.setSessionPath(path);
-                // Check file protocol
-                Matcher matcher = LTTngControlServiceConstants.TRACE_FILE_PROTOCOL_PATTERN.matcher(path);
-                if (matcher.matches()) {
-                    sessionInfo.setStreamedTrace(false);
-                }
-            }
-        }
-
-        // When using controlUrl and dataUrl the full session path is not known
-        // yet and will be set later on when listing the session
-
-        return sessionInfo;
-    }
-
-    /**
-     * Basic generation of command for streamed session creation
-     *
-     * @param sessionInfo
-     *            the session to create
-     * @return the basic command for command creation
-     */
-     protected @NonNull ICommandInput prepareStreamedSessionCreationCommand(ISessionInfo sessionInfo) {
-        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_CREATE_SESSION);
-        if (!sessionInfo.getName().isEmpty()) {
-            command.add(sessionInfo.getName());
-        }
-
-        if (sessionInfo.isSnapshotSession()) {
-            command.add(LTTngControlServiceConstants.OPTION_SNAPSHOT);
-        } else if (sessionInfo.isLive()) {
-            command.add(LTTngControlServiceConstants.OPTION_LIVE);
-            if (sessionInfo.getLiveDelay() != LTTngControlServiceConstants.UNUSED_VALUE) {
-                command.add(String.valueOf(sessionInfo.getLiveDelay()));
-            }
-        }
-
-        if (sessionInfo.getNetworkUrl() != null) {
-            command.add(LTTngControlServiceConstants.OPTION_NETWORK_URL);
-            command.add(sessionInfo.getNetworkUrl());
-        } else {
-            command.add(LTTngControlServiceConstants.OPTION_CONTROL_URL);
-            command.add(sessionInfo.getControlUrl());
-
-            command.add(LTTngControlServiceConstants.OPTION_DATA_URL);
-            command.add(sessionInfo.getDataUrl());
-        }
-        return command;
-    }
-
-    @Override
-    public void destroySession(String sessionName, IProgressMonitor monitor) throws ExecutionException {
-
-        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_DESTROY_SESSION, sessionName);
-
-        ICommandResult result = executeCommand(command, monitor, false);
-        boolean isError = isError(result);
-        if (isError && !ignoredPattern(result.getErrorOutput(), LTTngControlServiceConstants.SESSION_NOT_FOUND_ERROR_PATTERN)) {
-            throw new ExecutionException(Messages.TraceControl_CommandError + " " + command.toString() + "\n" + result.toString()); //$NON-NLS-1$ //$NON-NLS-2$
-        }
-
-        // Session <sessionName> destroyed
-    }
-
-    @Override
-    public void startSession(String sessionName, IProgressMonitor monitor) throws ExecutionException {
-
-        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_START_SESSION, sessionName);
-
-        executeCommand(command, monitor);
-
-        // Session <sessionName> started
-    }
-
-    @Override
-    public void stopSession(String sessionName, IProgressMonitor monitor) throws ExecutionException {
-        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_STOP_SESSION, sessionName);
-
-        executeCommand(command, monitor);
-
-        // Session <sessionName> stopped
-
-    }
-
-    @Override
-    public void enableChannels(String sessionName, List<String> channelNames, boolean isKernel, IChannelInfo info, IProgressMonitor monitor) throws ExecutionException {
-
-        // no channels to enable
-        if (channelNames.isEmpty()) {
-            return;
-        }
-
-        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_ENABLE_CHANNEL);
-
-        command.add(toCsv(channelNames));
-
-        if (isKernel) {
-            command.add(LTTngControlServiceConstants.OPTION_KERNEL);
-        } else {
-            command.add(LTTngControlServiceConstants.OPTION_UST);
-        }
-
-        command.add(LTTngControlServiceConstants.OPTION_SESSION);
-        command.add(sessionName);
-
-        if (info != null) {
-            // --discard Discard event when buffers are full (default)
-
-            // --overwrite Flight recorder mode
-            if (info.isOverwriteMode()) {
-                command.add(LTTngControlServiceConstants.OPTION_OVERWRITE);
-            }
-            // --subbuf-size SIZE Subbuffer size in bytes
-            // (default: 4096, kernel default: 262144)
-            if (info.getSubBufferSize() != LTTngControlServiceConstants.UNUSED_VALUE) {
-                command.add(LTTngControlServiceConstants.OPTION_SUB_BUFFER_SIZE);
-                command.add(String.valueOf(info.getSubBufferSize()));
-            }
-
-            // --num-subbuf NUM Number of subbufers
-            if (info.getNumberOfSubBuffers() != LTTngControlServiceConstants.UNUSED_VALUE) {
-                command.add(LTTngControlServiceConstants.OPTION_NUM_SUB_BUFFERS);
-                command.add(String.valueOf(info.getNumberOfSubBuffers()));
-            }
-
-            // --switch-timer USEC Switch timer interval in usec
-            if (info.getSwitchTimer() != LTTngControlServiceConstants.UNUSED_VALUE) {
-                command.add(LTTngControlServiceConstants.OPTION_SWITCH_TIMER);
-                command.add(String.valueOf(info.getSwitchTimer()));
-            }
-
-            // --read-timer USEC Read timer interval in usec
-            if (info.getReadTimer() != LTTngControlServiceConstants.UNUSED_VALUE) {
-                command.add(LTTngControlServiceConstants.OPTION_READ_TIMER);
-                command.add(String.valueOf(info.getReadTimer()));
-            }
-
-            if (isVersionSupported("2.2.0")) { //$NON-NLS-1$
-                // --buffers-uid Every application sharing the same UID use the
-                // same buffers --buffers-pid Buffers are allocated per PID
-                if (!isKernel) {
-                    if (info.getBufferType() == BufferType.BUFFER_PER_PID) {
-                        command.add(LTTngControlServiceConstants.OPTION_PER_PID_BUFFERS);
-
-                    } else if (info.getBufferType() == BufferType.BUFFER_PER_UID) {
-                        command.add(LTTngControlServiceConstants.OPTION_PER_UID_BUFFERS);
-                    }
-                }
-
-                // -C SIZE Maximum size of trace files in bytes
-                if (info.getMaxSizeTraceFiles() != LTTngControlServiceConstants.UNUSED_VALUE) {
-                    command.add(LTTngControlServiceConstants.OPTION_MAX_SIZE_TRACE_FILES);
-                    command.add(String.valueOf(info.getMaxSizeTraceFiles()));
-                }
-
-                // -W NUM Maximum number of trace files
-                if (info.getMaxNumberTraceFiles() != LTTngControlServiceConstants.UNUSED_VALUE) {
-                    command.add(LTTngControlServiceConstants.OPTION_MAX_TRACE_FILES);
-                    command.add(String.valueOf(info.getMaxNumberTraceFiles()));
-                }
-            }
-        }
-
-        executeCommand(command, monitor);
-
-    }
-
-    @Override
-    public void disableChannels(String sessionName, List<String> channelNames, boolean isKernel, IProgressMonitor monitor) throws ExecutionException {
-
-        // no channels to enable
-        if (channelNames.isEmpty()) {
-            return;
-        }
-
-        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_DISABLE_CHANNEL);
-
-        command.add(toCsv(channelNames));
-
-        if (isKernel) {
-            command.add(LTTngControlServiceConstants.OPTION_KERNEL);
-        } else {
-            command.add(LTTngControlServiceConstants.OPTION_UST);
-        }
-
-        command.add(LTTngControlServiceConstants.OPTION_SESSION);
-        command.add(sessionName);
-
-        executeCommand(command, monitor);
-    }
-
-    @Override
-    public void enableEvents(String sessionName, String channelName, List<String> eventNames, boolean isKernel, String filterExpression, IProgressMonitor monitor) throws ExecutionException {
-
-        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_ENABLE_EVENT);
-
-        if (eventNames == null || eventNames.isEmpty()) {
-            command.add(LTTngControlServiceConstants.OPTION_ALL);
-        } else {
-            command.add(toCsv(eventNames));
-        }
-
-        if (isKernel) {
-            command.add(LTTngControlServiceConstants.OPTION_KERNEL);
-        } else {
-            command.add(LTTngControlServiceConstants.OPTION_UST);
-        }
-
-        command.add(LTTngControlServiceConstants.OPTION_SESSION);
-        command.add(sessionName);
-
-        if (channelName != null) {
-            command.add(LTTngControlServiceConstants.OPTION_CHANNEL);
-            command.add(channelName);
-        }
-
-        command.add(LTTngControlServiceConstants.OPTION_TRACEPOINT);
-
-        if (filterExpression != null) {
-            command.add(LTTngControlServiceConstants.OPTION_FILTER);
-            command.add(filterExpression);
-        }
-
-        executeCommand(command, monitor);
-
-    }
-
-    @Override
-    public void enableSyscalls(String sessionName, String channelName, IProgressMonitor monitor) throws ExecutionException {
-
-        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_ENABLE_EVENT);
-
-        command.add(LTTngControlServiceConstants.OPTION_ALL);
-        command.add(LTTngControlServiceConstants.OPTION_KERNEL);
-
-
-        command.add(LTTngControlServiceConstants.OPTION_SESSION);
-        command.add(sessionName);
-
-        if (channelName != null) {
-            command.add(LTTngControlServiceConstants.OPTION_CHANNEL);
-            command.add(channelName);
-        }
-
-        command.add(LTTngControlServiceConstants.OPTION_SYSCALL);
-
-        executeCommand(command, monitor);
-    }
-
-    @Override
-    public void enableProbe(String sessionName, String channelName, String eventName, boolean isFunction, String probe, IProgressMonitor monitor) throws ExecutionException {
-        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_ENABLE_EVENT);
-
-        command.add(eventName);
-        command.add(LTTngControlServiceConstants.OPTION_KERNEL);
-
-        command.add(LTTngControlServiceConstants.OPTION_SESSION);
-        command.add(sessionName);
-
-        if (channelName != null) {
-            command.add(LTTngControlServiceConstants.OPTION_CHANNEL);
-            command.add(channelName);
-        }
-        if (isFunction) {
-            command.add(LTTngControlServiceConstants.OPTION_FUNCTION_PROBE);
-        } else {
-            command.add(LTTngControlServiceConstants.OPTION_PROBE);
-        }
-
-        command.add(probe);
-
-        executeCommand(command, monitor);
-    }
-
-    @Override
-    public void enableLogLevel(String sessionName, String channelName, String eventName, LogLevelType logLevelType, TraceLogLevel level, String filterExpression, IProgressMonitor monitor) throws ExecutionException {
-        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_ENABLE_EVENT);
-
-        command.add(eventName);
-        command.add(LTTngControlServiceConstants.OPTION_UST);
-
-        command.add(LTTngControlServiceConstants.OPTION_SESSION);
-        command.add(sessionName);
-
-        if (channelName != null) {
-            command.add(LTTngControlServiceConstants.OPTION_CHANNEL);
-            command.add(channelName);
-        }
-
-        if (logLevelType == LogLevelType.LOGLEVEL) {
-            command.add(LTTngControlServiceConstants.OPTION_LOGLEVEL);
-        } else if (logLevelType == LogLevelType.LOGLEVEL_ONLY) {
-            command.add(LTTngControlServiceConstants.OPTION_LOGLEVEL_ONLY);
-
-        } else {
-            return;
-        }
-        command.add(level.getInName());
-
-        executeCommand(command, monitor);
-    }
-
-    @Override
-    public void disableEvent(String sessionName, String channelName, List<String> eventNames, boolean isKernel, IProgressMonitor monitor) throws ExecutionException {
-        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_DISABLE_EVENT);
-
-        if (eventNames == null) {
-            command.add(LTTngControlServiceConstants.OPTION_ALL);
-        } else {
-            // no events to disable
-            if (eventNames.isEmpty()) {
-                return;
-            }
-
-            StringBuffer eventNameParameter = new StringBuffer();
-            for (Iterator<String> iterator = eventNames.iterator(); iterator.hasNext();) {
-                String event = iterator.next();
-                eventNameParameter.append(event);
-                if (iterator.hasNext()) {
-                    eventNameParameter.append(',');
-                }
-            }
-            command.add(eventNameParameter.toString());
-        }
-
-        if (isKernel) {
-            command.add(LTTngControlServiceConstants.OPTION_KERNEL);
-        } else {
-            command.add(LTTngControlServiceConstants.OPTION_UST);
-        }
-
-        command.add(LTTngControlServiceConstants.OPTION_SESSION);
-        command.add(sessionName);
-
-        if (channelName != null) {
-            command.add(LTTngControlServiceConstants.OPTION_CHANNEL);
-            command.add(channelName);
-        }
-
-        executeCommand(command, monitor);
-    }
-
-    @Override
-    public List<String> getContextList(IProgressMonitor monitor) throws ExecutionException {
-
-        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_ADD_CONTEXT, LTTngControlServiceConstants.OPTION_HELP);
-
-        ICommandResult result = executeCommand(command, monitor);
-
-        List<String> output = result.getOutput();
-
-        List<String> contexts = new ArrayList<>(0);
-
-        int index = 0;
-        boolean inList = false;
-        while (index < output.size()) {
-            String line = output.get(index);
-
-            Matcher startMatcher = LTTngControlServiceConstants.ADD_CONTEXT_HELP_CONTEXTS_INTRO.matcher(line);
-            Matcher endMatcher = LTTngControlServiceConstants.ADD_CONTEXT_HELP_CONTEXTS_END_LINE.matcher(line);
-
-            if (startMatcher.matches()) {
-                inList = true;
-            } else if (endMatcher.matches()) {
-                break;
-            } else if (inList == true) {
-                String[] tmp = line.split(","); //$NON-NLS-1$
-                for (int i = 0; i < tmp.length; i++) {
-                    contexts.add(tmp[i].trim());
-                }
-            }
-            index++;
-        }
-        return contexts;
-    }
-
-    @Override
-    public void addContexts(String sessionName, String channelName, String eventName, boolean isKernel, List<String> contextNames, IProgressMonitor monitor) throws ExecutionException {
-        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_ADD_CONTEXT);
-
-        command.add(LTTngControlServiceConstants.OPTION_SESSION);
-        command.add(sessionName);
-
-        if (channelName != null) {
-            command.add(LTTngControlServiceConstants.OPTION_CHANNEL);
-            command.add(channelName);
-        }
-
-        if (eventName != null) {
-            command.add(LTTngControlServiceConstants.OPTION_EVENT);
-            command.add(eventName);
-        }
-
-        if (isKernel) {
-            command.add(LTTngControlServiceConstants.OPTION_KERNEL);
-        } else {
-            command.add(LTTngControlServiceConstants.OPTION_UST);
-        }
-
-        for (Iterator<String> iterator = contextNames.iterator(); iterator.hasNext();) {
-            String context = iterator.next();
-            command.add(LTTngControlServiceConstants.OPTION_CONTEXT_TYPE);
-            command.add(context);
-        }
-
-        executeCommand(command, monitor);
-
-    }
-
-    @Override
-    public void calibrate(boolean isKernel, IProgressMonitor monitor) throws ExecutionException {
-        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_CALIBRATE);
-
-        if (isKernel) {
-            command.add(LTTngControlServiceConstants.OPTION_KERNEL);
-        } else {
-            command.add(LTTngControlServiceConstants.OPTION_UST);
-        }
-
-        command.add(LTTngControlServiceConstants.OPTION_FUNCTION_PROBE);
-
-        executeCommand(command, monitor);
-    }
-
-    @Override
-    public void recordSnapshot(String sessionName, IProgressMonitor monitor)
-            throws ExecutionException {
-        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_SNAPSHOT, LTTngControlServiceConstants.COMMAND_RECORD_SNAPSHOT);
-
-        String newSessionName = sessionName;
-        command.add(LTTngControlServiceConstants.OPTION_SESSION);
-        command.add(newSessionName);
-
-        executeCommand(command, monitor);
-    }
-
-    @Override
-    public void runCommands(IProgressMonitor monitor, List<String> commandLines) throws ExecutionException {
-        for (String commandLine : commandLines) {
-            if (monitor.isCanceled()) {
-                return;
-            }
-
-            if (commandLine.isEmpty() || commandLine.startsWith("#")) { //$NON-NLS-1$
-                continue;
-            }
-            String[] args = commandLine.split("\\s+"); //$NON-NLS-1$
-            ICommandInput command = fCommandShell.createCommand();
-            command.addAll(checkNotNull(Arrays.asList(args)));
-            ICommandResult result = executeCommand(command, monitor);
-
-            if (isError(result)) {
-                throw new ExecutionException(Messages.TraceControl_CommandError + " " + command.toString() + "\n" + result.toString()); //$NON-NLS-1$ //$NON-NLS-2$
-            }
-        }
-    }
-
-    // ------------------------------------------------------------------------
-    // Helper methods
-    // ------------------------------------------------------------------------
-
-    /**
-     * Checks if command result is an error result.
-     *
-     * @param result
-     *            - the command result to check
-     * @return true if error else false
-     */
-    protected boolean isError(ICommandResult result) {
-        // Check return code and length of returned strings
-
-        if ((result.getResult()) != 0) {
-            return true;
-        }
-
-        // Look for error pattern
-        for (String line : result.getErrorOutput()) {
-            Matcher matcher = LTTngControlServiceConstants.ERROR_PATTERN.matcher(line);
-            if (matcher.matches()) {
-                return true;
-            }
-        }
-
-        return false;
-    }
-
-    /**
-     * Creates a comma separated string from list of names
-     * @param names
-     *          List of name to convert
-     * @return comma separated string
-     */
-    protected String toCsv(List<String> names) {
-        StringBuilder csvString = new StringBuilder();
-        for (Iterator<String> iterator = names.iterator(); iterator.hasNext();) {
-            String name = iterator.next();
-            csvString.append(name);
-            if (iterator.hasNext()) {
-                csvString.append(',');
-            }
-        }
-        return csvString.toString();
-    }
-
-    /**
-     * Parses the domain information.
-     *
-     * @param output
-     *            a command output list
-     * @param currentIndex
-     *            current index in command output list
-     * @param channels
-     *            list for returning channel information
-     * @param domainInfo
-     *            The domain information
-     * @return the new current index in command output list
-     */
-    protected int parseDomain(List<String> output, int currentIndex, List<IChannelInfo> channels, IDomainInfo domainInfo) {
-        int index = currentIndex;
-
-        // if kernel set the buffer type to shared
-        if (domainInfo.isKernel()) {
-            domainInfo.setBufferType(BufferType.BUFFER_SHARED);
-        }
-
-        // Channels:
-        // -------------
-        // - channnel1: [enabled]
-        //
-        // Attributes:
-        // overwrite mode: 0
-        // subbufers size: 262144
-        // number of subbufers: 4
-        // switch timer interval: 0
-        // read timer interval: 200
-        // output: splice()
-
-        while (index < output.size()) {
-            String line = output.get(index);
-
-            if (isVersionSupported("2.2.0")) { //$NON-NLS-1$
-                Matcher bufferTypeMatcher = LTTngControlServiceConstants.BUFFER_TYPE_PATTERN.matcher(line);
-                if (bufferTypeMatcher.matches()) {
-                    String bufferTypeString = getAttributeValue(line);
-                    if (BufferType.BUFFER_PER_PID.getInName().equals(bufferTypeString)) {
-                        domainInfo.setBufferType(BufferType.BUFFER_PER_PID);
-                    } else if (BufferType.BUFFER_PER_UID.getInName().equals(bufferTypeString)) {
-                        domainInfo.setBufferType(BufferType.BUFFER_PER_UID);
-                    } else {
-                        domainInfo.setBufferType(BufferType.BUFFER_TYPE_UNKNOWN);
-                    }
-                }
-            } else {
-                domainInfo.setBufferType(BufferType.BUFFER_TYPE_UNKNOWN);
-            }
-            Matcher outerMatcher = LTTngControlServiceConstants.CHANNELS_SECTION_PATTERN.matcher(line);
-            Matcher noKernelChannelMatcher = LTTngControlServiceConstants.DOMAIN_NO_KERNEL_CHANNEL_PATTERN.matcher(line);
-            Matcher noUstChannelMatcher = LTTngControlServiceConstants.DOMAIN_NO_UST_CHANNEL_PATTERN.matcher(line);
-            if (outerMatcher.matches()) {
-                IChannelInfo channelInfo = null;
-                while (index < output.size()) {
-                    String subLine = output.get(index);
-
-                    Matcher innerMatcher = LTTngControlServiceConstants.CHANNEL_PATTERN.matcher(subLine);
-                    if (innerMatcher.matches()) {
-                        channelInfo = new ChannelInfo(""); //$NON-NLS-1$
-                        // get channel name
-                        channelInfo.setName(innerMatcher.group(1));
-
-                        // get channel enablement
-                        channelInfo.setState(innerMatcher.group(2));
-
-                        // set BufferType
-                        channelInfo.setBufferType(domainInfo.getBufferType());
-
-                        // add channel
-                        channels.add(channelInfo);
-
-                    } else if (LTTngControlServiceConstants.OVERWRITE_MODE_ATTRIBUTE.matcher(subLine).matches()) {
-                        String value = getAttributeValue(subLine);
-                        if (channelInfo != null) {
-                            channelInfo.setOverwriteMode(!LTTngControlServiceConstants.OVERWRITE_MODE_ATTRIBUTE_FALSE.equals(value));
-                        }
-                    } else if (LTTngControlServiceConstants.SUBBUFFER_SIZE_ATTRIBUTE.matcher(subLine).matches()) {
-                        if (channelInfo != null) {
-                            channelInfo.setSubBufferSize(Long.valueOf(getAttributeValue(subLine)));
-                        }
-
-                    } else if (LTTngControlServiceConstants.NUM_SUBBUFFERS_ATTRIBUTE.matcher(subLine).matches()) {
-                        if (channelInfo != null) {
-                            channelInfo.setNumberOfSubBuffers(Integer.valueOf(getAttributeValue(subLine)));
-                        }
-
-                    } else if (LTTngControlServiceConstants.SWITCH_TIMER_ATTRIBUTE.matcher(subLine).matches()) {
-                        if (channelInfo != null) {
-                            channelInfo.setSwitchTimer(Long.valueOf(getAttributeValue(subLine)));
-                        }
-
-                    } else if (LTTngControlServiceConstants.READ_TIMER_ATTRIBUTE.matcher(subLine).matches()) {
-                        if (channelInfo != null) {
-                            channelInfo.setReadTimer(Long.valueOf(getAttributeValue(subLine)));
-                        }
-
-                    } else if (LTTngControlServiceConstants.OUTPUT_ATTRIBUTE.matcher(subLine).matches()) {
-                        if (channelInfo != null) {
-                            channelInfo.setOutputType(getAttributeValue(subLine));
-                        }
-
-                    } else if (LTTngControlServiceConstants.TRACE_FILE_COUNT_ATTRIBUTE.matcher(subLine).matches()) {
-                        if (channelInfo != null) {
-                            channelInfo.setMaxNumberTraceFiles(Integer.valueOf(getAttributeValue(subLine)));
-                        }
-
-                    } else if (LTTngControlServiceConstants.TRACE_FILE_SIZE_ATTRIBUTE.matcher(subLine).matches()) {
-                        if (channelInfo != null) {
-                            channelInfo.setMaxSizeTraceFiles(Long.valueOf(getAttributeValue(subLine)));
-                        }
-                    } else if (LTTngControlServiceConstants.EVENT_SECTION_PATTERN.matcher(subLine).matches()) {
-                        List<IEventInfo> events = new ArrayList<>();
-                        index = parseEvents(output, index, events);
-                        if (channelInfo != null) {
-                            channelInfo.setEvents(events);
-                        }
-                        // we want to stay at the current index to be able to
-                        // exit the domain
-                        continue;
-                    } else if (LTTngControlServiceConstants.DOMAIN_KERNEL_PATTERN.matcher(subLine).matches()) {
-                        return index;
-
-                    } else if (LTTngControlServiceConstants.DOMAIN_UST_GLOBAL_PATTERN.matcher(subLine).matches()) {
-                        return index;
-                    }
-                    index++;
-                }
-            } else if (noKernelChannelMatcher.matches() || noUstChannelMatcher.matches()) {
-                // domain indicates that no channels were found -> return
-                index++;
-                return index;
-            }
-            index++;
-        }
-        return index;
-    }
-
-    /**
-     * Parses the event information within a domain.
-     *
-     * @param output
-     *            a command output list
-     * @param currentIndex
-     *            current index in command output list
-     * @param events
-     *            list for returning event information
-     * @return the new current index in command output list
-     */
-    protected int parseEvents(List<String> output, int currentIndex, List<IEventInfo> events) {
-        int index = currentIndex;
-
-        while (index < output.size()) {
-            String line = output.get(index);
-            if (LTTngControlServiceConstants.CHANNEL_PATTERN.matcher(line).matches()) {
-                // end of channel
-                return index;
-            } else if (LTTngControlServiceConstants.DOMAIN_KERNEL_PATTERN.matcher(line).matches()) {
-                // end of domain
-                return index;
-            } else if (LTTngControlServiceConstants.DOMAIN_UST_GLOBAL_PATTERN.matcher(line).matches()) {
-                // end of domain
-                return index;
-            }
-
-            Matcher matcher = LTTngControlServiceConstants.EVENT_PATTERN.matcher(line);
-            Matcher matcher2 = LTTngControlServiceConstants.WILDCARD_EVENT_PATTERN.matcher(line);
-
-            if (matcher.matches()) {
-                IEventInfo eventInfo = new EventInfo(matcher.group(1).trim());
-                eventInfo.setLogLevelType(matcher.group(2).trim());
-                eventInfo.setLogLevel(matcher.group(3).trim());
-                eventInfo.setEventType(matcher.group(4).trim());
-                eventInfo.setState(matcher.group(5));
-                String filter = matcher.group(6);
-                if (filter != null) {
-                    // remove '[' and ']'
-                    filter = filter.substring(1, filter.length() - 1);
-                    eventInfo.setFilterExpression(filter);
-                }
-                events.add(eventInfo);
-                index++;
-            } else if (matcher2.matches()) {
-                IEventInfo eventInfo = new EventInfo(matcher2.group(1).trim());
-                eventInfo.setLogLevel(TraceLogLevel.LEVEL_UNKNOWN);
-                eventInfo.setEventType(matcher2.group(2).trim());
-                eventInfo.setState(matcher2.group(3));
-                String filter = matcher2.group(4);
-                if (filter != null) {
-                    // remove '[' and ']'
-                    filter = filter.substring(1, filter.length() - 1);
-                    eventInfo.setFilterExpression(filter);
-                }
-
-                if ((eventInfo.getEventType() == TraceEventType.PROBE) ||
-                        (eventInfo.getEventType() == TraceEventType.FUNCTION)) {
-                    IProbeEventInfo probeEvent = new ProbeEventInfo(eventInfo.getName());
-                    probeEvent.setLogLevel(eventInfo.getLogLevel());
-                    probeEvent.setEventType(eventInfo.getEventType());
-                    probeEvent.setState(eventInfo.getState());
-
-                    // Overwrite eventinfo
-                    eventInfo = probeEvent;
-
-                    // myevent2 (type: probe) [enabled]
-                    // addr: 0xc0101340
-                    // myevent0 (type: function) [enabled]
-                    // offset: 0x0
-                    // symbol: init_post
-                    index++;
-                    while (index < output.size()) {
-                        String probeLine = output.get(index);
-                        // parse probe
-                        Matcher addrMatcher = LTTngControlServiceConstants.PROBE_ADDRESS_PATTERN.matcher(probeLine);
-                        Matcher offsetMatcher = LTTngControlServiceConstants.PROBE_OFFSET_PATTERN.matcher(probeLine);
-                        Matcher symbolMatcher = LTTngControlServiceConstants.PROBE_SYMBOL_PATTERN.matcher(probeLine);
-                        if (addrMatcher.matches()) {
-                            String addr = addrMatcher.group(2).trim();
-                            probeEvent.setAddress(addr);
-                        } else if (offsetMatcher.matches()) {
-                            String offset = offsetMatcher.group(2).trim();
-                            probeEvent.setOffset(offset);
-                        } else if (symbolMatcher.matches()) {
-                            String symbol = symbolMatcher.group(2).trim();
-                            probeEvent.setSymbol(symbol);
-                        } else if ((LTTngControlServiceConstants.EVENT_PATTERN.matcher(probeLine).matches()) || (LTTngControlServiceConstants.WILDCARD_EVENT_PATTERN.matcher(probeLine).matches())) {
-                            break;
-                        } else if (LTTngControlServiceConstants.CHANNEL_PATTERN.matcher(probeLine).matches()) {
-                            break;
-                        } else if (LTTngControlServiceConstants.DOMAIN_KERNEL_PATTERN.matcher(probeLine).matches()) {
-                            // end of domain
-                            break;
-                        } else if (LTTngControlServiceConstants.DOMAIN_UST_GLOBAL_PATTERN.matcher(probeLine).matches()) {
-                            // end of domain
-                            break;
-                        }
-                        index++;
-                    }
-                    events.add(eventInfo);
-                } else {
-                    events.add(eventInfo);
-                    index++;
-                    continue;
-                }
-            } else {
-                index++;
-            }
-        }
-
-        return index;
-    }
-
-    /**
-     * Parses a line with attributes: <attribute Name>: <attribute value>
-     *
-     * @param line
-     *            - attribute line to parse
-     * @return the attribute value as string
-     */
-    protected String getAttributeValue(String line) {
-        String[] temp = line.split("\\: "); //$NON-NLS-1$
-        return temp[1];
-    }
-
-    /**
-     * Parses the event information within a provider.
-     *
-     * @param output
-     *            a command output list
-     * @param currentIndex
-     *            current index in command output list
-     * @param events
-     *            list for returning event information
-     * @return the new current index in command output list
-     */
-    protected int getProviderEventInfo(List<String> output, int currentIndex, List<IBaseEventInfo> events) {
-        int index = currentIndex;
-        IBaseEventInfo eventInfo = null;
-        while (index < output.size()) {
-            String line = output.get(index);
-            Matcher matcher = LTTngControlServiceConstants.PROVIDER_EVENT_PATTERN.matcher(line);
-            if (matcher.matches()) {
-                // sched_kthread_stop (loglevel: TRACE_EMERG0) (type:
-                // tracepoint)
-                eventInfo = new BaseEventInfo(matcher.group(1).trim());
-                eventInfo.setLogLevel(matcher.group(2).trim());
-                eventInfo.setEventType(matcher.group(3).trim());
-                events.add(eventInfo);
-                index++;
-            } else if (LTTngControlServiceConstants.EVENT_FIELD_PATTERN.matcher(line).matches()) {
-                if (eventInfo != null) {
-                    List<IFieldInfo> fields = new ArrayList<>();
-                    index = getFieldInfo(output, index, fields);
-                    eventInfo.setFields(fields);
-                } else {
-                    index++;
-                }
-            }
-            else if (LTTngControlServiceConstants.UST_PROVIDER_PATTERN.matcher(line).matches()) {
-                return index;
-            } else {
-                index++;
-            }
-        }
-        return index;
-    }
-
-    /**
-     * Parse a field's information.
-     *
-     * @param output
-     *            A command output list
-     * @param currentIndex
-     *            The current index in the command output list
-     * @param fields
-     *            List for returning the field information
-     * @return The new current index in the command output list
-     */
-    protected int getFieldInfo(List<String> output, int currentIndex, List<IFieldInfo> fields) {
-        int index = currentIndex;
-        IFieldInfo fieldInfo = null;
-        while (index < output.size()) {
-            String line = output.get(index);
-            Matcher matcher = LTTngControlServiceConstants.EVENT_FIELD_PATTERN.matcher(line);
-            if (matcher.matches()) {
-                // field: content (string)
-                fieldInfo = new FieldInfo(matcher.group(2).trim());
-                fieldInfo.setFieldType(matcher.group(3).trim());
-                fields.add(fieldInfo);
-            } else if (LTTngControlServiceConstants.PROVIDER_EVENT_PATTERN.matcher(line).matches()) {
-                return index;
-            } else if (LTTngControlServiceConstants.UST_PROVIDER_PATTERN.matcher(line).matches()) {
-                return index;
-            }
-            index++;
-        }
-        return index;
-    }
-
-    /**
-     * Creates a command input instance
-     *
-     * @param segments
-     *            array of string that makes up a command line
-     * @return {@link ICommandInput} instance
-     */
-    protected @NonNull ICommandInput createCommand(String... segments) {
-        ICommandInput command = fCommandShell.createCommand();
-        command.add(LTTngControlServiceConstants.CONTROL_COMMAND);
-        List<String> groupOption = getTracingGroupOption();
-        if (!groupOption.isEmpty()) {
-            command.addAll(groupOption);
-        }
-        String verboseOption = getVerboseOption();
-        if (!verboseOption.isEmpty()) {
-            command.add(verboseOption);
-        }
-        for (String string : segments) {
-            command.add(checkNotNull(string));
-        }
-        return command;
-    }
-
-    /**
-     * @return the tracing group option if configured in the preferences
-     */
-    protected @NonNull List<String> getTracingGroupOption() {
-        List<String> groupOption = new ArrayList<>();
-        if (!ControlPreferences.getInstance().isDefaultTracingGroup() && !ControlPreferences.getInstance().getTracingGroup().equals("")) { //$NON-NLS-1$
-            groupOption.add(LTTngControlServiceConstants.OPTION_TRACING_GROUP);
-            groupOption.add(ControlPreferences.getInstance().getTracingGroup());
-        }
-        return groupOption;
-    }
-
-    /**
-     * @return the verbose option as configured in the preferences
-     */
-    protected String getVerboseOption() {
-        if (ControlPreferences.getInstance().isLoggingEnabled()) {
-            String level = ControlPreferences.getInstance().getVerboseLevel();
-            if (ControlPreferences.TRACE_CONTROL_VERBOSE_LEVEL_VERBOSE.equals(level)) {
-                return LTTngControlServiceConstants.OPTION_VERBOSE;
-            }
-            if (ControlPreferences.TRACE_CONTROL_VERBOSE_LEVEL_V_VERBOSE.equals(level)) {
-                return LTTngControlServiceConstants.OPTION_VERY_VERBOSE;
-            }
-            if (ControlPreferences.TRACE_CONTROL_VERBOSE_LEVEL_V_V_VERBOSE.equals(level)) {
-                return LTTngControlServiceConstants.OPTION_VERY_VERY_VERBOSE;
-            }
-        }
-        return ""; //$NON-NLS-1$
-    }
-
-    /**
-     * Method that logs the command and command result if logging is enabled as
-     * well as forwards the command execution to the shell.
-     *
-     * @param command
-     *            - the command to execute
-     * @param monitor
-     *            - a progress monitor
-     * @return the command result
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    protected ICommandResult executeCommand(@NonNull ICommandInput command,
-            @Nullable IProgressMonitor monitor) throws ExecutionException {
-        return executeCommand(command, monitor, true);
-    }
-
-    /**
-     * Method that logs the command and command result if logging is enabled as
-     * well as forwards the command execution to the shell.
-     *
-     * @param command
-     *            - the command to execute
-     * @param monitor
-     *            - a progress monitor
-     * @param checkForError
-     *            - true to verify command result, else false
-     * @return the command result
-     * @throws ExecutionException
-     *             in case of error result
-     */
-    protected ICommandResult executeCommand(@NonNull ICommandInput command,
-            @Nullable IProgressMonitor monitor, boolean checkForError)
-            throws ExecutionException {
-        if (ControlPreferences.getInstance().isLoggingEnabled()) {
-            ControlCommandLogger.log(command.toString());
-        }
-
-        ICommandResult result = fCommandShell.executeCommand(command, monitor);
-
-        if (ControlPreferences.getInstance().isLoggingEnabled()) {
-            ControlCommandLogger.log(result.toString());
-        }
-
-        if (checkForError && isError(result)) {
-            throw new ExecutionException(Messages.TraceControl_CommandError
-                    + " " + command.toString() + "\n" + result.toString()); //$NON-NLS-1$ //$NON-NLS-2$
-        }
-
-        return result;
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/service/LTTngControlServiceConstants.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/service/LTTngControlServiceConstants.java
deleted file mode 100644 (file)
index 7190e78..0000000
+++ /dev/null
@@ -1,474 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2015 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Bernd Hufmann - Updated for support of LTTng Tools 2.1
- *   Simon Delisle - Updated for support of LTTng Tools 2.2
- *   Marc-Andre Laperle - Support for creating a live session
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.service;
-
-import static org.eclipse.tracecompass.common.core.NonNullUtils.checkNotNull;
-
-import java.util.regex.Pattern;
-
-import org.eclipse.jdt.annotation.NonNullByDefault;
-
-/**
- * <p>
- * Constants for LTTng Control Service.
- * </p>
- *
- * @author Bernd Hufmann
- */
-@NonNullByDefault
-public interface LTTngControlServiceConstants {
-
-    // ------------------------------------------------------------------------
-    // Version constants
-    // ------------------------------------------------------------------------
-    /**
-     * Pattern to match the LTTng toolchain version 2.x.y.
-     */
-    Pattern VERSION_2_PATTERN = checkNotNull(Pattern.compile("(2\\.\\d+\\.\\d+).*")); //$NON-NLS-1$
-
-    // ------------------------------------------------------------------------
-    // Constants
-    // ------------------------------------------------------------------------
-    /**
-     * Unused value
-     */
-    int UNUSED_VALUE = -1;
-    /**
-     * String representation of numerical true element
-     */
-    String TRUE_NUMERICAL = "1"; //$NON-NLS-1$
-
-    // ------------------------------------------------------------------------
-    // LTTng Machine Interface constants
-    // ------------------------------------------------------------------------
-
-    /**
-     * Name of the XSD to validate against the xml machine interface
-     * output from LTTng
-     */
-    String MI_XSD_FILENAME = "mi_lttng.xsd"; //$NON-NLS-1$
-    // ------------------------------------------------------------------------
-    // Command constants
-    // ------------------------------------------------------------------------
-    /**
-     * The lttng tools command.
-     */
-    String CONTROL_COMMAND = "lttng"; //$NON-NLS-1$
-    /**
-     * The lttng tools machine interface command.
-     */
-    String CONTROL_COMMAND_MI_OPTION = "--mi"; //$NON-NLS-1$
-    /**
-     * The lttng tools XML machine interface command.
-     */
-    String CONTROL_COMMAND_MI_XML = "xml"; //$NON-NLS-1$
-    /**
-     * Command: lttng version.
-     */
-    String COMMAND_VERSION = "version"; //$NON-NLS-1$
-    /**
-     * Command: lttng list.
-     */
-    String COMMAND_LIST = "list"; //$NON-NLS-1$
-    /**
-     * Command to create a session.
-     */
-    String COMMAND_CREATE_SESSION = "create"; //$NON-NLS-1$
-    /**
-     * Command to destroy a session.
-     */
-    String COMMAND_DESTROY_SESSION = "destroy"; //$NON-NLS-1$
-    /**
-     * Command to destroy a session.
-     */
-    String COMMAND_START_SESSION = "start"; //$NON-NLS-1$
-    /**
-     * Command to destroy a session.
-     */
-    String COMMAND_STOP_SESSION = "stop"; //$NON-NLS-1$
-    /**
-     * Command to enable a channel.
-     */
-    String COMMAND_ENABLE_CHANNEL = "enable-channel"; //$NON-NLS-1$
-    /**
-     * Command to disable a channel.
-     */
-    String COMMAND_DISABLE_CHANNEL = "disable-channel"; //$NON-NLS-1$
-    /**
-     * Command to enable a event.
-     */
-    String COMMAND_ENABLE_EVENT = "enable-event"; //$NON-NLS-1$
-    /**
-     * Command to disable a event.
-     */
-    String COMMAND_DISABLE_EVENT = "disable-event"; //$NON-NLS-1$
-    /**
-     * Command to add a context to channels and/or events
-     */
-    String COMMAND_ADD_CONTEXT = "add-context"; //$NON-NLS-1$
-    /**
-     * Command to execute calibrate command to quantify LTTng overhead
-     */
-    String COMMAND_CALIBRATE = "calibrate"; //$NON-NLS-1$
-    /**
-     * Command to execute sub-command snapshot
-     */
-    String COMMAND_SNAPSHOT = "snapshot"; //$NON-NLS-1$
-    /**
-     * Command to list the snapshot outputs
-     */
-    String COMMAND_LIST_SNAPSHOT_OUTPUT = "list-output"; //$NON-NLS-1$
-    /**
-     * Command to record a snapshot
-     */
-    String COMMAND_RECORD_SNAPSHOT = "record"; //$NON-NLS-1$
-
-    // ------------------------------------------------------------------------
-    // Command line options constants
-    // ------------------------------------------------------------------------
-    /**
-     * Command line option to add tracing group of user.
-     */
-    String OPTION_TRACING_GROUP = "-g";  //$NON-NLS-1$
-    /**
-     * Command line option for verbose output.
-     */
-    String OPTION_VERBOSE = "-v";  //$NON-NLS-1$
-    /**
-     * Command line option for verbose output.
-     */
-    String OPTION_VERY_VERBOSE = "-vv";  //$NON-NLS-1$
-    /**
-     * Command line option for verbose output.
-     */
-    String OPTION_VERY_VERY_VERBOSE = "-vvv";  //$NON-NLS-1$
-    /**
-     * Command line option for output path.
-     */
-    String OPTION_OUTPUT_PATH = "-o"; //$NON-NLS-1$
-    /**
-     * Command line option for output path.
-     */
-    String OPTION_SNAPSHOT = "--snapshot"; //$NON-NLS-1$
-    /**
-     * Command line option for live
-     */
-    String OPTION_LIVE = "--live"; //$NON-NLS-1$
-    /**
-     * Command line option for kernel tracer.
-     */
-    String OPTION_KERNEL = "-k"; //$NON-NLS-1$
-    /**
-     * Command line option for UST tracer.
-     */
-    String OPTION_UST = "-u"; //$NON-NLS-1$
-    /**
-     * Command line option for specifying a session.
-     */
-    String OPTION_SESSION = "-s";  //$NON-NLS-1$
-    /**
-     * Command line option for specifying a channel.
-     */
-    String OPTION_CHANNEL = "-c";  //$NON-NLS-1$
-    /**
-     * Command line option for specifying a event.
-     */
-    String OPTION_EVENT = "-e";  //$NON-NLS-1$
-    /**
-     * Command line option for specifying all events.
-     */
-    String OPTION_ALL = "-a";  //$NON-NLS-1$
-    /**
-     * Command line option for specifying a context.
-     */
-    String OPTION_CONTEXT_TYPE = "-t";  //$NON-NLS-1$
-    /**
-     * Command line option for specifying tracepoint events.
-     */
-    String OPTION_TRACEPOINT = "--tracepoint";  //$NON-NLS-1$
-    /**
-     * Command line option for specifying syscall events.
-     */
-    String OPTION_SYSCALL = "--syscall";  //$NON-NLS-1$
-    /**
-     * Command line option for specifying a dynamic probe.
-     */
-    String OPTION_PROBE = "--probe";  //$NON-NLS-1$
-    /**
-     * Command line option for specifying a dynamic function entry/return probe.
-     */
-    String OPTION_FUNCTION_PROBE = "--function";  //$NON-NLS-1$
-    /**
-     * Command line option for specifying a log level range.
-     */
-    String OPTION_LOGLEVEL = "--loglevel";  //$NON-NLS-1$
-    /**
-     * Command line option for specifying a specific log level.
-     */
-    String OPTION_LOGLEVEL_ONLY = "--loglevel-only";  //$NON-NLS-1$
-    /**
-     * Optional command line option for configuring a channel's overwrite mode.
-     */
-    String OPTION_OVERWRITE = "--overwrite";  //$NON-NLS-1$
-    /**
-     * Optional command line option for configuring a channel's number of sub buffers.
-     */
-    String OPTION_NUM_SUB_BUFFERS = "--num-subbuf";  //$NON-NLS-1$
-    /**
-     * Optional command line option for configuring a channel's sub buffer size.
-     */
-    String OPTION_SUB_BUFFER_SIZE = "--subbuf-size";  //$NON-NLS-1$
-    /**
-     * Optional command line option for configuring a channel's switch timer interval.
-     */
-    String OPTION_SWITCH_TIMER = "--switch-timer";  //$NON-NLS-1$
-    /**
-     * Optional command line option for configuring a channel's read timer interval.
-     */
-    String OPTION_READ_TIMER = "--read-timer";  //$NON-NLS-1$
-    /**
-     * Command line option for printing the help of a specif command
-     */
-    String OPTION_HELP = "-h";  //$NON-NLS-1$
-    /**
-     * Command line option for listing the fields of UST tracepoints
-     */
-    String OPTION_FIELDS = "-f"; //$NON-NLS-1$
-    /**
-     * Command line option for configuring event's filter
-     */
-    String OPTION_FILTER = "--filter"; //$NON-NLS-1$
-    /**
-     * Command line option for configuring the streaming network URL (common for control and data channel).
-     */
-    String OPTION_NETWORK_URL = "-U"; //$NON-NLS-1$
-    /**
-     * Command line option for configuring the streaming control URL.
-     */
-    String OPTION_CONTROL_URL = "-C"; //$NON-NLS-1$
-    /**
-     * Command line option for configuring the streaming data URL.
-     */
-    String OPTION_DATA_URL = "-D"; //$NON-NLS-1$
-    /**
-     * Command line option for per UID buffers
-     */
-    String OPTION_PER_UID_BUFFERS = "--buffers-uid"; //$NON-NLS-1$
-    /**
-     * Command line option for per PID buffers
-     */
-    String OPTION_PER_PID_BUFFERS = "--buffers-pid"; //$NON-NLS-1$
-    /**
-     * Command line option for maximum size of trace files
-     */
-    String OPTION_MAX_SIZE_TRACE_FILES = "-C"; //$NON-NLS-1$
-    /**
-     * Command line option for maximum trace files
-     */
-    String OPTION_MAX_TRACE_FILES = "-W"; //$NON-NLS-1$
-
-    /**
-     * Maximum live timer interval value
-     */
-    Long MAX_LIVE_TIMER_INTERVAL = 0xFFFFFFFEL;
-
-    // ------------------------------------------------------------------------
-    // Parsing constants
-    // ------------------------------------------------------------------------
-    /**
-     * Pattern to match the version.
-     */
-    Pattern VERSION_PATTERN = checkNotNull(Pattern.compile(".*lttng\\s+version\\s+.*(\\d+\\.\\d+\\.\\d+).*")); //$NON-NLS-1$
-    /**
-     * Pattern to match for error output
-     */
-    Pattern ERROR_PATTERN = checkNotNull(Pattern.compile("\\s*Error\\:.*")); //$NON-NLS-1$
-    /**
-     * Pattern to match for session information (lttng list)
-     */
-    Pattern SESSION_PATTERN = checkNotNull(Pattern.compile("\\s+(\\d+)\\)\\s+(.*)\\s+\\((.*)\\)\\s+\\[(active|inactive).*\\].*")); //$NON-NLS-1$
-    /**
-     * Pattern to match for session information (lttng list <session>)
-     */
-    Pattern TRACE_SESSION_PATTERN = checkNotNull(Pattern.compile("\\s*Tracing\\s+session\\s+(.*)\\:\\s+\\[(active|inactive)\\].*")); //$NON-NLS-1$
-    /**
-     * Pattern to match for snapshot session information (lttng list <session>)
-     */
-    Pattern TRACE_SNAPSHOT_SESSION_PATTERN = checkNotNull(Pattern.compile("\\s*Tracing\\s+session\\s+(.*)\\:\\s+\\[(active|inactive)\\s*snapshot\\].*")); //$NON-NLS-1$
-    /**
-     * Pattern to match for session path information (lttng list <session>)
-     */
-    Pattern TRACE_SESSION_PATH_PATTERN = checkNotNull(Pattern.compile("\\s*Trace\\s+path\\:\\s+(.*)")); //$NON-NLS-1$
-    /**
-     * Pattern to match session path for network tracing (lttng list <session>)
-     * Note: file for protocol is not considered as network trace since local consumer will be used.
-     */
-    Pattern TRACE_NETWORK_PATH_PATTERN = checkNotNull(Pattern.compile("\\s*Trace\\s+path\\:\\s+(net|net4|net6|tcp|tcp4|tcp6)\\:\\/\\/(.*)(\\:(\\d*)\\/(.*)\\[data\\:\\s+(\\d*)\\]){0,1}")); //$NON-NLS-1$
-    /**
-     * Pattern to match session path for network tracing
-     * Note: file for protocol is not considered as network trace since local consumer will be used.
-     */
-    Pattern TRACE_NETWORK_PATTERN = checkNotNull(Pattern.compile("\\s*(net|net4|net6|tcp|tcp4|tcp6)\\:\\/\\/(.*)(\\:(\\d*)\\/(.*)\\[data\\:\\s+(\\d*)\\]){0,1}")); //$NON-NLS-1$
-    /**
-     * Sub-pattern to pattern TRACE_NETWORK_PATH_PATTERN to match file protocol
-     */
-    Pattern TRACE_FILE_PROTOCOL_PATTERN = checkNotNull(Pattern.compile("(file)\\:\\/\\/(.*)")); //$NON-NLS-1$
-    /**
-     * Pattern to match for kernel domain information (lttng list <session>)
-     */
-    Pattern DOMAIN_KERNEL_PATTERN = checkNotNull(Pattern.compile("=== Domain: Kernel ===")); //$NON-NLS-1$
-    /**
-     * Pattern to match for ust domain information (lttng list <session>)
-     */
-    Pattern DOMAIN_UST_GLOBAL_PATTERN = checkNotNull(Pattern.compile("=== Domain: UST global ===")); //$NON-NLS-1$
-    /**
-     * Pattern to match for matching warning about no kernel channel
-     */
-    Pattern DOMAIN_NO_KERNEL_CHANNEL_PATTERN = checkNotNull(Pattern.compile("\\s*Warning\\:\\s+No kernel\\s+channel.*")); //$NON-NLS-1$
-    /**
-     * Pattern to match for matching warning about no UST channel
-     */
-    Pattern DOMAIN_NO_UST_CHANNEL_PATTERN = checkNotNull(Pattern.compile("\\s*Error\\:\\s+UST\\s+channel\\s+not\\s+found.*")); //$NON-NLS-1$
-    /**
-     * Pattern to match for buffer type (lttng list <session>)
-     */
-    Pattern BUFFER_TYPE_PATTERN = checkNotNull(Pattern.compile("\\s*Buffer\\s+type\\:.*")); //$NON-NLS-1$
-    /**
-     * Pattern to match for channels section (lttng list <session>)
-     */
-    Pattern CHANNELS_SECTION_PATTERN = checkNotNull(Pattern.compile("\\s*Channels\\:")); //$NON-NLS-1$
-    /**
-     * Pattern to match for channel information (lttng list <session>)
-     */
-    Pattern CHANNEL_PATTERN = checkNotNull(Pattern.compile("\\s*-\\s+(.*)\\:\\s+\\[(enabled|disabled)\\]")); //$NON-NLS-1$
-    /**
-     * Pattern to match for events section information (lttng list <session>)
-     */
-    Pattern EVENT_SECTION_PATTERN = checkNotNull(Pattern.compile("\\s*Events\\:")); //$NON-NLS-1$
-    /**
-     * Pattern to match for event information (lttng list <session>)
-     */
-    Pattern EVENT_PATTERN = checkNotNull(Pattern.compile("\\s+(.*)\\s+\\(loglevel\\s*(:|<=|==)\\s+(.*)\\s+\\(\\d*\\)\\)\\s+\\(type:\\s+(.*)\\)\\s+\\[(enabled|disabled)\\]\\s*(\\[.*\\]){0,1}.*")); //$NON-NLS-1$
-    /**
-     * Pattern to match a wildcarded event information (lttng list <session>)
-     */
-    Pattern WILDCARD_EVENT_PATTERN = checkNotNull(Pattern.compile("\\s+(.*)\\s+\\(type:\\s+(.*)\\)\\s+\\[(enabled|disabled)\\]\\s*(\\[.*\\]){0,1}.*")); //$NON-NLS-1$
-    /**
-     * Pattern to match a probe address information (lttng list <session>)
-     */
-    Pattern PROBE_ADDRESS_PATTERN = checkNotNull(Pattern.compile("\\s+(addr)\\:\\s+(0x[0-9a-fA-F]{1,16})")); //$NON-NLS-1$
-    /**
-     * Pattern to match a probe OFFSET information (lttng list <session>)
-     */
-    Pattern PROBE_OFFSET_PATTERN = checkNotNull(Pattern.compile("\\s+(offset)\\:\\s+(0x[0-9a-fA-F]{1,16})")); //$NON-NLS-1$
-    /**
-     * Pattern to match a probe SYMBOL information (lttng list <session>)
-     */
-    Pattern PROBE_SYMBOL_PATTERN = checkNotNull(Pattern.compile("\\s+(symbol)\\:\\s+(.+)")); //$NON-NLS-1$
-    /**
-     * Pattern to match for channel (overwite mode) information (lttng list <session>)
-     */
-    Pattern OVERWRITE_MODE_ATTRIBUTE = checkNotNull(Pattern.compile("\\s+overwrite\\s+mode\\:.*")); //$NON-NLS-1$
-    /**
-     * Pattern to match indicating false for overwrite mode
-     */
-    String OVERWRITE_MODE_ATTRIBUTE_FALSE = "0"; //$NON-NLS-1$
-    /**
-     * Pattern to match indicating false for overwrite mode in machine interface mode
-     */
-    String OVERWRITE_MODE_ATTRIBUTE_FALSE_MI = "DISCARD"; //$NON-NLS-1$
-    /**
-     * Pattern to match for channel (sub-buffer size) information (lttng list <session>)
-     */
-    Pattern SUBBUFFER_SIZE_ATTRIBUTE = checkNotNull(Pattern.compile("\\s+subbufers\\s+size\\:.*")); //$NON-NLS-1$
-    /**
-     * Pattern to match for channel (number of sub-buffers) information (lttng list <session>)
-     */
-    Pattern NUM_SUBBUFFERS_ATTRIBUTE = checkNotNull(Pattern.compile("\\s+number\\s+of\\s+subbufers\\:.*")); //$NON-NLS-1$
-    /**
-     * Pattern to match for channel (switch timer) information (lttng list <session>)
-     */
-    Pattern SWITCH_TIMER_ATTRIBUTE = checkNotNull(Pattern.compile("\\s+switch\\s+timer\\s+interval\\:.*")); //$NON-NLS-1$
-    /**
-     * Pattern to match for channel (read timer) information (lttng list <session>)
-     */
-    Pattern READ_TIMER_ATTRIBUTE = checkNotNull(Pattern.compile("\\s+read\\s+timer\\s+interval\\:.*")); //$NON-NLS-1$
-    /**
-     * Pattern to match for channel (output type) information (lttng list <session>)
-     */
-    Pattern OUTPUT_ATTRIBUTE = checkNotNull(Pattern.compile("\\s+output\\:.*")); //$NON-NLS-1$
-    /**
-     * Pattern to match for channel (trace file size) information (lttng list <session>)
-     */
-    Pattern TRACE_FILE_COUNT_ATTRIBUTE = checkNotNull(Pattern.compile("\\s+trace\\s+file\\s+count\\:.*")); //$NON-NLS-1$
-    /**
-     * Pattern to match for channel (trace file size) information (lttng list <session>)
-     */
-    Pattern TRACE_FILE_SIZE_ATTRIBUTE = checkNotNull(Pattern.compile("\\s+trace\\s+file\\s+size\\s+\\(bytes\\)\\:.*")); //$NON-NLS-1$
-    /**
-     * Pattern to match for provider information (lttng list -k/-u)
-     */
-    Pattern PROVIDER_EVENT_PATTERN = checkNotNull(Pattern.compile("\\s*(.*)\\s+\\(loglevel:\\s+(.*)\\s+\\(\\d*\\)\\)\\s+\\(type:\\s+(.*)\\)")); //$NON-NLS-1$
-    /**
-     * Pattern to match event fields
-     */
-    Pattern EVENT_FIELD_PATTERN = checkNotNull(Pattern.compile("\\s*(field:)\\s+(.*)\\s+\\((.*)\\)")); //$NON-NLS-1$
-    /**
-     * Pattern to match for UST provider information (lttng list -u)
-     */
-    Pattern UST_PROVIDER_PATTERN = checkNotNull(Pattern.compile("\\s*PID\\:\\s+(\\d+)\\s+-\\s+Name\\:\\s+(.*)")); //$NON-NLS-1$
-    /**
-     * Pattern to match for session information (lttng create <session name>)
-     */
-    Pattern CREATE_SESSION_NAME_PATTERN = checkNotNull(Pattern.compile(".*Session\\s+(.*)\\s+created\\.")); //$NON-NLS-1$
-    /**
-     * Pattern to match for session path information (lttng create <session name>)
-     */
-    Pattern CREATE_SESSION_PATH_PATTERN = checkNotNull(Pattern.compile("\\s*Traces\\s+will\\s+be\\s+written\\s+in\\s+(.*).*")); //$NON-NLS-1$
-    /**
-     * Pattern to match for session command output for "session name not found".
-     */
-    Pattern SESSION_NOT_FOUND_ERROR_PATTERN = checkNotNull(Pattern.compile("\\s*Error:\\s+Session\\s+name\\s.*not\\s+found")); //$NON-NLS-1$
-    /**
-     * Pattern to match introduction line of context list.
-     */
-    Pattern ADD_CONTEXT_HELP_CONTEXTS_INTRO = checkNotNull(Pattern.compile("\\s*TYPE can\\s+be\\s+one\\s+of\\s+the\\s+strings\\s+below.*")); //$NON-NLS-1$
-    /**
-     * Pattern to match introduction line of context list.
-     */
-    Pattern ADD_CONTEXT_HELP_CONTEXTS_END_LINE = checkNotNull(Pattern.compile("\\s*Example.*")); //$NON-NLS-1$
-    /**
-     * Pattern to match error line if no kernel tracer is available or installed.
-     */
-    Pattern LIST_KERNEL_NO_KERNEL_PROVIDER_PATTERN = checkNotNull(Pattern.compile("\\s*Error:\\s+Unable\\s+to\\s+list\\s+kernel\\s+events.*")); //$NON-NLS-1$;
-    /**
-     * Pattern to match error line if no ust tracer is available or installed.
-     */
-    Pattern LIST_UST_NO_UST_PROVIDER_PATTERN = checkNotNull(Pattern.compile(".*Unable\\s*to\\s*list\\s*UST\\s*event.*")); //$NON-NLS-1$;
-    /**
-     * Pattern to match for list snapshot information (lttng snapshot list-output)
-     */
-    Pattern LIST_SNAPSHOT_OUTPUT_PATTERN = checkNotNull(Pattern.compile("\\s+\\[(\\d+)\\]\\s+(\\S*)\\:\\s+(\\S*)(.*)")); //$NON-NLS-1$
-    /**
-     * Pattern to match the live timer interval line of session list.
-     */
-    Pattern LIST_LIVE_TIMER_INTERVAL_PATTERN = checkNotNull(Pattern.compile("\\s*Live\\stimer\\sinterval\\s\\(usec\\):\\s(\\d+)")); //$NON-NLS-1$
-    /**
-     * Pattern to match snapshot path for network tracing (lttng list <session>)
-     * Note: file for protocol is not considered as network trace since local consumer will be used.
-     */
-    Pattern SNAPSHOT_NETWORK_PATH_PATTERN = checkNotNull(Pattern.compile("(net|net4|net6|tcp|tcp4|tcp6)\\:\\/\\/(.*)(\\:(\\d*)\\/(.*)\\[data\\:\\s+(\\d*)\\]){0,1}")); //$NON-NLS-1$
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/service/LTTngControlServiceFactory.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/service/LTTngControlServiceFactory.java
deleted file mode 100644 (file)
index 6d94077..0000000
+++ /dev/null
@@ -1,126 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2012, 2015 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Jonathan Rajotte - machine interface support
- **********************************************************************/
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.service;
-
-import static org.eclipse.tracecompass.common.core.NonNullUtils.checkNotNull;
-
-import java.util.regex.Matcher;
-
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.core.runtime.NullProgressMonitor;
-import org.eclipse.jdt.annotation.NonNullByDefault;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.logging.ControlCommandLogger;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.preferences.ControlPreferences;
-import org.eclipse.tracecompass.tmf.remote.core.shell.ICommandInput;
-import org.eclipse.tracecompass.tmf.remote.core.shell.ICommandResult;
-import org.eclipse.tracecompass.tmf.remote.core.shell.ICommandShell;
-
-/**
- * Factory to create LTTngControlService instances depending on the version of
- * the LTTng Trace Control installed on the remote host.
- *
- * @author Bernd Hufmann
- */
-@NonNullByDefault
-public final class LTTngControlServiceFactory {
-
-    // ------------------------------------------------------------------------
-    // Constructor
-    // ------------------------------------------------------------------------
-    /**
-     * Constructor
-     */
-    private LTTngControlServiceFactory() {
-    }
-
-    // ------------------------------------------------------------------------
-    // Factory method
-    // ------------------------------------------------------------------------
-    /**
-     * Gets the LTTng Control Service implementation based on the version of the
-     * remote LTTng Tools.
-     *
-     * @param shell
-     *            - the shell implementation to pass to the service
-     * @return - LTTng Control Service implementation
-     * @throws ExecutionException
-     *             If the command fails
-     */
-    public static ILttngControlService getLttngControlService(ICommandShell shell) throws ExecutionException {
-        // get the version
-        boolean machineInterfaceMode = true;
-
-        // Looking for a machine interface on LTTng side
-        ICommandInput command = shell.createCommand();
-        command.add(LTTngControlServiceConstants.CONTROL_COMMAND);
-        command.add(LTTngControlServiceConstants.CONTROL_COMMAND_MI_OPTION);
-        command.add(LTTngControlServiceConstants.CONTROL_COMMAND_MI_XML);
-        command.add(LTTngControlServiceConstants.COMMAND_VERSION);
-        ICommandResult result = executeCommand(shell, command);
-
-        if (result.getResult() != 0) {
-            machineInterfaceMode = false;
-            // Fall back if no machine interface is present
-            command = shell.createCommand();
-            command.add(LTTngControlServiceConstants.CONTROL_COMMAND);
-            command.add(LTTngControlServiceConstants.COMMAND_VERSION);
-            result = executeCommand(shell, command);
-        }
-
-        if ((result.getResult() == 0) && (!result.getOutput().isEmpty())) {
-            if (machineInterfaceMode) {
-                LTTngControlServiceMI service = new LTTngControlServiceMI(shell, LTTngControlService.class.getResource(LTTngControlServiceConstants.MI_XSD_FILENAME));
-                service.setVersion(result.getOutput());
-                return service;
-            }
-
-            for (String line : result.getOutput()) {
-                line = line.replace("-", ".");  //$NON-NLS-1$//$NON-NLS-2$
-                Matcher versionMatcher = LTTngControlServiceConstants.VERSION_PATTERN.matcher(line);
-                if (versionMatcher.matches()) {
-                    String version = versionMatcher.group(1).trim();
-                    Matcher matcher = LTTngControlServiceConstants.VERSION_2_PATTERN.matcher(version);
-                    if (matcher.matches()) {
-                        LTTngControlService service = new LTTngControlService(shell);
-                        service.setVersion(checkNotNull(version));
-                        return service;
-                    }
-                    throw new ExecutionException(Messages.TraceControl_UnsupportedVersionError + ": " + version); //$NON-NLS-1$
-                }
-            }
-        }
-        throw new ExecutionException(Messages.TraceControl_GettingVersionError);
-    }
-
-    private static ICommandResult executeCommand(ICommandShell shell, ICommandInput command) throws ExecutionException {
-        // Logging
-        if (ControlPreferences.getInstance().isLoggingEnabled()) {
-            ControlCommandLogger.log(command.toString());
-        }
-
-        ICommandResult result = null;
-
-        try {
-            result = shell.executeCommand(command, new NullProgressMonitor());
-        } catch (ExecutionException e) {
-            throw new ExecutionException(Messages.TraceControl_GettingVersionError + ": " + e); //$NON-NLS-1$
-        }
-
-        // Output logging
-        if (ControlPreferences.getInstance().isLoggingEnabled()) {
-            ControlCommandLogger.log(result.toString());
-        }
-        return result;
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/service/LTTngControlServiceMI.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/service/LTTngControlServiceMI.java
deleted file mode 100644 (file)
index 0b1c77f..0000000
+++ /dev/null
@@ -1,967 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014, 2015 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:
- *   Jonathan Rajotte - Initial support for machine interface lttng 2.6
- *   Bernd Hufmann - Fix check for live session
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.service;
-
-import static org.eclipse.tracecompass.common.core.NonNullUtils.checkNotNull;
-
-import java.io.IOException;
-import java.io.StringReader;
-import java.math.BigInteger;
-import java.net.URL;
-import java.util.ArrayList;
-import java.util.List;
-import java.util.regex.Matcher;
-
-import javax.xml.XMLConstants;
-import javax.xml.parsers.DocumentBuilder;
-import javax.xml.parsers.DocumentBuilderFactory;
-import javax.xml.parsers.ParserConfigurationException;
-import javax.xml.validation.SchemaFactory;
-
-import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.jdt.annotation.NonNull;
-import org.eclipse.jdt.annotation.Nullable;
-import org.eclipse.osgi.util.NLS;
-import org.eclipse.tracecompass.common.core.NonNullUtils;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IBaseEventInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IChannelInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IDomainInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IEventInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IFieldInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IProbeEventInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISessionInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.ISnapshotInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.IUstProviderInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.LogLevelType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceDomainType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEnablement;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceEventType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceLogLevel;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.BaseEventInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.BufferType;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.ChannelInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.DomainInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.EventInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.FieldInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.ProbeEventInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.SessionInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.SnapshotInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.core.model.impl.UstProviderInfo;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.handlers.XmlMiValidationErrorHandler;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.messages.Messages;
-import org.eclipse.tracecompass.tmf.remote.core.shell.ICommandInput;
-import org.eclipse.tracecompass.tmf.remote.core.shell.ICommandResult;
-import org.eclipse.tracecompass.tmf.remote.core.shell.ICommandShell;
-import org.w3c.dom.Document;
-import org.w3c.dom.Node;
-import org.w3c.dom.NodeList;
-import org.xml.sax.InputSource;
-import org.xml.sax.SAXException;
-
-/**
- * Service for sending LTTng trace control commands to remote host via machine
- * interface mode.
- *
- * @author Jonathan Rajotte
- */
-public class LTTngControlServiceMI extends LTTngControlService {
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-
-    private final DocumentBuilder fDocumentBuilder;
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-
-    /**
-     * Constructor
-     *
-     * @param shell
-     *            the command shell implementation to use
-     * @param xsdUrl
-     *            the xsd schema file for validation
-     * @throws ExecutionException
-     *             if the creation of the Schema and DocumentBuilder objects
-     *             fails
-     */
-    public LTTngControlServiceMI(@NonNull ICommandShell shell, @Nullable URL xsdUrl) throws ExecutionException {
-        super(shell);
-
-        DocumentBuilderFactory docBuilderFactory = DocumentBuilderFactory.newInstance();
-        docBuilderFactory.setValidating(false);
-
-        // Validate XSD schema
-        if (xsdUrl != null) {
-            SchemaFactory schemaFactory = SchemaFactory.newInstance(XMLConstants.W3C_XML_SCHEMA_NS_URI);
-            try {
-                docBuilderFactory.setSchema(schemaFactory.newSchema(xsdUrl));
-            } catch (SAXException e) {
-                throw new ExecutionException(Messages.TraceControl_InvalidSchemaError, e);
-            }
-        }
-
-        try {
-            fDocumentBuilder = docBuilderFactory.newDocumentBuilder();
-        } catch (ParserConfigurationException e) {
-            throw new ExecutionException(Messages.TraceControl_XmlDocumentBuilderError, e);
-        }
-
-        fDocumentBuilder.setErrorHandler(new XmlMiValidationErrorHandler());
-
-    }
-
-    /**
-     * Generate a Document object from an list of Strings.
-     *
-     * @param xmlStrings
-     *            list of strings representing an xml input
-     * @return Document generated from strings input
-     * @throws ExecutionException
-     *             when parsing has failed
-     */
-    private Document getDocumentFromStrings(List<String> xmlStrings) throws ExecutionException {
-        StringBuilder concatenedString = new StringBuilder();
-        for (String string : xmlStrings) {
-            concatenedString.append(string);
-        }
-        InputSource stream = new InputSource(new StringReader(concatenedString.toString()));
-
-        Document document;
-        try {
-            document = fDocumentBuilder.parse(stream);
-        } catch (SAXException | IOException e) {
-            throw new ExecutionException(Messages.TraceControl_XmlParsingError + ':' + e.toString(), e);
-        }
-        return document;
-
-    }
-
-    /**
-     * Parse, populate and set the internal LTTngVersion variable
-     *
-     * @param xmlOutput
-     *            the mi xml output of lttng version
-     * @throws ExecutionException
-     *             when xml extraction fail
-     */
-    public void setVersion(List<String> xmlOutput) throws ExecutionException {
-        Document doc = getDocumentFromStrings(xmlOutput);
-        NodeList element = doc.getElementsByTagName(MIStrings.VERSION);
-        int major = 0;
-        int minor = 0;
-        int patchLevel = 0;
-        String license = ""; //$NON-NLS-1$
-        String commit = ""; //$NON-NLS-1$
-        String name = ""; //$NON-NLS-1$
-        String description = ""; //$NON-NLS-1$
-        String url = ""; //$NON-NLS-1$
-        String fullVersion = ""; //$NON-NLS-1$
-        if (element.getLength() == 1) {
-            NodeList child = element.item(0).getChildNodes();
-            // Get basic information
-            for (int i = 0; i < child.getLength(); i++) {
-                Node node = child.item(i);
-                switch (node.getNodeName()) {
-                case MIStrings.VERSION_MAJOR:
-                    major = Integer.parseInt(node.getTextContent());
-                    break;
-                case MIStrings.VERSION_MINOR:
-                    minor = Integer.parseInt(node.getTextContent());
-                    break;
-                case MIStrings.VERSION_PATCH_LEVEL:
-                    patchLevel = Integer.parseInt(node.getTextContent());
-                    break;
-                case MIStrings.VERSION_COMMIT:
-                    commit = node.getTextContent();
-                    break;
-                case MIStrings.VERSION_DESCRIPTION:
-                    description = node.getTextContent();
-                    break;
-                case MIStrings.VERSION_LICENSE:
-                    license = node.getTextContent();
-                    break;
-                case MIStrings.VERSION_NAME:
-                    name = node.getTextContent();
-                    break;
-                case MIStrings.VERSION_STR:
-                    fullVersion = node.getTextContent();
-                    break;
-                case MIStrings.VERSION_WEB:
-                    url = node.getTextContent();
-                    break;
-                default:
-                    break;
-                }
-            }
-            setVersion(new LttngVersion(major, minor, patchLevel, license, commit, name, description, url, fullVersion));
-        } else {
-            throw new ExecutionException(Messages.TraceControl_UnsupportedVersionError);
-        }
-    }
-
-    @Override
-    public List<String> getSessionNames(IProgressMonitor monitor) throws ExecutionException {
-        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_LIST);
-        ICommandResult result = executeCommand(command, monitor);
-
-        Document doc = getDocumentFromStrings(result.getOutput());
-
-        NodeList elements = doc.getElementsByTagName(MIStrings.NAME);
-
-        ArrayList<String> retArray = new ArrayList<>();
-        for (int i = 0; i < elements.getLength(); i++) {
-            Node node = elements.item(i);
-            if (node.getParentNode().getNodeName().equalsIgnoreCase(MIStrings.SESSION)) {
-                retArray.add(node.getTextContent());
-            }
-        }
-        return retArray;
-    }
-
-    @Override
-    public ISessionInfo getSession(String sessionName, IProgressMonitor monitor) throws ExecutionException {
-        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_LIST, sessionName);
-        ICommandResult result = executeCommand(command, monitor);
-
-        ISessionInfo sessionInfo = new SessionInfo(sessionName);
-        Document document = getDocumentFromStrings(result.getOutput());
-
-        NodeList sessionsNode = document.getElementsByTagName(MIStrings.SESSION);
-        // There should be only one session
-        if (sessionsNode.getLength() != 1) {
-            throw new ExecutionException(NLS.bind(Messages.TraceControl_MiInvalidNumberOfElementError, MIStrings.SESSION));
-        }
-
-        // Populate session information
-        Node rawSession = sessionsNode.item(0);
-        parseSession(sessionInfo, rawSession);
-
-        // Fetch the snapshot info
-        if (sessionInfo.isSnapshotSession()) {
-            ISnapshotInfo snapshot = getSnapshotInfo(sessionName, monitor);
-            sessionInfo.setSnapshotInfo(snapshot);
-        }
-
-        return sessionInfo;
-    }
-
-    /**
-     * @param sessionInfo
-     * @param rawSession
-     * @throws ExecutionException
-     */
-    private void parseSession(ISessionInfo sessionInfo, Node rawSession) throws ExecutionException {
-        if (!rawSession.getNodeName().equalsIgnoreCase(MIStrings.SESSION)) {
-            throw new ExecutionException(Messages.TraceControl_MiInvalidElementError);
-        }
-        NodeList rawSessionInfos = rawSession.getChildNodes();
-        for (int i = 0; i < rawSessionInfos.getLength(); i++) {
-            Node rawInfo = rawSessionInfos.item(i);
-            switch (rawInfo.getNodeName()) {
-            case MIStrings.NAME:
-                sessionInfo.setName(rawInfo.getTextContent());
-                break;
-            case MIStrings.PATH:
-                sessionInfo.setSessionPath(rawInfo.getTextContent());
-                break;
-            case MIStrings.ENABLED:
-                sessionInfo.setSessionState(rawInfo.getTextContent());
-                break;
-            case MIStrings.SNAPSHOT_MODE:
-                if (rawInfo.getTextContent().equals(LTTngControlServiceConstants.TRUE_NUMERICAL)) {
-                    // real name will be set later
-                    ISnapshotInfo snapshotInfo = new SnapshotInfo(""); //$NON-NLS-1$
-                    sessionInfo.setSnapshotInfo(snapshotInfo);
-                }
-                break;
-            case MIStrings.LIVE_TIMER_INTERVAL:
-                long liveDelay = Long.parseLong(rawInfo.getTextContent());
-                if ((liveDelay > 0 && (liveDelay <= LTTngControlServiceConstants.MAX_LIVE_TIMER_INTERVAL))) {
-                    sessionInfo.setLive(true);
-                    sessionInfo.setLiveUrl(SessionInfo.DEFAULT_LIVE_NETWORK_URL);
-                    sessionInfo.setLivePort(SessionInfo.DEFAULT_LIVE_PORT);
-                    sessionInfo.setLiveDelay(liveDelay);
-                }
-                break;
-            case MIStrings.DOMAINS:
-                // Extract the domains node
-                NodeList rawDomains = rawInfo.getChildNodes();
-                IDomainInfo domain = null;
-                for (int j = 0; j < rawDomains.getLength(); j++) {
-                    if (rawDomains.item(j).getNodeName().equalsIgnoreCase(MIStrings.DOMAIN)) {
-                        domain = parseDomain(rawDomains.item(j));
-                        sessionInfo.addDomain(domain);
-                    }
-                }
-                break;
-            default:
-                break;
-            }
-        }
-
-        if (!sessionInfo.isSnapshotSession()) {
-            Matcher matcher = LTTngControlServiceConstants.TRACE_NETWORK_PATTERN.matcher(sessionInfo.getSessionPath());
-            if (matcher.matches()) {
-                sessionInfo.setStreamedTrace(true);
-            }
-        }
-    }
-
-    /**
-     * Parse a raw domain XML node to a IDomainInfo object
-     *
-     * @param rawDomain
-     *            a domain xml node
-     * @return a populated {@link DomainInfo} object
-     * @throws ExecutionException
-     *             when missing required xml element (type)
-     */
-    protected IDomainInfo parseDomain(Node rawDomain) throws ExecutionException {
-        IDomainInfo domain = null;
-        // Get the type
-        Node rawType = getFirstOf(rawDomain.getChildNodes(), MIStrings.TYPE);
-        if (rawType == null) {
-            throw new ExecutionException(Messages.TraceControl_MiMissingRequiredError);
-        }
-        String rawTypeString = rawType.getTextContent().toLowerCase();
-        TraceDomainType domainType = TraceDomainType.valueOfString(rawTypeString);
-        switch (domainType) {
-        case KERNEL:
-            domain = new DomainInfo(Messages.TraceControl_KernelProviderDisplayName);
-            domain.setIsKernel(true);
-            break;
-        case UST:
-            domain = new DomainInfo(Messages.TraceControl_UstGlobalDomainDisplayName);
-            domain.setIsKernel(false);
-            break;
-        case JUL:
-            /**
-             * TODO: Support for JUL JUL substructure and semantic is not the
-             * same as a regular UST or Kernel Domain There is no channel under
-             * JUL domain only events. The channel is activated in UST Channel
-             */
-            domain = new DomainInfo(Messages.TraceControl_JULDomainDisplayName);
-            domain.setIsKernel(false);
-            break;
-        case UNKNOWN:
-            domain = new DomainInfo(Messages.TraceControl_UnknownDomainDisplayName);
-            domain.setIsKernel(false);
-            break;
-        default:
-            throw new ExecutionException(Messages.TraceControl_MiInvalidElementError);
-        }
-
-        NodeList rawInfos = rawDomain.getChildNodes();
-        for (int i = 0; i < rawInfos.getLength(); i++) {
-            Node rawInfo = rawInfos.item(i);
-            switch (rawInfo.getNodeName()) {
-            case MIStrings.BUFFER_TYPE:
-                BufferType bufferType = BufferType.valueOfString(rawInfo.getTextContent());
-                domain.setBufferType(bufferType);
-                break;
-            case MIStrings.CHANNELS:
-                ArrayList<IChannelInfo> channels = new ArrayList<>();
-                parseChannels(rawInfo.getChildNodes(), channels);
-                if (channels.size() > 0) {
-                    domain.setChannels(channels);
-                }
-                break;
-            default:
-                break;
-            }
-        }
-
-        return domain;
-    }
-
-    /**
-     * Parse a list of raw channel XML node into an ArrayList of IChannelInfo
-     *
-     * @param rawChannes
-     *            List of raw channel XML node
-     * @param channels
-     *            the parsed channels list
-     * @throws ExecutionException
-     *             when missing required xml element (type)
-     */
-    private static void parseChannels(NodeList rawChannels, ArrayList<IChannelInfo> channels) throws ExecutionException {
-        IChannelInfo channel = null;
-        for (int i = 0; i < rawChannels.getLength(); i++) {
-            Node rawChannel = rawChannels.item(i);
-            if (rawChannel.getNodeName().equalsIgnoreCase(MIStrings.CHANNEL)) {
-                channel = new ChannelInfo(""); //$NON-NLS-1$
-
-                // Populate the channel
-                NodeList rawInfos = rawChannel.getChildNodes();
-                Node rawInfo = null;
-                for (int j = 0; j < rawInfos.getLength(); j++) {
-                    rawInfo = rawInfos.item(j);
-                    switch (rawInfo.getNodeName()) {
-                    case MIStrings.NAME:
-                        channel.setName(rawInfo.getTextContent());
-                        break;
-                    case MIStrings.ENABLED:
-                        channel.setState(TraceEnablement.valueOfString(rawInfo.getTextContent()));
-                        break;
-                    case MIStrings.EVENTS:
-                        List<IEventInfo> events = new ArrayList<>();
-                        getEventInfo(rawInfo.getChildNodes(), events);
-                        channel.setEvents(events);
-                        break;
-                    case MIStrings.ATTRIBUTES:
-                        NodeList rawAttributes = rawInfo.getChildNodes();
-                        for (int k = 0; k < rawAttributes.getLength(); k++) {
-                            Node attribute = rawAttributes.item(k);
-                            switch (attribute.getNodeName()) {
-                            case MIStrings.OVERWRITE_MODE:
-                                channel.setOverwriteMode(!LTTngControlServiceConstants.OVERWRITE_MODE_ATTRIBUTE_FALSE_MI.equalsIgnoreCase(attribute.getTextContent()));
-                                break;
-                            case MIStrings.SUBBUF_SIZE:
-                                channel.setSubBufferSize(Long.valueOf(attribute.getTextContent()));
-                                break;
-                            case MIStrings.NUM_SUBBUF:
-                                channel.setNumberOfSubBuffers(Integer.valueOf(attribute.getTextContent()));
-                                break;
-                            case MIStrings.SWITCH_TIMER_INTERVAL:
-                                channel.setSwitchTimer(Long.valueOf(attribute.getTextContent()));
-                                break;
-                            case MIStrings.READ_TIMER_INTERVAL:
-                                channel.setReadTimer(Long.valueOf(attribute.getTextContent()));
-                                break;
-                            case MIStrings.OUTPUT_TYPE:
-                                channel.setOutputType(attribute.getTextContent());
-                                break;
-                            case MIStrings.TRACEFILE_SIZE:
-                                channel.setMaxSizeTraceFiles(Long.parseLong(attribute.getTextContent()));
-                                break;
-                            case MIStrings.TRACEFILE_COUNT:
-                                channel.setMaxNumberTraceFiles(Integer.parseInt(attribute.getTextContent()));
-                                break;
-                            case MIStrings.LIVE_TIMER_INTERVAL:
-                                // TODO: currently not supported by tmf
-                                break;
-                            default:
-                                break;
-                            }
-                        }
-                        break;
-                    default:
-                        break;
-                    }
-                }
-                channels.add(channel);
-            }
-        }
-
-    }
-
-    @Override
-    public ISnapshotInfo getSnapshotInfo(String sessionName, IProgressMonitor monitor) throws ExecutionException {
-        // TODO A session can have multiple snapshot output. This need to be
-        // supported in the future.
-        // Currently the SessionInfo object does not support multiple snashot
-        // output.
-        // For now only keep the last one.
-        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_SNAPSHOT, LTTngControlServiceConstants.COMMAND_LIST_SNAPSHOT_OUTPUT, LTTngControlServiceConstants.OPTION_SESSION, sessionName);
-        ICommandResult result = executeCommand(command, monitor);
-        Document doc = getDocumentFromStrings(result.getOutput());
-        NodeList rawSnapshotsOutputs = doc.getElementsByTagName(MIStrings.SNAPSHOT_OUTPUTS);
-
-        ISnapshotInfo snapshotInfo = new SnapshotInfo(""); //$NON-NLS-1$
-
-        // TODO: tmf does not have a notion of a ctrl url.
-        for (int i = 0; i < rawSnapshotsOutputs.getLength(); i++) {
-            NodeList rawSnapshotOutput = rawSnapshotsOutputs.item(i).getChildNodes();
-            for (int j = 0; j < rawSnapshotOutput.getLength(); j++) {
-                Node rawInfo = rawSnapshotOutput.item(j);
-                switch (rawInfo.getNodeName()) {
-                case MIStrings.ID:
-                    snapshotInfo.setId(Integer.parseInt(rawInfo.getTextContent()));
-                    break;
-                case MIStrings.NAME:
-                    snapshotInfo.setName(rawInfo.getTextContent());
-                    break;
-                case MIStrings.SNAPSHOT_CTRL_URL:
-                    // The use of the ctrl_url for the snapshot path is to assure
-                    // basic support. Refactoring is necessary in lttng and
-                    // tmf side.
-                    // See http://bugs.lttng.org/issues/828 (+comment)
-                    snapshotInfo.setSnapshotPath(rawInfo.getTextContent());
-                    break;
-                default:
-                    break;
-                }
-            }
-        }
-
-        // Check if the snapshot output is Streamed
-        Matcher matcher2 = LTTngControlServiceConstants.TRACE_NETWORK_PATTERN.matcher(snapshotInfo.getSnapshotPath());
-        if (matcher2.matches()) {
-            snapshotInfo.setStreamedSnapshot(true);
-        }
-
-        return snapshotInfo;
-    }
-
-    @Override
-    public List<IBaseEventInfo> getKernelProvider(IProgressMonitor monitor) throws ExecutionException {
-        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_LIST, LTTngControlServiceConstants.OPTION_KERNEL);
-        ICommandResult result = executeCommand(command, monitor, false);
-        List<IBaseEventInfo> events = new ArrayList<>();
-
-        if (isError(result)) {
-            // Ignore the following 2 cases:
-            // Spawning a session daemon
-            // Error: Unable to list kernel events
-            // or:
-            // Error: Unable to list kernel events
-            if (ignoredPattern(result.getErrorOutput(), LTTngControlServiceConstants.LIST_KERNEL_NO_KERNEL_PROVIDER_PATTERN)) {
-                return events;
-            }
-            throw new ExecutionException(Messages.TraceControl_CommandError + command.toString());
-        }
-
-        Document document = getDocumentFromStrings(result.getOutput());
-        NodeList rawEvents = document.getElementsByTagName(MIStrings.EVENT);
-        getBaseEventInfo(rawEvents, events);
-        return events;
-    }
-
-    @Override
-    public List<IUstProviderInfo> getUstProvider(IProgressMonitor monitor) throws ExecutionException {
-        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_LIST, LTTngControlServiceConstants.OPTION_UST);
-        // Get the field to
-        command.add(LTTngControlServiceConstants.OPTION_FIELDS);
-
-        // Execute
-        ICommandResult result = executeCommand(command, monitor, false);
-        List<IUstProviderInfo> allProviders = new ArrayList<>();
-
-        if (isError(result)) {
-            // Ignore the following 2 cases:
-            // Spawning a session daemon
-            // Error: Unable to list UST events: Listing UST events failed
-            // or:
-            // Error: Unable to list UST events: Listing UST events failed
-            if (ignoredPattern(result.getErrorOutput(), LTTngControlServiceConstants.LIST_UST_NO_UST_PROVIDER_PATTERN)) {
-                return allProviders;
-            }
-            throw new ExecutionException(Messages.TraceControl_CommandError + command.toString());
-        }
-
-        Document document = getDocumentFromStrings(result.getOutput());
-        NodeList rawProviders = document.getElementsByTagName(MIStrings.PID);
-
-        IUstProviderInfo providerInfo = null;
-
-        for (int i = 0; i < rawProviders.getLength(); i++) {
-            Node provider = rawProviders.item(i);
-            Node name = getFirstOf(provider.getChildNodes(), MIStrings.NAME);
-            if (name == null) {
-                throw new ExecutionException(Messages.TraceControl_MiInvalidProviderError);
-            }
-            providerInfo = new UstProviderInfo(name.getTextContent());
-
-            // Populate provider
-            NodeList infos = provider.getChildNodes();
-            for (int j = 0; j < infos.getLength(); j++) {
-                Node info = infos.item(j);
-                switch (info.getNodeName()) {
-                case MIStrings.PID_ID:
-                    providerInfo.setPid(Integer.parseInt(info.getTextContent()));
-                    break;
-                case MIStrings.EVENTS:
-                    List<IBaseEventInfo> events = new ArrayList<>();
-                    NodeList rawEvents = info.getChildNodes();
-                    getBaseEventInfo(rawEvents, events);
-                    providerInfo.setEvents(events);
-                    break;
-                default:
-                    break;
-                }
-            }
-            allProviders.add(providerInfo);
-        }
-
-        return allProviders;
-    }
-
-    @Override
-    public ISessionInfo createSession(ISessionInfo sessionInfo, IProgressMonitor monitor) throws ExecutionException {
-        if (sessionInfo.isStreamedTrace()) {
-            return createStreamedSession(sessionInfo, monitor);
-        }
-
-        ICommandInput command = prepareSessionCreationCommand(sessionInfo);
-        ICommandResult result = executeCommand(command, monitor);
-
-        Document document = getDocumentFromStrings(result.getOutput());
-        NodeList sessions = document.getElementsByTagName(MIStrings.SESSION);
-
-        // Number of session should be equal to 1
-        if (sessions.getLength() != 1) {
-            throw new ExecutionException(Messages.TraceControl_CommandError + " " + command + "\n" //$NON-NLS-1$//$NON-NLS-2$
-                    + NLS.bind(Messages.TraceControl_UnexpectedNumberOfElementError, MIStrings.SESSION) + " " + sessions.getLength()); //$NON-NLS-1$
-        }
-
-        // Fetch a session from output
-        ISessionInfo outputSession = new SessionInfo(""); //$NON-NLS-1$
-        parseSession(outputSession, sessions.item(0));
-
-        // Verify session name
-        if ((outputSession.getName().equals("")) || (!"".equals(sessionInfo.getName()) && !outputSession.getName().equals(sessionInfo.getName()))) { //$NON-NLS-1$ //$NON-NLS-2$
-            // Unexpected name returned
-            throw new ExecutionException(Messages.TraceControl_CommandError + " " + command + "\n" + //$NON-NLS-1$ //$NON-NLS-2$
-                    Messages.TraceControl_UnexpectedNameError + ": " + outputSession.getName()); //$NON-NLS-1$
-        }
-
-        // Verify session path
-        if (!sessionInfo.isSnapshotSession() &&
-                ((outputSession.getSessionPath() == null) || ((sessionInfo.getSessionPath() != null) && (!outputSession.getSessionPath().contains(sessionInfo.getSessionPath()))))) {
-            // Unexpected path
-            throw new ExecutionException(Messages.TraceControl_CommandError + " " + command + "\n" + //$NON-NLS-1$ //$NON-NLS-2$
-                    Messages.TraceControl_UnexpectedPathError + ": " + outputSession.getName()); //$NON-NLS-1$
-        }
-
-        if (sessionInfo.isSnapshotSession()) {
-            // Make it a snapshot session - content of snapshot info need to
-            // set afterwards using getSession() or getSnapshotInfo()
-            outputSession.setSnapshotInfo(new SnapshotInfo("")); //$NON-NLS-1$
-        }
-
-        return outputSession;
-    }
-
-    private @NonNull ISessionInfo createStreamedSession(ISessionInfo sessionInfo, IProgressMonitor monitor) throws ExecutionException {
-
-        ICommandInput command = prepareStreamedSessionCreationCommand(sessionInfo);
-
-        ICommandResult result = executeCommand(command, monitor);
-
-        Document document = getDocumentFromStrings(result.getOutput());
-        NodeList sessions = document.getElementsByTagName(MIStrings.SESSION);
-
-        // Number of session should be equal to 1
-        if (sessions.getLength() != 1) {
-            throw new ExecutionException(Messages.TraceControl_CommandError + " " + command + "\n" //$NON-NLS-1$//$NON-NLS-2$
-                    + NLS.bind(Messages.TraceControl_UnexpectedNumberOfElementError, MIStrings.SESSION) + " " + sessions.getLength()); //$NON-NLS-1$
-        }
-
-        // Fetch a session from output
-        ISessionInfo outputSession = new SessionInfo(""); //$NON-NLS-1$
-        parseSession(outputSession, sessions.item(0));
-
-        // Verify session name
-        if ((outputSession.getName().equals("")) || (!"".equals(sessionInfo.getName()) && !outputSession.getName().equals(sessionInfo.getName()))) { //$NON-NLS-1$ //$NON-NLS-2$
-            // Unexpected name returned
-            throw new ExecutionException(Messages.TraceControl_CommandError + " " + command + "\n" + //$NON-NLS-1$ //$NON-NLS-2$
-                    Messages.TraceControl_UnexpectedNameError + ": " + outputSession.getName()); //$NON-NLS-1$
-        }
-
-        sessionInfo.setName(outputSession.getName());
-        sessionInfo.setStreamedTrace(true);
-
-        // Verify session path
-        if (sessionInfo.getNetworkUrl() != null) {
-            if (!sessionInfo.isSnapshotSession() && (outputSession.getSessionPath() == null)) {
-                // Unexpected path
-                throw new ExecutionException(Messages.TraceControl_CommandError + " " + command + "\n" + //$NON-NLS-1$ //$NON-NLS-2$
-                        Messages.TraceControl_UnexpectedPathError + ": " + outputSession.getName()); //$NON-NLS-1$
-            }
-
-            if (sessionInfo.isSnapshotSession()) {
-                sessionInfo.setStreamedTrace(false);
-            } else {
-                sessionInfo.setSessionPath(outputSession.getSessionPath());
-                // Check file protocol
-                Matcher matcher = LTTngControlServiceConstants.TRACE_FILE_PROTOCOL_PATTERN.matcher(outputSession.getSessionPath());
-                if (matcher.matches()) {
-                    sessionInfo.setStreamedTrace(false);
-                }
-            }
-        }
-
-        // When using controlUrl and dataUrl the full session path is not known
-        // yet
-        // and will be set later on when listing the session
-        return sessionInfo;
-    }
-
-    @Override
-    public void destroySession(String sessionName, IProgressMonitor monitor) throws ExecutionException {
-        ICommandInput command = createCommand(LTTngControlServiceConstants.COMMAND_DESTROY_SESSION, sessionName);
-
-        ICommandResult result = executeCommand(command, monitor, false);
-        List<String> errorOutput = result.getErrorOutput();
-
-        if (isError(result)) {
-            // Don't treat this as an error
-            if (ignoredPattern(errorOutput, LTTngControlServiceConstants.SESSION_NOT_FOUND_ERROR_PATTERN)) {
-                return;
-
-            }
-            throw new ExecutionException(Messages.TraceControl_CommandError + " " + command.toString() + "\n" + result.toString()); //$NON-NLS-1$ //$NON-NLS-2$
-        }
-
-        // Check for action effect
-        Document doc = getDocumentFromStrings(result.getOutput());
-        NodeList sessions = doc.getElementsByTagName(MIStrings.SESSION);
-        if (sessions.getLength() != 1) {
-            throw new ExecutionException(NLS.bind(Messages.TraceControl_MiInvalidNumberOfElementError, MIStrings.SESSION));
-        }
-
-        Node rawSessionName = getFirstOf(sessions.item(0).getChildNodes(), MIStrings.NAME);
-        if (rawSessionName == null) {
-            throw new ExecutionException(Messages.TraceControl_MiMissingRequiredError);
-        }
-
-        // Validity check
-        if (!rawSessionName.getTextContent().equals(sessionName)) {
-            throw new ExecutionException(NLS.bind(Messages.TraceControl_UnexpectedValueError, rawSessionName.getTextContent(), sessionName));
-        }
-    }
-
-    @Override
-    protected ICommandInput createCommand(String... strings) {
-        ICommandInput command = getCommandShell().createCommand();
-        command.add(LTTngControlServiceConstants.CONTROL_COMMAND);
-        List<String> groupOption = getTracingGroupOption();
-        if (!groupOption.isEmpty()) {
-            command.addAll(groupOption);
-        }
-        command.add(LTTngControlServiceConstants.CONTROL_COMMAND_MI_OPTION);
-        command.add(LTTngControlServiceConstants.CONTROL_COMMAND_MI_XML);
-        for (String string : strings) {
-            command.add(checkNotNull(string));
-        }
-        return command;
-    }
-
-    /**
-     * @param xmlBaseEvents
-     *            a Node list of base xml event element
-     * @param events
-     *            list of event generated by the parsing of the xml event
-     *            element
-     * @throws ExecutionException
-     *             when a raw event is not a complete/valid xml event
-     */
-    private static void getBaseEventInfo(NodeList xmlBaseEvents, List<IBaseEventInfo> events) throws ExecutionException {
-        IBaseEventInfo eventInfo = null;
-        for (int i = 0; i < xmlBaseEvents.getLength(); i++) {
-            NodeList rawInfos = xmlBaseEvents.item(i).getChildNodes();
-            // Search for name
-            if (xmlBaseEvents.item(i).getNodeName().equalsIgnoreCase(MIStrings.EVENT)) {
-                Node rawName = getFirstOf(rawInfos, MIStrings.NAME);
-                if (rawName == null) {
-                    throw new ExecutionException(Messages.TraceControl_MiMissingRequiredError);
-                }
-                eventInfo = new BaseEventInfo(rawName.getTextContent());
-
-                // Populate the event
-                for (int j = 0; j < rawInfos.getLength(); j++) {
-                    Node infoNode = rawInfos.item(j);
-                    switch (infoNode.getNodeName()) {
-                    case MIStrings.TYPE:
-                        eventInfo.setEventType(infoNode.getTextContent());
-                        break;
-                    case MIStrings.LOGLEVEL:
-                        eventInfo.setLogLevel(infoNode.getTextContent());
-                        break;
-                    case MIStrings.EVENT_FIELDS:
-                        List<IFieldInfo> fields = new ArrayList<>();
-                        getFieldInfo(infoNode.getChildNodes(), fields);
-                        eventInfo.setFields(fields);
-                        break;
-                    default:
-                        break;
-                    }
-                }
-                events.add(eventInfo);
-            }
-        }
-    }
-
-    /**
-     * @param xmlBaseEvents
-     *            a Node list of xml event element linked to a session
-     * @param events
-     *            list of event generated by the parsing of the xml event
-     *            element
-     * @throws ExecutionException
-     *             when a raw event is not a complete/valid xml event
-     */
-    static void getEventInfo(NodeList xmlEvents, List<IEventInfo> events) throws ExecutionException {
-        IEventInfo eventInfo = null;
-        for (int i = 0; i < xmlEvents.getLength(); i++) {
-            NodeList rawInfos = xmlEvents.item(i).getChildNodes();
-            // Search for name
-            if (xmlEvents.item(i).getNodeName().equalsIgnoreCase(MIStrings.EVENT)) {
-                Node rawName = getFirstOf(rawInfos, MIStrings.NAME);
-                if (rawName == null) {
-                    throw new ExecutionException(Messages.TraceControl_MiMissingRequiredError);
-                }
-
-                eventInfo = new EventInfo(rawName.getTextContent());
-
-                // Basic information
-                for (int j = 0; j < rawInfos.getLength(); j++) {
-                    Node infoNode = rawInfos.item(j);
-                    switch (infoNode.getNodeName()) {
-                    case MIStrings.TYPE:
-                        eventInfo.setEventType(infoNode.getTextContent());
-                        break;
-                    case MIStrings.LOGLEVEL_TYPE:
-                        eventInfo.setLogLevelType(LogLevelType.valueOfString(infoNode.getTextContent()));
-                        break;
-                    case MIStrings.LOGLEVEL:
-                        eventInfo.setLogLevel(TraceLogLevel.valueOfString(infoNode.getTextContent()));
-                        break;
-                    case MIStrings.ENABLED:
-                        eventInfo.setState(TraceEnablement.valueOfString(infoNode.getTextContent()));
-                        break;
-                    case MIStrings.FILTER:
-                        // TODO
-                        // See bug 334 http://bugs.lttng.org/issues/334 from
-                        // LTTng
-                        // For now we emulate the non-mi behavior and simply put
-                        // "with filter"
-                        eventInfo.setFilterExpression("with filter"); //$NON-NLS-1$
-                        break;
-                    case MIStrings.EXCLUSION:
-                        // TODO: Currently not supported by tmf
-                        // ExclusionS element is ignored
-                        break;
-                    default:
-                        break;
-                    }
-                }
-
-                boolean isProbeFunction = (eventInfo.getEventType().equals(TraceEventType.PROBE)) || (eventInfo.getEventType().equals(TraceEventType.FUNCTION));
-                if (isProbeFunction) {
-                    IProbeEventInfo probeEvent = new ProbeEventInfo(eventInfo);
-                    eventInfo = probeEvent;
-
-                    Node rawDataNode = null;
-                    switch (probeEvent.getEventType()) {
-                    case FUNCTION:
-                    case PROBE: {
-                        // get attributes
-                        Node rawAttributes = getFirstOf(rawInfos, MIStrings.ATTRIBUTES);
-                        if (rawAttributes == null) {
-                            throw new ExecutionException(Messages.TraceControl_MiMissingRequiredError);
-                        }
-                        rawDataNode = getFirstOf(rawAttributes.getChildNodes(), MIStrings.PROBE_ATTRIBUTES);
-                        break;
-                    }
-                    case SYSCALL:
-                    case TRACEPOINT:
-                    case UNKNOWN:
-                    default:
-                        throw new ExecutionException(Messages.TraceControl_MiInvalidElementError);
-                    }
-
-                    if (rawDataNode == null) {
-                        throw new ExecutionException(Messages.TraceControl_MiInvalidElementError);
-                    }
-
-                    // Extract info
-                    NodeList rawDatas = rawDataNode.getChildNodes();
-                    for (int j = 0; j < rawDatas.getLength(); j++) {
-                        Node rawData = rawDatas.item(j);
-                        switch (rawData.getNodeName()) {
-                        case MIStrings.SYMBOL_NAME:
-                            probeEvent.setSymbol(rawData.getTextContent());
-                            break;
-                        case MIStrings.ADDRESS:
-                            probeEvent.setAddress(String.format("%#016x", new BigInteger(rawData.getTextContent()))); //$NON-NLS-1$
-                            break;
-                        case MIStrings.OFFSET:
-                            probeEvent.setOffset(String.format("%#016x", new BigInteger(rawData.getTextContent()))); //$NON-NLS-1$
-                            break;
-                        default:
-                            break;
-                        }
-                    }
-                }
-
-                // Add the event
-                events.add(eventInfo);
-            }
-        }
-    }
-
-    /**
-     * @param fieldsList
-     *            a list of xml event_field element
-     * @param fields
-     *            a list of field generated by xml parsing
-     * @throws ExecutionException
-     *             when parsing fail or required elements are missing
-     */
-    private static void getFieldInfo(NodeList fieldsList, List<IFieldInfo> fields) throws ExecutionException {
-        IFieldInfo fieldInfo = null;
-        for (int i = 0; i < fieldsList.getLength(); i++) {
-            Node field = fieldsList.item(i);
-            if (field.getNodeName().equalsIgnoreCase(MIStrings.EVENT_FIELD)) {
-                // Get name
-                Node name = getFirstOf(field.getChildNodes(), MIStrings.NAME);
-                if (name == null) {
-                    throw new ExecutionException(Messages.TraceControl_MiMissingRequiredError);
-                }
-                fieldInfo = new FieldInfo(name.getTextContent());
-
-                // Populate the field information
-                NodeList infos = field.getChildNodes();
-                for (int j = 0; j < infos.getLength(); j++) {
-                    Node info = infos.item(j);
-                    switch (info.getNodeName()) {
-                    case MIStrings.TYPE:
-                        fieldInfo.setFieldType(info.getTextContent());
-                        break;
-                    default:
-                        break;
-                    }
-                }
-                fields.add(fieldInfo);
-            }
-        }
-    }
-
-    /**
-     * Retrieve the fist instance of a given node with tag name equal to tagName
-     * parameter
-     *
-     * @param nodeList
-     *            the list of Node to search against
-     * @param tagName
-     *            the tag name of the desired node
-     * @return the first occurrence of a node with a tag name equals to tagName
-     */
-    private static @Nullable Node getFirstOf(NodeList nodeList, String tagName) {
-        Node node = null;
-        for (int i = 0; i < nodeList.getLength(); i++) {
-            if (NonNullUtils.equalsNullable(nodeList.item(i).getNodeName(), tagName)) {
-                node = nodeList.item(i);
-                break;
-            }
-        }
-        return node;
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/service/LttngVersion.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/service/LttngVersion.java
deleted file mode 100644 (file)
index 92313d4..0000000
+++ /dev/null
@@ -1,156 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2013, 2014 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Jonathan Rajotte - Machine interface support and new information
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.service;
-
-import org.eclipse.jdt.annotation.NonNull;
-import org.osgi.framework.Version;
-
-/**
- * A version implementation with a special compareTo implementation to bypass
- * problems of older implementation of org.osgi.framework.Version.
- *
- * @author Bernd Hufmann
- */
-public class LttngVersion extends Version {
-
-    /** A null version */
-    public static final @NonNull LttngVersion NULL_VERSION = new LttngVersion(Version.emptyVersion.toString());
-
-    private final String fLicense;
-    private final String fCommit;
-    private final String fName;
-    private final String fDescription;
-    private final String fUrl;
-    private final String fFullVersion;
-
-    /**
-     * Constructor
-     *
-     * @param version
-     *            The version string
-     */
-    public LttngVersion(String version) {
-        super(version);
-        fLicense = ""; //$NON-NLS-1$
-        fCommit = ""; //$NON-NLS-1$
-        fName = ""; //$NON-NLS-1$
-        fDescription = ""; //$NON-NLS-1$
-        fUrl = ""; //$NON-NLS-1$
-        fFullVersion = ""; //$NON-NLS-1$
-    }
-
-    /**
-     * @param major
-     *            major version number
-     * @param minor
-     *            minor version number
-     * @param micro
-     *            micro version number
-     * @param license
-     *            licence text of LTTng
-     * @param commit
-     *            current git commit information about LTTng
-     * @param name
-     *            name of the version
-     * @param description
-     *            description of the version
-     * @param url
-     *            url to website
-     * @param fullVersion
-     *            complete string representation of the version
-     */
-    public LttngVersion(int major, int minor, int micro, String license, String commit, String name, String description, String url, String fullVersion) {
-        super(major, minor, micro);
-        fLicense = license;
-        fCommit = commit;
-        fName = name;
-        fDescription = description;
-        fUrl = url;
-        fFullVersion = fullVersion;
-    }
-
-    /**
-     * Special compareTo method to fix problem of older implementations of
-     * org.osgi.framework.Version where {@code Version.compareTo} takes an
-     * {@code Object} instead a {@code Version} as argument.
-     *
-     * @param other
-     *            - Other version to compare
-     * @return a negative integer, zero, or a positive integer if this version
-     *         is less than, equal to, or greater than the specified
-     *         {@code LttngVersion} object.
-     */
-    public int compareTo(LttngVersion other) {
-        if (other == this) { // quicktest
-            return 0;
-        }
-        int result = getMajor() - other.getMajor();
-        if (result != 0) {
-            return result;
-        }
-
-        result = getMinor() - other.getMinor();
-        if (result != 0) {
-            return result;
-        }
-
-        result = getMicro() - other.getMicro();
-        if (result != 0) {
-            return result;
-        }
-        return getQualifier().compareTo(other.getQualifier());
-    }
-
-    /**
-     * @return String representing the lttng license
-     */
-    public String getLicense() {
-        return fLicense;
-    }
-
-    /**
-     * @return commit id of lttng
-     */
-    public String getCommit() {
-        return fCommit;
-    }
-
-    /**
-     * @return name of lttng version
-     */
-    public String getName() {
-        return fName;
-    }
-
-    /**
-     * @return full description of lttng
-     */
-    public String getDescription() {
-        return fDescription;
-    }
-
-    /**
-     * @return url of lttng
-     */
-    public String getUrl() {
-        return fUrl;
-    }
-
-    /**
-     * @return the full_version
-     */
-    public String getFullVersion() {
-        return fFullVersion;
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/service/MIStrings.java b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/service/MIStrings.java
deleted file mode 100644 (file)
index 15c69ef..0000000
+++ /dev/null
@@ -1,578 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2014, 2015 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:
- *   Jonathan Rajotte Julien - Initial API and implementation
- *   Bernd Hufmann - Added null annotations
- *******************************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.control.ui.views.service;
-
-import org.eclipse.jdt.annotation.NonNullByDefault;
-
-
-/**
- * Non-externalized strings for use with the LTTng Control services. This
- * information is extracted from mi_lttng.xsd from lttng-tool libmi.
- *
- * @author Jonathan Rajotte
- */
-@SuppressWarnings("nls")
-@NonNullByDefault
-public interface MIStrings {
-
-    /**
-     * Represent the command_action xml element
-     */
-     String COMMAND_ACTION = "snapshot_action";
-
-    /**
-     * Represent the command_add_context xml element
-     */
-     String COMMAND_ADD_CONTEXT = "add-context";
-
-    /**
-     * Represent the command_calibrate xml element
-     */
-     String COMMAND_CALIBRATE = "calibrate";
-
-    /**
-     * Represent the command_create xml element
-     */
-     String COMMAND_CREATE = "create";
-
-    /**
-     * Represent the command_destroy xml element
-     */
-     String COMMAND_DESTROY = "destroy";
-
-    /**
-     * Represent the command_disable_channel xml element
-     */
-     String COMMAND_DISABLE_CHANNEL = "disable-channel";
-
-    /**
-     * Represent the command_disable_event xml element
-     */
-     String COMMAND_DISABLE_EVENT = "disable-event";
-
-    /**
-     * Represent the command_enable_channels xml element
-     */
-     String COMMAND_ENABLE_CHANNELS = "enable-channel";
-
-    /**
-     * Represent the command_enable_event xml element
-     */
-     String COMMAND_ENABLE_EVENT = "enable-event";
-
-    /**
-     * Represent the command_list xml element
-     */
-     String COMMAND_LIST = "list";
-
-    /**
-     * Represent the command_load xml element
-     */
-     String COMMAND_LOAD = "load";
-
-    /**
-     * Represent the command_name xml element
-     */
-     String COMMAND_NAME = "name";
-
-    /**
-     * Represent the command_output xml element
-     */
-     String COMMAND_OUTPUT = "output";
-
-    /**
-     * Represent the command_save xml element
-     */
-     String COMMAND_SAVE = "save";
-
-    /**
-     * Represent the command_set_session xml element
-     */
-     String COMMAND_SET_SESSION = "set-session";
-
-    /**
-     * Represent the command_snapshot xml element
-     */
-     String COMMAND_SNAPSHOT = "snapshot";
-
-    /**
-     * Represent the command_snapshot_add xml element
-     */
-     String COMMAND_SNAPSHOT_ADD = "add_snapshot";
-
-    /**
-     * Represent the command_snapshot_del xml element
-     */
-     String COMMAND_SNAPSHOT_DEL = "del_snapshot";
-
-    /**
-     * Represent the command_snapshot_list xml element
-     */
-     String COMMAND_SNAPSHOT_LIST = "list_snapshot";
-
-    /**
-     * Represent the command_snapshot_record xml element
-     */
-     String COMMAND_SNAPSHOT_RECORD = "record_snapshot";
-
-    /**
-     * Represent the command_start xml element
-     */
-     String COMMAND_START = "start";
-
-    /**
-     * Represent the command_stop xml element
-     */
-     String COMMAND_STOP = "stop";
-
-    /**
-     * Represent the command_success xml element
-     */
-     String COMMAND_SUCCESS = "success";
-
-    /**
-     * Represent the command_version xml element
-     */
-     String COMMAND_VERSION = "version";
-
-    /**
-     * Represent the version xml element
-     */
-     String VERSION = "version";
-
-    /**
-     * Represent the version_commit xml element
-     */
-     String VERSION_COMMIT = "commit";
-
-    /**
-     * Represent the version_description xml element
-     */
-     String VERSION_DESCRIPTION = "description";
-
-    /**
-     * Represent the version_license xml element
-     */
-     String VERSION_LICENSE = "license";
-
-    /**
-     * Represent the version_major xml element
-     */
-     String VERSION_MAJOR = "major";
-
-    /**
-     * Represent the version_minor xml element
-     */
-     String VERSION_MINOR = "minor";
-
-    /**
-     * Represent the version_patch_level xml element
-     */
-     String VERSION_PATCH_LEVEL = "patchLevel";
-
-    /**
-     * Represent the version_str xml element
-     */
-     String VERSION_STR = "string";
-
-    /**
-     * Represent the version_web xml element
-     */
-     String VERSION_WEB = "url";
-
-    /**
-     * Represent the version_name xml element
-     */
-     String VERSION_NAME = "name";
-    /* String related to a lttng_event_field */
-
-    /**
-     * Represent the event_field xml element
-     */
-     String EVENT_FIELD = "event_field";
-
-    /**
-     * Represent the event_fields xml element
-     */
-     String EVENT_FIELDS = "event_fields";
-
-    /**
-     * Represent the perf_counter_context xml element
-     */
-     String PERF_COUNTER_CONTEXT = "perf_counter_context";
-
-     // ------------------------------------------------------------------------
-     // String related to pid
-     // ------------------------------------------------------------------------/
-
-    /**
-     * Represent the pids xml element
-     */
-     String PIDS = "pids";
-
-    /**
-     * Represent the pid xml element
-     */
-     String PID = "pid";
-
-    /**
-     * Represent the pid_id xml element
-     */
-     String PID_ID = "id";
-
-     // ------------------------------------------------------------------------
-     // String related to save command
-     // ------------------------------------------------------------------------
-    /**
-     * Represent the save xml element
-     */
-     String SAVE = "save";
-
-     // ------------------------------------------------------------------------
-     // String related to load command
-     // ------------------------------------------------------------------------
-    /**
-     * Represent the load xml element
-     */
-     String LOAD = "load";
-
-     // ------------------------------------------------------------------------
-     // String related to general element of mi_lttng
-     // ------------------------------------------------------------------------
-    /**
-     * Represent the empty xml element
-     */
-     String EMPTY = "";
-
-    /**
-     * Represent the id xml element
-     */
-     String ID = "id";
-
-    /**
-     * Represent the nowrite xml element
-     */
-     String NOWRITE = "nowrite";
-
-    /**
-     * Represent the success xml element
-     */
-     String SUCCESS = "success";
-
-    /**
-     * Represent the type_enum xml element
-     */
-     String TYPE_ENUM = "ENUM";
-
-    /**
-     * Represent the type_float xml element
-     */
-     String TYPE_FLOAT = "FLOAT";
-
-    /**
-     * Represent the type_integer xml element
-     */
-     String TYPE_INTEGER = "INTEGER";
-
-    /**
-     * Represent the type_other xml element
-     */
-     String TYPE_OTHER = "OTHER";
-
-    /**
-     * Represent the type_string xml element
-     */
-     String TYPE_STRING = "STRING";
-
-     // ------------------------------------------------------------------------
-     // String related to lttng_calibrate
-     // ------------------------------------------------------------------------
-    /**
-     * Represent the calibrate xml element
-     */
-     String CALIBRATE = "calibrate";
-
-    /**
-     * Represent the calibrate_function xml element
-     */
-     String CALIBRATE_FUNCTION = "FUNCTION";
-
-     // ------------------------------------------------------------------------
-     // String related to a lttng_snapshot_output
-     // ------------------------------------------------------------------------
-    /**
-     * Represent the snapshot_ctrl_url xml element
-     */
-     String SNAPSHOT_CTRL_URL = "ctrl_url";
-
-    /**
-     * Represent the snapshot_data_url xml element
-     */
-     String SNAPSHOT_DATA_URL = "data_url";
-
-    /**
-     * Represent the snapshot_max_size xml element
-     */
-
-     String SNAPSHOT_MAX_SIZE = "max_size";
-
-    /**
-     * Represent the snapshot_n_ptr xml element
-     */
-     String SNAPSHOT_N_PTR = "n_ptr";
-
-    /**
-     * Represent the snapshot_session_name xml element
-     */
-     String SNAPSHOT_SESSION_NAME = "session_name";
-
-    /**
-     * Represent the snapshots xml element
-     */
-     String SNAPSHOTS = "snapshots";
-    /**
-     * Represent the channel xml element
-     */
-     String CHANNEL = "channel";
-
-    /**
-     * Represent the channels xml element
-     */
-     String CHANNELS = "channels";
-
-    /**
-     * Represent the domain xml element
-     */
-     String DOMAIN = "domain";
-
-    /**
-     * Represent the domains xml element
-     */
-     String DOMAINS = "domains";
-
-    /**
-     * Represent the event xml element
-     */
-     String EVENT = "event";
-
-    /**
-     * Represent the events xml element
-     */
-     String EVENTS = "events";
-
-    /**
-     * Represent the context xml element
-     */
-     String CONTEXT = "context";
-
-    /**
-     * Represent the contexts xml element
-     */
-     String CONTEXTS = "contexts";
-
-    /**
-     * Represent the attributes xml element
-     */
-     String ATTRIBUTES = "attributes";
-
-    /**
-     * Represent the exclusion xml element
-     */
-     String EXCLUSION = "exclusion";
-
-    /**
-     * Represent the exclusions xml element
-     */
-     String EXCLUSIONS = "exclusions";
-
-    /**
-     * Represent the function_attributes xml element
-     */
-     String FUNCTION_ATTRIBUTES = "function_attributes";
-
-    /**
-     * Represent the probe_attributes xml element
-     */
-     String PROBE_ATTRIBUTES = "probe_attributes";
-
-    /**
-     * Represent the symbol_name xml element
-     */
-     String SYMBOL_NAME = "symbol_name";
-
-    /**
-     * Represent the address xml element
-     */
-     String ADDRESS = "address";
-
-    /**
-     * Represent the offset xml element
-     */
-     String OFFSET = "offset";
-
-    /**
-     * Represent the name xml element
-     */
-     String NAME = "name";
-
-    /**
-     * Represent the enabled xml element
-     */
-     String ENABLED = "enabled";
-
-    /**
-     * Represent the overwrite_mode xml element
-     */
-     String OVERWRITE_MODE = "overwrite_mode";
-
-    /**
-     * Represent the subbuf_size xml element
-     */
-     String SUBBUF_SIZE = "subbuffer_size";
-
-    /**
-     * Represent the num_subbuf xml element
-     */
-     String NUM_SUBBUF = "subbuffer_count";
-
-    /**
-     * Represent the switch_timer_interval xml element
-     */
-     String SWITCH_TIMER_INTERVAL = "switch_timer_interval";
-
-    /**
-     * Represent the read_timer_interval xml element
-     */
-     String READ_TIMER_INTERVAL = "read_timer_interval";
-
-    /**
-     * Represent the output xml element
-     */
-     String OUTPUT = "output";
-
-    /**
-     * Represent the output_type xml element
-     */
-     String OUTPUT_TYPE = "output_type";
-
-    /**
-     * Represent the tracefile_size xml element
-     */
-     String TRACEFILE_SIZE = "tracefile_size";
-
-    /**
-     * Represent the tracefile_count xml element
-     */
-     String TRACEFILE_COUNT = "tracefile_count";
-
-    /**
-     * Represent the live_timer_interval xml element
-     */
-     String LIVE_TIMER_INTERVAL = "live_timer_interval";
-
-    /**
-     * Represent the type xml element
-     */
-     String TYPE = "type";
-
-    /**
-     * Represent the buffer_type xml element
-     */
-     String BUFFER_TYPE = "buffer_type";
-
-    /**
-     * Represent the session xml element
-     */
-     String SESSION = "session";
-
-    /**
-     * Represent the sessions xml element
-     */
-     String SESSIONS = "sessions";
-
-    /**
-     * Represent the perf xml element
-     */
-     String PERF = "perf";
-
-    /**
-     * Represent the config xml element
-     */
-     String CONFIG = "config";
-
-    /**
-     * Represent the started xml element
-     */
-     String STARTED = "started";
-
-    /**
-     * Represent the snapshot_mode xml element
-     */
-     String SNAPSHOT_MODE = "snapshot_mode";
-
-    /**
-     * Represent the loglevel xml element
-     */
-     String LOGLEVEL = "loglevel";
-
-    /**
-     * Represent the loglevel_type xml element
-     */
-     String LOGLEVEL_TYPE = "loglevel_type";
-
-    /**
-     * Represent the filter xml element
-     */
-     String FILTER = "filter";
-
-    /**
-     * Represent the snapshot_outputs xml element
-     */
-     String SNAPSHOT_OUTPUTS = "snapshot";
-
-    /**
-     * Represent the consumer_output xml element
-     */
-     String CONSUMER_OUTPUT = "consumer_output";
-
-    /**
-     * Represent the destination xml element
-     */
-     String DESTINATION = "destination";
-
-    /**
-     * Represent the path xml element
-     */
-     String PATH = "path";
-
-    /**
-     * Represent the net_output xml element
-     */
-     String NET_OUTPUT = "net_output";
-
-    /**
-     * Represent the control_uri xml element
-     */
-     String CONTROL_URI = "control_uri";
-
-    /**
-     * Represent the data_uri xml element
-     */
-     String DATA_URI = "data_uri";
-
-    /**
-     * Represent the max_size xml element
-     */
-    String MAX_SIZE = "max_size";
-}
diff --git a/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/service/mi_lttng.xsd b/org.eclipse.tracecompass.lttng2.control.ui/src/org/eclipse/tracecompass/internal/lttng2/control/ui/views/service/mi_lttng.xsd
deleted file mode 100644 (file)
index f5fc729..0000000
+++ /dev/null
@@ -1,495 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-Copyright (c) 2014 - Oliver Cotte <olivier.cotte@polymtl.ca>
-                   - Jonathan Rajotte <jonathan.r.julien@gmail.com>
-
-Permission is hereby granted, free of charge, to any person obtaining a copy
-of this software and associated documentation files (the "Software"), to deal
-in the Software without restriction, including without limitation the rights
-to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-copies of the Software, and to permit persons to whom the Software is
-furnished to do so, subject to the following conditions:
-
-The above copyright notice and this permission notice shall be included in
-all copies or substantial portions of the Software.
-
-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-THE SOFTWARE.
--->
-<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
-       elementFormDefault="qualified" version="2.5">
-
-       <!-- Maps to the uint32_t type -->
-       <xs:simpleType name="uint32_type">
-               <xs:restriction base="xs:integer">
-                       <xs:minInclusive value="0" />
-                       <xs:maxInclusive value="4294967295" />
-               </xs:restriction>
-       </xs:simpleType>
-
-       <!-- Maps to the uint64_t type -->
-       <xs:simpleType name="uint64_type">
-               <xs:restriction base="xs:integer">
-                       <xs:minInclusive value="0" />
-                       <xs:maxInclusive value="18446744073709551615" />
-               </xs:restriction>
-       </xs:simpleType>
-
-       <!-- Maps to the char name[LTTNG_SYMBOL_NAME_LEN] -->
-       <xs:simpleType name="name_type">
-               <xs:restriction base="xs:string">
-                       <xs:maxLength value="255" />
-               </xs:restriction>
-       </xs:simpleType>
-
-       <!-- Maps to the lttng_event_type enum -->
-       <xs:simpleType name="event_type_type">
-               <xs:restriction base="xs:string">
-                       <xs:enumeration value="ALL" />
-                       <xs:enumeration value="TRACEPOINT" />
-                       <xs:enumeration value="PROBE" />
-                       <xs:enumeration value="FUNCTION" />
-                       <xs:enumeration value="FUNCTION_ENTRY" />
-                       <xs:enumeration value="NOOP" />
-                       <xs:enumeration value="SYSCALL" />
-                       <xs:enumeration value="KPROBE" />
-                       <xs:enumeration value="KRETPROBE" />
-               </xs:restriction>
-       </xs:simpleType>
-
-       <!-- Maps to the lttng_event_field_type enum -->
-       <xs:simpleType name="event_field_type_type">
-               <xs:restriction base="xs:string">
-                       <xs:enumeration value="OTHER" />
-                       <xs:enumeration value="INTEGER" />
-                       <xs:enumeration value="ENUM" />
-                       <xs:enumeration value="FLOAT" />
-                       <xs:enumeration value="STRING" />
-               </xs:restriction>
-       </xs:simpleType>
-
-       <!-- Maps to the lttng_loglevel_type enum -->
-       <xs:simpleType name="loglevel_type">
-               <xs:restriction base="xs:string">
-                       <xs:enumeration value="ALL" />
-                       <xs:enumeration value="RANGE" />
-                       <xs:enumeration value="SINGLE" />
-                       <xs:enumeration value="UNKNOWN" />
-               </xs:restriction>
-       </xs:simpleType>
-
-       <!-- Maps to the lttng_event_context_type enum -->
-       <xs:simpleType name="context_type_type">
-               <xs:restriction base="xs:string">
-                       <xs:enumeration value="PERF_COUNTER" />
-                       <xs:enumeration value="PERF_CPU_COUNTER" />
-                       <xs:enumeration value="PERF_THREAD_COUNTER" />
-                       <xs:enumeration value="PID" />
-                       <xs:enumeration value="PROCNAME" />
-                       <xs:enumeration value="PRIO" />
-                       <xs:enumeration value="NICE" />
-                       <xs:enumeration value="VPID" />
-                       <xs:enumeration value="TID" />
-                       <xs:enumeration value="VTID" />
-                       <xs:enumeration value="PPID" />
-                       <xs:enumeration value="VPPID" />
-                       <xs:enumeration value="PTHREAD_ID" />
-                       <xs:enumeration value="HOSTNAME" />
-                       <xs:enumeration value="IP" />
-               </xs:restriction>
-       </xs:simpleType>
-
-       <!-- Maps to loglevel_string char * -->
-       <xs:simpleType name="loglevel_string_type">
-               <xs:restriction base="xs:string">
-                       <xs:enumeration value="" />
-                       <xs:enumeration value="TRACE_EMERG" />
-                       <xs:enumeration value="TRACE_ALERT" />
-                       <xs:enumeration value="TRACE_CRIT" />
-                       <xs:enumeration value="TRACE_ERR" />
-                       <xs:enumeration value="TRACE_WARNING" />
-                       <xs:enumeration value="TRACE_NOTICE" />
-                       <xs:enumeration value="TRACE_INFO" />
-                       <xs:enumeration value="TRACE_DEBUG_SYSTEM" />
-                       <xs:enumeration value="TRACE_DEBUG_PROGRAM" />
-                       <xs:enumeration value="TRACE_DEBUG_PROCESS" />
-                       <xs:enumeration value="TRACE_DEBUG_MODULE" />
-                       <xs:enumeration value="TRACE_DEBUG_UNIT" />
-                       <xs:enumeration value="TRACE_DEBUG_FUNCTION" />
-                       <xs:enumeration value="TRACE_DEBUG_LINE" />
-                       <xs:enumeration value="TRACE_DEBUG" />
-                       <xs:enumeration value="JUL_OFF" />
-                       <xs:enumeration value="JUL_SEVERE" />
-                       <xs:enumeration value="JUL_WARNING" />
-                       <xs:enumeration value="JUL_INFO" />
-                       <xs:enumeration value="JUL_CONFIG" />
-                       <xs:enumeration value="JUL_FINE" />
-                       <xs:enumeration value="JUL_FINER" />
-                       <xs:enumeration value="JUL_FINEST" />
-                       <xs:enumeration value="JUL_ALL" />
-                       <xs:enumeration value="LOG4J_OFF" />
-                       <xs:enumeration value="LOG4J_FATAL" />
-                       <xs:enumeration value="LOG4J_ERROR" />
-                       <xs:enumeration value="LOG4J_WARN" />
-                       <xs:enumeration value="LOG4J_INFO" />
-                       <xs:enumeration value="LOG4J_DEBUG" />
-                       <xs:enumeration value="LOG4J_TRACE" />
-                       <xs:enumeration value="LOG4J_ALL" />
-                       <xs:enumeration value="UNKNOWN" />
-               </xs:restriction>
-       </xs:simpleType>
-
-       <!-- Maps to the lttng_calibrate_type enum -->
-       <xs:simpleType name="calibrate_type_type">
-               <xs:restriction base="xs:string">
-                       <xs:enumeration value="FUNCTION" />
-               </xs:restriction>
-       </xs:simpleType>
-
-       <!-- Maps to the lttng_event_probe_attr struct -->
-       <xs:complexType name="event_probe_attributes_type">
-               <xs:all>
-                       <xs:element name="address" type="uint64_type" minOccurs="0" />
-                       <xs:element name="offset" type="uint64_type" minOccurs="0" />
-                       <xs:element name="symbol_name" type="name_type" minOccurs="0" />
-               </xs:all>
-       </xs:complexType>
-
-       <!-- Maps to the lttng_event_function_attr struct -->
-       <xs:complexType name="event_ftrace_attributes_type">
-               <xs:all>
-                       <xs:element name="symbol_name" type="name_type" />
-               </xs:all>
-       </xs:complexType>
-
-       <!-- Maps to per event type configuration -->
-       <xs:complexType name="event_attributes_type">
-               <xs:choice>
-                       <xs:element name="probe_attributes" type="event_probe_attributes_type" />
-                       <xs:element name="function_attributes" type="event_ftrace_attributes_type" />
-               </xs:choice>
-       </xs:complexType>
-
-       <!-- Maps to exclusion type -->
-       <xs:complexType name="event_exclusion_list_type">
-               <xs:sequence>
-                       <xs:element name="exclusion" type="xs:string" minOccurs="0" maxOccurs="unbounded"/>
-               </xs:sequence>
-       </xs:complexType>
-
-       <!-- Maps to lttng_event struct -->
-       <xs:complexType name="event_type">
-               <xs:all>
-                       <xs:element name="type" type="event_type_type" default="TRACEPOINT" minOccurs="0" />
-                       <xs:element name="name" type="name_type" minOccurs="0" />
-                       <xs:element name="loglevel_type" type="loglevel_type" default="ALL" minOccurs="0" />
-                       <xs:element name="loglevel" type="loglevel_string_type" default="" minOccurs="0" />
-                       <xs:element name="enabled" type="xs:boolean" default="false" minOccurs="0" />
-                       <xs:element name="filter" type="xs:boolean" minOccurs="0" />
-                       <xs:element name="exclusion" type="xs:boolean" minOccurs="0" />
-                       <xs:element name="exclusions" type="event_exclusion_list_type" minOccurs="0"/>
-                       <xs:element name="attributes" type="event_attributes_type" minOccurs="0" />
-                       <xs:element name="event_fields" type="event_fields_type" minOccurs="0" />
-                       <xs:element name="success" type="xs:boolean" minOccurs="0" />
-               </xs:all>
-       </xs:complexType>
-
-       <!-- Maps to mi_lttng_version struct -->
-       <xs:complexType name="version_type">
-               <xs:all>
-                       <xs:element name="name" type="name_type" />
-                       <xs:element name="string" type="name_type" />
-                       <xs:element name="major" type="uint32_type" />
-                       <xs:element name="url" type="xs:string" />
-                       <xs:element name="minor" type="uint32_type" />
-                       <xs:element name="commit" type="xs:string" />
-                       <xs:element name="license" type="xs:string" />
-                       <xs:element name="patchLevel" type="uint32_type" />
-                       <xs:element name="description" type="xs:string" />
-               </xs:all>
-       </xs:complexType>
-
-       <!-- Maps to an array of event -->
-       <xs:complexType name="event_list_type">
-               <xs:sequence>
-                       <xs:element name="event" type="event_type" minOccurs="0" maxOccurs="unbounded" />
-               </xs:sequence>
-       </xs:complexType>
-
-       <!-- Maps to the lttng_domain_type enum -->
-       <xs:simpleType name="domain_type_type">
-               <xs:restriction base="xs:string">
-                       <xs:enumeration value="KERNEL"/>
-                       <xs:enumeration value="UST"/>
-                       <xs:enumeration value="JUL"/>
-                       <xs:enumeration value="LOG4J"/>
-               </xs:restriction>
-       </xs:simpleType>
-
-       <!-- Maps to the lttng_buffer_type enum -->
-       <xs:simpleType name="domain_buffer_type">
-               <xs:restriction base="xs:string">
-                       <xs:enumeration value="PER_PID"/>
-                       <xs:enumeration value="PER_UID"/>
-                       <xs:enumeration value="GLOBAL"/>
-               </xs:restriction>
-       </xs:simpleType>
-
-       <!-- Maps to the type mode of a channel -->
-       <xs:simpleType name="channel_overwrite_mode_type">
-               <xs:restriction base="xs:string">
-                       <xs:enumeration value="DISCARD" />
-                       <xs:enumeration value="OVERWRITE" />
-               </xs:restriction>
-       </xs:simpleType>
-
-       <!-- Maps to the lttng_event_output enum -->
-       <xs:simpleType name="event_output_type">
-               <xs:restriction base="xs:string">
-                       <xs:enumeration value="SPLICE" />
-                       <xs:enumeration value="MMAP" />
-               </xs:restriction>
-       </xs:simpleType>
-
-       <!-- map to a pid -->
-       <xs:complexType name="pid_type">
-               <xs:all>
-                       <xs:element name="id" type="xs:int" />
-                       <xs:element name="name" type="name_type" />
-                       <xs:element name="events" type="event_list_type" minOccurs="0" />
-               </xs:all>
-       </xs:complexType>
-
-       <!-- maps to an array of pid -->
-       <xs:complexType name="pids_type">
-               <xs:sequence>
-                       <xs:element name="pid" type="pid_type" minOccurs="0" maxOccurs="unbounded" />
-               </xs:sequence>
-       </xs:complexType>
-
-       <!-- Maps to struct lttng_domain and contains channels -->
-       <xs:complexType name="domain_type">
-               <xs:all>
-                       <xs:element name="type" type="domain_type_type" />
-                       <xs:element name="buffer_type" type="domain_buffer_type" />
-                       <xs:element name="pids" type="pids_type" minOccurs="0" />
-                       <xs:element name="channels" type="channels_type" minOccurs="0" />
-                       <xs:element name="events" type="event_list_type" minOccurs="0" />
-               </xs:all>
-       </xs:complexType>
-
-       <!-- Maps to struct lttng_channel -->
-       <xs:complexType name="channel_type">
-               <xs:all>
-                       <xs:element name="name" type="name_type" />
-                       <xs:element name="enabled" type="xs:boolean" default="true" minOccurs="0" />
-                       <xs:element name="attributes" type="channel_attributes_type" minOccurs="0" />
-                       <xs:element name="events" type="event_list_type" minOccurs="0" />
-                       <xs:element name="success" type="xs:boolean" default="false" minOccurs="0" />
-               </xs:all>
-       </xs:complexType>
-
-       <!-- Maps to struct lttng_channel_attr -->
-       <xs:complexType name="channel_attributes_type">
-               <xs:all>
-                       <xs:element name="overwrite_mode" type="channel_overwrite_mode_type" default="DISCARD" minOccurs="0" />
-                       <xs:element name="subbuffer_size" type="uint64_type" minOccurs="0" /> <!-- bytes -->
-                       <xs:element name="subbuffer_count" type="uint64_type" default="4" minOccurs="0" />
-                       <xs:element name="switch_timer_interval" type="uint32_type" default="0" minOccurs="0" />  <!-- usec -->
-                       <xs:element name="read_timer_interval" type="uint32_type" />  <!-- usec -->
-                       <xs:element name="output_type" type="event_output_type" />
-                       <xs:element name="tracefile_size" type="uint64_type" default="0" minOccurs="0" /> <!-- bytes -->
-                       <xs:element name="tracefile_count" type="uint64_type" default="0" minOccurs="0" />
-                       <xs:element name="live_timer_interval" type="uint32_type" default="0" minOccurs="0" /> <!-- usec -->
-               </xs:all>
-       </xs:complexType>
-
-       <!-- Maps to struct lttng_snapshot_output -->
-       <xs:complexType name="snapshot_type">
-               <xs:all>
-                       <xs:element name="id" type="uint32_type" minOccurs="0" />
-                       <xs:element name="max_size" type="uint64_type" minOccurs="0" />
-                       <xs:element name="name" type="name_type" minOccurs="0" />
-                       <xs:element name="session_name" type="name_type" minOccurs="0" />
-                       <xs:element name="ctrl_url" type="name_type" minOccurs="0" />
-                       <xs:element name="data_url" type="name_type" minOccurs="0" />
-               </xs:all>
-       </xs:complexType>
-
-       <xs:complexType name="snapshots_type">
-               <xs:sequence>
-                       <xs:element name="snapshot" type="snapshot_type" minOccurs="0" maxOccurs="unbounded" />
-               </xs:sequence>
-       </xs:complexType>
-
-       <xs:complexType name="channels_type">
-               <xs:sequence>
-                       <xs:element name="channel" type="channel_type" minOccurs="0" maxOccurs="unbounded" />
-               </xs:sequence>
-       </xs:complexType>
-
-       <!-- Maps to a lttng_session -->
-       <xs:complexType name="session_type">
-               <xs:all>
-                       <xs:element name="name" type="name_type" />
-                       <xs:element name="path" type="name_type" minOccurs="0" />
-                       <xs:element name="enabled" type="xs:boolean" default="false" minOccurs="0" />
-                       <xs:element name="snapshot_mode" type="uint32_type" minOccurs="0" />
-                       <xs:element name="live_timer_interval" type="uint32_type" minOccurs="0" />
-                       <xs:element name="channels" type="channels_type" minOccurs="0" />
-                       <xs:element name="domains" type="domains_type" minOccurs="0" />
-                       <xs:element name="snapshots" type="snapshots_type" minOccurs="0" />
-               </xs:all>
-       </xs:complexType>
-
-       <!-- Maps to a lttng_event_field -->
-       <xs:complexType name="event_field_type">
-               <xs:all>
-                       <xs:element name="name" type="name_type" />
-                       <xs:element name="type" type="event_field_type_type" />
-                       <xs:element name="nowrite" type="xs:int" />
-               </xs:all>
-       </xs:complexType>
-
-       <!-- Map to the save command -->
-       <xs:complexType name="save_type">
-               <xs:all>
-                       <xs:element name="session" type="session_type" />
-                       <xs:element name="path" type="name_type" />
-               </xs:all>
-       </xs:complexType>
-
-       <!-- Map to the load command -->
-       <xs:complexType name="load_type">
-               <xs:all>
-                       <xs:element name="session" type="session_type" />
-                       <xs:element name="path" type="name_type" />
-               </xs:all>
-       </xs:complexType>
-
-       <!-- Maps to struct lttng_calibrate -->
-       <xs:complexType name="calibrate_type">
-               <xs:all>
-                       <xs:element name="type" type="calibrate_type_type" />
-               </xs:all>
-       </xs:complexType>
-
-       <!-- Map to lttng_event_perf_counter_ctx -->
-       <xs:complexType name="perf_counter_context_type">
-               <xs:all>
-                       <xs:element name="type" type="uint32_type" />
-                       <xs:element name="config" type="uint64_type" />
-                       <xs:element name="name" type="name_type" />
-               </xs:all>
-       </xs:complexType>
-
-       <!-- Map to lttng_event_context -->
-       <xs:complexType name="context_type">
-               <xs:all>
-                       <xs:element name="type" type="context_type_type" />
-                       <xs:element name="perf_counter_context" type="perf_counter_context_type" minOccurs="0" />
-                       <xs:element name="success" type="xs:boolean" default="false" minOccurs="0" />
-               </xs:all>
-       </xs:complexType>
-
-       <!-- Maps to an array of domain -->
-       <xs:complexType name="domains_type">
-               <xs:sequence>
-                       <xs:element name="domain" type="domain_type" minOccurs="0" maxOccurs="unbounded" />
-               </xs:sequence>
-       </xs:complexType>
-
-       <!-- Maps to an array of session -->
-       <xs:complexType name="sessions_type">
-               <xs:sequence>
-                       <xs:element name="session" type="session_type" minOccurs="0" maxOccurs="unbounded" />
-               </xs:sequence>
-       </xs:complexType>
-
-       <!-- Maps to an array of event_field -->
-       <xs:complexType name="event_fields_type">
-               <xs:sequence>
-                       <xs:element name="event_field" type="event_field_type" minOccurs="0" maxOccurs="unbounded" />
-               </xs:sequence>
-       </xs:complexType>
-
-       <!-- Maps to an array of context -->
-       <xs:complexType name="contexts_type">
-               <xs:sequence>
-                       <xs:element name="context" type="context_type" minOccurs="0" maxOccurs="unbounded" />
-               </xs:sequence>
-       </xs:complexType>
-
-       <!-- Maps to an action dutring snapshot command -->
-       <xs:complexType name="snapshot_action_type">
-               <xs:sequence>
-                       <xs:element name="name" type="snapshot_actiontype_type" minOccurs="0" />
-                       <xs:element name="output" type="output_type" minOccurs="0" />
-               </xs:sequence>
-       </xs:complexType>
-
-       <!-- Type of snapshot commands -->
-       <xs:simpleType name="snapshot_actiontype_type">
-               <xs:restriction base="xs:string">
-                       <xs:enumeration value="list-output" />
-                       <xs:enumeration value="del-output" />
-                       <xs:enumeration value="add-output" />
-                       <xs:enumeration value="record-output" />
-               </xs:restriction>
-       </xs:simpleType>
-
-       <xs:complexType name="output_type">
-               <xs:choice>
-                       <xs:element name="domains" type="domains_type" minOccurs="0" />
-                       <xs:element name="sessions" type="sessions_type" minOccurs="0" />
-                       <xs:element name="session" type="session_type" minOccurs="0" />
-                       <xs:element name="snapshot_action" type="snapshot_action_type" minOccurs="0" />
-                       <xs:element name="snapshot" type="snapshot_type" minOccurs="0" />
-                       <xs:element name="version" type="version_type" minOccurs="0" />
-                       <xs:element name="save" type="save_type" minOccurs="0" />
-                       <xs:element name="load" type="load_type" minOccurs="0" />
-                       <xs:element name="calibrate" type="calibrate_type" minOccurs="0" />
-                       <xs:element name="contexts" type="contexts_type" minOccurs="0" />
-                       <xs:element name="channels" type="channels_type" minOccurs="0" />
-                       <xs:element name="events" type="event_list_type" minOccurs="0" />
-                       <xs:element name="channel" type="channel_type" minOccurs="0" />
-               </xs:choice>
-       </xs:complexType>
-
-       <!-- Maps to the mi_lttng commands -->
-       <xs:simpleType name="command_string_type">
-               <xs:restriction base="xs:string">
-                       <xs:enumeration value="create" />
-                       <xs:enumeration value="list" />
-                       <xs:enumeration value="snapshot" />
-                       <xs:enumeration value="version" />
-                       <xs:enumeration value="save" />
-                       <xs:enumeration value="load" />
-                       <xs:enumeration value="start" />
-                       <xs:enumeration value="stop" />
-                       <xs:enumeration value="destroy" />
-                       <xs:enumeration value="calibrate" />
-                       <xs:enumeration value="add-context" />
-                       <xs:enumeration value="enable-channel" />
-                       <xs:enumeration value="enable-event" />
-                       <xs:enumeration value="set-session" />
-                       <xs:enumeration value="disable-event" />
-                       <xs:enumeration value="disable-channel" />
-               </xs:restriction>
-       </xs:simpleType>
-
-       <xs:element name="command">
-               <xs:complexType>
-                       <xs:all>
-                               <xs:element name="name" type="command_string_type" maxOccurs="1" />
-                               <xs:element name="output" type="output_type" maxOccurs="1" />
-                               <xs:element name="success" type="xs:boolean" minOccurs="0" maxOccurs="1" />
-                       </xs:all>
-               </xs:complexType>
-       </xs:element>
-</xs:schema>
diff --git a/org.eclipse.tracecompass.lttng2.control/.project b/org.eclipse.tracecompass.lttng2.control/.project
deleted file mode 100644 (file)
index 746cab5..0000000
+++ /dev/null
@@ -1,17 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
-       <name>org.eclipse.tracecompass.lttng2.control</name>
-       <comment></comment>
-       <projects>
-       </projects>
-       <buildSpec>
-               <buildCommand>
-                       <name>org.eclipse.pde.FeatureBuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-       </buildSpec>
-       <natures>
-               <nature>org.eclipse.pde.FeatureNature</nature>
-       </natures>
-</projectDescription>
diff --git a/org.eclipse.tracecompass.lttng2.control/.settings/org.eclipse.core.resources.prefs b/org.eclipse.tracecompass.lttng2.control/.settings/org.eclipse.core.resources.prefs
deleted file mode 100644 (file)
index 99f26c0..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-eclipse.preferences.version=1
-encoding/<project>=UTF-8
diff --git a/org.eclipse.tracecompass.lttng2.control/.settings/org.eclipse.core.runtime.prefs b/org.eclipse.tracecompass.lttng2.control/.settings/org.eclipse.core.runtime.prefs
deleted file mode 100644 (file)
index 5a0ad22..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-eclipse.preferences.version=1
-line.separator=\n
diff --git a/org.eclipse.tracecompass.lttng2.control/build.properties b/org.eclipse.tracecompass.lttng2.control/build.properties
deleted file mode 100644 (file)
index 9991fff..0000000
+++ /dev/null
@@ -1,16 +0,0 @@
-###############################################################################
-# Copyright (c) 2013, 2014 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:
-#     Ericsson - Initial API and implementation
-###############################################################################
-
-bin.includes = feature.xml,\
-               feature.properties,\
-               p2.inf
-src.includes = sourceTemplateFeature/p2.inf
diff --git a/org.eclipse.tracecompass.lttng2.control/feature.properties b/org.eclipse.tracecompass.lttng2.control/feature.properties
deleted file mode 100644 (file)
index c9f78ae..0000000
+++ /dev/null
@@ -1,21 +0,0 @@
-###############################################################################
-# Copyright (c) 2012, 2015 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:
-#     Ericsson - Initial API and implementation
-###############################################################################
-
-featureName=LTTng Tracer Control
-
-description=Plug-ins to integrate the LTTng tracer control into the workbench. \
-Includes the TMF (Tracing and Monitoring Framework) and CTF (Common Trace Format) features.
-
-featureProvider=Eclipse Trace Compass
-
-copyright=Copyright 2015 Ericsson
-
diff --git a/org.eclipse.tracecompass.lttng2.control/feature.xml b/org.eclipse.tracecompass.lttng2.control/feature.xml
deleted file mode 100644 (file)
index 6ce0aa4..0000000
+++ /dev/null
@@ -1,78 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<feature
-      id="org.eclipse.tracecompass.lttng2.control"
-      label="%featureName"
-      version="1.0.0.qualifier"
-      provider-name="%featureProvider"
-      license-feature="org.eclipse.license"
-      license-feature-version="0.0.0">
-
-   <description url="http://www.example.com/description">
-      %description
-   </description>
-
-   <copyright url="http://www.example.com/copyright">
-      %copyright
-   </copyright>
-
-   <license url="%licenseURL">
-      %license
-   </license>
-
-   <includes
-         id="org.eclipse.tracecompass.tmf.ctf"
-         version="0.0.0"/>
-
-   <requires>
-      <import plugin="org.eclipse.core.runtime"/>
-      <import plugin="org.eclipse.ui"/>
-      <import plugin="org.eclipse.ui.ide"/>
-      <import plugin="org.eclipse.core.resources"/>
-      <import plugin="org.eclipse.tracecompass.ctf.core" version="1.0.0" match="greaterOrEqual"/>
-      <import plugin="org.eclipse.tracecompass.lttng2.control.core" version="1.0.0" match="greaterOrEqual"/>
-      <import plugin="org.eclipse.tracecompass.tmf.core" version="1.0.0" match="greaterOrEqual"/>
-      <import plugin="org.eclipse.tracecompass.tmf.ctf.core" version="1.0.0" match="greaterOrEqual"/>
-      <import plugin="org.eclipse.tracecompass.tmf.remote.core" version="1.0.0" match="greaterOrEqual"/>
-      <import plugin="org.eclipse.tracecompass.tmf.remote.ui" version="1.0.0" match="greaterOrEqual"/>
-      <import plugin="org.eclipse.tracecompass.tmf.ui" version="1.0.0" match="greaterOrEqual"/>
-      <import plugin="org.eclipse.help"/>
-      <import feature="org.eclipse.remote" version="2.0.0" match="greaterOrEqual"/>
-      <import plugin="com.google.guava"/>
-      <import plugin="org.eclipse.core.expressions"/>
-   </requires>
-
-   <plugin
-         id="org.eclipse.tracecompass.lttng2.control.core"
-         download-size="0"
-         install-size="0"
-         version="0.0.0"
-         unpack="false"/>
-
-   <plugin
-         id="org.eclipse.tracecompass.lttng2.control.ui"
-         download-size="0"
-         install-size="0"
-         version="0.0.0"
-         unpack="false"/>
-
-   <plugin
-         id="org.eclipse.tracecompass.doc.user"
-         download-size="0"
-         install-size="0"
-         version="0.0.0"/>
-
-   <plugin
-         id="org.eclipse.tracecompass.tmf.remote.core"
-         download-size="0"
-         install-size="0"
-         version="0.0.0"
-         unpack="false"/>
-
-   <plugin
-         id="org.eclipse.tracecompass.tmf.remote.ui"
-         download-size="0"
-         install-size="0"
-         version="0.0.0"
-         unpack="false"/>
-
-</feature>
diff --git a/org.eclipse.tracecompass.lttng2.control/p2.inf b/org.eclipse.tracecompass.lttng2.control/p2.inf
deleted file mode 100644 (file)
index 5b8cc7b..0000000
+++ /dev/null
@@ -1 +0,0 @@
-update.matchExp=providedCapabilities.exists(pc | pc.namespace == 'org.eclipse.equinox.p2.iu' && (pc.name == 'org.eclipse.linuxtools.lttng2.feature.group' || pc.name == 'org.eclipse.linuxtools.lttng2.control.feature.group' || pc.name == 'org.eclipse.tracecompass.lttng2.control.feature.group'))
diff --git a/org.eclipse.tracecompass.lttng2.control/pom.xml b/org.eclipse.tracecompass.lttng2.control/pom.xml
deleted file mode 100644 (file)
index 7c19c79..0000000
+++ /dev/null
@@ -1,63 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-   Copyright (C) 2011, Red Hat, Inc.
-
-   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
--->
-<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>
-    <artifactId>org.eclipse.tracecompass</artifactId>
-    <groupId>org.eclipse.tracecompass</groupId>
-    <version>1.0.0-SNAPSHOT</version>
-  </parent>
-
-  <artifactId>org.eclipse.tracecompass.lttng2.control</artifactId>
-  <groupId>org.eclipse.tracecompass</groupId>
-  <version>1.0.0-SNAPSHOT</version>
-  <packaging>eclipse-feature</packaging>
-
-  <name>Trace Compass LTTng (Linux Tracing Toolkit) Feature</name>
-
-  <build>
-    <plugins>
-      <plugin>
-        <groupId>org.eclipse.tycho.extras</groupId>
-        <artifactId>tycho-source-feature-plugin</artifactId>
-        <executions>
-          <execution>
-            <id>source-feature</id>
-            <phase>package</phase>
-            <goals>
-              <goal>source-feature</goal>
-            </goals>
-            <configuration>
-              <excludes>
-                <plugin id="org.eclipse.tracecompass.doc.user"/>
-              </excludes>
-            </configuration>
-          </execution>
-        </executions>
-      </plugin>
-      <plugin>
-        <groupId>org.eclipse.tycho</groupId>
-        <artifactId>tycho-p2-plugin</artifactId>
-        <version>${tycho-version}</version>
-        <executions>
-          <execution>
-            <id>attached-p2-metadata</id>
-            <phase>package</phase>
-            <goals>
-              <goal>p2-metadata</goal>
-            </goals>
-          </execution>
-        </executions>
-      </plugin>
-    </plugins>
-  </build>
-</project>
diff --git a/org.eclipse.tracecompass.lttng2.control/sourceTemplateFeature/p2.inf b/org.eclipse.tracecompass.lttng2.control/sourceTemplateFeature/p2.inf
deleted file mode 100644 (file)
index e6ea35d..0000000
+++ /dev/null
@@ -1 +0,0 @@
-update.matchExp=providedCapabilities.exists(pc | pc.namespace == 'org.eclipse.equinox.p2.iu' && (pc.name == 'org.eclipse.linuxtools.lttng2.source.feature.group' || pc.name == 'org.eclipse.linuxtools.lttng2.control.source.feature.group' || pc.name == 'org.eclipse.tracecompass.lttng2.control.source.feature.group'))
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core.tests/.classpath b/org.eclipse.tracecompass.lttng2.kernel.core.tests/.classpath
deleted file mode 100644 (file)
index 8fbc9a2..0000000
+++ /dev/null
@@ -1,9 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
-       <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7"/>
-       <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
-       <classpathentry kind="src" path="src"/>
-       <classpathentry kind="src" path="perf"/>
-       <classpathentry kind="src" path="shared"/>
-       <classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core.tests/.project b/org.eclipse.tracecompass.lttng2.kernel.core.tests/.project
deleted file mode 100644 (file)
index 26161b2..0000000
+++ /dev/null
@@ -1,34 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
-       <name>org.eclipse.tracecompass.lttng2.kernel.core.tests</name>
-       <comment></comment>
-       <projects>
-       </projects>
-       <buildSpec>
-               <buildCommand>
-                       <name>org.eclipse.jdt.core.javabuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-               <buildCommand>
-                       <name>org.eclipse.pde.ManifestBuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-               <buildCommand>
-                       <name>org.eclipse.pde.SchemaBuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-               <buildCommand>
-                       <name>org.eclipse.pde.api.tools.apiAnalysisBuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-       </buildSpec>
-       <natures>
-               <nature>org.eclipse.pde.PluginNature</nature>
-               <nature>org.eclipse.jdt.core.javanature</nature>
-               <nature>org.eclipse.pde.api.tools.apiAnalysisNature</nature>
-       </natures>
-</projectDescription>
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core.tests/.settings/org.eclipse.core.resources.prefs b/org.eclipse.tracecompass.lttng2.kernel.core.tests/.settings/org.eclipse.core.resources.prefs
deleted file mode 100644 (file)
index 99f26c0..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-eclipse.preferences.version=1
-encoding/<project>=UTF-8
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core.tests/.settings/org.eclipse.core.runtime.prefs b/org.eclipse.tracecompass.lttng2.kernel.core.tests/.settings/org.eclipse.core.runtime.prefs
deleted file mode 100644 (file)
index 5a0ad22..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-eclipse.preferences.version=1
-line.separator=\n
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core.tests/.settings/org.eclipse.jdt.core.prefs b/org.eclipse.tracecompass.lttng2.kernel.core.tests/.settings/org.eclipse.jdt.core.prefs
deleted file mode 100644 (file)
index 0409c61..0000000
+++ /dev/null
@@ -1,403 +0,0 @@
-eclipse.preferences.version=1
-org.eclipse.jdt.core.codeComplete.argumentPrefixes=
-org.eclipse.jdt.core.codeComplete.argumentSuffixes=
-org.eclipse.jdt.core.codeComplete.fieldPrefixes=f
-org.eclipse.jdt.core.codeComplete.fieldSuffixes=
-org.eclipse.jdt.core.codeComplete.localPrefixes=
-org.eclipse.jdt.core.codeComplete.localSuffixes=
-org.eclipse.jdt.core.codeComplete.staticFieldPrefixes=
-org.eclipse.jdt.core.codeComplete.staticFieldSuffixes=
-org.eclipse.jdt.core.codeComplete.staticFinalFieldPrefixes=
-org.eclipse.jdt.core.codeComplete.staticFinalFieldSuffixes=
-org.eclipse.jdt.core.compiler.annotation.inheritNullAnnotations=enabled
-org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore
-org.eclipse.jdt.core.compiler.annotation.nonnull=org.eclipse.jdt.annotation.NonNull
-org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=org.eclipse.jdt.annotation.NonNullByDefault
-org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nullable
-org.eclipse.jdt.core.compiler.annotation.nullanalysis=enabled
-org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
-org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
-org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
-org.eclipse.jdt.core.compiler.compliance=1.7
-org.eclipse.jdt.core.compiler.debug.lineNumber=generate
-org.eclipse.jdt.core.compiler.debug.localVariable=generate
-org.eclipse.jdt.core.compiler.debug.sourceFile=generate
-org.eclipse.jdt.core.compiler.doc.comment.support=enabled
-org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=error
-org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
-org.eclipse.jdt.core.compiler.problem.autoboxing=ignore
-org.eclipse.jdt.core.compiler.problem.comparingIdentical=error
-org.eclipse.jdt.core.compiler.problem.deadCode=error
-org.eclipse.jdt.core.compiler.problem.deprecation=error
-org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled
-org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=enabled
-org.eclipse.jdt.core.compiler.problem.discouragedReference=error
-org.eclipse.jdt.core.compiler.problem.emptyStatement=error
-org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
-org.eclipse.jdt.core.compiler.problem.explicitlyClosedAutoCloseable=error
-org.eclipse.jdt.core.compiler.problem.fallthroughCase=error
-org.eclipse.jdt.core.compiler.problem.fatalOptionalError=disabled
-org.eclipse.jdt.core.compiler.problem.fieldHiding=error
-org.eclipse.jdt.core.compiler.problem.finalParameterBound=error
-org.eclipse.jdt.core.compiler.problem.finallyBlockNotCompletingNormally=error
-org.eclipse.jdt.core.compiler.problem.forbiddenReference=error
-org.eclipse.jdt.core.compiler.problem.hiddenCatchBlock=error
-org.eclipse.jdt.core.compiler.problem.includeNullInfoFromAsserts=disabled
-org.eclipse.jdt.core.compiler.problem.incompatibleNonInheritedInterfaceMethod=error
-org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch=error
-org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=error
-org.eclipse.jdt.core.compiler.problem.invalidJavadoc=warning
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTags=enabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsDeprecatedRef=enabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsNotVisibleRef=enabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsVisibility=protected
-org.eclipse.jdt.core.compiler.problem.localVariableHiding=error
-org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=error
-org.eclipse.jdt.core.compiler.problem.missingDefaultCase=error
-org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=error
-org.eclipse.jdt.core.compiler.problem.missingEnumCaseDespiteDefault=enabled
-org.eclipse.jdt.core.compiler.problem.missingHashCodeMethod=error
-org.eclipse.jdt.core.compiler.problem.missingJavadocComments=warning
-org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsOverriding=disabled
-org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsVisibility=protected
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagDescription=all_standard_tags
-org.eclipse.jdt.core.compiler.problem.missingJavadocTags=warning
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagsMethodTypeParameters=disabled
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagsOverriding=disabled
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagsVisibility=protected
-org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotation=error
-org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotationForInterfaceMethodImplementation=enabled
-org.eclipse.jdt.core.compiler.problem.missingSerialVersion=error
-org.eclipse.jdt.core.compiler.problem.missingSynchronizedOnInheritedMethod=error
-org.eclipse.jdt.core.compiler.problem.noEffectAssignment=error
-org.eclipse.jdt.core.compiler.problem.noImplicitStringConversion=error
-org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=ignore
-org.eclipse.jdt.core.compiler.problem.nonnullParameterAnnotationDropped=warning
-org.eclipse.jdt.core.compiler.problem.nullAnnotationInferenceConflict=warning
-org.eclipse.jdt.core.compiler.problem.nullReference=error
-org.eclipse.jdt.core.compiler.problem.nullSpecViolation=error
-org.eclipse.jdt.core.compiler.problem.nullUncheckedConversion=warning
-org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=error
-org.eclipse.jdt.core.compiler.problem.parameterAssignment=error
-org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=error
-org.eclipse.jdt.core.compiler.problem.potentialNullReference=error
-org.eclipse.jdt.core.compiler.problem.potentiallyUnclosedCloseable=warning
-org.eclipse.jdt.core.compiler.problem.rawTypeReference=error
-org.eclipse.jdt.core.compiler.problem.redundantNullAnnotation=warning
-org.eclipse.jdt.core.compiler.problem.redundantNullCheck=error
-org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=error
-org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=error
-org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore
-org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=error
-org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled
-org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=error
-org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=disabled
-org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled
-org.eclipse.jdt.core.compiler.problem.syntacticNullAnalysisForFields=enabled
-org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=ignore
-org.eclipse.jdt.core.compiler.problem.typeParameterHiding=error
-org.eclipse.jdt.core.compiler.problem.unavoidableGenericTypeProblems=disabled
-org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=error
-org.eclipse.jdt.core.compiler.problem.unclosedCloseable=error
-org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=ignore
-org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=error
-org.eclipse.jdt.core.compiler.problem.unnecessaryElse=error
-org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=error
-org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=error
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionExemptExceptionAndThrowable=disabled
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionIncludeDocCommentReference=disabled
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverriding=disabled
-org.eclipse.jdt.core.compiler.problem.unusedImport=error
-org.eclipse.jdt.core.compiler.problem.unusedLabel=error
-org.eclipse.jdt.core.compiler.problem.unusedLocal=error
-org.eclipse.jdt.core.compiler.problem.unusedObjectAllocation=ignore
-org.eclipse.jdt.core.compiler.problem.unusedParameter=ignore
-org.eclipse.jdt.core.compiler.problem.unusedParameterIncludeDocCommentReference=enabled
-org.eclipse.jdt.core.compiler.problem.unusedParameterWhenImplementingAbstract=disabled
-org.eclipse.jdt.core.compiler.problem.unusedParameterWhenOverridingConcrete=disabled
-org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=error
-org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=ignore
-org.eclipse.jdt.core.compiler.problem.unusedWarningToken=error
-org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=error
-org.eclipse.jdt.core.compiler.source=1.7
-org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_call=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression=16
-org.eclipse.jdt.core.formatter.alignment_for_assignment=0
-org.eclipse.jdt.core.formatter.alignment_for_binary_expression=16
-org.eclipse.jdt.core.formatter.alignment_for_compact_if=16
-org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=80
-org.eclipse.jdt.core.formatter.alignment_for_enum_constants=0
-org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=16
-org.eclipse.jdt.core.formatter.alignment_for_method_declaration=0
-org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16
-org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=80
-org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation=0
-org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_constructor_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_method_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_union_type_in_multicatch=16
-org.eclipse.jdt.core.formatter.blank_lines_after_imports=1
-org.eclipse.jdt.core.formatter.blank_lines_after_package=1
-org.eclipse.jdt.core.formatter.blank_lines_before_field=0
-org.eclipse.jdt.core.formatter.blank_lines_before_first_class_body_declaration=0
-org.eclipse.jdt.core.formatter.blank_lines_before_imports=1
-org.eclipse.jdt.core.formatter.blank_lines_before_member_type=1
-org.eclipse.jdt.core.formatter.blank_lines_before_method=1
-org.eclipse.jdt.core.formatter.blank_lines_before_new_chunk=1
-org.eclipse.jdt.core.formatter.blank_lines_before_package=0
-org.eclipse.jdt.core.formatter.blank_lines_between_import_groups=1
-org.eclipse.jdt.core.formatter.blank_lines_between_type_declarations=1
-org.eclipse.jdt.core.formatter.brace_position_for_annotation_type_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_array_initializer=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_block=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_block_in_case=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_constructor_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_enum_constant=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_enum_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_method_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_switch=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_type_declaration=end_of_line
-org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_block_comment=false
-org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_javadoc_comment=false
-org.eclipse.jdt.core.formatter.comment.format_block_comments=true
-org.eclipse.jdt.core.formatter.comment.format_header=false
-org.eclipse.jdt.core.formatter.comment.format_html=true
-org.eclipse.jdt.core.formatter.comment.format_javadoc_comments=true
-org.eclipse.jdt.core.formatter.comment.format_line_comments=true
-org.eclipse.jdt.core.formatter.comment.format_source_code=true
-org.eclipse.jdt.core.formatter.comment.indent_parameter_description=true
-org.eclipse.jdt.core.formatter.comment.indent_root_tags=true
-org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags=insert
-org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter=insert
-org.eclipse.jdt.core.formatter.comment.line_length=80
-org.eclipse.jdt.core.formatter.comment.new_lines_at_block_boundaries=true
-org.eclipse.jdt.core.formatter.comment.new_lines_at_javadoc_boundaries=true
-org.eclipse.jdt.core.formatter.comment.preserve_white_space_between_code_and_line_comments=false
-org.eclipse.jdt.core.formatter.compact_else_if=true
-org.eclipse.jdt.core.formatter.continuation_indentation=2
-org.eclipse.jdt.core.formatter.continuation_indentation_for_array_initializer=2
-org.eclipse.jdt.core.formatter.disabling_tag=@formatter\:off
-org.eclipse.jdt.core.formatter.enabling_tag=@formatter\:on
-org.eclipse.jdt.core.formatter.format_guardian_clause_on_one_line=false
-org.eclipse.jdt.core.formatter.format_line_comment_starting_on_first_column=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_annotation_declaration_header=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_constant_header=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_declaration_header=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_type_header=true
-org.eclipse.jdt.core.formatter.indent_breaks_compare_to_cases=true
-org.eclipse.jdt.core.formatter.indent_empty_lines=false
-org.eclipse.jdt.core.formatter.indent_statements_compare_to_block=true
-org.eclipse.jdt.core.formatter.indent_statements_compare_to_body=true
-org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_cases=true
-org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_switch=false
-org.eclipse.jdt.core.formatter.indentation.size=4
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_field=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_local_variable=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_method=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_package=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_parameter=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_type=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_label=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_opening_brace_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_at_end_of_file_if_missing=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_finally_in_try_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_while_in_do_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_annotation_declaration=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_anonymous_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_block=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter=insert
-org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_binary_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_paren_in_cast=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_assert=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_case=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_labeled_statement=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_allocation_expression=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_annotation=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_throws=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_constant_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_declarations=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_explicitconstructorcall_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_increments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_inits=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_throws=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_invocation_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_field_declarations=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_local_declarations=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_parameterized_type_reference=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_superinterfaces=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_ellipsis=insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_brace_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_cast=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_catch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_for=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_if=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_parenthesized_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_switch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_synchronized=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_try=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_while=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_try_resources=insert
-org.eclipse.jdt.core.formatter.insert_space_after_unary_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter=insert
-org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_binary_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_brace_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_cast=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_catch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_for=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_if=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_parenthesized_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_switch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_synchronized=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_try=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_while=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_assert=insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_case=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_default=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_labeled_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_throws=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_constant_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_declarations=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_explicitconstructorcall_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_increments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_inits=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_throws=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_invocation_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_field_declarations=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_local_declarations=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_superinterfaces=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_ellipsis=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_annotation_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_anonymous_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_block=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_constructor_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_constant=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_method_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_switch=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation_type_member_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_catch=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_if=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_parenthesized_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_switch=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_synchronized=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_try=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_while=insert
-org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_return=insert
-org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_throw=insert
-org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_semicolon=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_try_resources=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_unary_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_brackets_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_annotation_type_member_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.join_lines_in_comments=true
-org.eclipse.jdt.core.formatter.join_wrapped_lines=false
-org.eclipse.jdt.core.formatter.keep_else_statement_on_same_line=false
-org.eclipse.jdt.core.formatter.keep_empty_array_initializer_on_one_line=false
-org.eclipse.jdt.core.formatter.keep_imple_if_on_one_line=false
-org.eclipse.jdt.core.formatter.keep_then_statement_on_same_line=false
-org.eclipse.jdt.core.formatter.lineSplit=250
-org.eclipse.jdt.core.formatter.never_indent_block_comments_on_first_column=false
-org.eclipse.jdt.core.formatter.never_indent_line_comments_on_first_column=false
-org.eclipse.jdt.core.formatter.number_of_blank_lines_at_beginning_of_method_body=0
-org.eclipse.jdt.core.formatter.number_of_empty_lines_to_preserve=1
-org.eclipse.jdt.core.formatter.put_empty_statement_on_new_line=true
-org.eclipse.jdt.core.formatter.tabulation.char=space
-org.eclipse.jdt.core.formatter.tabulation.size=4
-org.eclipse.jdt.core.formatter.use_on_off_tags=false
-org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false
-org.eclipse.jdt.core.formatter.wrap_before_binary_operator=true
-org.eclipse.jdt.core.formatter.wrap_before_or_operator_multicatch=true
-org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core.tests/.settings/org.eclipse.jdt.ui.prefs b/org.eclipse.tracecompass.lttng2.kernel.core.tests/.settings/org.eclipse.jdt.ui.prefs
deleted file mode 100644 (file)
index 232a3fd..0000000
+++ /dev/null
@@ -1,60 +0,0 @@
-eclipse.preferences.version=1
-editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true
-formatter_profile=_tmf-style
-formatter_settings_version=12
-org.eclipse.jdt.ui.exception.name=e
-org.eclipse.jdt.ui.gettersetter.use.is=true
-org.eclipse.jdt.ui.keywordthis=false
-org.eclipse.jdt.ui.overrideannotation=true
-sp_cleanup.add_default_serial_version_id=true
-sp_cleanup.add_generated_serial_version_id=false
-sp_cleanup.add_missing_annotations=false
-sp_cleanup.add_missing_deprecated_annotations=true
-sp_cleanup.add_missing_methods=false
-sp_cleanup.add_missing_nls_tags=false
-sp_cleanup.add_missing_override_annotations=true
-sp_cleanup.add_missing_override_annotations_interface_methods=true
-sp_cleanup.add_serial_version_id=false
-sp_cleanup.always_use_blocks=true
-sp_cleanup.always_use_parentheses_in_expressions=false
-sp_cleanup.always_use_this_for_non_static_field_access=false
-sp_cleanup.always_use_this_for_non_static_method_access=false
-sp_cleanup.convert_to_enhanced_for_loop=false
-sp_cleanup.correct_indentation=false
-sp_cleanup.format_source_code=false
-sp_cleanup.format_source_code_changes_only=false
-sp_cleanup.make_local_variable_final=false
-sp_cleanup.make_parameters_final=false
-sp_cleanup.make_private_fields_final=true
-sp_cleanup.make_type_abstract_if_missing_method=false
-sp_cleanup.make_variable_declarations_final=false
-sp_cleanup.never_use_blocks=false
-sp_cleanup.never_use_parentheses_in_expressions=true
-sp_cleanup.on_save_use_additional_actions=true
-sp_cleanup.organize_imports=false
-sp_cleanup.qualify_static_field_accesses_with_declaring_class=false
-sp_cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=true
-sp_cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=true
-sp_cleanup.qualify_static_member_accesses_with_declaring_class=false
-sp_cleanup.qualify_static_method_accesses_with_declaring_class=false
-sp_cleanup.remove_private_constructors=true
-sp_cleanup.remove_trailing_whitespaces=true
-sp_cleanup.remove_trailing_whitespaces_all=true
-sp_cleanup.remove_trailing_whitespaces_ignore_empty=false
-sp_cleanup.remove_unnecessary_casts=false
-sp_cleanup.remove_unnecessary_nls_tags=false
-sp_cleanup.remove_unused_imports=false
-sp_cleanup.remove_unused_local_variables=false
-sp_cleanup.remove_unused_private_fields=true
-sp_cleanup.remove_unused_private_members=false
-sp_cleanup.remove_unused_private_methods=true
-sp_cleanup.remove_unused_private_types=true
-sp_cleanup.sort_members=false
-sp_cleanup.sort_members_all=false
-sp_cleanup.use_blocks=true
-sp_cleanup.use_blocks_only_for_return_and_throw=false
-sp_cleanup.use_parentheses_in_expressions=false
-sp_cleanup.use_this_for_non_static_field_access=false
-sp_cleanup.use_this_for_non_static_field_access_only_if_necessary=true
-sp_cleanup.use_this_for_non_static_method_access=false
-sp_cleanup.use_this_for_non_static_method_access_only_if_necessary=true
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core.tests/.settings/org.eclipse.pde.api.tools.prefs b/org.eclipse.tracecompass.lttng2.kernel.core.tests/.settings/org.eclipse.pde.api.tools.prefs
deleted file mode 100644 (file)
index acc3abd..0000000
+++ /dev/null
@@ -1,97 +0,0 @@
-ANNOTATION_ELEMENT_TYPE_ADDED_METHOD_WITHOUT_DEFAULT_VALUE=Error
-ANNOTATION_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-ANNOTATION_ELEMENT_TYPE_REMOVED_FIELD=Error
-ANNOTATION_ELEMENT_TYPE_REMOVED_METHOD=Error
-ANNOTATION_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_API_TYPE=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_API_TYPE=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_TYPE=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_TYPE=Error
-API_USE_SCAN_FIELD_SEVERITY=Error
-API_USE_SCAN_METHOD_SEVERITY=Error
-API_USE_SCAN_TYPE_SEVERITY=Error
-CLASS_ELEMENT_TYPE_ADDED_METHOD=Error
-CLASS_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
-CLASS_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-CLASS_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
-CLASS_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-CLASS_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
-CLASS_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
-CLASS_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-CLASS_ELEMENT_TYPE_REMOVED_CONSTRUCTOR=Error
-CLASS_ELEMENT_TYPE_REMOVED_FIELD=Error
-CLASS_ELEMENT_TYPE_REMOVED_METHOD=Error
-CLASS_ELEMENT_TYPE_REMOVED_SUPERCLASS=Error
-CLASS_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-CLASS_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-CONSTRUCTOR_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-CONSTRUCTOR_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-CONSTRUCTOR_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
-CONSTRUCTOR_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-ENUM_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
-ENUM_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-ENUM_ELEMENT_TYPE_REMOVED_ENUM_CONSTANT=Error
-ENUM_ELEMENT_TYPE_REMOVED_FIELD=Error
-ENUM_ELEMENT_TYPE_REMOVED_METHOD=Error
-ENUM_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-FIELD_ELEMENT_TYPE_ADDED_VALUE=Error
-FIELD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-FIELD_ELEMENT_TYPE_CHANGED_FINAL_TO_NON_FINAL_STATIC_CONSTANT=Error
-FIELD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
-FIELD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
-FIELD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
-FIELD_ELEMENT_TYPE_CHANGED_TYPE=Error
-FIELD_ELEMENT_TYPE_CHANGED_VALUE=Error
-FIELD_ELEMENT_TYPE_REMOVED_TYPE_ARGUMENT=Error
-FIELD_ELEMENT_TYPE_REMOVED_VALUE=Error
-ILLEGAL_EXTEND=Warning
-ILLEGAL_IMPLEMENT=Warning
-ILLEGAL_INSTANTIATE=Warning
-ILLEGAL_OVERRIDE=Warning
-ILLEGAL_REFERENCE=Warning
-INTERFACE_ELEMENT_TYPE_ADDED_FIELD=Error
-INTERFACE_ELEMENT_TYPE_ADDED_METHOD=Error
-INTERFACE_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
-INTERFACE_ELEMENT_TYPE_ADDED_SUPER_INTERFACE_WITH_METHODS=Error
-INTERFACE_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-INTERFACE_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
-INTERFACE_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_FIELD=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_METHOD=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-INVALID_JAVADOC_TAG=Warning
-INVALID_REFERENCE_IN_SYSTEM_LIBRARIES=Warning
-LEAK_EXTEND=Warning
-LEAK_FIELD_DECL=Warning
-LEAK_IMPLEMENT=Warning
-LEAK_METHOD_PARAM=Warning
-LEAK_METHOD_RETURN_TYPE=Warning
-METHOD_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
-METHOD_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-METHOD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-METHOD_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
-METHOD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
-METHOD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
-METHOD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
-METHOD_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
-METHOD_ELEMENT_TYPE_REMOVED_ANNOTATION_DEFAULT_VALUE=Error
-METHOD_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-MISSING_EE_DESCRIPTIONS=Ignore
-TYPE_PARAMETER_ELEMENT_TYPE_ADDED_CLASS_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_ADDED_INTERFACE_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_CLASS_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_INTERFACE_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_CLASS_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_INTERFACE_BOUND=Error
-UNUSED_PROBLEM_FILTERS=Warning
-automatically_removed_unused_problem_filters=false
-eclipse.preferences.version=1
-incompatible_api_component_version=Error
-incompatible_api_component_version_include_major_without_breaking_change=Disabled
-incompatible_api_component_version_include_minor_without_api_change=Disabled
-invalid_since_tag_version=Error
-malformed_since_tag=Error
-missing_since_tag=Error
-report_api_breakage_when_major_version_incremented=Disabled
-report_resolution_errors_api_component=Warning
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core.tests/.settings/org.eclipse.pde.prefs b/org.eclipse.tracecompass.lttng2.kernel.core.tests/.settings/org.eclipse.pde.prefs
deleted file mode 100644 (file)
index 62cfa90..0000000
+++ /dev/null
@@ -1,32 +0,0 @@
-compilers.f.unresolved-features=1
-compilers.f.unresolved-plugins=1
-compilers.incompatible-environment=1
-compilers.p.build=1
-compilers.p.build.bin.includes=1
-compilers.p.build.encodings=2
-compilers.p.build.java.compiler=2
-compilers.p.build.java.compliance=1
-compilers.p.build.missing.output=2
-compilers.p.build.output.library=1
-compilers.p.build.source.library=1
-compilers.p.build.src.includes=1
-compilers.p.deprecated=1
-compilers.p.discouraged-class=1
-compilers.p.internal=1
-compilers.p.missing-packages=2
-compilers.p.missing-version-export-package=2
-compilers.p.missing-version-import-package=2
-compilers.p.missing-version-require-bundle=2
-compilers.p.no-required-att=0
-compilers.p.not-externalized-att=2
-compilers.p.unknown-attribute=1
-compilers.p.unknown-class=1
-compilers.p.unknown-element=1
-compilers.p.unknown-identifier=1
-compilers.p.unknown-resource=1
-compilers.p.unresolved-ex-points=0
-compilers.p.unresolved-import=0
-compilers.s.create-docs=false
-compilers.s.doc-folder=doc
-compilers.s.open-tags=1
-eclipse.preferences.version=1
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core.tests/META-INF/MANIFEST.MF b/org.eclipse.tracecompass.lttng2.kernel.core.tests/META-INF/MANIFEST.MF
deleted file mode 100644 (file)
index 271ede2..0000000
+++ /dev/null
@@ -1,31 +0,0 @@
-Manifest-Version: 1.0
-Bundle-ManifestVersion: 2
-Bundle-Name: %Bundle-Name
-Bundle-Vendor: %Bundle-Vendor
-Bundle-Version: 1.0.0.qualifier
-Bundle-Localization: plugin
-Bundle-SymbolicName: org.eclipse.tracecompass.lttng2.kernel.core.tests;singleton:=true
-Bundle-Activator: org.eclipse.tracecompass.lttng2.kernel.core.tests.Activator
-Bundle-ActivationPolicy: lazy
-Bundle-RequiredExecutionEnvironment: JavaSE-1.7
-Require-Bundle: org.junit;bundle-version="4.0.0",
- org.eclipse.core.runtime,
- org.eclipse.tracecompass.common.core,
- org.eclipse.tracecompass.tmf.core,
- org.eclipse.tracecompass.tmf.core.tests,
- org.eclipse.tracecompass.tmf.ctf.core,
- org.eclipse.tracecompass.tmf.ctf.core.tests,
- org.eclipse.tracecompass.lttng2.kernel.core,
- org.eclipse.core.resources,
- org.eclipse.tracecompass.lttng2.control.core,
- org.eclipse.tracecompass.analysis.os.linux.core,
- org.eclipse.tracecompass.analysis.os.linux.core.tests
-Export-Package: org.eclipse.tracecompass.lttng2.kernel.core.tests,
- org.eclipse.tracecompass.lttng2.kernel.core.tests.analysis.kernel;x-internal:=true,
- org.eclipse.tracecompass.lttng2.kernel.core.tests.analysis.kernel.statesystem;x-internal:=true,
- org.eclipse.tracecompass.lttng2.kernel.core.tests.event.matchandsync;x-internal:=true,
- org.eclipse.tracecompass.lttng2.kernel.core.tests.perf,
- org.eclipse.tracecompass.lttng2.kernel.core.tests.perf.analysis;x-internal:=true,
- org.eclipse.tracecompass.lttng2.lttng.kernel.core.tests.shared.vm
-Import-Package: com.google.common.collect,
- org.eclipse.test.performance
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core.tests/about.html b/org.eclipse.tracecompass.lttng2.kernel.core.tests/about.html
deleted file mode 100644 (file)
index c258ef5..0000000
+++ /dev/null
@@ -1,28 +0,0 @@
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
-    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml">
-<head>
-<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"/>
-<title>About</title>
-</head>
-<body lang="EN-US">
-<h2>About This Content</h2>
-<p>June 5, 2006</p>    
-<h3>License</h3>
-
-<p>The Eclipse Foundation makes available all content in this plug-in (&quot;Content&quot;).  Unless otherwise 
-indicated below, the Content is provided to you under the terms and conditions of the
-Eclipse Public License Version 1.0 (&quot;EPL&quot;).  A copy of the EPL is available 
-at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>.
-For purposes of the EPL, &quot;Program&quot; will mean the Content.</p>
-
-<p>If you did not receive this Content directly from the Eclipse Foundation, the Content is 
-being redistributed by another party (&quot;Redistributor&quot;) and different terms and conditions may
-apply to your use of any object code in the Content.  Check the Redistributor's license that was 
-provided with the Content.  If no such license exists, contact the Redistributor.  Unless otherwise
-indicated below, the terms and conditions of the EPL still apply to any source code in the Content
-and such source code may be obtained at <a href="http://www.eclipse.org/">http://www.eclipse.org</a>.</p>
-
-</body>
-</html>
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core.tests/build.properties b/org.eclipse.tracecompass.lttng2.kernel.core.tests/build.properties
deleted file mode 100644 (file)
index 68a4f26..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-###############################################################################
-# Copyright (c) 2013, 2015 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:
-#     Ericsson - Initial API and implementation
-###############################################################################
-
-source.. = src/,\
-           perf/,\
-           shared/
-output.. = bin/
-bin.includes = META-INF/,\
-               .,\
-               plugin.properties,\
-               about.html
-src.includes = about.html
-additional.bundles = org.eclipse.jdt.annotation
-jars.extra.classpath = platform:/plugin/org.eclipse.jdt.annotation
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core.tests/perf/org/eclipse/tracecompass/lttng2/kernel/core/tests/perf/AllPerfTests.java b/org.eclipse.tracecompass.lttng2.kernel.core.tests/perf/org/eclipse/tracecompass/lttng2/kernel/core/tests/perf/AllPerfTests.java
deleted file mode 100644 (file)
index 7d3b2bf..0000000
+++ /dev/null
@@ -1,30 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2014 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:
- *   Alexandre Montplaisir - Initial implementation and API
- *******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.kernel.core.tests.perf;
-
-import org.junit.runner.RunWith;
-import org.junit.runners.Suite;
-
-/**
- * Run all performance test suites.
- *
- * @author Alexandre Montplaisir
- */
-@RunWith(Suite.class)
-@Suite.SuiteClasses({
-        org.eclipse.tracecompass.lttng2.kernel.core.tests.perf.analysis.AllPerfTests.class,
-        org.eclipse.tracecompass.lttng2.kernel.core.tests.perf.event.matching.AllPerfTests.class
-})
-public class AllPerfTests {
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core.tests/perf/org/eclipse/tracecompass/lttng2/kernel/core/tests/perf/analysis/AllPerfTests.java b/org.eclipse.tracecompass.lttng2.kernel.core.tests/perf/org/eclipse/tracecompass/lttng2/kernel/core/tests/perf/analysis/AllPerfTests.java
deleted file mode 100644 (file)
index cd949ec..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2014 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:
- *   Alexandre Montplaisir - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.kernel.core.tests.perf.analysis;
-
-import org.junit.runner.RunWith;
-import org.junit.runners.Suite;
-
-/**
- * Test suite
- */
-@RunWith(Suite.class)
-@Suite.SuiteClasses({
-        AnalysisBenchmark.class
-})
-public class AllPerfTests {
-}
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core.tests/perf/org/eclipse/tracecompass/lttng2/kernel/core/tests/perf/analysis/AnalysisBenchmark.java b/org.eclipse.tracecompass.lttng2.kernel.core.tests/perf/org/eclipse/tracecompass/lttng2/kernel/core/tests/perf/analysis/AnalysisBenchmark.java
deleted file mode 100644 (file)
index 3233cce..0000000
+++ /dev/null
@@ -1,97 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2014, 2015 École Polytechnique de Montréal
- *
- * 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:
- *   Geneviève Bastien - Initial API and implementation
- *   Alexandre Montplaisir - Convert to org.eclipse.test.performance test
- *******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.kernel.core.tests.perf.analysis;
-
-import static org.junit.Assert.fail;
-import static org.junit.Assume.assumeTrue;
-
-import java.io.File;
-
-import org.eclipse.test.performance.Dimension;
-import org.eclipse.test.performance.Performance;
-import org.eclipse.test.performance.PerformanceMeter;
-import org.eclipse.tracecompass.analysis.os.linux.core.kernelanalysis.KernelAnalysisModule;
-import org.eclipse.tracecompass.lttng2.kernel.core.trace.LttngKernelTrace;
-import org.eclipse.tracecompass.tmf.core.analysis.IAnalysisModule;
-import org.eclipse.tracecompass.tmf.core.exceptions.TmfAnalysisException;
-import org.eclipse.tracecompass.tmf.core.exceptions.TmfTraceException;
-import org.eclipse.tracecompass.tmf.core.tests.shared.TmfTestHelper;
-import org.eclipse.tracecompass.tmf.core.trace.TmfTraceManager;
-import org.eclipse.tracecompass.tmf.ctf.core.event.CtfTmfEvent;
-import org.eclipse.tracecompass.tmf.ctf.core.tests.shared.CtfTmfTestTrace;
-import org.junit.Test;
-
-/**
- * This is a test of the time to build a kernel state system
- *
- * @author Genevieve Bastien
- */
-public class AnalysisBenchmark {
-
-    private static final String TEST_ID = "org.eclipse.linuxtools#LTTng kernel analysis";
-    private static final int LOOP_COUNT = 25;
-
-    /**
-     * Run the benchmark with "trace2"
-     */
-    @Test
-    public void testTrace2() {
-        runTest(CtfTmfTestTrace.TRACE2, "Trace2");
-    }
-
-    private static void runTest(CtfTmfTestTrace testTrace, String testName) {
-        assumeTrue(testTrace.exists());
-
-        Performance perf = Performance.getDefault();
-        PerformanceMeter pm = perf.createPerformanceMeter(TEST_ID + '#' + testName);
-        perf.tagAsSummary(pm, "LTTng Kernel Analysis: " + testName, Dimension.CPU_TIME);
-
-        if (testTrace == CtfTmfTestTrace.TRACE2) {
-            /* Do not show all traces in the global summary */
-            perf.tagAsGlobalSummary(pm, "LTTng Kernel Analysis: " + testName, Dimension.CPU_TIME);
-        }
-
-        for (int i = 0; i < LOOP_COUNT; i++) {
-            IAnalysisModule module = null;
-            try (LttngKernelTrace trace = new LttngKernelTrace()) {
-                module = new KernelAnalysisModule();
-                module.setId("test");
-                trace.initTrace(null, testTrace.getPath(), CtfTmfEvent.class);
-                module.setTrace(trace);
-
-                pm.start();
-                TmfTestHelper.executeAnalysis(module);
-                pm.stop();
-
-                /*
-                 * Delete the supplementary files, so that the next iteration
-                 * rebuilds the state system.
-                 */
-                File suppDir = new File(TmfTraceManager.getSupplementaryFileDir(trace));
-                for (File file : suppDir.listFiles()) {
-                    file.delete();
-                }
-
-            } catch (TmfAnalysisException | TmfTraceException e) {
-                fail(e.getMessage());
-            } finally {
-                if (module != null) {
-                    module.dispose();
-                }
-            }
-        }
-        pm.commit();
-        testTrace.dispose();
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core.tests/perf/org/eclipse/tracecompass/lttng2/kernel/core/tests/perf/event/matching/AllPerfTests.java b/org.eclipse.tracecompass.lttng2.kernel.core.tests/perf/org/eclipse/tracecompass/lttng2/kernel/core/tests/perf/event/matching/AllPerfTests.java
deleted file mode 100644 (file)
index a9b017b..0000000
+++ /dev/null
@@ -1,28 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2014 École Polytechnique de Montréal
- *
- * 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:
- *   Geneviève Bastien - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.kernel.core.tests.perf.event.matching;
-
-import org.junit.runner.RunWith;
-import org.junit.runners.Suite;
-
-/**
- * Test suite
- */
-@RunWith(Suite.class)
-@Suite.SuiteClasses({
-        EventMatchingBenchmark.class,
-        TraceSynchronizationBenchmark.class
-})
-public class AllPerfTests {
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core.tests/perf/org/eclipse/tracecompass/lttng2/kernel/core/tests/perf/event/matching/EventMatchingBenchmark.java b/org.eclipse.tracecompass.lttng2.kernel.core.tests/perf/org/eclipse/tracecompass/lttng2/kernel/core/tests/perf/event/matching/EventMatchingBenchmark.java
deleted file mode 100644 (file)
index 4e35cf4..0000000
+++ /dev/null
@@ -1,119 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2014 École Polytechnique de Montréal
- *
- * 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:
- *   Geneviève Bastien - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.kernel.core.tests.perf.event.matching;
-
-import static org.junit.Assume.assumeTrue;
-
-import java.util.Set;
-
-import org.eclipse.test.performance.Dimension;
-import org.eclipse.test.performance.Performance;
-import org.eclipse.test.performance.PerformanceMeter;
-import org.eclipse.tracecompass.internal.lttng2.kernel.core.event.matching.TcpEventMatching;
-import org.eclipse.tracecompass.internal.lttng2.kernel.core.event.matching.TcpLttngEventMatching;
-import org.eclipse.tracecompass.tmf.core.event.matching.TmfEventMatching;
-import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace;
-import org.eclipse.tracecompass.tmf.ctf.core.tests.shared.CtfTmfTestTrace;
-import org.eclipse.tracecompass.tmf.ctf.core.trace.CtfTmfTrace;
-import org.junit.BeforeClass;
-import org.junit.Test;
-
-import com.google.common.collect.ImmutableSet;
-
-/**
- * Benchmark simple event matching, without trace synchronization
- *
- * @author Geneviève Bastien
- */
-public class EventMatchingBenchmark {
-
-    private static final String TEST_ID = "org.eclipse.linuxtools#Event matching#";
-    private static final String TIME = " (time)";
-    private static final String MEMORY = " (memory usage)";
-    private static final String TEST_SUMMARY = "Event matching";
-
-    /**
-     * Initialize some data
-     */
-    @BeforeClass
-    public static void setUp() {
-        TmfEventMatching.registerMatchObject(new TcpEventMatching());
-        TmfEventMatching.registerMatchObject(new TcpLttngEventMatching());
-    }
-
-    /**
-     * Run the benchmark with 2 small traces
-     */
-    @Test
-    public void testSmallTraces() {
-        assumeTrue(CtfTmfTestTrace.SYNC_SRC.exists());
-        assumeTrue(CtfTmfTestTrace.SYNC_DEST.exists());
-        try (CtfTmfTrace trace1 = CtfTmfTestTrace.SYNC_SRC.getTrace();
-                CtfTmfTrace trace2 = CtfTmfTestTrace.SYNC_DEST.getTrace();) {
-            Set<ITmfTrace> traces = ImmutableSet.of((ITmfTrace) trace1, trace2);
-            runCpuTest(traces, "Match TCP events", 100);
-        }
-    }
-
-    /**
-     * Run the benchmark with 3 bigger traces
-     */
-    @Test
-    public void testDjangoTraces() {
-        assumeTrue(CtfTmfTestTrace.DJANGO_CLIENT.exists());
-        assumeTrue(CtfTmfTestTrace.DJANGO_DB.exists());
-        assumeTrue(CtfTmfTestTrace.DJANGO_HTTPD.exists());
-        try (CtfTmfTrace trace1 = CtfTmfTestTrace.DJANGO_CLIENT.getTrace();
-                CtfTmfTrace trace2 = CtfTmfTestTrace.DJANGO_DB.getTrace();
-                CtfTmfTrace trace3 = CtfTmfTestTrace.DJANGO_HTTPD.getTrace();) {
-            Set<ITmfTrace> traces = ImmutableSet.of((ITmfTrace) trace1, trace2, trace3);
-            runCpuTest(traces, "Django traces", 10);
-            runMemoryTest(traces, "Django traces", 10);
-        }
-    }
-
-    private static void runCpuTest(Set<ITmfTrace> testTraces, String testName, int loop_count) {
-        Performance perf = Performance.getDefault();
-        PerformanceMeter pm = perf.createPerformanceMeter(TEST_ID + testName + TIME);
-        perf.tagAsSummary(pm, TEST_SUMMARY + ':' + testName + TIME, Dimension.CPU_TIME);
-
-        for (int i = 0; i < loop_count; i++) {
-            TmfEventMatching traceMatch = new TmfEventMatching(testTraces);
-
-            pm.start();
-            traceMatch.matchEvents();
-            pm.stop();
-        }
-        pm.commit();
-
-    }
-
-    /* Benchmark memory used by the algorithm */
-    private static void runMemoryTest(Set<ITmfTrace> testTraces, String testName, int loop_count) {
-        Performance perf = Performance.getDefault();
-        PerformanceMeter pm = perf.createPerformanceMeter(TEST_ID + testName + MEMORY);
-        perf.tagAsSummary(pm, TEST_SUMMARY + ':' + testName + MEMORY, Dimension.USED_JAVA_HEAP);
-
-        for (int i = 0; i < loop_count; i++) {
-            TmfEventMatching traceMatch = new TmfEventMatching(testTraces);
-
-            System.gc();
-            pm.start();
-            traceMatch.matchEvents();
-            System.gc();
-            pm.stop();
-        }
-        pm.commit();
-
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core.tests/perf/org/eclipse/tracecompass/lttng2/kernel/core/tests/perf/event/matching/TraceSynchronizationBenchmark.java b/org.eclipse.tracecompass.lttng2.kernel.core.tests/perf/org/eclipse/tracecompass/lttng2/kernel/core/tests/perf/event/matching/TraceSynchronizationBenchmark.java
deleted file mode 100644 (file)
index 802bc8a..0000000
+++ /dev/null
@@ -1,122 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2014 École Polytechnique de Montréal
- *
- * 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:
- *   Geneviève Bastien - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.kernel.core.tests.perf.event.matching;
-
-import static org.junit.Assert.assertNotNull;
-import static org.junit.Assume.assumeTrue;
-
-import java.util.Collections;
-
-import org.eclipse.test.performance.Dimension;
-import org.eclipse.test.performance.Performance;
-import org.eclipse.test.performance.PerformanceMeter;
-import org.eclipse.tracecompass.internal.lttng2.kernel.core.event.matching.TcpEventMatching;
-import org.eclipse.tracecompass.internal.lttng2.kernel.core.event.matching.TcpLttngEventMatching;
-import org.eclipse.tracecompass.tmf.core.event.matching.TmfEventMatching;
-import org.eclipse.tracecompass.tmf.core.synchronization.SynchronizationAlgorithm;
-import org.eclipse.tracecompass.tmf.core.synchronization.SynchronizationManager;
-import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace;
-import org.eclipse.tracecompass.tmf.core.trace.experiment.TmfExperiment;
-import org.eclipse.tracecompass.tmf.ctf.core.event.CtfTmfEvent;
-import org.eclipse.tracecompass.tmf.ctf.core.tests.shared.CtfTmfTestTrace;
-import org.eclipse.tracecompass.tmf.ctf.core.trace.CtfTmfTrace;
-import org.junit.BeforeClass;
-import org.junit.Test;
-
-/**
- * Benchmark trace synchronization
- *
- * @author Geneviève Bastien
- */
-public class TraceSynchronizationBenchmark {
-
-    private static final String TEST_ID = "org.eclipse.linuxtools#Trace synchronization#";
-    private static final String TIME = " (time)";
-    private static final String MEMORY = " (memory usage)";
-    private static final String TEST_SUMMARY = "Trace synchronization";
-
-    /**
-     * Initialize some data
-     */
-    @BeforeClass
-    public static void setUp() {
-        TmfEventMatching.registerMatchObject(new TcpEventMatching());
-        TmfEventMatching.registerMatchObject(new TcpLttngEventMatching());
-    }
-
-    /**
-     * Run the benchmark with 2 small traces
-     */
-    @Test
-    public void testSmallTraces() {
-        assumeTrue(CtfTmfTestTrace.SYNC_SRC.exists());
-        assumeTrue(CtfTmfTestTrace.SYNC_DEST.exists());
-        try (CtfTmfTrace trace1 = CtfTmfTestTrace.SYNC_SRC.getTrace();
-                CtfTmfTrace trace2 = CtfTmfTestTrace.SYNC_DEST.getTrace();) {
-            ITmfTrace[] traces = { trace1, trace2 };
-            TmfExperiment experiment = new TmfExperiment(CtfTmfEvent.class, "Test experiment", traces, TmfExperiment.DEFAULT_INDEX_PAGE_SIZE, null);
-            runCpuTest(experiment, "Match TCP events", 40);
-        }
-    }
-
-    /**
-     * Run the benchmark with 3 bigger traces
-     */
-    @Test
-    public void testDjangoTraces() {
-        assumeTrue(CtfTmfTestTrace.DJANGO_CLIENT.exists());
-        assumeTrue(CtfTmfTestTrace.DJANGO_DB.exists());
-        assumeTrue(CtfTmfTestTrace.DJANGO_HTTPD.exists());
-        try (CtfTmfTrace trace1 = CtfTmfTestTrace.DJANGO_CLIENT.getTrace();
-                CtfTmfTrace trace2 = CtfTmfTestTrace.DJANGO_DB.getTrace();
-                CtfTmfTrace trace3 = CtfTmfTestTrace.DJANGO_HTTPD.getTrace();) {
-            ITmfTrace[] traces = { trace1, trace2, trace3 };
-            TmfExperiment experiment = new TmfExperiment(CtfTmfEvent.class, "Test experiment", traces, TmfExperiment.DEFAULT_INDEX_PAGE_SIZE, null);
-            runCpuTest(experiment, "Django traces", 10);
-            runMemoryTest(experiment, "Django traces", 10);
-        }
-    }
-
-    private static void runCpuTest(TmfExperiment experiment, String testName, int loop_count) {
-        Performance perf = Performance.getDefault();
-        PerformanceMeter pm = perf.createPerformanceMeter(TEST_ID + testName + TIME);
-        perf.tagAsSummary(pm, TEST_SUMMARY + ':' + testName + TIME, Dimension.CPU_TIME);
-
-        for (int i = 0; i < loop_count; i++) {
-            pm.start();
-            SynchronizationManager.synchronizeTraces(null, Collections.<ITmfTrace> singleton(experiment), true);
-            pm.stop();
-        }
-        pm.commit();
-
-    }
-
-    /* Benchmark memory used by the algorithm */
-    private static void runMemoryTest(TmfExperiment experiment, String testName, int loop_count) {
-        Performance perf = Performance.getDefault();
-        PerformanceMeter pm = perf.createPerformanceMeter(TEST_ID + testName + MEMORY);
-        perf.tagAsSummary(pm, TEST_SUMMARY + ':' + testName + MEMORY, Dimension.USED_JAVA_HEAP);
-
-        for (int i = 0; i < loop_count; i++) {
-
-            System.gc();
-            pm.start();
-            SynchronizationAlgorithm algo = SynchronizationManager.synchronizeTraces(null, Collections.<ITmfTrace> singleton(experiment), true);
-            assertNotNull(algo);
-
-            System.gc();
-            pm.stop();
-        }
-        pm.commit();
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core.tests/plugin.properties b/org.eclipse.tracecompass.lttng2.kernel.core.tests/plugin.properties
deleted file mode 100644 (file)
index 5ed44d2..0000000
+++ /dev/null
@@ -1,14 +0,0 @@
-###############################################################################
-# Copyright (c) 2013, 2014 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:
-#     Ericsson - Initial API and implementation
-###############################################################################
-
-Bundle-Vendor = Eclipse Trace Compass
-Bundle-Name = Trace Compass LTTng Kernel Analysis Core Tests Plug-in
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core.tests/pom.xml b/org.eclipse.tracecompass.lttng2.kernel.core.tests/pom.xml
deleted file mode 100644 (file)
index 5e6e666..0000000
+++ /dev/null
@@ -1,44 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-   Copyright (C) 2011, Red Hat, Inc.
-
-   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
--->
-<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>
-    <artifactId>org.eclipse.tracecompass</artifactId>
-    <groupId>org.eclipse.tracecompass</groupId>
-    <version>1.0.0-SNAPSHOT</version>
-  </parent>
-
-  <artifactId>org.eclipse.tracecompass.lttng2.kernel.core.tests</artifactId>
-  <version>1.0.0-SNAPSHOT</version>
-  <packaging>eclipse-test-plugin</packaging>
-
-  <name>Trace Compass LTTng Kernel Analysis Core Tests Plug-in</name>
-
- <build>
-    <plugins>
-      <plugin>
-        <groupId>org.eclipse.tycho</groupId>
-        <artifactId>tycho-surefire-plugin</artifactId>
-        <version>${tycho-version}</version>
-        <configuration>
-          <testSuite>org.eclipse.tracecompass.lttng2.kernel.core.tests</testSuite>
-          <testClass>org.eclipse.tracecompass.lttng2.kernel.core.tests.AllTests</testClass>
-          <useUIHarness>false</useUIHarness>
-          <useUIThread>false</useUIThread>
-          <product>org.eclipse.platform.ide</product>
-        </configuration>
-      </plugin>
-    </plugins>
-  </build>
-
- <groupId>org.eclipse.tracecompass</groupId>
-</project>
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core.tests/shared/org/eclipse/tracecompass/lttng2/lttng/kernel/core/tests/shared/vm/VmTestExperiment.java b/org.eclipse.tracecompass.lttng2.kernel.core.tests/shared/org/eclipse/tracecompass/lttng2/lttng/kernel/core/tests/shared/vm/VmTestExperiment.java
deleted file mode 100644 (file)
index 8fe1869..0000000
+++ /dev/null
@@ -1,95 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2014 École Polytechnique de Montréal
- *
- * 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:
- *   Geneviève Bastien - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.lttng.kernel.core.tests.shared.vm;
-
-import java.io.File;
-import java.util.HashSet;
-import java.util.Set;
-
-import org.eclipse.jdt.annotation.NonNull;
-import org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.trace.VirtualMachineExperiment;
-import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace;
-import org.eclipse.tracecompass.tmf.core.trace.TmfTraceManager;
-import org.eclipse.tracecompass.tmf.core.trace.experiment.TmfExperiment;
-
-/**
- * List virtual machine experiments that can be used in unit tests
- *
- * @author Geneviève Bastien
- */
-public enum VmTestExperiment {
-
-    /**
-     * Virtual machine experiment: 1 guest, 1 host, using QEMU/KVM model
-     */
-    ONE_QEMUKVM(VmTraces.HOST_ONE_QEMUKVM, VmTraces.GUEST_ONE_QEMUKVM);
-
-    private Set<VmTraces> fTraces = new HashSet<>();
-
-    private VmTestExperiment(VmTraces... traces) {
-        for (VmTraces trace : traces) {
-            fTraces.add(trace);
-        }
-    }
-
-    /**
-     * Return a VirtualMachineExperiment object for this experiment with all its
-     * traces. It will be already initTrace()'ed.
-     *
-     * Make sure you call {@link #exists()} before calling this! This will make
-     * sure all traces in the experiment are available
-     *
-     * After being used by unit tests, the experiment must be properly disposed
-     * of by calling the {@link VirtualMachineExperiment#dispose()} method on
-     * the object returned by this method.
-     *
-     * @param deleteSuppFiles
-     *            Indicate whether to make sure supplementary files are deleted
-     * @return A VirtualMachineExperiment object corresponding to this
-     *         experiment
-     */
-    public synchronized TmfExperiment getExperiment(boolean deleteSuppFiles) {
-        Set<ITmfTrace> traces = new HashSet<>();
-        for (VmTraces trace : fTraces) {
-            traces.add(trace.getTrace());
-        }
-        @SuppressWarnings("null")
-        @NonNull String expName = this.name();
-        VirtualMachineExperiment experiment = new VirtualMachineExperiment(expName, traces);
-        if (deleteSuppFiles) {
-            /*
-             * Delete the supplementary files, so that the next iteration
-             * rebuilds the state system.
-             */
-            File suppDir = new File(TmfTraceManager.getSupplementaryFileDir(experiment));
-            for (File file : suppDir.listFiles()) {
-                file.delete();
-            }
-        }
-        return experiment;
-    }
-
-    /**
-     * Check if all the traces actually exist on disk or not.
-     *
-     * @return If all traces for this experiment are present
-     */
-    public boolean exists() {
-        boolean exists = true;
-        for (VmTraces trace : fTraces) {
-            exists &= trace.exists();
-        }
-        return exists;
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core.tests/shared/org/eclipse/tracecompass/lttng2/lttng/kernel/core/tests/shared/vm/VmTraces.java b/org.eclipse.tracecompass.lttng2.kernel.core.tests/shared/org/eclipse/tracecompass/lttng2/lttng/kernel/core/tests/shared/vm/VmTraces.java
deleted file mode 100644 (file)
index e464161..0000000
+++ /dev/null
@@ -1,94 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2014 École Polytechnique de Montréal
- *
- * 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:
- *   Geneviève Bastien - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.lttng.kernel.core.tests.shared.vm;
-
-import java.io.File;
-import java.io.IOException;
-import java.net.URL;
-
-import org.eclipse.core.runtime.FileLocator;
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Path;
-import org.eclipse.jdt.annotation.NonNull;
-import org.eclipse.tracecompass.lttng2.kernel.core.tests.Activator;
-import org.eclipse.tracecompass.tmf.core.event.TmfEvent;
-import org.eclipse.tracecompass.tmf.core.exceptions.TmfTraceException;
-import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace;
-import org.eclipse.tracecompass.tmf.tests.stubs.trace.xml.TmfXmlTraceStub;
-
-/**
- * List the available virtual machine host and guest traces
- *
- * @author Geneviève Bastien
- */
-public enum VmTraces {
-
-    /** Host from simple QEMU/KVM experiment */
-    HOST_ONE_QEMUKVM("vm/OneQemuKvm/host.xml"),
-    /** Guest from simple QEMU/KVM experiment */
-    GUEST_ONE_QEMUKVM("vm/OneQemuKvm/guest.xml");
-
-    private static final @NonNull String filePath = "testfiles";
-
-    private final IPath fPath;
-
-    VmTraces(String path) {
-        IPath relativePath = new Path(filePath + File.separator + path);
-        Activator plugin = Activator.getDefault();
-        if (plugin == null) {
-            /*
-             * Shouldn't happen but at least throw something to get the test to
-             * fail early
-             */
-            throw new IllegalStateException();
-        }
-        URL location = FileLocator.find(plugin.getBundle(), relativePath, null);
-        try {
-            fPath = new Path(FileLocator.toFileURL(location).getPath());
-        } catch (IOException e) {
-            throw new IllegalStateException();
-        }
-    }
-
-    /**
-     * Return a TmfXmlTraceStub object of this test trace. It will be already
-     * initTrace()'ed.
-     *
-     * Make sure you call {@link #exists()} before calling this!
-     *
-     * @return A TmfXmlTraceStub reference to this trace
-     */
-    public ITmfTrace getTrace() {
-        ITmfTrace trace = new TmfXmlTraceStub();
-        IStatus status = trace.validate(null, fPath.toOSString());
-        if (!status.isOK()) {
-            return null;
-        }
-        try {
-            trace.initTrace(null, fPath.toOSString(), TmfEvent.class);
-        } catch (TmfTraceException e) {
-            return null;
-        }
-        return trace;
-    }
-
-    /**
-     * Check if the trace actually exists on disk or not.
-     *
-     * @return If the trace is present
-     */
-    public boolean exists() {
-        return fPath.toFile().exists();
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/Activator.java b/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/Activator.java
deleted file mode 100644 (file)
index 2b12ca1..0000000
+++ /dev/null
@@ -1,106 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2014 École Polytechnique de Montréal
- *
- * 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:
- *   Geneviève Bastien - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.kernel.core.tests;
-
-import java.io.IOException;
-import java.net.URL;
-
-import org.eclipse.core.runtime.FileLocator;
-import org.eclipse.core.runtime.IPath;
-import org.eclipse.core.runtime.Path;
-import org.eclipse.core.runtime.Plugin;
-import org.osgi.framework.BundleContext;
-
-/**
- * Activator for the lttng2.kernel.core.tests plugin
- *
- * @author Geneviève Bastien
- */
-public class Activator extends Plugin {
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-
-    /**
-     * The plug-in ID
-     */
-    public static final String PLUGIN_ID = "org.eclipse.tracecompass.lttng2.kernel.core.tests"; //$NON-NLS-1$
-
-    /**
-     * The shared instance
-     */
-    private static Activator PLUGIN;
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-
-    /**
-     * The constructor
-     */
-    public Activator() {
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    /**
-     * Returns the shared instance
-     *
-     * @return the shared instance
-     */
-    public static Activator getDefault() {
-        return PLUGIN;
-    }
-
-    // ------------------------------------------------------------------------
-    // Operators
-    // ------------------------------------------------------------------------
-
-    @Override
-    public void start(BundleContext context) throws Exception {
-        super.start(context);
-        PLUGIN = this;
-    }
-
-    @Override
-    public void stop(BundleContext context) throws Exception {
-        PLUGIN = null;
-        super.stop(context);
-    }
-
-    /**
-     * Return a path to a file relative to this plugin's base directory
-     *
-     * @param relativePath
-     *            The path relative to the plugin's root directory
-     * @return The path corresponding to the relative path in parameter
-     */
-    public static IPath getAbsoluteFilePath(String relativePath) {
-        Activator plugin = Activator.getDefault();
-        if (plugin == null) {
-            /*
-             * Shouldn't happen but at least throw something to get the test to
-             * fail early
-             */
-            throw new IllegalStateException();
-        }
-        URL location = FileLocator.find(plugin.getBundle(), new Path(relativePath), null);
-        try {
-            return new Path(FileLocator.toFileURL(location).getPath());
-        } catch (IOException e) {
-            throw new IllegalStateException();
-        }
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/ActivatorTest.java b/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/ActivatorTest.java
deleted file mode 100644 (file)
index 12b265c..0000000
+++ /dev/null
@@ -1,96 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2012, 2015 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:
- *   Francois Chouinard - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.kernel.core.tests;
-
-import junit.framework.TestCase;
-
-import org.junit.After;
-import org.junit.AfterClass;
-import org.junit.Before;
-import org.junit.BeforeClass;
-import org.junit.Test;
-
-/**
- * <b><u>ActivatorTest</u></b>
- * <p>
- * Test suite for the Activator class
- * <p>
- */
-@SuppressWarnings("javadoc")
-public class ActivatorTest extends TestCase {
-
-    // ------------------------------------------------------------------------
-    // JUnit
-    // ------------------------------------------------------------------------
-
-    @BeforeClass
-    public static void setUpBeforeClass() {
-    }
-
-    @AfterClass
-    public static void tearDownAfterClass() {
-    }
-
-    /**
-     * @throws java.lang.Exception
-     */
-    @Before
-    @Override
-    public void setUp() throws Exception {
-    }
-
-    /**
-     * @throws java.lang.Exception
-     */
-    @After
-    @Override
-    public void tearDown() throws Exception {
-    }
-
-    // ------------------------------------------------------------------------
-    // Tests
-    // ------------------------------------------------------------------------
-
-    /**
-     * Test method for {@link org.eclipse.tracecompass.lttng2.kernel.core.Activator#Activator()}.
-     */
-    @Test
-    public void testActivator() {
-        assertTrue(true);
-    }
-
-    /**
-     * Test method for {@link org.eclipse.tracecompass.lttng2.kernel.core.Activator#getDefault()}.
-     */
-    @Test
-    public void testGetDefault() {
-        assertTrue(true);
-    }
-
-    /**
-     * Test method for {@link org.eclipse.tracecompass.lttng2.kernel.core.Activator#start(org.osgi.framework.BundleContext)}.
-     */
-    @Test
-    public void testStartBundleContext() {
-        assertTrue(true);
-    }
-
-    /**
-     * Test method for {@link org.eclipse.tracecompass.lttng2.kernel.core.Activator#stop(org.osgi.framework.BundleContext)}.
-     */
-    @Test
-    public void testStopBundleContext() {
-        assertTrue(true);
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/AllTests.java b/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/AllTests.java
deleted file mode 100644 (file)
index 2150b4e..0000000
+++ /dev/null
@@ -1,31 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2012, 2015 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:
- *   Francois Chouinard - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.kernel.core.tests;
-
-import org.eclipse.tracecompass.tmf.core.tests.shared.DebugSuite;
-import org.junit.runner.RunWith;
-
-/**
- * Runner for the lttng2.kernel unit tests.
- */
-@RunWith(DebugSuite.class)
-@DebugSuite.SuiteClasses({
-    ActivatorTest.class,
-    org.eclipse.tracecompass.lttng2.kernel.core.tests.analysis.kernel.AllTests.class,
-    org.eclipse.tracecompass.lttng2.kernel.core.tests.analysis.kernel.statesystem.TestAll.class,
-    org.eclipse.tracecompass.lttng2.kernel.core.tests.analysis.vm.AllTests.class,
-    org.eclipse.tracecompass.lttng2.kernel.core.tests.event.matchandsync.AllTests.class
-})
-public class AllTests {
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/AllTests.java b/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/AllTests.java
deleted file mode 100644 (file)
index 8db6614..0000000
+++ /dev/null
@@ -1,27 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2014, 2015 École Polytechnique de Montréal
- *
- * 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:
- *   Geneviève Bastien - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.kernel.core.tests.analysis.kernel;
-
-import org.junit.runner.RunWith;
-import org.junit.runners.Suite;
-
-/**
- * Test suite for org.eclipse.linuxtools.lttng2.kernel.core.analysis package
- */
-@RunWith(Suite.class)
-@Suite.SuiteClasses({
-    LttngKernelAnalysisTest.class
-})
-public class AllTests {
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/LttngKernelAnalysisTest.java b/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/LttngKernelAnalysisTest.java
deleted file mode 100644 (file)
index 6d6a697..0000000
+++ /dev/null
@@ -1,197 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2014, 2015 École Polytechnique de Montréal
- *
- * 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:
- *   Geneviève Bastien - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.kernel.core.tests.analysis.kernel;
-
-import static org.junit.Assert.assertEquals;
-import static org.junit.Assert.assertFalse;
-import static org.junit.Assert.assertNotNull;
-import static org.junit.Assert.assertNull;
-import static org.junit.Assert.assertTrue;
-import static org.junit.Assert.fail;
-import static org.junit.Assume.assumeTrue;
-
-import java.util.List;
-import java.util.Set;
-
-import org.eclipse.tracecompass.analysis.os.linux.core.kernelanalysis.KernelAnalysisModule;
-import org.eclipse.tracecompass.lttng2.control.core.session.SessionConfigStrings;
-import org.eclipse.tracecompass.lttng2.kernel.core.trace.LttngKernelTrace;
-import org.eclipse.tracecompass.statesystem.core.ITmfStateSystem;
-import org.eclipse.tracecompass.tmf.core.analysis.TmfAnalysisRequirement;
-import org.eclipse.tracecompass.tmf.core.exceptions.TmfAnalysisException;
-import org.eclipse.tracecompass.tmf.core.exceptions.TmfTraceException;
-import org.eclipse.tracecompass.tmf.core.tests.shared.TmfTestHelper;
-import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace;
-import org.eclipse.tracecompass.tmf.ctf.core.event.CtfTmfEvent;
-import org.eclipse.tracecompass.tmf.ctf.core.tests.shared.CtfTmfTestTrace;
-import org.eclipse.tracecompass.tmf.ctf.core.trace.CtfTmfTrace;
-import org.junit.After;
-import org.junit.Before;
-import org.junit.BeforeClass;
-import org.junit.Ignore;
-import org.junit.Test;
-
-import com.google.common.collect.ImmutableSet;
-
-/**
- * Test the {@link KernelAnalysisModule} class
- *
- * @author Geneviève Bastien
- */
-public class LttngKernelAnalysisTest {
-
-    private LttngKernelTrace fTrace;
-    private KernelAnalysisModule fKernelAnalysisModule;
-
-    /**
-     * Class setup
-     */
-    @BeforeClass
-    public static void setUpClass() {
-        assumeTrue(CtfTmfTestTrace.KERNEL.exists());
-    }
-
-    /**
-     * Set-up the test
-     */
-    @Before
-    public void setUp() {
-        fKernelAnalysisModule = new KernelAnalysisModule();
-        fTrace = new LttngKernelTrace();
-        try {
-            fTrace.initTrace(null, CtfTmfTestTrace.KERNEL.getPath(), CtfTmfEvent.class);
-        } catch (TmfTraceException e) {
-            /* Should not happen if tracesExist() passed */
-            throw new RuntimeException(e);
-        }
-    }
-
-    /**
-     * Dispose test objects
-     */
-    @After
-    public void tearDown() {
-        fTrace.dispose();
-        fKernelAnalysisModule.dispose();
-        fTrace = null;
-        fKernelAnalysisModule = null;
-    }
-
-    /**
-     * Test the LTTng kernel analysis execution
-     */
-    @Test
-    public void testAnalysisExecution() {
-        fKernelAnalysisModule.setId("test");
-        ITmfTrace trace = fTrace;
-        assertNotNull(trace);
-        try {
-            assertTrue(fKernelAnalysisModule.setTrace(trace));
-        } catch (TmfAnalysisException e) {
-            fail(e.getMessage());
-        }
-        // Assert the state system has not been initialized yet
-        ITmfStateSystem ss = fKernelAnalysisModule.getStateSystem();
-        assertNull(ss);
-
-        assertTrue(TmfTestHelper.executeAnalysis(fKernelAnalysisModule));
-
-        ss = fKernelAnalysisModule.getStateSystem();
-        assertNotNull(ss);
-
-        List<Integer> quarks = ss.getQuarks("*");
-        assertFalse(quarks.isEmpty());
-    }
-
-    /**
-     * Test the canExecute method on valid and invalid traces
-     */
-    @Test
-    public void testCanExecute() {
-        /* Test with a valid kernel trace */
-        assertNotNull(fTrace);
-        assertTrue(fKernelAnalysisModule.canExecute(fTrace));
-
-        /* Test with a CTF trace that does not have required events */
-        assumeTrue(CtfTmfTestTrace.CYG_PROFILE.exists());
-        try (CtfTmfTrace trace = CtfTmfTestTrace.CYG_PROFILE.getTrace();) {
-            /*
-             * TODO: This should be false, but for now there is no mandatory
-             * events in the kernel analysis so it will return true.
-             */
-            assertTrue(fKernelAnalysisModule.canExecute(trace));
-        }
-    }
-
-    /**
-     * Test for {@link KernelAnalysisModule#getAnalysisRequirements()}
-     *
-     * FIXME Ignored for now because the analysis does not provide any
-     * requirements (it doesn't look for particular event names anymore).
-     */
-    @Test
-    @Ignore
-    public void testGetAnalysisRequirements() {
-        Iterable<TmfAnalysisRequirement> requirements = fKernelAnalysisModule.getAnalysisRequirements();
-        assertNotNull(requirements);
-
-        /* There should be the event and domain type */
-        TmfAnalysisRequirement eventReq = null;
-        TmfAnalysisRequirement domainReq = null;
-        int numberOfRequirement = 0;
-        for (TmfAnalysisRequirement requirement : requirements) {
-            ++numberOfRequirement;
-            if (requirement.getType().equals(SessionConfigStrings.CONFIG_ELEMENT_EVENT)) {
-                eventReq = requirement;
-            } else if (requirement.getType().equals(SessionConfigStrings.CONFIG_ELEMENT_DOMAIN)) {
-                domainReq = requirement;
-            }
-        }
-        assertNotNull(eventReq);
-        assertNotNull(domainReq);
-
-        /* There should be two requirements */
-        assertEquals(2, numberOfRequirement);
-
-        /* Verify the content of the requirements themselves */
-        /* Domain should be kernel */
-        assertEquals(1, domainReq.getValues().size());
-        for (String domain : domainReq.getValues()) {
-            assertEquals(SessionConfigStrings.CONFIG_DOMAIN_TYPE_KERNEL, domain);
-        }
-
-        /* Events */
-        Set<String> expectedEvents = ImmutableSet.of(
-//                LttngStrings.EXIT_SYSCALL,
-//                LttngStrings.IRQ_HANDLER_ENTRY,
-//                LttngStrings.IRQ_HANDLER_EXIT,
-//                LttngStrings.SOFTIRQ_ENTRY,
-//                LttngStrings.SOFTIRQ_EXIT,
-//                LttngStrings.SOFTIRQ_RAISE,
-//                LttngStrings.SCHED_SWITCH,
-//                LttngStrings.SCHED_PROCESS_FORK,
-//                LttngStrings.SCHED_PROCESS_EXIT,
-//                LttngStrings.SCHED_PROCESS_FREE,
-//                LttngStrings.STATEDUMP_PROCESS_STATE,
-//                LttngStrings.SCHED_WAKEUP,
-//                LttngStrings.SCHED_WAKEUP_NEW,
-//                /* Add the prefix for syscalls */
-//                LttngStrings.SYSCALL_PREFIX
-                );
-
-        assertEquals(0, eventReq.getValues().size());
-        for (String event : eventReq.getValues()) {
-            assertTrue("Unexpected event " + event, expectedEvents.contains(event));
-        }
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/statesystem/GenerateTestValues.java b/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/statesystem/GenerateTestValues.java
deleted file mode 100644 (file)
index a63ca7f..0000000
+++ /dev/null
@@ -1,140 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2013, 2015 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:
- *   Alexandre Montplaisir - Initial API and implementation
- ******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.kernel.core.tests.analysis.kernel.statesystem;
-
-import java.io.File;
-import java.io.FileWriter;
-import java.io.PrintWriter;
-import java.util.List;
-
-import org.eclipse.tracecompass.analysis.os.linux.core.kernelanalysis.KernelAnalysisModule;
-import org.eclipse.tracecompass.statesystem.core.ITmfStateSystem;
-import org.eclipse.tracecompass.statesystem.core.interval.ITmfStateInterval;
-import org.eclipse.tracecompass.statesystem.core.statevalue.ITmfStateValue;
-import org.eclipse.tracecompass.tmf.core.statesystem.TmfStateSystemAnalysisModule;
-import org.eclipse.tracecompass.tmf.ctf.core.tests.shared.CtfTmfTestTrace;
-import org.eclipse.tracecompass.tmf.ctf.core.trace.CtfTmfTrace;
-
-/**
- * Small program to regenerate the values used in "TestValues.java" from the
- * current LTTng-kernel state provider.
- *
- * It will write its output the a file called 'TestValues<something>.java' in your
- * temporary files directory.
- *
- * @author Alexandre Montplaisir
- */
-public class GenerateTestValues {
-
-    private static CtfTmfTestTrace testTrace = CtfTmfTestTrace.TRACE2;
-    private static final long targetTimestamp = 18670067372290L + 1331649577946812237L;
-    private static final String INDENT = "    ";
-
-    /**
-     * Run the program
-     *
-     * @param args
-     *            Command-line arguments, unused.
-     * @throws Exception
-     *             I'm messing with Exception. Come at me bro!
-     */
-    public static void main(String[] args) throws Exception {
-        if (!testTrace.exists()) {
-            System.err.println("Trace files not present.");
-            return;
-        }
-
-        /* Prepare the files */
-        File logFile = File.createTempFile("TestValues", ".java");
-        try (final CtfTmfTrace trace = testTrace.getTrace();
-                PrintWriter writer = new PrintWriter(new FileWriter(logFile), true);) {
-
-            /* Build and query the state system */
-            TmfStateSystemAnalysisModule module = new KernelAnalysisModule() {
-                @Override
-                protected String getSsFileName() {
-                    return "test-values";
-                }
-            };
-
-            if (!module.setTrace(trace)) {
-                throw new IllegalStateException();
-            }
-            module.setId("test-values");
-            module.schedule();
-            module.waitForCompletion();
-            ITmfStateSystem ssq = module.getStateSystem();
-            if (ssq == null) {
-                throw new IllegalStateException();
-            }
-
-            List<ITmfStateInterval> fullState = ssq.queryFullState(targetTimestamp);
-
-            /* Start printing the java file's contents */
-            writer.println("interface TestValues {");
-            writer.println();
-            writer.println(INDENT + "int size = " + fullState.size() + ";");
-            writer.println();
-
-            /* Print the array contents */
-            writer.println(INDENT + "long[] startTimes = {");
-            for (ITmfStateInterval interval : fullState) {
-                writer.println(INDENT + INDENT + String.valueOf(interval.getStartTime()) + "L,");
-            }
-            writer.println(INDENT + "};");
-            writer.println();
-
-            writer.println(INDENT + "long[] endTimes = {");
-            for (ITmfStateInterval interval : fullState) {
-                writer.println(INDENT + INDENT + String.valueOf(interval.getEndTime()) + "L,");
-            }
-            writer.println(INDENT + "};");
-            writer.println();
-
-            writer.println(INDENT + "ITmfStateValue[] values = {");
-            for (ITmfStateInterval interval : fullState) {
-                ITmfStateValue val = interval.getStateValue();
-                writer.print(INDENT + INDENT);
-
-                switch (val.getType()) {
-                case NULL:
-                    writer.println("TmfStateValue.nullValue(),");
-                    break;
-                case INTEGER:
-                    writer.println("TmfStateValue.newValueInt(" + val.unboxInt() + "),");
-                    break;
-                case LONG:
-                    writer.println("TmfStateValue.newValueLong(" + val.unboxLong() + "),");
-                    break;
-                case DOUBLE:
-                    writer.println("TmfStateValue.newValueDouble(" + val.unboxDouble() + "),");
-                    break;
-                case STRING:
-                    writer.println("TmfStateValue.newValueString(\"" + val.unboxStr() + "\"),");
-                    break;
-                default:
-                    writer.println(val.toString());
-                    break;
-                }
-            }
-            writer.println(INDENT + "};");
-
-            writer.println("}");
-            writer.println();
-
-            module.dispose();
-        }
-        System.exit(0);
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/statesystem/PartialStateSystemTest.java b/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/statesystem/PartialStateSystemTest.java
deleted file mode 100644 (file)
index 7dfbae8..0000000
+++ /dev/null
@@ -1,189 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2013, 2015 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:
- *   Alexandre Montplaisir - Initial API and implementation
- *   Bernd Hufmann - Use state system analysis module instead of factory
- ******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.kernel.core.tests.analysis.kernel.statesystem;
-
-import static org.junit.Assert.assertTrue;
-import static org.junit.Assert.fail;
-
-import java.io.File;
-
-import org.eclipse.jdt.annotation.NonNull;
-import org.eclipse.jdt.annotation.NonNullByDefault;
-import org.eclipse.jdt.annotation.Nullable;
-import org.eclipse.tracecompass.analysis.os.linux.core.kernelanalysis.KernelAnalysisModule;
-import org.eclipse.tracecompass.statesystem.core.exceptions.TimeRangeException;
-import org.eclipse.tracecompass.tmf.core.exceptions.TmfAnalysisException;
-import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace;
-import org.eclipse.tracecompass.tmf.core.trace.TmfTraceManager;
-import org.eclipse.tracecompass.tmf.ctf.core.trace.CtfTmfTrace;
-import org.junit.AfterClass;
-import org.junit.BeforeClass;
-import org.junit.Ignore;
-import org.junit.Test;
-
-/**
- * State system tests using a partial history.
- *
- * @author Alexandre Montplaisir
- */
-@Ignore
-public class PartialStateSystemTest extends StateSystemTest {
-
-    private static final @NonNull String TEST_FILE_NAME = "test-partial";
-
-    private static File stateFile;
-    private static TestLttngKernelAnalysisModule module;
-
-    /**
-     * Test class setup
-     */
-    @BeforeClass
-    public static void initialize() {
-        if (!testTrace.exists()) {
-            traceIsPresent = false;
-            return;
-        }
-        traceIsPresent = true;
-
-        stateFile = new File(TmfTraceManager.getSupplementaryFileDir(testTrace.getTrace()) + TEST_FILE_NAME);
-        if (stateFile.exists()) {
-            stateFile.delete();
-        }
-
-        module = new TestLttngKernelAnalysisModule(TEST_FILE_NAME);
-        try {
-            assertTrue(module.setTrace(testTrace.getTrace()));
-        } catch (TmfAnalysisException e) {
-            fail();
-        }
-        module.schedule();
-        assertTrue(module.waitForCompletion());
-
-        fixture = module.getStateSystem();
-    }
-
-    /**
-     * Class clean-up
-     */
-    @AfterClass
-    public static void cleanup() {
-        if (module != null) {
-            module.dispose();
-        }
-        if (stateFile != null) {
-            stateFile.delete();
-        }
-        if (fixture != null) {
-            fixture.dispose();
-        }
-        module = null;
-        fixture = null;
-    }
-
-    /**
-     * Partial histories cannot get the intervals' end times. The fake value that
-     * is returned is equal to the query's timestamp. So override this here
-     * so that {@link #testFullQueryThorough} keeps working.
-     */
-    @Override
-    protected long getEndTimes(int idx) {
-        return interestingTimestamp1;
-    }
-
-    // ------------------------------------------------------------------------
-    // Skip tests using single-queries (unsupported in partial history)
-    // ------------------------------------------------------------------------
-
-    @Override
-    @Test(expected = UnsupportedOperationException.class)
-    public void testSingleQuery1() {
-        super.testSingleQuery1();
-    }
-
-    @Override
-    @Test(expected = UnsupportedOperationException.class)
-    public void testRangeQuery1() {
-        super.testRangeQuery1();
-    }
-
-    @Override
-    @Test(expected = UnsupportedOperationException.class)
-    public void testRangeQuery2() {
-        super.testRangeQuery2();
-    }
-
-    @Override
-    @Test(expected = UnsupportedOperationException.class)
-    public void testRangeQuery3() {
-        super.testRangeQuery3();
-    }
-
-    @Override
-    @Test(expected = UnsupportedOperationException.class)
-    public void testSingleQueryInvalidTime1() throws TimeRangeException {
-        super.testSingleQueryInvalidTime1();
-    }
-
-    @Override
-    @Test(expected = UnsupportedOperationException.class)
-    public void testSingleQueryInvalidTime2() throws TimeRangeException {
-        super.testSingleQueryInvalidTime2();
-    }
-
-    @Override
-    @Test(expected = UnsupportedOperationException.class)
-    public void testRangeQueryInvalidTime1() throws TimeRangeException {
-        super.testRangeQueryInvalidTime1();
-    }
-
-    @Override
-    @Test(expected = UnsupportedOperationException.class)
-    public void testRangeQueryInvalidTime2() throws TimeRangeException {
-        super.testRangeQueryInvalidTime2();
-    }
-
-    @NonNullByDefault
-    private static class TestLttngKernelAnalysisModule extends KernelAnalysisModule {
-
-        private final String htFileName;
-
-        /**
-         * Constructor adding the views to the analysis
-         * @param htFileName
-         *      The History File Name
-         */
-        public TestLttngKernelAnalysisModule(String htFileName) {
-            super();
-            this.htFileName = htFileName;
-        }
-
-        @Override
-        public boolean setTrace(@Nullable ITmfTrace trace) throws TmfAnalysisException {
-            if (!(trace instanceof CtfTmfTrace)) {
-                return false;
-            }
-            return super.setTrace(trace);
-        }
-
-        @Override
-        protected StateSystemBackendType getBackendType() {
-            return StateSystemBackendType.PARTIAL;
-        }
-
-        @Override
-        protected String getSsFileName() {
-            return htFileName;
-        }
-
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/statesystem/StateSystemFullHistoryTest.java b/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/statesystem/StateSystemFullHistoryTest.java
deleted file mode 100644 (file)
index ad4f25c..0000000
+++ /dev/null
@@ -1,192 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2012, 2015 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:
- *   Alexandre Montplaisir - Initial API and implementation
- *   Bernd Hufmann - Use state system analysis module instead of factory
- ******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.kernel.core.tests.analysis.kernel.statesystem;
-
-import static org.junit.Assert.assertEquals;
-import static org.junit.Assert.assertNotNull;
-import static org.junit.Assert.assertTrue;
-import static org.junit.Assert.fail;
-
-import java.io.File;
-
-import org.eclipse.jdt.annotation.NonNull;
-import org.eclipse.jdt.annotation.NonNullByDefault;
-import org.eclipse.jdt.annotation.Nullable;
-import org.eclipse.tracecompass.analysis.os.linux.core.kernelanalysis.KernelAnalysisModule;
-import org.eclipse.tracecompass.statesystem.core.ITmfStateSystem;
-import org.eclipse.tracecompass.tmf.core.exceptions.TmfAnalysisException;
-import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace;
-import org.eclipse.tracecompass.tmf.core.trace.TmfTraceManager;
-import org.eclipse.tracecompass.tmf.ctf.core.trace.CtfTmfTrace;
-import org.junit.AfterClass;
-import org.junit.BeforeClass;
-import org.junit.Test;
-
-/**
- * State system tests using a full history back-end and the LTTng kernel state
- * input.
- *
- * @author Alexandre Montplaisir
- */
-public class StateSystemFullHistoryTest extends StateSystemTest {
-
-    private static final @NonNull String TEST_FILE_NAME = "test.ht";
-    private static final @NonNull String BENCHMARK_FILE_NAME = "test.benchmark.ht";
-
-    private static File stateFile;
-    private static File stateFileBenchmark;
-    private static TestLttngKernelAnalysisModule module;
-
-    /**
-     * Test class setup
-     */
-    @BeforeClass
-    public static void initialize() {
-        if (!testTrace.exists()) {
-            traceIsPresent = false;
-            return;
-        }
-        traceIsPresent = true;
-
-        stateFile = createStateFile(TEST_FILE_NAME);
-        stateFileBenchmark = createStateFile(BENCHMARK_FILE_NAME);
-
-        module = new TestLttngKernelAnalysisModule(TEST_FILE_NAME);
-        try {
-            assertTrue(module.setTrace(testTrace.getTrace()));
-        } catch (TmfAnalysisException e) {
-            fail();
-        }
-        module.schedule();
-        assertTrue(module.waitForCompletion());
-
-        fixture = module.getStateSystem();
-    }
-
-    /**
-     * Clean-up
-     */
-    @AfterClass
-    public static void cleanup() {
-        if (module != null) {
-            module.dispose();
-        }
-        if (stateFile != null) {
-            stateFile.delete();
-        }
-        if (stateFileBenchmark != null) {
-            stateFileBenchmark.delete();
-        }
-        if (fixture != null) {
-            fixture.dispose();
-        }
-        module = null;
-        fixture = null;
-    }
-
-    // ------------------------------------------------------------------------
-    // Tests specific to a full-history
-    // ------------------------------------------------------------------------
-
-    /**
-     * Rebuild independently so we can benchmark it. Too bad JUnit doesn't allow
-     * us to @Test the @BeforeClass...
-     */
-    @Test
-    public void testBuild() {
-        TestLttngKernelAnalysisModule module2 = new TestLttngKernelAnalysisModule(BENCHMARK_FILE_NAME);
-        try {
-            assertTrue(module2.setTrace(testTrace.getTrace()));
-        } catch (TmfAnalysisException e) {
-            module2.dispose();
-            fail();
-        }
-        module2.schedule();
-        assertTrue(module2.waitForCompletion());
-        ITmfStateSystem ssb2 = module2.getStateSystem();
-
-        assertNotNull(ssb2);
-        assertEquals(startTime, ssb2.getStartTime());
-        assertEquals(endTime, ssb2.getCurrentEndTime());
-
-        module2.dispose();
-    }
-
-    /**
-     * Test re-opening the existing file.
-     */
-    @Test
-    public void testOpenExistingStateFile() {
-        /* 'newStateFile' should have already been created */
-        TestLttngKernelAnalysisModule module2 = new TestLttngKernelAnalysisModule(TEST_FILE_NAME);
-        try {
-            assertTrue(module2.setTrace(testTrace.getTrace()));
-        } catch (TmfAnalysisException e) {
-            module2.dispose();
-            fail();
-        }
-        module2.schedule();
-        assertTrue(module2.waitForCompletion());
-        ITmfStateSystem ssb2 = module2.getStateSystem();
-
-        assertNotNull(ssb2);
-        assertEquals(startTime, ssb2.getStartTime());
-        assertEquals(endTime, ssb2.getCurrentEndTime());
-
-        module2.dispose();
-    }
-
-    @NonNullByDefault
-    private static class TestLttngKernelAnalysisModule extends KernelAnalysisModule {
-
-        private final String htFileName;
-
-        /**
-         * Constructor adding the views to the analysis
-         * @param htFileName
-         *      The History File Name
-         */
-        public TestLttngKernelAnalysisModule(String htFileName) {
-            super();
-            this.htFileName = htFileName;
-        }
-
-        @Override
-        public boolean setTrace(@Nullable ITmfTrace trace) throws TmfAnalysisException {
-            if (!(trace instanceof CtfTmfTrace)) {
-                return false;
-            }
-            return super.setTrace(trace);
-        }
-
-        @Override
-        protected StateSystemBackendType getBackendType() {
-            return StateSystemBackendType.FULL;
-        }
-
-        @Override
-        protected String getSsFileName() {
-            return htFileName;
-        }
-    }
-
-    private static File createStateFile(String name) {
-        File file = new File(TmfTraceManager.getSupplementaryFileDir(testTrace.getTrace()) + name);
-        if (file.exists()) {
-            file.delete();
-        }
-        return file;
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/statesystem/StateSystemInMemoryTest.java b/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/statesystem/StateSystemInMemoryTest.java
deleted file mode 100644 (file)
index 1840a7a..0000000
+++ /dev/null
@@ -1,95 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2013, 2015 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:
- *   Alexandre Montplaisir - Initial API and implementation
- *   Bernd Hufmann - Use state system analysis module instead of factory
- ******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.kernel.core.tests.analysis.kernel.statesystem;
-
-import static org.junit.Assert.assertTrue;
-import static org.junit.Assert.fail;
-
-import org.eclipse.tracecompass.analysis.os.linux.core.kernelanalysis.KernelAnalysisModule;
-import org.eclipse.tracecompass.tmf.core.exceptions.TmfAnalysisException;
-import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace;
-import org.eclipse.tracecompass.tmf.ctf.core.trace.CtfTmfTrace;
-import org.junit.AfterClass;
-import org.junit.BeforeClass;
-
-/**
- * State system tests using the in-memory back-end.
- *
- * @author Alexandre Montplaisir
- */
-public class StateSystemInMemoryTest extends StateSystemTest {
-
-    private static TestLttngKernelAnalysisModule module;
-
-    /**
-     * Test class setup
-     */
-    @BeforeClass
-    public static void initialize() {
-        if (!testTrace.exists()) {
-            traceIsPresent = false;
-            return;
-        }
-        traceIsPresent = true;
-
-        module = new TestLttngKernelAnalysisModule();
-        try {
-            assertTrue(module.setTrace(testTrace.getTrace()));
-        } catch (TmfAnalysisException e) {
-            fail();
-        }
-        module.schedule();
-        assertTrue(module.waitForCompletion());
-
-        fixture = module.getStateSystem();
-    }
-
-    /**
-     * Class cleanup
-     */
-    @AfterClass
-    public static void cleanup() {
-        if (module != null) {
-            module.dispose();
-        }
-        if (fixture != null) {
-            fixture.dispose();
-        }
-        module = null;
-        fixture = null;
-    }
-
-    private static class TestLttngKernelAnalysisModule extends KernelAnalysisModule {
-
-        /**
-         * Constructor adding the views to the analysis
-         */
-        public TestLttngKernelAnalysisModule() {
-            super();
-        }
-
-        @Override
-        public boolean setTrace(ITmfTrace trace) throws TmfAnalysisException {
-            if (!(trace instanceof CtfTmfTrace)) {
-                return false;
-            }
-            return super.setTrace(trace);
-        }
-
-        @Override
-        protected StateSystemBackendType getBackendType() {
-            return StateSystemBackendType.INMEM;
-        }
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/statesystem/StateSystemTest.java b/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/statesystem/StateSystemTest.java
deleted file mode 100644 (file)
index a66b2a0..0000000
+++ /dev/null
@@ -1,436 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2012, 2015 Ericsson
- * Copyright (c) 2010, 2011 École Polytechnique de Montréal
- * Copyright (c) 2010, 2011 Alexandre Montplaisir <alexandre.montplaisir@gmail.com>
- *
- * 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
- *
- *******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.kernel.core.tests.analysis.kernel.statesystem;
-
-import static org.junit.Assert.assertEquals;
-import static org.junit.Assert.assertNotNull;
-import static org.junit.Assert.fail;
-import static org.junit.Assume.assumeTrue;
-
-import java.util.List;
-
-import org.eclipse.tracecompass.analysis.os.linux.core.kernelanalysis.Attributes;
-import org.eclipse.tracecompass.statesystem.core.ITmfStateSystem;
-import org.eclipse.tracecompass.statesystem.core.StateSystemUtils;
-import org.eclipse.tracecompass.statesystem.core.exceptions.AttributeNotFoundException;
-import org.eclipse.tracecompass.statesystem.core.exceptions.StateSystemDisposedException;
-import org.eclipse.tracecompass.statesystem.core.exceptions.StateValueTypeException;
-import org.eclipse.tracecompass.statesystem.core.exceptions.TimeRangeException;
-import org.eclipse.tracecompass.statesystem.core.interval.ITmfStateInterval;
-import org.eclipse.tracecompass.statesystem.core.statevalue.ITmfStateValue;
-import org.eclipse.tracecompass.tmf.ctf.core.tests.shared.CtfTmfTestTrace;
-import org.junit.Before;
-import org.junit.Rule;
-import org.junit.Test;
-import org.junit.rules.TestRule;
-import org.junit.rules.Timeout;
-
-/**
- * Base unit tests for the StateHistorySystem. Extension can be made to test
- * different state back-end types or configurations.
- *
- * @author Alexandre Montplaisir
- */
-@SuppressWarnings("javadoc")
-public abstract class StateSystemTest {
-
-    /** Timeout the tests after 2 minutes */
-    @Rule
-    public TestRule timeoutRule = new Timeout(120000);
-
-    /** Test trace used for these tests */
-    protected static final CtfTmfTestTrace testTrace = CtfTmfTestTrace.TRACE2;
-
-    /** Expected start time of the test trace/state history */
-    protected static final long startTime = 1331668247314038062L;
-
-    /** Expected end time of the state history built from the test trace */
-    protected static final long endTime = 1331668259054285979L;
-
-    /** Offset in the trace + start time of the trace */
-    protected static final long interestingTimestamp1 = 18670067372290L + 1331649577946812237L;
-
-    /** Number of nanoseconds in one second */
-    private static final long NANOSECS_PER_SEC = 1000000000L;
-
-    protected static ITmfStateSystem fixture;
-    protected static boolean traceIsPresent = false;
-
-    /**
-     * Test set-up
-     */
-    @Before
-    public void setUp() {
-        assumeTrue(traceIsPresent);
-        /* Subclasses should set-up 'fixture' */
-        assertNotNull(fixture);
-    }
-
-    @Test
-    public void testFullQuery1() {
-        List<ITmfStateInterval> list;
-        ITmfStateInterval interval;
-        int quark, valueInt;
-        String valueStr;
-
-        try {
-            list = fixture.queryFullState(interestingTimestamp1);
-
-            quark = fixture.getQuarkAbsolute(Attributes.CPUS, "0", Attributes.CURRENT_THREAD);
-            interval = list.get(quark);
-            valueInt = interval.getStateValue().unboxInt();
-            assertEquals(1397, valueInt);
-
-            quark = fixture.getQuarkAbsolute(Attributes.THREADS, "1432", Attributes.EXEC_NAME);
-            interval = list.get(quark);
-            valueStr = interval.getStateValue().unboxStr();
-            assertEquals("gdbus", valueStr);
-
-            quark = fixture.getQuarkAbsolute(Attributes.THREADS, "1432", Attributes.SYSTEM_CALL);
-            interval = list.get(quark);
-            valueStr = interval.getStateValue().unboxStr();
-            assertEquals("sys_poll", valueStr);
-
-        } catch (AttributeNotFoundException | StateSystemDisposedException e) {
-            fail();
-        }
-    }
-
-    @Test
-    public void testSingleQuery1() {
-        long timestamp = interestingTimestamp1;
-        int quark;
-        ITmfStateInterval interval;
-        String valueStr;
-
-        try {
-            quark = fixture.getQuarkAbsolute(Attributes.THREADS, "1432", Attributes.EXEC_NAME);
-            interval = fixture.querySingleState(timestamp, quark);
-            valueStr = interval.getStateValue().unboxStr();
-            assertEquals("gdbus", valueStr);
-
-        } catch (AttributeNotFoundException | StateSystemDisposedException e) {
-            fail();
-        }
-    }
-
-    /**
-     * Test a range query (with no resolution parameter, so all intervals)
-     */
-    @Test
-    public void testRangeQuery1() {
-        long time1 = interestingTimestamp1;
-        long time2 = time1 + 1L * NANOSECS_PER_SEC;
-        int quark;
-        List<ITmfStateInterval> intervals;
-
-        final ITmfStateSystem ss = fixture;
-        assertNotNull(ss);
-
-        try {
-            quark = ss.getQuarkAbsolute(Attributes.CPUS, "0", Attributes.CURRENT_THREAD);
-            intervals = StateSystemUtils.queryHistoryRange(ss, quark, time1, time2);
-            assertEquals(487, intervals.size()); /* Number of context switches! */
-            assertEquals(1685, intervals.get(100).getStateValue().unboxInt());
-            assertEquals(1331668248427681372L, intervals.get(205).getEndTime());
-
-        } catch (AttributeNotFoundException | StateSystemDisposedException e) {
-            fail();
-        }
-    }
-
-    /**
-     * Range query, but with a t2 far off the end of the trace. The result
-     * should still be valid.
-     */
-    @Test
-    public void testRangeQuery2() {
-        List<ITmfStateInterval> intervals;
-
-        final ITmfStateSystem ss = fixture;
-        assertNotNull(ss);
-
-        try {
-            int quark = ss.getQuarkAbsolute(Attributes.RESOURCES, Attributes.IRQS, "1");
-            long ts1 = ss.getStartTime(); /* start of the trace */
-            long ts2 = startTime + 20L * NANOSECS_PER_SEC; /* invalid, but ignored */
-
-            intervals = StateSystemUtils.queryHistoryRange(ss, quark, ts1, ts2);
-
-            /* Activity of IRQ 1 over the whole trace */
-            assertEquals(65, intervals.size());
-
-        } catch (AttributeNotFoundException | StateSystemDisposedException e) {
-            fail();
-        }
-    }
-
-    /**
-     * Test a range query with a resolution
-     */
-    @Test
-    public void testRangeQuery3() {
-        long time1 = interestingTimestamp1;
-        long time2 = time1 + 1L * NANOSECS_PER_SEC;
-        long resolution = 1000000; /* One query every millisecond */
-        int quark;
-        List<ITmfStateInterval> intervals;
-
-        final ITmfStateSystem ss = fixture;
-        assertNotNull(ss);
-
-        try {
-            quark = ss.getQuarkAbsolute(Attributes.CPUS, "0", Attributes.CURRENT_THREAD);
-            intervals = StateSystemUtils.queryHistoryRange(ss, quark, time1, time2, resolution, null);
-            assertEquals(126, intervals.size()); /* Number of context switches! */
-            assertEquals(1452, intervals.get(50).getStateValue().unboxInt());
-            assertEquals(1331668248815698779L, intervals.get(100).getEndTime());
-
-        } catch (AttributeNotFoundException | StateSystemDisposedException e) {
-            fail();
-        }
-    }
-
-    /**
-     * Ask for a time range outside of the trace's range
-     */
-    @Test(expected = TimeRangeException.class)
-    public void testFullQueryInvalidTime1() throws TimeRangeException,
-            StateSystemDisposedException {
-        long ts = startTime + 20L * NANOSECS_PER_SEC;
-        fixture.queryFullState(ts);
-    }
-
-    @Test(expected = TimeRangeException.class)
-    public void testFullQueryInvalidTime2() throws TimeRangeException,
-            StateSystemDisposedException {
-        long ts = startTime - 20L * NANOSECS_PER_SEC;
-        fixture.queryFullState(ts);
-    }
-
-    @Test(expected = TimeRangeException.class)
-    public void testSingleQueryInvalidTime1() throws TimeRangeException {
-        try {
-            int quark = fixture.getQuarkAbsolute(Attributes.CPUS, "0", Attributes.CURRENT_THREAD);
-            long ts = startTime + 20L * NANOSECS_PER_SEC;
-            fixture.querySingleState(ts, quark);
-
-        } catch (AttributeNotFoundException | StateSystemDisposedException e) {
-            fail();
-        }
-    }
-
-    @Test(expected = TimeRangeException.class)
-    public void testSingleQueryInvalidTime2() throws TimeRangeException {
-        try {
-            int quark = fixture.getQuarkAbsolute(Attributes.CPUS, "0", Attributes.CURRENT_THREAD);
-            long ts = startTime - 20L * NANOSECS_PER_SEC;
-            fixture.querySingleState(ts, quark);
-
-        } catch (AttributeNotFoundException | StateSystemDisposedException e) {
-            fail();
-        }
-    }
-
-    @Test(expected = TimeRangeException.class)
-    public void testRangeQueryInvalidTime1() throws TimeRangeException {
-        final ITmfStateSystem ss = fixture;
-        assertNotNull(ss);
-
-        try {
-            int quark = ss.getQuarkAbsolute(Attributes.CPUS, "0", Attributes.CURRENT_THREAD);
-            long ts1 = startTime - 20L * NANOSECS_PER_SEC; /* invalid */
-            long ts2 = startTime + 1L * NANOSECS_PER_SEC; /* valid */
-            StateSystemUtils.queryHistoryRange(ss, quark, ts1, ts2);
-
-        } catch (AttributeNotFoundException e) {
-            fail();
-        } catch (StateSystemDisposedException e) {
-            fail();
-        }
-    }
-
-    @Test(expected = TimeRangeException.class)
-    public void testRangeQueryInvalidTime2() throws TimeRangeException {
-        final ITmfStateSystem ss = fixture;
-        assertNotNull(ss);
-
-        try {
-            int quark = ss.getQuarkAbsolute(Attributes.CPUS, "0", Attributes.CURRENT_THREAD);
-            long ts1 = startTime - 1L * NANOSECS_PER_SEC; /* invalid */
-            long ts2 = startTime + 20L * NANOSECS_PER_SEC; /* invalid */
-            StateSystemUtils.queryHistoryRange(ss, quark, ts1, ts2);
-
-        } catch (AttributeNotFoundException | StateSystemDisposedException e) {
-            fail();
-        }
-    }
-
-    /**
-     * Ask for a non-existing attribute
-     *
-     * @throws AttributeNotFoundException
-     */
-    @Test(expected = AttributeNotFoundException.class)
-    public void testQueryInvalidAttribute() throws AttributeNotFoundException {
-        fixture.getQuarkAbsolute("There", "is", "no", "cow", "level");
-    }
-
-    /**
-     * Query but with the wrong State Value type
-     */
-    @Test(expected = StateValueTypeException.class)
-    public void testQueryInvalidValuetype1() throws StateValueTypeException {
-        List<ITmfStateInterval> list;
-        ITmfStateInterval interval;
-        int quark;
-
-        try {
-            list = fixture.queryFullState(interestingTimestamp1);
-            quark = fixture.getQuarkAbsolute(Attributes.CPUS, "0", Attributes.CURRENT_THREAD);
-            interval = list.get(quark);
-
-            /* This is supposed to be an int value */
-            interval.getStateValue().unboxStr();
-
-        } catch (AttributeNotFoundException | StateSystemDisposedException e) {
-            fail();
-        }
-    }
-
-    @Test(expected = StateValueTypeException.class)
-    public void testQueryInvalidValuetype2() throws StateValueTypeException {
-        List<ITmfStateInterval> list;
-        ITmfStateInterval interval;
-        int quark;
-
-        try {
-            list = fixture.queryFullState(interestingTimestamp1);
-            quark = fixture.getQuarkAbsolute(Attributes.THREADS, "1432", Attributes.EXEC_NAME);
-            interval = list.get(quark);
-
-            /* This is supposed to be a String value */
-            interval.getStateValue().unboxInt();
-
-        } catch (AttributeNotFoundException | StateSystemDisposedException e) {
-            fail();
-        }
-    }
-
-    @Test
-    public void testFullAttributeName() {
-        try {
-            int quark = fixture.getQuarkAbsolute(Attributes.CPUS, "0", Attributes.CURRENT_THREAD);
-            String name = fixture.getFullAttributePath(quark);
-            assertEquals(name, "CPUs/0/Current_thread");
-
-        } catch (AttributeNotFoundException e) {
-            fail();
-        }
-    }
-
-    @Test
-    public void testGetQuarks_begin() {
-        List<Integer> list = fixture.getQuarks("*", "1577", Attributes.EXEC_NAME);
-
-        assertEquals(1, list.size());
-    }
-
-    @Test
-    public void testGetQuarks_middle() {
-        List<Integer> list = fixture.getQuarks(Attributes.THREADS, "*", Attributes.EXEC_NAME);
-
-        /* Number of different kernel threads in the trace */
-        assertEquals(168, list.size());
-    }
-
-    @Test
-    public void testGetQuarks_end() {
-        List<Integer> list = fixture.getQuarks(Attributes.THREADS, "1577", "*");
-
-        /* There should be 5 sub-attributes for each Thread node */
-        assertEquals(5, list.size());
-    }
-
-    // ------------------------------------------------------------------------
-    // Tests verifying the *complete* results of a full queries
-    // ------------------------------------------------------------------------
-
-    protected long getStartTimes(int idx) {
-        return TestValues.startTimes[idx];
-    }
-
-    protected long getEndTimes(int idx) {
-        return TestValues.endTimes[idx];
-    }
-
-    protected ITmfStateValue getStateValues(int idx) {
-        return TestValues.values[idx];
-    }
-
-    @Test
-    public void testFullQueryThorough() {
-        try {
-            List<ITmfStateInterval> state = fixture.queryFullState(interestingTimestamp1);
-            assertEquals(TestValues.size, state.size());
-
-            for (int i = 0; i < state.size(); i++) {
-                /* Test each component of the intervals */
-                assertEquals(getStartTimes(i), state.get(i).getStartTime());
-                assertEquals(getEndTimes(i), state.get(i).getEndTime());
-                assertEquals(i, state.get(i).getAttribute());
-                assertEquals(getStateValues(i), state.get(i).getStateValue());
-            }
-
-        } catch (StateSystemDisposedException e) {
-            fail();
-        }
-    }
-
-    @Test
-    public void testFirstIntervalIsConsidered() {
-        try {
-            int quark = fixture.getQuarkAbsolute(Attributes.THREADS, "1397", Attributes.STATUS);
-            List<ITmfStateInterval> list = fixture.queryFullState(1331668248014135800L);
-            ITmfStateInterval interval = list.get(quark);
-            assertEquals(1331668247516664825L, interval.getStartTime());
-
-            int valueInt = interval.getStateValue().unboxInt();
-            assertEquals(1, valueInt);
-
-        } catch (StateSystemDisposedException | AttributeNotFoundException e) {
-            fail();
-        }
-    }
-
-    @Test
-    public void testParentAttribute() {
-        String[] path = { "CPUs/0/Current_thread",
-                          "CPUs/0",
-                          "CPUs" };
-        try {
-            int q = fixture.getQuarkAbsolute(Attributes.CPUS, "0", Attributes.CURRENT_THREAD);
-            for (int i = 0; i < path.length; i++) {
-                String name = fixture.getFullAttributePath(q);
-                assertEquals(path[i], name);
-                q = fixture.getParentAttributeQuark(q);
-            }
-            assertEquals(-1, q);
-            q = fixture.getParentAttributeQuark(q);
-            assertEquals(-1, q);
-        } catch (AttributeNotFoundException e) {
-            fail();
-        }
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/statesystem/TestAll.java b/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/statesystem/TestAll.java
deleted file mode 100644 (file)
index 0fe407d..0000000
+++ /dev/null
@@ -1,29 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2012, 2014 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:
- *   Alexandre Montplaisir - Initial implementation
- ******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.kernel.core.tests.analysis.kernel.statesystem;
-
-import org.junit.runner.RunWith;
-import org.junit.runners.Suite;
-
-/**
- * Runner for the LTTng kernel state system tests.
- */
-@RunWith(Suite.class)
-@Suite.SuiteClasses({
-    PartialStateSystemTest.class,
-    StateSystemFullHistoryTest.class,
-    StateSystemInMemoryTest.class
-})
-public class TestAll {
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/statesystem/TestValues.java b/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/kernel/statesystem/TestValues.java
deleted file mode 100644 (file)
index 353f6bc..0000000
+++ /dev/null
@@ -1,3132 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2013, 2015 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:
- *   Alexandre Montplaisir - Initial API and implementation
- ******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.kernel.core.tests.analysis.kernel.statesystem;
-
-import org.eclipse.tracecompass.statesystem.core.statevalue.ITmfStateValue;
-import org.eclipse.tracecompass.statesystem.core.statevalue.TmfStateValue;
-
-/**
- * Expected return values of querying test trace #1's state system at time
- * "18670067372290L + 1331649577946812237L".
- *
- * This file is can be generated using the {@link GenerateTestValues} script.
- *
- * @author Alexandre Montplaisir
- */
-interface TestValues {
-
-    int size = 1031;
-
-    long[] startTimes = {
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668248014145796L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247399757985L,
-        1331668247316320929L,
-        1331668247316334243L,
-        1331668247314046266L,
-        1331668247316120937L,
-        1331668247314038062L,
-        1331668248014183954L,
-        1331668247314038062L,
-        1331668247327098502L,
-        1331668247327098502L,
-        1331668247327098502L,
-        1331668247327098502L,
-        1331668247327098502L,
-        1331668247314038062L,
-        1331668247415001807L,
-        1331668247415001807L,
-        1331668247415001807L,
-        1331668247415001807L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668248013353414L,
-        1331668248004935409L,
-        1331668247314601653L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668248014184526L,
-        1331668248014130616L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668248011125682L,
-        1331668247314038062L,
-        1331668247931793142L,
-        1331668247930941981L,
-        1331668247959041965L,
-        1331668248011129576L,
-        1331668247314038062L,
-        1331668247335106720L,
-        1331668247335106720L,
-        1331668247335106720L,
-        1331668247335106720L,
-        1331668247335106720L,
-        1331668247931782426L,
-        1331668247315274351L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247335112802L,
-        1331668247335112802L,
-        1331668247335112802L,
-        1331668247335112802L,
-        1331668247335112802L,
-        1331668247314038062L,
-        1331668248004705322L,
-        1331668247314038062L,
-        1331668248004935409L,
-        1331668248004770916L,
-        1331668248004925240L,
-        1331668247316553071L,
-        1331668247314038062L,
-        1331668247399148733L,
-        1331668247399743968L,
-        1331668247316925661L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247999256178L,
-        1331668247999239403L,
-        1331668247999250697L,
-        1331668247318567561L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247999336085L,
-        1331668247999131058L,
-        1331668247999327778L,
-        1331668247318631139L,
-        1331668247314038062L,
-        1331668247960265258L,
-        1331668247314038062L,
-        1331668247903884233L,
-        1331668247902254797L,
-        1331668247903869067L,
-        1331668247328403934L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247908495390L,
-        1331668247908391792L,
-        1331668247908464125L,
-        1331668247328921944L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247903840082L,
-        1331668247902986051L,
-        1331668247903831313L,
-        1331668247329404733L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247960291263L,
-        1331668247960272741L,
-        1331668247314038062L,
-        1331668247330548245L,
-        1331668247314038062L,
-        1331668247340039213L,
-        1331668247340083580L,
-        1331668247966976915L,
-        1331668247314038062L,
-        1331668248004729173L,
-        1331668248004720009L,
-        1331668247314038062L,
-        1331668247371137735L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247387196023L,
-        1331668247387154824L,
-        1331668247387191465L,
-        1331668247376420842L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247400231496L,
-        1331668247400130260L,
-        1331668247400218303L,
-        1331668247378430187L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247751186217L,
-        1331668247751173305L,
-        1331668247314038062L,
-        1331668247387136191L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247415047817L,
-        1331668247415047817L,
-        1331668247415047817L,
-        1331668247415047817L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247400095883L,
-        1331668247399991225L,
-        1331668247400085049L,
-        1331668247399991225L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247401441000L,
-        1331668247401408057L,
-        1331668247401428073L,
-        1331668247400779449L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247410754305L,
-        1331668247410594291L,
-        1331668247314038062L,
-        1331668247519727372L,
-        1331668247519619353L,
-        1331668247314038062L,
-        1331668247412887695L,
-        1331668247412803787L,
-        1331668247314038062L,
-        1331668247413704524L,
-        1331668247413576917L,
-        1331668247412877246L,
-        1331668247410583861L,
-        1331668247314038062L,
-        1331668247410735104L,
-        1331668247410594291L,
-        1331668247314038062L,
-        1331668247413682702L,
-        1331668247410844189L,
-        1331668247314038062L,
-        1331668247519712481L,
-        1331668247411099759L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247924029486L,
-        1331668247923412966L,
-        1331668247924012402L,
-        1331668247412302666L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247924105876L,
-        1331668247924010016L,
-        1331668247924098044L,
-        1331668247417574343L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668248014184526L,
-        1331668248013799545L,
-        1331668248014130616L,
-        1331668247417635948L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247928627023L,
-        1331668247928556625L,
-        1331668247928621067L,
-        1331668247417978805L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247928556625L,
-        1331668247927469138L,
-        1331668247928529840L,
-        1331668247418470511L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247930341625L,
-        1331668247928614605L,
-        1331668247314038062L,
-        1331668248014184526L,
-        1331668248014184526L,
-        1331668248013793850L,
-        1331668247419578477L,
-        1331668247314038062L,
-        1331668247930328175L,
-        1331668247419655652L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668248013753736L,
-        1331668248013353414L,
-        1331668248013749389L,
-        1331668247420382626L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247930579872L,
-        1331668247930316322L,
-        1331668247930574368L,
-        1331668247420451876L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247926378321L,
-        1331668247925622863L,
-        1331668247926367737L,
-        1331668247423543945L,
-        1331668247314038062L,
-        1331668247619316825L,
-        1331668247619491008L,
-        1331668247314038062L,
-        1331668247619505885L,
-        1331668247619392829L,
-        1331668247619495072L,
-        1331668247434248026L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247434551326L,
-        1331668247434365352L,
-        1331668247434546203L,
-        1331668247434365352L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247908325947L,
-        1331668247908264450L,
-        1331668247908319810L,
-        1331668247467380509L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247908677700L,
-        1331668247908325947L,
-        1331668247908640244L,
-        1331668247467447781L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247869556425L,
-        1331668247869483379L,
-        1331668247869544380L,
-        1331668247503177108L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247504321893L,
-        1331668247504294050L,
-        1331668247504319470L,
-        1331668247503423094L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668248014183954L,
-        1331668248014145796L,
-        1331668248014183954L,
-        1331668247512172527L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247539381562L,
-        1331668247539325848L,
-        1331668247539369787L,
-        1331668247539325848L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247735177820L,
-        1331668247735128110L,
-        1331668247735170303L,
-        1331668247735128110L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247735168206L,
-        1331668247735152717L,
-        1331668247735161964L,
-        1331668247735152717L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247775218227L,
-        1331668247775191569L,
-        1331668247314038062L,
-        1331668247775231079L,
-        1331668247775218227L,
-        1331668247775205377L,
-        1331668247775191569L,
-        1331668247314038062L,
-        1331668247775223776L,
-        1331668247775218227L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247869483379L,
-        1331668247869457807L,
-        1331668247869477795L,
-        1331668247869457807L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247941667986L,
-        1331668247941620894L,
-        1331668247941650415L,
-        1331668247941620894L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-        1331668247314038062L,
-    };
-
-    long[] endTimes = {
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668248014620024L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054130388L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668248014185078L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668248014620024L,
-        1331668248014620024L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668248014548923L,
-        1331668248014188534L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668248015040151L,
-        1331668259054285979L,
-        1331668248482983146L,
-        1331668248482983146L,
-        1331668248015041609L,
-        1331668248015176320L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668248483009726L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668248015959980L,
-        1331668259054285979L,
-        1331668248016172023L,
-        1331668248016172023L,
-        1331668248016194935L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054130388L,
-        1331668259054136697L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668248016556933L,
-        1331668248016556933L,
-        1331668248016592456L,
-        1331668252511012367L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668248016623209L,
-        1331668248016623209L,
-        1331668248016645047L,
-        1331668252843104826L,
-        1331668259054285979L,
-        1331668248486545657L,
-        1331668259054285979L,
-        1331668248502954816L,
-        1331668248502954816L,
-        1331668248503000162L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668248020364249L,
-        1331668248020364249L,
-        1331668248020419523L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668248020866943L,
-        1331668248020866943L,
-        1331668248020888352L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668248531200073L,
-        1331668248531200073L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668257323835062L,
-        1331668257323879563L,
-        1331668248021867385L,
-        1331668259054285979L,
-        1331668248175307354L,
-        1331668248175307354L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259051873438L,
-        1331668259051873438L,
-        1331668259051879701L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668248751061201L,
-        1331668248751061201L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259051838247L,
-        1331668259051838247L,
-        1331668259051846351L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668257325265220L,
-        1331668257325265220L,
-        1331668257325277639L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668250005943125L,
-        1331668250005943125L,
-        1331668259054285979L,
-        1331668248014565260L,
-        1331668248014565260L,
-        1331668259054285979L,
-        1331668250006219013L,
-        1331668250006219013L,
-        1331668259054285979L,
-        1331668250004649129L,
-        1331668250004649129L,
-        1331668250006228246L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668250005962644L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668250004668081L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668248014624125L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668248414826115L,
-        1331668248414826115L,
-        1331668248414875444L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668248420327828L,
-        1331668248420327828L,
-        1331668248420342919L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668248015353903L,
-        1331668248015353903L,
-        1331668248015428919L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668248420617453L,
-        1331668248420617453L,
-        1331668248420709272L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668248421112139L,
-        1331668248421112139L,
-        1331668248421137268L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668248421291701L,
-        1331668248421291701L,
-        1331668259054285979L,
-        1331668248014188534L,
-        1331668248015518081L,
-        1331668248014188534L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668248421940554L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668248014548923L,
-        1331668248016397030L,
-        1331668248014550770L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668248422509298L,
-        1331668248422509298L,
-        1331668248422523601L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668248424325503L,
-        1331668248424325503L,
-        1331668248424394073L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668248140683324L,
-        1331668248140686546L,
-        1331668259054285979L,
-        1331668248140727269L,
-        1331668248140727269L,
-        1331668248140780012L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668251031789570L,
-        1331668251031789570L,
-        1331668251031812282L,
-        1331668252047037657L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668248269586770L,
-        1331668248269586770L,
-        1331668248269613258L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668248141167328L,
-        1331668248141167328L,
-        1331668248141400164L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668248141004006L,
-        1331668248141004006L,
-        1331668248141028631L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668248141324868L,
-        1331668248141324868L,
-        1331668248141345677L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668248014185078L,
-        1331668248015165243L,
-        1331668248014185078L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668248539549580L,
-        1331668248539549580L,
-        1331668248539579511L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668255234884605L,
-        1331668255234884605L,
-        1331668255234905622L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668255234936617L,
-        1331668255234936617L,
-        1331668255234941684L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668252778982101L,
-        1331668252778982101L,
-        1331668259054285979L,
-        1331668252779007563L,
-        1331668252779007563L,
-        1331668252781320133L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668252781341690L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668248869653287L,
-        1331668248869653287L,
-        1331668248869679933L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668248941858743L,
-        1331668248941858743L,
-        1331668248941885421L,
-        1331668252782929207L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668248207116451L,
-        1331668248207116451L,
-        1331668248207177650L,
-        1331668248207163589L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668248207165629L,
-        1331668248207165629L,
-        1331668248207212201L,
-        1331668248207197204L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668248763171129L,
-        1331668248763171129L,
-        1331668259054285979L,
-        1331668248763179780L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668248895005379L,
-        1331668248895005379L,
-        1331668248895062414L,
-        1331668248895035146L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668249000328909L,
-        1331668249000328909L,
-        1331668249000373092L,
-        1331668249000350716L,
-        1331668259054285979L,
-        1331668249548101920L,
-        1331668259054285979L,
-        1331668249947171998L,
-        1331668249947171998L,
-        1331668249947269897L,
-        1331668249947249018L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668249951033184L,
-        1331668249951033184L,
-        1331668249951077605L,
-        1331668249951058138L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668249959079406L,
-        1331668249959079406L,
-        1331668259054285979L,
-        1331668249959100633L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668249970937981L,
-        1331668249970937981L,
-        1331668259054285979L,
-        1331668249970963407L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668250007423753L,
-        1331668250007423753L,
-        1331668250007449251L,
-        1331668250007428034L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668250231124169L,
-        1331668250231124169L,
-        1331668250231169946L,
-        1331668250231148973L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668250326525622L,
-        1331668250326525622L,
-        1331668250329519305L,
-        1331668250329507458L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668251063191270L,
-        1331668251063191270L,
-        1331668251063256143L,
-        1331668251063222335L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668251065026369L,
-        1331668251065026369L,
-        1331668251065048462L,
-        1331668251065030498L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668251065058051L,
-        1331668251065058051L,
-        1331668251065091761L,
-        1331668251065069765L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668251065364590L,
-        1331668251065364590L,
-        1331668251065412381L,
-        1331668251065407607L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668251065462500L,
-        1331668251065462500L,
-        1331668251065477027L,
-        1331668251065465604L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668251065780572L,
-        1331668251065780572L,
-        1331668251065836719L,
-        1331668251065829440L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668251065899750L,
-        1331668251065899750L,
-        1331668251065913891L,
-        1331668251065902892L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668251066057402L,
-        1331668251066057402L,
-        1331668251066070617L,
-        1331668251066060363L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668251066495616L,
-        1331668251066495616L,
-        1331668251066520321L,
-        1331668251066506338L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668251066532840L,
-        1331668251066532840L,
-        1331668251066546436L,
-        1331668251066535866L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668251066658006L,
-        1331668251066658006L,
-        1331668251066671812L,
-        1331668251066660635L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668251066883302L,
-        1331668251066883302L,
-        1331668251066906446L,
-        1331668251066887423L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668251067153808L,
-        1331668251067153808L,
-        1331668251067176405L,
-        1331668251067157534L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668251067407214L,
-        1331668251067407214L,
-        1331668251067420770L,
-        1331668251067410220L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668251067763731L,
-        1331668251067763731L,
-        1331668251067818612L,
-        1331668251067811009L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668251067884367L,
-        1331668251067884367L,
-        1331668251067897382L,
-        1331668251067887136L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668251068275691L,
-        1331668251068275691L,
-        1331668251068288692L,
-        1331668251068278423L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668251068706355L,
-        1331668251068706355L,
-        1331668251068719015L,
-        1331668251068709290L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668251069067645L,
-        1331668251069067645L,
-        1331668251069122518L,
-        1331668251069116275L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668251069178617L,
-        1331668251069178617L,
-        1331668251069191305L,
-        1331668251069181300L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668251069664884L,
-        1331668251069664884L,
-        1331668251069684555L,
-        1331668251069668097L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668251069682852L,
-        1331668251069682852L,
-        1331668251069708201L,
-        1331668251069690226L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668251715054925L,
-        1331668251715054925L,
-        1331668259054285979L,
-        1331668251715066022L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668251803784493L,
-        1331668251803784493L,
-        1331668251803827591L,
-        1331668251803808547L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668251983438636L,
-        1331668251983438636L,
-        1331668251983448709L,
-        1331668251983441583L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668251992993580L,
-        1331668251992993580L,
-        1331668251993008591L,
-        1331668251992998928L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668252022091542L,
-        1331668252022091542L,
-        1331668252022091542L,
-        1331668252022091542L,
-        1331668252022095079L,
-        1331668259054285979L,
-        1331668252031771660L,
-        1331668252031771660L,
-        1331668252031777595L,
-        1331668252031773847L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668252032463013L,
-        1331668252032463013L,
-        1331668252032502964L,
-        1331668252032497700L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668252032506884L,
-        1331668252032506884L,
-        1331668252032559227L,
-        1331668252032539402L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668252039535067L,
-        1331668252039535067L,
-        1331668259054285979L,
-        1331668252039537404L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668252044008981L,
-        1331668252044008981L,
-        1331668252044014257L,
-        1331668252044010861L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668252044059151L,
-        1331668252044059151L,
-        1331668252044064004L,
-        1331668252044060420L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668252179391423L,
-        1331668252179391423L,
-        1331668252184781913L,
-        1331668252184772369L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668252193425490L,
-        1331668252193425490L,
-        1331668252193432385L,
-        1331668252193427706L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668252253575716L,
-        1331668252253575716L,
-        1331668252253592491L,
-        1331668252253581852L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668252472449352L,
-        1331668252472449352L,
-        1331668252472474547L,
-        1331668252472458163L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668252487295286L,
-        1331668252487295286L,
-        1331668252487300925L,
-        1331668252487297683L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668252495759849L,
-        1331668252495759849L,
-        1331668252495766026L,
-        1331668252495762178L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668252496219924L,
-        1331668252496219924L,
-        1331668252496245837L,
-        1331668252496228816L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668252523291829L,
-        1331668252523291829L,
-        1331668252523482082L,
-        1331668252523469395L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668252764810964L,
-        1331668252764810964L,
-        1331668252764829827L,
-        1331668252764814570L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668252765021775L,
-        1331668252765021775L,
-        1331668252765026623L,
-        1331668252765023841L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668252769399706L,
-        1331668252769399706L,
-        1331668259054285979L,
-        1331668252769401404L,
-        1331668252769401404L,
-        1331668259054285979L,
-        1331668252769446847L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668252769456141L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668252784988923L,
-        1331668252784988923L,
-        1331668259054285979L,
-        1331668252785262589L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668252795062126L,
-        1331668252795062126L,
-        1331668259054285979L,
-        1331668252795122600L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668252828832090L,
-        1331668252828832090L,
-        1331668259054285979L,
-        1331668252828859292L,
-        1331668252828859292L,
-        1331668252828904216L,
-        1331668252828866041L,
-        1331668259054285979L,
-        1331668252829060434L,
-        1331668252828992804L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668252829505108L,
-        1331668252829505108L,
-        1331668259054285979L,
-        1331668252829527974L,
-        1331668252829527974L,
-        1331668252829719292L,
-        1331668252829638887L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668252829643060L,
-        1331668252829643060L,
-        1331668259054285979L,
-        1331668252829660274L,
-        1331668252829660274L,
-        1331668259054285979L,
-        1331668252829683896L,
-        1331668252829683896L,
-        1331668259054285979L,
-        1331668252829799248L,
-        1331668252829799248L,
-        1331668259054285979L,
-        1331668252829802278L,
-        1331668252829802278L,
-        1331668259054285979L,
-        1331668252829821642L,
-        1331668252829821642L,
-        1331668259054285979L,
-        1331668252829840961L,
-        1331668252829840961L,
-        1331668259054285979L,
-        1331668252829859256L,
-        1331668252829859256L,
-        1331668259054285979L,
-        1331668252829976501L,
-        1331668252829976501L,
-        1331668252830107659L,
-        1331668252830085595L,
-        1331668259054285979L,
-        1331668252830154848L,
-        1331668252830139534L,
-        1331668259054285979L,
-        1331668252830212497L,
-        1331668252830194969L,
-        1331668259054285979L,
-        1331668252830382459L,
-        1331668252830368625L,
-        1331668259054285979L,
-        1331668252830526491L,
-        1331668252830499169L,
-        1331668259054285979L,
-        1331668252830576634L,
-        1331668252830564658L,
-        1331668259054285979L,
-        1331668252831112505L,
-        1331668252831083126L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668252831228714L,
-        1331668252831228714L,
-        1331668252831318123L,
-        1331668252831301843L,
-        1331668259054285979L,
-        1331668252831543926L,
-        1331668252831527998L,
-        1331668259054285979L,
-        1331668252831834393L,
-        1331668252831817197L,
-        1331668259054285979L,
-        1331668252832056760L,
-        1331668252832046333L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668252883172744L,
-        1331668252883172744L,
-        1331668252883172744L,
-        1331668252883172744L,
-        1331668252883178472L,
-        1331668259054285979L,
-        1331668252885827603L,
-        1331668252885827603L,
-        1331668252885827603L,
-        1331668252885827603L,
-        1331668252885834716L,
-        1331668259054285979L,
-        1331668252889337098L,
-        1331668252889337098L,
-        1331668259054285979L,
-        1331668252889396688L,
-        1331668252889396688L,
-        1331668252889396688L,
-        1331668252889396688L,
-        1331668252889399649L,
-        1331668252901232798L,
-        1331668252901118256L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668252901540914L,
-        1331668252901540914L,
-        1331668252901540914L,
-        1331668252901540914L,
-        1331668252901545242L,
-        1331668259054285979L,
-        1331668252901573889L,
-        1331668252901573889L,
-        1331668252901586635L,
-        1331668252901577276L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668252906764880L,
-        1331668252906764880L,
-        1331668252906764880L,
-        1331668252906764880L,
-        1331668252906769816L,
-        1331668259054285979L,
-        1331668252912042743L,
-        1331668252912042743L,
-        1331668259054285979L,
-        1331668252912048618L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668252927449371L,
-        1331668252927449371L,
-        1331668252927449371L,
-        1331668252927449371L,
-        1331668252927454567L,
-        1331668259054285979L,
-        1331668252947156908L,
-        1331668252947156908L,
-        1331668252947156908L,
-        1331668252947156908L,
-        1331668252947162086L,
-        1331668259054285979L,
-        1331668252947197386L,
-        1331668252947197386L,
-        1331668252947197386L,
-        1331668252947197386L,
-        1331668252947200470L,
-        1331668259054285979L,
-        1331668253035499713L,
-        1331668253035499713L,
-        1331668253035499713L,
-        1331668253035499713L,
-        1331668253035505047L,
-        1331668259054285979L,
-        1331668253036766769L,
-        1331668253036766769L,
-        1331668253036766769L,
-        1331668253036766769L,
-        1331668253036770602L,
-        1331668259054285979L,
-        1331668253037890651L,
-        1331668253037890651L,
-        1331668253037890651L,
-        1331668253037890651L,
-        1331668253037894147L,
-        1331668259054285979L,
-        1331668253051945128L,
-        1331668253051945128L,
-        1331668253051945128L,
-        1331668253051945128L,
-        1331668253051948233L,
-        1331668259054285979L,
-        1331668253054627961L,
-        1331668253054627961L,
-        1331668253054627961L,
-        1331668253054627961L,
-        1331668253054630786L,
-        1331668259054285979L,
-        1331668253057609433L,
-        1331668253057609433L,
-        1331668253057609433L,
-        1331668253057609433L,
-        1331668253057612341L,
-        1331668259054285979L,
-        1331668253062222314L,
-        1331668253062222314L,
-        1331668253062222314L,
-        1331668253062222314L,
-        1331668253062227485L,
-        1331668259054285979L,
-        1331668253097239708L,
-        1331668253097239708L,
-        1331668253097239708L,
-        1331668253097239708L,
-        1331668253097246792L,
-        1331668259054285979L,
-        1331668253097518746L,
-        1331668253097518746L,
-        1331668253097518746L,
-        1331668253097518746L,
-        1331668253097521994L,
-        1331668259054285979L,
-        1331668253267104284L,
-        1331668253267104284L,
-        1331668253267117055L,
-        1331668253267107624L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668253267342015L,
-        1331668253267342015L,
-        1331668253267378405L,
-        1331668253267367303L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668253278218713L,
-        1331668253278218713L,
-        1331668253278218713L,
-        1331668253278218713L,
-        1331668253278223105L,
-        1331668259054285979L,
-        1331668253324119756L,
-        1331668253324119756L,
-        1331668253324119756L,
-        1331668253324119756L,
-        1331668253324123194L,
-        1331668259054285979L,
-        1331668253614347227L,
-        1331668253614347227L,
-        1331668253614347227L,
-        1331668253614347227L,
-        1331668253614351910L,
-        1331668259054285979L,
-        1331668253619459320L,
-        1331668253619459320L,
-        1331668253619459320L,
-        1331668253619459320L,
-        1331668253619462745L,
-        1331668259054285979L,
-        1331668253619867625L,
-        1331668253619867625L,
-        1331668253619867625L,
-        1331668253619867625L,
-        1331668253619870183L,
-        1331668259054285979L,
-        1331668253621486721L,
-        1331668253621486721L,
-        1331668253621508851L,
-        1331668253621491536L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668253622429608L,
-        1331668253622429608L,
-        1331668253622429608L,
-        1331668253622429608L,
-        1331668253622432889L,
-        1331668259054285979L,
-        1331668253857465365L,
-        1331668253857465365L,
-        1331668253857465365L,
-        1331668253857465365L,
-        1331668253857469629L,
-        1331668259054285979L,
-        1331668253858125091L,
-        1331668253858125091L,
-        1331668253858125091L,
-        1331668253858125091L,
-        1331668253858128274L,
-        1331668259054285979L,
-        1331668253910194540L,
-        1331668253910194540L,
-        1331668253910194540L,
-        1331668253910194540L,
-        1331668253910198633L,
-        1331668259054285979L,
-        1331668253910329721L,
-        1331668253910329721L,
-        1331668253910329721L,
-        1331668253910329721L,
-        1331668253910333029L,
-        1331668259054285979L,
-        1331668253984922308L,
-        1331668253984922308L,
-        1331668253984922308L,
-        1331668253984922308L,
-        1331668253984926366L,
-        1331668259054285979L,
-        1331668254004098152L,
-        1331668254004098152L,
-        1331668254004098152L,
-        1331668254004098152L,
-        1331668254004102129L,
-        1331668259054285979L,
-        1331668254047839900L,
-        1331668254047839900L,
-        1331668254047839900L,
-        1331668254047839900L,
-        1331668254047843621L,
-        1331668259054285979L,
-        1331668254093066195L,
-        1331668254093066195L,
-        1331668254093066195L,
-        1331668254093066195L,
-        1331668254093071603L,
-        1331668259054285979L,
-        1331668254106326339L,
-        1331668254106326339L,
-        1331668254106326339L,
-        1331668254106326339L,
-        1331668254106330527L,
-        1331668259054285979L,
-        1331668255052411647L,
-        1331668255052411647L,
-        1331668255052411647L,
-        1331668255052411647L,
-        1331668255052417904L,
-        1331668259054285979L,
-        1331668255157088064L,
-        1331668255157088064L,
-        1331668255157101973L,
-        1331668255157091812L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668256244508635L,
-        1331668256244508635L,
-        1331668256244508635L,
-        1331668256244508635L,
-        1331668256244513337L,
-        1331668259054285979L,
-        1331668257246987050L,
-        1331668257246987050L,
-        1331668257247036372L,
-        1331668257247027684L,
-        1331668259054285979L,
-        1331668259054285979L,
-        1331668259045096840L,
-        1331668259045096840L,
-        1331668259045096840L,
-        1331668259045096840L,
-        1331668259045103189L,
-        1331668259054285979L,
-        1331668259052126585L,
-        1331668259052126585L,
-        1331668259052126585L,
-        1331668259052126585L,
-        1331668259052129986L,
-        1331668259054285979L,
-        1331668259053345550L,
-        1331668259053345550L,
-        1331668259054285979L,
-        1331668259053349544L,
-        1331668259054285979L,
-    };
-
-    ITmfStateValue[] values = {
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueInt(1397),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueInt(1),
-        TmfStateValue.newValueString("sys_poll"),
-        TmfStateValue.newValueInt(1),
-        TmfStateValue.newValueString("lttng-consumerd"),
-        TmfStateValue.newValueInt(20),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueInt(1),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueInt(5),
-        TmfStateValue.newValueString("swapper/1"),
-        TmfStateValue.newValueInt(20),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueInt(1432),
-        TmfStateValue.newValueInt(2),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueInt(1),
-        TmfStateValue.newValueInt(20),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueString("sys_poll"),
-        TmfStateValue.newValueString("lttng-consumerd"),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueInt(1),
-        TmfStateValue.newValueInt(-6),
-        TmfStateValue.newValueString("sys_ppoll"),
-        TmfStateValue.newValueString("alsa-sink"),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueInt(20),
-        TmfStateValue.newValueString("sys_epoll_wait"),
-        TmfStateValue.newValueString("lttng-sessiond"),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueInt(1),
-        TmfStateValue.newValueInt(20),
-        TmfStateValue.newValueString("sys_futex"),
-        TmfStateValue.newValueString("firefox"),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueInt(1),
-        TmfStateValue.newValueInt(20),
-        TmfStateValue.newValueString("sys_poll"),
-        TmfStateValue.newValueString("firefox"),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueInt(1),
-        TmfStateValue.newValueInt(20),
-        TmfStateValue.newValueString("sys_poll"),
-        TmfStateValue.newValueString("gnome-terminal"),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueInt(1),
-        TmfStateValue.newValueInt(20),
-        TmfStateValue.newValueString("sys_select"),
-        TmfStateValue.newValueString("Xorg"),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueInt(1),
-        TmfStateValue.newValueInt(20),
-        TmfStateValue.newValueString("sys_poll"),
-        TmfStateValue.newValueString("metacity"),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueInt(1),
-        TmfStateValue.newValueInt(20),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueString("kworker/0:1"),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueInt(1),
-        TmfStateValue.newValueInt(20),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueString("ksoftirqd/0"),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueInt(1),
-        TmfStateValue.newValueInt(20),
-        TmfStateValue.newValueString("sys_read"),
-        TmfStateValue.newValueString("rsyslogd"),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueInt(1),
-        TmfStateValue.newValueInt(20),
-        TmfStateValue.newValueString("sys_futex"),
-        TmfStateValue.newValueString("rs:main Q:Reg"),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueInt(1),
-        TmfStateValue.newValueInt(20),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueString("kworker/1:1"),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueInt(1),
-        TmfStateValue.newValueInt(20),
-        TmfStateValue.newValueString("sys_select"),
-        TmfStateValue.newValueString("rsyslogd"),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueInt(1),
-        TmfStateValue.newValueInt(20),
-        TmfStateValue.newValueString("sys_read"),
-        TmfStateValue.newValueString("bash"),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueInt(1),
-        TmfStateValue.newValueInt(20),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueInt(1),
-        TmfStateValue.newValueInt(20),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueInt(1),
-        TmfStateValue.newValueInt(20),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueInt(1),
-        TmfStateValue.newValueInt(20),
-        TmfStateValue.newValueString("sys_poll"),
-        TmfStateValue.newValueString("bamfdaemon"),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueString("sys_poll"),
-        TmfStateValue.newValueString("gnome-settings-"),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueString("sys_poll"),
-        TmfStateValue.newValueString("unity-2d-shell"),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueString("sys_poll"),
-        TmfStateValue.newValueString("unity-2d-panel"),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueInt(1),
-        TmfStateValue.newValueInt(20),
-        TmfStateValue.newValueString("sys_poll"),
-        TmfStateValue.newValueString("indicator-multi"),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueInt(1),
-        TmfStateValue.newValueInt(20),
-        TmfStateValue.newValueString("sys_poll"),
-        TmfStateValue.newValueString("gdbus"),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueInt(1),
-        TmfStateValue.newValueInt(20),
-        TmfStateValue.newValueString("sys_poll"),
-        TmfStateValue.newValueString("dbus-daemon"),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueInt(1),
-        TmfStateValue.newValueInt(20),
-        TmfStateValue.newValueString("sys_poll"),
-        TmfStateValue.newValueString("gdbus"),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueInt(1),
-        TmfStateValue.newValueInt(20),
-        TmfStateValue.newValueString("sys_poll"),
-        TmfStateValue.newValueString("indicator-appli"),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueInt(1),
-        TmfStateValue.newValueInt(20),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueInt(3),
-        TmfStateValue.newValueInt(20),
-        TmfStateValue.newValueString("sys_poll"),
-        TmfStateValue.newValueString("gdbus"),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueString("sys_poll"),
-        TmfStateValue.newValueString("gdbus"),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueInt(5),
-        TmfStateValue.newValueInt(20),
-        TmfStateValue.newValueString("sys_futex"),
-        TmfStateValue.newValueString("unity-panel-ser"),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueInt(1),
-        TmfStateValue.newValueInt(20),
-        TmfStateValue.newValueString("sys_poll"),
-        TmfStateValue.newValueString("hud-service"),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueInt(1),
-        TmfStateValue.newValueInt(20),
-        TmfStateValue.newValueString("sys_poll"),
-        TmfStateValue.newValueString("gdbus"),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueInt(1),
-        TmfStateValue.newValueInt(20),
-        TmfStateValue.newValueString("sys_poll"),
-        TmfStateValue.newValueString("openvpn"),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueInt(1),
-        TmfStateValue.newValueInt(20),
-        TmfStateValue.newValueString("sys_poll"),
-        TmfStateValue.newValueString("firefox"),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueInt(1),
-        TmfStateValue.newValueInt(20),
-        TmfStateValue.newValueString("sys_futex"),
-        TmfStateValue.newValueString("thunderbird-bin"),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueInt(1),
-        TmfStateValue.newValueInt(20),
-        TmfStateValue.newValueString("sys_poll"),
-        TmfStateValue.newValueString("thunderbird-bin"),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueInt(1),
-        TmfStateValue.newValueInt(20),
-        TmfStateValue.newValueString("sys_poll"),
-        TmfStateValue.newValueString("thunderbird-bin"),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueInt(1),
-        TmfStateValue.newValueInt(20),
-        TmfStateValue.newValueString("sys_futex"),
-        TmfStateValue.newValueString("thunderbird-bin"),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueInt(2),
-        TmfStateValue.newValueInt(20),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueString("gdbus"),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueInt(1),
-        TmfStateValue.newValueInt(20),
-        TmfStateValue.newValueString("sys_nanosleep"),
-        TmfStateValue.newValueString("gvfs-afc-volume"),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueInt(1),
-        TmfStateValue.newValueInt(20),
-        TmfStateValue.newValueString("sys_poll"),
-        TmfStateValue.newValueString("rtkit-daemon"),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueInt(1),
-        TmfStateValue.newValueInt(-100),
-        TmfStateValue.newValueString("sys_poll"),
-        TmfStateValue.newValueString("rtkit-daemon"),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueInt(1),
-        TmfStateValue.newValueInt(20),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueInt(1),
-        TmfStateValue.newValueInt(20),
-        TmfStateValue.newValueString("sys_poll"),
-        TmfStateValue.newValueString("thunderbird-bin"),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueString("sys_poll"),
-        TmfStateValue.newValueString("thunderbird-bin"),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueInt(1),
-        TmfStateValue.newValueInt(20),
-        TmfStateValue.newValueString("sys_futex"),
-        TmfStateValue.newValueString("thunderbird-bin"),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.newValueInt(1),
-        TmfStateValue.newValueInt(20),
-        TmfStateValue.newValueString("sys_futex"),
-        TmfStateValue.newValueString("firefox"),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-        TmfStateValue.nullValue(),
-    };
-}
-
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/vm/AllTests.java b/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/vm/AllTests.java
deleted file mode 100644 (file)
index 2223160..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2014 École Polytechnique de Montréal
- *
- * 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:
- *   Geneviève Bastien - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.kernel.core.tests.analysis.vm;
-
-import org.junit.runner.RunWith;
-import org.junit.runners.Suite;
-
-/**
- * Test suite
- */
-@RunWith(Suite.class)
-@Suite.SuiteClasses({
-        VirtualMachineAnalysisTest.class
-})
-public class AllTests {
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/vm/VirtualMachineAnalysisTest.java b/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/analysis/vm/VirtualMachineAnalysisTest.java
deleted file mode 100644 (file)
index e5cd79b..0000000
+++ /dev/null
@@ -1,196 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2014, 2015 École Polytechnique de Montréal
- *
- * 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:
- *   Geneviève Bastien - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.kernel.core.tests.analysis.vm;
-
-import static org.eclipse.tracecompass.common.core.NonNullUtils.checkNotNull;
-import static org.junit.Assert.assertEquals;
-import static org.junit.Assert.assertNotNull;
-import static org.junit.Assert.fail;
-import static org.junit.Assume.assumeTrue;
-
-import java.util.Collection;
-import java.util.List;
-
-import org.eclipse.core.runtime.NullProgressMonitor;
-import org.eclipse.tracecompass.analysis.os.linux.core.kernelanalysis.KernelAnalysisModule;
-import org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.VcpuStateValues;
-import org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.VmAttributes;
-import org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.module.VirtualMachineCpuAnalysis;
-import org.eclipse.tracecompass.lttng2.lttng.kernel.core.tests.shared.vm.VmTestExperiment;
-import org.eclipse.tracecompass.statesystem.core.ITmfStateSystem;
-import org.eclipse.tracecompass.statesystem.core.StateSystemUtils;
-import org.eclipse.tracecompass.statesystem.core.exceptions.AttributeNotFoundException;
-import org.eclipse.tracecompass.statesystem.core.exceptions.StateSystemDisposedException;
-import org.eclipse.tracecompass.statesystem.core.interval.ITmfStateInterval;
-import org.eclipse.tracecompass.statesystem.core.statevalue.ITmfStateValue;
-import org.eclipse.tracecompass.statesystem.core.statevalue.TmfStateValue;
-import org.eclipse.tracecompass.tmf.core.signal.TmfTraceOpenedSignal;
-import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace;
-import org.eclipse.tracecompass.tmf.core.trace.TmfTrace;
-import org.eclipse.tracecompass.tmf.core.trace.TmfTraceUtils;
-import org.eclipse.tracecompass.tmf.core.trace.experiment.TmfExperiment;
-import org.junit.Test;
-
-import com.google.common.collect.Multimap;
-
-/**
- * Test suite for the {@link VirtualMachineCpuAnalysis} class
- *
- * @author Geneviève Bastien
- */
-public class VirtualMachineAnalysisTest {
-
-    private static void verifyStateIntervals(String testId, List<ITmfStateInterval> intervals, int[] expectedStarts, ITmfStateValue[] expectedValues) {
-        int expectedCount = expectedStarts.length - 1;
-
-        assertEquals(testId + ": Interval count", expectedCount, intervals.size());
-        for (int i = 0; i < expectedCount; i++) {
-            ITmfStateInterval interval = intervals.get(i);
-            assertEquals(testId + ": Start time of interval " + i, expectedStarts[i], interval.getStartTime());
-            long actualEnd = (i == expectedCount - 1) ? (expectedStarts[i + 1]) : (expectedStarts[i + 1]) - 1;
-            assertEquals(testId + ": End time of interval " + i, actualEnd, interval.getEndTime());
-            assertEquals(testId + ": Expected value of interval " + i, expectedValues[i], interval.getStateValue());
-        }
-    }
-
-    private static void verifyIntervalsWithMask(String testId, Collection<ITmfStateInterval> intervals, int[] expectedStarts, int[] expectedEnds, ITmfStateValue[] expectedValues, int mask) {
-        int expectedCount = expectedStarts.length - 1;
-
-        assertEquals(testId + ": Interval count", expectedCount, intervals.size());
-        int i = 0;
-        for (ITmfStateInterval interval : intervals) {
-            assertEquals(testId + ": Start time of interval " + i, expectedStarts[i], interval.getStartTime());
-            assertEquals(testId + ": End time of interval " + i, expectedEnds[i], interval.getEndTime());
-            assertEquals(testId + ": Expected value of interval " + i, expectedValues[i].unboxInt() & mask, interval.getStateValue().unboxInt() & mask);
-            i++;
-        }
-    }
-
-    /**
-     * Test the analysis execution with stub traces of a virtual machine with
-     * one virtual machine and one CPU
-     */
-    @Test
-    public void testStubTracesOneQemuKvm() {
-
-        assumeTrue(VmTestExperiment.ONE_QEMUKVM.exists());
-        TmfExperiment experiment = VmTestExperiment.ONE_QEMUKVM.getExperiment(true);
-
-        /* Open the traces */
-        for (ITmfTrace trace : experiment.getTraces()) {
-            ((TmfTrace) trace).traceOpened(new TmfTraceOpenedSignal(this, trace, null));
-        }
-
-        /*
-         * TODO For now, make sure the LttngKernelAnalysis have been run for
-         * each trace before running the analysis. When event request precedence
-         * is implemented, we can remove this
-         */
-        for (ITmfTrace trace : experiment.getTraces()) {
-            trace = checkNotNull(trace);
-            for (KernelAnalysisModule module : TmfTraceUtils.getAnalysisModulesOfClass(trace, KernelAnalysisModule.class)) {
-                module.schedule();
-                module.waitForCompletion();
-            }
-        }
-        /* End of TODO block */
-
-        experiment.traceOpened(new TmfTraceOpenedSignal(this, experiment, null));
-        VirtualMachineCpuAnalysis module = null;
-        for (VirtualMachineCpuAnalysis mod : TmfTraceUtils.getAnalysisModulesOfClass(experiment, VirtualMachineCpuAnalysis.class)) {
-            module = mod;
-            break;
-        }
-        assertNotNull(module);
-        module.schedule();
-        if (!module.waitForCompletion()) {
-            fail("Module did not complete properly");
-        }
-
-        try {
-            /* Check the state system */
-            ITmfStateSystem ss = module.getStateSystem();
-            assertNotNull(ss);
-            int vmQuark;
-
-            vmQuark = ss.getQuarkAbsolute(VmAttributes.VIRTUAL_MACHINES);
-
-            List<Integer> guestQuarks = ss.getSubAttributes(vmQuark, false);
-            assertEquals("Number of guests", 1, guestQuarks.size());
-            List<Integer> vcpuQuarks = ss.getSubAttributes(guestQuarks.get(0), false);
-            assertEquals("Number of virtual CPUs", 1, vcpuQuarks.size());
-            Integer statusQuark = ss.getQuarkRelative(vcpuQuarks.get(0), VmAttributes.STATUS);
-
-            /* Check the intervals for the virtual CPU */
-            List<ITmfStateInterval> intervals = StateSystemUtils.queryHistoryRange(ss, statusQuark, ss.getStartTime(), ss.getCurrentEndTime());
-
-            /* Expected interval values for the virtual CPU */
-            int[] expectedStarts = { 1, 60, 75, 95, 100, 150, 155, 195, 210, 245, 260, 295, 300, 350, 355, 375 };
-            ITmfStateValue[] expectedValues = { TmfStateValue.nullValue(),
-                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_UNKNOWN),
-                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_RUNNING),
-                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_RUNNING | VcpuStateValues.VCPU_VMM),
-                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_RUNNING | VcpuStateValues.VCPU_VMM | VcpuStateValues.VCPU_PREEMPT),
-                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_RUNNING | VcpuStateValues.VCPU_VMM),
-                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_RUNNING),
-                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_RUNNING | VcpuStateValues.VCPU_VMM),
-                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_RUNNING),
-                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_RUNNING | VcpuStateValues.VCPU_VMM),
-                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_RUNNING),
-                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_RUNNING | VcpuStateValues.VCPU_VMM),
-                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_RUNNING | VcpuStateValues.VCPU_VMM | VcpuStateValues.VCPU_PREEMPT),
-                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_RUNNING | VcpuStateValues.VCPU_VMM),
-                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_RUNNING) };
-            verifyStateIntervals("Virtual CPU", intervals, expectedStarts, expectedValues);
-
-            /* Check the status of the guest's threads */
-            int[] expectedStartsT130 = { 10, 35, 75, 175, 195, 225, 275, 295, 300, 350, 375 };
-            int[] expectedEndsT130 = { 34, 74, 174, 224, 209, 274, 374, 299, 349, 354, 375 };
-            ITmfStateValue[] expectedValuesT30 = { TmfStateValue.newValueInt(VcpuStateValues.VCPU_IDLE),
-                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_RUNNING),
-                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_IDLE),
-                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_RUNNING),
-                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_PREEMPT),
-                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_IDLE),
-                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_RUNNING),
-                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_PREEMPT),
-                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_PREEMPT),
-                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_PREEMPT),
-                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_RUNNING) };
-
-            int[] expectedStartsT131 = { 10, 35, 75, 95, 100, 150, 175, 225, 245, 275, 375 };
-            int[] expectedEndsT131 = { 34, 74, 174, 99, 149, 154, 224, 274, 259, 374, 375 };
-            ITmfStateValue[] expectedValuesT31 = { TmfStateValue.newValueInt(VcpuStateValues.VCPU_RUNNING),
-                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_IDLE),
-                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_RUNNING),
-                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_PREEMPT),
-                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_PREEMPT),
-                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_PREEMPT),
-                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_IDLE),
-                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_RUNNING),
-                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_PREEMPT),
-                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_IDLE),
-                    TmfStateValue.newValueInt(VcpuStateValues.VCPU_RUNNING) };
-
-            Multimap<Integer, ITmfStateInterval> threadIntervals = module.getUpdatedThreadIntervals(guestQuarks.get(0), ss.getStartTime(), ss.getCurrentEndTime(), 1, new NullProgressMonitor());
-            verifyIntervalsWithMask("Thread 130", threadIntervals.get(130), expectedStartsT130, expectedEndsT130, expectedValuesT30, VcpuStateValues.VCPU_PREEMPT);
-            verifyIntervalsWithMask("Thread 131", threadIntervals.get(131), expectedStartsT131, expectedEndsT131, expectedValuesT31, VcpuStateValues.VCPU_PREEMPT);
-
-        } catch (AttributeNotFoundException | StateSystemDisposedException e) {
-            fail(e.getMessage());
-        } finally {
-            experiment.dispose();
-        }
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/event/matchandsync/AllTests.java b/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/event/matchandsync/AllTests.java
deleted file mode 100644 (file)
index 2402a4b..0000000
+++ /dev/null
@@ -1,28 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2013, 2014 École Polytechnique de Montréal
- *
- * 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:
- *   Geneviève Bastien - Initial implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.kernel.core.tests.event.matchandsync;
-
-import org.junit.runner.RunWith;
-import org.junit.runners.Suite;
-
-/**
- * Test suite for org.eclipse.linuxtools.lttng2.kernel.core.tests.event.matching
- */
-@RunWith(Suite.class)
-@Suite.SuiteClasses({
-    ExperimentSyncTest.class,
-    MatchAndSyncTest.class
-})
-public class AllTests {
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/event/matchandsync/ExperimentSyncTest.java b/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/event/matchandsync/ExperimentSyncTest.java
deleted file mode 100644 (file)
index 4a65cf0..0000000
+++ /dev/null
@@ -1,112 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2013, 2014 École Polytechnique de Montréal
- *
- * 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:
- *   Geneviève Bastien - Initial implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.kernel.core.tests.event.matchandsync;
-
-import static org.junit.Assert.assertEquals;
-import static org.junit.Assume.assumeTrue;
-
-import org.eclipse.tracecompass.internal.lttng2.kernel.core.event.matching.TcpEventMatching;
-import org.eclipse.tracecompass.internal.lttng2.kernel.core.event.matching.TcpLttngEventMatching;
-import org.eclipse.tracecompass.tmf.core.event.matching.TmfEventMatching;
-import org.eclipse.tracecompass.tmf.core.synchronization.ITmfTimestampTransform;
-import org.eclipse.tracecompass.tmf.core.synchronization.SynchronizationAlgorithm;
-import org.eclipse.tracecompass.tmf.core.synchronization.TimestampTransformFactory;
-import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace;
-import org.eclipse.tracecompass.tmf.core.trace.experiment.TmfExperiment;
-import org.eclipse.tracecompass.tmf.ctf.core.tests.shared.CtfTmfTestTrace;
-import org.eclipse.tracecompass.tmf.ctf.core.trace.CtfTmfTrace;
-import org.junit.BeforeClass;
-import org.junit.Test;
-
-/**
- * Tests for experiment syncing
- *
- * @author Geneviève Bastien
- */
-@SuppressWarnings("nls")
-public class ExperimentSyncTest {
-
-    private static final String EXPERIMENT = "MyExperiment";
-    private static int BLOCK_SIZE = 1000;
-
-    /**
-     * Initialize some data
-     */
-    @BeforeClass
-    public static void setUp() {
-        TmfEventMatching.registerMatchObject(new TcpEventMatching());
-        TmfEventMatching.registerMatchObject(new TcpLttngEventMatching());
-    }
-
-    /**
-     * Testing experiment synchronization
-     */
-    @Test
-    public void testExperimentSync() {
-        assumeTrue(CtfTmfTestTrace.SYNC_SRC.exists());
-        assumeTrue(CtfTmfTestTrace.SYNC_DEST.exists());
-        try (CtfTmfTrace trace1 = CtfTmfTestTrace.SYNC_SRC.getTrace();
-                CtfTmfTrace trace2 = CtfTmfTestTrace.SYNC_DEST.getTrace();) {
-
-            ITmfTrace[] traces = { trace1, trace2 };
-            TmfExperiment experiment = new TmfExperiment(traces[0].getEventType(), EXPERIMENT, traces, BLOCK_SIZE, null);
-
-            SynchronizationAlgorithm syncAlgo = experiment.synchronizeTraces(true);
-
-            ITmfTimestampTransform tt1 = syncAlgo.getTimestampTransform(trace1);
-            ITmfTimestampTransform tt2 = syncAlgo.getTimestampTransform(trace2);
-
-            trace1.setTimestampTransform(tt1);
-            trace2.setTimestampTransform(tt2);
-
-            assertEquals("TmfTimestampTransformLinearFast [ slope = 0.9999413783703139011056845831168394, offset = 79796507913179.33347660124688298171 ]", tt1.toString());
-            assertEquals(TimestampTransformFactory.getDefaultTransform(), tt2);
-
-            assertEquals(syncAlgo.getTimestampTransform(trace1.getHostId()), trace1.getTimestampTransform());
-            assertEquals(syncAlgo.getTimestampTransform(trace2.getHostId()), trace2.getTimestampTransform());
-
-        }
-    }
-
-    /**
-     * Testing synchronization with 3 traces, one of which synchronizes with
-     * both other
-     */
-    @Test
-    public void testDjangoExperimentSync() {
-        assumeTrue(CtfTmfTestTrace.DJANGO_CLIENT.exists());
-        assumeTrue(CtfTmfTestTrace.DJANGO_DB.exists());
-        assumeTrue(CtfTmfTestTrace.DJANGO_HTTPD.exists());
-        try (CtfTmfTrace trace1 = CtfTmfTestTrace.DJANGO_CLIENT.getTrace();
-                CtfTmfTrace trace2 = CtfTmfTestTrace.DJANGO_DB.getTrace();
-                CtfTmfTrace trace3 = CtfTmfTestTrace.DJANGO_HTTPD.getTrace();) {
-            ITmfTrace[] traces = { trace1, trace2, trace3 };
-            TmfExperiment experiment = new TmfExperiment(traces[0].getEventType(), EXPERIMENT, traces, BLOCK_SIZE, null);
-
-            SynchronizationAlgorithm syncAlgo = experiment.synchronizeTraces(true);
-
-            ITmfTimestampTransform tt1 = syncAlgo.getTimestampTransform(trace1);
-            ITmfTimestampTransform tt2 = syncAlgo.getTimestampTransform(trace2);
-            ITmfTimestampTransform tt3 = syncAlgo.getTimestampTransform(trace3);
-
-            trace1.setTimestampTransform(tt1);
-            trace2.setTimestampTransform(tt2);
-            trace3.setTimestampTransform(tt3);
-
-            assertEquals(TimestampTransformFactory.getDefaultTransform(), tt1);
-            assertEquals("TmfTimestampTransformLinearFast [ slope = 0.9999996313017589597204633828681240, offset = 498490309972.0038068817738527724192 ]", tt2.toString());
-            assertEquals("TmfTimestampTransformLinearFast [ slope = 1.000000119014882262265342419815932, offset = -166652893534.6189900382736187431134 ]", tt3.toString());
-
-        }
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/event/matchandsync/MatchAndSyncTest.java b/org.eclipse.tracecompass.lttng2.kernel.core.tests/src/org/eclipse/tracecompass/lttng2/kernel/core/tests/event/matchandsync/MatchAndSyncTest.java
deleted file mode 100644 (file)
index 29aa3ad..0000000
+++ /dev/null
@@ -1,77 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2013, 2014 École Polytechnique de Montréal
- *
- * 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:
- *   Geneviève Bastien - Initial implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.kernel.core.tests.event.matchandsync;
-
-import static org.junit.Assert.assertEquals;
-import static org.junit.Assert.assertTrue;
-import static org.junit.Assert.fail;
-import static org.junit.Assume.assumeTrue;
-
-import java.lang.reflect.InvocationTargetException;
-import java.lang.reflect.Method;
-import java.util.LinkedList;
-import java.util.List;
-
-import org.eclipse.tracecompass.internal.lttng2.kernel.core.event.matching.TcpEventMatching;
-import org.eclipse.tracecompass.internal.lttng2.kernel.core.event.matching.TcpLttngEventMatching;
-import org.eclipse.tracecompass.tmf.core.event.matching.IMatchProcessingUnit;
-import org.eclipse.tracecompass.tmf.core.event.matching.TmfEventMatching;
-import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace;
-import org.eclipse.tracecompass.tmf.ctf.core.tests.shared.CtfTmfTestTrace;
-import org.eclipse.tracecompass.tmf.ctf.core.trace.CtfTmfTrace;
-import org.junit.Test;
-
-/**
- * Tests for {@link TcpEventMatching}
- *
- * @author Geneviève Bastien
- */
-@SuppressWarnings("nls")
-public class MatchAndSyncTest {
-
-    /**
-     * Testing the packet matching
-     */
-    @Test
-    public void testMatching() {
-        assumeTrue(CtfTmfTestTrace.SYNC_SRC.exists());
-        assumeTrue(CtfTmfTestTrace.SYNC_DEST.exists());
-        try (CtfTmfTrace trace1 = CtfTmfTestTrace.SYNC_SRC.getTrace();
-                CtfTmfTrace trace2 = CtfTmfTestTrace.SYNC_DEST.getTrace();) {
-
-            List<ITmfTrace> tracearr = new LinkedList<>();
-            tracearr.add(trace1);
-            tracearr.add(trace2);
-
-            TmfEventMatching.registerMatchObject(new TcpEventMatching());
-            TmfEventMatching.registerMatchObject(new TcpLttngEventMatching());
-
-            TmfEventMatching twoTraceMatch = new TmfEventMatching(tracearr);
-            assertTrue(twoTraceMatch.matchEvents());
-
-            /* Set method and fields accessible to make sure the counts are ok */
-            try {
-                /* Verify number of matches */
-                Method method = TmfEventMatching.class.getDeclaredMethod("getProcessingUnit");
-                method.setAccessible(true);
-                IMatchProcessingUnit procUnit = (IMatchProcessingUnit) method.invoke(twoTraceMatch);
-                assertEquals(46, procUnit.countMatches());
-
-            } catch (NoSuchMethodException | SecurityException | IllegalAccessException | IllegalArgumentException | InvocationTargetException e) {
-                fail(e.getMessage());
-            }
-
-        }
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core.tests/testfiles/vm/OneQemuKvm/guest.xml b/org.eclipse.tracecompass.lttng2.kernel.core.tests/testfiles/vm/OneQemuKvm/guest.xml
deleted file mode 100644 (file)
index fc973d3..0000000
+++ /dev/null
@@ -1,105 +0,0 @@
-<trace>
-<event timestamp="0" name="set_aspects">
-<field name="cpu" value="1" type="int" />
-</event>
-<event timestamp="10" name="sched_switch">
-<field name="cpu" value="0" type="int" />
-<field name="prev_comm" value="any" type="string" />
-<field name="prev_tid" value="130" type="long" />
-<field name="prev_prio" value="20" type="long" />
-<field name="prev_state" value="0" type="long" />
-<field name="next_comm" value="any2" type="string" />
-<field name="next_tid" value="131" type="long" />
-<field name="next_prio" value="20" type="long" />
-</event>
-<event timestamp="35" name="sched_switch">
-<field name="cpu" value="0" type="int" />
-<field name="prev_comm" value="any2" type="string" />
-<field name="prev_tid" value="131" type="long" />
-<field name="prev_prio" value="20" type="long" />
-<field name="prev_state" value="0" type="long" />
-<field name="next_comm" value="any" type="string" />
-<field name="next_tid" value="130" type="long" />
-<field name="next_prio" value="20" type="long" />
-</event>
-<event timestamp="40" name="vmsync_gh_guest">
-<field name="cpu" value="0" type="int" />
-<field name="cnt" value="1" type="int" />
-<field name="vm_uid" value="123456" type="long" />
-</event>
-<event timestamp="65" name="vmsync_hg_guest">
-<field name="cpu" value="0" type="int" />
-<field name="cnt" value="2" type="int" />
-<field name="vm_uid" value="123456" type="long" />
-</event>
-<event timestamp="75" name="sched_switch">
-<field name="cpu" value="0" type="int" />
-<field name="prev_comm" value="any" type="string" />
-<field name="prev_tid" value="130" type="long" />
-<field name="prev_prio" value="20" type="long" />
-<field name="prev_state" value="0" type="long" />
-<field name="next_comm" value="any2" type="string" />
-<field name="next_tid" value="131" type="long" />
-<field name="next_prio" value="20" type="long" />
-</event>
-<event timestamp="175" name="sched_switch">
-<field name="cpu" value="0" type="int" />
-<field name="prev_comm" value="any2" type="string" />
-<field name="prev_tid" value="131" type="long" />
-<field name="prev_prio" value="20" type="long" />
-<field name="prev_state" value="0" type="long" />
-<field name="next_comm" value="any" type="string" />
-<field name="next_tid" value="130" type="long" />
-<field name="next_prio" value="20" type="long" />
-</event>
-<event timestamp="190" name="vmsync_gh_guest">
-<field name="cpu" value="0" type="int" />
-<field name="cnt" value="3" type="int" />
-<field name="vm_uid" value="123456" type="long" />
-</event>
-<event timestamp="215" name="vmsync_hg_guest">
-<field name="cpu" value="0" type="int" />
-<field name="cnt" value="4" type="int" />
-<field name="vm_uid" value="123456" type="long" />
-</event>
-<event timestamp="225" name="sched_switch">
-<field name="cpu" value="0" type="int" />
-<field name="prev_comm" value="any" type="string" />
-<field name="prev_tid" value="130" type="long" />
-<field name="prev_prio" value="20" type="long" />
-<field name="prev_state" value="0" type="long" />
-<field name="next_comm" value="any2" type="string" />
-<field name="next_tid" value="131" type="long" />
-<field name="next_prio" value="20" type="long" />
-</event>
-<event timestamp="240" name="vmsync_gh_guest">
-<field name="cpu" value="0" type="int" />
-<field name="cnt" value="5" type="int" />
-<field name="vm_uid" value="123456" type="long" />
-</event>
-<event timestamp="265" name="vmsync_hg_guest">
-<field name="cpu" value="0" type="int" />
-<field name="cnt" value="6" type="int" />
-<field name="vm_uid" value="123456" type="long" />
-</event>
-<event timestamp="275" name="sched_switch">
-<field name="cpu" value="0" type="int" />
-<field name="prev_comm" value="any2" type="string" />
-<field name="prev_tid" value="131" type="long" />
-<field name="prev_prio" value="20" type="long" />
-<field name="prev_state" value="0" type="long" />
-<field name="next_comm" value="any" type="string" />
-<field name="next_tid" value="130" type="long" />
-<field name="next_prio" value="20" type="long" />
-</event>
-<event timestamp="375" name="sched_switch">
-<field name="cpu" value="0" type="int" />
-<field name="prev_comm" value="any" type="string" />
-<field name="prev_tid" value="130" type="long" />
-<field name="prev_prio" value="20" type="long" />
-<field name="prev_state" value="0" type="long" />
-<field name="next_comm" value="any2" type="string" />
-<field name="next_tid" value="131" type="long" />
-<field name="next_prio" value="20" type="long" />
-</event>
-</trace>
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core.tests/testfiles/vm/OneQemuKvm/host.xml b/org.eclipse.tracecompass.lttng2.kernel.core.tests/testfiles/vm/OneQemuKvm/host.xml
deleted file mode 100644 (file)
index c26e836..0000000
+++ /dev/null
@@ -1,149 +0,0 @@
-<trace>
-<event timestamp="0" name="set_aspects">
-<field name="cpu" value="1" type="int" />
-</event>
-<event timestamp="1" name="sched_switch">
-<field name="cpu" value="0" type="int" />
-<field name="prev_comm" value="any" type="string" />
-<field name="prev_tid" value="30" type="long" />
-<field name="prev_prio" value="20" type="long" />
-<field name="prev_state" value="0" type="long" />
-<field name="next_comm" value="qemucpu1" type="string" />
-<field name="next_tid" value="31" type="long" />
-<field name="next_prio" value="20" type="long" />
-</event>
-<event timestamp="5" name="kvm_entry">
-<field name="cpu" value="0" type="int" />
-<field name="vcpu_id" value="0" type="long" />
-</event>
-<event timestamp="45" name="kvm_exit">
-<field name="cpu" value="0" type="int" />
-<field name="exit_reason" value="32" type="int" />
-<field name="guest_rip" value="123456" type="long" />
-<field name="isa" value="1" type="int" />
-<field name="info1" value="654654" type="long" />
-<field name="info2" value="456789" type="long" />
-</event>
-<event timestamp="50" name="vmsync_gh_host">
-<field name="cpu" value="0" type="int" />
-<field name="cnt" value="1" type="int" />
-<field name="vm_uid" value="123456" type="long" />
-</event>
-<event timestamp="55" name="vmsync_hg_host">
-<field name="cpu" value="0" type="int" />
-<field name="cnt" value="2" type="int" />
-<field name="vm_uid" value="123456" type="long" />
-</event>
-<event timestamp="60" name="kvm_entry">
-<field name="cpu" value="0" type="int" />
-<field name="vcpu_id" value="0" type="long" />
-</event>
-<event timestamp="95" name="kvm_exit">
-<field name="cpu" value="0" type="int" />
-<field name="exit_reason" value="32" type="int" />
-<field name="guest_rip" value="123456" type="long" />
-<field name="isa" value="1" type="int" />
-<field name="info1" value="654654" type="long" />
-<field name="info2" value="456789" type="long" />
-</event>
-<event timestamp="100" name="sched_switch">
-<field name="cpu" value="0" type="int" />
-<field name="prev_comm" value="qemucpu1" type="string" />
-<field name="prev_tid" value="31" type="long" />
-<field name="prev_prio" value="20" type="long" />
-<field name="prev_state" value="0" type="long" />
-<field name="next_comm" value="any" type="string" />
-<field name="next_tid" value="30" type="long" />
-<field name="next_prio" value="20" type="long" />
-</event>
-<event timestamp="150" name="sched_switch">
-<field name="cpu" value="0" type="int" />
-<field name="prev_comm" value="any" type="string" />
-<field name="prev_tid" value="30" type="long" />
-<field name="prev_prio" value="20" type="long" />
-<field name="prev_state" value="0" type="long" />
-<field name="next_comm" value="qemucpu1" type="string" />
-<field name="next_tid" value="31" type="long" />
-<field name="next_prio" value="20" type="long" />
-</event>
-<event timestamp="155" name="kvm_entry">
-<field name="cpu" value="0" type="int" />
-<field name="vcpu_id" value="0" type="long" />
-</event>
-<event timestamp="195" name="kvm_exit">
-<field name="cpu" value="0" type="int" />
-<field name="exit_reason" value="32" type="int" />
-<field name="guest_rip" value="123456" type="long" />
-<field name="isa" value="1" type="int" />
-<field name="info1" value="654654" type="long" />
-<field name="info2" value="456789" type="long" />
-</event>
-<event timestamp="200" name="vmsync_gh_host">
-<field name="cpu" value="0" type="int" />
-<field name="cnt" value="3" type="int" />
-<field name="vm_uid" value="123456" type="long" />
-</event>
-<event timestamp="205" name="vmsync_hg_host">
-<field name="cpu" value="0" type="int" />
-<field name="cnt" value="4" type="int" />
-<field name="vm_uid" value="123456" type="long" />
-</event>
-<event timestamp="210" name="kvm_entry">
-<field name="cpu" value="0" type="int" />
-<field name="vcpu_id" value="0" type="long" />
-</event>
-<event timestamp="245" name="kvm_exit">
-<field name="cpu" value="0" type="int" />
-<field name="exit_reason" value="32" type="int" />
-<field name="guest_rip" value="123456" type="long" />
-<field name="isa" value="1" type="int" />
-<field name="info1" value="654654" type="long" />
-<field name="info2" value="456789" type="long" />
-</event>
-<event timestamp="250" name="vmsync_gh_host">
-<field name="cpu" value="0" type="int" />
-<field name="cnt" value="5" type="int" />
-<field name="vm_uid" value="123456" type="long" />
-</event>
-<event timestamp="255" name="vmsync_hg_host">
-<field name="cpu" value="0" type="int" />
-<field name="cnt" value="6" type="int" />
-<field name="vm_uid" value="123456" type="long" />
-</event>
-<event timestamp="260" name="kvm_entry">
-<field name="cpu" value="0" type="int" />
-<field name="vcpu_id" value="0" type="long" />
-</event>
-<event timestamp="295" name="kvm_exit">
-<field name="cpu" value="0" type="int" />
-<field name="exit_reason" value="32" type="int" />
-<field name="guest_rip" value="123456" type="long" />
-<field name="isa" value="1" type="int" />
-<field name="info1" value="654654" type="long" />
-<field name="info2" value="456789" type="long" />
-</event>
-<event timestamp="300" name="sched_switch">
-<field name="cpu" value="0" type="int" />
-<field name="prev_comm" value="qemucpu1" type="string" />
-<field name="prev_tid" value="31" type="long" />
-<field name="prev_prio" value="20" type="long" />
-<field name="prev_state" value="0" type="long" />
-<field name="next_comm" value="any" type="string" />
-<field name="next_tid" value="30" type="long" />
-<field name="next_prio" value="20" type="long" />
-</event>
-<event timestamp="350" name="sched_switch">
-<field name="cpu" value="0" type="int" />
-<field name="prev_comm" value="any" type="string" />
-<field name="prev_tid" value="30" type="long" />
-<field name="prev_prio" value="20" type="long" />
-<field name="prev_state" value="0" type="long" />
-<field name="next_comm" value="qemucpu1" type="string" />
-<field name="next_tid" value="31" type="long" />
-<field name="next_prio" value="20" type="long" />
-</event>
-<event timestamp="355" name="kvm_entry">
-<field name="cpu" value="0" type="int" />
-<field name="vcpu_id" value="0" type="long" />
-</event>
-</trace>
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core/.classpath b/org.eclipse.tracecompass.lttng2.kernel.core/.classpath
deleted file mode 100644 (file)
index 098194c..0000000
+++ /dev/null
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
-       <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7"/>
-       <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
-       <classpathentry kind="src" path="src"/>
-       <classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core/.project b/org.eclipse.tracecompass.lttng2.kernel.core/.project
deleted file mode 100644 (file)
index 6883fd5..0000000
+++ /dev/null
@@ -1,34 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
-       <name>org.eclipse.tracecompass.lttng2.kernel.core</name>
-       <comment></comment>
-       <projects>
-       </projects>
-       <buildSpec>
-               <buildCommand>
-                       <name>org.eclipse.jdt.core.javabuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-               <buildCommand>
-                       <name>org.eclipse.pde.ManifestBuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-               <buildCommand>
-                       <name>org.eclipse.pde.SchemaBuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-               <buildCommand>
-                       <name>org.eclipse.pde.api.tools.apiAnalysisBuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-       </buildSpec>
-       <natures>
-               <nature>org.eclipse.pde.PluginNature</nature>
-               <nature>org.eclipse.jdt.core.javanature</nature>
-               <nature>org.eclipse.pde.api.tools.apiAnalysisNature</nature>
-       </natures>
-</projectDescription>
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core/.settings/org.eclipse.core.resources.prefs b/org.eclipse.tracecompass.lttng2.kernel.core/.settings/org.eclipse.core.resources.prefs
deleted file mode 100644 (file)
index 99f26c0..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-eclipse.preferences.version=1
-encoding/<project>=UTF-8
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core/.settings/org.eclipse.core.runtime.prefs b/org.eclipse.tracecompass.lttng2.kernel.core/.settings/org.eclipse.core.runtime.prefs
deleted file mode 100644 (file)
index 5a0ad22..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-eclipse.preferences.version=1
-line.separator=\n
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core/.settings/org.eclipse.jdt.core.prefs b/org.eclipse.tracecompass.lttng2.kernel.core/.settings/org.eclipse.jdt.core.prefs
deleted file mode 100644 (file)
index a2b5e6b..0000000
+++ /dev/null
@@ -1,405 +0,0 @@
-eclipse.preferences.version=1
-org.eclipse.jdt.core.codeComplete.argumentPrefixes=
-org.eclipse.jdt.core.codeComplete.argumentSuffixes=
-org.eclipse.jdt.core.codeComplete.fieldPrefixes=f
-org.eclipse.jdt.core.codeComplete.fieldSuffixes=
-org.eclipse.jdt.core.codeComplete.localPrefixes=
-org.eclipse.jdt.core.codeComplete.localSuffixes=
-org.eclipse.jdt.core.codeComplete.staticFieldPrefixes=
-org.eclipse.jdt.core.codeComplete.staticFieldSuffixes=
-org.eclipse.jdt.core.codeComplete.staticFinalFieldPrefixes=
-org.eclipse.jdt.core.codeComplete.staticFinalFieldSuffixes=
-org.eclipse.jdt.core.compiler.annotation.inheritNullAnnotations=enabled
-org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore
-org.eclipse.jdt.core.compiler.annotation.nonnull=org.eclipse.jdt.annotation.NonNull
-org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=org.eclipse.jdt.annotation.NonNullByDefault
-org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nullable
-org.eclipse.jdt.core.compiler.annotation.nullanalysis=enabled
-org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
-org.eclipse.jdt.core.compiler.codegen.methodParameters=do not generate
-org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
-org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
-org.eclipse.jdt.core.compiler.compliance=1.7
-org.eclipse.jdt.core.compiler.debug.lineNumber=generate
-org.eclipse.jdt.core.compiler.debug.localVariable=generate
-org.eclipse.jdt.core.compiler.debug.sourceFile=generate
-org.eclipse.jdt.core.compiler.doc.comment.support=enabled
-org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=error
-org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
-org.eclipse.jdt.core.compiler.problem.autoboxing=ignore
-org.eclipse.jdt.core.compiler.problem.comparingIdentical=error
-org.eclipse.jdt.core.compiler.problem.deadCode=error
-org.eclipse.jdt.core.compiler.problem.deprecation=error
-org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled
-org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=enabled
-org.eclipse.jdt.core.compiler.problem.discouragedReference=warning
-org.eclipse.jdt.core.compiler.problem.emptyStatement=error
-org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
-org.eclipse.jdt.core.compiler.problem.explicitlyClosedAutoCloseable=error
-org.eclipse.jdt.core.compiler.problem.fallthroughCase=error
-org.eclipse.jdt.core.compiler.problem.fatalOptionalError=disabled
-org.eclipse.jdt.core.compiler.problem.fieldHiding=error
-org.eclipse.jdt.core.compiler.problem.finalParameterBound=error
-org.eclipse.jdt.core.compiler.problem.finallyBlockNotCompletingNormally=error
-org.eclipse.jdt.core.compiler.problem.forbiddenReference=error
-org.eclipse.jdt.core.compiler.problem.hiddenCatchBlock=error
-org.eclipse.jdt.core.compiler.problem.includeNullInfoFromAsserts=disabled
-org.eclipse.jdt.core.compiler.problem.incompatibleNonInheritedInterfaceMethod=error
-org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch=error
-org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=error
-org.eclipse.jdt.core.compiler.problem.invalidJavadoc=warning
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTags=enabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsDeprecatedRef=enabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsNotVisibleRef=enabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsVisibility=protected
-org.eclipse.jdt.core.compiler.problem.localVariableHiding=error
-org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=error
-org.eclipse.jdt.core.compiler.problem.missingDefaultCase=error
-org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=error
-org.eclipse.jdt.core.compiler.problem.missingEnumCaseDespiteDefault=enabled
-org.eclipse.jdt.core.compiler.problem.missingHashCodeMethod=error
-org.eclipse.jdt.core.compiler.problem.missingJavadocComments=warning
-org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsOverriding=disabled
-org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsVisibility=protected
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagDescription=all_standard_tags
-org.eclipse.jdt.core.compiler.problem.missingJavadocTags=warning
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagsMethodTypeParameters=disabled
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagsOverriding=disabled
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagsVisibility=protected
-org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotation=error
-org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotationForInterfaceMethodImplementation=enabled
-org.eclipse.jdt.core.compiler.problem.missingSerialVersion=error
-org.eclipse.jdt.core.compiler.problem.missingSynchronizedOnInheritedMethod=error
-org.eclipse.jdt.core.compiler.problem.noEffectAssignment=error
-org.eclipse.jdt.core.compiler.problem.noImplicitStringConversion=error
-org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=warning
-org.eclipse.jdt.core.compiler.problem.nonnullParameterAnnotationDropped=warning
-org.eclipse.jdt.core.compiler.problem.nullAnnotationInferenceConflict=warning
-org.eclipse.jdt.core.compiler.problem.nullReference=error
-org.eclipse.jdt.core.compiler.problem.nullSpecViolation=error
-org.eclipse.jdt.core.compiler.problem.nullUncheckedConversion=warning
-org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=error
-org.eclipse.jdt.core.compiler.problem.parameterAssignment=error
-org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=error
-org.eclipse.jdt.core.compiler.problem.potentialNullReference=error
-org.eclipse.jdt.core.compiler.problem.potentiallyUnclosedCloseable=warning
-org.eclipse.jdt.core.compiler.problem.rawTypeReference=warning
-org.eclipse.jdt.core.compiler.problem.redundantNullAnnotation=warning
-org.eclipse.jdt.core.compiler.problem.redundantNullCheck=error
-org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=error
-org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=error
-org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore
-org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=error
-org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled
-org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=error
-org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=disabled
-org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled
-org.eclipse.jdt.core.compiler.problem.syntacticNullAnalysisForFields=enabled
-org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=ignore
-org.eclipse.jdt.core.compiler.problem.typeParameterHiding=error
-org.eclipse.jdt.core.compiler.problem.unavoidableGenericTypeProblems=disabled
-org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=warning
-org.eclipse.jdt.core.compiler.problem.unclosedCloseable=error
-org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=ignore
-org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=error
-org.eclipse.jdt.core.compiler.problem.unnecessaryElse=error
-org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=error
-org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=warning
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionExemptExceptionAndThrowable=disabled
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionIncludeDocCommentReference=disabled
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverriding=disabled
-org.eclipse.jdt.core.compiler.problem.unusedExceptionParameter=ignore
-org.eclipse.jdt.core.compiler.problem.unusedImport=error
-org.eclipse.jdt.core.compiler.problem.unusedLabel=error
-org.eclipse.jdt.core.compiler.problem.unusedLocal=error
-org.eclipse.jdt.core.compiler.problem.unusedObjectAllocation=ignore
-org.eclipse.jdt.core.compiler.problem.unusedParameter=error
-org.eclipse.jdt.core.compiler.problem.unusedParameterIncludeDocCommentReference=enabled
-org.eclipse.jdt.core.compiler.problem.unusedParameterWhenImplementingAbstract=disabled
-org.eclipse.jdt.core.compiler.problem.unusedParameterWhenOverridingConcrete=disabled
-org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=error
-org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=error
-org.eclipse.jdt.core.compiler.problem.unusedWarningToken=error
-org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=error
-org.eclipse.jdt.core.compiler.source=1.7
-org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_call=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression=16
-org.eclipse.jdt.core.formatter.alignment_for_assignment=0
-org.eclipse.jdt.core.formatter.alignment_for_binary_expression=16
-org.eclipse.jdt.core.formatter.alignment_for_compact_if=16
-org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=80
-org.eclipse.jdt.core.formatter.alignment_for_enum_constants=0
-org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=16
-org.eclipse.jdt.core.formatter.alignment_for_method_declaration=0
-org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16
-org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=80
-org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation=0
-org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_constructor_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_method_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_union_type_in_multicatch=16
-org.eclipse.jdt.core.formatter.blank_lines_after_imports=1
-org.eclipse.jdt.core.formatter.blank_lines_after_package=1
-org.eclipse.jdt.core.formatter.blank_lines_before_field=0
-org.eclipse.jdt.core.formatter.blank_lines_before_first_class_body_declaration=0
-org.eclipse.jdt.core.formatter.blank_lines_before_imports=1
-org.eclipse.jdt.core.formatter.blank_lines_before_member_type=1
-org.eclipse.jdt.core.formatter.blank_lines_before_method=1
-org.eclipse.jdt.core.formatter.blank_lines_before_new_chunk=1
-org.eclipse.jdt.core.formatter.blank_lines_before_package=0
-org.eclipse.jdt.core.formatter.blank_lines_between_import_groups=1
-org.eclipse.jdt.core.formatter.blank_lines_between_type_declarations=1
-org.eclipse.jdt.core.formatter.brace_position_for_annotation_type_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_array_initializer=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_block=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_block_in_case=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_constructor_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_enum_constant=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_enum_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_method_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_switch=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_type_declaration=end_of_line
-org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_block_comment=false
-org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_javadoc_comment=false
-org.eclipse.jdt.core.formatter.comment.format_block_comments=true
-org.eclipse.jdt.core.formatter.comment.format_header=false
-org.eclipse.jdt.core.formatter.comment.format_html=true
-org.eclipse.jdt.core.formatter.comment.format_javadoc_comments=true
-org.eclipse.jdt.core.formatter.comment.format_line_comments=true
-org.eclipse.jdt.core.formatter.comment.format_source_code=true
-org.eclipse.jdt.core.formatter.comment.indent_parameter_description=true
-org.eclipse.jdt.core.formatter.comment.indent_root_tags=true
-org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags=insert
-org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter=insert
-org.eclipse.jdt.core.formatter.comment.line_length=80
-org.eclipse.jdt.core.formatter.comment.new_lines_at_block_boundaries=true
-org.eclipse.jdt.core.formatter.comment.new_lines_at_javadoc_boundaries=true
-org.eclipse.jdt.core.formatter.comment.preserve_white_space_between_code_and_line_comments=false
-org.eclipse.jdt.core.formatter.compact_else_if=true
-org.eclipse.jdt.core.formatter.continuation_indentation=2
-org.eclipse.jdt.core.formatter.continuation_indentation_for_array_initializer=2
-org.eclipse.jdt.core.formatter.disabling_tag=@formatter\:off
-org.eclipse.jdt.core.formatter.enabling_tag=@formatter\:on
-org.eclipse.jdt.core.formatter.format_guardian_clause_on_one_line=false
-org.eclipse.jdt.core.formatter.format_line_comment_starting_on_first_column=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_annotation_declaration_header=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_constant_header=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_declaration_header=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_type_header=true
-org.eclipse.jdt.core.formatter.indent_breaks_compare_to_cases=true
-org.eclipse.jdt.core.formatter.indent_empty_lines=false
-org.eclipse.jdt.core.formatter.indent_statements_compare_to_block=true
-org.eclipse.jdt.core.formatter.indent_statements_compare_to_body=true
-org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_cases=true
-org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_switch=false
-org.eclipse.jdt.core.formatter.indentation.size=4
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_field=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_local_variable=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_method=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_package=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_parameter=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_type=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_label=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_opening_brace_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_at_end_of_file_if_missing=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_finally_in_try_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_while_in_do_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_annotation_declaration=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_anonymous_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_block=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter=insert
-org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_binary_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_paren_in_cast=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_assert=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_case=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_labeled_statement=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_allocation_expression=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_annotation=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_throws=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_constant_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_declarations=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_explicitconstructorcall_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_increments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_inits=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_throws=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_invocation_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_field_declarations=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_local_declarations=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_parameterized_type_reference=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_superinterfaces=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_ellipsis=insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_brace_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_cast=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_catch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_for=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_if=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_parenthesized_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_switch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_synchronized=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_try=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_while=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_try_resources=insert
-org.eclipse.jdt.core.formatter.insert_space_after_unary_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter=insert
-org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_binary_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_brace_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_cast=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_catch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_for=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_if=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_parenthesized_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_switch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_synchronized=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_try=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_while=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_assert=insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_case=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_default=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_labeled_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_throws=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_constant_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_declarations=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_explicitconstructorcall_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_increments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_inits=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_throws=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_invocation_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_field_declarations=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_local_declarations=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_superinterfaces=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_ellipsis=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_annotation_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_anonymous_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_block=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_constructor_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_constant=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_method_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_switch=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation_type_member_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_catch=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_if=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_parenthesized_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_switch=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_synchronized=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_try=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_while=insert
-org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_return=insert
-org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_throw=insert
-org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_semicolon=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_try_resources=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_unary_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_brackets_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_annotation_type_member_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.join_lines_in_comments=true
-org.eclipse.jdt.core.formatter.join_wrapped_lines=false
-org.eclipse.jdt.core.formatter.keep_else_statement_on_same_line=false
-org.eclipse.jdt.core.formatter.keep_empty_array_initializer_on_one_line=false
-org.eclipse.jdt.core.formatter.keep_imple_if_on_one_line=false
-org.eclipse.jdt.core.formatter.keep_then_statement_on_same_line=false
-org.eclipse.jdt.core.formatter.lineSplit=250
-org.eclipse.jdt.core.formatter.never_indent_block_comments_on_first_column=false
-org.eclipse.jdt.core.formatter.never_indent_line_comments_on_first_column=false
-org.eclipse.jdt.core.formatter.number_of_blank_lines_at_beginning_of_method_body=0
-org.eclipse.jdt.core.formatter.number_of_empty_lines_to_preserve=1
-org.eclipse.jdt.core.formatter.put_empty_statement_on_new_line=true
-org.eclipse.jdt.core.formatter.tabulation.char=space
-org.eclipse.jdt.core.formatter.tabulation.size=4
-org.eclipse.jdt.core.formatter.use_on_off_tags=false
-org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false
-org.eclipse.jdt.core.formatter.wrap_before_binary_operator=true
-org.eclipse.jdt.core.formatter.wrap_before_or_operator_multicatch=true
-org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core/.settings/org.eclipse.jdt.ui.prefs b/org.eclipse.tracecompass.lttng2.kernel.core/.settings/org.eclipse.jdt.ui.prefs
deleted file mode 100644 (file)
index 232a3fd..0000000
+++ /dev/null
@@ -1,60 +0,0 @@
-eclipse.preferences.version=1
-editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true
-formatter_profile=_tmf-style
-formatter_settings_version=12
-org.eclipse.jdt.ui.exception.name=e
-org.eclipse.jdt.ui.gettersetter.use.is=true
-org.eclipse.jdt.ui.keywordthis=false
-org.eclipse.jdt.ui.overrideannotation=true
-sp_cleanup.add_default_serial_version_id=true
-sp_cleanup.add_generated_serial_version_id=false
-sp_cleanup.add_missing_annotations=false
-sp_cleanup.add_missing_deprecated_annotations=true
-sp_cleanup.add_missing_methods=false
-sp_cleanup.add_missing_nls_tags=false
-sp_cleanup.add_missing_override_annotations=true
-sp_cleanup.add_missing_override_annotations_interface_methods=true
-sp_cleanup.add_serial_version_id=false
-sp_cleanup.always_use_blocks=true
-sp_cleanup.always_use_parentheses_in_expressions=false
-sp_cleanup.always_use_this_for_non_static_field_access=false
-sp_cleanup.always_use_this_for_non_static_method_access=false
-sp_cleanup.convert_to_enhanced_for_loop=false
-sp_cleanup.correct_indentation=false
-sp_cleanup.format_source_code=false
-sp_cleanup.format_source_code_changes_only=false
-sp_cleanup.make_local_variable_final=false
-sp_cleanup.make_parameters_final=false
-sp_cleanup.make_private_fields_final=true
-sp_cleanup.make_type_abstract_if_missing_method=false
-sp_cleanup.make_variable_declarations_final=false
-sp_cleanup.never_use_blocks=false
-sp_cleanup.never_use_parentheses_in_expressions=true
-sp_cleanup.on_save_use_additional_actions=true
-sp_cleanup.organize_imports=false
-sp_cleanup.qualify_static_field_accesses_with_declaring_class=false
-sp_cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=true
-sp_cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=true
-sp_cleanup.qualify_static_member_accesses_with_declaring_class=false
-sp_cleanup.qualify_static_method_accesses_with_declaring_class=false
-sp_cleanup.remove_private_constructors=true
-sp_cleanup.remove_trailing_whitespaces=true
-sp_cleanup.remove_trailing_whitespaces_all=true
-sp_cleanup.remove_trailing_whitespaces_ignore_empty=false
-sp_cleanup.remove_unnecessary_casts=false
-sp_cleanup.remove_unnecessary_nls_tags=false
-sp_cleanup.remove_unused_imports=false
-sp_cleanup.remove_unused_local_variables=false
-sp_cleanup.remove_unused_private_fields=true
-sp_cleanup.remove_unused_private_members=false
-sp_cleanup.remove_unused_private_methods=true
-sp_cleanup.remove_unused_private_types=true
-sp_cleanup.sort_members=false
-sp_cleanup.sort_members_all=false
-sp_cleanup.use_blocks=true
-sp_cleanup.use_blocks_only_for_return_and_throw=false
-sp_cleanup.use_parentheses_in_expressions=false
-sp_cleanup.use_this_for_non_static_field_access=false
-sp_cleanup.use_this_for_non_static_field_access_only_if_necessary=true
-sp_cleanup.use_this_for_non_static_method_access=false
-sp_cleanup.use_this_for_non_static_method_access_only_if_necessary=true
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core/.settings/org.eclipse.pde.api.tools.prefs b/org.eclipse.tracecompass.lttng2.kernel.core/.settings/org.eclipse.pde.api.tools.prefs
deleted file mode 100644 (file)
index acc3abd..0000000
+++ /dev/null
@@ -1,97 +0,0 @@
-ANNOTATION_ELEMENT_TYPE_ADDED_METHOD_WITHOUT_DEFAULT_VALUE=Error
-ANNOTATION_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-ANNOTATION_ELEMENT_TYPE_REMOVED_FIELD=Error
-ANNOTATION_ELEMENT_TYPE_REMOVED_METHOD=Error
-ANNOTATION_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_API_TYPE=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_API_TYPE=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_TYPE=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_TYPE=Error
-API_USE_SCAN_FIELD_SEVERITY=Error
-API_USE_SCAN_METHOD_SEVERITY=Error
-API_USE_SCAN_TYPE_SEVERITY=Error
-CLASS_ELEMENT_TYPE_ADDED_METHOD=Error
-CLASS_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
-CLASS_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-CLASS_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
-CLASS_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-CLASS_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
-CLASS_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
-CLASS_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-CLASS_ELEMENT_TYPE_REMOVED_CONSTRUCTOR=Error
-CLASS_ELEMENT_TYPE_REMOVED_FIELD=Error
-CLASS_ELEMENT_TYPE_REMOVED_METHOD=Error
-CLASS_ELEMENT_TYPE_REMOVED_SUPERCLASS=Error
-CLASS_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-CLASS_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-CONSTRUCTOR_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-CONSTRUCTOR_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-CONSTRUCTOR_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
-CONSTRUCTOR_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-ENUM_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
-ENUM_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-ENUM_ELEMENT_TYPE_REMOVED_ENUM_CONSTANT=Error
-ENUM_ELEMENT_TYPE_REMOVED_FIELD=Error
-ENUM_ELEMENT_TYPE_REMOVED_METHOD=Error
-ENUM_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-FIELD_ELEMENT_TYPE_ADDED_VALUE=Error
-FIELD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-FIELD_ELEMENT_TYPE_CHANGED_FINAL_TO_NON_FINAL_STATIC_CONSTANT=Error
-FIELD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
-FIELD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
-FIELD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
-FIELD_ELEMENT_TYPE_CHANGED_TYPE=Error
-FIELD_ELEMENT_TYPE_CHANGED_VALUE=Error
-FIELD_ELEMENT_TYPE_REMOVED_TYPE_ARGUMENT=Error
-FIELD_ELEMENT_TYPE_REMOVED_VALUE=Error
-ILLEGAL_EXTEND=Warning
-ILLEGAL_IMPLEMENT=Warning
-ILLEGAL_INSTANTIATE=Warning
-ILLEGAL_OVERRIDE=Warning
-ILLEGAL_REFERENCE=Warning
-INTERFACE_ELEMENT_TYPE_ADDED_FIELD=Error
-INTERFACE_ELEMENT_TYPE_ADDED_METHOD=Error
-INTERFACE_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
-INTERFACE_ELEMENT_TYPE_ADDED_SUPER_INTERFACE_WITH_METHODS=Error
-INTERFACE_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-INTERFACE_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
-INTERFACE_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_FIELD=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_METHOD=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-INVALID_JAVADOC_TAG=Warning
-INVALID_REFERENCE_IN_SYSTEM_LIBRARIES=Warning
-LEAK_EXTEND=Warning
-LEAK_FIELD_DECL=Warning
-LEAK_IMPLEMENT=Warning
-LEAK_METHOD_PARAM=Warning
-LEAK_METHOD_RETURN_TYPE=Warning
-METHOD_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
-METHOD_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-METHOD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-METHOD_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
-METHOD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
-METHOD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
-METHOD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
-METHOD_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
-METHOD_ELEMENT_TYPE_REMOVED_ANNOTATION_DEFAULT_VALUE=Error
-METHOD_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-MISSING_EE_DESCRIPTIONS=Ignore
-TYPE_PARAMETER_ELEMENT_TYPE_ADDED_CLASS_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_ADDED_INTERFACE_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_CLASS_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_INTERFACE_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_CLASS_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_INTERFACE_BOUND=Error
-UNUSED_PROBLEM_FILTERS=Warning
-automatically_removed_unused_problem_filters=false
-eclipse.preferences.version=1
-incompatible_api_component_version=Error
-incompatible_api_component_version_include_major_without_breaking_change=Disabled
-incompatible_api_component_version_include_minor_without_api_change=Disabled
-invalid_since_tag_version=Error
-malformed_since_tag=Error
-missing_since_tag=Error
-report_api_breakage_when_major_version_incremented=Disabled
-report_resolution_errors_api_component=Warning
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core/.settings/org.eclipse.pde.prefs b/org.eclipse.tracecompass.lttng2.kernel.core/.settings/org.eclipse.pde.prefs
deleted file mode 100644 (file)
index d92b94f..0000000
+++ /dev/null
@@ -1,32 +0,0 @@
-compilers.f.unresolved-features=1
-compilers.f.unresolved-plugins=1
-compilers.incompatible-environment=1
-compilers.p.build=1
-compilers.p.build.bin.includes=1
-compilers.p.build.encodings=2
-compilers.p.build.java.compiler=2
-compilers.p.build.java.compliance=1
-compilers.p.build.missing.output=2
-compilers.p.build.output.library=1
-compilers.p.build.source.library=1
-compilers.p.build.src.includes=1
-compilers.p.deprecated=1
-compilers.p.discouraged-class=1
-compilers.p.internal=1
-compilers.p.missing-packages=1
-compilers.p.missing-version-export-package=2
-compilers.p.missing-version-import-package=2
-compilers.p.missing-version-require-bundle=2
-compilers.p.no-required-att=0
-compilers.p.not-externalized-att=1
-compilers.p.unknown-attribute=1
-compilers.p.unknown-class=1
-compilers.p.unknown-element=1
-compilers.p.unknown-identifier=1
-compilers.p.unknown-resource=1
-compilers.p.unresolved-ex-points=0
-compilers.p.unresolved-import=0
-compilers.s.create-docs=false
-compilers.s.doc-folder=doc
-compilers.s.open-tags=1
-eclipse.preferences.version=1
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core/META-INF/MANIFEST.MF b/org.eclipse.tracecompass.lttng2.kernel.core/META-INF/MANIFEST.MF
deleted file mode 100644 (file)
index 1ca10fe..0000000
+++ /dev/null
@@ -1,28 +0,0 @@
-Manifest-Version: 1.0
-Bundle-ManifestVersion: 2
-Bundle-Name: %Bundle-Name
-Bundle-Vendor: %Bundle-Vendor
-Bundle-Version: 1.0.0.qualifier
-Bundle-Localization: plugin
-Bundle-SymbolicName: org.eclipse.tracecompass.lttng2.kernel.core;singleton:=true
-Bundle-Activator: org.eclipse.tracecompass.internal.lttng2.kernel.core.Activator
-Bundle-ActivationPolicy: lazy
-Bundle-RequiredExecutionEnvironment: JavaSE-1.7
-Require-Bundle: org.eclipse.core.runtime,
- org.eclipse.core.resources,
- org.eclipse.tracecompass.common.core,
- org.eclipse.tracecompass.tmf.core,
- org.eclipse.tracecompass.tmf.ctf.core,
- org.eclipse.tracecompass.lttng2.control.core,
- org.eclipse.tracecompass.analysis.os.linux.core
-Export-Package: org.eclipse.tracecompass.internal.lttng2.kernel.core;x-friends:="org.eclipse.tracecompass.lttng2.kernel.ui,org.eclipse.tracecompass.lttng2.kernel.core.tests",
- org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm;x-friends:="org.eclipse.tracecompass.lttng2.kernel.core.tests,org.eclipse.tracecompass.lttng2.kernel.ui",
- org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.model;x-friends:="org.eclipse.tracecompass.lttng2.kernel.core.tests,org.eclipse.tracecompass.lttng2.kernel.ui",
- org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.model.qemukvm;x-friends:="org.eclipse.tracecompass.lttng2.kernel.core.tests,org.eclipse.tracecompass.lttng2.kernel.ui",
- org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.module;x-friends:="org.eclipse.tracecompass.lttng2.kernel.core.tests,org.eclipse.tracecompass.lttng2.kernel.ui",
- org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.trace;x-friends:="org.eclipse.tracecompass.lttng2.kernel.ui,org.eclipse.tracecompass.lttng2.kernel.core.tests",
- org.eclipse.tracecompass.internal.lttng2.kernel.core.event.matching,
- org.eclipse.tracecompass.internal.lttng2.kernel.core.trace.layout;x-friends:="org.eclipse.tracecompass.lttng2.kernel.core.tests,org.eclipse.tracecompass.lttng2.kernel.ui",
- org.eclipse.tracecompass.lttng2.kernel.core.trace
-Import-Package: com.google.common.collect,
- com.google.common.hash;version="15.0.0"
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core/about.html b/org.eclipse.tracecompass.lttng2.kernel.core/about.html
deleted file mode 100644 (file)
index c258ef5..0000000
+++ /dev/null
@@ -1,28 +0,0 @@
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
-    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml">
-<head>
-<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"/>
-<title>About</title>
-</head>
-<body lang="EN-US">
-<h2>About This Content</h2>
-<p>June 5, 2006</p>    
-<h3>License</h3>
-
-<p>The Eclipse Foundation makes available all content in this plug-in (&quot;Content&quot;).  Unless otherwise 
-indicated below, the Content is provided to you under the terms and conditions of the
-Eclipse Public License Version 1.0 (&quot;EPL&quot;).  A copy of the EPL is available 
-at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>.
-For purposes of the EPL, &quot;Program&quot; will mean the Content.</p>
-
-<p>If you did not receive this Content directly from the Eclipse Foundation, the Content is 
-being redistributed by another party (&quot;Redistributor&quot;) and different terms and conditions may
-apply to your use of any object code in the Content.  Check the Redistributor's license that was 
-provided with the Content.  If no such license exists, contact the Redistributor.  Unless otherwise
-indicated below, the terms and conditions of the EPL still apply to any source code in the Content
-and such source code may be obtained at <a href="http://www.eclipse.org/">http://www.eclipse.org</a>.</p>
-
-</body>
-</html>
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core/build.properties b/org.eclipse.tracecompass.lttng2.kernel.core/build.properties
deleted file mode 100644 (file)
index 244c9d8..0000000
+++ /dev/null
@@ -1,22 +0,0 @@
-###############################################################################
-# Copyright (c) 2013, 2014 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:
-#     Ericsson - Initial API and implementation
-###############################################################################
-
-source.. = src/
-output.. = bin/
-bin.includes = META-INF/,\
-               .,\
-               about.html,\
-               plugin.properties,\
-               plugin.xml
-src.includes = about.html
-additional.bundles = org.eclipse.jdt.annotation
-jars.extra.classpath = platform:/plugin/org.eclipse.jdt.annotation
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core/plugin.properties b/org.eclipse.tracecompass.lttng2.kernel.core/plugin.properties
deleted file mode 100644 (file)
index b5bafe2..0000000
+++ /dev/null
@@ -1,20 +0,0 @@
-###############################################################################
-# Copyright (c) 2013, 2014 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:
-#     Ericsson - Initial API and implementation
-###############################################################################
-
-Bundle-Vendor = Eclipse Trace Compass
-Bundle-Name = Trace Compass LTTng Kernel Analysis Core Plug-in
-
-tracetype.type.kernel = Linux Kernel Trace
-analysis.lttngkernel = Linux Kernel Analysis
-
-cpuusage.lttng.kernel = CPU usage
-
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core/plugin.xml b/org.eclipse.tracecompass.lttng2.kernel.core/plugin.xml
deleted file mode 100644 (file)
index 5271045..0000000
+++ /dev/null
@@ -1,33 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<?eclipse version="3.4"?>
-<plugin>
-   <extension
-         point="org.eclipse.linuxtools.tmf.core.tracetype">
-      <type
-            category="org.eclipse.linuxtools.tmf.ctf.core.category.ctf"
-            event_type="org.eclipse.tracecompass.tmf.ctf.core.event.CtfTmfEvent"
-            id="org.eclipse.linuxtools.lttng2.kernel.tracetype"
-            isDirectory="true"
-            name="%tracetype.type.kernel"
-            trace_type="org.eclipse.tracecompass.lttng2.kernel.core.trace.LttngKernelTrace">
-      </type>
-      <experiment
-            experiment_type="org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.trace.VirtualMachineExperiment"
-            id="lttng2.analysis.vm.VirtualMachineExperiment"
-            name="Virtual Machine Experiment">
-      </experiment>
-   </extension>
-   <extension
-         point="org.eclipse.linuxtools.tmf.core.analysis">
-      <module
-            analysis_module="org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.module.VirtualMachineCpuAnalysis"
-            automatic="false"
-            id="lttng2.analysis.vm.core.VirtualMachineAnalysisModule"
-            name="Virtual Machine Analysis">
-            <tracetype
-                  applies="true"
-                  class="org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.trace.VirtualMachineExperiment">
-            </tracetype>
-      </module>
-   </extension>
-</plugin>
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core/pom.xml b/org.eclipse.tracecompass.lttng2.kernel.core/pom.xml
deleted file mode 100644 (file)
index 7442201..0000000
+++ /dev/null
@@ -1,36 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-   Copyright (C) 2011, Red Hat, Inc.
-
-   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
--->
-<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>
-    <artifactId>org.eclipse.tracecompass</artifactId>
-    <groupId>org.eclipse.tracecompass</groupId>
-    <version>1.0.0-SNAPSHOT</version>
-  </parent>
-
-  <artifactId>org.eclipse.tracecompass.lttng2.kernel.core</artifactId>
-  <version>1.0.0-SNAPSHOT</version>
-  <packaging>eclipse-plugin</packaging>
-
-  <name>Trace Compass LTTng Kernel Analysis Core Plug-in</name>
-
- <build>
-    <plugins>
-      <plugin>
-        <groupId>org.eclipse.tycho</groupId>
-        <artifactId>tycho-source-plugin</artifactId>
-      </plugin>
-    </plugins>
-  </build>
-
- <groupId>org.eclipse.tracecompass</groupId>
-</project>
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/Activator.java b/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/Activator.java
deleted file mode 100644 (file)
index e7f7765..0000000
+++ /dev/null
@@ -1,142 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2012, 2015 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:
- *   Francois Chouinard - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.kernel.core;
-
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Plugin;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.tracecompass.internal.lttng2.kernel.core.event.matching.TcpEventMatching;
-import org.eclipse.tracecompass.internal.lttng2.kernel.core.event.matching.TcpLttngEventMatching;
-import org.eclipse.tracecompass.tmf.core.event.matching.TmfEventMatching;
-import org.osgi.framework.BundleContext;
-
-/**
- * <b><u>Activator</u></b>
- * <p>
- * The activator class controls the plug-in life cycle
- */
-public class Activator extends Plugin {
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-
-    /**
-     * The plug-in ID
-     */
-    public static final String PLUGIN_ID = "org.eclipse.tracecompass.lttng2.kernel.core"; //$NON-NLS-1$
-
-    /**
-     * The shared instance
-     */
-    private static Activator plugin;
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-
-    /**
-     * The constructor
-     */
-    public Activator() {
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    /**
-     * Returns the shared instance
-     *
-     * @return the shared instance
-     */
-    public static Activator getDefault() {
-        return plugin;
-    }
-
-    // ------------------------------------------------------------------------
-    // Operators
-    // ------------------------------------------------------------------------
-
-    @Override
-    public void start(BundleContext context) throws Exception {
-        super.start(context);
-        plugin = this;
-        TmfEventMatching.registerMatchObject(new TcpEventMatching());
-        TmfEventMatching.registerMatchObject(new TcpLttngEventMatching());
-    }
-
-    @Override
-    public void stop(BundleContext context) throws Exception {
-        plugin = null;
-        super.stop(context);
-    }
-
-    /**
-     * Logs a message with severity INFO in the runtime log of the plug-in.
-     *
-     * @param message A message to log
-     */
-    public void logInfo(String message) {
-        getLog().log(new Status(IStatus.INFO, PLUGIN_ID, message));
-    }
-
-    /**
-     * Logs a message and exception with severity INFO in the runtime log of the plug-in.
-     *
-     * @param message A message to log
-     * @param exception A exception to log
-     */
-    public void logInfo(String message, Throwable exception) {
-        getLog().log(new Status(IStatus.INFO, PLUGIN_ID, message, exception));
-    }
-
-    /**
-     * Logs a message and exception with severity WARNING in the runtime log of the plug-in.
-     *
-     * @param message A message to log
-     */
-    public void logWarning(String message) {
-        getLog().log(new Status(IStatus.WARNING, PLUGIN_ID, message));
-    }
-
-    /**
-     * Logs a message and exception with severity WARNING in the runtime log of the plug-in.
-     *
-     * @param message A message to log
-     * @param exception A exception to log
-     */
-    public void logWarning(String message, Throwable exception) {
-        getLog().log(new Status(IStatus.WARNING, PLUGIN_ID, message, exception));
-    }
-
-    /**
-     * Logs a message and exception with severity ERROR in the runtime log of the plug-in.
-     *
-     * @param message A message to log
-     */
-    public void logError(String message) {
-        getLog().log(new Status(IStatus.ERROR, PLUGIN_ID, message));
-    }
-
-    /**
-     * Logs a message and exception with severity ERROR in the runtime log of the plug-in.
-     *
-     * @param message A message to log
-     * @param exception A exception to log
-     */
-    public void logError(String message, Throwable exception) {
-        getLog().log(new Status(IStatus.ERROR, PLUGIN_ID, message, exception));
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/TcpEventStrings.java b/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/TcpEventStrings.java
deleted file mode 100644 (file)
index dd9fd3c..0000000
+++ /dev/null
@@ -1,60 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2013, 2014 École Polytechnique de Montréal
- *
- * 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:
- *   Geneviève Bastien - Initial API and implementation
- ******************************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.kernel.core;
-
-/**
- * This file defines all the known event and field names used to trace socket
- * connection for both the addons module method (
- * {@link org.eclipse.tracecompass.internal.lttng2.kernel.core.event.matching.TcpEventMatching}
- * ) and the net_data_experimental branch (
- * {@link org.eclipse.tracecompass.internal.lttng2.kernel.core.event.matching.TcpLttngEventMatching}
- * ).
- *
- * These events should be eventually mainlined and when this happens, this class
- * won't be necessary anymore and they should be moved to {@link LttngStrings}
- * class
- *
- *
- * @author Geneviève Bastien
- */
-@SuppressWarnings({ "javadoc", "nls" })
-public interface TcpEventStrings {
-
-    /* Event names */
-    public static final String INET_CONNECT = "inet_connect";
-    public static final String INET_SOCK_CREATE = "inet_sock_create";
-    public static final String INET_SOCK_LOCAL_OUT = "inet_sock_local_out";
-    public static final String INET_SOCK_LOCAL_IN = "inet_sock_local_in";
-    public static final String INET_SOCK_CLONE = "inet_sock_clone";
-    public static final String INET_ACCEPT = "inet_accept";
-    public static final String INET_SOCK_DELETE = "inet_sock_delete";
-    public static final String NETIF_RECEIVE_SKB = "netif_receive_skb";
-    public static final String NET_DEV_QUEUE = "net_dev_queue";
-
-    /* Field names */
-    public static final String SEQ = "seq";
-    public static final String SK = "sk";
-    public static final String OSK = "osk";
-    public static final String NSK = "nsk";
-    public static final String SPORT = "sport";
-    public static final String DPORT = "dport";
-    public static final String SADDR = "saddr";
-    public static final String DADDR = "daddr";
-    public static final String ACKSEQ = "ack_seq";
-    public static final String CHECK = "check";
-    public static final String WINDOW = "window";
-    public static final String FLAGS = "flags";
-    public static final String TRANSPORT_FIELDS = "transport_fields";
-    public static final String TYPE_TCP = "thtype_tcp";
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/VcpuStateValues.java b/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/VcpuStateValues.java
deleted file mode 100644 (file)
index 445b3b7..0000000
+++ /dev/null
@@ -1,35 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2014 École Polytechnique de Montréal
- *
- * 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:
- *   Mohamad Gebai - Initial API and implementation
- *   Geneviève Bastien - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm;
-
-/**
- * State system values used by the VM analysis
- *
- * @author Mohamad Gebai
- */
-public interface VcpuStateValues {
-
-    /* VCPU Status */
-    /** The virtual CPU state is unknown */
-    int VCPU_UNKNOWN = 0;
-    /** The virtual CPU is idle */
-    int VCPU_IDLE = 1;
-    /** The virtual CPU is running */
-    int VCPU_RUNNING = 2;
-    /** Flag for when the virtual CPU is in hypervisor mode */
-    int VCPU_VMM = 128;
-    /** Flag for when the virtual CPU is preempted */
-    int VCPU_PREEMPT = 256;
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/VmAttributes.java b/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/VmAttributes.java
deleted file mode 100644 (file)
index 6e18a0b..0000000
+++ /dev/null
@@ -1,30 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2014 École Polytechnique de Montréal
- *
- * 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:
- *   Mohamad Gebai - Initial API and implementation
- *   Geneviève Bastien - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm;
-
-/**
- * Attributes used by the VM Analysis
- *
- * @author Mohamad Gebai
- */
-@SuppressWarnings({"nls"})
-public interface VmAttributes {
-
-    /** First-level attributes */
-    String VIRTUAL_MACHINES = "Virtual Machines";
-
-    /** Sub-attributes for virtual CPUs */
-    String STATUS = "Status";
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/model/IVirtualMachineModel.java b/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/model/IVirtualMachineModel.java
deleted file mode 100644 (file)
index 4b226c5..0000000
+++ /dev/null
@@ -1,119 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2014 École Polytechnique de Montréal
- *
- * 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:
- *   Geneviève Bastien - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.model;
-
-import java.util.Set;
-
-import org.eclipse.jdt.annotation.Nullable;
-import org.eclipse.tracecompass.analysis.os.linux.core.model.HostThread;
-import org.eclipse.tracecompass.tmf.core.event.ITmfEvent;
-
-/**
- * Interface that represents the model of an hypervisor. Each hypervisor (or
- * tracing method for an hypervisor) should implement this.
- *
- * @author Geneviève Bastien
- */
-public interface IVirtualMachineModel {
-
-    /**
-     * Get the machine that ran this event
-     *
-     * @param event
-     *            The trace event
-     * @return The machine this event was run on or {@code null} if the machine
-     *         is not one belonging to this model.
-     */
-    @Nullable
-    VirtualMachine getCurrentMachine(ITmfEvent event);
-
-    /**
-     * Get a the set of events required for this model to apply.
-     *
-     * TODO: This should be updated to something else to fit the event layout
-     * generic linux model
-     *
-     * @return The set of required events for this model
-     */
-    Set<String> getRequiredEvents();
-
-    /**
-     * Get the virtual CPU that is entering hypervisor mode with this event.
-     *
-     * "Hypervisor mode" means the virtual CPU of the guest is running on the
-     * host, but it is not running code from the guest, but rather other tasks
-     * from the hypervisor. When hypervisor mode is entered, the process on the
-     * host stops running guest code, so from the guest point of view, the
-     * thread running on this CPU is preempted.
-     *
-     * @param event
-     *            The event being handled
-     * @param ht
-     *            The current thread this event belongs to
-     * @return The virtual CPU entering hypervisor mode or {@code null} if the
-     *         hypervisor is not being entered with this event.
-     */
-    @Nullable
-    VirtualCPU getVCpuEnteringHypervisorMode(ITmfEvent event, HostThread ht);
-
-    /**
-     * Get the virtual CPU that is exiting hypervisor mode with this event.
-     *
-     * "Hypervisor mode" means the virtual CPU of the guest is running on the
-     * host, but it is not running code from the guest, but rather other tasks
-     * from the hypervisor. When hypervisor mode is exited, the process on the
-     * host runs guest code, so from the guest point of view, the thread running
-     * on this CPU is actively running.
-     *
-     * @param event
-     *            The event being handled
-     * @param ht
-     *            The current thread this event belongs to
-     * @return The virutal CPU exiting hypervisor mode or {@code null} if the
-     *         hypervisor is not exiting with this event.
-     */
-    @Nullable
-    VirtualCPU getVCpuExitingHypervisorMode(ITmfEvent event, HostThread ht);
-
-    /**
-     * Get the virtual CPU from a guest that corresponds to a specific thread
-     * from the host
-     *
-     * @param event
-     *            The event being handled
-     * @param ht
-     *            The current thread this event belongs to. This thread should
-     *            be running on the host.
-     * @return The virtual CPU corresponding to this thread or {@code null} if
-     *         no virtual CPU corresponds to the thread
-     */
-    @Nullable
-    VirtualCPU getVirtualCpu(HostThread ht);
-
-    /**
-     * Handles the event. This method will be called for each event required or
-     * optional by the analysis, before any other handling is done on this
-     * event.
-     *
-     * This is where each implementation of the model will build itself,
-     * determine which guests are running on which hosts and get the necessary
-     * information to be able to return the virtual CPUs requested by the other
-     * methods of this interface.
-     *
-     * @param event
-     *            The event being handled. It can come from any trace in the
-     *            experiment
-     */
-    void handleEvent(ITmfEvent event);
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/model/VirtualCPU.java b/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/model/VirtualCPU.java
deleted file mode 100644 (file)
index bb5f974..0000000
+++ /dev/null
@@ -1,79 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2014 École Polytechnique de Montréal
- *
- * 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:
- *   Geneviève Bastien - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.model;
-
-import org.eclipse.tracecompass.common.core.NonNullUtils;
-
-import com.google.common.collect.HashBasedTable;
-import com.google.common.collect.Table;
-
-/**
- * This class represents a virtual CPU, which is a CPU running on a guest. It
- * associates the guest CPU ID to a virtual machine of the model.
- *
- * @author Geneviève Bastien
- */
-public class VirtualCPU {
-
-    private static final Table<VirtualMachine, Long, VirtualCPU> VIRTUAL_CPU_TABLE = NonNullUtils.checkNotNull(HashBasedTable.<VirtualMachine, Long, VirtualCPU> create());
-
-    private final VirtualMachine fVm;
-    private final Long fCpuId;
-
-    /**
-     * Return the virtual CPU for to the virtual machine and requested CPU ID
-     *
-     * @param vm
-     *            The virtual machine
-     * @param cpu
-     *            the CPU number
-     * @return the virtual CPU
-     */
-    public static synchronized VirtualCPU getVirtualCPU(VirtualMachine vm, Long cpu) {
-        VirtualCPU ht = VIRTUAL_CPU_TABLE.get(vm, cpu);
-        if (ht == null) {
-            ht = new VirtualCPU(vm, cpu);
-            VIRTUAL_CPU_TABLE.put(vm, cpu, ht);
-        }
-        return ht;
-    }
-
-    private VirtualCPU(VirtualMachine vm, Long cpu) {
-        fVm = vm;
-        fCpuId = cpu;
-    }
-
-    /**
-     * Get the CPU ID of this virtual CPU
-     *
-     * @return The zero-based CPU ID
-     */
-    public Long getCpuId() {
-        return fCpuId;
-    }
-
-    /**
-     * Get the virtual machine object this virtual CPU belongs to
-     *
-     * @return The guest Virtual Machine
-     */
-    public VirtualMachine getVm() {
-        return fVm;
-    }
-
-    @Override
-    public String toString() {
-        return "VirtualCPU: [" + fVm + ',' + fCpuId + ']'; //$NON-NLS-1$
-    }
-
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/model/VirtualMachine.java b/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/model/VirtualMachine.java
deleted file mode 100644 (file)
index bf5d54e..0000000
+++ /dev/null
@@ -1,99 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2014 École Polytechnique de Montréal
- *
- * 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:
- *   Geneviève Bastien - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.model;
-
-/**
- * This class represents a machine, host or guest, in a virtual machine model. A
- * machine is identified by a trace's host ID.
- *
- * @author Geneviève Bastien
- */
-public class VirtualMachine {
-
-    private static enum MachineType {
-        HOST,
-        GUEST
-    }
-
-    private final long fVmUid;
-    private final String fHostId;
-    private final MachineType fType;
-
-    /**
-     * Create a new host machine. A host is a physical machine that may contain
-     * virtual guest machines.
-     *
-     * @param hostId
-     *            The host ID of the trace(s) this machine represents
-     * @return A {@link VirtualMachine} of type host
-     */
-    public static VirtualMachine newHostMachine(String hostId) {
-        return new VirtualMachine(MachineType.HOST, hostId, -1);
-    }
-
-    /**
-     * Create a new guest machine. A guest is a virtual machine with virtual
-     * CPUs running on a host.
-     *
-     * @param uid
-     *            Some unique identifier of this guest machine that can be used
-     *            in both the guest and the host to match both machines.
-     * @param hostId
-     *            The host ID of the trace(s) this machine represents
-     * @return A {@link VirtualMachine} of type guest.
-     */
-    public static VirtualMachine newGuestMachine(long uid, String hostId) {
-        return new VirtualMachine(MachineType.GUEST, hostId, uid);
-    }
-
-    private VirtualMachine(MachineType type, String hostId, long uid) {
-        fType = type;
-        fVmUid = uid;
-        fHostId = hostId;
-    }
-
-    /**
-     * Return whether this machine is a guest or a host
-     *
-     * @return {@code true} if the machine is a guest, or {@code false} if it is
-     *         a host
-     */
-    public boolean isGuest() {
-        return fType == MachineType.GUEST;
-    }
-
-    /**
-     * Get the unique identifier that is used between the host and the guest to
-     * identify this machine.
-     *
-     * @return The Virtual Machine unique ID.
-     */
-    public long getVmUid() {
-        return fVmUid;
-    }
-
-    /**
-     * Get the host ID of this machine
-     *
-     * @return The host ID of this machine
-     */
-    public String getHostId() {
-        return fHostId;
-    }
-
-    @Override
-    public String toString() {
-        return "VirtualMachine: " + fHostId; //$NON-NLS-1$
-    }
-
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/model/package-info.java b/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/model/package-info.java
deleted file mode 100644 (file)
index b30f2be..0000000
+++ /dev/null
@@ -1,14 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2014 École Polytechnique de Montréal
- *
- * 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:
- *    École Polytechnique de Montréal - Initial API and implementation
- *******************************************************************************/
-
-@org.eclipse.jdt.annotation.NonNullByDefault
-package org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.model;
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/model/qemukvm/QemuKvmStrings.java b/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/model/qemukvm/QemuKvmStrings.java
deleted file mode 100644 (file)
index e7adb1d..0000000
+++ /dev/null
@@ -1,75 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2014 École Polytechnique de Montréal
- *
- * 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:
- *   Mohamad Gebai - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.model.qemukvm;
-
-/**
- * Lttng specific strings for the events used by the Qemu/KVM virtual machine
- * model
- *
- * TODO: The whole model should be updated to use the linux event layout. These
- * event names are LTTng-specific
- *
- * @author Mohamad Gebai
- */
-@SuppressWarnings({ "nls" })
-public interface QemuKvmStrings {
-
-    /* vmsync events */
-
-    /**
-     * Event produced by the host, for a message sent from the guest, received
-     * by the host
-     */
-    String VMSYNC_GH_HOST = "vmsync_gh_host";
-    /**
-     * Event produced by the host, for a message sent from the host, received by
-     * the guest
-     */
-    String VMSYNC_HG_HOST = "vmsync_hg_host";
-    /**
-     * Event produced by the guest, for a message sent from the guest, received
-     * by the host
-     */
-    String VMSYNC_GH_GUEST = "vmsync_gh_guest";
-    /**
-     * Event produced by the guest, for a message sent from the host, received
-     * by the guest
-     */
-    String VMSYNC_HG_GUEST = "vmsync_hg_guest";
-    /**
-     * Event field of previous events, containing a message counter, updated at
-     * each message
-     */
-    String COUNTER_PAYLOAD = "cnt";
-    /**
-     * Event field of previous events, with a unique UID to identify a single
-     * guest on a host
-     */
-    String VM_UID_PAYLOAD = "vm_uid";
-
-    /* kvm entry/exit events */
-    /**
-     * KVM kernel event indicating that virtual machine code is being run
-     */
-    String KVM_ENTRY = "kvm_entry";
-    /**
-     * KVM kernel event indicating that virtual machine code is not run anymore,
-     * but rather hypervisor-specific code
-     */
-    String KVM_EXIT = "kvm_exit";
-    /**
-     * Field from kvm_entry event indicating which virtual CPU is being run
-     */
-    String VCPU_ID = "vcpu_id";
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/model/qemukvm/QemuKvmVmModel.java b/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/model/qemukvm/QemuKvmVmModel.java
deleted file mode 100644 (file)
index c39cd65..0000000
+++ /dev/null
@@ -1,263 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2014, 2015 École Polytechnique de Montréal
- *
- * 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:
- *   Mohamad Gebai - Initial API and implementation
- *   Geneviève Bastien - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.model.qemukvm;
-
-import java.util.HashMap;
-import java.util.Map;
-import java.util.Map.Entry;
-import java.util.Set;
-
-import org.eclipse.jdt.annotation.Nullable;
-import org.eclipse.tracecompass.analysis.os.linux.core.kernelanalysis.KernelAnalysisModule;
-import org.eclipse.tracecompass.analysis.os.linux.core.kernelanalysis.KernelThreadInformationProvider;
-import org.eclipse.tracecompass.analysis.os.linux.core.model.HostThread;
-import org.eclipse.tracecompass.common.core.NonNullUtils;
-import org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.model.IVirtualMachineModel;
-import org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.model.VirtualCPU;
-import org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.model.VirtualMachine;
-import org.eclipse.tracecompass.tmf.core.event.ITmfEvent;
-import org.eclipse.tracecompass.tmf.core.event.ITmfEventField;
-import org.eclipse.tracecompass.tmf.core.event.TmfEventField;
-import org.eclipse.tracecompass.tmf.core.event.aspect.TmfCpuAspect;
-import org.eclipse.tracecompass.tmf.core.trace.TmfTraceUtils;
-import org.eclipse.tracecompass.tmf.core.trace.experiment.TmfExperiment;
-import org.eclipse.tracecompass.tmf.core.trace.experiment.TmfExperimentUtils;
-
-import com.google.common.collect.ImmutableSet;
-
-/**
- * The virtual machine model corresponding to the Qemu/KVM hypervisor. It uses
- * the kvm_exit/kvm_entry events to identify entry to and exit from the
- * hypervisor. It also requires vmsync_* events from both guests and hosts to
- * identify which thread from a host belongs to which machine.
- *
- * @author Mohamad Gebai
- */
-public class QemuKvmVmModel implements IVirtualMachineModel {
-
-    private static final String KVM = "kvm_"; //$NON-NLS-1$
-
-    /* Associate a host's thread to a virtual CPU */
-    private final Map<HostThread, VirtualCPU> fTidToVcpu = new HashMap<>();
-    /* Associate a host's thread to a virtual machine */
-    private final Map<HostThread, VirtualMachine> fTidToVm = new HashMap<>();
-    /* Maps a virtual machine name to a virtual machine */
-    private final Map<String, VirtualMachine> fKnownMachines = new HashMap<>();
-
-    private final TmfExperiment fExperiment;
-
-    static final ImmutableSet<String> REQUIRED_EVENTS = NonNullUtils.checkNotNull(ImmutableSet.of(
-            QemuKvmStrings.KVM_ENTRY,
-            QemuKvmStrings.KVM_EXIT,
-            QemuKvmStrings.VMSYNC_GH_GUEST,
-            QemuKvmStrings.VMSYNC_GH_HOST,
-            QemuKvmStrings.VMSYNC_HG_GUEST,
-            QemuKvmStrings.VMSYNC_HG_HOST
-            ));
-
-    /**
-     * Constructor
-     *
-     * @param exp
-     *            The experiment this model applies to
-     */
-    public QemuKvmVmModel(TmfExperiment exp) {
-        fExperiment = exp;
-    }
-
-    @Override
-    public @Nullable VirtualMachine getCurrentMachine(ITmfEvent event) {
-        final String hostId = event.getTrace().getHostId();
-        VirtualMachine machine = fKnownMachines.get(hostId);
-        if (machine != null) {
-            return machine;
-        }
-
-        /*
-         * TODO: This model wouldn't support a machine (same hostId) being both
-         * a guest and a host
-         */
-
-        /*
-         * This code path would be used only at the beginning of the analysis.
-         * Once all the hostIds have been associated with a virtual machine, the
-         * machines are all cached and the method returns earlier
-         */
-        /* Try to get the virtual machine from the event */
-        String eventName = event.getName();
-        if (eventName.startsWith(KVM)) {
-            /* Only the host machine has kvm_* events, so this is a host */
-            machine = VirtualMachine.newHostMachine(hostId);
-        } else if (eventName.equals(QemuKvmStrings.VMSYNC_GH_GUEST) || eventName.equals(QemuKvmStrings.VMSYNC_HG_GUEST)) {
-            /* Those events are only present in the guests */
-            TmfEventField field = (TmfEventField) event.getContent();
-            ITmfEventField data = field.getField(QemuKvmStrings.VM_UID_PAYLOAD);
-            if (data != null) {
-                machine = VirtualMachine.newGuestMachine((Long) data.getValue(), hostId);
-            }
-        }
-        if (machine != null) {
-            /* Associate the machine to the hostID here, for cached access later */
-            fKnownMachines.put(hostId, machine);
-        }
-        return machine;
-    }
-
-    @Override
-    public Set<String> getRequiredEvents() {
-        return REQUIRED_EVENTS;
-    }
-
-    private @Nullable VirtualMachine findVmFromParent(ITmfEvent event, HostThread ht) {
-        /*
-         * Maybe the parent of the current thread has a VM associated, see if we
-         * can infer the VM for this thread
-         */
-        KernelAnalysisModule module = getLttngKernelModuleFor(ht.getHost());
-        if (module == null) {
-            return null;
-        }
-
-        Integer ppid = KernelThreadInformationProvider.getParentPid(module, ht.getTid(), event.getTimestamp().getValue());
-        if (ppid == null) {
-            return null;
-        }
-
-        HostThread parentHt = new HostThread(ht.getHost(), ppid);
-        VirtualMachine vm = fTidToVm.get(parentHt);
-        if (vm == null) {
-            return null;
-        }
-        fTidToVm.put(ht, vm);
-
-        return vm;
-    }
-
-    @Override
-    public @Nullable VirtualCPU getVCpuExitingHypervisorMode(ITmfEvent event, HostThread ht) {
-        final String eventName = event.getName();
-
-        /* TODO: Use event layouts for this part also */
-        /*
-         * The KVM_ENTRY event means we are entering a virtual CPU, so exiting
-         * hypervisor mode
-         */
-        if (!eventName.equals(QemuKvmStrings.KVM_ENTRY)) {
-            return null;
-        }
-
-        /*
-         * Are we entering the hypervisor and if so, which virtual CPU is
-         * concerned?
-         */
-        VirtualMachine vm = fTidToVm.get(ht);
-        if (vm == null) {
-            vm = findVmFromParent(event, ht);
-            if (vm == null) {
-                return null;
-            }
-        }
-        /* Associate this thread with the virtual CPU that is going to be run */
-        final ITmfEventField content = event.getContent();
-        long vcpu_id = (Long) content.getField(QemuKvmStrings.VCPU_ID).getValue();
-
-        VirtualCPU virtualCPU = VirtualCPU.getVirtualCPU(vm, vcpu_id);
-        fTidToVcpu.put(ht, virtualCPU);
-
-        return virtualCPU;
-    }
-
-    @Override
-    public @Nullable VirtualCPU getVCpuEnteringHypervisorMode(ITmfEvent event, HostThread ht) {
-        final String eventName = event.getName();
-        /*
-         * The KVM_EXIT event means we are exiting a virtual CPU, so entering
-         * hypervisor mode
-         */
-        if (!eventName.equals(QemuKvmStrings.KVM_EXIT)) {
-            return null;
-        }
-
-        return getVirtualCpu(ht);
-    }
-
-    @Override
-    public @Nullable VirtualCPU getVirtualCpu(HostThread ht) {
-        return fTidToVcpu.get(ht);
-    }
-
-    @Override
-    public void handleEvent(ITmfEvent event) {
-        /* Is the event handled by this model */
-        final String eventName = event.getName();
-        if (!eventName.equals(QemuKvmStrings.VMSYNC_GH_HOST)) {
-            return;
-        }
-
-        final ITmfEventField content = event.getContent();
-        final long ts = event.getTimestamp().getValue();
-        final String hostId = event.getTrace().getHostId();
-
-        Object cpuObj = TmfTraceUtils.resolveEventAspectOfClassForEvent(event.getTrace(), TmfCpuAspect.class, event);
-        if (cpuObj == null) {
-            /* We couldn't find any CPU information, ignore this event */
-            return;
-        }
-        Integer cpu = (Integer) cpuObj;
-
-        /* Find a virtual machine with the vm uid payload value */
-        ITmfEventField data = content.getField(QemuKvmStrings.VM_UID_PAYLOAD);
-        if (data == null) {
-            return;
-        }
-        long vmUid = (Long) data.getValue();
-        for (Entry<String, VirtualMachine> entry : fKnownMachines.entrySet()) {
-            if (entry.getValue().getVmUid() == vmUid) {
-                /*
-                 * We found the VM being run, let's associate it with the thread
-                 * ID
-                 */
-                KernelAnalysisModule module = getLttngKernelModuleFor(hostId);
-                if (module == null) {
-                    break;
-                }
-                Integer tid = KernelThreadInformationProvider.getThreadOnCpu(module, cpu, ts);
-                if (tid == null) {
-                    /*
-                     * We do not know which process is running at this point. It
-                     * may happen at the beginning of the trace.
-                     */
-                    break;
-                }
-                HostThread ht = new HostThread(hostId, tid);
-                fTidToVm.put(ht, entry.getValue());
-
-                /*
-                 * To make sure siblings are also associated with this VM, also
-                 * add an entry for the parent TID
-                 */
-                Integer ppid = KernelThreadInformationProvider.getParentPid(module, tid, ts);
-                if (ppid != null) {
-                    HostThread parentHt = new HostThread(hostId, ppid);
-                    fTidToVm.put(parentHt, entry.getValue());
-                }
-            }
-        }
-    }
-
-    private @Nullable KernelAnalysisModule getLttngKernelModuleFor(String hostId) {
-        return TmfExperimentUtils.getAnalysisModuleOfClassForHost(fExperiment, hostId, KernelAnalysisModule.class);
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/model/qemukvm/package-info.java b/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/model/qemukvm/package-info.java
deleted file mode 100644 (file)
index 7f6debb..0000000
+++ /dev/null
@@ -1,14 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2014 École Polytechnique de Montréal
- *
- * 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:
- *    École Polytechnique de Montréal - Initial API and implementation
- *******************************************************************************/
-
-@org.eclipse.jdt.annotation.NonNullByDefault
-package org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.model.qemukvm;
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/module/Messages.java b/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/module/Messages.java
deleted file mode 100644 (file)
index b68f7b5..0000000
+++ /dev/null
@@ -1,46 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2014 École Polytechnique de Montréal
- *
- * 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:
- *   Geneviève Bastien - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.module;
-
-import org.eclipse.jdt.annotation.Nullable;
-import org.eclipse.osgi.util.NLS;
-
-/**
- * Externalized message strings from the LTTng Kernel Analysis
- *
- * @author Geneviève Bastien
- */
-@SuppressWarnings("javadoc")
-public class Messages extends NLS {
-    private static final String BUNDLE_NAME = "org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.module.messages"; //$NON-NLS-1$
-
-    public static @Nullable String VirtualMachineCPUAnalysis_Help;
-
-    static {
-        // initialize resource bundle
-        NLS.initializeMessages(BUNDLE_NAME, Messages.class);
-    }
-
-    private Messages() {
-    }
-
-    /**
-     * Helper method to expose externalized strings as non-null objects.
-     */
-    public static String getMessage(@Nullable String msg) {
-        if (msg == null) {
-            return ""; //$NON-NLS-1$
-        }
-        return msg;
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/module/VirtualMachineCpuAnalysis.java b/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/module/VirtualMachineCpuAnalysis.java
deleted file mode 100644 (file)
index 6cc1155..0000000
+++ /dev/null
@@ -1,246 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2014, 2015 École Polytechnique de Montréal
- *
- * 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:
- *   Mohamad Gebai - Initial API and implementation
- *   Geneviève Bastien - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.module;
-
-import static org.eclipse.tracecompass.common.core.NonNullUtils.checkNotNull;
-
-import java.util.Comparator;
-import java.util.HashSet;
-import java.util.Set;
-
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.jdt.annotation.NonNull;
-import org.eclipse.jdt.annotation.Nullable;
-import org.eclipse.tracecompass.analysis.os.linux.core.kernelanalysis.KernelAnalysisModule;
-import org.eclipse.tracecompass.analysis.os.linux.core.kernelanalysis.KernelThreadInformationProvider;
-import org.eclipse.tracecompass.common.core.NonNullUtils;
-import org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.VcpuStateValues;
-import org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.VmAttributes;
-import org.eclipse.tracecompass.statesystem.core.ITmfStateSystem;
-import org.eclipse.tracecompass.statesystem.core.StateSystemUtils;
-import org.eclipse.tracecompass.statesystem.core.exceptions.AttributeNotFoundException;
-import org.eclipse.tracecompass.statesystem.core.exceptions.StateSystemDisposedException;
-import org.eclipse.tracecompass.statesystem.core.interval.ITmfStateInterval;
-import org.eclipse.tracecompass.statesystem.core.interval.TmfStateInterval;
-import org.eclipse.tracecompass.statesystem.core.statevalue.ITmfStateValue;
-import org.eclipse.tracecompass.statesystem.core.statevalue.TmfStateValue;
-import org.eclipse.tracecompass.tmf.core.analysis.IAnalysisModule;
-import org.eclipse.tracecompass.tmf.core.statesystem.ITmfStateProvider;
-import org.eclipse.tracecompass.tmf.core.statesystem.TmfStateSystemAnalysisModule;
-import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace;
-import org.eclipse.tracecompass.tmf.core.trace.TmfTraceManager;
-import org.eclipse.tracecompass.tmf.core.trace.TmfTraceUtils;
-import org.eclipse.tracecompass.tmf.core.trace.experiment.TmfExperiment;
-import org.eclipse.tracecompass.tmf.core.trace.experiment.TmfExperimentUtils;
-
-import com.google.common.collect.ImmutableSet;
-import com.google.common.collect.Multimap;
-import com.google.common.collect.TreeMultimap;
-
-/**
- * Module for the virtual machine CPU analysis. It tracks the status of the
- * virtual CPUs for each guest of the experiment.
- *
- * @author Mohamad Gebai
- * @author Geneviève Bastien
- */
-public class VirtualMachineCpuAnalysis extends TmfStateSystemAnalysisModule {
-
-    // TODO: Update with event layout when requirements are back */
-    static final Set<String> REQUIRED_EVENTS = NonNullUtils.checkNotNull(ImmutableSet.<String> of(
-            // LttngStrings.SCHED_SWITCH
-            ));
-
-    /* State value for a preempted virtual CPU */
-    private static final ITmfStateValue VCPU_PREEMPT_VALUE = TmfStateValue.newValueInt(VcpuStateValues.VCPU_PREEMPT);
-
-    /**
-     * Constructor
-     */
-    public VirtualMachineCpuAnalysis() {
-        super();
-    }
-
-    @Override
-    protected ITmfStateProvider createStateProvider() {
-        ITmfTrace trace = getTrace();
-        if (!(trace instanceof TmfExperiment)) {
-            throw new IllegalStateException();
-        }
-        return new VirtualMachineStateProvider((TmfExperiment) trace);
-    }
-
-    @Override
-    protected @NonNull StateSystemBackendType getBackendType() {
-        return StateSystemBackendType.FULL;
-    }
-
-    @Override
-    public String getHelpText() {
-        return Messages.getMessage(Messages.VirtualMachineCPUAnalysis_Help);
-    }
-
-    @Override
-    protected Iterable<IAnalysisModule> getDependentAnalyses() {
-        Set<IAnalysisModule> modules = new HashSet<>();
-        /* Depends on the LTTng Kernel analysis modules */
-        for (ITmfTrace trace : TmfTraceManager.getTraceSet(getTrace())) {
-            trace = checkNotNull(trace);
-            for (KernelAnalysisModule module : TmfTraceUtils.getAnalysisModulesOfClass(trace, KernelAnalysisModule.class)) {
-                modules.add(module);
-            }
-        }
-        return modules;
-    }
-
-    private static Multimap<Integer, ITmfStateInterval> createThreadMultimap() {
-
-        /*
-         * Create the multimap for threads with the appropriate comparator
-         * objects for keys and values
-         */
-        final Multimap<Integer, ITmfStateInterval> map = NonNullUtils.checkNotNull(TreeMultimap.<Integer, ITmfStateInterval> create(
-                new Comparator<Integer>() {
-                    @Override
-                    public int compare(@Nullable Integer arg0, @Nullable Integer arg1) {
-                        /*
-                         * Keys do not have to be sorted, just use natural
-                         * sorting
-                         */
-                        if (arg0 == null || arg1 == null) {
-                            return -1;
-                        }
-                        return arg0.compareTo(arg1);
-                    }
-                }, new Comparator<ITmfStateInterval>() {
-                    @Override
-                    public int compare(@Nullable ITmfStateInterval arg0, @Nullable ITmfStateInterval arg1) {
-                        if (arg0 == null || arg1 == null) {
-                            return 0;
-                        }
-                        if (arg1.getStateValue() == VCPU_PREEMPT_VALUE && arg0.getStateValue() != VCPU_PREEMPT_VALUE) {
-                            /*
-                             * For VCPU_PREEMPT state values, the state has to
-                             * be after any other state that it overlaps,
-                             * because those intervals usually decorate the
-                             * other intervals.
-                             */
-                            if (((Long) arg0.getEndTime()).compareTo(arg1.getStartTime()) < 0) {
-                                return -1;
-                            }
-                            return ((Long) arg0.getStartTime()).compareTo(arg1.getEndTime());
-                        }
-                        /* Otherwise, we use ordering by start time */
-                        return (((Long) arg0.getStartTime()).compareTo(arg1.getStartTime()));
-                    }
-                }));
-        return map;
-    }
-
-    /**
-     * Get the status intervals for the threads from a virtual machine. Those
-     * intervals are correlated with the data from the virtual CPU's preemption
-     * status.
-     *
-     * This method uses the Linux Kernel Analysis data for the thread's status
-     * intervals.
-     *
-     * @param vmQuark
-     *            The quark of the virtual machine
-     * @param start
-     *            The start time of the period to get the intervals from
-     * @param end
-     *            The end time of the period to get the intervals from
-     * @param resolution
-     *            The resolution
-     * @param monitor
-     *            A progress monitor for this task
-     * @return A map of status intervals for the machine's threads, including
-     *         preempted intervals. Intervals from the thread status and the CPU
-     *         preemption status overlap and are ordered such that CPU
-     *         preemption intervals are after any interval they overlap with
-     */
-    public Multimap<Integer, ITmfStateInterval> getUpdatedThreadIntervals(int vmQuark, long start, long end, long resolution, IProgressMonitor monitor) {
-
-        final Multimap<Integer, ITmfStateInterval> map = createThreadMultimap();
-
-        ITmfStateSystem ss = getStateSystem();
-        if (ss == null) {
-            return map;
-        }
-        ITmfTrace trace = getTrace();
-        if (!(trace instanceof TmfExperiment)) {
-            return map;
-        }
-
-        String vmHostId = NonNullUtils.checkNotNull(ss.getAttributeName(vmQuark));
-        KernelAnalysisModule kernelModule = TmfExperimentUtils.getAnalysisModuleOfClassForHost((TmfExperiment) trace, vmHostId, KernelAnalysisModule.class);
-        if (kernelModule == null) {
-            return map;
-        }
-
-        /*
-         * Initialize the map with the original status intervals from the kernel
-         * module
-         */
-        for (Integer tid : KernelThreadInformationProvider.getThreadIds(kernelModule)) {
-            if (tid == null) {
-                throw new IllegalStateException();
-            }
-            map.putAll(tid, KernelThreadInformationProvider.getStatusIntervalsForThread(kernelModule, tid, start, end, resolution, monitor));
-            if (monitor.isCanceled()) {
-                return map;
-            }
-        }
-
-        try {
-            /* Correlate thread information with virtual CPU information */
-            for (Integer vcpuQuark : ss.getSubAttributes(vmQuark, false)) {
-                Long virtualCPU = Long.parseLong(ss.getAttributeName(vcpuQuark));
-                Integer statusQuark = ss.getQuarkRelative(vcpuQuark, VmAttributes.STATUS);
-
-                for (ITmfStateInterval cpuInterval : StateSystemUtils.queryHistoryRange(ss, statusQuark, start, end - 1, resolution, monitor)) {
-                    ITmfStateValue stateValue = cpuInterval.getStateValue();
-                    switch (stateValue.getType()) {
-                    case INTEGER:
-                        int value = stateValue.unboxInt();
-                        /*
-                         * If the current CPU is either preempted or in
-                         * hypervisor mode, add preempted intervals to running
-                         * processes
-                         */
-                        if ((value & (VcpuStateValues.VCPU_PREEMPT | VcpuStateValues.VCPU_VMM)) == 0) {
-                            break;
-                        }
-                        Integer threadOnCpu = KernelThreadInformationProvider.getThreadOnCpu(kernelModule, virtualCPU, cpuInterval.getStartTime());
-                        if (threadOnCpu != null) {
-                            map.put(threadOnCpu, new TmfStateInterval(cpuInterval.getStartTime(), cpuInterval.getEndTime(), threadOnCpu, VCPU_PREEMPT_VALUE));
-                        }
-                        break;
-                    case DOUBLE:
-                    case LONG:
-                    case NULL:
-                    case STRING:
-                    default:
-                        break;
-                    }
-
-                }
-            }
-        } catch (AttributeNotFoundException | StateSystemDisposedException e) {
-        }
-        return NonNullUtils.checkNotNull(map);
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/module/VirtualMachineStateProvider.java b/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/module/VirtualMachineStateProvider.java
deleted file mode 100644 (file)
index a39b71c..0000000
+++ /dev/null
@@ -1,365 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2014, 2015 École Polytechnique de Montréal
- *
- * 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:
- *   Mohamad Gebai - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.module;
-
-import static org.eclipse.tracecompass.common.core.NonNullUtils.checkNotNull;
-
-import java.util.HashMap;
-import java.util.Map;
-
-import org.eclipse.jdt.annotation.Nullable;
-import org.eclipse.tracecompass.analysis.os.linux.core.kernelanalysis.KernelAnalysisModule;
-import org.eclipse.tracecompass.analysis.os.linux.core.kernelanalysis.KernelThreadInformationProvider;
-import org.eclipse.tracecompass.analysis.os.linux.core.model.HostThread;
-import org.eclipse.tracecompass.analysis.os.linux.core.trace.IKernelAnalysisEventLayout;
-import org.eclipse.tracecompass.common.core.NonNullUtils;
-import org.eclipse.tracecompass.internal.lttng2.kernel.core.Activator;
-import org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.VcpuStateValues;
-import org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.VmAttributes;
-import org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.model.IVirtualMachineModel;
-import org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.model.VirtualCPU;
-import org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.model.VirtualMachine;
-import org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.model.qemukvm.QemuKvmVmModel;
-import org.eclipse.tracecompass.internal.lttng2.kernel.core.trace.layout.LttngEventLayout;
-import org.eclipse.tracecompass.lttng2.kernel.core.trace.LttngKernelTrace;
-import org.eclipse.tracecompass.statesystem.core.ITmfStateSystemBuilder;
-import org.eclipse.tracecompass.statesystem.core.exceptions.AttributeNotFoundException;
-import org.eclipse.tracecompass.statesystem.core.exceptions.StateValueTypeException;
-import org.eclipse.tracecompass.statesystem.core.exceptions.TimeRangeException;
-import org.eclipse.tracecompass.statesystem.core.statevalue.ITmfStateValue;
-import org.eclipse.tracecompass.statesystem.core.statevalue.TmfStateValue;
-import org.eclipse.tracecompass.tmf.core.event.ITmfEvent;
-import org.eclipse.tracecompass.tmf.core.event.ITmfEventField;
-import org.eclipse.tracecompass.tmf.core.event.aspect.TmfCpuAspect;
-import org.eclipse.tracecompass.tmf.core.statesystem.AbstractTmfStateProvider;
-import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace;
-import org.eclipse.tracecompass.tmf.core.trace.TmfTraceUtils;
-import org.eclipse.tracecompass.tmf.core.trace.experiment.TmfExperiment;
-import org.eclipse.tracecompass.tmf.core.trace.experiment.TmfExperimentUtils;
-
-import com.google.common.collect.HashBasedTable;
-import com.google.common.collect.Table;
-
-/**
- * This is the state provider which translates the virtual machine experiment
- * events to a state system.
- *
- * Attribute tree:
- *
- * <pre>
- * |- Virtual Machines
- * |  |- <Guest Host ID> -> Friendly name (trace name)
- * |  |  |- <VCPU number>
- * |  |  |  |- Status -> <Status value>
- * </pre>
- *
- * The status value of the VCPUs are either {@link VcpuStateValues#VCPU_IDLE},
- * {@link VcpuStateValues#VCPU_UNKNOWN} or {@link VcpuStateValues#VCPU_RUNNING}.
- * Those three values are ORed with flags {@link VcpuStateValues#VCPU_VMM}
- * and/or {@link VcpuStateValues#VCPU_PREEMPT} to indicate respectively whether
- * they are in hypervisor mode or preempted on the host.
- *
- * @author Mohamad Gebai
- */
-public class VirtualMachineStateProvider extends AbstractTmfStateProvider {
-
-    /**
-     * Version number of this state provider. Please bump this if you modify the
-     * contents of the generated state history in some way.
-     */
-    private static final int VERSION = 1;
-
-    private static final int SCHED_SWITCH_INDEX = 0;
-
-    /* TODO: An analysis should support many hypervisor models */
-    private IVirtualMachineModel fModel;
-    private final Table<ITmfTrace, String, Integer> fEventNames;
-    private final Map<ITmfTrace, IKernelAnalysisEventLayout> fLayouts;
-
-    // ------------------------------------------------------------------------
-    // Constructor
-    // ------------------------------------------------------------------------
-
-    /**
-     * Constructor
-     *
-     * @param experiment
-     *            The virtual machine experiment
-     */
-    public VirtualMachineStateProvider(TmfExperiment experiment) {
-        super(experiment, "Virtual Machine State Provider"); //$NON-NLS-1$
-
-        fModel = new QemuKvmVmModel(experiment);
-        Table<ITmfTrace, String, Integer> table = NonNullUtils.checkNotNull(HashBasedTable.<ITmfTrace, String, Integer> create());
-        fEventNames = table;
-        fLayouts = new HashMap<>();
-    }
-
-    // ------------------------------------------------------------------------
-    // Event names management
-    // ------------------------------------------------------------------------
-
-    private void buildEventNames(ITmfTrace trace) {
-        IKernelAnalysisEventLayout layout;
-        if (trace instanceof LttngKernelTrace) {
-            layout = ((LttngKernelTrace) trace).getKernelEventLayout();
-        } else {
-            /* Fall-back to the base LttngEventLayout */
-            layout = LttngEventLayout.getInstance();
-        }
-        fLayouts.put(trace, layout);
-        fEventNames.put(trace, layout.eventSchedSwitch(), SCHED_SWITCH_INDEX);
-    }
-
-    // ------------------------------------------------------------------------
-    // IStateChangeInput
-    // ------------------------------------------------------------------------
-
-    @Override
-    public TmfExperiment getTrace() {
-        ITmfTrace trace = super.getTrace();
-        if (trace instanceof TmfExperiment) {
-            return (TmfExperiment) trace;
-        }
-        throw new IllegalStateException("VirtualMachineStateProvider: The associated trace should be an experiment"); //$NON-NLS-1$
-    }
-
-    @Override
-    public int getVersion() {
-        return VERSION;
-    }
-
-    @Override
-    public VirtualMachineStateProvider getNewInstance() {
-        TmfExperiment trace = getTrace();
-        return new VirtualMachineStateProvider(trace);
-    }
-
-    @Override
-    protected void eventHandle(@Nullable ITmfEvent event) {
-        if (event == null) {
-            return;
-        }
-
-        /* Is the event managed by this analysis */
-        final String eventName = event.getName();
-
-        /* TODO When requirements work again, don't hardcode this */
-        if (!eventName.equals("sched_switch") && //$NON-NLS-1$
-                !fModel.getRequiredEvents().contains(eventName)) {
-            return;
-        }
-
-        ITmfStateSystemBuilder ss = checkNotNull(getStateSystemBuilder());
-        ITmfStateValue value;
-
-        final ITmfEventField content = event.getContent();
-        final long ts = event.getTimestamp().getValue();
-        final String hostId = event.getTrace().getHostId();
-        try {
-            /* Do we know this trace's role yet? */
-            VirtualMachine host = fModel.getCurrentMachine(event);
-            if (host == null) {
-                return;
-            }
-
-            /* Make sure guest traces are added to the state system */
-            if (host.isGuest()) {
-                /*
-                 * If event from a guest OS, make sure the guest exists in the
-                 * state system
-                 */
-                int vmQuark = -1;
-                try {
-                    vmQuark = ss.getQuarkRelative(getNodeVirtualMachines(), host.getHostId());
-                } catch (AttributeNotFoundException e) {
-                    /*
-                     * We should enter this catch only once per machine, so it
-                     * is not so costly to do compared with adding the trace's
-                     * name for each guest event
-                     */
-                    vmQuark = ss.getQuarkRelativeAndAdd(getNodeVirtualMachines(), host.getHostId());
-                    TmfStateValue machineName = TmfStateValue.newValueString(event.getTrace().getName());
-                    ss.modifyAttribute(ts, machineName, vmQuark);
-                }
-            }
-
-            /* Have the hypervisor models handle the event first */
-            fModel.handleEvent(event);
-
-            /* Handle the event here */
-            if (!fEventNames.containsRow(event.getTrace())) {
-                buildEventNames(event.getTrace());
-            }
-            Integer idx = fEventNames.get(event.getTrace(), eventName);
-            int intval = (idx == null ? -1 : idx.intValue());
-            switch (intval) {
-            case SCHED_SWITCH_INDEX: // "sched_switch":
-            /*
-             * Fields: string prev_comm, int32 prev_tid, int32 prev_prio, int64
-             * prev_state, string next_comm, int32 next_tid, int32 next_prio
-             */
-            {
-                int prevTid = ((Long) content.getField(fLayouts.get(event.getTrace()).fieldPrevTid()).getValue()).intValue();
-                int nextTid = ((Long) content.getField(fLayouts.get(event.getTrace()).fieldNextTid()).getValue()).intValue();
-
-                if (host.isGuest()) {
-                    /* Get the event's CPU */
-                    Object cpuObj = TmfTraceUtils.resolveEventAspectOfClassForEvent(event.getTrace(), TmfCpuAspect.class, event);
-                    if (cpuObj == null) {
-                        /* We couldn't find any CPU information, ignore this event */
-                        break;
-                    }
-                    Integer cpu = (Integer) cpuObj;
-
-                    /*
-                     * If sched switch is from a guest, just update the status
-                     * of the virtual CPU to either idle or running
-                     */
-                    int curStatusQuark = ss.getQuarkRelativeAndAdd(getNodeVirtualMachines(), host.getHostId(),
-                            cpu.toString(), VmAttributes.STATUS);
-                    value = TmfStateValue.newValueInt(VcpuStateValues.VCPU_IDLE);
-                    if (nextTid > 0) {
-                        value = TmfStateValue.newValueInt(VcpuStateValues.VCPU_RUNNING);
-                    }
-                    ss.modifyAttribute(ts, value, curStatusQuark);
-                    break;
-                }
-
-                /* Event is not from a guest */
-                /* Verify if the previous thread corresponds to a virtual CPU */
-                HostThread ht = new HostThread(hostId, prevTid);
-                VirtualCPU vcpu = fModel.getVirtualCpu(ht);
-
-                /*
-                 * If previous thread is virtual CPU, update status of the
-                 * virtual CPU to preempted
-                 */
-                if (vcpu != null) {
-                    VirtualMachine vm = vcpu.getVm();
-
-                    int curStatusQuark = ss.getQuarkRelativeAndAdd(getNodeVirtualMachines(), vm.getHostId(),
-                            vcpu.getCpuId().toString(), VmAttributes.STATUS);
-
-                    /* Add the preempted flag to the status */
-                    value = ss.queryOngoingState(curStatusQuark);
-                    int newVal = Math.max(VcpuStateValues.VCPU_UNKNOWN, value.unboxInt());
-                    value = TmfStateValue.newValueInt(newVal | VcpuStateValues.VCPU_PREEMPT);
-                    ss.modifyAttribute(ts, value, curStatusQuark);
-                }
-
-                /* Verify if the next thread corresponds to a virtual CPU */
-                ht = new HostThread(hostId, nextTid);
-                vcpu = fModel.getVirtualCpu(ht);
-
-                /*
-                 * If next thread is virtual CPU, update status of the virtual
-                 * CPU the previous status
-                 */
-                if (vcpu != null) {
-                    VirtualMachine vm = vcpu.getVm();
-                    int curStatusQuark = ss.getQuarkRelativeAndAdd(getNodeVirtualMachines(), vm.getHostId(),
-                            vcpu.getCpuId().toString(), VmAttributes.STATUS);
-
-                    /* Remove the preempted flag from the status */
-                    value = ss.queryOngoingState(curStatusQuark);
-                    int newVal = Math.max(VcpuStateValues.VCPU_UNKNOWN, value.unboxInt());
-                    value = TmfStateValue.newValueInt(newVal & ~VcpuStateValues.VCPU_PREEMPT);
-                    ss.modifyAttribute(ts, value, curStatusQuark);
-
-                }
-
-            }
-                break;
-
-            default:
-            /* Other events not covered by the main switch */
-            {
-                HostThread ht = getCurrentHostThread(event, ts);
-                if (ht == null) {
-                    break;
-                }
-
-                /*
-                 * Are we entering the hypervisor mode and if so, which virtual
-                 * CPU is concerned?
-                 */
-                VirtualCPU virtualCpu = fModel.getVCpuEnteringHypervisorMode(event, ht);
-                if (virtualCpu != null) {
-                    /* Add the hypervisor flag to the status */
-                    VirtualMachine vm = virtualCpu.getVm();
-                    int curStatusQuark = ss.getQuarkRelativeAndAdd(getNodeVirtualMachines(), vm.getHostId(),
-                            Long.toString(virtualCpu.getCpuId()), VmAttributes.STATUS);
-                    value = ss.queryOngoingState(curStatusQuark);
-                    int newVal = Math.max(VcpuStateValues.VCPU_UNKNOWN, value.unboxInt());
-                    value = TmfStateValue.newValueInt(newVal | VcpuStateValues.VCPU_VMM);
-                    ss.modifyAttribute(ts, value, curStatusQuark);
-                }
-
-                /*
-                 * Are we exiting the hypervisor mode and if so, which virtual
-                 * CPU is concerned?
-                 */
-                virtualCpu = fModel.getVCpuExitingHypervisorMode(event, ht);
-                if (virtualCpu != null) {
-                    /* Remove the hypervisor flag from the status */
-                    VirtualMachine vm = virtualCpu.getVm();
-                    int curStatusQuark = ss.getQuarkRelativeAndAdd(getNodeVirtualMachines(), vm.getHostId(),
-                            Long.toString(virtualCpu.getCpuId()), VmAttributes.STATUS);
-                    value = ss.queryOngoingState(curStatusQuark);
-                    int newVal = Math.max(VcpuStateValues.VCPU_UNKNOWN, value.unboxInt());
-                    value = TmfStateValue.newValueInt(newVal & ~VcpuStateValues.VCPU_VMM);
-                    ss.modifyAttribute(ts, value, curStatusQuark);
-                }
-
-            }
-                break;
-            }
-
-        } catch (AttributeNotFoundException | TimeRangeException | StateValueTypeException e) {
-            Activator.getDefault().logError("Error handling event in VirtualMachineStateProvider", e); //$NON-NLS-1$
-        }
-    }
-
-    // ------------------------------------------------------------------------
-    // Convenience methods for commonly-used attribute tree locations
-    // ------------------------------------------------------------------------
-
-    private int getNodeVirtualMachines() {
-        return checkNotNull(getStateSystemBuilder()).getQuarkAbsoluteAndAdd(VmAttributes.VIRTUAL_MACHINES);
-    }
-
-    private @Nullable HostThread getCurrentHostThread(ITmfEvent event, long ts) {
-        /* Get the LTTng kernel analysis for the host */
-        String hostId = event.getTrace().getHostId();
-        KernelAnalysisModule module = TmfExperimentUtils.getAnalysisModuleOfClassForHost(getTrace(), hostId, KernelAnalysisModule.class);
-        if (module == null) {
-            return null;
-        }
-
-        /* Get the CPU the event is running on */
-        Object cpuObj = TmfTraceUtils.resolveEventAspectOfClassForEvent(event.getTrace(), TmfCpuAspect.class, event);
-        if (cpuObj == null) {
-            /* We couldn't find any CPU information, ignore this event */
-            return null;
-        }
-        Integer cpu = (Integer) cpuObj;
-
-        Integer currentTid = KernelThreadInformationProvider.getThreadOnCpu(module, cpu, ts);
-        if (currentTid == null) {
-            return null;
-        }
-        return new HostThread(hostId, currentTid);
-    }
-
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/module/messages.properties b/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/module/messages.properties
deleted file mode 100644 (file)
index 7f89d62..0000000
+++ /dev/null
@@ -1,13 +0,0 @@
-###############################################################################
-# Copyright (c) 2014 École Polytechnique de Montréal
-#
-# 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:
-#     Geneviève Bastien - Initial API and implementation
-###############################################################################
-
-VirtualMachineCPUAnalysis_Help=Tracks the state of the virtual CPUs of the guest virtual machine in an experiment. It also interrelate the CPU information with the information from thread status of each guest.
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/module/package-info.java b/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/module/package-info.java
deleted file mode 100644 (file)
index ef9c73e..0000000
+++ /dev/null
@@ -1,14 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2014 École Polytechnique de Montréal
- *
- * 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:
- *    École Polytechnique de Montréal - Initial API and implementation
- *******************************************************************************/
-
-@org.eclipse.jdt.annotation.NonNullByDefault
-package org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.module;
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/package-info.java b/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/package-info.java
deleted file mode 100644 (file)
index 2efb6c7..0000000
+++ /dev/null
@@ -1,14 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2014 École Polytechnique de Montréal
- *
- * 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:
- *    École Polytechnique de Montréal - Initial API and implementation
- *******************************************************************************/
-
-@org.eclipse.jdt.annotation.NonNullByDefault
-package org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm;
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/trace/VirtualMachineExperiment.java b/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/trace/VirtualMachineExperiment.java
deleted file mode 100644 (file)
index 4eef98c..0000000
+++ /dev/null
@@ -1,52 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2014, 2015 École Polytechnique de Montréal
- *
- * 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:
- *   Mohamad Gebai - Initial API and implementation
- *   Patrick Tasse - Fix experiment name
- *******************************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.trace;
-
-import static org.eclipse.tracecompass.common.core.NonNullUtils.checkNotNull;
-
-import java.util.Collections;
-import java.util.Set;
-
-import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace;
-import org.eclipse.tracecompass.tmf.core.trace.experiment.TmfExperiment;
-import org.eclipse.tracecompass.tmf.ctf.core.event.CtfTmfEvent;
-
-/**
- * Experiment class containing traces from physical machine and the virtual
- * guests running on them.
- *
- * @author Mohamad Gebai
- */
-public class VirtualMachineExperiment extends TmfExperiment {
-
-    /**
-     * Default constructor. Needed by the extension point.
-     */
-    public VirtualMachineExperiment() {
-        this("", checkNotNull(Collections.EMPTY_SET)); //$NON-NLS-1$
-    }
-
-    /**
-     * Constructor with traces and id
-     *
-     * @param id
-     *            The ID of this experiment
-     * @param traces
-     *            The set of traces that are part of this experiment
-     */
-    public VirtualMachineExperiment(String id, Set<ITmfTrace> traces) {
-        super(CtfTmfEvent.class, id, traces.toArray(new ITmfTrace[traces.size()]), TmfExperiment.DEFAULT_INDEX_PAGE_SIZE, null);
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/trace/package-info.java b/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/analysis/vm/trace/package-info.java
deleted file mode 100644 (file)
index 0bcb5e3..0000000
+++ /dev/null
@@ -1,14 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2014 École Polytechnique de Montréal
- *
- * 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:
- *    École Polytechnique de Montréal - Initial API and implementation
- *******************************************************************************/
-
-@org.eclipse.jdt.annotation.NonNullByDefault
-package org.eclipse.tracecompass.internal.lttng2.kernel.core.analysis.vm.trace;
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/event/matching/TcpEventMatching.java b/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/event/matching/TcpEventMatching.java
deleted file mode 100644 (file)
index 2feeb23..0000000
+++ /dev/null
@@ -1,97 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2013, 2014 École Polytechnique de Montréal
- *
- * 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:
- *   Geneviève Bastien - Initial implementation and API
- *******************************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.kernel.core.event.matching;
-
-import java.util.Set;
-
-import org.eclipse.tracecompass.internal.lttng2.kernel.core.TcpEventStrings;
-import org.eclipse.tracecompass.tmf.core.event.ITmfEvent;
-import org.eclipse.tracecompass.tmf.core.event.ITmfEventField;
-import org.eclipse.tracecompass.tmf.core.event.matching.IEventMatchingKey;
-import org.eclipse.tracecompass.tmf.core.event.matching.ITmfMatchEventDefinition;
-import org.eclipse.tracecompass.tmf.core.event.matching.TcpEventKey;
-import org.eclipse.tracecompass.tmf.core.event.matching.TmfEventMatching.Direction;
-import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace;
-import org.eclipse.tracecompass.tmf.core.trace.ITmfTraceWithPreDefinedEvents;
-import org.eclipse.tracecompass.tmf.core.trace.TmfEventTypeCollectionHelper;
-
-import com.google.common.collect.ImmutableSet;
-
-/**
- * Class to match tcp type events. This matching class applies to traces
- * obtained with the 'addons' lttng module. This module can be obtained with
- * lttng-modules to generate traces at
- * https://github.com/giraldeau/lttng-modules/tree/addons
- *
- * Note: this module only allows to generate traces to be read and analyzed by
- * TMF, no code from this module is being used here
- *
- * @author Geneviève Bastien
- */
-public class TcpEventMatching implements ITmfMatchEventDefinition {
-
-    private static final ImmutableSet<String> REQUIRED_EVENTS = ImmutableSet.of(
-            TcpEventStrings.INET_SOCK_LOCAL_IN,
-            TcpEventStrings.INET_SOCK_LOCAL_OUT);
-
-    private static boolean canMatchPacket(final ITmfEvent event) {
-        /* Make sure all required fields are present to match with this event */
-        ITmfEventField content = event.getContent();
-        if ((content.getField(TcpEventStrings.SEQ) != null) &&
-                (content.getField(TcpEventStrings.ACKSEQ) != null) && (content.getField(TcpEventStrings.FLAGS) != null)) {
-            return true;
-        }
-        return false;
-    }
-
-    /**
-     * @since 1.0
-     */
-    @Override
-    public Direction getDirection(ITmfEvent event) {
-        String evname = event.getName();
-
-        if (!canMatchPacket(event)) {
-            return null;
-        }
-
-        /* Is the event a tcp socket in or out event */
-        if (evname.equals(TcpEventStrings.INET_SOCK_LOCAL_IN)) {
-            return Direction.CAUSE;
-        } else if (evname.equals(TcpEventStrings.INET_SOCK_LOCAL_OUT)) {
-            return Direction.EFFECT;
-        }
-        return null;
-    }
-
-    @Override
-    public IEventMatchingKey getEventKey(ITmfEvent event) {
-        IEventMatchingKey key = new TcpEventKey((long) event.getContent().getField(TcpEventStrings.SEQ).getValue(),
-                (long) event.getContent().getField(TcpEventStrings.ACKSEQ).getValue(),
-                (long) event.getContent().getField(TcpEventStrings.FLAGS).getValue());
-        return key;
-    }
-
-    @Override
-    public boolean canMatchTrace(ITmfTrace trace) {
-        if (!(trace instanceof ITmfTraceWithPreDefinedEvents)) {
-            return true;
-        }
-        ITmfTraceWithPreDefinedEvents ktrace = (ITmfTraceWithPreDefinedEvents) trace;
-
-        Set<String> traceEvents = TmfEventTypeCollectionHelper.getEventNames(ktrace.getContainedEventTypes());
-        traceEvents.retainAll(REQUIRED_EVENTS);
-        return !traceEvents.isEmpty();
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/event/matching/TcpLttngEventMatching.java b/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/event/matching/TcpLttngEventMatching.java
deleted file mode 100644 (file)
index 89ff699..0000000
+++ /dev/null
@@ -1,122 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2013, 2015 École Polytechnique de Montréal
- *
- * 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:
- *   Geneviève Bastien - Initial implementation and API
- *   Patrick Tasse - Remove getSubField
- *******************************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.kernel.core.event.matching;
-
-import java.util.Set;
-
-import org.eclipse.jdt.annotation.NonNull;
-import org.eclipse.tracecompass.internal.lttng2.kernel.core.TcpEventStrings;
-import org.eclipse.tracecompass.tmf.core.event.ITmfEvent;
-import org.eclipse.tracecompass.tmf.core.event.ITmfEventField;
-import org.eclipse.tracecompass.tmf.core.event.TmfEventField;
-import org.eclipse.tracecompass.tmf.core.event.matching.IEventMatchingKey;
-import org.eclipse.tracecompass.tmf.core.event.matching.ITmfMatchEventDefinition;
-import org.eclipse.tracecompass.tmf.core.event.matching.TcpEventKey;
-import org.eclipse.tracecompass.tmf.core.event.matching.TmfEventMatching.Direction;
-import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace;
-import org.eclipse.tracecompass.tmf.core.trace.ITmfTraceWithPreDefinedEvents;
-import org.eclipse.tracecompass.tmf.core.trace.TmfEventTypeCollectionHelper;
-
-import com.google.common.collect.ImmutableSet;
-
-/**
- * Class to match tcp type events. This class applies to traces obtained with
- * the full network tracepoint data available from an experimental branch of
- * lttng-modules. This branch is often rebased on lttng-modules master and is
- * available at
- * http://git.dorsal.polymtl.ca/~gbastien?p=lttng-modules.git;a=summary
- * net_data_experimental branch.
- *
- * @author Geneviève Bastien
- */
-public class TcpLttngEventMatching implements ITmfMatchEventDefinition {
-
-    private static final @NonNull String[] KEY_SEQ = { TcpEventStrings.TRANSPORT_FIELDS, TcpEventStrings.TYPE_TCP, TcpEventStrings.SEQ };
-    private static final @NonNull String[] KEY_ACKSEQ = { TcpEventStrings.TRANSPORT_FIELDS, TcpEventStrings.TYPE_TCP, TcpEventStrings.ACKSEQ };
-    private static final @NonNull String[] KEY_FLAGS = { TcpEventStrings.TRANSPORT_FIELDS, TcpEventStrings.TYPE_TCP, TcpEventStrings.FLAGS };
-
-    private static final ImmutableSet<String> REQUIRED_EVENTS = ImmutableSet.of(
-            TcpEventStrings.NET_DEV_QUEUE,
-            TcpEventStrings.NETIF_RECEIVE_SKB);
-
-    private static boolean canMatchPacket(final ITmfEvent event) {
-        TmfEventField field = (TmfEventField) event.getContent();
-
-        String[] tcp_data = { TcpEventStrings.TRANSPORT_FIELDS, TcpEventStrings.TYPE_TCP };
-        ITmfEventField data = field.getField(tcp_data);
-        if (data != null) {
-            return (data.getValue() != null);
-        }
-        return false;
-    }
-
-    @Override
-    public boolean canMatchTrace(ITmfTrace trace) {
-        if (!(trace instanceof ITmfTraceWithPreDefinedEvents)) {
-            return true;
-        }
-        ITmfTraceWithPreDefinedEvents ktrace = (ITmfTraceWithPreDefinedEvents) trace;
-
-        Set<String> traceEvents = TmfEventTypeCollectionHelper.getEventNames(ktrace.getContainedEventTypes());
-        traceEvents.retainAll(REQUIRED_EVENTS);
-        return !traceEvents.isEmpty();
-    }
-
-    /**
-     * @since 1.0
-     */
-    @Override
-    public Direction getDirection(ITmfEvent event) {
-        String evname = event.getName();
-
-        /* Is the event a tcp socket in or out event */
-        if (evname.equals(TcpEventStrings.NETIF_RECEIVE_SKB) && canMatchPacket(event)) {
-            return Direction.CAUSE;
-        } else if (evname.equals(TcpEventStrings.NET_DEV_QUEUE) && canMatchPacket(event)) {
-            return Direction.EFFECT;
-        }
-        return null;
-    }
-
-    @Override
-    public IEventMatchingKey getEventKey(ITmfEvent event) {
-        TmfEventField field = (TmfEventField) event.getContent();
-        ITmfEventField data;
-
-        long seq = -1, ackseq = -1, flags = -1;
-        data = field.getField(KEY_SEQ);
-        if (data != null) {
-            seq = (long) data.getValue();
-        } else {
-            return null;
-        }
-        data = field.getField(KEY_ACKSEQ);
-        if (data != null) {
-            ackseq = (long) data.getValue();
-        } else {
-            return null;
-        }
-        data = field.getField(KEY_FLAGS);
-        if (data != null) {
-            flags = (long) data.getValue();
-        } else {
-            return null;
-        }
-
-        IEventMatchingKey key = new TcpEventKey(seq, ackseq, flags);
-
-        return key;
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/trace/layout/Lttng26EventLayout.java b/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/trace/layout/Lttng26EventLayout.java
deleted file mode 100644 (file)
index 34284ce..0000000
+++ /dev/null
@@ -1,52 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2014 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:
- *   Alexandre Montplaisir - Initial API and implementation
- ******************************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.kernel.core.trace.layout;
-
-/**
- * This file defines all the known event and field names for LTTng kernel
- * traces, for versions of lttng-modules 2.6 and above.
- *
- * @author Alexandre Montplaisir
- */
-public class Lttng26EventLayout extends LttngEventLayout {
-
-    /**
-     * Constructor
-     */
-    protected Lttng26EventLayout() {}
-
-    private static final Lttng26EventLayout INSTANCE = new Lttng26EventLayout();
-
-    public static Lttng26EventLayout getInstance() {
-        return INSTANCE;
-    }
-
-    // ------------------------------------------------------------------------
-    // New event names in these versions
-    // ------------------------------------------------------------------------
-
-    @Override
-    public String eventSyscallEntryPrefix() {
-        return "syscall_entry_"; //$NON-NLS-1$
-    }
-
-    @Override
-    public String eventCompatSyscallEntryPrefix() {
-        return "compat_syscall_entry_"; //$NON-NLS-1$
-    }
-
-    @Override
-    public String eventSyscallExitPrefix() {
-        return "syscall_exit_"; //$NON-NLS-1$
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/trace/layout/Lttng27EventLayout.java b/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/trace/layout/Lttng27EventLayout.java
deleted file mode 100644 (file)
index edfb35d..0000000
+++ /dev/null
@@ -1,66 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2015 Ericsson, École Polytechnique de Montréal
- *
- * 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:
- *   Sebastien Lorrain - Initial API and implementation
- ******************************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.kernel.core.trace.layout;
-
-/**
- * This file defines all the known event and field names for LTTng kernel
- * traces, for versions of lttng-modules 2.7 and above.
- *
- * @author Sebastien Lorrain
- */
-@SuppressWarnings("javadoc")
-public class Lttng27EventLayout extends Lttng26EventLayout {
-
-    /**
-     * Constructor
-     */
-    protected Lttng27EventLayout() {}
-
-    public static final Lttng27EventLayout INSTANCE = new Lttng27EventLayout();
-
-    // ------------------------------------------------------------------------
-    // New definitions in LTTng 2.7
-    // ------------------------------------------------------------------------
-
-    public String fieldParentNSInum() {
-        return "parent_ns_inum"; //$NON-NLS-1$
-    }
-
-    public String fieldChildNSInum() {
-        return "child_ns_inum"; //$NON-NLS-1$
-    }
-
-    public String fieldChildVTids() {
-        return "vtids"; //$NON-NLS-1$
-    }
-
-    public String fieldNSInum() {
-        return "ns_inum"; //$NON-NLS-1$
-    }
-
-    public String fieldVTid() {
-        return "vtid"; //$NON-NLS-1$
-    }
-
-    public String fieldPPid() {
-        return "ppid"; //$NON-NLS-1$
-    }
-
-    public String fieldNSLevel() {
-        return "ns_level"; //$NON-NLS-1$
-    }
-
-    public String fieldStatus() {
-        return "status"; //$NON-NLS-1$
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/trace/layout/LttngEventLayout.java b/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/trace/layout/LttngEventLayout.java
deleted file mode 100644 (file)
index 13a9fbf..0000000
+++ /dev/null
@@ -1,239 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2012, 2015 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:
- *   Alexandre Montplaisir - Initial API and implementation
- ******************************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.kernel.core.trace.layout;
-
-import static org.eclipse.tracecompass.common.core.NonNullUtils.checkNotNull;
-
-import java.util.Collection;
-
-import org.eclipse.jdt.annotation.NonNull;
-import org.eclipse.tracecompass.analysis.os.linux.core.trace.IKernelAnalysisEventLayout;
-
-import com.google.common.collect.ImmutableList;
-
-/**
- * This file defines all the known event and field names for LTTng kernel
- * traces, for versions of lttng-modules up to 2.5.
- *
- * These should not be externalized, since they need to match exactly what the
- * tracer outputs. If you want to localize them in a view, you should do a
- * mapping in the view itself.
- *
- * @author Alexandre Montplaisir
- */
-@SuppressWarnings("nls")
-public class LttngEventLayout implements IKernelAnalysisEventLayout {
-
-    /* Event names */
-    private static final String IRQ_HANDLER_ENTRY = "irq_handler_entry";
-    private static final String IRQ_HANDLER_EXIT = "irq_handler_exit";
-    private static final String SOFTIRQ_ENTRY = "softirq_entry";
-    private static final String SOFTIRQ_EXIT = "softirq_exit";
-    private static final String SOFTIRQ_RAISE = "softirq_raise";
-    private static final String SCHED_SWITCH = "sched_switch";
-    private static final String SCHED_PI_SETPRIO = "sched_pi_setprio";
-
-    private static final Collection<String> SCHED_WAKEUP_EVENTS =
-            checkNotNull(ImmutableList.of("sched_wakeup", "sched_wakeup_new"));
-
-    private static final String SCHED_PROCESS_FORK = "sched_process_fork";
-    private static final String SCHED_PROCESS_EXIT = "sched_process_exit";
-    private static final String SCHED_PROCESS_FREE = "sched_process_free";
-    private static final String STATEDUMP_PROCESS_STATE = "lttng_statedump_process_state";
-
-    private static final String SYSCALL_ENTRY_PREFIX = "sys_";
-    private static final String COMPAT_SYSCALL_ENTRY_PREFIX = "compat_sys_";
-    private static final String SYSCALL_EXIT_PREFIX = "exit_syscall";
-
-    /* Field names */
-    private static final String IRQ = "irq";
-    private static final String TID = "tid";
-    private static final String VEC = "vec";
-    private static final String PREV_TID = "prev_tid";
-    private static final String PREV_STATE = "prev_state";
-    private static final String NEXT_COMM = "next_comm";
-    private static final String NEXT_TID = "next_tid";
-    private static final String PARENT_TID = "parent_tid";
-    private static final String CHILD_COMM = "child_comm";
-    private static final String CHILD_TID = "child_tid";
-    private static final String PRIO = "prio";
-    private static final String NEXT_PRIO = "next_prio";
-    private static final String NEW_PRIO = "newprio";
-
-    /** All instances are the same. Only provide a static instance getter */
-    protected LttngEventLayout() {
-    }
-
-    private static final IKernelAnalysisEventLayout INSTANCE = new LttngEventLayout();
-
-    /**
-     * Get an instance of this event layout
-     *
-     * This object is completely immutable, so no need to create additional
-     * instances via the constructor.
-     *
-     * @return The instance
-     */
-    public static IKernelAnalysisEventLayout getInstance() {
-        return INSTANCE;
-    }
-
-    // ------------------------------------------------------------------------
-    // Event names
-    // ------------------------------------------------------------------------
-
-    @Override
-    public String eventIrqHandlerEntry() {
-        return IRQ_HANDLER_ENTRY;
-    }
-
-    @Override
-    public String eventIrqHandlerExit() {
-        return IRQ_HANDLER_EXIT;
-    }
-
-    @Override
-    public String eventSoftIrqEntry() {
-        return SOFTIRQ_ENTRY;
-    }
-
-    @Override
-    public String eventSoftIrqExit() {
-        return SOFTIRQ_EXIT;
-    }
-
-    @Override
-    public String eventSoftIrqRaise() {
-        return SOFTIRQ_RAISE;
-    }
-
-    @Override
-    public String eventSchedSwitch() {
-        return SCHED_SWITCH;
-    }
-
-    @Override
-    public String eventSchedPiSetprio() {
-        return SCHED_PI_SETPRIO;
-    }
-
-    @Override
-    public Collection<String> eventsSchedWakeup() {
-        return SCHED_WAKEUP_EVENTS;
-    }
-
-    @Override
-    public String eventSchedProcessFork() {
-        return SCHED_PROCESS_FORK;
-    }
-
-    @Override
-    public String eventSchedProcessExit() {
-        return SCHED_PROCESS_EXIT;
-    }
-
-    @Override
-    public String eventSchedProcessFree() {
-        return SCHED_PROCESS_FREE;
-    }
-
-    @Override
-    public @NonNull String eventStatedumpProcessState() {
-        return STATEDUMP_PROCESS_STATE;
-    }
-
-    @Override
-    public String eventSyscallEntryPrefix() {
-        return SYSCALL_ENTRY_PREFIX;
-    }
-
-    @Override
-    public String eventCompatSyscallEntryPrefix() {
-        return COMPAT_SYSCALL_ENTRY_PREFIX;
-    }
-
-    @Override
-    public String eventSyscallExitPrefix() {
-        return SYSCALL_EXIT_PREFIX;
-    }
-
-    // ------------------------------------------------------------------------
-    // Event field names
-    // ------------------------------------------------------------------------
-
-    @Override
-    public String fieldIrq() {
-        return IRQ;
-    }
-
-    @Override
-    public String fieldVec() {
-        return VEC;
-    }
-
-    @Override
-    public String fieldTid() {
-        return TID;
-    }
-
-    @Override
-    public String fieldPrevTid() {
-        return PREV_TID;
-    }
-
-    @Override
-    public String fieldPrevState() {
-        return PREV_STATE;
-    }
-
-    @Override
-    public String fieldNextComm() {
-        return NEXT_COMM;
-    }
-
-    @Override
-    public String fieldNextTid() {
-        return NEXT_TID;
-    }
-
-    @Override
-    public String fieldChildComm() {
-        return CHILD_COMM;
-    }
-
-    @Override
-    public String fieldParentTid() {
-        return PARENT_TID;
-    }
-
-    @Override
-    public String fieldChildTid() {
-        return CHILD_TID;
-    }
-
-    @Override
-    public String fieldPrio() {
-        return PRIO;
-    }
-
-    @Override
-    public String fieldNewPrio() {
-        return NEW_PRIO;
-    }
-
-    @Override
-    public String fieldNextPrio() {
-        return NEXT_PRIO;
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/trace/layout/PerfEventLayout.java b/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/trace/layout/PerfEventLayout.java
deleted file mode 100644 (file)
index 03512c2..0000000
+++ /dev/null
@@ -1,196 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2012, 2015 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:
- *   Alexandre Montplaisir - Initial API and implementation
- ******************************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.kernel.core.trace.layout;
-
-import static org.eclipse.tracecompass.common.core.NonNullUtils.checkNotNull;
-
-import java.util.Collection;
-
-import org.eclipse.jdt.annotation.Nullable;
-import org.eclipse.tracecompass.analysis.os.linux.core.trace.IKernelAnalysisEventLayout;
-
-import com.google.common.collect.ImmutableList;
-
-/**
- * Event and field definitions for perf traces in CTF format.
- *
- * @author Alexandre Montplaisir
- */
-public class PerfEventLayout implements IKernelAnalysisEventLayout {
-
-    private PerfEventLayout() {}
-
-    private static final PerfEventLayout INSTANCE = new PerfEventLayout();
-
-    /**
-     * Get the singleton instance of this event layout object.
-     *
-     * @return The instance
-     */
-    public static PerfEventLayout getInstance() {
-        return INSTANCE;
-    }
-
-    // ------------------------------------------------------------------------
-    // Event names
-    // ------------------------------------------------------------------------
-
-    @Override
-    public String eventIrqHandlerEntry() {
-        return "irq:irq_handler_exit"; //$NON-NLS-1$
-    }
-
-    @Override
-    public String eventIrqHandlerExit() {
-        return "irq:irq_handler_entry"; //$NON-NLS-1$
-    }
-
-    @Override
-    public String eventSoftIrqEntry() {
-        return "irq:softirq_entry"; //$NON-NLS-1$
-    }
-
-    @Override
-    public String eventSoftIrqExit() {
-        return "irq:softirq_exit"; //$NON-NLS-1$
-    }
-
-    @Override
-    public String eventSoftIrqRaise() {
-        return "irq:softirq_raise"; //$NON-NLS-1$
-    }
-
-    @Override
-    public String eventSchedSwitch() {
-        return "sched:sched_switch"; //$NON-NLS-1$
-    }
-
-    @Override
-    public String eventSchedPiSetprio() {
-        return "sched:sched_pi_setprio"; //$NON-NLS-1$
-    }
-
-    private static final Collection<String> WAKEUP_EVENTS =
-            checkNotNull(ImmutableList.of("sched:sched_wakeup", "sched:sched_wakeup_new")); //$NON-NLS-1$ //$NON-NLS-2$
-
-    @Override
-    public Collection<String> eventsSchedWakeup() {
-        return WAKEUP_EVENTS;
-    }
-
-    @Override
-    public String eventSchedProcessFork() {
-        return "sched:sched_process_fork"; //$NON-NLS-1$
-    }
-
-    @Override
-    public String eventSchedProcessExit() {
-        return "sched:sched_process_exit"; //$NON-NLS-1$
-    }
-
-    @Override
-    public String eventSchedProcessFree() {
-        return "sched:sched_process_free"; //$NON-NLS-1$
-    }
-
-    @Override
-    public @Nullable String eventStatedumpProcessState() {
-        /* Not present in perf traces */
-        return null;
-    }
-
-    @Override
-    public String eventSyscallEntryPrefix() {
-        return "raw_syscalls:sys_enter"; //$NON-NLS-1$
-    }
-
-    @Override
-    public String eventCompatSyscallEntryPrefix() {
-        return eventSyscallEntryPrefix();
-    }
-
-    @Override
-    public String eventSyscallExitPrefix() {
-        return "raw_syscalls:sys_exit"; //$NON-NLS-1$
-    }
-
-    // ------------------------------------------------------------------------
-    // Field names
-    // ------------------------------------------------------------------------
-
-    @Override
-    public String fieldIrq() {
-        return "irq"; //$NON-NLS-1$
-    }
-
-    @Override
-    public String fieldVec() {
-        return "vec"; //$NON-NLS-1$
-    }
-
-    @Override
-    public String fieldTid() {
-        return "pid"; //$NON-NLS-1$
-    }
-
-    @Override
-    public String fieldPrevTid() {
-        return "prev_pid"; //$NON-NLS-1$
-    }
-
-    @Override
-    public String fieldPrevState() {
-        return "prev_state"; //$NON-NLS-1$
-    }
-
-    @Override
-    public String fieldNextComm() {
-        return "next_comm"; //$NON-NLS-1$
-    }
-
-    @Override
-    public String fieldNextTid() {
-        return "next_pid"; //$NON-NLS-1$
-    }
-
-    @Override
-    public String fieldChildComm() {
-        return "child_comm"; //$NON-NLS-1$
-    }
-
-    @Override
-    public String fieldParentTid() {
-        return "parent_pid"; //$NON-NLS-1$
-    }
-
-    @Override
-    public String fieldChildTid() {
-        return "child_pid"; //$NON-NLS-1$
-    }
-
-    @Override
-    public String fieldPrio() {
-        return "prio"; //$NON-NLS-1$
-    }
-
-    @Override
-    public String fieldNewPrio() {
-        return "newprio"; //$NON-NLS-1$
-    }
-
-    @Override
-    public String fieldNextPrio() {
-        return "next_prio"; //$NON-NLS-1$
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/trace/layout/package-info.java b/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/internal/lttng2/kernel/core/trace/layout/package-info.java
deleted file mode 100644 (file)
index d74f33f..0000000
+++ /dev/null
@@ -1,14 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2014 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:
- *    Ericsson - Initial API and implementation
- *******************************************************************************/
-
-@org.eclipse.jdt.annotation.NonNullByDefault
-package org.eclipse.tracecompass.internal.lttng2.kernel.core.trace.layout;
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/lttng2/kernel/core/trace/LttngKernelTrace.java b/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/lttng2/kernel/core/trace/LttngKernelTrace.java
deleted file mode 100644 (file)
index b3e3c70..0000000
+++ /dev/null
@@ -1,164 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2012, 2015 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:
- *   Alexandre Montplaisir - Initial API and implementation
- *   Matthew Khouzam - Improved validation
- ******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.kernel.core.trace;
-
-import java.util.Collection;
-import java.util.Map;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.resources.IResource;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.jdt.annotation.NonNull;
-import org.eclipse.tracecompass.analysis.os.linux.core.kernelanalysis.KernelTidAspect;
-import org.eclipse.tracecompass.analysis.os.linux.core.kernelanalysis.ThreadPriorityAspect;
-import org.eclipse.tracecompass.analysis.os.linux.core.trace.IKernelAnalysisEventLayout;
-import org.eclipse.tracecompass.analysis.os.linux.core.trace.IKernelTrace;
-import org.eclipse.tracecompass.common.core.NonNullUtils;
-import org.eclipse.tracecompass.internal.lttng2.kernel.core.Activator;
-import org.eclipse.tracecompass.internal.lttng2.kernel.core.trace.layout.Lttng26EventLayout;
-import org.eclipse.tracecompass.internal.lttng2.kernel.core.trace.layout.Lttng27EventLayout;
-import org.eclipse.tracecompass.internal.lttng2.kernel.core.trace.layout.LttngEventLayout;
-import org.eclipse.tracecompass.internal.lttng2.kernel.core.trace.layout.PerfEventLayout;
-import org.eclipse.tracecompass.tmf.core.event.ITmfEvent;
-import org.eclipse.tracecompass.tmf.core.event.aspect.ITmfEventAspect;
-import org.eclipse.tracecompass.tmf.core.exceptions.TmfTraceException;
-import org.eclipse.tracecompass.tmf.core.trace.TraceValidationStatus;
-import org.eclipse.tracecompass.tmf.ctf.core.trace.CtfTmfTrace;
-import org.eclipse.tracecompass.tmf.ctf.core.trace.CtfTraceValidationStatus;
-
-import com.google.common.collect.ImmutableSet;
-
-/**
- * This is the specification of CtfTmfTrace for use with LTTng 2.x kernel
- * traces.
- *
- * @author Alexandre Montplaisir
- */
-public class LttngKernelTrace extends CtfTmfTrace implements IKernelTrace {
-
-    /**
-     * Supported Linux kernel tracers
-     */
-    private enum OriginTracer {
-        LTTNG(LttngEventLayout.getInstance()),
-        LTTNG26(Lttng26EventLayout.getInstance()),
-        LTTNG27(Lttng27EventLayout.INSTANCE),
-        PERF(PerfEventLayout.getInstance());
-
-        private final @NonNull IKernelAnalysisEventLayout fLayout;
-
-        private OriginTracer(@NonNull IKernelAnalysisEventLayout layout) {
-            fLayout = layout;
-        }
-    }
-
-    /**
-     * Event aspects available for all Lttng Kernel traces
-     */
-    private static final @NonNull Collection<ITmfEventAspect> LTTNG_KERNEL_ASPECTS;
-
-    static {
-        ImmutableSet.Builder<ITmfEventAspect> builder = ImmutableSet.builder();
-        builder.addAll(CtfTmfTrace.CTF_ASPECTS);
-        builder.add(KernelTidAspect.INSTANCE);
-        builder.add(ThreadPriorityAspect.INSTANCE);
-        LTTNG_KERNEL_ASPECTS = NonNullUtils.checkNotNull(builder.build());
-    }
-
-    /**
-     * CTF metadata identifies trace type and tracer version pretty well, we are
-     * quite confident in the inferred trace type.
-     */
-    private static final int CONFIDENCE = 100;
-
-    /** The tracer which originated this trace */
-    private OriginTracer fOriginTracer = null;
-
-    /**
-     * Default constructor
-     */
-    public LttngKernelTrace() {
-        super();
-    }
-
-    @Override
-    public @NonNull IKernelAnalysisEventLayout getKernelEventLayout() {
-        OriginTracer tracer = fOriginTracer;
-        if (tracer == null) {
-            throw new IllegalStateException("Cannot get the layout of a non-initialized trace!"); //$NON-NLS-1$
-        }
-        return tracer.fLayout;
-    }
-
-    @Override
-    public void initTrace(IResource resource, String path,
-            Class<? extends ITmfEvent> eventType) throws TmfTraceException {
-        super.initTrace(resource, path, eventType);
-        fOriginTracer = getTracerFromEnv(this.getEnvironment());
-    }
-
-    /**
-     * Identify which tracer generated a trace from its metadata.
-     */
-    private static OriginTracer getTracerFromEnv(Map<String, String> traceEnv) {
-        String tracerName = traceEnv.get("tracer_name"); //$NON-NLS-1$
-        String tracerMajor = traceEnv.get("tracer_major"); //$NON-NLS-1$
-        String tracerMinor = traceEnv.get("tracer_minor"); //$NON-NLS-1$
-
-        if ("\"perf\"".equals(tracerName)) { //$NON-NLS-1$
-            return OriginTracer.PERF;
-
-        } else if ("\"lttng-modules\"".equals(tracerName) && tracerMajor != null && tracerMinor != null) { //$NON-NLS-1$
-            /* Look for specific versions of LTTng */
-            if (Integer.valueOf(tracerMajor) >= 2) {
-                if (Integer.valueOf(tracerMinor) >= 7) {
-                    return OriginTracer.LTTNG27;
-                } else if (Integer.valueOf(tracerMinor) >= 6) {
-                    return OriginTracer.LTTNG26;
-                }
-            }
-        }
-
-        /* Use base LTTng layout as default */
-        return OriginTracer.LTTNG;
-    }
-
-    /**
-     * {@inheritDoc}
-     * <p>
-     * This implementation sets the confidence to 100 if the trace is a valid
-     * CTF trace in the "kernel" domain.
-     */
-    @Override
-    public IStatus validate(final IProject project, final String path) {
-        IStatus status = super.validate(project, path);
-        if (status instanceof CtfTraceValidationStatus) {
-            Map<String, String> environment = ((CtfTraceValidationStatus) status).getEnvironment();
-            /* Make sure the domain is "kernel" in the trace's env vars */
-            String domain = environment.get("domain"); //$NON-NLS-1$
-            if (domain == null || !domain.equals("\"kernel\"")) { //$NON-NLS-1$
-                return new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.LttngKernelTrace_DomainError);
-            }
-            return new TraceValidationStatus(CONFIDENCE, Activator.PLUGIN_ID);
-        }
-        return status;
-    }
-
-    @Override
-    public Iterable<ITmfEventAspect> getEventAspects() {
-         return LTTNG_KERNEL_ASPECTS;
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/lttng2/kernel/core/trace/Messages.java b/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/lttng2/kernel/core/trace/Messages.java
deleted file mode 100644 (file)
index e5751fd..0000000
+++ /dev/null
@@ -1,45 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2013, 2014 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:
- *     Matthew Khouzam - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.kernel.core.trace;
-
-import org.eclipse.osgi.util.NLS;
-
-/**
- * Message bundle for lttng2.kernel.core.trace
- *
- * @author Matthew Khouzam
- */
-public class Messages extends NLS {
-
-    private static final String BUNDLE_NAME = "org.eclipse.tracecompass.lttng2.kernel.core.trace.messages"; //$NON-NLS-1$
-
-    /**
-     * The domain is not "kernel"
-     */
-    public static String LttngKernelTrace_DomainError;
-    /**
-     * Malformed trace (buffer overflow maybe?)
-     */
-    public static String LttngKernelTrace_MalformedTrace;
-    /**
-     * Trace read error
-     */
-    public static String LttngKernelTrace_TraceReadError;
-
-    static {
-        // initialize resource bundle
-        NLS.initializeMessages(BUNDLE_NAME, Messages.class);
-    }
-
-    private Messages() {
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/lttng2/kernel/core/trace/messages.properties b/org.eclipse.tracecompass.lttng2.kernel.core/src/org/eclipse/tracecompass/lttng2/kernel/core/trace/messages.properties
deleted file mode 100644 (file)
index 290c225..0000000
+++ /dev/null
@@ -1,15 +0,0 @@
-###############################################################################
-# Copyright (c) 2013, 2014 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:
-#     Ericsson - Initial API and implementation
-###############################################################################
-
-LttngKernelTrace_DomainError=Domain mismatch, the environment should be 'kernel'.
-LttngKernelTrace_MalformedTrace=Buffer overflow exception, trace is malformed
-LttngKernelTrace_TraceReadError=Lttng trace read error
diff --git a/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.classpath b/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.classpath
deleted file mode 100644 (file)
index 3bc2475..0000000
+++ /dev/null
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
-       <classpathentry kind="src" path="src"/>
-       <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7"/>
-       <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
-       <classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.gitignore b/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.gitignore
deleted file mode 100644 (file)
index 750e145..0000000
+++ /dev/null
@@ -1 +0,0 @@
-screenshots/
diff --git a/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.project b/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.project
deleted file mode 100644 (file)
index 2955b91..0000000
+++ /dev/null
@@ -1,34 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
-       <name>org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests</name>
-       <comment></comment>
-       <projects>
-       </projects>
-       <buildSpec>
-               <buildCommand>
-                       <name>org.eclipse.jdt.core.javabuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-               <buildCommand>
-                       <name>org.eclipse.pde.ManifestBuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-               <buildCommand>
-                       <name>org.eclipse.pde.SchemaBuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-               <buildCommand>
-                       <name>org.eclipse.pde.api.tools.apiAnalysisBuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-       </buildSpec>
-       <natures>
-               <nature>org.eclipse.jdt.core.javanature</nature>
-               <nature>org.eclipse.pde.PluginNature</nature>
-               <nature>org.eclipse.pde.api.tools.apiAnalysisNature</nature>
-       </natures>
-</projectDescription>
diff --git a/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.settings/org.eclipse.core.resources.prefs b/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.settings/org.eclipse.core.resources.prefs
deleted file mode 100644 (file)
index 99f26c0..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-eclipse.preferences.version=1
-encoding/<project>=UTF-8
diff --git a/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.settings/org.eclipse.core.runtime.prefs b/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.settings/org.eclipse.core.runtime.prefs
deleted file mode 100644 (file)
index 5a0ad22..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-eclipse.preferences.version=1
-line.separator=\n
diff --git a/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.settings/org.eclipse.jdt.core.prefs b/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.settings/org.eclipse.jdt.core.prefs
deleted file mode 100644 (file)
index 0409c61..0000000
+++ /dev/null
@@ -1,403 +0,0 @@
-eclipse.preferences.version=1
-org.eclipse.jdt.core.codeComplete.argumentPrefixes=
-org.eclipse.jdt.core.codeComplete.argumentSuffixes=
-org.eclipse.jdt.core.codeComplete.fieldPrefixes=f
-org.eclipse.jdt.core.codeComplete.fieldSuffixes=
-org.eclipse.jdt.core.codeComplete.localPrefixes=
-org.eclipse.jdt.core.codeComplete.localSuffixes=
-org.eclipse.jdt.core.codeComplete.staticFieldPrefixes=
-org.eclipse.jdt.core.codeComplete.staticFieldSuffixes=
-org.eclipse.jdt.core.codeComplete.staticFinalFieldPrefixes=
-org.eclipse.jdt.core.codeComplete.staticFinalFieldSuffixes=
-org.eclipse.jdt.core.compiler.annotation.inheritNullAnnotations=enabled
-org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore
-org.eclipse.jdt.core.compiler.annotation.nonnull=org.eclipse.jdt.annotation.NonNull
-org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=org.eclipse.jdt.annotation.NonNullByDefault
-org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nullable
-org.eclipse.jdt.core.compiler.annotation.nullanalysis=enabled
-org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
-org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
-org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
-org.eclipse.jdt.core.compiler.compliance=1.7
-org.eclipse.jdt.core.compiler.debug.lineNumber=generate
-org.eclipse.jdt.core.compiler.debug.localVariable=generate
-org.eclipse.jdt.core.compiler.debug.sourceFile=generate
-org.eclipse.jdt.core.compiler.doc.comment.support=enabled
-org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=error
-org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
-org.eclipse.jdt.core.compiler.problem.autoboxing=ignore
-org.eclipse.jdt.core.compiler.problem.comparingIdentical=error
-org.eclipse.jdt.core.compiler.problem.deadCode=error
-org.eclipse.jdt.core.compiler.problem.deprecation=error
-org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled
-org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=enabled
-org.eclipse.jdt.core.compiler.problem.discouragedReference=error
-org.eclipse.jdt.core.compiler.problem.emptyStatement=error
-org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
-org.eclipse.jdt.core.compiler.problem.explicitlyClosedAutoCloseable=error
-org.eclipse.jdt.core.compiler.problem.fallthroughCase=error
-org.eclipse.jdt.core.compiler.problem.fatalOptionalError=disabled
-org.eclipse.jdt.core.compiler.problem.fieldHiding=error
-org.eclipse.jdt.core.compiler.problem.finalParameterBound=error
-org.eclipse.jdt.core.compiler.problem.finallyBlockNotCompletingNormally=error
-org.eclipse.jdt.core.compiler.problem.forbiddenReference=error
-org.eclipse.jdt.core.compiler.problem.hiddenCatchBlock=error
-org.eclipse.jdt.core.compiler.problem.includeNullInfoFromAsserts=disabled
-org.eclipse.jdt.core.compiler.problem.incompatibleNonInheritedInterfaceMethod=error
-org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch=error
-org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=error
-org.eclipse.jdt.core.compiler.problem.invalidJavadoc=warning
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTags=enabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsDeprecatedRef=enabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsNotVisibleRef=enabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsVisibility=protected
-org.eclipse.jdt.core.compiler.problem.localVariableHiding=error
-org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=error
-org.eclipse.jdt.core.compiler.problem.missingDefaultCase=error
-org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=error
-org.eclipse.jdt.core.compiler.problem.missingEnumCaseDespiteDefault=enabled
-org.eclipse.jdt.core.compiler.problem.missingHashCodeMethod=error
-org.eclipse.jdt.core.compiler.problem.missingJavadocComments=warning
-org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsOverriding=disabled
-org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsVisibility=protected
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagDescription=all_standard_tags
-org.eclipse.jdt.core.compiler.problem.missingJavadocTags=warning
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagsMethodTypeParameters=disabled
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagsOverriding=disabled
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagsVisibility=protected
-org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotation=error
-org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotationForInterfaceMethodImplementation=enabled
-org.eclipse.jdt.core.compiler.problem.missingSerialVersion=error
-org.eclipse.jdt.core.compiler.problem.missingSynchronizedOnInheritedMethod=error
-org.eclipse.jdt.core.compiler.problem.noEffectAssignment=error
-org.eclipse.jdt.core.compiler.problem.noImplicitStringConversion=error
-org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=ignore
-org.eclipse.jdt.core.compiler.problem.nonnullParameterAnnotationDropped=warning
-org.eclipse.jdt.core.compiler.problem.nullAnnotationInferenceConflict=warning
-org.eclipse.jdt.core.compiler.problem.nullReference=error
-org.eclipse.jdt.core.compiler.problem.nullSpecViolation=error
-org.eclipse.jdt.core.compiler.problem.nullUncheckedConversion=warning
-org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=error
-org.eclipse.jdt.core.compiler.problem.parameterAssignment=error
-org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=error
-org.eclipse.jdt.core.compiler.problem.potentialNullReference=error
-org.eclipse.jdt.core.compiler.problem.potentiallyUnclosedCloseable=warning
-org.eclipse.jdt.core.compiler.problem.rawTypeReference=error
-org.eclipse.jdt.core.compiler.problem.redundantNullAnnotation=warning
-org.eclipse.jdt.core.compiler.problem.redundantNullCheck=error
-org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=error
-org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=error
-org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore
-org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=error
-org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled
-org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=error
-org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=disabled
-org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled
-org.eclipse.jdt.core.compiler.problem.syntacticNullAnalysisForFields=enabled
-org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=ignore
-org.eclipse.jdt.core.compiler.problem.typeParameterHiding=error
-org.eclipse.jdt.core.compiler.problem.unavoidableGenericTypeProblems=disabled
-org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=error
-org.eclipse.jdt.core.compiler.problem.unclosedCloseable=error
-org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=ignore
-org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=error
-org.eclipse.jdt.core.compiler.problem.unnecessaryElse=error
-org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=error
-org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=error
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionExemptExceptionAndThrowable=disabled
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionIncludeDocCommentReference=disabled
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverriding=disabled
-org.eclipse.jdt.core.compiler.problem.unusedImport=error
-org.eclipse.jdt.core.compiler.problem.unusedLabel=error
-org.eclipse.jdt.core.compiler.problem.unusedLocal=error
-org.eclipse.jdt.core.compiler.problem.unusedObjectAllocation=ignore
-org.eclipse.jdt.core.compiler.problem.unusedParameter=ignore
-org.eclipse.jdt.core.compiler.problem.unusedParameterIncludeDocCommentReference=enabled
-org.eclipse.jdt.core.compiler.problem.unusedParameterWhenImplementingAbstract=disabled
-org.eclipse.jdt.core.compiler.problem.unusedParameterWhenOverridingConcrete=disabled
-org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=error
-org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=ignore
-org.eclipse.jdt.core.compiler.problem.unusedWarningToken=error
-org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=error
-org.eclipse.jdt.core.compiler.source=1.7
-org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_call=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression=16
-org.eclipse.jdt.core.formatter.alignment_for_assignment=0
-org.eclipse.jdt.core.formatter.alignment_for_binary_expression=16
-org.eclipse.jdt.core.formatter.alignment_for_compact_if=16
-org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=80
-org.eclipse.jdt.core.formatter.alignment_for_enum_constants=0
-org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=16
-org.eclipse.jdt.core.formatter.alignment_for_method_declaration=0
-org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16
-org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=80
-org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation=0
-org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_constructor_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_method_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_union_type_in_multicatch=16
-org.eclipse.jdt.core.formatter.blank_lines_after_imports=1
-org.eclipse.jdt.core.formatter.blank_lines_after_package=1
-org.eclipse.jdt.core.formatter.blank_lines_before_field=0
-org.eclipse.jdt.core.formatter.blank_lines_before_first_class_body_declaration=0
-org.eclipse.jdt.core.formatter.blank_lines_before_imports=1
-org.eclipse.jdt.core.formatter.blank_lines_before_member_type=1
-org.eclipse.jdt.core.formatter.blank_lines_before_method=1
-org.eclipse.jdt.core.formatter.blank_lines_before_new_chunk=1
-org.eclipse.jdt.core.formatter.blank_lines_before_package=0
-org.eclipse.jdt.core.formatter.blank_lines_between_import_groups=1
-org.eclipse.jdt.core.formatter.blank_lines_between_type_declarations=1
-org.eclipse.jdt.core.formatter.brace_position_for_annotation_type_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_array_initializer=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_block=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_block_in_case=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_constructor_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_enum_constant=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_enum_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_method_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_switch=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_type_declaration=end_of_line
-org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_block_comment=false
-org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_javadoc_comment=false
-org.eclipse.jdt.core.formatter.comment.format_block_comments=true
-org.eclipse.jdt.core.formatter.comment.format_header=false
-org.eclipse.jdt.core.formatter.comment.format_html=true
-org.eclipse.jdt.core.formatter.comment.format_javadoc_comments=true
-org.eclipse.jdt.core.formatter.comment.format_line_comments=true
-org.eclipse.jdt.core.formatter.comment.format_source_code=true
-org.eclipse.jdt.core.formatter.comment.indent_parameter_description=true
-org.eclipse.jdt.core.formatter.comment.indent_root_tags=true
-org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags=insert
-org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter=insert
-org.eclipse.jdt.core.formatter.comment.line_length=80
-org.eclipse.jdt.core.formatter.comment.new_lines_at_block_boundaries=true
-org.eclipse.jdt.core.formatter.comment.new_lines_at_javadoc_boundaries=true
-org.eclipse.jdt.core.formatter.comment.preserve_white_space_between_code_and_line_comments=false
-org.eclipse.jdt.core.formatter.compact_else_if=true
-org.eclipse.jdt.core.formatter.continuation_indentation=2
-org.eclipse.jdt.core.formatter.continuation_indentation_for_array_initializer=2
-org.eclipse.jdt.core.formatter.disabling_tag=@formatter\:off
-org.eclipse.jdt.core.formatter.enabling_tag=@formatter\:on
-org.eclipse.jdt.core.formatter.format_guardian_clause_on_one_line=false
-org.eclipse.jdt.core.formatter.format_line_comment_starting_on_first_column=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_annotation_declaration_header=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_constant_header=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_declaration_header=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_type_header=true
-org.eclipse.jdt.core.formatter.indent_breaks_compare_to_cases=true
-org.eclipse.jdt.core.formatter.indent_empty_lines=false
-org.eclipse.jdt.core.formatter.indent_statements_compare_to_block=true
-org.eclipse.jdt.core.formatter.indent_statements_compare_to_body=true
-org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_cases=true
-org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_switch=false
-org.eclipse.jdt.core.formatter.indentation.size=4
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_field=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_local_variable=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_method=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_package=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_parameter=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_type=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_label=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_opening_brace_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_at_end_of_file_if_missing=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_finally_in_try_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_while_in_do_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_annotation_declaration=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_anonymous_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_block=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter=insert
-org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_binary_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_paren_in_cast=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_assert=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_case=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_labeled_statement=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_allocation_expression=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_annotation=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_throws=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_constant_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_declarations=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_explicitconstructorcall_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_increments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_inits=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_throws=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_invocation_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_field_declarations=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_local_declarations=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_parameterized_type_reference=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_superinterfaces=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_ellipsis=insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_brace_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_cast=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_catch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_for=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_if=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_parenthesized_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_switch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_synchronized=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_try=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_while=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_try_resources=insert
-org.eclipse.jdt.core.formatter.insert_space_after_unary_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter=insert
-org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_binary_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_brace_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_cast=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_catch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_for=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_if=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_parenthesized_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_switch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_synchronized=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_try=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_while=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_assert=insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_case=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_default=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_labeled_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_throws=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_constant_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_declarations=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_explicitconstructorcall_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_increments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_inits=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_throws=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_invocation_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_field_declarations=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_local_declarations=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_superinterfaces=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_ellipsis=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_annotation_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_anonymous_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_block=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_constructor_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_constant=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_method_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_switch=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation_type_member_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_catch=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_if=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_parenthesized_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_switch=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_synchronized=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_try=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_while=insert
-org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_return=insert
-org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_throw=insert
-org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_semicolon=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_try_resources=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_unary_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_brackets_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_annotation_type_member_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.join_lines_in_comments=true
-org.eclipse.jdt.core.formatter.join_wrapped_lines=false
-org.eclipse.jdt.core.formatter.keep_else_statement_on_same_line=false
-org.eclipse.jdt.core.formatter.keep_empty_array_initializer_on_one_line=false
-org.eclipse.jdt.core.formatter.keep_imple_if_on_one_line=false
-org.eclipse.jdt.core.formatter.keep_then_statement_on_same_line=false
-org.eclipse.jdt.core.formatter.lineSplit=250
-org.eclipse.jdt.core.formatter.never_indent_block_comments_on_first_column=false
-org.eclipse.jdt.core.formatter.never_indent_line_comments_on_first_column=false
-org.eclipse.jdt.core.formatter.number_of_blank_lines_at_beginning_of_method_body=0
-org.eclipse.jdt.core.formatter.number_of_empty_lines_to_preserve=1
-org.eclipse.jdt.core.formatter.put_empty_statement_on_new_line=true
-org.eclipse.jdt.core.formatter.tabulation.char=space
-org.eclipse.jdt.core.formatter.tabulation.size=4
-org.eclipse.jdt.core.formatter.use_on_off_tags=false
-org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false
-org.eclipse.jdt.core.formatter.wrap_before_binary_operator=true
-org.eclipse.jdt.core.formatter.wrap_before_or_operator_multicatch=true
-org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true
diff --git a/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.settings/org.eclipse.jdt.ui.prefs b/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.settings/org.eclipse.jdt.ui.prefs
deleted file mode 100644 (file)
index 232a3fd..0000000
+++ /dev/null
@@ -1,60 +0,0 @@
-eclipse.preferences.version=1
-editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true
-formatter_profile=_tmf-style
-formatter_settings_version=12
-org.eclipse.jdt.ui.exception.name=e
-org.eclipse.jdt.ui.gettersetter.use.is=true
-org.eclipse.jdt.ui.keywordthis=false
-org.eclipse.jdt.ui.overrideannotation=true
-sp_cleanup.add_default_serial_version_id=true
-sp_cleanup.add_generated_serial_version_id=false
-sp_cleanup.add_missing_annotations=false
-sp_cleanup.add_missing_deprecated_annotations=true
-sp_cleanup.add_missing_methods=false
-sp_cleanup.add_missing_nls_tags=false
-sp_cleanup.add_missing_override_annotations=true
-sp_cleanup.add_missing_override_annotations_interface_methods=true
-sp_cleanup.add_serial_version_id=false
-sp_cleanup.always_use_blocks=true
-sp_cleanup.always_use_parentheses_in_expressions=false
-sp_cleanup.always_use_this_for_non_static_field_access=false
-sp_cleanup.always_use_this_for_non_static_method_access=false
-sp_cleanup.convert_to_enhanced_for_loop=false
-sp_cleanup.correct_indentation=false
-sp_cleanup.format_source_code=false
-sp_cleanup.format_source_code_changes_only=false
-sp_cleanup.make_local_variable_final=false
-sp_cleanup.make_parameters_final=false
-sp_cleanup.make_private_fields_final=true
-sp_cleanup.make_type_abstract_if_missing_method=false
-sp_cleanup.make_variable_declarations_final=false
-sp_cleanup.never_use_blocks=false
-sp_cleanup.never_use_parentheses_in_expressions=true
-sp_cleanup.on_save_use_additional_actions=true
-sp_cleanup.organize_imports=false
-sp_cleanup.qualify_static_field_accesses_with_declaring_class=false
-sp_cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=true
-sp_cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=true
-sp_cleanup.qualify_static_member_accesses_with_declaring_class=false
-sp_cleanup.qualify_static_method_accesses_with_declaring_class=false
-sp_cleanup.remove_private_constructors=true
-sp_cleanup.remove_trailing_whitespaces=true
-sp_cleanup.remove_trailing_whitespaces_all=true
-sp_cleanup.remove_trailing_whitespaces_ignore_empty=false
-sp_cleanup.remove_unnecessary_casts=false
-sp_cleanup.remove_unnecessary_nls_tags=false
-sp_cleanup.remove_unused_imports=false
-sp_cleanup.remove_unused_local_variables=false
-sp_cleanup.remove_unused_private_fields=true
-sp_cleanup.remove_unused_private_members=false
-sp_cleanup.remove_unused_private_methods=true
-sp_cleanup.remove_unused_private_types=true
-sp_cleanup.sort_members=false
-sp_cleanup.sort_members_all=false
-sp_cleanup.use_blocks=true
-sp_cleanup.use_blocks_only_for_return_and_throw=false
-sp_cleanup.use_parentheses_in_expressions=false
-sp_cleanup.use_this_for_non_static_field_access=false
-sp_cleanup.use_this_for_non_static_field_access_only_if_necessary=true
-sp_cleanup.use_this_for_non_static_method_access=false
-sp_cleanup.use_this_for_non_static_method_access_only_if_necessary=true
diff --git a/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.settings/org.eclipse.pde.api.tools.prefs b/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.settings/org.eclipse.pde.api.tools.prefs
deleted file mode 100644 (file)
index acc3abd..0000000
+++ /dev/null
@@ -1,97 +0,0 @@
-ANNOTATION_ELEMENT_TYPE_ADDED_METHOD_WITHOUT_DEFAULT_VALUE=Error
-ANNOTATION_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-ANNOTATION_ELEMENT_TYPE_REMOVED_FIELD=Error
-ANNOTATION_ELEMENT_TYPE_REMOVED_METHOD=Error
-ANNOTATION_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_API_TYPE=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_API_TYPE=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_TYPE=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_TYPE=Error
-API_USE_SCAN_FIELD_SEVERITY=Error
-API_USE_SCAN_METHOD_SEVERITY=Error
-API_USE_SCAN_TYPE_SEVERITY=Error
-CLASS_ELEMENT_TYPE_ADDED_METHOD=Error
-CLASS_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
-CLASS_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-CLASS_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
-CLASS_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-CLASS_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
-CLASS_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
-CLASS_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-CLASS_ELEMENT_TYPE_REMOVED_CONSTRUCTOR=Error
-CLASS_ELEMENT_TYPE_REMOVED_FIELD=Error
-CLASS_ELEMENT_TYPE_REMOVED_METHOD=Error
-CLASS_ELEMENT_TYPE_REMOVED_SUPERCLASS=Error
-CLASS_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-CLASS_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-CONSTRUCTOR_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-CONSTRUCTOR_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-CONSTRUCTOR_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
-CONSTRUCTOR_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-ENUM_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
-ENUM_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-ENUM_ELEMENT_TYPE_REMOVED_ENUM_CONSTANT=Error
-ENUM_ELEMENT_TYPE_REMOVED_FIELD=Error
-ENUM_ELEMENT_TYPE_REMOVED_METHOD=Error
-ENUM_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-FIELD_ELEMENT_TYPE_ADDED_VALUE=Error
-FIELD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-FIELD_ELEMENT_TYPE_CHANGED_FINAL_TO_NON_FINAL_STATIC_CONSTANT=Error
-FIELD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
-FIELD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
-FIELD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
-FIELD_ELEMENT_TYPE_CHANGED_TYPE=Error
-FIELD_ELEMENT_TYPE_CHANGED_VALUE=Error
-FIELD_ELEMENT_TYPE_REMOVED_TYPE_ARGUMENT=Error
-FIELD_ELEMENT_TYPE_REMOVED_VALUE=Error
-ILLEGAL_EXTEND=Warning
-ILLEGAL_IMPLEMENT=Warning
-ILLEGAL_INSTANTIATE=Warning
-ILLEGAL_OVERRIDE=Warning
-ILLEGAL_REFERENCE=Warning
-INTERFACE_ELEMENT_TYPE_ADDED_FIELD=Error
-INTERFACE_ELEMENT_TYPE_ADDED_METHOD=Error
-INTERFACE_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
-INTERFACE_ELEMENT_TYPE_ADDED_SUPER_INTERFACE_WITH_METHODS=Error
-INTERFACE_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-INTERFACE_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
-INTERFACE_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_FIELD=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_METHOD=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-INVALID_JAVADOC_TAG=Warning
-INVALID_REFERENCE_IN_SYSTEM_LIBRARIES=Warning
-LEAK_EXTEND=Warning
-LEAK_FIELD_DECL=Warning
-LEAK_IMPLEMENT=Warning
-LEAK_METHOD_PARAM=Warning
-LEAK_METHOD_RETURN_TYPE=Warning
-METHOD_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
-METHOD_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-METHOD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-METHOD_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
-METHOD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
-METHOD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
-METHOD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
-METHOD_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
-METHOD_ELEMENT_TYPE_REMOVED_ANNOTATION_DEFAULT_VALUE=Error
-METHOD_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-MISSING_EE_DESCRIPTIONS=Ignore
-TYPE_PARAMETER_ELEMENT_TYPE_ADDED_CLASS_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_ADDED_INTERFACE_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_CLASS_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_INTERFACE_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_CLASS_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_INTERFACE_BOUND=Error
-UNUSED_PROBLEM_FILTERS=Warning
-automatically_removed_unused_problem_filters=false
-eclipse.preferences.version=1
-incompatible_api_component_version=Error
-incompatible_api_component_version_include_major_without_breaking_change=Disabled
-incompatible_api_component_version_include_minor_without_api_change=Disabled
-invalid_since_tag_version=Error
-malformed_since_tag=Error
-missing_since_tag=Error
-report_api_breakage_when_major_version_incremented=Disabled
-report_resolution_errors_api_component=Warning
diff --git a/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.settings/org.eclipse.pde.prefs b/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/.settings/org.eclipse.pde.prefs
deleted file mode 100644 (file)
index 62cfa90..0000000
+++ /dev/null
@@ -1,32 +0,0 @@
-compilers.f.unresolved-features=1
-compilers.f.unresolved-plugins=1
-compilers.incompatible-environment=1
-compilers.p.build=1
-compilers.p.build.bin.includes=1
-compilers.p.build.encodings=2
-compilers.p.build.java.compiler=2
-compilers.p.build.java.compliance=1
-compilers.p.build.missing.output=2
-compilers.p.build.output.library=1
-compilers.p.build.source.library=1
-compilers.p.build.src.includes=1
-compilers.p.deprecated=1
-compilers.p.discouraged-class=1
-compilers.p.internal=1
-compilers.p.missing-packages=2
-compilers.p.missing-version-export-package=2
-compilers.p.missing-version-import-package=2
-compilers.p.missing-version-require-bundle=2
-compilers.p.no-required-att=0
-compilers.p.not-externalized-att=2
-compilers.p.unknown-attribute=1
-compilers.p.unknown-class=1
-compilers.p.unknown-element=1
-compilers.p.unknown-identifier=1
-compilers.p.unknown-resource=1
-compilers.p.unresolved-ex-points=0
-compilers.p.unresolved-import=0
-compilers.s.create-docs=false
-compilers.s.doc-folder=doc
-compilers.s.open-tags=1
-eclipse.preferences.version=1
diff --git a/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/META-INF/MANIFEST.MF b/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/META-INF/MANIFEST.MF
deleted file mode 100644 (file)
index 69db396..0000000
+++ /dev/null
@@ -1,29 +0,0 @@
-Manifest-Version: 1.0
-Bundle-ManifestVersion: 2
-Bundle-Name: %Bundle-Name
-Bundle-Vendor: %Bundle-Vendor
-Bundle-Version: 1.0.0.qualifier
-Bundle-Localization: plugin
-Bundle-SymbolicName: org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests;singleton:=true
-Bundle-ActivationPolicy: lazy
-Bundle-RequiredExecutionEnvironment: JavaSE-1.7
-Export-Package: org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests
-Require-Bundle: org.apache.log4j,
- org.eclipse.core.resources,
- org.eclipse.core.runtime,
- org.eclipse.tracecompass.lttng2.kernel.core,
- org.eclipse.tracecompass.lttng2.kernel.ui,
- org.eclipse.tracecompass.lttng2.control.ui,
- org.eclipse.tracecompass.analysis.os.linux.ui,
- org.eclipse.tracecompass.tmf.core,
- org.eclipse.tracecompass.tmf.core.tests,
- org.eclipse.tracecompass.tmf.ctf.core,
- org.eclipse.tracecompass.tmf.ctf.core.tests,
- org.eclipse.tracecompass.tmf.ui,
- org.eclipse.tracecompass.tmf.ui.swtbot.tests,
- org.eclipse.swtbot.eclipse.finder,
- org.eclipse.swtbot.junit4_x,
- org.eclipse.ui,
- org.eclipse.ui.ide,
- org.eclipse.ui.views,
- org.junit
diff --git a/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/about.html b/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/about.html
deleted file mode 100644 (file)
index c258ef5..0000000
+++ /dev/null
@@ -1,28 +0,0 @@
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
-    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml">
-<head>
-<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"/>
-<title>About</title>
-</head>
-<body lang="EN-US">
-<h2>About This Content</h2>
-<p>June 5, 2006</p>    
-<h3>License</h3>
-
-<p>The Eclipse Foundation makes available all content in this plug-in (&quot;Content&quot;).  Unless otherwise 
-indicated below, the Content is provided to you under the terms and conditions of the
-Eclipse Public License Version 1.0 (&quot;EPL&quot;).  A copy of the EPL is available 
-at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>.
-For purposes of the EPL, &quot;Program&quot; will mean the Content.</p>
-
-<p>If you did not receive this Content directly from the Eclipse Foundation, the Content is 
-being redistributed by another party (&quot;Redistributor&quot;) and different terms and conditions may
-apply to your use of any object code in the Content.  Check the Redistributor's license that was 
-provided with the Content.  If no such license exists, contact the Redistributor.  Unless otherwise
-indicated below, the terms and conditions of the EPL still apply to any source code in the Content
-and such source code may be obtained at <a href="http://www.eclipse.org/">http://www.eclipse.org</a>.</p>
-
-</body>
-</html>
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/build.properties b/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/build.properties
deleted file mode 100644 (file)
index cee367f..0000000
+++ /dev/null
@@ -1,19 +0,0 @@
-###############################################################################
-# Copyright (c) 2014, 2015 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:
-#    Ericsson - Initial API and implementation
-###############################################################################
-
-source.. = src/
-bin.includes = META-INF/,\
-               .,\
-               plugin.properties,\
-               about.html
-additional.bundles = org.eclipse.jdt.annotation
-jars.extra.classpath = platform:/plugin/org.eclipse.jdt.annotation
diff --git a/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/plugin.properties b/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/plugin.properties
deleted file mode 100644 (file)
index 2e8033d..0000000
+++ /dev/null
@@ -1,14 +0,0 @@
-###############################################################################
-# Copyright (c) 2013, 2014 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:
-#     Ericsson - Initial API and implementation
-###############################################################################
-
-Bundle-Vendor = Eclipse Trace Compass
-Bundle-Name = Trace Compass LTTng Kernel UI SWTBot Tests Plug-in
diff --git a/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/pom.xml b/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/pom.xml
deleted file mode 100644 (file)
index 225bc43..0000000
+++ /dev/null
@@ -1,50 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-   Copyright (C) 2013 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
--->
-
-<project xmlns="http://maven.apache.org/POM/4.0.0"
-    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-    xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
-  <modelVersion>4.0.0</modelVersion>
-
-  <parent>
-    <artifactId>org.eclipse.tracecompass</artifactId>
-    <groupId>org.eclipse.tracecompass</groupId>
-    <version>1.0.0-SNAPSHOT</version>
-  </parent>
-
-  <artifactId>org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests</artifactId>
-  <version>1.0.0-SNAPSHOT</version>
-  <packaging>eclipse-test-plugin</packaging>
-
-  <name>Trace Compass LTTng Kernel UI SWTBot Tests Plug-in</name>
-
-  <build>
-    <plugins>
-      <plugin>
-        <groupId>org.eclipse.tycho</groupId>
-        <artifactId>tycho-surefire-plugin</artifactId>
-        <version>${tycho-version}</version>
-        <configuration>
-          <testSuite>org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests</testSuite>
-          <testClass>org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests.AllTests</testClass>
-          <useUIHarness>true</useUIHarness>
-          <useUIThread>false</useUIThread>
-          <argLine>${tycho.testArgLine} ${base.ui.test.vmargs}</argLine>
-          <product>org.eclipse.platform.ide</product>
-          <environmentVariables>
-            <SWT_GTK3>${SWT_GTK3}</SWT_GTK3>
-          </environmentVariables>
-        </configuration>
-      </plugin>
-    </plugins>
-  </build>
-
- <groupId>org.eclipse.tracecompass</groupId>
-</project>
diff --git a/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/src/org/eclipse/tracecompass/lttng2/kernel/ui/swtbot/tests/AllTests.java b/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/src/org/eclipse/tracecompass/lttng2/kernel/ui/swtbot/tests/AllTests.java
deleted file mode 100644 (file)
index 8a78de8..0000000
+++ /dev/null
@@ -1,30 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2013, 2015 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:
- *   Matthew Khouzam - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests;
-
-import org.junit.runner.RunWith;
-import org.junit.runners.Suite;
-
-/**
- * Test suite for UI on the lttng kernel perspective
- */
-@RunWith(Suite.class)
-@Suite.SuiteClasses({
-    KernelPerspectiveChecker.class,
-    ImportAndReadKernelSmokeTest.class,
-    ControlFlowViewTest.class,
-    OpenTraceStressTest.class
-})
-public class AllTests {
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/src/org/eclipse/tracecompass/lttng2/kernel/ui/swtbot/tests/ControlFlowViewTest.java b/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/src/org/eclipse/tracecompass/lttng2/kernel/ui/swtbot/tests/ControlFlowViewTest.java
deleted file mode 100644 (file)
index a84ad87..0000000
+++ /dev/null
@@ -1,341 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2015 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:
- *   Patrick Tasse - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests;
-
-import static org.junit.Assert.assertTrue;
-
-import java.util.List;
-
-import org.eclipse.jdt.annotation.NonNull;
-import org.eclipse.swt.SWT;
-import org.eclipse.swtbot.eclipse.finder.widgets.SWTBotView;
-import org.eclipse.swtbot.swt.finder.finders.UIThreadRunnable;
-import org.eclipse.swtbot.swt.finder.keyboard.Keyboard;
-import org.eclipse.swtbot.swt.finder.keyboard.KeyboardFactory;
-import org.eclipse.swtbot.swt.finder.keyboard.Keystrokes;
-import org.eclipse.swtbot.swt.finder.matchers.WidgetOfType;
-import org.eclipse.swtbot.swt.finder.results.VoidResult;
-import org.eclipse.swtbot.swt.finder.waits.DefaultCondition;
-import org.eclipse.swtbot.swt.finder.widgets.SWTBotTree;
-import org.eclipse.tracecompass.tmf.core.signal.TmfSelectionRangeUpdatedSignal;
-import org.eclipse.tracecompass.tmf.core.signal.TmfSignalManager;
-import org.eclipse.tracecompass.tmf.core.signal.TmfWindowRangeUpdatedSignal;
-import org.eclipse.tracecompass.tmf.core.timestamp.ITmfTimestamp;
-import org.eclipse.tracecompass.tmf.core.timestamp.TmfNanoTimestamp;
-import org.eclipse.tracecompass.tmf.core.timestamp.TmfTimeRange;
-import org.eclipse.tracecompass.tmf.core.trace.TmfTraceManager;
-import org.eclipse.tracecompass.tmf.ui.swtbot.tests.shared.ConditionHelpers;
-import org.eclipse.tracecompass.tmf.ui.widgets.timegraph.model.ILinkEvent;
-import org.eclipse.tracecompass.tmf.ui.widgets.timegraph.widgets.TimeGraphControl;
-import org.junit.Before;
-import org.junit.Test;
-
-/**
- * SWTBot tests for Control Flow view
- *
- * @author Patrick Tasse
- */
-public class ControlFlowViewTest extends KernelTest {
-
-    private static final String FOLLOW_CPU_BACKWARD = "Follow CPU Backward";
-    private static final String FOLLOW_CPU_FORWARD = "Follow CPU Forward";
-    private static final String SELECT_PREVIOUS_EVENT = "Select Previous Event";
-    private static final String SELECT_NEXT_EVENT = "Select Next Event";
-    private static final Keyboard KEYBOARD = KeyboardFactory.getSWTKeyboard();
-    private static final @NonNull ITmfTimestamp START_TIME = new TmfNanoTimestamp(1368000272650993664L);
-    private static final @NonNull ITmfTimestamp TID1_TIME1 = new TmfNanoTimestamp(1368000272651208412L);
-    private static final @NonNull ITmfTimestamp TID1_TIME2 = new TmfNanoTimestamp(1368000272656147616L);
-    private static final @NonNull ITmfTimestamp TID1_TIME3 = new TmfNanoTimestamp(1368000272656362364L);
-    private static final @NonNull ITmfTimestamp TID1_TIME4 = new TmfNanoTimestamp(1368000272663234300L);
-    private static final @NonNull ITmfTimestamp TID1_TIME5 = new TmfNanoTimestamp(1368000272663449048L);
-    private static final @NonNull ITmfTimestamp TID1_TIME6 = new TmfNanoTimestamp(1368000272665596528L);
-    private static final @NonNull ITmfTimestamp TID2_TIME1 = new TmfNanoTimestamp(1368000272651852656L);
-    private static final @NonNull ITmfTimestamp TID2_TIME2 = new TmfNanoTimestamp(1368000272652067404L);
-    private static final @NonNull ITmfTimestamp TID2_TIME3 = new TmfNanoTimestamp(1368000272652282152L);
-    private static final @NonNull ITmfTimestamp TID2_TIME4 = new TmfNanoTimestamp(1368000272652496900L);
-    private static final @NonNull ITmfTimestamp TID5_TIME1 = new TmfNanoTimestamp(1368000272652496900L);
-
-    private SWTBotView fViewBot;
-
-    /**
-     * Before Test
-     */
-    @Override
-    @Before
-    public void before() {
-        super.before();
-        fViewBot = fBot.viewByTitle("Control Flow");
-    }
-
-    /**
-     * Test keyboard navigation using ARROW_RIGHT and ARROW_LEFT
-     */
-    @Test
-    public void testKeyboardLeftRight() {
-        /* change window range to 10 ms */
-        TmfTimeRange range = new TmfTimeRange(START_TIME, START_TIME.normalize(10000000L, ITmfTimestamp.NANOSECOND_SCALE));
-        TmfSignalManager.dispatchSignal(new TmfWindowRangeUpdatedSignal(this, range));
-        fBot.waitUntil(ConditionHelpers.windowRange(range));
-
-        /* set selection to trace start time */
-        TmfSignalManager.dispatchSignal(new TmfSelectionRangeUpdatedSignal(this, START_TIME));
-        fBot.waitUntil(ConditionHelpers.selectionRange(new TmfTimeRange(START_TIME, START_TIME)));
-
-        /* select first item */
-        final SWTBotTree tree = fViewBot.bot().tree();
-        tree.pressShortcut(Keystrokes.HOME);
-
-        /* set focus on time graph */
-        final TimeGraphControl timegraph = fViewBot.bot().widget(WidgetOfType.widgetOfType(TimeGraphControl.class));
-        UIThreadRunnable.syncExec(new VoidResult() {
-            @Override
-            public void run() {
-                timegraph.setFocus();
-            }
-        });
-
-        /* press ARROW_RIGHT 3 times */
-        KEYBOARD.pressShortcut(Keystrokes.RIGHT);
-        KEYBOARD.pressShortcut(Keystrokes.RIGHT);
-        KEYBOARD.pressShortcut(Keystrokes.RIGHT);
-        fBot.waitUntil(ConditionHelpers.selectionRange(new TmfTimeRange(TID1_TIME3, TID1_TIME3)));
-        assertTrue(TmfTraceManager.getInstance().getCurrentTraceContext().getWindowRange().contains(TID1_TIME3));
-
-        /* press Shift-ARROW_RIGHT 3 times */
-        KEYBOARD.pressShortcut(Keystrokes.SHIFT, Keystrokes.RIGHT);
-        KEYBOARD.pressShortcut(Keystrokes.SHIFT, Keystrokes.RIGHT);
-        KEYBOARD.pressShortcut(Keystrokes.SHIFT, Keystrokes.RIGHT);
-        fBot.waitUntil(ConditionHelpers.selectionRange(new TmfTimeRange(TID1_TIME3, TID1_TIME6)));
-        assertTrue(TmfTraceManager.getInstance().getCurrentTraceContext().getWindowRange().contains(TID1_TIME6));
-
-        /* press Shift-ARROW_LEFT 4 times */
-        KEYBOARD.pressShortcut(Keystrokes.SHIFT, Keystrokes.LEFT);
-        KEYBOARD.pressShortcut(Keystrokes.SHIFT, Keystrokes.LEFT);
-        KEYBOARD.pressShortcut(Keystrokes.SHIFT, Keystrokes.LEFT);
-        KEYBOARD.pressShortcut(Keystrokes.SHIFT, Keystrokes.LEFT);
-        fBot.waitUntil(ConditionHelpers.selectionRange(new TmfTimeRange(TID1_TIME3, TID1_TIME2)));
-        assertTrue(TmfTraceManager.getInstance().getCurrentTraceContext().getWindowRange().contains(TID1_TIME2));
-
-        /* press ARROW_RIGHT 2 times */
-        KEYBOARD.pressShortcut(Keystrokes.RIGHT);
-        KEYBOARD.pressShortcut(Keystrokes.RIGHT);
-        fBot.waitUntil(ConditionHelpers.selectionRange(new TmfTimeRange(TID1_TIME4, TID1_TIME4)));
-        assertTrue(TmfTraceManager.getInstance().getCurrentTraceContext().getWindowRange().contains(TID1_TIME4));
-
-        /* press Shift-ARROW_LEFT 3 times */
-        KEYBOARD.pressShortcut(Keystrokes.SHIFT, Keystrokes.LEFT);
-        KEYBOARD.pressShortcut(Keystrokes.SHIFT, Keystrokes.LEFT);
-        KEYBOARD.pressShortcut(Keystrokes.SHIFT, Keystrokes.LEFT);
-        fBot.waitUntil(ConditionHelpers.selectionRange(new TmfTimeRange(TID1_TIME4, TID1_TIME1)));
-        assertTrue(TmfTraceManager.getInstance().getCurrentTraceContext().getWindowRange().contains(TID1_TIME1));
-
-        /* press Shift-ARROW_RIGHT 4 times */
-        KEYBOARD.pressShortcut(Keystrokes.SHIFT, Keystrokes.RIGHT);
-        KEYBOARD.pressShortcut(Keystrokes.SHIFT, Keystrokes.RIGHT);
-        KEYBOARD.pressShortcut(Keystrokes.SHIFT, Keystrokes.RIGHT);
-        KEYBOARD.pressShortcut(Keystrokes.SHIFT, Keystrokes.RIGHT);
-        fBot.waitUntil(ConditionHelpers.selectionRange(new TmfTimeRange(TID1_TIME4, TID1_TIME5)));
-        assertTrue(TmfTraceManager.getInstance().getCurrentTraceContext().getWindowRange().contains(TID1_TIME5));
-
-        /* press ARROW_LEFT 5 times */
-        KEYBOARD.pressShortcut(Keystrokes.LEFT);
-        KEYBOARD.pressShortcut(Keystrokes.LEFT);
-        KEYBOARD.pressShortcut(Keystrokes.LEFT);
-        KEYBOARD.pressShortcut(Keystrokes.LEFT);
-        KEYBOARD.pressShortcut(Keystrokes.LEFT);
-        fBot.waitUntil(ConditionHelpers.selectionRange(new TmfTimeRange(START_TIME, START_TIME)));
-        assertTrue(TmfTraceManager.getInstance().getCurrentTraceContext().getWindowRange().contains(START_TIME));
-    }
-
-    /**
-     * Test tool bar buttons "Select Next Event" and "Select Previous Event"
-     */
-    @Test
-    public void testToolBarSelectNextPreviousEvent() {
-        /* change window range to 10 ms */
-        TmfTimeRange range = new TmfTimeRange(START_TIME, START_TIME.normalize(10000000L, ITmfTimestamp.NANOSECOND_SCALE));
-        TmfSignalManager.dispatchSignal(new TmfWindowRangeUpdatedSignal(this, range));
-        fBot.waitUntil(ConditionHelpers.windowRange(range));
-
-        /* set selection to trace start time */
-        TmfSignalManager.dispatchSignal(new TmfSelectionRangeUpdatedSignal(this, START_TIME));
-        fBot.waitUntil(ConditionHelpers.selectionRange(new TmfTimeRange(START_TIME, START_TIME)));
-
-        /* select first item */
-        final SWTBotTree tree = fViewBot.bot().tree();
-        tree.pressShortcut(Keystrokes.HOME);
-
-        /* set focus on time graph */
-        final TimeGraphControl timegraph = fViewBot.bot().widget(WidgetOfType.widgetOfType(TimeGraphControl.class));
-        UIThreadRunnable.syncExec(new VoidResult() {
-            @Override
-            public void run() {
-                timegraph.setFocus();
-            }
-        });
-
-        /* click "Select Next Event" 3 times */
-        fViewBot.toolbarButton(SELECT_NEXT_EVENT).click();
-        fViewBot.toolbarButton(SELECT_NEXT_EVENT).click();
-        fViewBot.toolbarButton(SELECT_NEXT_EVENT).click();
-        fBot.waitUntil(ConditionHelpers.selectionRange(new TmfTimeRange(TID1_TIME3, TID1_TIME3)));
-        assertTrue(TmfTraceManager.getInstance().getCurrentTraceContext().getWindowRange().contains(TID1_TIME3));
-
-        /* shift-click "Select Next Event" 3 times */
-        fViewBot.toolbarButton(SELECT_NEXT_EVENT).click(SWT.SHIFT);
-        fViewBot.toolbarButton(SELECT_NEXT_EVENT).click(SWT.SHIFT);
-        fViewBot.toolbarButton(SELECT_NEXT_EVENT).click(SWT.SHIFT);
-        fBot.waitUntil(ConditionHelpers.selectionRange(new TmfTimeRange(TID1_TIME3, TID1_TIME6)));
-        assertTrue(TmfTraceManager.getInstance().getCurrentTraceContext().getWindowRange().contains(TID1_TIME6));
-
-        /* shift-click "Select Previous Event" 4 times */
-        fViewBot.toolbarButton(SELECT_PREVIOUS_EVENT).click(SWT.SHIFT);
-        fViewBot.toolbarButton(SELECT_PREVIOUS_EVENT).click(SWT.SHIFT);
-        fViewBot.toolbarButton(SELECT_PREVIOUS_EVENT).click(SWT.SHIFT);
-        fViewBot.toolbarButton(SELECT_PREVIOUS_EVENT).click(SWT.SHIFT);
-        fBot.waitUntil(ConditionHelpers.selectionRange(new TmfTimeRange(TID1_TIME3, TID1_TIME2)));
-        assertTrue(TmfTraceManager.getInstance().getCurrentTraceContext().getWindowRange().contains(TID1_TIME2));
-
-        /* click "Select Next Event" 2 times */
-        fViewBot.toolbarButton(SELECT_NEXT_EVENT).click();
-        fViewBot.toolbarButton(SELECT_NEXT_EVENT).click();
-        fBot.waitUntil(ConditionHelpers.selectionRange(new TmfTimeRange(TID1_TIME4, TID1_TIME4)));
-        assertTrue(TmfTraceManager.getInstance().getCurrentTraceContext().getWindowRange().contains(TID1_TIME4));
-
-        /* shift-click "Select Previous Event" 3 times */
-        fViewBot.toolbarButton(SELECT_PREVIOUS_EVENT).click(SWT.SHIFT);
-        fViewBot.toolbarButton(SELECT_PREVIOUS_EVENT).click(SWT.SHIFT);
-        fViewBot.toolbarButton(SELECT_PREVIOUS_EVENT).click(SWT.SHIFT);
-        fBot.waitUntil(ConditionHelpers.selectionRange(new TmfTimeRange(TID1_TIME4, TID1_TIME1)));
-        assertTrue(TmfTraceManager.getInstance().getCurrentTraceContext().getWindowRange().contains(TID1_TIME1));
-
-        /* shift-click "Select Next Event" 4 times */
-        fViewBot.toolbarButton(SELECT_NEXT_EVENT).click(SWT.SHIFT);
-        fViewBot.toolbarButton(SELECT_NEXT_EVENT).click(SWT.SHIFT);
-        fViewBot.toolbarButton(SELECT_NEXT_EVENT).click(SWT.SHIFT);
-        fViewBot.toolbarButton(SELECT_NEXT_EVENT).click(SWT.SHIFT);
-        fBot.waitUntil(ConditionHelpers.selectionRange(new TmfTimeRange(TID1_TIME4, TID1_TIME5)));
-        assertTrue(TmfTraceManager.getInstance().getCurrentTraceContext().getWindowRange().contains(TID1_TIME5));
-
-        /* click "Select Previous Event" 5 times */
-        fViewBot.toolbarButton(SELECT_PREVIOUS_EVENT).click();
-        fViewBot.toolbarButton(SELECT_PREVIOUS_EVENT).click();
-        fViewBot.toolbarButton(SELECT_PREVIOUS_EVENT).click();
-        fViewBot.toolbarButton(SELECT_PREVIOUS_EVENT).click();
-        fViewBot.toolbarButton(SELECT_PREVIOUS_EVENT).click();
-        fBot.waitUntil(ConditionHelpers.selectionRange(new TmfTimeRange(START_TIME, START_TIME)));
-        assertTrue(TmfTraceManager.getInstance().getCurrentTraceContext().getWindowRange().contains(START_TIME));
-    }
-
-    /**
-     * Test tool bar buttons "Follow CPU Forward" and "Follow CPU Backward"
-     */
-    @Test
-    public void testToolBarFollowCPUForwardBackward() {
-        /* change window range to 10 ms */
-        TmfTimeRange range = new TmfTimeRange(START_TIME, START_TIME.normalize(10000000L, ITmfTimestamp.NANOSECOND_SCALE));
-        TmfSignalManager.dispatchSignal(new TmfWindowRangeUpdatedSignal(this, range));
-        fBot.waitUntil(ConditionHelpers.windowRange(range));
-
-        /* set selection to trace start time */
-        TmfSignalManager.dispatchSignal(new TmfSelectionRangeUpdatedSignal(this, START_TIME));
-        fBot.waitUntil(ConditionHelpers.selectionRange(new TmfTimeRange(START_TIME, START_TIME)));
-
-        /* select first item */
-        final SWTBotTree tree = fViewBot.bot().tree();
-        tree.pressShortcut(Keystrokes.HOME);
-
-        /* set focus on time graph */
-        final TimeGraphControl timegraph = fViewBot.bot().widget(WidgetOfType.widgetOfType(TimeGraphControl.class));
-        UIThreadRunnable.syncExec(new VoidResult() {
-            @Override
-            public void run() {
-                timegraph.setFocus();
-            }
-        });
-
-        /* make sure arrows have been computed */
-        fBot.waitUntil(new DefaultCondition() {
-            @Override
-            public boolean test() throws Exception {
-                List<ILinkEvent> arrows = timegraph.getArrows();
-                return arrows.size() >= 3 &&
-                        arrows.get(0).getTime() == TID1_TIME1.getValue() &&
-                        arrows.get(1).getTime() == TID2_TIME2.getValue() &&
-                        arrows.get(2).getTime() == TID2_TIME4.getValue();
-            }
-            @Override
-            public String getFailureMessage() {
-                return "Arrows not found";
-            }
-        });
-
-        /* click "Follow CPU Forward" 3 times */
-        fViewBot.toolbarButton(FOLLOW_CPU_FORWARD).click();
-        fViewBot.toolbarButton(FOLLOW_CPU_FORWARD).click();
-        fViewBot.toolbarButton(FOLLOW_CPU_FORWARD).click();
-        fBot.waitUntil(ConditionHelpers.selectionRange(new TmfTimeRange(TID2_TIME2, TID2_TIME2)));
-        fBot.waitUntil(ConditionHelpers.treeSelectionContains(tree, 1, "2"));
-        assertTrue(TmfTraceManager.getInstance().getCurrentTraceContext().getWindowRange().contains(TID2_TIME2));
-
-        /* shift-click "Follow CPU Forward" 3 times */
-        fViewBot.toolbarButton(FOLLOW_CPU_FORWARD).click(SWT.SHIFT);
-        fViewBot.toolbarButton(FOLLOW_CPU_FORWARD).click(SWT.SHIFT);
-        fViewBot.toolbarButton(FOLLOW_CPU_FORWARD).click(SWT.SHIFT);
-        fBot.waitUntil(ConditionHelpers.selectionRange(new TmfTimeRange(TID2_TIME2, TID5_TIME1)));
-        fBot.waitUntil(ConditionHelpers.treeSelectionContains(tree, 1, "5"));
-        assertTrue(TmfTraceManager.getInstance().getCurrentTraceContext().getWindowRange().contains(TID5_TIME1));
-
-        /* shift-click "Follow CPU Backward" 4 times */
-        fViewBot.toolbarButton(FOLLOW_CPU_BACKWARD).click(SWT.SHIFT);
-        fViewBot.toolbarButton(FOLLOW_CPU_BACKWARD).click(SWT.SHIFT);
-        fViewBot.toolbarButton(FOLLOW_CPU_BACKWARD).click(SWT.SHIFT);
-        fViewBot.toolbarButton(FOLLOW_CPU_BACKWARD).click(SWT.SHIFT);
-        fBot.waitUntil(ConditionHelpers.selectionRange(new TmfTimeRange(TID2_TIME2, TID2_TIME1)));
-        fBot.waitUntil(ConditionHelpers.treeSelectionContains(tree, 1, "2"));
-        assertTrue(TmfTraceManager.getInstance().getCurrentTraceContext().getWindowRange().contains(TID2_TIME1));
-
-        /* click "Follow CPU Forward" 2 times */
-        fViewBot.toolbarButton(FOLLOW_CPU_FORWARD).click();
-        fViewBot.toolbarButton(FOLLOW_CPU_FORWARD).click();
-        fBot.waitUntil(ConditionHelpers.selectionRange(new TmfTimeRange(TID2_TIME3, TID2_TIME3)));
-        fBot.waitUntil(ConditionHelpers.treeSelectionContains(tree, 1, "2"));
-        assertTrue(TmfTraceManager.getInstance().getCurrentTraceContext().getWindowRange().contains(TID2_TIME3));
-
-        /* shift-click "Follow CPU Backward" 3 times */
-        fViewBot.toolbarButton(FOLLOW_CPU_BACKWARD).click(SWT.SHIFT);
-        fViewBot.toolbarButton(FOLLOW_CPU_BACKWARD).click(SWT.SHIFT);
-        fViewBot.toolbarButton(FOLLOW_CPU_BACKWARD).click(SWT.SHIFT);
-        fBot.waitUntil(ConditionHelpers.selectionRange(new TmfTimeRange(TID2_TIME3, TID1_TIME1)));
-        fBot.waitUntil(ConditionHelpers.treeSelectionContains(tree, 1, "1"));
-        assertTrue(TmfTraceManager.getInstance().getCurrentTraceContext().getWindowRange().contains(TID1_TIME1));
-
-        /* shift-click "Follow CPU Forward" 4 times */
-        fViewBot.toolbarButton(FOLLOW_CPU_FORWARD).click(SWT.SHIFT);
-        fViewBot.toolbarButton(FOLLOW_CPU_FORWARD).click(SWT.SHIFT);
-        fViewBot.toolbarButton(FOLLOW_CPU_FORWARD).click(SWT.SHIFT);
-        fViewBot.toolbarButton(FOLLOW_CPU_FORWARD).click(SWT.SHIFT);
-        fBot.waitUntil(ConditionHelpers.selectionRange(new TmfTimeRange(TID2_TIME3, TID2_TIME4)));
-        fBot.waitUntil(ConditionHelpers.treeSelectionContains(tree, 1, "2"));
-        assertTrue(TmfTraceManager.getInstance().getCurrentTraceContext().getWindowRange().contains(TID2_TIME4));
-
-        /* click "Follow CPU Backward" 5 times */
-        fViewBot.toolbarButton(FOLLOW_CPU_BACKWARD).click();
-        fViewBot.toolbarButton(FOLLOW_CPU_BACKWARD).click();
-        fViewBot.toolbarButton(FOLLOW_CPU_BACKWARD).click();
-        fViewBot.toolbarButton(FOLLOW_CPU_BACKWARD).click();
-        fViewBot.toolbarButton(FOLLOW_CPU_BACKWARD).click();
-        fBot.waitUntil(ConditionHelpers.selectionRange(new TmfTimeRange(START_TIME, START_TIME)));
-        assertTrue(TmfTraceManager.getInstance().getCurrentTraceContext().getWindowRange().contains(START_TIME));
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/src/org/eclipse/tracecompass/lttng2/kernel/ui/swtbot/tests/ImportAndReadKernelSmokeTest.java b/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/src/org/eclipse/tracecompass/lttng2/kernel/ui/swtbot/tests/ImportAndReadKernelSmokeTest.java
deleted file mode 100644 (file)
index c71f7a0..0000000
+++ /dev/null
@@ -1,149 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2013, 2015 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:
- *   Matthew Khouzam - Initial API and implementation
- *   Marc-Andre Laperle
- *   Patrick Tasse - Extract base class from ImportAndReadKernelSmokeTest
- *******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests;
-
-import static org.junit.Assert.assertNotNull;
-
-import java.util.List;
-
-import org.eclipse.jface.viewers.SelectionChangedEvent;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.swtbot.eclipse.finder.SWTWorkbenchBot;
-import org.eclipse.swtbot.eclipse.finder.matchers.WidgetMatcherFactory;
-import org.eclipse.swtbot.eclipse.finder.widgets.SWTBotView;
-import org.eclipse.swtbot.swt.finder.finders.UIThreadRunnable;
-import org.eclipse.swtbot.swt.finder.junit.SWTBotJunit4ClassRunner;
-import org.eclipse.swtbot.swt.finder.results.VoidResult;
-import org.eclipse.swtbot.swt.finder.widgets.SWTBotToolbarButton;
-import org.eclipse.tracecompass.analysis.os.linux.ui.views.controlflow.ControlFlowView;
-import org.eclipse.tracecompass.analysis.os.linux.ui.views.resources.ResourcesView;
-import org.eclipse.tracecompass.tmf.core.event.ITmfEvent;
-import org.eclipse.tracecompass.tmf.core.signal.TmfSelectionRangeUpdatedSignal;
-import org.eclipse.tracecompass.tmf.core.trace.ITmfContext;
-import org.eclipse.tracecompass.tmf.ctf.core.event.CtfTmfEvent;
-import org.eclipse.tracecompass.tmf.ctf.core.tests.shared.CtfTmfTestTrace;
-import org.eclipse.tracecompass.tmf.ctf.core.trace.CtfTmfTrace;
-import org.eclipse.tracecompass.tmf.ui.editors.TmfEventsEditor;
-import org.eclipse.tracecompass.tmf.ui.swtbot.tests.shared.SWTBotUtils;
-import org.eclipse.tracecompass.tmf.ui.views.histogram.HistogramView;
-import org.eclipse.ui.IEditorPart;
-import org.eclipse.ui.IEditorReference;
-import org.eclipse.ui.IViewPart;
-import org.eclipse.ui.IViewReference;
-import org.eclipse.ui.PlatformUI;
-import org.hamcrest.Matcher;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-
-/**
- * SWTBot Smoke test for LTTng Kernel UI.
- *
- * @author Matthew Khouzam
- */
-@RunWith(SWTBotJunit4ClassRunner.class)
-public class ImportAndReadKernelSmokeTest extends KernelTest {
-
-    private static final CtfTmfTestTrace CTT = CtfTmfTestTrace.SYNTHETIC_TRACE;
-
-    private ITmfEvent fDesired1;
-    private ITmfEvent fDesired2;
-
-    /**
-     * Main test case
-     */
-    @Test
-    public void test() {
-        Matcher<IEditorReference> matcher = WidgetMatcherFactory.withPartName(CTT.getTrace().getName());
-        IEditorPart iep = fBot.editor(matcher).getReference().getEditor(true);
-        final TmfEventsEditor tmfEd = (TmfEventsEditor) iep;
-        fDesired1 = getEvent(100);
-        fDesired2 = getEvent(10000);
-        UIThreadRunnable.syncExec(new VoidResult() {
-            @Override
-            public void run() {
-                tmfEd.setFocus();
-                tmfEd.selectionChanged(new SelectionChangedEvent(tmfEd, new StructuredSelection(fDesired1)));
-            }
-        });
-        testHV(getViewPart("Histogram"));
-        testCFV((ControlFlowView) getViewPart("Control Flow"));
-        testRV((ResourcesView) getViewPart("Resources"));
-    }
-
-    private static void testCFV(ControlFlowView vp) {
-        assertNotNull(vp);
-    }
-
-    private void testHV(IViewPart vp) {
-        SWTBotView hvBot = (new SWTWorkbenchBot()).viewById(HistogramView.ID);
-        List<SWTBotToolbarButton> hvTools = hvBot.getToolbarButtons();
-        for (SWTBotToolbarButton hvTool : hvTools) {
-            if (hvTool.getToolTipText().toLowerCase().contains("lost")) {
-                hvTool.click();
-            }
-        }
-        HistogramView hv = (HistogramView) vp;
-        final TmfSelectionRangeUpdatedSignal signal = new TmfSelectionRangeUpdatedSignal(hv, fDesired1.getTimestamp());
-        final TmfSelectionRangeUpdatedSignal signal2 = new TmfSelectionRangeUpdatedSignal(hv, fDesired2.getTimestamp());
-        hv.updateTimeRange(100000);
-        SWTBotUtils.waitForJobs();
-        hv.selectionRangeUpdated(signal);
-        hv.broadcast(signal);
-        SWTBotUtils.waitForJobs();
-        SWTBotUtils.delay(1000);
-
-        hv.updateTimeRange(1000000000);
-        SWTBotUtils.waitForJobs();
-        hv.selectionRangeUpdated(signal2);
-        hv.broadcast(signal2);
-        SWTBotUtils.waitForJobs();
-        SWTBotUtils.delay(1000);
-        assertNotNull(hv);
-    }
-
-    private static void testRV(ResourcesView vp) {
-        assertNotNull(vp);
-    }
-
-    private static CtfTmfEvent getEvent(int rank) {
-        try (CtfTmfTrace trace = CtfTmfTestTrace.SYNTHETIC_TRACE.getTrace()) {
-            ITmfContext ctx = trace.seekEvent(0);
-            for (int i = 0; i < rank; i++) {
-                trace.getNext(ctx);
-            }
-            return trace.getNext(ctx);
-        }
-
-    }
-
-    private static IViewPart getViewPart(final String viewTile) {
-        final IViewPart[] vps = new IViewPart[1];
-        UIThreadRunnable.syncExec(new VoidResult() {
-            @Override
-            public void run() {
-                IViewReference[] viewRefs = PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActivePage().getViewReferences();
-                for (IViewReference viewRef : viewRefs) {
-                    IViewPart vp = viewRef.getView(true);
-                    if (vp.getTitle().equals(viewTile)) {
-                        vps[0] = vp;
-                        return;
-                    }
-                }
-            }
-        });
-
-        return vps[0];
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/src/org/eclipse/tracecompass/lttng2/kernel/ui/swtbot/tests/KernelPerspectiveChecker.java b/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/src/org/eclipse/tracecompass/lttng2/kernel/ui/swtbot/tests/KernelPerspectiveChecker.java
deleted file mode 100644 (file)
index 192c1b9..0000000
+++ /dev/null
@@ -1,55 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2014, 2015 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:
- *   Matthew Khouzam - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests;
-
-import java.util.ArrayList;
-import java.util.Arrays;
-
-import org.eclipse.tracecompass.analysis.os.linux.ui.views.controlflow.ControlFlowView;
-import org.eclipse.tracecompass.analysis.os.linux.ui.views.resources.ResourcesView;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
-import org.eclipse.tracecompass.internal.lttng2.kernel.ui.views.PerspectiveFactory;
-import org.eclipse.tracecompass.tmf.ui.swtbot.tests.shared.AbstractPerspectiveChecker;
-import org.eclipse.tracecompass.tmf.ui.views.histogram.HistogramView;
-import org.eclipse.tracecompass.tmf.ui.views.statistics.TmfStatisticsView;
-import org.eclipse.ui.IPageLayout;
-import org.junit.Before;
-
-/**
- * Tracing perspective view checker
- *
- * @author Matthew Khouzam
- */
-public class KernelPerspectiveChecker extends AbstractPerspectiveChecker {
-
-    /**
-     * Set up arrays for test
-     */
-    @Before
-    public void init() {
-        fPerspectiveId = PerspectiveFactory.ID;
-        fViewIds = new ArrayList<>();
-        fViewIds.addAll(Arrays.asList(new String[] {
-                // LTTng views
-                HistogramView.ID,
-                ControlView.ID,
-                ControlFlowView.ID,
-                ResourcesView.ID,
-                TmfStatisticsView.ID,
-                // Standard Eclipse views
-                IPageLayout.ID_PROJECT_EXPLORER,
-                IPageLayout.ID_PROP_SHEET,
-                IPageLayout.ID_BOOKMARKS
-        }));
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/src/org/eclipse/tracecompass/lttng2/kernel/ui/swtbot/tests/KernelTest.java b/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/src/org/eclipse/tracecompass/lttng2/kernel/ui/swtbot/tests/KernelTest.java
deleted file mode 100644 (file)
index ef19434..0000000
+++ /dev/null
@@ -1,132 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2013, 2015 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:
- *   Matthew Khouzam - Initial API and implementation
- *   Marc-Andre Laperle
- *   Patrick Tasse - Extract base class from ImportAndReadKernelSmokeTest
- *******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests;
-
-import static org.junit.Assert.fail;
-
-import java.util.List;
-
-import org.apache.log4j.ConsoleAppender;
-import org.apache.log4j.Logger;
-import org.apache.log4j.SimpleLayout;
-import org.eclipse.swtbot.eclipse.finder.SWTWorkbenchBot;
-import org.eclipse.swtbot.eclipse.finder.widgets.SWTBotView;
-import org.eclipse.swtbot.swt.finder.finders.UIThreadRunnable;
-import org.eclipse.swtbot.swt.finder.junit.SWTBotJunit4ClassRunner;
-import org.eclipse.swtbot.swt.finder.results.BoolResult;
-import org.eclipse.swtbot.swt.finder.utils.SWTBotPreferences;
-import org.eclipse.tracecompass.tmf.ctf.core.tests.shared.CtfTmfTestTrace;
-import org.eclipse.tracecompass.tmf.ui.swtbot.tests.shared.ConditionHelpers;
-import org.eclipse.tracecompass.tmf.ui.swtbot.tests.shared.SWTBotUtils;
-import org.eclipse.ui.PlatformUI;
-import org.eclipse.ui.WorkbenchException;
-import org.junit.After;
-import org.junit.AfterClass;
-import org.junit.Before;
-import org.junit.BeforeClass;
-import org.junit.runner.RunWith;
-
-/**
- * Base SWTBot test for LTTng Kernel UI.
- *
- * @author Matthew Khouzam
- */
-@RunWith(SWTBotJunit4ClassRunner.class)
-public class KernelTest {
-
-    private static final String TRACE_TYPE = "org.eclipse.linuxtools.lttng2.kernel.tracetype";
-    private static final String KERNEL_PERSPECTIVE_ID = "org.eclipse.linuxtools.lttng2.kernel.ui.perspective";
-    private static final String TRACE_PROJECT_NAME = "test";
-    private static final CtfTmfTestTrace CTT = CtfTmfTestTrace.SYNTHETIC_TRACE;
-
-    /** The workbench bot */
-    protected static SWTWorkbenchBot fBot;
-
-    /** The Log4j logger instance. */
-    private static final Logger fLogger = Logger.getRootLogger();
-
-    /**
-     * Before Class
-     */
-    @BeforeClass
-    public static void beforeClass() {
-        SWTBotUtils.failIfUIThread();
-
-        /* set up for swtbot */
-        SWTBotPreferences.TIMEOUT = 20000; /* 20 second timeout */
-        fLogger.removeAllAppenders();
-        fLogger.addAppender(new ConsoleAppender(new SimpleLayout(), ConsoleAppender.SYSTEM_OUT));
-        fBot = new SWTWorkbenchBot();
-
-        final List<SWTBotView> openViews = fBot.views();
-        for (SWTBotView view : openViews) {
-            if (view.getTitle().equals("Welcome")) {
-                view.close();
-                fBot.waitUntil(ConditionHelpers.ViewIsClosed(view));
-            }
-        }
-        /* Switch perspectives */
-        switchKernelPerspective();
-        /* Finish waiting for eclipse to load */
-        SWTBotUtils.waitForJobs();
-        SWTBotUtils.createProject(TRACE_PROJECT_NAME);
-    }
-
-    /**
-     * After Class
-     */
-    @AfterClass
-    public static void afterClass() {
-        SWTBotUtils.deleteProject(TRACE_PROJECT_NAME, fBot);
-        fLogger.removeAllAppenders();
-    }
-
-    private static void switchKernelPerspective() {
-        final Exception retE[] = new Exception[1];
-        if (!UIThreadRunnable.syncExec(new BoolResult() {
-            @Override
-            public Boolean run() {
-                try {
-                    PlatformUI.getWorkbench().showPerspective(KERNEL_PERSPECTIVE_ID,
-                            PlatformUI.getWorkbench().getActiveWorkbenchWindow());
-                } catch (WorkbenchException e) {
-                    retE[0] = e;
-                    return false;
-                }
-                return true;
-            }
-        })) {
-            fail(retE[0].getMessage());
-        }
-
-    }
-
-    /**
-     * Before Test
-     */
-    @Before
-    public void before() {
-        SWTBotUtils.openTrace(TRACE_PROJECT_NAME, CTT.getPath(), TRACE_TYPE);
-        SWTBotUtils.activateEditor(fBot, CTT.getTrace().getName());
-    }
-
-    /**
-     * After Test
-     */
-    @After
-    public void after() {
-        fBot.closeAllEditors();
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/src/org/eclipse/tracecompass/lttng2/kernel/ui/swtbot/tests/OpenTraceStressTest.java b/org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests/src/org/eclipse/tracecompass/lttng2/kernel/ui/swtbot/tests/OpenTraceStressTest.java
deleted file mode 100644 (file)
index 015779d..0000000
+++ /dev/null
@@ -1,181 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2014, 2015 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:
- *   Bernd Hufmann - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests;
-
-import static org.junit.Assert.assertNotNull;
-import static org.junit.Assert.fail;
-import static org.junit.Assume.assumeTrue;
-
-import java.io.ByteArrayOutputStream;
-import java.io.File;
-import java.io.IOException;
-import java.io.PrintStream;
-
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.MultiStatus;
-import org.eclipse.core.runtime.jobs.IJobChangeEvent;
-import org.eclipse.core.runtime.jobs.IJobManager;
-import org.eclipse.core.runtime.jobs.Job;
-import org.eclipse.core.runtime.jobs.JobChangeAdapter;
-import org.eclipse.osgi.util.NLS;
-import org.eclipse.swtbot.eclipse.finder.SWTWorkbenchBot;
-import org.eclipse.swtbot.swt.finder.junit.SWTBotJunit4ClassRunner;
-import org.eclipse.swtbot.swt.finder.utils.SWTBotPreferences;
-import org.eclipse.tracecompass.tmf.core.analysis.Messages;
-import org.eclipse.tracecompass.tmf.ctf.core.tests.shared.CtfTmfTestTrace;
-import org.eclipse.tracecompass.tmf.ui.swtbot.tests.shared.SWTBotUtils;
-import org.junit.BeforeClass;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-
-/**
- * SWTBot stress test for opening and closing of traces.
- *
- * @author Bernd Hufmann
- */
-@RunWith(SWTBotJunit4ClassRunner.class)
-public class OpenTraceStressTest {
-
-    private static final String TRACE_TYPE = "org.eclipse.linuxtools.lttng2.kernel.tracetype";
-    private static final String KERNEL_PERSPECTIVE_ID = "org.eclipse.linuxtools.lttng2.kernel.ui.perspective";
-    private static final CtfTmfTestTrace CTF_TRACE = CtfTmfTestTrace.SYNC_DEST;
-    private static final String TRACE_PROJECT_NAME = "test";
-
-    private static SWTWorkbenchBot workbenchbot;
-
-    /**
-     * Test Class setup
-     */
-    @BeforeClass
-    public static void init() {
-        SWTBotUtils.failIfUIThread();
-
-        /* Set up for swtbot */
-        SWTBotPreferences.TIMEOUT = 20000; /* 20 second timeout */
-
-        workbenchbot = new SWTWorkbenchBot();
-
-        /* Close welcome view */
-        SWTBotUtils.closeView("Welcome", workbenchbot);
-
-        /* Switch perspectives */
-        SWTBotUtils.switchToPerspective(KERNEL_PERSPECTIVE_ID);
-
-        /* Finish waiting for eclipse to load */
-        SWTBotUtils.waitForJobs();
-    }
-
-    /**
-     * Main test case to test opening and closing of traces concurrently.
-     */
-    @Test
-    public void testOpenAndCloseConcurrency() {
-        SWTBotUtils.createProject(TRACE_PROJECT_NAME);
-
-        File fTestFile = new File(CTF_TRACE.getPath());
-
-        String path = fTestFile.getAbsolutePath();
-
-        assertNotNull(fTestFile);
-        assumeTrue(fTestFile.exists());
-
-        /*
-         *  This opening and closing of traces will trigger several threads for analysis which
-         *  will be closed concurrently. There used to be a concurrency bug (447434) which should
-         *  be fixed by now and this test should run without any exceptions.
-         *
-         *  Since the failure depends on timing it only happened sometimes before the bug fix
-         *  using this test.
-         */
-        final MultiStatus status = new MultiStatus("lttn2.kernel.ui.swtbot.tests", IStatus.OK, null, null);
-        IJobManager mgr = Job.getJobManager();
-        JobChangeAdapter changeListener = new JobChangeAdapter() {
-            @Override
-            public void done(IJobChangeEvent event) {
-                Job job = event.getJob();
-                // Check for analysis failure
-                String jobNamePrefix = NLS.bind(Messages.TmfAbstractAnalysisModule_RunningAnalysis, "");
-                if ((job.getName().startsWith(jobNamePrefix)) && (job.getResult().getSeverity() == IStatus.ERROR)) {
-                    status.add(job.getResult());
-                }
-            }
-        };
-        mgr.addJobChangeListener(changeListener);
-        for (int i = 0; i < 10; i++) {
-            SWTBotUtils.openTrace(TRACE_PROJECT_NAME, path, TRACE_TYPE, false);
-            SWTBotUtils.openTrace(TRACE_PROJECT_NAME, path, TRACE_TYPE, false);
-            SWTBotUtils.openTrace(TRACE_PROJECT_NAME, path, TRACE_TYPE, false);
-            SWTBotUtils.openTrace(TRACE_PROJECT_NAME, path, TRACE_TYPE, false);
-            SWTBotUtils.openTrace(TRACE_PROJECT_NAME, path, TRACE_TYPE, false);
-            // Add little delay so that treads have a chance to start
-            SWTBotUtils.delay(1000);
-            workbenchbot.closeAllEditors();
-
-            if (!status.isOK()) {
-                SWTBotUtils.deleteProject(TRACE_PROJECT_NAME, workbenchbot);
-                fail(handleErrorStatus(status));
-            }
-        }
-        SWTBotUtils.deleteProject(TRACE_PROJECT_NAME, workbenchbot);
-    }
-
-    private static String handleErrorStatus(MultiStatus status) {
-
-        // Build a string with all the children status messages, exception
-        // messages and stack traces
-        StringBuilder sb = new StringBuilder();
-        for (IStatus childStatus : status.getChildren()) {
-            StringBuilder childSb = new StringBuilder();
-            if (!childStatus.getMessage().isEmpty()) {
-                childSb.append(childStatus.getMessage() + '\n');
-            }
-
-            Throwable childException = childStatus.getException();
-            if (childException != null) {
-                String reason = childException.getMessage();
-                // Some system exceptions have no message
-                if (reason == null) {
-                    reason = childException.toString();
-                }
-
-                String stackMessage = getExceptionStackMessage(childException);
-                if (stackMessage == null) {
-                    stackMessage = reason;
-                }
-
-                childSb.append(stackMessage);
-            }
-
-            if (childSb.length() > 0) {
-                childSb.insert(0, '\n');
-                sb.append(childSb.toString());
-            }
-        }
-        return sb.toString();
-    }
-
-    private static String getExceptionStackMessage(Throwable exception) {
-        String stackMessage = null;
-        ByteArrayOutputStream baos = new ByteArrayOutputStream();
-        PrintStream ps = new PrintStream(baos);
-        exception.printStackTrace(ps);
-        ps.flush();
-        try {
-            baos.flush();
-            stackMessage = baos.toString();
-        } catch (IOException e) {
-        }
-
-        return stackMessage;
-    }
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.kernel.ui/.classpath b/org.eclipse.tracecompass.lttng2.kernel.ui/.classpath
deleted file mode 100644 (file)
index 098194c..0000000
+++ /dev/null
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
-       <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7"/>
-       <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
-       <classpathentry kind="src" path="src"/>
-       <classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/org.eclipse.tracecompass.lttng2.kernel.ui/.project b/org.eclipse.tracecompass.lttng2.kernel.ui/.project
deleted file mode 100644 (file)
index 9206b86..0000000
+++ /dev/null
@@ -1,34 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
-       <name>org.eclipse.tracecompass.lttng2.kernel.ui</name>
-       <comment></comment>
-       <projects>
-       </projects>
-       <buildSpec>
-               <buildCommand>
-                       <name>org.eclipse.jdt.core.javabuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-               <buildCommand>
-                       <name>org.eclipse.pde.ManifestBuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-               <buildCommand>
-                       <name>org.eclipse.pde.SchemaBuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-               <buildCommand>
-                       <name>org.eclipse.pde.api.tools.apiAnalysisBuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-       </buildSpec>
-       <natures>
-               <nature>org.eclipse.pde.PluginNature</nature>
-               <nature>org.eclipse.jdt.core.javanature</nature>
-               <nature>org.eclipse.pde.api.tools.apiAnalysisNature</nature>
-       </natures>
-</projectDescription>
diff --git a/org.eclipse.tracecompass.lttng2.kernel.ui/.settings/org.eclipse.core.resources.prefs b/org.eclipse.tracecompass.lttng2.kernel.ui/.settings/org.eclipse.core.resources.prefs
deleted file mode 100644 (file)
index 99f26c0..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-eclipse.preferences.version=1
-encoding/<project>=UTF-8
diff --git a/org.eclipse.tracecompass.lttng2.kernel.ui/.settings/org.eclipse.core.runtime.prefs b/org.eclipse.tracecompass.lttng2.kernel.ui/.settings/org.eclipse.core.runtime.prefs
deleted file mode 100644 (file)
index 5a0ad22..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-eclipse.preferences.version=1
-line.separator=\n
diff --git a/org.eclipse.tracecompass.lttng2.kernel.ui/.settings/org.eclipse.jdt.core.prefs b/org.eclipse.tracecompass.lttng2.kernel.ui/.settings/org.eclipse.jdt.core.prefs
deleted file mode 100644 (file)
index a2b5e6b..0000000
+++ /dev/null
@@ -1,405 +0,0 @@
-eclipse.preferences.version=1
-org.eclipse.jdt.core.codeComplete.argumentPrefixes=
-org.eclipse.jdt.core.codeComplete.argumentSuffixes=
-org.eclipse.jdt.core.codeComplete.fieldPrefixes=f
-org.eclipse.jdt.core.codeComplete.fieldSuffixes=
-org.eclipse.jdt.core.codeComplete.localPrefixes=
-org.eclipse.jdt.core.codeComplete.localSuffixes=
-org.eclipse.jdt.core.codeComplete.staticFieldPrefixes=
-org.eclipse.jdt.core.codeComplete.staticFieldSuffixes=
-org.eclipse.jdt.core.codeComplete.staticFinalFieldPrefixes=
-org.eclipse.jdt.core.codeComplete.staticFinalFieldSuffixes=
-org.eclipse.jdt.core.compiler.annotation.inheritNullAnnotations=enabled
-org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore
-org.eclipse.jdt.core.compiler.annotation.nonnull=org.eclipse.jdt.annotation.NonNull
-org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=org.eclipse.jdt.annotation.NonNullByDefault
-org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nullable
-org.eclipse.jdt.core.compiler.annotation.nullanalysis=enabled
-org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
-org.eclipse.jdt.core.compiler.codegen.methodParameters=do not generate
-org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
-org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
-org.eclipse.jdt.core.compiler.compliance=1.7
-org.eclipse.jdt.core.compiler.debug.lineNumber=generate
-org.eclipse.jdt.core.compiler.debug.localVariable=generate
-org.eclipse.jdt.core.compiler.debug.sourceFile=generate
-org.eclipse.jdt.core.compiler.doc.comment.support=enabled
-org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=error
-org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
-org.eclipse.jdt.core.compiler.problem.autoboxing=ignore
-org.eclipse.jdt.core.compiler.problem.comparingIdentical=error
-org.eclipse.jdt.core.compiler.problem.deadCode=error
-org.eclipse.jdt.core.compiler.problem.deprecation=error
-org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled
-org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=enabled
-org.eclipse.jdt.core.compiler.problem.discouragedReference=warning
-org.eclipse.jdt.core.compiler.problem.emptyStatement=error
-org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
-org.eclipse.jdt.core.compiler.problem.explicitlyClosedAutoCloseable=error
-org.eclipse.jdt.core.compiler.problem.fallthroughCase=error
-org.eclipse.jdt.core.compiler.problem.fatalOptionalError=disabled
-org.eclipse.jdt.core.compiler.problem.fieldHiding=error
-org.eclipse.jdt.core.compiler.problem.finalParameterBound=error
-org.eclipse.jdt.core.compiler.problem.finallyBlockNotCompletingNormally=error
-org.eclipse.jdt.core.compiler.problem.forbiddenReference=error
-org.eclipse.jdt.core.compiler.problem.hiddenCatchBlock=error
-org.eclipse.jdt.core.compiler.problem.includeNullInfoFromAsserts=disabled
-org.eclipse.jdt.core.compiler.problem.incompatibleNonInheritedInterfaceMethod=error
-org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch=error
-org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=error
-org.eclipse.jdt.core.compiler.problem.invalidJavadoc=warning
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTags=enabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsDeprecatedRef=enabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsNotVisibleRef=enabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsVisibility=protected
-org.eclipse.jdt.core.compiler.problem.localVariableHiding=error
-org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=error
-org.eclipse.jdt.core.compiler.problem.missingDefaultCase=error
-org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=error
-org.eclipse.jdt.core.compiler.problem.missingEnumCaseDespiteDefault=enabled
-org.eclipse.jdt.core.compiler.problem.missingHashCodeMethod=error
-org.eclipse.jdt.core.compiler.problem.missingJavadocComments=warning
-org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsOverriding=disabled
-org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsVisibility=protected
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagDescription=all_standard_tags
-org.eclipse.jdt.core.compiler.problem.missingJavadocTags=warning
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagsMethodTypeParameters=disabled
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagsOverriding=disabled
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagsVisibility=protected
-org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotation=error
-org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotationForInterfaceMethodImplementation=enabled
-org.eclipse.jdt.core.compiler.problem.missingSerialVersion=error
-org.eclipse.jdt.core.compiler.problem.missingSynchronizedOnInheritedMethod=error
-org.eclipse.jdt.core.compiler.problem.noEffectAssignment=error
-org.eclipse.jdt.core.compiler.problem.noImplicitStringConversion=error
-org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=warning
-org.eclipse.jdt.core.compiler.problem.nonnullParameterAnnotationDropped=warning
-org.eclipse.jdt.core.compiler.problem.nullAnnotationInferenceConflict=warning
-org.eclipse.jdt.core.compiler.problem.nullReference=error
-org.eclipse.jdt.core.compiler.problem.nullSpecViolation=error
-org.eclipse.jdt.core.compiler.problem.nullUncheckedConversion=warning
-org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=error
-org.eclipse.jdt.core.compiler.problem.parameterAssignment=error
-org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=error
-org.eclipse.jdt.core.compiler.problem.potentialNullReference=error
-org.eclipse.jdt.core.compiler.problem.potentiallyUnclosedCloseable=warning
-org.eclipse.jdt.core.compiler.problem.rawTypeReference=warning
-org.eclipse.jdt.core.compiler.problem.redundantNullAnnotation=warning
-org.eclipse.jdt.core.compiler.problem.redundantNullCheck=error
-org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=error
-org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=error
-org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore
-org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=error
-org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled
-org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=error
-org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=disabled
-org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled
-org.eclipse.jdt.core.compiler.problem.syntacticNullAnalysisForFields=enabled
-org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=ignore
-org.eclipse.jdt.core.compiler.problem.typeParameterHiding=error
-org.eclipse.jdt.core.compiler.problem.unavoidableGenericTypeProblems=disabled
-org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=warning
-org.eclipse.jdt.core.compiler.problem.unclosedCloseable=error
-org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=ignore
-org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=error
-org.eclipse.jdt.core.compiler.problem.unnecessaryElse=error
-org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=error
-org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=warning
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionExemptExceptionAndThrowable=disabled
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionIncludeDocCommentReference=disabled
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverriding=disabled
-org.eclipse.jdt.core.compiler.problem.unusedExceptionParameter=ignore
-org.eclipse.jdt.core.compiler.problem.unusedImport=error
-org.eclipse.jdt.core.compiler.problem.unusedLabel=error
-org.eclipse.jdt.core.compiler.problem.unusedLocal=error
-org.eclipse.jdt.core.compiler.problem.unusedObjectAllocation=ignore
-org.eclipse.jdt.core.compiler.problem.unusedParameter=error
-org.eclipse.jdt.core.compiler.problem.unusedParameterIncludeDocCommentReference=enabled
-org.eclipse.jdt.core.compiler.problem.unusedParameterWhenImplementingAbstract=disabled
-org.eclipse.jdt.core.compiler.problem.unusedParameterWhenOverridingConcrete=disabled
-org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=error
-org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=error
-org.eclipse.jdt.core.compiler.problem.unusedWarningToken=error
-org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=error
-org.eclipse.jdt.core.compiler.source=1.7
-org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_call=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression=16
-org.eclipse.jdt.core.formatter.alignment_for_assignment=0
-org.eclipse.jdt.core.formatter.alignment_for_binary_expression=16
-org.eclipse.jdt.core.formatter.alignment_for_compact_if=16
-org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=80
-org.eclipse.jdt.core.formatter.alignment_for_enum_constants=0
-org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=16
-org.eclipse.jdt.core.formatter.alignment_for_method_declaration=0
-org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16
-org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=80
-org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation=0
-org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_constructor_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_method_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_union_type_in_multicatch=16
-org.eclipse.jdt.core.formatter.blank_lines_after_imports=1
-org.eclipse.jdt.core.formatter.blank_lines_after_package=1
-org.eclipse.jdt.core.formatter.blank_lines_before_field=0
-org.eclipse.jdt.core.formatter.blank_lines_before_first_class_body_declaration=0
-org.eclipse.jdt.core.formatter.blank_lines_before_imports=1
-org.eclipse.jdt.core.formatter.blank_lines_before_member_type=1
-org.eclipse.jdt.core.formatter.blank_lines_before_method=1
-org.eclipse.jdt.core.formatter.blank_lines_before_new_chunk=1
-org.eclipse.jdt.core.formatter.blank_lines_before_package=0
-org.eclipse.jdt.core.formatter.blank_lines_between_import_groups=1
-org.eclipse.jdt.core.formatter.blank_lines_between_type_declarations=1
-org.eclipse.jdt.core.formatter.brace_position_for_annotation_type_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_array_initializer=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_block=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_block_in_case=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_constructor_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_enum_constant=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_enum_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_method_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_switch=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_type_declaration=end_of_line
-org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_block_comment=false
-org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_javadoc_comment=false
-org.eclipse.jdt.core.formatter.comment.format_block_comments=true
-org.eclipse.jdt.core.formatter.comment.format_header=false
-org.eclipse.jdt.core.formatter.comment.format_html=true
-org.eclipse.jdt.core.formatter.comment.format_javadoc_comments=true
-org.eclipse.jdt.core.formatter.comment.format_line_comments=true
-org.eclipse.jdt.core.formatter.comment.format_source_code=true
-org.eclipse.jdt.core.formatter.comment.indent_parameter_description=true
-org.eclipse.jdt.core.formatter.comment.indent_root_tags=true
-org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags=insert
-org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter=insert
-org.eclipse.jdt.core.formatter.comment.line_length=80
-org.eclipse.jdt.core.formatter.comment.new_lines_at_block_boundaries=true
-org.eclipse.jdt.core.formatter.comment.new_lines_at_javadoc_boundaries=true
-org.eclipse.jdt.core.formatter.comment.preserve_white_space_between_code_and_line_comments=false
-org.eclipse.jdt.core.formatter.compact_else_if=true
-org.eclipse.jdt.core.formatter.continuation_indentation=2
-org.eclipse.jdt.core.formatter.continuation_indentation_for_array_initializer=2
-org.eclipse.jdt.core.formatter.disabling_tag=@formatter\:off
-org.eclipse.jdt.core.formatter.enabling_tag=@formatter\:on
-org.eclipse.jdt.core.formatter.format_guardian_clause_on_one_line=false
-org.eclipse.jdt.core.formatter.format_line_comment_starting_on_first_column=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_annotation_declaration_header=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_constant_header=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_declaration_header=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_type_header=true
-org.eclipse.jdt.core.formatter.indent_breaks_compare_to_cases=true
-org.eclipse.jdt.core.formatter.indent_empty_lines=false
-org.eclipse.jdt.core.formatter.indent_statements_compare_to_block=true
-org.eclipse.jdt.core.formatter.indent_statements_compare_to_body=true
-org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_cases=true
-org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_switch=false
-org.eclipse.jdt.core.formatter.indentation.size=4
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_field=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_local_variable=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_method=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_package=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_parameter=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_type=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_label=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_opening_brace_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_at_end_of_file_if_missing=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_finally_in_try_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_while_in_do_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_annotation_declaration=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_anonymous_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_block=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter=insert
-org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_binary_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_paren_in_cast=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_assert=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_case=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_labeled_statement=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_allocation_expression=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_annotation=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_throws=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_constant_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_declarations=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_explicitconstructorcall_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_increments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_inits=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_throws=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_invocation_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_field_declarations=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_local_declarations=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_parameterized_type_reference=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_superinterfaces=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_ellipsis=insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_brace_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_cast=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_catch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_for=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_if=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_parenthesized_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_switch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_synchronized=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_try=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_while=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_try_resources=insert
-org.eclipse.jdt.core.formatter.insert_space_after_unary_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter=insert
-org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_binary_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_brace_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_cast=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_catch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_for=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_if=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_parenthesized_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_switch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_synchronized=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_try=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_while=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_assert=insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_case=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_default=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_labeled_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_throws=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_constant_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_declarations=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_explicitconstructorcall_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_increments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_inits=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_throws=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_invocation_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_field_declarations=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_local_declarations=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_superinterfaces=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_ellipsis=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_annotation_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_anonymous_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_block=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_constructor_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_constant=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_method_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_switch=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation_type_member_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_catch=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_if=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_parenthesized_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_switch=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_synchronized=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_try=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_while=insert
-org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_return=insert
-org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_throw=insert
-org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_semicolon=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_try_resources=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_unary_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_brackets_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_annotation_type_member_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.join_lines_in_comments=true
-org.eclipse.jdt.core.formatter.join_wrapped_lines=false
-org.eclipse.jdt.core.formatter.keep_else_statement_on_same_line=false
-org.eclipse.jdt.core.formatter.keep_empty_array_initializer_on_one_line=false
-org.eclipse.jdt.core.formatter.keep_imple_if_on_one_line=false
-org.eclipse.jdt.core.formatter.keep_then_statement_on_same_line=false
-org.eclipse.jdt.core.formatter.lineSplit=250
-org.eclipse.jdt.core.formatter.never_indent_block_comments_on_first_column=false
-org.eclipse.jdt.core.formatter.never_indent_line_comments_on_first_column=false
-org.eclipse.jdt.core.formatter.number_of_blank_lines_at_beginning_of_method_body=0
-org.eclipse.jdt.core.formatter.number_of_empty_lines_to_preserve=1
-org.eclipse.jdt.core.formatter.put_empty_statement_on_new_line=true
-org.eclipse.jdt.core.formatter.tabulation.char=space
-org.eclipse.jdt.core.formatter.tabulation.size=4
-org.eclipse.jdt.core.formatter.use_on_off_tags=false
-org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false
-org.eclipse.jdt.core.formatter.wrap_before_binary_operator=true
-org.eclipse.jdt.core.formatter.wrap_before_or_operator_multicatch=true
-org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true
diff --git a/org.eclipse.tracecompass.lttng2.kernel.ui/.settings/org.eclipse.jdt.ui.prefs b/org.eclipse.tracecompass.lttng2.kernel.ui/.settings/org.eclipse.jdt.ui.prefs
deleted file mode 100644 (file)
index 232a3fd..0000000
+++ /dev/null
@@ -1,60 +0,0 @@
-eclipse.preferences.version=1
-editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true
-formatter_profile=_tmf-style
-formatter_settings_version=12
-org.eclipse.jdt.ui.exception.name=e
-org.eclipse.jdt.ui.gettersetter.use.is=true
-org.eclipse.jdt.ui.keywordthis=false
-org.eclipse.jdt.ui.overrideannotation=true
-sp_cleanup.add_default_serial_version_id=true
-sp_cleanup.add_generated_serial_version_id=false
-sp_cleanup.add_missing_annotations=false
-sp_cleanup.add_missing_deprecated_annotations=true
-sp_cleanup.add_missing_methods=false
-sp_cleanup.add_missing_nls_tags=false
-sp_cleanup.add_missing_override_annotations=true
-sp_cleanup.add_missing_override_annotations_interface_methods=true
-sp_cleanup.add_serial_version_id=false
-sp_cleanup.always_use_blocks=true
-sp_cleanup.always_use_parentheses_in_expressions=false
-sp_cleanup.always_use_this_for_non_static_field_access=false
-sp_cleanup.always_use_this_for_non_static_method_access=false
-sp_cleanup.convert_to_enhanced_for_loop=false
-sp_cleanup.correct_indentation=false
-sp_cleanup.format_source_code=false
-sp_cleanup.format_source_code_changes_only=false
-sp_cleanup.make_local_variable_final=false
-sp_cleanup.make_parameters_final=false
-sp_cleanup.make_private_fields_final=true
-sp_cleanup.make_type_abstract_if_missing_method=false
-sp_cleanup.make_variable_declarations_final=false
-sp_cleanup.never_use_blocks=false
-sp_cleanup.never_use_parentheses_in_expressions=true
-sp_cleanup.on_save_use_additional_actions=true
-sp_cleanup.organize_imports=false
-sp_cleanup.qualify_static_field_accesses_with_declaring_class=false
-sp_cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=true
-sp_cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=true
-sp_cleanup.qualify_static_member_accesses_with_declaring_class=false
-sp_cleanup.qualify_static_method_accesses_with_declaring_class=false
-sp_cleanup.remove_private_constructors=true
-sp_cleanup.remove_trailing_whitespaces=true
-sp_cleanup.remove_trailing_whitespaces_all=true
-sp_cleanup.remove_trailing_whitespaces_ignore_empty=false
-sp_cleanup.remove_unnecessary_casts=false
-sp_cleanup.remove_unnecessary_nls_tags=false
-sp_cleanup.remove_unused_imports=false
-sp_cleanup.remove_unused_local_variables=false
-sp_cleanup.remove_unused_private_fields=true
-sp_cleanup.remove_unused_private_members=false
-sp_cleanup.remove_unused_private_methods=true
-sp_cleanup.remove_unused_private_types=true
-sp_cleanup.sort_members=false
-sp_cleanup.sort_members_all=false
-sp_cleanup.use_blocks=true
-sp_cleanup.use_blocks_only_for_return_and_throw=false
-sp_cleanup.use_parentheses_in_expressions=false
-sp_cleanup.use_this_for_non_static_field_access=false
-sp_cleanup.use_this_for_non_static_field_access_only_if_necessary=true
-sp_cleanup.use_this_for_non_static_method_access=false
-sp_cleanup.use_this_for_non_static_method_access_only_if_necessary=true
diff --git a/org.eclipse.tracecompass.lttng2.kernel.ui/.settings/org.eclipse.pde.api.tools.prefs b/org.eclipse.tracecompass.lttng2.kernel.ui/.settings/org.eclipse.pde.api.tools.prefs
deleted file mode 100644 (file)
index acc3abd..0000000
+++ /dev/null
@@ -1,97 +0,0 @@
-ANNOTATION_ELEMENT_TYPE_ADDED_METHOD_WITHOUT_DEFAULT_VALUE=Error
-ANNOTATION_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-ANNOTATION_ELEMENT_TYPE_REMOVED_FIELD=Error
-ANNOTATION_ELEMENT_TYPE_REMOVED_METHOD=Error
-ANNOTATION_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_API_TYPE=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_API_TYPE=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_TYPE=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_TYPE=Error
-API_USE_SCAN_FIELD_SEVERITY=Error
-API_USE_SCAN_METHOD_SEVERITY=Error
-API_USE_SCAN_TYPE_SEVERITY=Error
-CLASS_ELEMENT_TYPE_ADDED_METHOD=Error
-CLASS_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
-CLASS_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-CLASS_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
-CLASS_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-CLASS_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
-CLASS_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
-CLASS_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-CLASS_ELEMENT_TYPE_REMOVED_CONSTRUCTOR=Error
-CLASS_ELEMENT_TYPE_REMOVED_FIELD=Error
-CLASS_ELEMENT_TYPE_REMOVED_METHOD=Error
-CLASS_ELEMENT_TYPE_REMOVED_SUPERCLASS=Error
-CLASS_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-CLASS_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-CONSTRUCTOR_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-CONSTRUCTOR_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-CONSTRUCTOR_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
-CONSTRUCTOR_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-ENUM_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
-ENUM_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-ENUM_ELEMENT_TYPE_REMOVED_ENUM_CONSTANT=Error
-ENUM_ELEMENT_TYPE_REMOVED_FIELD=Error
-ENUM_ELEMENT_TYPE_REMOVED_METHOD=Error
-ENUM_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-FIELD_ELEMENT_TYPE_ADDED_VALUE=Error
-FIELD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-FIELD_ELEMENT_TYPE_CHANGED_FINAL_TO_NON_FINAL_STATIC_CONSTANT=Error
-FIELD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
-FIELD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
-FIELD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
-FIELD_ELEMENT_TYPE_CHANGED_TYPE=Error
-FIELD_ELEMENT_TYPE_CHANGED_VALUE=Error
-FIELD_ELEMENT_TYPE_REMOVED_TYPE_ARGUMENT=Error
-FIELD_ELEMENT_TYPE_REMOVED_VALUE=Error
-ILLEGAL_EXTEND=Warning
-ILLEGAL_IMPLEMENT=Warning
-ILLEGAL_INSTANTIATE=Warning
-ILLEGAL_OVERRIDE=Warning
-ILLEGAL_REFERENCE=Warning
-INTERFACE_ELEMENT_TYPE_ADDED_FIELD=Error
-INTERFACE_ELEMENT_TYPE_ADDED_METHOD=Error
-INTERFACE_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
-INTERFACE_ELEMENT_TYPE_ADDED_SUPER_INTERFACE_WITH_METHODS=Error
-INTERFACE_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-INTERFACE_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
-INTERFACE_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_FIELD=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_METHOD=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-INVALID_JAVADOC_TAG=Warning
-INVALID_REFERENCE_IN_SYSTEM_LIBRARIES=Warning
-LEAK_EXTEND=Warning
-LEAK_FIELD_DECL=Warning
-LEAK_IMPLEMENT=Warning
-LEAK_METHOD_PARAM=Warning
-LEAK_METHOD_RETURN_TYPE=Warning
-METHOD_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
-METHOD_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-METHOD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-METHOD_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
-METHOD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
-METHOD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
-METHOD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
-METHOD_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
-METHOD_ELEMENT_TYPE_REMOVED_ANNOTATION_DEFAULT_VALUE=Error
-METHOD_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-MISSING_EE_DESCRIPTIONS=Ignore
-TYPE_PARAMETER_ELEMENT_TYPE_ADDED_CLASS_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_ADDED_INTERFACE_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_CLASS_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_INTERFACE_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_CLASS_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_INTERFACE_BOUND=Error
-UNUSED_PROBLEM_FILTERS=Warning
-automatically_removed_unused_problem_filters=false
-eclipse.preferences.version=1
-incompatible_api_component_version=Error
-incompatible_api_component_version_include_major_without_breaking_change=Disabled
-incompatible_api_component_version_include_minor_without_api_change=Disabled
-invalid_since_tag_version=Error
-malformed_since_tag=Error
-missing_since_tag=Error
-report_api_breakage_when_major_version_incremented=Disabled
-report_resolution_errors_api_component=Warning
diff --git a/org.eclipse.tracecompass.lttng2.kernel.ui/.settings/org.eclipse.pde.prefs b/org.eclipse.tracecompass.lttng2.kernel.ui/.settings/org.eclipse.pde.prefs
deleted file mode 100644 (file)
index d92b94f..0000000
+++ /dev/null
@@ -1,32 +0,0 @@
-compilers.f.unresolved-features=1
-compilers.f.unresolved-plugins=1
-compilers.incompatible-environment=1
-compilers.p.build=1
-compilers.p.build.bin.includes=1
-compilers.p.build.encodings=2
-compilers.p.build.java.compiler=2
-compilers.p.build.java.compliance=1
-compilers.p.build.missing.output=2
-compilers.p.build.output.library=1
-compilers.p.build.source.library=1
-compilers.p.build.src.includes=1
-compilers.p.deprecated=1
-compilers.p.discouraged-class=1
-compilers.p.internal=1
-compilers.p.missing-packages=1
-compilers.p.missing-version-export-package=2
-compilers.p.missing-version-import-package=2
-compilers.p.missing-version-require-bundle=2
-compilers.p.no-required-att=0
-compilers.p.not-externalized-att=1
-compilers.p.unknown-attribute=1
-compilers.p.unknown-class=1
-compilers.p.unknown-element=1
-compilers.p.unknown-identifier=1
-compilers.p.unknown-resource=1
-compilers.p.unresolved-ex-points=0
-compilers.p.unresolved-import=0
-compilers.s.create-docs=false
-compilers.s.doc-folder=doc
-compilers.s.open-tags=1
-eclipse.preferences.version=1
diff --git a/org.eclipse.tracecompass.lttng2.kernel.ui/META-INF/MANIFEST.MF b/org.eclipse.tracecompass.lttng2.kernel.ui/META-INF/MANIFEST.MF
deleted file mode 100644 (file)
index 43eb8b1..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-Manifest-Version: 1.0
-Bundle-ManifestVersion: 2
-Bundle-Name: %Bundle-Name
-Bundle-Vendor: %Bundle-Vendor
-Bundle-Version: 1.0.0.qualifier
-Bundle-Localization: plugin
-Bundle-SymbolicName: org.eclipse.tracecompass.lttng2.kernel.ui;singleton:=true
-Bundle-Activator: org.eclipse.tracecompass.internal.lttng2.kernel.ui.Activator
-Bundle-ActivationPolicy: lazy
-Bundle-RequiredExecutionEnvironment: JavaSE-1.7
-Require-Bundle: org.eclipse.ui,
- org.eclipse.ui.ide,
- org.eclipse.core.resources,
- org.eclipse.core.runtime,
- org.eclipse.tracecompass.common.core,
- org.eclipse.tracecompass.tmf.core,
- org.eclipse.tracecompass.tmf.ui,
- org.eclipse.tracecompass.analysis.os.linux.ui,
- org.eclipse.tracecompass.tmf.ctf.core,
- org.eclipse.tracecompass.lttng2.control.core,
- org.eclipse.tracecompass.lttng2.control.ui,
- org.eclipse.tracecompass.lttng2.kernel.core,
- org.eclipse.tracecompass.lttng2.kernel.ui
-Import-Package: com.google.common.collect
-Export-Package: org.eclipse.tracecompass.internal.lttng2.kernel.ui;x-internal:=true,
- org.eclipse.tracecompass.internal.lttng2.kernel.ui.views;x-friends:="org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests"
diff --git a/org.eclipse.tracecompass.lttng2.kernel.ui/about.html b/org.eclipse.tracecompass.lttng2.kernel.ui/about.html
deleted file mode 100644 (file)
index c258ef5..0000000
+++ /dev/null
@@ -1,28 +0,0 @@
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
-    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml">
-<head>
-<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"/>
-<title>About</title>
-</head>
-<body lang="EN-US">
-<h2>About This Content</h2>
-<p>June 5, 2006</p>    
-<h3>License</h3>
-
-<p>The Eclipse Foundation makes available all content in this plug-in (&quot;Content&quot;).  Unless otherwise 
-indicated below, the Content is provided to you under the terms and conditions of the
-Eclipse Public License Version 1.0 (&quot;EPL&quot;).  A copy of the EPL is available 
-at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>.
-For purposes of the EPL, &quot;Program&quot; will mean the Content.</p>
-
-<p>If you did not receive this Content directly from the Eclipse Foundation, the Content is 
-being redistributed by another party (&quot;Redistributor&quot;) and different terms and conditions may
-apply to your use of any object code in the Content.  Check the Redistributor's license that was 
-provided with the Content.  If no such license exists, contact the Redistributor.  Unless otherwise
-indicated below, the terms and conditions of the EPL still apply to any source code in the Content
-and such source code may be obtained at <a href="http://www.eclipse.org/">http://www.eclipse.org</a>.</p>
-
-</body>
-</html>
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.kernel.ui/build.properties b/org.eclipse.tracecompass.lttng2.kernel.ui/build.properties
deleted file mode 100644 (file)
index 9775951..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-###############################################################################
-# Copyright (c) 2013, 2014 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:
-#     Ericsson - Initial API and implementation
-###############################################################################
-
-source.. = src/
-output.. = bin/
-bin.includes = META-INF/,\
-               .,\
-               plugin.xml,\
-               icons/,\
-               about.html,\
-               plugin.properties
-src.includes = about.html
-additional.bundles = org.eclipse.jdt.annotation
-jars.extra.classpath = platform:/plugin/org.eclipse.jdt.annotation
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.kernel.ui/icons/eview16/control_flow_view.gif b/org.eclipse.tracecompass.lttng2.kernel.ui/icons/eview16/control_flow_view.gif
deleted file mode 100644 (file)
index 3971b50..0000000
Binary files a/org.eclipse.tracecompass.lttng2.kernel.ui/icons/eview16/control_flow_view.gif and /dev/null differ
diff --git a/org.eclipse.tracecompass.lttng2.kernel.ui/icons/eview16/resources_view.gif b/org.eclipse.tracecompass.lttng2.kernel.ui/icons/eview16/resources_view.gif
deleted file mode 100644 (file)
index 2344861..0000000
Binary files a/org.eclipse.tracecompass.lttng2.kernel.ui/icons/eview16/resources_view.gif and /dev/null differ
diff --git a/org.eclipse.tracecompass.lttng2.kernel.ui/icons/obj16/garland16.png b/org.eclipse.tracecompass.lttng2.kernel.ui/icons/obj16/garland16.png
deleted file mode 100644 (file)
index 74f9751..0000000
Binary files a/org.eclipse.tracecompass.lttng2.kernel.ui/icons/obj16/garland16.png and /dev/null differ
diff --git a/org.eclipse.tracecompass.lttng2.kernel.ui/plugin.properties b/org.eclipse.tracecompass.lttng2.kernel.ui/plugin.properties
deleted file mode 100644 (file)
index 96a73ce..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-###############################################################################
-# Copyright (c) 2013, 2014 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:
-#     Ericsson - Initial API and implementation
-###############################################################################
-
-Bundle-Vendor = Eclipse Trace Compass
-Bundle-Name = Trace Compass LTTng Kernel Analysis UI Plug-in
-
-kernel.perspective.name = LTTng Kernel
-
-controlflow.view.name = Control Flow
-resources.view.name = Resources
-cpuusage.view.name = CPU Usage
-
-tracetype.type.kernel = LTTng Kernel Trace
-analysis.lttngkernel = LTTng Kernel Analysis
diff --git a/org.eclipse.tracecompass.lttng2.kernel.ui/plugin.xml b/org.eclipse.tracecompass.lttng2.kernel.ui/plugin.xml
deleted file mode 100644 (file)
index 0bba560..0000000
+++ /dev/null
@@ -1,36 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<?eclipse version="3.4"?>
-<plugin>
-   <extension
-         point="org.eclipse.ui.perspectives">
-      <perspective
-            class="org.eclipse.tracecompass.internal.lttng2.kernel.ui.views.PerspectiveFactory"
-            icon="icons/obj16/garland16.png"
-            id="org.eclipse.linuxtools.lttng2.kernel.ui.perspective"
-            name="%kernel.perspective.name">
-      </perspective>
-   </extension>
-   <extension
-         point="org.eclipse.ui.navigator.navigatorContent">
-      <commonWizard
-            associatedExtensionId="org.eclipse.linuxtools.tmf.ui.navigator.content"
-            menuGroupId="org.eclipse.linuxtools.tmf.ui.views.ui.wizards.menuGroupId"
-            type="new"
-            wizardId="org.eclipse.linuxtools.tmf.ui.views.ui.wizards.newProject">
-         <enablement>
-            <with variable="activeWorkbenchWindow.activePerspective">
-               <equals
-                     value="org.eclipse.linuxtools.lttng2.kernel.ui.perspective">
-               </equals>
-            </with>
-         </enablement>
-      </commonWizard>
-   </extension>
-   <extension
-         point="org.eclipse.linuxtools.tmf.ui.tracetypeui">
-      <type
-            icon="icons/obj16/garland16.png"
-            tracetype="org.eclipse.linuxtools.lttng2.kernel.tracetype">
-      </type>
-   </extension>
-</plugin>
diff --git a/org.eclipse.tracecompass.lttng2.kernel.ui/pom.xml b/org.eclipse.tracecompass.lttng2.kernel.ui/pom.xml
deleted file mode 100644 (file)
index 43ef21d..0000000
+++ /dev/null
@@ -1,36 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-   Copyright (C) 2011, Red Hat, Inc.
-
-   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
--->
-<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>
-    <artifactId>org.eclipse.tracecompass</artifactId>
-    <groupId>org.eclipse.tracecompass</groupId>
-    <version>1.0.0-SNAPSHOT</version>
-  </parent>
-
-  <artifactId>org.eclipse.tracecompass.lttng2.kernel.ui</artifactId>
-  <version>1.0.0-SNAPSHOT</version>
-  <packaging>eclipse-plugin</packaging>
-
-  <name>Trace Compass LTTng Kernel Analysis UI Plug-in</name>
-
- <build>
-    <plugins>
-      <plugin>
-        <groupId>org.eclipse.tycho</groupId>
-        <artifactId>tycho-source-plugin</artifactId>
-      </plugin>
-    </plugins>
-  </build>
-
- <groupId>org.eclipse.tracecompass</groupId>
-</project>
diff --git a/org.eclipse.tracecompass.lttng2.kernel.ui/src/org/eclipse/tracecompass/internal/lttng2/kernel/ui/Activator.java b/org.eclipse.tracecompass.lttng2.kernel.ui/src/org/eclipse/tracecompass/internal/lttng2/kernel/ui/Activator.java
deleted file mode 100644 (file)
index f9e1350..0000000
+++ /dev/null
@@ -1,184 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2012, 2015 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:
- *   Francois Chouinard - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.kernel.ui;
-
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.jface.resource.ImageDescriptor;
-import org.eclipse.jface.resource.ImageRegistry;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.ui.plugin.AbstractUIPlugin;
-import org.osgi.framework.BundleContext;
-
-/**
- * The activator class controls the plug-in life cycle
- */
-public class Activator extends AbstractUIPlugin {
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-
-    /**
-     *  The plug-in ID
-     */
-    public static final String PLUGIN_ID = "org.eclipse.tracecompass.lttng2.kernel.ui"; //$NON-NLS-1$
-
-    /**
-     *  The shared instance
-     */
-    private static Activator plugin;
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-
-    /**
-     * The constructor
-     */
-    public Activator() {
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    /**
-     * Returns the shared instance
-     *
-     * @return the shared instance
-     */
-    public static Activator getDefault() {
-        return plugin;
-    }
-
-    // ------------------------------------------------------------------------
-    // AbstractUIPlugin
-    // ------------------------------------------------------------------------
-
-    @Override
-    public void start(BundleContext context) throws Exception {
-        super.start(context);
-        plugin = this;
-    }
-
-    @Override
-    public void stop(BundleContext context) throws Exception {
-        plugin = null;
-        super.stop(context);
-    }
-
-    @Override
-    protected void initializeImageRegistry(ImageRegistry reg) {
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    /**
-     * Get the image object from a given path
-     *
-     * @param path
-     *            The path to the image file
-     * @return The Image object
-     */
-    public Image getImageFromPath(String path) {
-        return getImageDescripterFromPath(path).createImage();
-    }
-
-    /**
-     * Get the ImageDescriptor from a given path
-     *
-     * @param path
-     *            The path to the image file
-     * @return The ImageDescriptor object
-     */
-    public ImageDescriptor getImageDescripterFromPath(String path) {
-        return AbstractUIPlugin.imageDescriptorFromPlugin(PLUGIN_ID, path);
-    }
-
-    /**
-     * Get the Image from a registry
-     *
-     * @param path
-     *            The path to the image registry
-     * @return The Image object
-     */
-    public Image getImageFromImageRegistry(String path) {
-        Image icon = getImageRegistry().get(path);
-        if (icon == null) {
-            icon = getImageDescripterFromPath(path).createImage();
-            plugin.getImageRegistry().put(path, icon);
-        }
-        return icon;
-    }
-
-    /**
-     * Logs a message with severity INFO in the runtime log of the plug-in.
-     *
-     * @param message A message to log
-     */
-    public void logInfo(String message) {
-        getLog().log(new Status(IStatus.INFO, PLUGIN_ID, message));
-    }
-
-    /**
-     * Logs a message and exception with severity INFO in the runtime log of the plug-in.
-     *
-     * @param message A message to log
-     * @param exception A exception to log
-     */
-    public void logInfo(String message, Throwable exception) {
-        getLog().log(new Status(IStatus.INFO, PLUGIN_ID, message, exception));
-    }
-
-    /**
-     * Logs a message and exception with severity WARNING in the runtime log of the plug-in.
-     *
-     * @param message A message to log
-     */
-    public void logWarning(String message) {
-        getLog().log(new Status(IStatus.WARNING, PLUGIN_ID, message));
-    }
-
-    /**
-     * Logs a message and exception with severity WARNING in the runtime log of the plug-in.
-     *
-     * @param message A message to log
-     * @param exception A exception to log
-     */
-    public void logWarning(String message, Throwable exception) {
-        getLog().log(new Status(IStatus.WARNING, PLUGIN_ID, message, exception));
-    }
-
-    /**
-     * Logs a message and exception with severity ERROR in the runtime log of the plug-in.
-     *
-     * @param message A message to log
-     */
-    public void logError(String message) {
-        getLog().log(new Status(IStatus.ERROR, PLUGIN_ID, message));
-    }
-
-    /**
-     * Logs a message and exception with severity ERROR in the runtime log of the plug-in.
-     *
-     * @param message A message to log
-     * @param exception A exception to log
-     */
-    public void logError(String message, Throwable exception) {
-        getLog().log(new Status(IStatus.ERROR, PLUGIN_ID, message, exception));
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.kernel.ui/src/org/eclipse/tracecompass/internal/lttng2/kernel/ui/views/PerspectiveFactory.java b/org.eclipse.tracecompass.lttng2.kernel.ui/src/org/eclipse/tracecompass/internal/lttng2/kernel/ui/views/PerspectiveFactory.java
deleted file mode 100644 (file)
index 92688af..0000000
+++ /dev/null
@@ -1,105 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2012, 2015 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:
- *   Francois Chouinard - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.kernel.ui.views;
-
-import org.eclipse.tracecompass.analysis.os.linux.ui.views.controlflow.ControlFlowView;
-import org.eclipse.tracecompass.analysis.os.linux.ui.views.resources.ResourcesView;
-import org.eclipse.tracecompass.internal.lttng2.control.ui.views.ControlView;
-import org.eclipse.tracecompass.tmf.ui.project.wizards.NewTmfProjectWizard;
-import org.eclipse.tracecompass.tmf.ui.views.histogram.HistogramView;
-import org.eclipse.tracecompass.tmf.ui.views.statistics.TmfStatisticsView;
-import org.eclipse.ui.IFolderLayout;
-import org.eclipse.ui.IPageLayout;
-import org.eclipse.ui.IPerspectiveFactory;
-
-/**
- * The default LTTng perspective.
- */
-public class PerspectiveFactory implements IPerspectiveFactory {
-
-    /** Perspective ID */
-    public static final String ID = "org.eclipse.linuxtools.lttng2.kernel.ui.perspective"; //$NON-NLS-1$
-
-    // LTTng views
-    private static final String HISTOGRAM_VIEW_ID = HistogramView.ID;
-    private static final String CONTROL_VIEW_ID = ControlView.ID;
-    private static final String CONTROLFLOW_VIEW_ID = ControlFlowView.ID;
-    private static final String RESOURCES_VIEW_ID = ResourcesView.ID;
-    private static final String STATISTICS_VIEW_ID = TmfStatisticsView.ID;
-
-    // Standard Eclipse views
-    private static final String PROJECT_VIEW_ID = IPageLayout.ID_PROJECT_EXPLORER;
-    private static final String PROPERTIES_VIEW_ID = IPageLayout.ID_PROP_SHEET;
-    private static final String BOOKMARKS_VIEW_ID = IPageLayout.ID_BOOKMARKS;
-
-    @Override
-    public void createInitialLayout(IPageLayout layout) {
-
-        layout.setEditorAreaVisible(true);
-
-        addFastViews(layout);
-        addViewShortcuts(layout);
-        addPerspectiveShortcuts(layout);
-
-        // Create the top left folder
-        IFolderLayout topLeftFolder = layout.createFolder(
-                "topLeftFolder", IPageLayout.LEFT, 0.15f, IPageLayout.ID_EDITOR_AREA); //$NON-NLS-1$
-        topLeftFolder.addView(PROJECT_VIEW_ID);
-
-        // Create the bottom left folder
-        IFolderLayout bottomLeftFolder = layout.createFolder(
-                "bottomLeftFolder", IPageLayout.BOTTOM, 0.70f, "topLeftFolder"); //$NON-NLS-1$ //$NON-NLS-2$
-        bottomLeftFolder.addView(CONTROL_VIEW_ID);
-
-        // Create the top right folder
-        IFolderLayout topRightFolder = layout.createFolder(
-                "topRightFolder", IPageLayout.TOP, 0.40f, IPageLayout.ID_EDITOR_AREA); //$NON-NLS-1$
-        topRightFolder.addView(CONTROLFLOW_VIEW_ID);
-        topRightFolder.addView(RESOURCES_VIEW_ID);
-        topRightFolder.addView(STATISTICS_VIEW_ID);
-
-        // Create the bottom right folder
-        IFolderLayout bottomRightFolder = layout.createFolder(
-                "bottomRightFolder", IPageLayout.BOTTOM, 0.50f, IPageLayout.ID_EDITOR_AREA); //$NON-NLS-1$
-        bottomRightFolder.addView(HISTOGRAM_VIEW_ID);
-        bottomRightFolder.addView(PROPERTIES_VIEW_ID);
-        bottomRightFolder.addView(BOOKMARKS_VIEW_ID);
-
-        layout.addNewWizardShortcut(NewTmfProjectWizard.ID);
-    }
-
-    /**
-     * Add fast views to the perspective
-     *
-     * @param layout
-     */
-    private void addFastViews(IPageLayout layout) {
-    }
-
-    /**
-     * Add view shortcuts to the perspective
-     *
-     * @param layout
-     */
-    private void addViewShortcuts(IPageLayout layout) {
-    }
-
-    /**
-     * Add perspective shortcuts to the perspective
-     *
-     * @param layout
-     */
-    private void addPerspectiveShortcuts(IPageLayout layout) {
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.kernel/.project b/org.eclipse.tracecompass.lttng2.kernel/.project
deleted file mode 100644 (file)
index 2c8611b..0000000
+++ /dev/null
@@ -1,17 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
-       <name>org.eclipse.tracecompass.lttng2.kernel</name>
-       <comment></comment>
-       <projects>
-       </projects>
-       <buildSpec>
-               <buildCommand>
-                       <name>org.eclipse.pde.FeatureBuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-       </buildSpec>
-       <natures>
-               <nature>org.eclipse.pde.FeatureNature</nature>
-       </natures>
-</projectDescription>
diff --git a/org.eclipse.tracecompass.lttng2.kernel/.settings/org.eclipse.core.resources.prefs b/org.eclipse.tracecompass.lttng2.kernel/.settings/org.eclipse.core.resources.prefs
deleted file mode 100644 (file)
index 99f26c0..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-eclipse.preferences.version=1
-encoding/<project>=UTF-8
diff --git a/org.eclipse.tracecompass.lttng2.kernel/.settings/org.eclipse.core.runtime.prefs b/org.eclipse.tracecompass.lttng2.kernel/.settings/org.eclipse.core.runtime.prefs
deleted file mode 100644 (file)
index 5a0ad22..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-eclipse.preferences.version=1
-line.separator=\n
diff --git a/org.eclipse.tracecompass.lttng2.kernel/build.properties b/org.eclipse.tracecompass.lttng2.kernel/build.properties
deleted file mode 100644 (file)
index 475ce21..0000000
+++ /dev/null
@@ -1,16 +0,0 @@
-###############################################################################
-# Copyright (c) 2013, 2015 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:
-#     Ericsson - Initial API and implementation
-###############################################################################
-
-bin.includes = feature.xml,\
-               feature.properties,\
-               p2.inf
-src.includes = sourceTemplateFeature/p2.inf
diff --git a/org.eclipse.tracecompass.lttng2.kernel/feature.properties b/org.eclipse.tracecompass.lttng2.kernel/feature.properties
deleted file mode 100644 (file)
index 39f25b4..0000000
+++ /dev/null
@@ -1,22 +0,0 @@
-###############################################################################
-# Copyright (c) 2009, 2015 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:
-#     Ericsson - Initial API and implementation
-###############################################################################
-
-featureName=LTTng Kernel Analysis
-
-description=Plug-ins to integrate LTTng Kernel analysis tools into the workbench. \
-Includes the LTTng (Linux Tracing Toolkit), TMF (Tracing and Monitoring Framework) \
-and CTF (Common Trace Format) features.
-
-featureProvider=Eclipse Trace Compass
-
-copyright=Copyright 2015 Ericsson
-
diff --git a/org.eclipse.tracecompass.lttng2.kernel/feature.xml b/org.eclipse.tracecompass.lttng2.kernel/feature.xml
deleted file mode 100644 (file)
index 1579e2f..0000000
+++ /dev/null
@@ -1,81 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- For PDE build, remove "ws" and "arch" -->
-<feature
-      id="org.eclipse.tracecompass.lttng2.kernel"
-      label="%featureName"
-      version="1.0.0.qualifier"
-      provider-name="%featureProvider"
-      license-feature="org.eclipse.license"
-      license-feature-version="0.0.0">
-
-   <description>
-      %description
-   </description>
-
-   <copyright>
-      %copyright
-   </copyright>
-
-   <license url="%licenseURL">
-      %license
-   </license>
-
-   <includes
-         id="org.eclipse.tracecompass.lttng2.control"
-         version="0.0.0"
-         name="Linux Tracing Toolkit next generation (LTTng)"/>
-
-   <includes
-         id="org.eclipse.tracecompass.tmf.ctf"
-         version="0.0.0"
-         name="CTF Support for TMF"/>
-
-   <requires>
-      <import plugin="org.eclipse.core.runtime"/>
-      <import plugin="org.eclipse.core.resources"/>
-      <import plugin="org.eclipse.tracecompass.ctf.core" version="1.0.0" match="greaterOrEqual"/>
-      <import plugin="org.eclipse.tracecompass.tmf.core" version="1.0.0" match="greaterOrEqual"/>
-      <import plugin="org.eclipse.ui"/>
-      <import plugin="org.eclipse.ui.ide"/>
-      <import plugin="org.eclipse.tracecompass.tmf.ui" version="1.0.0" match="greaterOrEqual"/>
-      <import plugin="org.eclipse.tracecompass.lttng2.control.core" version="1.0.0" match="greaterOrEqual"/>
-      <import plugin="org.eclipse.tracecompass.lttng2.control.ui" version="1.0.0" match="greaterOrEqual"/>
-      <import plugin="org.eclipse.tracecompass.lttng2.kernel.core" version="1.0.0" match="greaterOrEqual"/>
-      <import plugin="org.eclipse.help"/>
-   </requires>
-
-   <plugin
-         id="org.eclipse.tracecompass.analysis.os.linux.core"
-         download-size="0"
-         install-size="0"
-         version="0.0.0"
-         unpack="false"/>
-
-   <plugin
-         id="org.eclipse.tracecompass.analysis.os.linux.ui"
-         download-size="0"
-         install-size="0"
-         version="0.0.0"
-         unpack="false"/>
-
-   <plugin
-         id="org.eclipse.tracecompass.lttng2.kernel.core"
-         download-size="0"
-         install-size="0"
-         version="0.0.0"
-         unpack="false"/>
-
-   <plugin
-         id="org.eclipse.tracecompass.lttng2.kernel.ui"
-         download-size="0"
-         install-size="0"
-         version="0.0.0"
-         unpack="false"/>
-
-   <plugin
-         id="org.eclipse.tracecompass.doc.user"
-         download-size="0"
-         install-size="0"
-         version="0.0.0"/>
-
-</feature>
diff --git a/org.eclipse.tracecompass.lttng2.kernel/p2.inf b/org.eclipse.tracecompass.lttng2.kernel/p2.inf
deleted file mode 100644 (file)
index 575b43d..0000000
+++ /dev/null
@@ -1 +0,0 @@
-update.matchExp=providedCapabilities.exists(pc | pc.namespace == 'org.eclipse.equinox.p2.iu' && (pc.name == 'org.eclipse.linuxtools.lttng2.kernel.feature.group' || pc.name == 'org.eclipse.tracecompass.lttng2.kernel.feature.group'))
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.kernel/pom.xml b/org.eclipse.tracecompass.lttng2.kernel/pom.xml
deleted file mode 100644 (file)
index b882df8..0000000
+++ /dev/null
@@ -1,64 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-   Copyright (C) 2011, Red Hat, Inc.
-
-   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
--->
-<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>
-    <artifactId>org.eclipse.tracecompass</artifactId>
-    <groupId>org.eclipse.tracecompass</groupId>
-    <version>1.0.0-SNAPSHOT</version>
-  </parent>
-
-  <artifactId>org.eclipse.tracecompass.lttng2.kernel</artifactId>
-  <version>1.0.0-SNAPSHOT</version>
-  <packaging>eclipse-feature</packaging>
-
-  <name>Trace Compass LTTng Kernel Analysis Feature</name>
-
-  <groupId>org.eclipse.tracecompass</groupId>
-
-  <build>
-    <plugins>
-      <plugin>
-        <groupId>org.eclipse.tycho.extras</groupId>
-        <artifactId>tycho-source-feature-plugin</artifactId>
-        <executions>
-          <execution>
-            <id>source-feature</id>
-            <phase>package</phase>
-            <goals>
-              <goal>source-feature</goal>
-            </goals>
-            <configuration>
-              <excludes>
-                <plugin id="org.eclipse.tracecompass.doc.user"/>
-              </excludes>
-            </configuration>
-          </execution>
-        </executions>
-      </plugin>
-      <plugin>
-        <groupId>org.eclipse.tycho</groupId>
-        <artifactId>tycho-p2-plugin</artifactId>
-        <version>${tycho-version}</version>
-        <executions>
-          <execution>
-            <id>attached-p2-metadata</id>
-            <phase>package</phase>
-            <goals>
-              <goal>p2-metadata</goal>
-            </goals>
-          </execution>
-        </executions>
-      </plugin>
-    </plugins>
-  </build>
-</project>
diff --git a/org.eclipse.tracecompass.lttng2.kernel/sourceTemplateFeature/p2.inf b/org.eclipse.tracecompass.lttng2.kernel/sourceTemplateFeature/p2.inf
deleted file mode 100644 (file)
index bc608b9..0000000
+++ /dev/null
@@ -1 +0,0 @@
-update.matchExp=providedCapabilities.exists(pc | pc.namespace == 'org.eclipse.equinox.p2.iu' && (pc.name == 'org.eclipse.linuxtools.lttng2.kernel.source.feature.group' || pc.name == 'org.eclipse.tracecompass.lttng2.kernel.source.feature.group'))
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.ust.core.tests/.classpath b/org.eclipse.tracecompass.lttng2.ust.core.tests/.classpath
deleted file mode 100644 (file)
index 098194c..0000000
+++ /dev/null
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
-       <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7"/>
-       <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
-       <classpathentry kind="src" path="src"/>
-       <classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/org.eclipse.tracecompass.lttng2.ust.core.tests/.project b/org.eclipse.tracecompass.lttng2.ust.core.tests/.project
deleted file mode 100644 (file)
index 1ebf5c3..0000000
+++ /dev/null
@@ -1,34 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
-       <name>org.eclipse.tracecompass.lttng2.ust.core.tests</name>
-       <comment></comment>
-       <projects>
-       </projects>
-       <buildSpec>
-               <buildCommand>
-                       <name>org.eclipse.jdt.core.javabuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-               <buildCommand>
-                       <name>org.eclipse.pde.ManifestBuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-               <buildCommand>
-                       <name>org.eclipse.pde.SchemaBuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-               <buildCommand>
-                       <name>org.eclipse.pde.api.tools.apiAnalysisBuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-       </buildSpec>
-       <natures>
-               <nature>org.eclipse.pde.PluginNature</nature>
-               <nature>org.eclipse.jdt.core.javanature</nature>
-               <nature>org.eclipse.pde.api.tools.apiAnalysisNature</nature>
-       </natures>
-</projectDescription>
diff --git a/org.eclipse.tracecompass.lttng2.ust.core.tests/.settings/org.eclipse.core.resources.prefs b/org.eclipse.tracecompass.lttng2.ust.core.tests/.settings/org.eclipse.core.resources.prefs
deleted file mode 100644 (file)
index 99f26c0..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-eclipse.preferences.version=1
-encoding/<project>=UTF-8
diff --git a/org.eclipse.tracecompass.lttng2.ust.core.tests/.settings/org.eclipse.core.runtime.prefs b/org.eclipse.tracecompass.lttng2.ust.core.tests/.settings/org.eclipse.core.runtime.prefs
deleted file mode 100644 (file)
index 5a0ad22..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-eclipse.preferences.version=1
-line.separator=\n
diff --git a/org.eclipse.tracecompass.lttng2.ust.core.tests/.settings/org.eclipse.jdt.core.prefs b/org.eclipse.tracecompass.lttng2.ust.core.tests/.settings/org.eclipse.jdt.core.prefs
deleted file mode 100644 (file)
index 0409c61..0000000
+++ /dev/null
@@ -1,403 +0,0 @@
-eclipse.preferences.version=1
-org.eclipse.jdt.core.codeComplete.argumentPrefixes=
-org.eclipse.jdt.core.codeComplete.argumentSuffixes=
-org.eclipse.jdt.core.codeComplete.fieldPrefixes=f
-org.eclipse.jdt.core.codeComplete.fieldSuffixes=
-org.eclipse.jdt.core.codeComplete.localPrefixes=
-org.eclipse.jdt.core.codeComplete.localSuffixes=
-org.eclipse.jdt.core.codeComplete.staticFieldPrefixes=
-org.eclipse.jdt.core.codeComplete.staticFieldSuffixes=
-org.eclipse.jdt.core.codeComplete.staticFinalFieldPrefixes=
-org.eclipse.jdt.core.codeComplete.staticFinalFieldSuffixes=
-org.eclipse.jdt.core.compiler.annotation.inheritNullAnnotations=enabled
-org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore
-org.eclipse.jdt.core.compiler.annotation.nonnull=org.eclipse.jdt.annotation.NonNull
-org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=org.eclipse.jdt.annotation.NonNullByDefault
-org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nullable
-org.eclipse.jdt.core.compiler.annotation.nullanalysis=enabled
-org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
-org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
-org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
-org.eclipse.jdt.core.compiler.compliance=1.7
-org.eclipse.jdt.core.compiler.debug.lineNumber=generate
-org.eclipse.jdt.core.compiler.debug.localVariable=generate
-org.eclipse.jdt.core.compiler.debug.sourceFile=generate
-org.eclipse.jdt.core.compiler.doc.comment.support=enabled
-org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=error
-org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
-org.eclipse.jdt.core.compiler.problem.autoboxing=ignore
-org.eclipse.jdt.core.compiler.problem.comparingIdentical=error
-org.eclipse.jdt.core.compiler.problem.deadCode=error
-org.eclipse.jdt.core.compiler.problem.deprecation=error
-org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled
-org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=enabled
-org.eclipse.jdt.core.compiler.problem.discouragedReference=error
-org.eclipse.jdt.core.compiler.problem.emptyStatement=error
-org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
-org.eclipse.jdt.core.compiler.problem.explicitlyClosedAutoCloseable=error
-org.eclipse.jdt.core.compiler.problem.fallthroughCase=error
-org.eclipse.jdt.core.compiler.problem.fatalOptionalError=disabled
-org.eclipse.jdt.core.compiler.problem.fieldHiding=error
-org.eclipse.jdt.core.compiler.problem.finalParameterBound=error
-org.eclipse.jdt.core.compiler.problem.finallyBlockNotCompletingNormally=error
-org.eclipse.jdt.core.compiler.problem.forbiddenReference=error
-org.eclipse.jdt.core.compiler.problem.hiddenCatchBlock=error
-org.eclipse.jdt.core.compiler.problem.includeNullInfoFromAsserts=disabled
-org.eclipse.jdt.core.compiler.problem.incompatibleNonInheritedInterfaceMethod=error
-org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch=error
-org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=error
-org.eclipse.jdt.core.compiler.problem.invalidJavadoc=warning
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTags=enabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsDeprecatedRef=enabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsNotVisibleRef=enabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsVisibility=protected
-org.eclipse.jdt.core.compiler.problem.localVariableHiding=error
-org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=error
-org.eclipse.jdt.core.compiler.problem.missingDefaultCase=error
-org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=error
-org.eclipse.jdt.core.compiler.problem.missingEnumCaseDespiteDefault=enabled
-org.eclipse.jdt.core.compiler.problem.missingHashCodeMethod=error
-org.eclipse.jdt.core.compiler.problem.missingJavadocComments=warning
-org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsOverriding=disabled
-org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsVisibility=protected
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagDescription=all_standard_tags
-org.eclipse.jdt.core.compiler.problem.missingJavadocTags=warning
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagsMethodTypeParameters=disabled
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagsOverriding=disabled
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagsVisibility=protected
-org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotation=error
-org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotationForInterfaceMethodImplementation=enabled
-org.eclipse.jdt.core.compiler.problem.missingSerialVersion=error
-org.eclipse.jdt.core.compiler.problem.missingSynchronizedOnInheritedMethod=error
-org.eclipse.jdt.core.compiler.problem.noEffectAssignment=error
-org.eclipse.jdt.core.compiler.problem.noImplicitStringConversion=error
-org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=ignore
-org.eclipse.jdt.core.compiler.problem.nonnullParameterAnnotationDropped=warning
-org.eclipse.jdt.core.compiler.problem.nullAnnotationInferenceConflict=warning
-org.eclipse.jdt.core.compiler.problem.nullReference=error
-org.eclipse.jdt.core.compiler.problem.nullSpecViolation=error
-org.eclipse.jdt.core.compiler.problem.nullUncheckedConversion=warning
-org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=error
-org.eclipse.jdt.core.compiler.problem.parameterAssignment=error
-org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=error
-org.eclipse.jdt.core.compiler.problem.potentialNullReference=error
-org.eclipse.jdt.core.compiler.problem.potentiallyUnclosedCloseable=warning
-org.eclipse.jdt.core.compiler.problem.rawTypeReference=error
-org.eclipse.jdt.core.compiler.problem.redundantNullAnnotation=warning
-org.eclipse.jdt.core.compiler.problem.redundantNullCheck=error
-org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=error
-org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=error
-org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore
-org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=error
-org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled
-org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=error
-org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=disabled
-org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled
-org.eclipse.jdt.core.compiler.problem.syntacticNullAnalysisForFields=enabled
-org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=ignore
-org.eclipse.jdt.core.compiler.problem.typeParameterHiding=error
-org.eclipse.jdt.core.compiler.problem.unavoidableGenericTypeProblems=disabled
-org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=error
-org.eclipse.jdt.core.compiler.problem.unclosedCloseable=error
-org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=ignore
-org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=error
-org.eclipse.jdt.core.compiler.problem.unnecessaryElse=error
-org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=error
-org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=error
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionExemptExceptionAndThrowable=disabled
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionIncludeDocCommentReference=disabled
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverriding=disabled
-org.eclipse.jdt.core.compiler.problem.unusedImport=error
-org.eclipse.jdt.core.compiler.problem.unusedLabel=error
-org.eclipse.jdt.core.compiler.problem.unusedLocal=error
-org.eclipse.jdt.core.compiler.problem.unusedObjectAllocation=ignore
-org.eclipse.jdt.core.compiler.problem.unusedParameter=ignore
-org.eclipse.jdt.core.compiler.problem.unusedParameterIncludeDocCommentReference=enabled
-org.eclipse.jdt.core.compiler.problem.unusedParameterWhenImplementingAbstract=disabled
-org.eclipse.jdt.core.compiler.problem.unusedParameterWhenOverridingConcrete=disabled
-org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=error
-org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=ignore
-org.eclipse.jdt.core.compiler.problem.unusedWarningToken=error
-org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=error
-org.eclipse.jdt.core.compiler.source=1.7
-org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_call=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression=16
-org.eclipse.jdt.core.formatter.alignment_for_assignment=0
-org.eclipse.jdt.core.formatter.alignment_for_binary_expression=16
-org.eclipse.jdt.core.formatter.alignment_for_compact_if=16
-org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=80
-org.eclipse.jdt.core.formatter.alignment_for_enum_constants=0
-org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=16
-org.eclipse.jdt.core.formatter.alignment_for_method_declaration=0
-org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16
-org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=80
-org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation=0
-org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_constructor_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_method_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_union_type_in_multicatch=16
-org.eclipse.jdt.core.formatter.blank_lines_after_imports=1
-org.eclipse.jdt.core.formatter.blank_lines_after_package=1
-org.eclipse.jdt.core.formatter.blank_lines_before_field=0
-org.eclipse.jdt.core.formatter.blank_lines_before_first_class_body_declaration=0
-org.eclipse.jdt.core.formatter.blank_lines_before_imports=1
-org.eclipse.jdt.core.formatter.blank_lines_before_member_type=1
-org.eclipse.jdt.core.formatter.blank_lines_before_method=1
-org.eclipse.jdt.core.formatter.blank_lines_before_new_chunk=1
-org.eclipse.jdt.core.formatter.blank_lines_before_package=0
-org.eclipse.jdt.core.formatter.blank_lines_between_import_groups=1
-org.eclipse.jdt.core.formatter.blank_lines_between_type_declarations=1
-org.eclipse.jdt.core.formatter.brace_position_for_annotation_type_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_array_initializer=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_block=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_block_in_case=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_constructor_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_enum_constant=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_enum_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_method_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_switch=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_type_declaration=end_of_line
-org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_block_comment=false
-org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_javadoc_comment=false
-org.eclipse.jdt.core.formatter.comment.format_block_comments=true
-org.eclipse.jdt.core.formatter.comment.format_header=false
-org.eclipse.jdt.core.formatter.comment.format_html=true
-org.eclipse.jdt.core.formatter.comment.format_javadoc_comments=true
-org.eclipse.jdt.core.formatter.comment.format_line_comments=true
-org.eclipse.jdt.core.formatter.comment.format_source_code=true
-org.eclipse.jdt.core.formatter.comment.indent_parameter_description=true
-org.eclipse.jdt.core.formatter.comment.indent_root_tags=true
-org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags=insert
-org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter=insert
-org.eclipse.jdt.core.formatter.comment.line_length=80
-org.eclipse.jdt.core.formatter.comment.new_lines_at_block_boundaries=true
-org.eclipse.jdt.core.formatter.comment.new_lines_at_javadoc_boundaries=true
-org.eclipse.jdt.core.formatter.comment.preserve_white_space_between_code_and_line_comments=false
-org.eclipse.jdt.core.formatter.compact_else_if=true
-org.eclipse.jdt.core.formatter.continuation_indentation=2
-org.eclipse.jdt.core.formatter.continuation_indentation_for_array_initializer=2
-org.eclipse.jdt.core.formatter.disabling_tag=@formatter\:off
-org.eclipse.jdt.core.formatter.enabling_tag=@formatter\:on
-org.eclipse.jdt.core.formatter.format_guardian_clause_on_one_line=false
-org.eclipse.jdt.core.formatter.format_line_comment_starting_on_first_column=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_annotation_declaration_header=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_constant_header=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_declaration_header=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_type_header=true
-org.eclipse.jdt.core.formatter.indent_breaks_compare_to_cases=true
-org.eclipse.jdt.core.formatter.indent_empty_lines=false
-org.eclipse.jdt.core.formatter.indent_statements_compare_to_block=true
-org.eclipse.jdt.core.formatter.indent_statements_compare_to_body=true
-org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_cases=true
-org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_switch=false
-org.eclipse.jdt.core.formatter.indentation.size=4
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_field=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_local_variable=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_method=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_package=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_parameter=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_type=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_label=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_opening_brace_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_at_end_of_file_if_missing=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_finally_in_try_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_while_in_do_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_annotation_declaration=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_anonymous_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_block=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter=insert
-org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_binary_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_paren_in_cast=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_assert=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_case=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_labeled_statement=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_allocation_expression=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_annotation=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_throws=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_constant_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_declarations=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_explicitconstructorcall_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_increments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_inits=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_throws=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_invocation_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_field_declarations=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_local_declarations=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_parameterized_type_reference=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_superinterfaces=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_ellipsis=insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_brace_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_cast=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_catch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_for=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_if=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_parenthesized_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_switch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_synchronized=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_try=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_while=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_try_resources=insert
-org.eclipse.jdt.core.formatter.insert_space_after_unary_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter=insert
-org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_binary_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_brace_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_cast=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_catch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_for=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_if=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_parenthesized_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_switch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_synchronized=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_try=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_while=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_assert=insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_case=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_default=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_labeled_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_throws=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_constant_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_declarations=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_explicitconstructorcall_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_increments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_inits=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_throws=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_invocation_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_field_declarations=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_local_declarations=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_superinterfaces=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_ellipsis=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_annotation_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_anonymous_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_block=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_constructor_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_constant=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_method_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_switch=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation_type_member_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_catch=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_if=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_parenthesized_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_switch=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_synchronized=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_try=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_while=insert
-org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_return=insert
-org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_throw=insert
-org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_semicolon=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_try_resources=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_unary_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_brackets_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_annotation_type_member_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.join_lines_in_comments=true
-org.eclipse.jdt.core.formatter.join_wrapped_lines=false
-org.eclipse.jdt.core.formatter.keep_else_statement_on_same_line=false
-org.eclipse.jdt.core.formatter.keep_empty_array_initializer_on_one_line=false
-org.eclipse.jdt.core.formatter.keep_imple_if_on_one_line=false
-org.eclipse.jdt.core.formatter.keep_then_statement_on_same_line=false
-org.eclipse.jdt.core.formatter.lineSplit=250
-org.eclipse.jdt.core.formatter.never_indent_block_comments_on_first_column=false
-org.eclipse.jdt.core.formatter.never_indent_line_comments_on_first_column=false
-org.eclipse.jdt.core.formatter.number_of_blank_lines_at_beginning_of_method_body=0
-org.eclipse.jdt.core.formatter.number_of_empty_lines_to_preserve=1
-org.eclipse.jdt.core.formatter.put_empty_statement_on_new_line=true
-org.eclipse.jdt.core.formatter.tabulation.char=space
-org.eclipse.jdt.core.formatter.tabulation.size=4
-org.eclipse.jdt.core.formatter.use_on_off_tags=false
-org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false
-org.eclipse.jdt.core.formatter.wrap_before_binary_operator=true
-org.eclipse.jdt.core.formatter.wrap_before_or_operator_multicatch=true
-org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true
diff --git a/org.eclipse.tracecompass.lttng2.ust.core.tests/.settings/org.eclipse.jdt.ui.prefs b/org.eclipse.tracecompass.lttng2.ust.core.tests/.settings/org.eclipse.jdt.ui.prefs
deleted file mode 100644 (file)
index 232a3fd..0000000
+++ /dev/null
@@ -1,60 +0,0 @@
-eclipse.preferences.version=1
-editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true
-formatter_profile=_tmf-style
-formatter_settings_version=12
-org.eclipse.jdt.ui.exception.name=e
-org.eclipse.jdt.ui.gettersetter.use.is=true
-org.eclipse.jdt.ui.keywordthis=false
-org.eclipse.jdt.ui.overrideannotation=true
-sp_cleanup.add_default_serial_version_id=true
-sp_cleanup.add_generated_serial_version_id=false
-sp_cleanup.add_missing_annotations=false
-sp_cleanup.add_missing_deprecated_annotations=true
-sp_cleanup.add_missing_methods=false
-sp_cleanup.add_missing_nls_tags=false
-sp_cleanup.add_missing_override_annotations=true
-sp_cleanup.add_missing_override_annotations_interface_methods=true
-sp_cleanup.add_serial_version_id=false
-sp_cleanup.always_use_blocks=true
-sp_cleanup.always_use_parentheses_in_expressions=false
-sp_cleanup.always_use_this_for_non_static_field_access=false
-sp_cleanup.always_use_this_for_non_static_method_access=false
-sp_cleanup.convert_to_enhanced_for_loop=false
-sp_cleanup.correct_indentation=false
-sp_cleanup.format_source_code=false
-sp_cleanup.format_source_code_changes_only=false
-sp_cleanup.make_local_variable_final=false
-sp_cleanup.make_parameters_final=false
-sp_cleanup.make_private_fields_final=true
-sp_cleanup.make_type_abstract_if_missing_method=false
-sp_cleanup.make_variable_declarations_final=false
-sp_cleanup.never_use_blocks=false
-sp_cleanup.never_use_parentheses_in_expressions=true
-sp_cleanup.on_save_use_additional_actions=true
-sp_cleanup.organize_imports=false
-sp_cleanup.qualify_static_field_accesses_with_declaring_class=false
-sp_cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=true
-sp_cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=true
-sp_cleanup.qualify_static_member_accesses_with_declaring_class=false
-sp_cleanup.qualify_static_method_accesses_with_declaring_class=false
-sp_cleanup.remove_private_constructors=true
-sp_cleanup.remove_trailing_whitespaces=true
-sp_cleanup.remove_trailing_whitespaces_all=true
-sp_cleanup.remove_trailing_whitespaces_ignore_empty=false
-sp_cleanup.remove_unnecessary_casts=false
-sp_cleanup.remove_unnecessary_nls_tags=false
-sp_cleanup.remove_unused_imports=false
-sp_cleanup.remove_unused_local_variables=false
-sp_cleanup.remove_unused_private_fields=true
-sp_cleanup.remove_unused_private_members=false
-sp_cleanup.remove_unused_private_methods=true
-sp_cleanup.remove_unused_private_types=true
-sp_cleanup.sort_members=false
-sp_cleanup.sort_members_all=false
-sp_cleanup.use_blocks=true
-sp_cleanup.use_blocks_only_for_return_and_throw=false
-sp_cleanup.use_parentheses_in_expressions=false
-sp_cleanup.use_this_for_non_static_field_access=false
-sp_cleanup.use_this_for_non_static_field_access_only_if_necessary=true
-sp_cleanup.use_this_for_non_static_method_access=false
-sp_cleanup.use_this_for_non_static_method_access_only_if_necessary=true
diff --git a/org.eclipse.tracecompass.lttng2.ust.core.tests/.settings/org.eclipse.pde.api.tools.prefs b/org.eclipse.tracecompass.lttng2.ust.core.tests/.settings/org.eclipse.pde.api.tools.prefs
deleted file mode 100644 (file)
index acc3abd..0000000
+++ /dev/null
@@ -1,97 +0,0 @@
-ANNOTATION_ELEMENT_TYPE_ADDED_METHOD_WITHOUT_DEFAULT_VALUE=Error
-ANNOTATION_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-ANNOTATION_ELEMENT_TYPE_REMOVED_FIELD=Error
-ANNOTATION_ELEMENT_TYPE_REMOVED_METHOD=Error
-ANNOTATION_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_API_TYPE=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_API_TYPE=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_TYPE=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_TYPE=Error
-API_USE_SCAN_FIELD_SEVERITY=Error
-API_USE_SCAN_METHOD_SEVERITY=Error
-API_USE_SCAN_TYPE_SEVERITY=Error
-CLASS_ELEMENT_TYPE_ADDED_METHOD=Error
-CLASS_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
-CLASS_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-CLASS_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
-CLASS_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-CLASS_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
-CLASS_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
-CLASS_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-CLASS_ELEMENT_TYPE_REMOVED_CONSTRUCTOR=Error
-CLASS_ELEMENT_TYPE_REMOVED_FIELD=Error
-CLASS_ELEMENT_TYPE_REMOVED_METHOD=Error
-CLASS_ELEMENT_TYPE_REMOVED_SUPERCLASS=Error
-CLASS_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-CLASS_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-CONSTRUCTOR_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-CONSTRUCTOR_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-CONSTRUCTOR_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
-CONSTRUCTOR_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-ENUM_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
-ENUM_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-ENUM_ELEMENT_TYPE_REMOVED_ENUM_CONSTANT=Error
-ENUM_ELEMENT_TYPE_REMOVED_FIELD=Error
-ENUM_ELEMENT_TYPE_REMOVED_METHOD=Error
-ENUM_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-FIELD_ELEMENT_TYPE_ADDED_VALUE=Error
-FIELD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-FIELD_ELEMENT_TYPE_CHANGED_FINAL_TO_NON_FINAL_STATIC_CONSTANT=Error
-FIELD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
-FIELD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
-FIELD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
-FIELD_ELEMENT_TYPE_CHANGED_TYPE=Error
-FIELD_ELEMENT_TYPE_CHANGED_VALUE=Error
-FIELD_ELEMENT_TYPE_REMOVED_TYPE_ARGUMENT=Error
-FIELD_ELEMENT_TYPE_REMOVED_VALUE=Error
-ILLEGAL_EXTEND=Warning
-ILLEGAL_IMPLEMENT=Warning
-ILLEGAL_INSTANTIATE=Warning
-ILLEGAL_OVERRIDE=Warning
-ILLEGAL_REFERENCE=Warning
-INTERFACE_ELEMENT_TYPE_ADDED_FIELD=Error
-INTERFACE_ELEMENT_TYPE_ADDED_METHOD=Error
-INTERFACE_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
-INTERFACE_ELEMENT_TYPE_ADDED_SUPER_INTERFACE_WITH_METHODS=Error
-INTERFACE_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-INTERFACE_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
-INTERFACE_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_FIELD=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_METHOD=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-INVALID_JAVADOC_TAG=Warning
-INVALID_REFERENCE_IN_SYSTEM_LIBRARIES=Warning
-LEAK_EXTEND=Warning
-LEAK_FIELD_DECL=Warning
-LEAK_IMPLEMENT=Warning
-LEAK_METHOD_PARAM=Warning
-LEAK_METHOD_RETURN_TYPE=Warning
-METHOD_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
-METHOD_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-METHOD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-METHOD_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
-METHOD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
-METHOD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
-METHOD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
-METHOD_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
-METHOD_ELEMENT_TYPE_REMOVED_ANNOTATION_DEFAULT_VALUE=Error
-METHOD_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-MISSING_EE_DESCRIPTIONS=Ignore
-TYPE_PARAMETER_ELEMENT_TYPE_ADDED_CLASS_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_ADDED_INTERFACE_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_CLASS_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_INTERFACE_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_CLASS_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_INTERFACE_BOUND=Error
-UNUSED_PROBLEM_FILTERS=Warning
-automatically_removed_unused_problem_filters=false
-eclipse.preferences.version=1
-incompatible_api_component_version=Error
-incompatible_api_component_version_include_major_without_breaking_change=Disabled
-incompatible_api_component_version_include_minor_without_api_change=Disabled
-invalid_since_tag_version=Error
-malformed_since_tag=Error
-missing_since_tag=Error
-report_api_breakage_when_major_version_incremented=Disabled
-report_resolution_errors_api_component=Warning
diff --git a/org.eclipse.tracecompass.lttng2.ust.core.tests/.settings/org.eclipse.pde.prefs b/org.eclipse.tracecompass.lttng2.ust.core.tests/.settings/org.eclipse.pde.prefs
deleted file mode 100644 (file)
index 62cfa90..0000000
+++ /dev/null
@@ -1,32 +0,0 @@
-compilers.f.unresolved-features=1
-compilers.f.unresolved-plugins=1
-compilers.incompatible-environment=1
-compilers.p.build=1
-compilers.p.build.bin.includes=1
-compilers.p.build.encodings=2
-compilers.p.build.java.compiler=2
-compilers.p.build.java.compliance=1
-compilers.p.build.missing.output=2
-compilers.p.build.output.library=1
-compilers.p.build.source.library=1
-compilers.p.build.src.includes=1
-compilers.p.deprecated=1
-compilers.p.discouraged-class=1
-compilers.p.internal=1
-compilers.p.missing-packages=2
-compilers.p.missing-version-export-package=2
-compilers.p.missing-version-import-package=2
-compilers.p.missing-version-require-bundle=2
-compilers.p.no-required-att=0
-compilers.p.not-externalized-att=2
-compilers.p.unknown-attribute=1
-compilers.p.unknown-class=1
-compilers.p.unknown-element=1
-compilers.p.unknown-identifier=1
-compilers.p.unknown-resource=1
-compilers.p.unresolved-ex-points=0
-compilers.p.unresolved-import=0
-compilers.s.create-docs=false
-compilers.s.doc-folder=doc
-compilers.s.open-tags=1
-eclipse.preferences.version=1
diff --git a/org.eclipse.tracecompass.lttng2.ust.core.tests/META-INF/MANIFEST.MF b/org.eclipse.tracecompass.lttng2.ust.core.tests/META-INF/MANIFEST.MF
deleted file mode 100644 (file)
index 16eade2..0000000
+++ /dev/null
@@ -1,22 +0,0 @@
-Manifest-Version: 1.0
-Bundle-ManifestVersion: 2
-Bundle-Name: %Bundle-Name
-Bundle-Vendor: %Bundle-Vendor
-Bundle-Version: 1.0.0.qualifier
-Bundle-Localization: plugin
-Bundle-SymbolicName: org.eclipse.tracecompass.lttng2.ust.core.tests;singleton:=true
-Bundle-ActivationPolicy: lazy
-Bundle-RequiredExecutionEnvironment: JavaSE-1.7
-Require-Bundle: org.junit;bundle-version="4.0.0",
- org.eclipse.core.resources,
- org.eclipse.core.runtime,
- org.eclipse.tracecompass.common.core,
- org.eclipse.tracecompass.tmf.core,
- org.eclipse.tracecompass.tmf.core.tests,
- org.eclipse.tracecompass.tmf.ctf.core,
- org.eclipse.tracecompass.tmf.ctf.core.tests,
- org.eclipse.tracecompass.lttng2.ust.core,
- org.eclipse.tracecompass.lttng2.control.core
-Export-Package: org.eclipse.tracecompass.lttng2.ust.core.tests,
- org.eclipse.tracecompass.lttng2.ust.core.tests.callstack
-Import-Package: com.google.common.collect
diff --git a/org.eclipse.tracecompass.lttng2.ust.core.tests/about.html b/org.eclipse.tracecompass.lttng2.ust.core.tests/about.html
deleted file mode 100644 (file)
index c258ef5..0000000
+++ /dev/null
@@ -1,28 +0,0 @@
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
-    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml">
-<head>
-<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"/>
-<title>About</title>
-</head>
-<body lang="EN-US">
-<h2>About This Content</h2>
-<p>June 5, 2006</p>    
-<h3>License</h3>
-
-<p>The Eclipse Foundation makes available all content in this plug-in (&quot;Content&quot;).  Unless otherwise 
-indicated below, the Content is provided to you under the terms and conditions of the
-Eclipse Public License Version 1.0 (&quot;EPL&quot;).  A copy of the EPL is available 
-at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>.
-For purposes of the EPL, &quot;Program&quot; will mean the Content.</p>
-
-<p>If you did not receive this Content directly from the Eclipse Foundation, the Content is 
-being redistributed by another party (&quot;Redistributor&quot;) and different terms and conditions may
-apply to your use of any object code in the Content.  Check the Redistributor's license that was 
-provided with the Content.  If no such license exists, contact the Redistributor.  Unless otherwise
-indicated below, the terms and conditions of the EPL still apply to any source code in the Content
-and such source code may be obtained at <a href="http://www.eclipse.org/">http://www.eclipse.org</a>.</p>
-
-</body>
-</html>
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.ust.core.tests/build.properties b/org.eclipse.tracecompass.lttng2.ust.core.tests/build.properties
deleted file mode 100644 (file)
index 64c09cd..0000000
+++ /dev/null
@@ -1,21 +0,0 @@
-###############################################################################
-# Copyright (c) 2013, 2014 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:
-#     Ericsson - Initial API and implementation
-###############################################################################
-
-source.. = src/
-output.. = bin/
-bin.includes = META-INF/,\
-               .,\
-               about.html,\
-               plugin.properties
-src.includes = about.html
-additional.bundles = org.eclipse.jdt.annotation
-jars.extra.classpath = platform:/plugin/org.eclipse.jdt.annotation
diff --git a/org.eclipse.tracecompass.lttng2.ust.core.tests/plugin.properties b/org.eclipse.tracecompass.lttng2.ust.core.tests/plugin.properties
deleted file mode 100644 (file)
index 9bd944f..0000000
+++ /dev/null
@@ -1,14 +0,0 @@
-###############################################################################
-# Copyright (c) 2013, 2014 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:
-#     Ericsson - Initial API and implementation
-###############################################################################
-
-Bundle-Vendor = Eclipse Trace Compass
-Bundle-Name = Trace Compass LTTng Userspace Tracer Analysis Core Tests Plug-in
diff --git a/org.eclipse.tracecompass.lttng2.ust.core.tests/pom.xml b/org.eclipse.tracecompass.lttng2.ust.core.tests/pom.xml
deleted file mode 100644 (file)
index 1c6aa88..0000000
+++ /dev/null
@@ -1,42 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-   Copyright (C) 2011, 2013 Red Hat Inc., 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
--->
-<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>
-    <artifactId>org.eclipse.tracecompass</artifactId>
-    <groupId>org.eclipse.tracecompass</groupId>
-    <version>1.0.0-SNAPSHOT</version>
-  </parent>
-
-  <artifactId>org.eclipse.tracecompass.lttng2.ust.core.tests</artifactId>
-  <version>1.0.0-SNAPSHOT</version>
-  <packaging>eclipse-test-plugin</packaging>
-
-  <name>Trace Compass LTTng Userspace Tracer Analysis Core Test Plug-in</name>
-
-  <build>
-    <plugins>
-      <plugin>
-        <groupId>org.eclipse.tycho</groupId>
-        <artifactId>tycho-surefire-plugin</artifactId>
-        <version>${tycho-version}</version>
-        <configuration>
-          <useUIHarness>false</useUIHarness>
-          <useUIThread>false</useUIThread>
-          <product>org.eclipse.platform.ide</product>
-        </configuration>
-      </plugin>
-    </plugins>
-  </build>
-
-  <groupId>org.eclipse.tracecompass</groupId>
-</project>
diff --git a/org.eclipse.tracecompass.lttng2.ust.core.tests/src/org/eclipse/tracecompass/lttng2/ust/core/tests/ActivatorTest.java b/org.eclipse.tracecompass.lttng2.ust.core.tests/src/org/eclipse/tracecompass/lttng2/ust/core/tests/ActivatorTest.java
deleted file mode 100644 (file)
index 53dbe91..0000000
+++ /dev/null
@@ -1,96 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2013, 2015 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:
- *   Alexandre Montplaisir - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.ust.core.tests;
-
-import junit.framework.TestCase;
-
-import org.junit.After;
-import org.junit.AfterClass;
-import org.junit.Before;
-import org.junit.BeforeClass;
-import org.junit.Test;
-
-/**
- * <b><u>ActivatorTest</u></b>
- * <p>
- * Test suite for the Activator class
- * <p>
- */
-@SuppressWarnings("javadoc")
-public class ActivatorTest extends TestCase {
-
-    // ------------------------------------------------------------------------
-    // JUnit
-    // ------------------------------------------------------------------------
-
-    @BeforeClass
-    public static void setUpBeforeClass() {
-    }
-
-    @AfterClass
-    public static void tearDownAfterClass() {
-    }
-
-    /**
-     * @throws java.lang.Exception
-     */
-    @Before
-    @Override
-    public void setUp() throws Exception {
-    }
-
-    /**
-     * @throws java.lang.Exception
-     */
-    @After
-    @Override
-    public void tearDown() throws Exception {
-    }
-
-    // ------------------------------------------------------------------------
-    // Tests
-    // ------------------------------------------------------------------------
-
-    /**
-     * Test method for {@link org.eclipse.tracecompass.internal.lttng2.ust.core.Activator#Activator()}.
-     */
-    @Test
-    public void testActivator() {
-        assertTrue(true);
-    }
-
-    /**
-     * Test method for {@link org.eclipse.tracecompass.internal.lttng2.ust.core.Activator#getDefault()}.
-     */
-    @Test
-    public void testGetDefault() {
-        assertTrue(true);
-    }
-
-    /**
-     * Test method for {@link org.eclipse.tracecompass.internal.lttng2.ust.core.Activator#start(org.osgi.framework.BundleContext)}.
-     */
-    @Test
-    public void testStartBundleContext() {
-        assertTrue(true);
-    }
-
-    /**
-     * Test method for {@link org.eclipse.tracecompass.internal.lttng2.ust.core.Activator#stop(org.osgi.framework.BundleContext)}.
-     */
-    @Test
-    public void testStopBundleContext() {
-        assertTrue(true);
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.ust.core.tests/src/org/eclipse/tracecompass/lttng2/ust/core/tests/AllTests.java b/org.eclipse.tracecompass.lttng2.ust.core.tests/src/org/eclipse/tracecompass/lttng2/ust/core/tests/AllTests.java
deleted file mode 100644 (file)
index 36ed9f1..0000000
+++ /dev/null
@@ -1,29 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2013, 2014 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:
- *   Alexandre Montplaisir - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.ust.core.tests;
-
-import org.eclipse.tracecompass.tmf.core.tests.shared.DebugSuite;
-import org.junit.runner.RunWith;
-
-/**
- * Runner for the lttng2.kernel unit tests.
- */
-@RunWith(DebugSuite.class)
-@DebugSuite.SuiteClasses({
-    ActivatorTest.class,
-    org.eclipse.tracecompass.lttng2.ust.core.tests.analysis.memory.AllTests.class,
-    org.eclipse.tracecompass.lttng2.ust.core.tests.callstack.AllTests.class
-})
-public class AllTests {
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.ust.core.tests/src/org/eclipse/tracecompass/lttng2/ust/core/tests/analysis/memory/AllTests.java b/org.eclipse.tracecompass.lttng2.ust.core.tests/src/org/eclipse/tracecompass/lttng2/ust/core/tests/analysis/memory/AllTests.java
deleted file mode 100644 (file)
index 495af20..0000000
+++ /dev/null
@@ -1,27 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2014 École Polytechnique de Montréal
- *
- * 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:
- *   Guilliano Molaire - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.ust.core.tests.analysis.memory;
-
-import org.junit.runner.RunWith;
-import org.junit.runners.Suite;
-
-/**
- * Test suite.
- */
-@RunWith(Suite.class)
-@Suite.SuiteClasses({
-    UstMemoryAnalysisModuleTest.class
-})
-public class AllTests {
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.ust.core.tests/src/org/eclipse/tracecompass/lttng2/ust/core/tests/analysis/memory/UstMemoryAnalysisModuleTest.java b/org.eclipse.tracecompass.lttng2.ust.core.tests/src/org/eclipse/tracecompass/lttng2/ust/core/tests/analysis/memory/UstMemoryAnalysisModuleTest.java
deleted file mode 100644 (file)
index 0ec8f10..0000000
+++ /dev/null
@@ -1,101 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2014 École Polytechnique de Montréal
- *
- * 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:
- *   Guilliano Molaire - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.ust.core.tests.analysis.memory;
-
-import static org.junit.Assert.assertEquals;
-import static org.junit.Assert.assertNotNull;
-import static org.junit.Assert.assertTrue;
-
-import java.util.Set;
-
-import org.eclipse.tracecompass.internal.lttng2.ust.core.analysis.memory.UstMemoryStrings;
-import org.eclipse.tracecompass.lttng2.control.core.session.SessionConfigStrings;
-import org.eclipse.tracecompass.lttng2.ust.core.analysis.memory.UstMemoryAnalysisModule;
-import org.eclipse.tracecompass.tmf.core.analysis.TmfAnalysisRequirement;
-import org.junit.Before;
-import org.junit.Test;
-
-import com.google.common.collect.ImmutableSet;
-
-/**
- * Tests for the {@link UstMemoryAnalysisModule}
- *
- * @author Guilliano Molaire
- */
-public class UstMemoryAnalysisModuleTest {
-
-    /** The analysis module */
-    private UstMemoryAnalysisModule fUstAnalysisModule;
-
-    /**
-     * Set-up the test
-     */
-    @Before
-    public void setup() {
-        fUstAnalysisModule = new UstMemoryAnalysisModule();
-    }
-
-    /**
-     * Test for {@link UstMemoryAnalysisModule#getAnalysisRequirements()}
-     */
-    @Test
-    public void testGetAnalysisRequirements() {
-        Iterable<TmfAnalysisRequirement> requirements = fUstAnalysisModule.getAnalysisRequirements();
-        assertNotNull(requirements);
-        assertTrue(requirements.iterator().hasNext());
-
-        /* There should be the event and domain type */
-        TmfAnalysisRequirement eventReq = null;
-        TmfAnalysisRequirement domainReq = null;
-        int numberOfRequirement = 0;
-        for (TmfAnalysisRequirement requirement : requirements) {
-            ++numberOfRequirement;
-            if (requirement.getType().equals(SessionConfigStrings.CONFIG_ELEMENT_EVENT)) {
-                eventReq = requirement;
-            } else if (requirement.getType().equals(SessionConfigStrings.CONFIG_ELEMENT_DOMAIN)) {
-                domainReq = requirement;
-            }
-        }
-        assertNotNull(eventReq);
-        assertNotNull(domainReq);
-
-        /* There should be two requirements */
-        assertEquals(2, numberOfRequirement);
-
-        /* Verify the content of the requirements themselves */
-        /* Domain should be kernel */
-        assertEquals(1, domainReq.getValues().size());
-        for (String domain : domainReq.getValues()) {
-            assertEquals(SessionConfigStrings.CONFIG_DOMAIN_TYPE_UST, domain);
-        }
-
-        /* Events */
-        Set<String> expectedEvents = ImmutableSet.of(
-                UstMemoryStrings.MALLOC,
-                UstMemoryStrings.FREE,
-                UstMemoryStrings.CALLOC,
-                UstMemoryStrings.REALLOC,
-                UstMemoryStrings.MEMALIGN,
-                UstMemoryStrings.POSIX_MEMALIGN
-                );
-
-        assertEquals(6, eventReq.getValues().size());
-        for (String event : eventReq.getValues()) {
-            assertTrue("Unexpected event " + event, expectedEvents.contains(event));
-        }
-
-        Set<String> infos = eventReq.getInformation();
-        assertEquals(2, infos.size());
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.ust.core.tests/src/org/eclipse/tracecompass/lttng2/ust/core/tests/callstack/AbstractProviderTest.java b/org.eclipse.tracecompass.lttng2.ust.core.tests/src/org/eclipse/tracecompass/lttng2/ust/core/tests/callstack/AbstractProviderTest.java
deleted file mode 100644 (file)
index d5b979b..0000000
+++ /dev/null
@@ -1,292 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2014, 2015 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:
- *   Alexandre Montplaisir - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.ust.core.tests.callstack;
-
-import static org.eclipse.tracecompass.common.core.NonNullUtils.checkNotNull;
-import static org.junit.Assert.assertEquals;
-import static org.junit.Assert.assertFalse;
-import static org.junit.Assert.assertNotNull;
-import static org.junit.Assert.assertTrue;
-import static org.junit.Assert.fail;
-
-import java.io.File;
-import java.util.List;
-
-import org.eclipse.tracecompass.internal.lttng2.ust.core.callstack.LttngUstCallStackProvider;
-import org.eclipse.tracecompass.statesystem.core.ITmfStateSystem;
-import org.eclipse.tracecompass.statesystem.core.StateSystemUtils;
-import org.eclipse.tracecompass.statesystem.core.exceptions.AttributeNotFoundException;
-import org.eclipse.tracecompass.statesystem.core.exceptions.StateSystemDisposedException;
-import org.eclipse.tracecompass.statesystem.core.interval.ITmfStateInterval;
-import org.eclipse.tracecompass.statesystem.core.statevalue.ITmfStateValue;
-import org.eclipse.tracecompass.tmf.core.exceptions.TmfAnalysisException;
-import org.eclipse.tracecompass.tmf.core.statesystem.ITmfStateProvider;
-import org.eclipse.tracecompass.tmf.core.statesystem.TmfStateSystemAnalysisModule;
-import org.eclipse.tracecompass.tmf.core.timestamp.ITmfTimestamp;
-import org.eclipse.tracecompass.tmf.core.trace.TmfTraceManager;
-import org.eclipse.tracecompass.tmf.ctf.core.tests.shared.CtfTmfTestTrace;
-import org.eclipse.tracecompass.tmf.ctf.core.trace.CtfTmfTrace;
-import org.junit.After;
-import org.junit.Before;
-import org.junit.Rule;
-import org.junit.Test;
-import org.junit.rules.TestRule;
-import org.junit.rules.Timeout;
-
-/**
- * Base class for the UST callstack state provider tests.
- *
- * @author Alexandre Montplaisir
- */
-public abstract class AbstractProviderTest {
-
-    /** Time-out tests after 20 seconds */
-    @Rule public TestRule globalTimeout= new Timeout(20000);
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-
-    private static final CtfTmfTestTrace otherUstTrace = CtfTmfTestTrace.HELLO_LOST;
-
-    private CtfTmfTrace fTrace = null;
-    private ITmfStateSystem fSS = null;
-    private TestLttngCallStackModule fModule;
-
-
-    // ------------------------------------------------------------------------
-    // Abstract methods
-    // ------------------------------------------------------------------------
-
-    /**
-     * @return The test trace to use for this test
-     */
-    protected abstract CtfTmfTestTrace getTestTrace();
-
-    /**
-     * @return The name of the executable process in that particular trace
-     */
-    protected abstract String getProcName();
-
-    /**
-     * Get the list of timestamps to query in that trace.
-     *
-     * @param index
-     *            Which of the test timestamps?
-     * @return That particular timestamp
-     */
-    protected abstract long getTestTimestamp(int index);
-
-    // ------------------------------------------------------------------------
-    // Maintenance
-    // ------------------------------------------------------------------------
-
-    /**
-     * Perform pre-class initialization.
-     */
-    @Before
-    public void setUp() {
-        CtfTmfTestTrace testTrace = getTestTrace();
-
-        CtfTmfTrace trace = testTrace.getTrace();
-        fTrace = trace;
-        fModule = new TestLttngCallStackModule();
-        try {
-            assertTrue(fModule.setTrace(trace));
-        } catch (TmfAnalysisException e) {
-            fail();
-        }
-        fModule.schedule();
-        assertTrue(fModule.waitForCompletion());
-
-        fSS = fModule.getStateSystem();
-        assertNotNull(fSS);
-    }
-
-    /**
-     * Perform post-class clean-up.
-     */
-    @After
-    public void tearDown() {
-        fModule.dispose();
-        if (fTrace != null) {
-            fTrace.dispose();
-            File suppDir = new File(TmfTraceManager.getSupplementaryFileDir(fTrace));
-            deleteDirectory(suppDir);
-        }
-    }
-
-    // ------------------------------------------------------------------------
-    // Test methods
-    // ------------------------------------------------------------------------
-
-    /**
-     * Test the handling of generic UST traces who do not contain the required
-     * information.
-     */
-    @Test
-    public void testOtherUstTrace() {
-        /* Initialize the trace and analysis module */
-        File suppDir;
-        try (CtfTmfTrace ustTrace = otherUstTrace.getTrace();) {
-            TestLttngCallStackModule module = null;
-            try {
-                module = new TestLttngCallStackModule();
-                try {
-                    assertTrue(module.setTrace(ustTrace));
-                } catch (TmfAnalysisException e) {
-                    fail();
-                }
-                module.schedule();
-                assertTrue(module.waitForCompletion());
-
-                /* Make sure the generated state system exists, but is empty */
-                ITmfStateSystem ss = module.getStateSystem();
-                assertNotNull(ss);
-                assertTrue(ss.getStartTime() >= ustTrace.getStartTime().normalize(0, ITmfTimestamp.NANOSECOND_SCALE).getValue());
-                assertEquals(0, ss.getNbAttributes());
-            } finally {
-                if (module != null) {
-                    module.dispose();
-                }
-            }
-            suppDir = new File(TmfTraceManager.getSupplementaryFileDir(ustTrace));
-        }
-        deleteDirectory(suppDir);
-        assertFalse(suppDir.exists());
-    }
-
-    /**
-     * Test that the callstack state system is there and contains data.
-     */
-    @Test
-    public void testConstruction() {
-        assertNotNull(fSS);
-        assertTrue(fSS.getNbAttributes() > 0);
-    }
-
-    /**
-     * Test the callstack at the beginning of the state system.
-     */
-    @Test
-    public void testCallStackBegin() {
-        long start = fSS.getStartTime();
-        String[] cs = getCallStack(fSS, getProcName(), start);
-        assertEquals(1, cs.length);
-
-        assertEquals("40472b", cs[0]);
-    }
-
-    /**
-     * Test the callstack somewhere in the trace.
-     */
-    @Test
-    public void testCallStack1() {
-        String[] cs = getCallStack(fSS, getProcName(), getTestTimestamp(0));
-        assertEquals(2, cs.length);
-
-        assertEquals("40472b", cs[0]);
-        assertEquals("403d60", cs[1]);
-    }
-
-    /**
-     * Test the callstack somewhere in the trace.
-     */
-    @Test
-    public void testCallStack2() {
-        String[] cs = getCallStack(fSS, getProcName(), getTestTimestamp(1));
-        assertEquals(3, cs.length);
-
-        assertEquals("40472b", cs[0]);
-        assertEquals("403b14", cs[1]);
-        assertEquals("401b23", cs[2]);
-    }
-
-    /**
-     * Test the callstack somewhere in the trace.
-     */
-    @Test
-    public void testCallStack3() {
-        String[] cs = getCallStack(fSS, getProcName(), getTestTimestamp(2));
-        assertEquals(4, cs.length);
-
-        assertEquals("40472b", cs[0]);
-        assertEquals("4045c8", cs[1]);
-        assertEquals("403760", cs[2]);
-        assertEquals("401aac", cs[3]);
-    }
-
-    /**
-     * Test the callstack at the end of the trace/state system.
-     */
-    @Test
-    public void testCallStackEnd() {
-        long end = fSS.getCurrentEndTime();
-        String[] cs = getCallStack(fSS, getProcName(), end);
-        assertEquals(3, cs.length);
-
-        assertEquals("40472b", cs[0]);
-        assertEquals("4045c8", cs[1]);
-        assertEquals("403760", cs[2]);
-    }
-
-    // ------------------------------------------------------------------------
-    // Utility methods
-    // ------------------------------------------------------------------------
-
-    /** Empty and delete a directory */
-    private static void deleteDirectory(File dir) {
-        /* Assuming the dir only contains file or empty directories */
-        for (File file : dir.listFiles()) {
-            file.delete();
-        }
-        dir.delete();
-    }
-
-    /** Get the callstack for the given timestamp, for this particular trace */
-    private static String[] getCallStack(ITmfStateSystem ss, String processName, long timestamp) {
-        try {
-            int stackAttribute = ss.getQuarkAbsolute("Threads", processName, "CallStack");
-            List<ITmfStateInterval> state = ss.queryFullState(timestamp);
-            int depth = state.get(stackAttribute).getStateValue().unboxInt();
-
-            int stackTop = ss.getQuarkRelative(stackAttribute, String.valueOf(depth));
-            ITmfStateValue expectedValue = state.get(stackTop).getStateValue();
-            ITmfStateInterval interval = StateSystemUtils.querySingleStackTop(ss, timestamp, stackAttribute);
-            assertNotNull(interval);
-            assertEquals(expectedValue, interval.getStateValue());
-
-            String[] ret = new String[depth];
-            for (int i = 0; i < depth; i++) {
-                int quark = ss.getQuarkRelative(stackAttribute, String.valueOf(i + 1));
-                ret[i] = state.get(quark).getStateValue().unboxStr();
-            }
-            return ret;
-
-        } catch (AttributeNotFoundException e) {
-            fail(e.getMessage());
-        } catch (StateSystemDisposedException e) {
-            fail(e.getMessage());
-        }
-        fail();
-        return null;
-    }
-
-    private class TestLttngCallStackModule extends TmfStateSystemAnalysisModule {
-
-        @Override
-        protected ITmfStateProvider createStateProvider() {
-            return new LttngUstCallStackProvider(checkNotNull(getTrace()));
-        }
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.ust.core.tests/src/org/eclipse/tracecompass/lttng2/ust/core/tests/callstack/AllTests.java b/org.eclipse.tracecompass.lttng2.ust.core.tests/src/org/eclipse/tracecompass/lttng2/ust/core/tests/callstack/AllTests.java
deleted file mode 100644 (file)
index 70b2807..0000000
+++ /dev/null
@@ -1,28 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2013, 2015 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:
- *   Alexandre Montplaisir - Initial implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.ust.core.tests.callstack;
-
-import org.junit.runner.RunWith;
-import org.junit.runners.Suite;
-
-/**
- * Test suite for org.eclipse.tracecompass.lttng2.ust.core.tests.trace.callstack
- */
-@RunWith(Suite.class)
-@Suite.SuiteClasses({
-    LttngUstCallStackProviderFastTest.class,
-    LttngUstCallStackProviderTest.class
-})
-public class AllTests {
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.ust.core.tests/src/org/eclipse/tracecompass/lttng2/ust/core/tests/callstack/LttngUstCallStackProviderFastTest.java b/org.eclipse.tracecompass.lttng2.ust.core.tests/src/org/eclipse/tracecompass/lttng2/ust/core/tests/callstack/LttngUstCallStackProviderFastTest.java
deleted file mode 100644 (file)
index 56935ac..0000000
+++ /dev/null
@@ -1,56 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2013, 2014 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:
- *   Alexandre Montplaisir - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.ust.core.tests.callstack;
-
-import static org.junit.Assume.assumeTrue;
-
-import org.eclipse.tracecompass.tmf.ctf.core.tests.shared.CtfTmfTestTrace;
-import org.junit.BeforeClass;
-
-/**
- * Test suite for the UST callstack state provider, using the trace of a program
- * instrumented with lttng-ust-cyg-profile-fast.so tracepoints. These do not
- * contain the function addresses in the func_exit events.
- *
- * @author Alexandre Montplaisir
- */
-public class LttngUstCallStackProviderFastTest extends AbstractProviderTest {
-
-    private static final long[] timestamps = { 1379361250310000000L,
-                                               1379361250498400000L,
-                                               1379361250499759000L };
-
-    /**
-     * Class setup
-     */
-    @BeforeClass
-    public static void setUpClass() {
-        assumeTrue(CtfTmfTestTrace.CYG_PROFILE_FAST.exists());
-    }
-
-    @Override
-    protected CtfTmfTestTrace getTestTrace() {
-        return CtfTmfTestTrace.CYG_PROFILE_FAST;
-    }
-
-    @Override
-    protected String getProcName() {
-        return "glxgears-29822";
-    }
-
-    @Override
-    protected long getTestTimestamp(int index) {
-        return timestamps[index];
-    }
-
-}
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.ust.core.tests/src/org/eclipse/tracecompass/lttng2/ust/core/tests/callstack/LttngUstCallStackProviderTest.java b/org.eclipse.tracecompass.lttng2.ust.core.tests/src/org/eclipse/tracecompass/lttng2/ust/core/tests/callstack/LttngUstCallStackProviderTest.java
deleted file mode 100644 (file)
index b5d2792..0000000
+++ /dev/null
@@ -1,55 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2013, 2014 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:
- *   Alexandre Montplaisir - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.ust.core.tests.callstack;
-
-import static org.junit.Assume.assumeTrue;
-
-import org.eclipse.tracecompass.tmf.ctf.core.tests.shared.CtfTmfTestTrace;
-import org.junit.BeforeClass;
-
-/**
- * Test suite for the UST callstack state provider, using the trace of a program
- * instrumented with lttng-ust-cyg-profile.so tracepoints.
- *
- * @author Alexandre Montplaisir
- */
-public class LttngUstCallStackProviderTest extends AbstractProviderTest {
-
-    private static final long[] timestamps = { 1378850463600000000L,
-                                               1378850463770000000L,
-                                               1378850463868753000L };
-
-    /**
-     * Class setup
-     */
-    @BeforeClass
-    public static void setUpClass() {
-        assumeTrue(CtfTmfTestTrace.CYG_PROFILE.exists());
-    }
-
-    @Override
-    protected CtfTmfTestTrace getTestTrace() {
-        return CtfTmfTestTrace.CYG_PROFILE;
-    }
-
-    @Override
-    protected String getProcName() {
-        return "glxgears-16073";
-    }
-
-    @Override
-    protected long getTestTimestamp(int index) {
-        return timestamps[index];
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.ust.core/.classpath b/org.eclipse.tracecompass.lttng2.ust.core/.classpath
deleted file mode 100644 (file)
index 098194c..0000000
+++ /dev/null
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
-       <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7"/>
-       <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
-       <classpathentry kind="src" path="src"/>
-       <classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/org.eclipse.tracecompass.lttng2.ust.core/.project b/org.eclipse.tracecompass.lttng2.ust.core/.project
deleted file mode 100644 (file)
index 4293adb..0000000
+++ /dev/null
@@ -1,34 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
-       <name>org.eclipse.tracecompass.lttng2.ust.core</name>
-       <comment></comment>
-       <projects>
-       </projects>
-       <buildSpec>
-               <buildCommand>
-                       <name>org.eclipse.jdt.core.javabuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-               <buildCommand>
-                       <name>org.eclipse.pde.ManifestBuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-               <buildCommand>
-                       <name>org.eclipse.pde.SchemaBuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-               <buildCommand>
-                       <name>org.eclipse.pde.api.tools.apiAnalysisBuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-       </buildSpec>
-       <natures>
-               <nature>org.eclipse.pde.PluginNature</nature>
-               <nature>org.eclipse.jdt.core.javanature</nature>
-               <nature>org.eclipse.pde.api.tools.apiAnalysisNature</nature>
-       </natures>
-</projectDescription>
diff --git a/org.eclipse.tracecompass.lttng2.ust.core/.settings/org.eclipse.core.resources.prefs b/org.eclipse.tracecompass.lttng2.ust.core/.settings/org.eclipse.core.resources.prefs
deleted file mode 100644 (file)
index 99f26c0..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-eclipse.preferences.version=1
-encoding/<project>=UTF-8
diff --git a/org.eclipse.tracecompass.lttng2.ust.core/.settings/org.eclipse.core.runtime.prefs b/org.eclipse.tracecompass.lttng2.ust.core/.settings/org.eclipse.core.runtime.prefs
deleted file mode 100644 (file)
index 5a0ad22..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-eclipse.preferences.version=1
-line.separator=\n
diff --git a/org.eclipse.tracecompass.lttng2.ust.core/.settings/org.eclipse.jdt.core.prefs b/org.eclipse.tracecompass.lttng2.ust.core/.settings/org.eclipse.jdt.core.prefs
deleted file mode 100644 (file)
index a2b5e6b..0000000
+++ /dev/null
@@ -1,405 +0,0 @@
-eclipse.preferences.version=1
-org.eclipse.jdt.core.codeComplete.argumentPrefixes=
-org.eclipse.jdt.core.codeComplete.argumentSuffixes=
-org.eclipse.jdt.core.codeComplete.fieldPrefixes=f
-org.eclipse.jdt.core.codeComplete.fieldSuffixes=
-org.eclipse.jdt.core.codeComplete.localPrefixes=
-org.eclipse.jdt.core.codeComplete.localSuffixes=
-org.eclipse.jdt.core.codeComplete.staticFieldPrefixes=
-org.eclipse.jdt.core.codeComplete.staticFieldSuffixes=
-org.eclipse.jdt.core.codeComplete.staticFinalFieldPrefixes=
-org.eclipse.jdt.core.codeComplete.staticFinalFieldSuffixes=
-org.eclipse.jdt.core.compiler.annotation.inheritNullAnnotations=enabled
-org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore
-org.eclipse.jdt.core.compiler.annotation.nonnull=org.eclipse.jdt.annotation.NonNull
-org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=org.eclipse.jdt.annotation.NonNullByDefault
-org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nullable
-org.eclipse.jdt.core.compiler.annotation.nullanalysis=enabled
-org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
-org.eclipse.jdt.core.compiler.codegen.methodParameters=do not generate
-org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
-org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
-org.eclipse.jdt.core.compiler.compliance=1.7
-org.eclipse.jdt.core.compiler.debug.lineNumber=generate
-org.eclipse.jdt.core.compiler.debug.localVariable=generate
-org.eclipse.jdt.core.compiler.debug.sourceFile=generate
-org.eclipse.jdt.core.compiler.doc.comment.support=enabled
-org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=error
-org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
-org.eclipse.jdt.core.compiler.problem.autoboxing=ignore
-org.eclipse.jdt.core.compiler.problem.comparingIdentical=error
-org.eclipse.jdt.core.compiler.problem.deadCode=error
-org.eclipse.jdt.core.compiler.problem.deprecation=error
-org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled
-org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=enabled
-org.eclipse.jdt.core.compiler.problem.discouragedReference=warning
-org.eclipse.jdt.core.compiler.problem.emptyStatement=error
-org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
-org.eclipse.jdt.core.compiler.problem.explicitlyClosedAutoCloseable=error
-org.eclipse.jdt.core.compiler.problem.fallthroughCase=error
-org.eclipse.jdt.core.compiler.problem.fatalOptionalError=disabled
-org.eclipse.jdt.core.compiler.problem.fieldHiding=error
-org.eclipse.jdt.core.compiler.problem.finalParameterBound=error
-org.eclipse.jdt.core.compiler.problem.finallyBlockNotCompletingNormally=error
-org.eclipse.jdt.core.compiler.problem.forbiddenReference=error
-org.eclipse.jdt.core.compiler.problem.hiddenCatchBlock=error
-org.eclipse.jdt.core.compiler.problem.includeNullInfoFromAsserts=disabled
-org.eclipse.jdt.core.compiler.problem.incompatibleNonInheritedInterfaceMethod=error
-org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch=error
-org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=error
-org.eclipse.jdt.core.compiler.problem.invalidJavadoc=warning
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTags=enabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsDeprecatedRef=enabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsNotVisibleRef=enabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsVisibility=protected
-org.eclipse.jdt.core.compiler.problem.localVariableHiding=error
-org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=error
-org.eclipse.jdt.core.compiler.problem.missingDefaultCase=error
-org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=error
-org.eclipse.jdt.core.compiler.problem.missingEnumCaseDespiteDefault=enabled
-org.eclipse.jdt.core.compiler.problem.missingHashCodeMethod=error
-org.eclipse.jdt.core.compiler.problem.missingJavadocComments=warning
-org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsOverriding=disabled
-org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsVisibility=protected
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagDescription=all_standard_tags
-org.eclipse.jdt.core.compiler.problem.missingJavadocTags=warning
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagsMethodTypeParameters=disabled
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagsOverriding=disabled
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagsVisibility=protected
-org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotation=error
-org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotationForInterfaceMethodImplementation=enabled
-org.eclipse.jdt.core.compiler.problem.missingSerialVersion=error
-org.eclipse.jdt.core.compiler.problem.missingSynchronizedOnInheritedMethod=error
-org.eclipse.jdt.core.compiler.problem.noEffectAssignment=error
-org.eclipse.jdt.core.compiler.problem.noImplicitStringConversion=error
-org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=warning
-org.eclipse.jdt.core.compiler.problem.nonnullParameterAnnotationDropped=warning
-org.eclipse.jdt.core.compiler.problem.nullAnnotationInferenceConflict=warning
-org.eclipse.jdt.core.compiler.problem.nullReference=error
-org.eclipse.jdt.core.compiler.problem.nullSpecViolation=error
-org.eclipse.jdt.core.compiler.problem.nullUncheckedConversion=warning
-org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=error
-org.eclipse.jdt.core.compiler.problem.parameterAssignment=error
-org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=error
-org.eclipse.jdt.core.compiler.problem.potentialNullReference=error
-org.eclipse.jdt.core.compiler.problem.potentiallyUnclosedCloseable=warning
-org.eclipse.jdt.core.compiler.problem.rawTypeReference=warning
-org.eclipse.jdt.core.compiler.problem.redundantNullAnnotation=warning
-org.eclipse.jdt.core.compiler.problem.redundantNullCheck=error
-org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=error
-org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=error
-org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore
-org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=error
-org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled
-org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=error
-org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=disabled
-org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled
-org.eclipse.jdt.core.compiler.problem.syntacticNullAnalysisForFields=enabled
-org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=ignore
-org.eclipse.jdt.core.compiler.problem.typeParameterHiding=error
-org.eclipse.jdt.core.compiler.problem.unavoidableGenericTypeProblems=disabled
-org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=warning
-org.eclipse.jdt.core.compiler.problem.unclosedCloseable=error
-org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=ignore
-org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=error
-org.eclipse.jdt.core.compiler.problem.unnecessaryElse=error
-org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=error
-org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=warning
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionExemptExceptionAndThrowable=disabled
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionIncludeDocCommentReference=disabled
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverriding=disabled
-org.eclipse.jdt.core.compiler.problem.unusedExceptionParameter=ignore
-org.eclipse.jdt.core.compiler.problem.unusedImport=error
-org.eclipse.jdt.core.compiler.problem.unusedLabel=error
-org.eclipse.jdt.core.compiler.problem.unusedLocal=error
-org.eclipse.jdt.core.compiler.problem.unusedObjectAllocation=ignore
-org.eclipse.jdt.core.compiler.problem.unusedParameter=error
-org.eclipse.jdt.core.compiler.problem.unusedParameterIncludeDocCommentReference=enabled
-org.eclipse.jdt.core.compiler.problem.unusedParameterWhenImplementingAbstract=disabled
-org.eclipse.jdt.core.compiler.problem.unusedParameterWhenOverridingConcrete=disabled
-org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=error
-org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=error
-org.eclipse.jdt.core.compiler.problem.unusedWarningToken=error
-org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=error
-org.eclipse.jdt.core.compiler.source=1.7
-org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_call=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression=16
-org.eclipse.jdt.core.formatter.alignment_for_assignment=0
-org.eclipse.jdt.core.formatter.alignment_for_binary_expression=16
-org.eclipse.jdt.core.formatter.alignment_for_compact_if=16
-org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=80
-org.eclipse.jdt.core.formatter.alignment_for_enum_constants=0
-org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=16
-org.eclipse.jdt.core.formatter.alignment_for_method_declaration=0
-org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16
-org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=80
-org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation=0
-org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_constructor_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_method_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_union_type_in_multicatch=16
-org.eclipse.jdt.core.formatter.blank_lines_after_imports=1
-org.eclipse.jdt.core.formatter.blank_lines_after_package=1
-org.eclipse.jdt.core.formatter.blank_lines_before_field=0
-org.eclipse.jdt.core.formatter.blank_lines_before_first_class_body_declaration=0
-org.eclipse.jdt.core.formatter.blank_lines_before_imports=1
-org.eclipse.jdt.core.formatter.blank_lines_before_member_type=1
-org.eclipse.jdt.core.formatter.blank_lines_before_method=1
-org.eclipse.jdt.core.formatter.blank_lines_before_new_chunk=1
-org.eclipse.jdt.core.formatter.blank_lines_before_package=0
-org.eclipse.jdt.core.formatter.blank_lines_between_import_groups=1
-org.eclipse.jdt.core.formatter.blank_lines_between_type_declarations=1
-org.eclipse.jdt.core.formatter.brace_position_for_annotation_type_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_array_initializer=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_block=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_block_in_case=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_constructor_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_enum_constant=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_enum_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_method_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_switch=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_type_declaration=end_of_line
-org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_block_comment=false
-org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_javadoc_comment=false
-org.eclipse.jdt.core.formatter.comment.format_block_comments=true
-org.eclipse.jdt.core.formatter.comment.format_header=false
-org.eclipse.jdt.core.formatter.comment.format_html=true
-org.eclipse.jdt.core.formatter.comment.format_javadoc_comments=true
-org.eclipse.jdt.core.formatter.comment.format_line_comments=true
-org.eclipse.jdt.core.formatter.comment.format_source_code=true
-org.eclipse.jdt.core.formatter.comment.indent_parameter_description=true
-org.eclipse.jdt.core.formatter.comment.indent_root_tags=true
-org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags=insert
-org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter=insert
-org.eclipse.jdt.core.formatter.comment.line_length=80
-org.eclipse.jdt.core.formatter.comment.new_lines_at_block_boundaries=true
-org.eclipse.jdt.core.formatter.comment.new_lines_at_javadoc_boundaries=true
-org.eclipse.jdt.core.formatter.comment.preserve_white_space_between_code_and_line_comments=false
-org.eclipse.jdt.core.formatter.compact_else_if=true
-org.eclipse.jdt.core.formatter.continuation_indentation=2
-org.eclipse.jdt.core.formatter.continuation_indentation_for_array_initializer=2
-org.eclipse.jdt.core.formatter.disabling_tag=@formatter\:off
-org.eclipse.jdt.core.formatter.enabling_tag=@formatter\:on
-org.eclipse.jdt.core.formatter.format_guardian_clause_on_one_line=false
-org.eclipse.jdt.core.formatter.format_line_comment_starting_on_first_column=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_annotation_declaration_header=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_constant_header=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_declaration_header=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_type_header=true
-org.eclipse.jdt.core.formatter.indent_breaks_compare_to_cases=true
-org.eclipse.jdt.core.formatter.indent_empty_lines=false
-org.eclipse.jdt.core.formatter.indent_statements_compare_to_block=true
-org.eclipse.jdt.core.formatter.indent_statements_compare_to_body=true
-org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_cases=true
-org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_switch=false
-org.eclipse.jdt.core.formatter.indentation.size=4
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_field=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_local_variable=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_method=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_package=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_parameter=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_type=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_label=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_opening_brace_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_at_end_of_file_if_missing=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_finally_in_try_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_while_in_do_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_annotation_declaration=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_anonymous_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_block=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter=insert
-org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_binary_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_paren_in_cast=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_assert=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_case=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_labeled_statement=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_allocation_expression=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_annotation=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_throws=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_constant_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_declarations=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_explicitconstructorcall_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_increments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_inits=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_throws=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_invocation_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_field_declarations=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_local_declarations=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_parameterized_type_reference=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_superinterfaces=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_ellipsis=insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_brace_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_cast=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_catch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_for=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_if=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_parenthesized_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_switch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_synchronized=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_try=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_while=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_try_resources=insert
-org.eclipse.jdt.core.formatter.insert_space_after_unary_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter=insert
-org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_binary_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_brace_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_cast=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_catch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_for=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_if=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_parenthesized_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_switch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_synchronized=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_try=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_while=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_assert=insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_case=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_default=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_labeled_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_throws=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_constant_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_declarations=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_explicitconstructorcall_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_increments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_inits=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_throws=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_invocation_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_field_declarations=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_local_declarations=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_superinterfaces=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_ellipsis=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_annotation_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_anonymous_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_block=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_constructor_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_constant=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_method_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_switch=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation_type_member_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_catch=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_if=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_parenthesized_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_switch=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_synchronized=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_try=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_while=insert
-org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_return=insert
-org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_throw=insert
-org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_semicolon=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_try_resources=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_unary_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_brackets_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_annotation_type_member_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.join_lines_in_comments=true
-org.eclipse.jdt.core.formatter.join_wrapped_lines=false
-org.eclipse.jdt.core.formatter.keep_else_statement_on_same_line=false
-org.eclipse.jdt.core.formatter.keep_empty_array_initializer_on_one_line=false
-org.eclipse.jdt.core.formatter.keep_imple_if_on_one_line=false
-org.eclipse.jdt.core.formatter.keep_then_statement_on_same_line=false
-org.eclipse.jdt.core.formatter.lineSplit=250
-org.eclipse.jdt.core.formatter.never_indent_block_comments_on_first_column=false
-org.eclipse.jdt.core.formatter.never_indent_line_comments_on_first_column=false
-org.eclipse.jdt.core.formatter.number_of_blank_lines_at_beginning_of_method_body=0
-org.eclipse.jdt.core.formatter.number_of_empty_lines_to_preserve=1
-org.eclipse.jdt.core.formatter.put_empty_statement_on_new_line=true
-org.eclipse.jdt.core.formatter.tabulation.char=space
-org.eclipse.jdt.core.formatter.tabulation.size=4
-org.eclipse.jdt.core.formatter.use_on_off_tags=false
-org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false
-org.eclipse.jdt.core.formatter.wrap_before_binary_operator=true
-org.eclipse.jdt.core.formatter.wrap_before_or_operator_multicatch=true
-org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true
diff --git a/org.eclipse.tracecompass.lttng2.ust.core/.settings/org.eclipse.jdt.ui.prefs b/org.eclipse.tracecompass.lttng2.ust.core/.settings/org.eclipse.jdt.ui.prefs
deleted file mode 100644 (file)
index 232a3fd..0000000
+++ /dev/null
@@ -1,60 +0,0 @@
-eclipse.preferences.version=1
-editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true
-formatter_profile=_tmf-style
-formatter_settings_version=12
-org.eclipse.jdt.ui.exception.name=e
-org.eclipse.jdt.ui.gettersetter.use.is=true
-org.eclipse.jdt.ui.keywordthis=false
-org.eclipse.jdt.ui.overrideannotation=true
-sp_cleanup.add_default_serial_version_id=true
-sp_cleanup.add_generated_serial_version_id=false
-sp_cleanup.add_missing_annotations=false
-sp_cleanup.add_missing_deprecated_annotations=true
-sp_cleanup.add_missing_methods=false
-sp_cleanup.add_missing_nls_tags=false
-sp_cleanup.add_missing_override_annotations=true
-sp_cleanup.add_missing_override_annotations_interface_methods=true
-sp_cleanup.add_serial_version_id=false
-sp_cleanup.always_use_blocks=true
-sp_cleanup.always_use_parentheses_in_expressions=false
-sp_cleanup.always_use_this_for_non_static_field_access=false
-sp_cleanup.always_use_this_for_non_static_method_access=false
-sp_cleanup.convert_to_enhanced_for_loop=false
-sp_cleanup.correct_indentation=false
-sp_cleanup.format_source_code=false
-sp_cleanup.format_source_code_changes_only=false
-sp_cleanup.make_local_variable_final=false
-sp_cleanup.make_parameters_final=false
-sp_cleanup.make_private_fields_final=true
-sp_cleanup.make_type_abstract_if_missing_method=false
-sp_cleanup.make_variable_declarations_final=false
-sp_cleanup.never_use_blocks=false
-sp_cleanup.never_use_parentheses_in_expressions=true
-sp_cleanup.on_save_use_additional_actions=true
-sp_cleanup.organize_imports=false
-sp_cleanup.qualify_static_field_accesses_with_declaring_class=false
-sp_cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=true
-sp_cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=true
-sp_cleanup.qualify_static_member_accesses_with_declaring_class=false
-sp_cleanup.qualify_static_method_accesses_with_declaring_class=false
-sp_cleanup.remove_private_constructors=true
-sp_cleanup.remove_trailing_whitespaces=true
-sp_cleanup.remove_trailing_whitespaces_all=true
-sp_cleanup.remove_trailing_whitespaces_ignore_empty=false
-sp_cleanup.remove_unnecessary_casts=false
-sp_cleanup.remove_unnecessary_nls_tags=false
-sp_cleanup.remove_unused_imports=false
-sp_cleanup.remove_unused_local_variables=false
-sp_cleanup.remove_unused_private_fields=true
-sp_cleanup.remove_unused_private_members=false
-sp_cleanup.remove_unused_private_methods=true
-sp_cleanup.remove_unused_private_types=true
-sp_cleanup.sort_members=false
-sp_cleanup.sort_members_all=false
-sp_cleanup.use_blocks=true
-sp_cleanup.use_blocks_only_for_return_and_throw=false
-sp_cleanup.use_parentheses_in_expressions=false
-sp_cleanup.use_this_for_non_static_field_access=false
-sp_cleanup.use_this_for_non_static_field_access_only_if_necessary=true
-sp_cleanup.use_this_for_non_static_method_access=false
-sp_cleanup.use_this_for_non_static_method_access_only_if_necessary=true
diff --git a/org.eclipse.tracecompass.lttng2.ust.core/.settings/org.eclipse.pde.api.tools.prefs b/org.eclipse.tracecompass.lttng2.ust.core/.settings/org.eclipse.pde.api.tools.prefs
deleted file mode 100644 (file)
index acc3abd..0000000
+++ /dev/null
@@ -1,97 +0,0 @@
-ANNOTATION_ELEMENT_TYPE_ADDED_METHOD_WITHOUT_DEFAULT_VALUE=Error
-ANNOTATION_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-ANNOTATION_ELEMENT_TYPE_REMOVED_FIELD=Error
-ANNOTATION_ELEMENT_TYPE_REMOVED_METHOD=Error
-ANNOTATION_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_API_TYPE=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_API_TYPE=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_TYPE=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_TYPE=Error
-API_USE_SCAN_FIELD_SEVERITY=Error
-API_USE_SCAN_METHOD_SEVERITY=Error
-API_USE_SCAN_TYPE_SEVERITY=Error
-CLASS_ELEMENT_TYPE_ADDED_METHOD=Error
-CLASS_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
-CLASS_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-CLASS_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
-CLASS_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-CLASS_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
-CLASS_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
-CLASS_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-CLASS_ELEMENT_TYPE_REMOVED_CONSTRUCTOR=Error
-CLASS_ELEMENT_TYPE_REMOVED_FIELD=Error
-CLASS_ELEMENT_TYPE_REMOVED_METHOD=Error
-CLASS_ELEMENT_TYPE_REMOVED_SUPERCLASS=Error
-CLASS_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-CLASS_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-CONSTRUCTOR_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-CONSTRUCTOR_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-CONSTRUCTOR_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
-CONSTRUCTOR_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-ENUM_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
-ENUM_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-ENUM_ELEMENT_TYPE_REMOVED_ENUM_CONSTANT=Error
-ENUM_ELEMENT_TYPE_REMOVED_FIELD=Error
-ENUM_ELEMENT_TYPE_REMOVED_METHOD=Error
-ENUM_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-FIELD_ELEMENT_TYPE_ADDED_VALUE=Error
-FIELD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-FIELD_ELEMENT_TYPE_CHANGED_FINAL_TO_NON_FINAL_STATIC_CONSTANT=Error
-FIELD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
-FIELD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
-FIELD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
-FIELD_ELEMENT_TYPE_CHANGED_TYPE=Error
-FIELD_ELEMENT_TYPE_CHANGED_VALUE=Error
-FIELD_ELEMENT_TYPE_REMOVED_TYPE_ARGUMENT=Error
-FIELD_ELEMENT_TYPE_REMOVED_VALUE=Error
-ILLEGAL_EXTEND=Warning
-ILLEGAL_IMPLEMENT=Warning
-ILLEGAL_INSTANTIATE=Warning
-ILLEGAL_OVERRIDE=Warning
-ILLEGAL_REFERENCE=Warning
-INTERFACE_ELEMENT_TYPE_ADDED_FIELD=Error
-INTERFACE_ELEMENT_TYPE_ADDED_METHOD=Error
-INTERFACE_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
-INTERFACE_ELEMENT_TYPE_ADDED_SUPER_INTERFACE_WITH_METHODS=Error
-INTERFACE_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-INTERFACE_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
-INTERFACE_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_FIELD=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_METHOD=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-INVALID_JAVADOC_TAG=Warning
-INVALID_REFERENCE_IN_SYSTEM_LIBRARIES=Warning
-LEAK_EXTEND=Warning
-LEAK_FIELD_DECL=Warning
-LEAK_IMPLEMENT=Warning
-LEAK_METHOD_PARAM=Warning
-LEAK_METHOD_RETURN_TYPE=Warning
-METHOD_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
-METHOD_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-METHOD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-METHOD_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
-METHOD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
-METHOD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
-METHOD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
-METHOD_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
-METHOD_ELEMENT_TYPE_REMOVED_ANNOTATION_DEFAULT_VALUE=Error
-METHOD_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-MISSING_EE_DESCRIPTIONS=Ignore
-TYPE_PARAMETER_ELEMENT_TYPE_ADDED_CLASS_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_ADDED_INTERFACE_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_CLASS_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_INTERFACE_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_CLASS_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_INTERFACE_BOUND=Error
-UNUSED_PROBLEM_FILTERS=Warning
-automatically_removed_unused_problem_filters=false
-eclipse.preferences.version=1
-incompatible_api_component_version=Error
-incompatible_api_component_version_include_major_without_breaking_change=Disabled
-incompatible_api_component_version_include_minor_without_api_change=Disabled
-invalid_since_tag_version=Error
-malformed_since_tag=Error
-missing_since_tag=Error
-report_api_breakage_when_major_version_incremented=Disabled
-report_resolution_errors_api_component=Warning
diff --git a/org.eclipse.tracecompass.lttng2.ust.core/.settings/org.eclipse.pde.prefs b/org.eclipse.tracecompass.lttng2.ust.core/.settings/org.eclipse.pde.prefs
deleted file mode 100644 (file)
index d92b94f..0000000
+++ /dev/null
@@ -1,32 +0,0 @@
-compilers.f.unresolved-features=1
-compilers.f.unresolved-plugins=1
-compilers.incompatible-environment=1
-compilers.p.build=1
-compilers.p.build.bin.includes=1
-compilers.p.build.encodings=2
-compilers.p.build.java.compiler=2
-compilers.p.build.java.compliance=1
-compilers.p.build.missing.output=2
-compilers.p.build.output.library=1
-compilers.p.build.source.library=1
-compilers.p.build.src.includes=1
-compilers.p.deprecated=1
-compilers.p.discouraged-class=1
-compilers.p.internal=1
-compilers.p.missing-packages=1
-compilers.p.missing-version-export-package=2
-compilers.p.missing-version-import-package=2
-compilers.p.missing-version-require-bundle=2
-compilers.p.no-required-att=0
-compilers.p.not-externalized-att=1
-compilers.p.unknown-attribute=1
-compilers.p.unknown-class=1
-compilers.p.unknown-element=1
-compilers.p.unknown-identifier=1
-compilers.p.unknown-resource=1
-compilers.p.unresolved-ex-points=0
-compilers.p.unresolved-import=0
-compilers.s.create-docs=false
-compilers.s.doc-folder=doc
-compilers.s.open-tags=1
-eclipse.preferences.version=1
diff --git a/org.eclipse.tracecompass.lttng2.ust.core/META-INF/MANIFEST.MF b/org.eclipse.tracecompass.lttng2.ust.core/META-INF/MANIFEST.MF
deleted file mode 100644 (file)
index abc60e7..0000000
+++ /dev/null
@@ -1,22 +0,0 @@
-Manifest-Version: 1.0
-Bundle-ManifestVersion: 2
-Bundle-Name: %Bundle-Name
-Bundle-Vendor: %Bundle-Vendor
-Bundle-Version: 1.0.0.qualifier
-Bundle-Localization: plugin
-Bundle-SymbolicName: org.eclipse.tracecompass.lttng2.ust.core;singleton:=true
-Bundle-Activator: org.eclipse.tracecompass.internal.lttng2.ust.core.Activator
-Bundle-ActivationPolicy: lazy
-Bundle-RequiredExecutionEnvironment: JavaSE-1.7
-Export-Package: org.eclipse.tracecompass.internal.lttng2.ust.core;x-friends:="org.eclipse.tracecompass.lttng2.ust.core.tests,org.eclipse.tracecompass.lttng2.ust.ui",
- org.eclipse.tracecompass.internal.lttng2.ust.core.analysis.memory;x-friends:="org.eclipse.tracecompass.lttng2.ust.ui,org.eclipse.tracecompass.lttng2.ust.core.tests",
- org.eclipse.tracecompass.internal.lttng2.ust.core.callstack;x-friends:="org.eclipse.tracecompass.lttng2.ust.ui,org.eclipse.tracecompass.lttng2.ust.core.tests",
- org.eclipse.tracecompass.lttng2.ust.core.analysis.memory,
- org.eclipse.tracecompass.lttng2.ust.core.trace
-Require-Bundle: org.eclipse.core.runtime,
- org.eclipse.core.resources,
- org.eclipse.tracecompass.common.core,
- org.eclipse.tracecompass.tmf.core,
- org.eclipse.tracecompass.tmf.ctf.core,
- org.eclipse.tracecompass.lttng2.control.core
-Import-Package: com.google.common.collect
diff --git a/org.eclipse.tracecompass.lttng2.ust.core/about.html b/org.eclipse.tracecompass.lttng2.ust.core/about.html
deleted file mode 100644 (file)
index c258ef5..0000000
+++ /dev/null
@@ -1,28 +0,0 @@
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
-    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml">
-<head>
-<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"/>
-<title>About</title>
-</head>
-<body lang="EN-US">
-<h2>About This Content</h2>
-<p>June 5, 2006</p>    
-<h3>License</h3>
-
-<p>The Eclipse Foundation makes available all content in this plug-in (&quot;Content&quot;).  Unless otherwise 
-indicated below, the Content is provided to you under the terms and conditions of the
-Eclipse Public License Version 1.0 (&quot;EPL&quot;).  A copy of the EPL is available 
-at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>.
-For purposes of the EPL, &quot;Program&quot; will mean the Content.</p>
-
-<p>If you did not receive this Content directly from the Eclipse Foundation, the Content is 
-being redistributed by another party (&quot;Redistributor&quot;) and different terms and conditions may
-apply to your use of any object code in the Content.  Check the Redistributor's license that was 
-provided with the Content.  If no such license exists, contact the Redistributor.  Unless otherwise
-indicated below, the terms and conditions of the EPL still apply to any source code in the Content
-and such source code may be obtained at <a href="http://www.eclipse.org/">http://www.eclipse.org</a>.</p>
-
-</body>
-</html>
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.ust.core/build.properties b/org.eclipse.tracecompass.lttng2.ust.core/build.properties
deleted file mode 100644 (file)
index 244c9d8..0000000
+++ /dev/null
@@ -1,22 +0,0 @@
-###############################################################################
-# Copyright (c) 2013, 2014 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:
-#     Ericsson - Initial API and implementation
-###############################################################################
-
-source.. = src/
-output.. = bin/
-bin.includes = META-INF/,\
-               .,\
-               about.html,\
-               plugin.properties,\
-               plugin.xml
-src.includes = about.html
-additional.bundles = org.eclipse.jdt.annotation
-jars.extra.classpath = platform:/plugin/org.eclipse.jdt.annotation
diff --git a/org.eclipse.tracecompass.lttng2.ust.core/plugin.properties b/org.eclipse.tracecompass.lttng2.ust.core/plugin.properties
deleted file mode 100644 (file)
index db7013a..0000000
+++ /dev/null
@@ -1,16 +0,0 @@
-###############################################################################
-# Copyright (c) 2013, 2014 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:
-#     Ericsson - Initial API and implementation
-###############################################################################
-
-Bundle-Vendor = Eclipse Trace Compass
-Bundle-Name = Trace Compass LTTng Userspace Tracer Analysis Core Plug-in
-
-tracetype.type.ust = LTTng UST Trace
diff --git a/org.eclipse.tracecompass.lttng2.ust.core/plugin.xml b/org.eclipse.tracecompass.lttng2.ust.core/plugin.xml
deleted file mode 100644 (file)
index 963f4f3..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<?eclipse version="3.4"?>
-<plugin>
-   <extension
-         point="org.eclipse.linuxtools.tmf.core.tracetype">
-      <type
-            category="org.eclipse.linuxtools.tmf.ctf.core.category.ctf"
-            event_type="org.eclipse.tracecompass.tmf.ctf.core.event.CtfTmfEvent"
-            id="org.eclipse.linuxtools.lttng2.ust.tracetype"
-            isDirectory="true"
-            name="%tracetype.type.ust"
-            trace_type="org.eclipse.tracecompass.lttng2.ust.core.trace.LttngUstTrace">
-      </type>
-   </extension>
-   <extension
-         point="org.eclipse.linuxtools.tmf.core.analysis">
-      <module
-            analysis_module="org.eclipse.tracecompass.lttng2.ust.core.analysis.memory.UstMemoryAnalysisModule"
-            id="org.eclipse.linuxtools.lttng2.ust.analysis.memory"
-            name="Ust Memory">
-         <tracetype
-               class="org.eclipse.tracecompass.lttng2.ust.core.trace.LttngUstTrace">
-         </tracetype>
-      </module>
-   </extension>
-</plugin>
diff --git a/org.eclipse.tracecompass.lttng2.ust.core/pom.xml b/org.eclipse.tracecompass.lttng2.ust.core/pom.xml
deleted file mode 100644 (file)
index 91f6292..0000000
+++ /dev/null
@@ -1,36 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-   Copyright (C) 2011, 2013 Red Hat Inc., 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
--->
-<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>
-    <artifactId>org.eclipse.tracecompass</artifactId>
-    <groupId>org.eclipse.tracecompass</groupId>
-    <version>1.0.0-SNAPSHOT</version>
-  </parent>
-
-  <artifactId>org.eclipse.tracecompass.lttng2.ust.core</artifactId>
-  <version>1.0.0-SNAPSHOT</version>
-  <packaging>eclipse-plugin</packaging>
-
-  <name>Trace Compass LTTng Userspace Tracer Analysis Core Plug-in</name>
-
- <build>
-    <plugins>
-      <plugin>
-        <groupId>org.eclipse.tycho</groupId>
-        <artifactId>tycho-source-plugin</artifactId>
-      </plugin>
-    </plugins>
-  </build>
-
-  <groupId>org.eclipse.tracecompass</groupId>
-</project>
diff --git a/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/internal/lttng2/ust/core/Activator.java b/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/internal/lttng2/ust/core/Activator.java
deleted file mode 100644 (file)
index 9fc434c..0000000
+++ /dev/null
@@ -1,137 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2013, 2015 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:
- *   Alexandre Montplaisir - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.ust.core;
-
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Plugin;
-import org.eclipse.core.runtime.Status;
-import org.osgi.framework.BundleContext;
-
-/**
- * <b><u>Activator</u></b>
- * <p>
- * The activator class controls the plug-in life cycle
- */
-public class Activator extends Plugin {
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-
-    /**
-     * The plug-in ID
-     */
-    public static final String PLUGIN_ID = "org.eclipse.tracecompass.lttng2.ust.core"; //$NON-NLS-1$
-
-    /**
-     * The shared instance
-     */
-    private static Activator plugin;
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-
-    /**
-     * The constructor
-     */
-    public Activator() {
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    /**
-     * Returns the shared instance
-     *
-     * @return the shared instance
-     */
-    public static Activator getDefault() {
-        return plugin;
-    }
-
-    // ------------------------------------------------------------------------
-    // Operators
-    // ------------------------------------------------------------------------
-
-    @Override
-    public void start(BundleContext context) throws Exception {
-        super.start(context);
-        plugin = this;
-    }
-
-    @Override
-    public void stop(BundleContext context) throws Exception {
-        plugin = null;
-        super.stop(context);
-    }
-
-    /**
-     * Logs a message with severity INFO in the runtime log of the plug-in.
-     *
-     * @param message A message to log
-     */
-    public void logInfo(String message) {
-        getLog().log(new Status(IStatus.INFO, PLUGIN_ID, message));
-    }
-
-    /**
-     * Logs a message and exception with severity INFO in the runtime log of the plug-in.
-     *
-     * @param message A message to log
-     * @param exception A exception to log
-     */
-    public void logInfo(String message, Throwable exception) {
-        getLog().log(new Status(IStatus.INFO, PLUGIN_ID, message, exception));
-    }
-
-    /**
-     * Logs a message and exception with severity WARNING in the runtime log of the plug-in.
-     *
-     * @param message A message to log
-     */
-    public void logWarning(String message) {
-        getLog().log(new Status(IStatus.WARNING, PLUGIN_ID, message));
-    }
-
-    /**
-     * Logs a message and exception with severity WARNING in the runtime log of the plug-in.
-     *
-     * @param message A message to log
-     * @param exception A exception to log
-     */
-    public void logWarning(String message, Throwable exception) {
-        getLog().log(new Status(IStatus.WARNING, PLUGIN_ID, message, exception));
-    }
-
-    /**
-     * Logs a message and exception with severity ERROR in the runtime log of the plug-in.
-     *
-     * @param message A message to log
-     */
-    public void logError(String message) {
-        getLog().log(new Status(IStatus.ERROR, PLUGIN_ID, message));
-    }
-
-    /**
-     * Logs a message and exception with severity ERROR in the runtime log of the plug-in.
-     *
-     * @param message A message to log
-     * @param exception A exception to log
-     */
-    public void logError(String message, Throwable exception) {
-        getLog().log(new Status(IStatus.ERROR, PLUGIN_ID, message, exception));
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/internal/lttng2/ust/core/analysis/memory/UstMemoryStateProvider.java b/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/internal/lttng2/ust/core/analysis/memory/UstMemoryStateProvider.java
deleted file mode 100644 (file)
index 3175711..0000000
+++ /dev/null
@@ -1,204 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014, 2015 Ericsson, École Polytechnique de Montréal
- *
- * 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:
- *   Matthew Khouzam - Initial API and implementation
- *   Geneviève Bastien - Memory is per thread and only total is kept
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.ust.core.analysis.memory;
-
-import static org.eclipse.tracecompass.common.core.NonNullUtils.checkNotNull;
-
-import java.util.HashMap;
-import java.util.Map;
-
-import org.eclipse.jdt.annotation.NonNull;
-import org.eclipse.tracecompass.lttng2.ust.core.trace.LttngUstTrace;
-import org.eclipse.tracecompass.statesystem.core.ITmfStateSystemBuilder;
-import org.eclipse.tracecompass.statesystem.core.exceptions.AttributeNotFoundException;
-import org.eclipse.tracecompass.statesystem.core.exceptions.StateValueTypeException;
-import org.eclipse.tracecompass.statesystem.core.exceptions.TimeRangeException;
-import org.eclipse.tracecompass.statesystem.core.statevalue.ITmfStateValue;
-import org.eclipse.tracecompass.statesystem.core.statevalue.TmfStateValue;
-import org.eclipse.tracecompass.tmf.core.event.ITmfEvent;
-import org.eclipse.tracecompass.tmf.core.event.ITmfEventField;
-import org.eclipse.tracecompass.tmf.core.statesystem.AbstractTmfStateProvider;
-import org.eclipse.tracecompass.tmf.core.statesystem.ITmfStateProvider;
-
-/**
- * State provider to track the memory of the threads using the UST libc wrapper
- * memory events.
- *
- * @author Matthew Khouzam
- * @author Geneviève Bastien
- */
-public class UstMemoryStateProvider extends AbstractTmfStateProvider {
-
-    /* Version of this state provider */
-    private static final int VERSION = 1;
-
-    /* Maps a pointer to a memory zone to the size of the memory */
-    private final Map<Long, Long> fMemory = new HashMap<>();
-
-    private static final Long MINUS_ONE = Long.valueOf(-1);
-    private static final Long ZERO = Long.valueOf(0);
-    private static final String EMPTY_STRING = ""; //$NON-NLS-1$
-
-    /**
-     * Constructor
-     *
-     * @param trace
-     *            trace
-     */
-    public UstMemoryStateProvider(@NonNull LttngUstTrace trace) {
-        super(trace, "Ust:Memory"); //$NON-NLS-1$
-    }
-
-    @Override
-    protected void eventHandle(ITmfEvent event) {
-        String name = event.getName();
-        switch (name) {
-        case UstMemoryStrings.MALLOC: {
-            Long ptr = (Long) event.getContent().getField(UstMemoryStrings.FIELD_PTR).getValue();
-            if (ZERO.equals(ptr)) {
-                return;
-            }
-            Long size = (Long) event.getContent().getField(UstMemoryStrings.FIELD_SIZE).getValue();
-            setMem(event, ptr, size);
-        }
-            break;
-        case UstMemoryStrings.FREE: {
-            Long ptr = (Long) event.getContent().getField(UstMemoryStrings.FIELD_PTR).getValue();
-            if (ZERO.equals(ptr)) {
-                return;
-            }
-            setMem(event, ptr, ZERO);
-        }
-            break;
-        case UstMemoryStrings.CALLOC: {
-            Long ptr = (Long) event.getContent().getField(UstMemoryStrings.FIELD_PTR).getValue();
-            if (ZERO.equals(ptr)) {
-                return;
-            }
-            Long nmemb = (Long) event.getContent().getField(UstMemoryStrings.FIELD_NMEMB).getValue();
-            Long size = (Long) event.getContent().getField(UstMemoryStrings.FIELD_SIZE).getValue();
-            setMem(event, ptr, size * nmemb);
-        }
-            break;
-        case UstMemoryStrings.REALLOC: {
-            Long ptr = (Long) event.getContent().getField(UstMemoryStrings.FIELD_PTR).getValue();
-            if (ZERO.equals(ptr)) {
-                return;
-            }
-            Long newPtr = (Long) event.getContent().getField(UstMemoryStrings.FIELD_INPTR).getValue();
-            Long size = (Long) event.getContent().getField(UstMemoryStrings.FIELD_SIZE).getValue();
-            setMem(event, ptr, ZERO);
-            setMem(event, newPtr, size);
-        }
-            break;
-        case UstMemoryStrings.MEMALIGN: {
-            Long ptr = (Long) event.getContent().getField(UstMemoryStrings.FIELD_PTR).getValue();
-            if (ZERO.equals(ptr)) {
-                return;
-            }
-            Long size = (Long) event.getContent().getField(UstMemoryStrings.FIELD_SIZE).getValue();
-            setMem(event, ptr, size);
-        }
-            break;
-        case UstMemoryStrings.POSIX_MEMALIGN: {
-            Long ptr = (Long) event.getContent().getField(UstMemoryStrings.FIELD_OUTPTR).getValue();
-            if (ZERO.equals(ptr)) {
-                return;
-            }
-            Long size = (Long) event.getContent().getField(UstMemoryStrings.FIELD_SIZE).getValue();
-            setMem(event, ptr, size);
-        }
-            break;
-        default:
-            break;
-        }
-
-    }
-
-    @Override
-    public ITmfStateProvider getNewInstance() {
-        return new UstMemoryStateProvider(getTrace());
-    }
-
-    @Override
-    public LttngUstTrace getTrace() {
-        return (LttngUstTrace) super.getTrace();
-    }
-
-    @Override
-    public int getVersion() {
-        return VERSION;
-    }
-
-    private static Long getVtid(ITmfEvent event) {
-        ITmfEventField field = event.getContent().getField(UstMemoryStrings.CONTEXT_VTID);
-        if (field == null) {
-            return MINUS_ONE;
-        }
-        return (Long) field.getValue();
-    }
-
-    private static String getProcname(ITmfEvent event) {
-        ITmfEventField field = event.getContent().getField(UstMemoryStrings.CONTEXT_PROCNAME);
-        if (field == null) {
-            return EMPTY_STRING;
-        }
-        return (String) field.getValue();
-    }
-
-    private void setMem(ITmfEvent event, Long ptr, Long size) {
-        ITmfStateSystemBuilder ss = checkNotNull(getStateSystemBuilder());
-        long ts = event.getTimestamp().getValue();
-        Long tid = getVtid(event);
-
-        Long memoryDiff = size;
-        /* Size is 0, it means it was deleted */
-        if (ZERO.equals(size)) {
-            Long memSize = fMemory.remove(ptr);
-            if (memSize == null) {
-                return;
-            }
-            memoryDiff = -memSize;
-        } else {
-            fMemory.put(ptr, size);
-        }
-        try {
-            int tidQuark = ss.getQuarkAbsoluteAndAdd(tid.toString());
-            int tidMemQuark = ss.getQuarkRelativeAndAdd(tidQuark, UstMemoryStrings.UST_MEMORY_MEMORY_ATTRIBUTE);
-
-            ITmfStateValue prevMem = ss.queryOngoingState(tidMemQuark);
-            /* First time we set this value */
-            if (prevMem.isNull()) {
-                int procNameQuark = ss.getQuarkRelativeAndAdd(tidQuark, UstMemoryStrings.UST_MEMORY_PROCNAME_ATTRIBUTE);
-                String procName = getProcname(event);
-                /*
-                 * No tid/procname for the event for the event, added to a
-                 * 'others' thread
-                 */
-                if (tid.equals(MINUS_ONE)) {
-                    procName = UstMemoryStrings.OTHERS;
-                }
-                ss.modifyAttribute(ts, TmfStateValue.newValueString(procName), procNameQuark);
-                prevMem = TmfStateValue.newValueLong(0);
-            }
-
-            long prevMemValue = prevMem.unboxLong();
-            prevMemValue += memoryDiff.longValue();
-            ss.modifyAttribute(ts, TmfStateValue.newValueLong(prevMemValue), tidMemQuark);
-        } catch (AttributeNotFoundException | TimeRangeException | StateValueTypeException e) {
-            throw new IllegalStateException(e);
-        }
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/internal/lttng2/ust/core/analysis/memory/UstMemoryStrings.java b/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/internal/lttng2/ust/core/analysis/memory/UstMemoryStrings.java
deleted file mode 100644 (file)
index b573a3f..0000000
+++ /dev/null
@@ -1,51 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2014 Ericsson, École Polytechnique de Montréal
- *
- * 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:
- *   Matthew Khouzam, Geneviève Bastien - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.ust.core.analysis.memory;
-
-/**
- * Strings for the memory usage state system using the LTTng UST libc
- * instrumentation
- *
- * @author Matthew Khouzam
- * @author Geneviève Bastien
- */
-@SuppressWarnings({ "nls", "javadoc" })
-public interface UstMemoryStrings {
-
-    /** Memory state system attribute name */
-    static final String UST_MEMORY_MEMORY_ATTRIBUTE = "Memory"; //$NON-NLS-1$
-    /** Procname state system attribute name */
-    static final String UST_MEMORY_PROCNAME_ATTRIBUTE = "Procname"; //$NON-NLS-1$
-    /** Name of the attribute to store memory usage of events with no context */
-    static final String OTHERS = "Others";
-
-    /* UST_libc event names */
-    static final String MALLOC = "ust_libc:malloc";
-    static final String CALLOC = "ust_libc:calloc";
-    static final String REALLOC = "ust_libc:realloc";
-    static final String FREE = "ust_libc:free";
-    static final String MEMALIGN = "ust_libc:memalign";
-    static final String POSIX_MEMALIGN = "ust_libc:posix_memalign";
-
-    /* Possible contexts */
-    static final String CONTEXT_VTID = "context._vtid";
-    static final String CONTEXT_PROCNAME = "context._procname";
-
-    /* Event fields */
-    static final String FIELD_PTR = "ptr";
-    static final String FIELD_NMEMB = "nmemb";
-    static final String FIELD_SIZE = "size";
-    static final String FIELD_OUTPTR = "out_ptr";
-    static final String FIELD_INPTR = "in_ptr";
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/internal/lttng2/ust/core/callstack/LttngUstCallStackProvider.java b/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/internal/lttng2/ust/core/callstack/LttngUstCallStackProvider.java
deleted file mode 100644 (file)
index 6d14911..0000000
+++ /dev/null
@@ -1,172 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2013, 2015 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:
- *   Alexandre Montplaisir - Initial API and implementation
- *   Patrick Tasse - Add support for thread id
- *******************************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.ust.core.callstack;
-
-import java.util.HashSet;
-import java.util.Set;
-
-import org.eclipse.jdt.annotation.NonNull;
-import org.eclipse.tracecompass.tmf.core.callstack.CallStackStateProvider;
-import org.eclipse.tracecompass.tmf.core.event.ITmfEvent;
-import org.eclipse.tracecompass.tmf.core.event.ITmfEventField;
-import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace;
-import org.eclipse.tracecompass.tmf.ctf.core.event.CtfTmfEvent;
-
-/**
- * Callstack provider for LTTng-UST traces.
- *
- * If the traces contains 'func_entry' and 'func_exit' event (see the
- * lttng-ust-cyg-profile manpage), AND contains vtid and procname contexts, we
- * can use this information to populate the TMF Callstack View.
- *
- * Granted, most UST traces will not contain this information. In this case,
- * this will simply build an empty state system, and the view will remain
- * unavailable.
- *
- * @author Alexandre Montplaisir
- */
-public class LttngUstCallStackProvider extends CallStackStateProvider {
-
-    // ------------------------------------------------------------------------
-    // Event strings
-    // ------------------------------------------------------------------------
-
-    /** Name of the fake field for the vtid contexts */
-    private static final String CONTEXT_VTID = "context._vtid"; //$NON-NLS-1$
-
-    /** Name of the fake field for the procname context */
-    private static final String CONTEXT_PROCNAME = "context._procname"; //$NON-NLS-1$
-
-    /** Field name for the target function address */
-    private static final String FIELD_ADDR = "addr"; //$NON-NLS-1$
-
-    /** Event names indicating function entry */
-    private static final Set<String> FUNC_ENTRY_EVENTS = new HashSet<>();
-
-    /** Event names indicating function exit */
-    private static final Set<String> FUNC_EXIT_EVENTS = new HashSet<>();
-
-    static {
-        /* This seems overkill, but it will be checked every event. Gotta go FAST! */
-        FUNC_ENTRY_EVENTS.add("lttng_ust_cyg_profile:func_entry"); //$NON-NLS-1$
-        FUNC_ENTRY_EVENTS.add("lttng_ust_cyg_profile_fast:func_entry"); //$NON-NLS-1$
-
-        FUNC_EXIT_EVENTS.add("lttng_ust_cyg_profile:func_exit"); //$NON-NLS-1$
-        FUNC_EXIT_EVENTS.add("lttng_ust_cyg_profile_fast:func_exit"); //$NON-NLS-1$
-    }
-
-    /**
-     * Version number of this state provider. Please bump this if you modify
-     * the contents of the generated state history in some way.
-     */
-    private static final int VERSION = 2;
-
-    // ------------------------------------------------------------------------
-    // Constructor
-    // ------------------------------------------------------------------------
-
-    /**
-     * Constructor
-     *
-     * @param trace
-     *            The UST trace
-     */
-    public LttngUstCallStackProvider(@NonNull ITmfTrace trace) {
-        super(trace);
-    }
-
-    // ------------------------------------------------------------------------
-    // Methods from AbstractTmfStateProvider
-    // ------------------------------------------------------------------------
-
-    @Override
-    public LttngUstCallStackProvider getNewInstance() {
-        return new LttngUstCallStackProvider(getTrace());
-    }
-
-    @Override
-    public int getVersion() {
-        return VERSION;
-    }
-
-    // ------------------------------------------------------------------------
-    // Methods from CallStackStateProvider
-    // ------------------------------------------------------------------------
-
-    /**
-     * Check that this event contains the required information we need to be
-     * used in the call stack view. We need at least the "procname" and "vtid"
-     * contexts.
-     */
-    @Override
-    protected boolean considerEvent(ITmfEvent event) {
-        if (!(event instanceof CtfTmfEvent)) {
-            return false;
-        }
-        ITmfEventField content = ((CtfTmfEvent) event).getContent();
-        if (content.getField(CONTEXT_VTID) == null ||
-                content.getField(CONTEXT_PROCNAME) == null) {
-            return false;
-        }
-        return true;
-    }
-
-    @Override
-    public String functionEntry(ITmfEvent event) {
-        String eventName = event.getName();
-        if (!FUNC_ENTRY_EVENTS.contains(eventName)) {
-            return null;
-        }
-        Long address = (Long) event.getContent().getField(FIELD_ADDR).getValue();
-        return Long.toHexString(address);
-    }
-
-    @Override
-    public String functionExit(ITmfEvent event) {
-        String eventName = event.getName();
-        if (!FUNC_EXIT_EVENTS.contains(eventName)) {
-            return null;
-        }
-        /*
-         * The 'addr' field may or may not be present in func_exit events,
-         * depending on if cyg-profile.so or cyg-profile-fast.so was used.
-         */
-        ITmfEventField field = event.getContent().getField(FIELD_ADDR);
-        if (field == null) {
-            return CallStackStateProvider.UNDEFINED;
-        }
-        Long address = (Long) field.getValue();
-        return Long.toHexString(address);
-    }
-
-    @Override
-    public String getThreadName(ITmfEvent event) {
-        /* Class type and content was already checked if we get called here */
-        ITmfEventField content = ((CtfTmfEvent) event).getContent();
-        String procName = (String) content.getField(CONTEXT_PROCNAME).getValue();
-        Long vtid = (Long) content.getField(CONTEXT_VTID).getValue();
-
-        if (procName == null || vtid == null) {
-            throw new IllegalStateException();
-        }
-
-        return new String(procName + '-' + vtid.toString());
-    }
-
-    @Override
-    protected Long getThreadId(ITmfEvent event) {
-        ITmfEventField content = ((CtfTmfEvent) event).getContent();
-        return (Long) content.getField(CONTEXT_VTID).getValue();
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/lttng2/ust/core/analysis/memory/Messages.java b/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/lttng2/ust/core/analysis/memory/Messages.java
deleted file mode 100644 (file)
index 41cdf3c..0000000
+++ /dev/null
@@ -1,37 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2014 École Polytechnique de Montréal
- *
- * 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:
- *   Guilliano Molaire - Initial API and implementation
- *******************************************************************************/
-package org.eclipse.tracecompass.lttng2.ust.core.analysis.memory;
-
-import org.eclipse.osgi.util.NLS;
-
-/**
- * Message bundle for the ust memory analysis module
- *
- * @author Guilliano Molaire
- */
-public class Messages extends NLS {
-    private static final String BUNDLE_NAME = "org.eclipse.tracecompass.lttng2.ust.core.analysis.memory.messages"; //$NON-NLS-1$
-
-    /** Information regarding events loading prior to the analysis execution */
-    public static String UstMemoryAnalysisModule_EventsLoadingInformation;
-
-    /** Example of how to execute the application with the libc wrapper */
-    public static String UstMemoryAnalysisModule_EventsLoadingExampleInformation;
-
-    static {
-        // initialize resource bundle
-        NLS.initializeMessages(BUNDLE_NAME, Messages.class);
-    }
-
-    private Messages() {
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/lttng2/ust/core/analysis/memory/UstMemoryAnalysisModule.java b/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/lttng2/ust/core/analysis/memory/UstMemoryAnalysisModule.java
deleted file mode 100644 (file)
index 43bea13..0000000
+++ /dev/null
@@ -1,101 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2014, 2015 École Polytechnique de Montréal
- *
- * 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:
- *   Geneviève Bastien - Initial API and implementation
- *   Guilliano Molaire - Provide the requirements of the analysis
- *******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.ust.core.analysis.memory;
-
-import static org.eclipse.tracecompass.common.core.NonNullUtils.checkNotNull;
-
-import java.util.Set;
-
-import org.eclipse.jdt.annotation.NonNull;
-import org.eclipse.tracecompass.internal.lttng2.ust.core.analysis.memory.UstMemoryStateProvider;
-import org.eclipse.tracecompass.internal.lttng2.ust.core.analysis.memory.UstMemoryStrings;
-import org.eclipse.tracecompass.lttng2.control.core.session.SessionConfigStrings;
-import org.eclipse.tracecompass.lttng2.ust.core.trace.LttngUstTrace;
-import org.eclipse.tracecompass.tmf.core.analysis.TmfAnalysisRequirement;
-import org.eclipse.tracecompass.tmf.core.analysis.TmfAnalysisRequirement.ValuePriorityLevel;
-import org.eclipse.tracecompass.tmf.core.exceptions.TmfAnalysisException;
-import org.eclipse.tracecompass.tmf.core.statesystem.ITmfStateProvider;
-import org.eclipse.tracecompass.tmf.core.statesystem.TmfStateSystemAnalysisModule;
-import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace;
-
-import com.google.common.collect.ImmutableSet;
-
-/**
- * This analysis build a state system from the libc memory instrumentation on a
- * UST trace
- *
- * @author Geneviève Bastien
- */
-public class UstMemoryAnalysisModule extends TmfStateSystemAnalysisModule {
-
-    /**
-     * Analysis ID, it should match that in the plugin.xml file
-     */
-    public static final @NonNull String ID = "org.eclipse.linuxtools.lttng2.ust.analysis.memory"; //$NON-NLS-1$
-
-    private static final ImmutableSet<String> REQUIRED_EVENTS = ImmutableSet.of(
-            UstMemoryStrings.MALLOC,
-            UstMemoryStrings.FREE,
-            UstMemoryStrings.CALLOC,
-            UstMemoryStrings.REALLOC,
-            UstMemoryStrings.MEMALIGN,
-            UstMemoryStrings.POSIX_MEMALIGN
-            );
-
-    /** The requirements as an immutable set */
-    private static final @NonNull Set<TmfAnalysisRequirement> REQUIREMENTS;
-
-    static {
-        /* Initialize the requirements for the analysis: domain and events */
-        TmfAnalysisRequirement eventsReq = new TmfAnalysisRequirement(SessionConfigStrings.CONFIG_ELEMENT_EVENT, REQUIRED_EVENTS, ValuePriorityLevel.MANDATORY);
-        /*
-         * In order to have these events, the libc wrapper with probes should be
-         * loaded
-         */
-        eventsReq.addInformation(Messages.UstMemoryAnalysisModule_EventsLoadingInformation);
-        eventsReq.addInformation(Messages.UstMemoryAnalysisModule_EventsLoadingExampleInformation);
-
-        /* The domain type of the analysis */
-        TmfAnalysisRequirement domainReq = new TmfAnalysisRequirement(SessionConfigStrings.CONFIG_ELEMENT_DOMAIN);
-        domainReq.addValue(SessionConfigStrings.CONFIG_DOMAIN_TYPE_UST, ValuePriorityLevel.MANDATORY);
-
-        REQUIREMENTS = checkNotNull(ImmutableSet.of(domainReq, eventsReq));
-    }
-
-    @Override
-    protected ITmfStateProvider createStateProvider() {
-        return new UstMemoryStateProvider(checkNotNull(getTrace()));
-    }
-
-    /**
-     * @since 1.0
-     */
-    @Override
-    public boolean setTrace(ITmfTrace trace) throws TmfAnalysisException {
-        if (!(trace instanceof LttngUstTrace)) {
-            return false;
-        }
-        return super.setTrace(trace);
-    }
-
-    @Override
-    protected LttngUstTrace getTrace() {
-        return (LttngUstTrace) super.getTrace();
-    }
-
-    @Override
-    public Iterable<TmfAnalysisRequirement> getAnalysisRequirements() {
-        return REQUIREMENTS;
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/lttng2/ust/core/analysis/memory/messages.properties b/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/lttng2/ust/core/analysis/memory/messages.properties
deleted file mode 100644 (file)
index e271aaa..0000000
+++ /dev/null
@@ -1,13 +0,0 @@
-###############################################################################
-# Copyright (c) 2015 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:
-#     Ericsson - Initial API and implementation
-###############################################################################
-UstMemoryAnalysisModule_EventsLoadingInformation=The libc wrapper should be loaded in order to get the events in the trace output.
-UstMemoryAnalysisModule_EventsLoadingExampleInformation=Start the application to trace with: LD_PRELOAD=/path/to/liblttng-ust-libc-wrapper.so ./myProgram.
diff --git a/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/lttng2/ust/core/trace/LttngUstTrace.java b/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/lttng2/ust/core/trace/LttngUstTrace.java
deleted file mode 100644 (file)
index fd56bf0..0000000
+++ /dev/null
@@ -1,63 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2013, 2014 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:
- *   Matthew Khouzam - Initial API and implementation
- *   Alexandre Montplaisir - Add UST callstack state system
- *   Marc-Andre Laperle - Handle BufferOverflowException (Bug 420203)
- **********************************************************************/
-
-package org.eclipse.tracecompass.lttng2.ust.core.trace;
-
-import java.util.Map;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.tracecompass.internal.lttng2.ust.core.Activator;
-import org.eclipse.tracecompass.tmf.core.trace.TraceValidationStatus;
-import org.eclipse.tracecompass.tmf.ctf.core.trace.CtfTmfTrace;
-import org.eclipse.tracecompass.tmf.ctf.core.trace.CtfTraceValidationStatus;
-
-/**
- * Class to contain LTTng-UST traces
- *
- * @author Matthew Khouzam
- */
-public class LttngUstTrace extends CtfTmfTrace {
-
-    private static final int CONFIDENCE = 100;
-
-    /**
-     * Default constructor
-     */
-    public LttngUstTrace() {
-        super();
-    }
-
-    /**
-     * {@inheritDoc}
-     * <p>
-     * This implementation sets the confidence to 100 if the trace is a valid
-     * CTF trace in the "ust" domain.
-     */
-    @Override
-    public IStatus validate(final IProject project, final String path) {
-        IStatus status = super.validate(project, path);
-        if (status instanceof CtfTraceValidationStatus) {
-            Map<String, String> environment = ((CtfTraceValidationStatus) status).getEnvironment();
-            /* Make sure the domain is "ust" in the trace's env vars */
-            String domain = environment.get("domain"); //$NON-NLS-1$
-            if (domain == null || !domain.equals("\"ust\"")) { //$NON-NLS-1$
-                return new Status(IStatus.ERROR, Activator.PLUGIN_ID, Messages.LttngUstTrace_DomainError);
-            }
-            return new TraceValidationStatus(CONFIDENCE, Activator.PLUGIN_ID);
-        }
-        return status;
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/lttng2/ust/core/trace/Messages.java b/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/lttng2/ust/core/trace/Messages.java
deleted file mode 100644 (file)
index a2e3ea5..0000000
+++ /dev/null
@@ -1,47 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2013, 2014 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:
- *     Matthew Khouzam - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.ust.core.trace;
-
-import org.eclipse.osgi.util.NLS;
-
-/**
- * Message bundle for lttng2.kernel.core.trace
- *
- * @author Matthew Khouzam
- */
-public class Messages extends NLS {
-
-    private static final String BUNDLE_NAME = "org.eclipse.tracecompass.lttng2.ust.core.trace.messages"; //$NON-NLS-1$
-
-    /**
-     * The domain is not "ust"
-     */
-    public static String LttngUstTrace_DomainError;
-
-    /**
-     * Malformed trace (buffer overflow maybe?)
-     */
-    public static String LttngUstTrace_MalformedTrace;
-
-    /**
-     * Trace read error
-     */
-    public static String LttngUstTrace_TraceReadError;
-
-    static {
-        // initialize resource bundle
-        NLS.initializeMessages(BUNDLE_NAME, Messages.class);
-    }
-
-    private Messages() {
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/lttng2/ust/core/trace/messages.properties b/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/lttng2/ust/core/trace/messages.properties
deleted file mode 100644 (file)
index 1d44d7d..0000000
+++ /dev/null
@@ -1,15 +0,0 @@
-###############################################################################
-# Copyright (c) 2013, 2014 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:
-#     Ericsson - Initial API and implementation
-###############################################################################
-
-LttngUstTrace_DomainError=Domain mismatch, the environment should be 'ust'.
-LttngUstTrace_MalformedTrace=Buffer overflow exception, trace is malformed
-LttngUstTrace_TraceReadError=Lttng UST trace read error
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.ust.ui.tests/.classpath b/org.eclipse.tracecompass.lttng2.ust.ui.tests/.classpath
deleted file mode 100644 (file)
index 098194c..0000000
+++ /dev/null
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
-       <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7"/>
-       <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
-       <classpathentry kind="src" path="src"/>
-       <classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/org.eclipse.tracecompass.lttng2.ust.ui.tests/.project b/org.eclipse.tracecompass.lttng2.ust.ui.tests/.project
deleted file mode 100644 (file)
index bbd5f4d..0000000
+++ /dev/null
@@ -1,34 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
-       <name>org.eclipse.tracecompass.lttng2.ust.ui.tests</name>
-       <comment></comment>
-       <projects>
-       </projects>
-       <buildSpec>
-               <buildCommand>
-                       <name>org.eclipse.jdt.core.javabuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-               <buildCommand>
-                       <name>org.eclipse.pde.ManifestBuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-               <buildCommand>
-                       <name>org.eclipse.pde.SchemaBuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-               <buildCommand>
-                       <name>org.eclipse.pde.api.tools.apiAnalysisBuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-       </buildSpec>
-       <natures>
-               <nature>org.eclipse.pde.PluginNature</nature>
-               <nature>org.eclipse.jdt.core.javanature</nature>
-               <nature>org.eclipse.pde.api.tools.apiAnalysisNature</nature>
-       </natures>
-</projectDescription>
diff --git a/org.eclipse.tracecompass.lttng2.ust.ui.tests/.settings/org.eclipse.core.resources.prefs b/org.eclipse.tracecompass.lttng2.ust.ui.tests/.settings/org.eclipse.core.resources.prefs
deleted file mode 100644 (file)
index 99f26c0..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-eclipse.preferences.version=1
-encoding/<project>=UTF-8
diff --git a/org.eclipse.tracecompass.lttng2.ust.ui.tests/.settings/org.eclipse.core.runtime.prefs b/org.eclipse.tracecompass.lttng2.ust.ui.tests/.settings/org.eclipse.core.runtime.prefs
deleted file mode 100644 (file)
index 5a0ad22..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-eclipse.preferences.version=1
-line.separator=\n
diff --git a/org.eclipse.tracecompass.lttng2.ust.ui.tests/.settings/org.eclipse.jdt.core.prefs b/org.eclipse.tracecompass.lttng2.ust.ui.tests/.settings/org.eclipse.jdt.core.prefs
deleted file mode 100644 (file)
index 0409c61..0000000
+++ /dev/null
@@ -1,403 +0,0 @@
-eclipse.preferences.version=1
-org.eclipse.jdt.core.codeComplete.argumentPrefixes=
-org.eclipse.jdt.core.codeComplete.argumentSuffixes=
-org.eclipse.jdt.core.codeComplete.fieldPrefixes=f
-org.eclipse.jdt.core.codeComplete.fieldSuffixes=
-org.eclipse.jdt.core.codeComplete.localPrefixes=
-org.eclipse.jdt.core.codeComplete.localSuffixes=
-org.eclipse.jdt.core.codeComplete.staticFieldPrefixes=
-org.eclipse.jdt.core.codeComplete.staticFieldSuffixes=
-org.eclipse.jdt.core.codeComplete.staticFinalFieldPrefixes=
-org.eclipse.jdt.core.codeComplete.staticFinalFieldSuffixes=
-org.eclipse.jdt.core.compiler.annotation.inheritNullAnnotations=enabled
-org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore
-org.eclipse.jdt.core.compiler.annotation.nonnull=org.eclipse.jdt.annotation.NonNull
-org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=org.eclipse.jdt.annotation.NonNullByDefault
-org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nullable
-org.eclipse.jdt.core.compiler.annotation.nullanalysis=enabled
-org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
-org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
-org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
-org.eclipse.jdt.core.compiler.compliance=1.7
-org.eclipse.jdt.core.compiler.debug.lineNumber=generate
-org.eclipse.jdt.core.compiler.debug.localVariable=generate
-org.eclipse.jdt.core.compiler.debug.sourceFile=generate
-org.eclipse.jdt.core.compiler.doc.comment.support=enabled
-org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=error
-org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
-org.eclipse.jdt.core.compiler.problem.autoboxing=ignore
-org.eclipse.jdt.core.compiler.problem.comparingIdentical=error
-org.eclipse.jdt.core.compiler.problem.deadCode=error
-org.eclipse.jdt.core.compiler.problem.deprecation=error
-org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled
-org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=enabled
-org.eclipse.jdt.core.compiler.problem.discouragedReference=error
-org.eclipse.jdt.core.compiler.problem.emptyStatement=error
-org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
-org.eclipse.jdt.core.compiler.problem.explicitlyClosedAutoCloseable=error
-org.eclipse.jdt.core.compiler.problem.fallthroughCase=error
-org.eclipse.jdt.core.compiler.problem.fatalOptionalError=disabled
-org.eclipse.jdt.core.compiler.problem.fieldHiding=error
-org.eclipse.jdt.core.compiler.problem.finalParameterBound=error
-org.eclipse.jdt.core.compiler.problem.finallyBlockNotCompletingNormally=error
-org.eclipse.jdt.core.compiler.problem.forbiddenReference=error
-org.eclipse.jdt.core.compiler.problem.hiddenCatchBlock=error
-org.eclipse.jdt.core.compiler.problem.includeNullInfoFromAsserts=disabled
-org.eclipse.jdt.core.compiler.problem.incompatibleNonInheritedInterfaceMethod=error
-org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch=error
-org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=error
-org.eclipse.jdt.core.compiler.problem.invalidJavadoc=warning
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTags=enabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsDeprecatedRef=enabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsNotVisibleRef=enabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsVisibility=protected
-org.eclipse.jdt.core.compiler.problem.localVariableHiding=error
-org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=error
-org.eclipse.jdt.core.compiler.problem.missingDefaultCase=error
-org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=error
-org.eclipse.jdt.core.compiler.problem.missingEnumCaseDespiteDefault=enabled
-org.eclipse.jdt.core.compiler.problem.missingHashCodeMethod=error
-org.eclipse.jdt.core.compiler.problem.missingJavadocComments=warning
-org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsOverriding=disabled
-org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsVisibility=protected
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagDescription=all_standard_tags
-org.eclipse.jdt.core.compiler.problem.missingJavadocTags=warning
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagsMethodTypeParameters=disabled
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagsOverriding=disabled
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagsVisibility=protected
-org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotation=error
-org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotationForInterfaceMethodImplementation=enabled
-org.eclipse.jdt.core.compiler.problem.missingSerialVersion=error
-org.eclipse.jdt.core.compiler.problem.missingSynchronizedOnInheritedMethod=error
-org.eclipse.jdt.core.compiler.problem.noEffectAssignment=error
-org.eclipse.jdt.core.compiler.problem.noImplicitStringConversion=error
-org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=ignore
-org.eclipse.jdt.core.compiler.problem.nonnullParameterAnnotationDropped=warning
-org.eclipse.jdt.core.compiler.problem.nullAnnotationInferenceConflict=warning
-org.eclipse.jdt.core.compiler.problem.nullReference=error
-org.eclipse.jdt.core.compiler.problem.nullSpecViolation=error
-org.eclipse.jdt.core.compiler.problem.nullUncheckedConversion=warning
-org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=error
-org.eclipse.jdt.core.compiler.problem.parameterAssignment=error
-org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=error
-org.eclipse.jdt.core.compiler.problem.potentialNullReference=error
-org.eclipse.jdt.core.compiler.problem.potentiallyUnclosedCloseable=warning
-org.eclipse.jdt.core.compiler.problem.rawTypeReference=error
-org.eclipse.jdt.core.compiler.problem.redundantNullAnnotation=warning
-org.eclipse.jdt.core.compiler.problem.redundantNullCheck=error
-org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=error
-org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=error
-org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore
-org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=error
-org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled
-org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=error
-org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=disabled
-org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled
-org.eclipse.jdt.core.compiler.problem.syntacticNullAnalysisForFields=enabled
-org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=ignore
-org.eclipse.jdt.core.compiler.problem.typeParameterHiding=error
-org.eclipse.jdt.core.compiler.problem.unavoidableGenericTypeProblems=disabled
-org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=error
-org.eclipse.jdt.core.compiler.problem.unclosedCloseable=error
-org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=ignore
-org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=error
-org.eclipse.jdt.core.compiler.problem.unnecessaryElse=error
-org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=error
-org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=error
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionExemptExceptionAndThrowable=disabled
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionIncludeDocCommentReference=disabled
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverriding=disabled
-org.eclipse.jdt.core.compiler.problem.unusedImport=error
-org.eclipse.jdt.core.compiler.problem.unusedLabel=error
-org.eclipse.jdt.core.compiler.problem.unusedLocal=error
-org.eclipse.jdt.core.compiler.problem.unusedObjectAllocation=ignore
-org.eclipse.jdt.core.compiler.problem.unusedParameter=ignore
-org.eclipse.jdt.core.compiler.problem.unusedParameterIncludeDocCommentReference=enabled
-org.eclipse.jdt.core.compiler.problem.unusedParameterWhenImplementingAbstract=disabled
-org.eclipse.jdt.core.compiler.problem.unusedParameterWhenOverridingConcrete=disabled
-org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=error
-org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=ignore
-org.eclipse.jdt.core.compiler.problem.unusedWarningToken=error
-org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=error
-org.eclipse.jdt.core.compiler.source=1.7
-org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_call=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression=16
-org.eclipse.jdt.core.formatter.alignment_for_assignment=0
-org.eclipse.jdt.core.formatter.alignment_for_binary_expression=16
-org.eclipse.jdt.core.formatter.alignment_for_compact_if=16
-org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=80
-org.eclipse.jdt.core.formatter.alignment_for_enum_constants=0
-org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=16
-org.eclipse.jdt.core.formatter.alignment_for_method_declaration=0
-org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16
-org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=80
-org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation=0
-org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_constructor_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_method_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_union_type_in_multicatch=16
-org.eclipse.jdt.core.formatter.blank_lines_after_imports=1
-org.eclipse.jdt.core.formatter.blank_lines_after_package=1
-org.eclipse.jdt.core.formatter.blank_lines_before_field=0
-org.eclipse.jdt.core.formatter.blank_lines_before_first_class_body_declaration=0
-org.eclipse.jdt.core.formatter.blank_lines_before_imports=1
-org.eclipse.jdt.core.formatter.blank_lines_before_member_type=1
-org.eclipse.jdt.core.formatter.blank_lines_before_method=1
-org.eclipse.jdt.core.formatter.blank_lines_before_new_chunk=1
-org.eclipse.jdt.core.formatter.blank_lines_before_package=0
-org.eclipse.jdt.core.formatter.blank_lines_between_import_groups=1
-org.eclipse.jdt.core.formatter.blank_lines_between_type_declarations=1
-org.eclipse.jdt.core.formatter.brace_position_for_annotation_type_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_array_initializer=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_block=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_block_in_case=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_constructor_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_enum_constant=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_enum_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_method_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_switch=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_type_declaration=end_of_line
-org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_block_comment=false
-org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_javadoc_comment=false
-org.eclipse.jdt.core.formatter.comment.format_block_comments=true
-org.eclipse.jdt.core.formatter.comment.format_header=false
-org.eclipse.jdt.core.formatter.comment.format_html=true
-org.eclipse.jdt.core.formatter.comment.format_javadoc_comments=true
-org.eclipse.jdt.core.formatter.comment.format_line_comments=true
-org.eclipse.jdt.core.formatter.comment.format_source_code=true
-org.eclipse.jdt.core.formatter.comment.indent_parameter_description=true
-org.eclipse.jdt.core.formatter.comment.indent_root_tags=true
-org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags=insert
-org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter=insert
-org.eclipse.jdt.core.formatter.comment.line_length=80
-org.eclipse.jdt.core.formatter.comment.new_lines_at_block_boundaries=true
-org.eclipse.jdt.core.formatter.comment.new_lines_at_javadoc_boundaries=true
-org.eclipse.jdt.core.formatter.comment.preserve_white_space_between_code_and_line_comments=false
-org.eclipse.jdt.core.formatter.compact_else_if=true
-org.eclipse.jdt.core.formatter.continuation_indentation=2
-org.eclipse.jdt.core.formatter.continuation_indentation_for_array_initializer=2
-org.eclipse.jdt.core.formatter.disabling_tag=@formatter\:off
-org.eclipse.jdt.core.formatter.enabling_tag=@formatter\:on
-org.eclipse.jdt.core.formatter.format_guardian_clause_on_one_line=false
-org.eclipse.jdt.core.formatter.format_line_comment_starting_on_first_column=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_annotation_declaration_header=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_constant_header=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_declaration_header=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_type_header=true
-org.eclipse.jdt.core.formatter.indent_breaks_compare_to_cases=true
-org.eclipse.jdt.core.formatter.indent_empty_lines=false
-org.eclipse.jdt.core.formatter.indent_statements_compare_to_block=true
-org.eclipse.jdt.core.formatter.indent_statements_compare_to_body=true
-org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_cases=true
-org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_switch=false
-org.eclipse.jdt.core.formatter.indentation.size=4
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_field=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_local_variable=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_method=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_package=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_parameter=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_type=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_label=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_opening_brace_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_at_end_of_file_if_missing=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_finally_in_try_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_while_in_do_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_annotation_declaration=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_anonymous_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_block=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter=insert
-org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_binary_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_paren_in_cast=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_assert=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_case=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_labeled_statement=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_allocation_expression=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_annotation=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_throws=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_constant_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_declarations=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_explicitconstructorcall_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_increments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_inits=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_throws=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_invocation_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_field_declarations=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_local_declarations=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_parameterized_type_reference=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_superinterfaces=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_ellipsis=insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_brace_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_cast=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_catch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_for=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_if=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_parenthesized_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_switch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_synchronized=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_try=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_while=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_try_resources=insert
-org.eclipse.jdt.core.formatter.insert_space_after_unary_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter=insert
-org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_binary_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_brace_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_cast=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_catch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_for=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_if=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_parenthesized_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_switch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_synchronized=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_try=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_while=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_assert=insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_case=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_default=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_labeled_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_throws=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_constant_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_declarations=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_explicitconstructorcall_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_increments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_inits=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_throws=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_invocation_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_field_declarations=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_local_declarations=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_superinterfaces=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_ellipsis=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_annotation_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_anonymous_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_block=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_constructor_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_constant=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_method_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_switch=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation_type_member_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_catch=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_if=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_parenthesized_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_switch=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_synchronized=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_try=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_while=insert
-org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_return=insert
-org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_throw=insert
-org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_semicolon=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_try_resources=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_unary_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_brackets_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_annotation_type_member_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.join_lines_in_comments=true
-org.eclipse.jdt.core.formatter.join_wrapped_lines=false
-org.eclipse.jdt.core.formatter.keep_else_statement_on_same_line=false
-org.eclipse.jdt.core.formatter.keep_empty_array_initializer_on_one_line=false
-org.eclipse.jdt.core.formatter.keep_imple_if_on_one_line=false
-org.eclipse.jdt.core.formatter.keep_then_statement_on_same_line=false
-org.eclipse.jdt.core.formatter.lineSplit=250
-org.eclipse.jdt.core.formatter.never_indent_block_comments_on_first_column=false
-org.eclipse.jdt.core.formatter.never_indent_line_comments_on_first_column=false
-org.eclipse.jdt.core.formatter.number_of_blank_lines_at_beginning_of_method_body=0
-org.eclipse.jdt.core.formatter.number_of_empty_lines_to_preserve=1
-org.eclipse.jdt.core.formatter.put_empty_statement_on_new_line=true
-org.eclipse.jdt.core.formatter.tabulation.char=space
-org.eclipse.jdt.core.formatter.tabulation.size=4
-org.eclipse.jdt.core.formatter.use_on_off_tags=false
-org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false
-org.eclipse.jdt.core.formatter.wrap_before_binary_operator=true
-org.eclipse.jdt.core.formatter.wrap_before_or_operator_multicatch=true
-org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true
diff --git a/org.eclipse.tracecompass.lttng2.ust.ui.tests/.settings/org.eclipse.jdt.ui.prefs b/org.eclipse.tracecompass.lttng2.ust.ui.tests/.settings/org.eclipse.jdt.ui.prefs
deleted file mode 100644 (file)
index 232a3fd..0000000
+++ /dev/null
@@ -1,60 +0,0 @@
-eclipse.preferences.version=1
-editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true
-formatter_profile=_tmf-style
-formatter_settings_version=12
-org.eclipse.jdt.ui.exception.name=e
-org.eclipse.jdt.ui.gettersetter.use.is=true
-org.eclipse.jdt.ui.keywordthis=false
-org.eclipse.jdt.ui.overrideannotation=true
-sp_cleanup.add_default_serial_version_id=true
-sp_cleanup.add_generated_serial_version_id=false
-sp_cleanup.add_missing_annotations=false
-sp_cleanup.add_missing_deprecated_annotations=true
-sp_cleanup.add_missing_methods=false
-sp_cleanup.add_missing_nls_tags=false
-sp_cleanup.add_missing_override_annotations=true
-sp_cleanup.add_missing_override_annotations_interface_methods=true
-sp_cleanup.add_serial_version_id=false
-sp_cleanup.always_use_blocks=true
-sp_cleanup.always_use_parentheses_in_expressions=false
-sp_cleanup.always_use_this_for_non_static_field_access=false
-sp_cleanup.always_use_this_for_non_static_method_access=false
-sp_cleanup.convert_to_enhanced_for_loop=false
-sp_cleanup.correct_indentation=false
-sp_cleanup.format_source_code=false
-sp_cleanup.format_source_code_changes_only=false
-sp_cleanup.make_local_variable_final=false
-sp_cleanup.make_parameters_final=false
-sp_cleanup.make_private_fields_final=true
-sp_cleanup.make_type_abstract_if_missing_method=false
-sp_cleanup.make_variable_declarations_final=false
-sp_cleanup.never_use_blocks=false
-sp_cleanup.never_use_parentheses_in_expressions=true
-sp_cleanup.on_save_use_additional_actions=true
-sp_cleanup.organize_imports=false
-sp_cleanup.qualify_static_field_accesses_with_declaring_class=false
-sp_cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=true
-sp_cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=true
-sp_cleanup.qualify_static_member_accesses_with_declaring_class=false
-sp_cleanup.qualify_static_method_accesses_with_declaring_class=false
-sp_cleanup.remove_private_constructors=true
-sp_cleanup.remove_trailing_whitespaces=true
-sp_cleanup.remove_trailing_whitespaces_all=true
-sp_cleanup.remove_trailing_whitespaces_ignore_empty=false
-sp_cleanup.remove_unnecessary_casts=false
-sp_cleanup.remove_unnecessary_nls_tags=false
-sp_cleanup.remove_unused_imports=false
-sp_cleanup.remove_unused_local_variables=false
-sp_cleanup.remove_unused_private_fields=true
-sp_cleanup.remove_unused_private_members=false
-sp_cleanup.remove_unused_private_methods=true
-sp_cleanup.remove_unused_private_types=true
-sp_cleanup.sort_members=false
-sp_cleanup.sort_members_all=false
-sp_cleanup.use_blocks=true
-sp_cleanup.use_blocks_only_for_return_and_throw=false
-sp_cleanup.use_parentheses_in_expressions=false
-sp_cleanup.use_this_for_non_static_field_access=false
-sp_cleanup.use_this_for_non_static_field_access_only_if_necessary=true
-sp_cleanup.use_this_for_non_static_method_access=false
-sp_cleanup.use_this_for_non_static_method_access_only_if_necessary=true
diff --git a/org.eclipse.tracecompass.lttng2.ust.ui.tests/.settings/org.eclipse.pde.api.tools.prefs b/org.eclipse.tracecompass.lttng2.ust.ui.tests/.settings/org.eclipse.pde.api.tools.prefs
deleted file mode 100644 (file)
index acc3abd..0000000
+++ /dev/null
@@ -1,97 +0,0 @@
-ANNOTATION_ELEMENT_TYPE_ADDED_METHOD_WITHOUT_DEFAULT_VALUE=Error
-ANNOTATION_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-ANNOTATION_ELEMENT_TYPE_REMOVED_FIELD=Error
-ANNOTATION_ELEMENT_TYPE_REMOVED_METHOD=Error
-ANNOTATION_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_API_TYPE=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_API_TYPE=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_TYPE=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_TYPE=Error
-API_USE_SCAN_FIELD_SEVERITY=Error
-API_USE_SCAN_METHOD_SEVERITY=Error
-API_USE_SCAN_TYPE_SEVERITY=Error
-CLASS_ELEMENT_TYPE_ADDED_METHOD=Error
-CLASS_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
-CLASS_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-CLASS_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
-CLASS_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-CLASS_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
-CLASS_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
-CLASS_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-CLASS_ELEMENT_TYPE_REMOVED_CONSTRUCTOR=Error
-CLASS_ELEMENT_TYPE_REMOVED_FIELD=Error
-CLASS_ELEMENT_TYPE_REMOVED_METHOD=Error
-CLASS_ELEMENT_TYPE_REMOVED_SUPERCLASS=Error
-CLASS_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-CLASS_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-CONSTRUCTOR_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-CONSTRUCTOR_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-CONSTRUCTOR_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
-CONSTRUCTOR_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-ENUM_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
-ENUM_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-ENUM_ELEMENT_TYPE_REMOVED_ENUM_CONSTANT=Error
-ENUM_ELEMENT_TYPE_REMOVED_FIELD=Error
-ENUM_ELEMENT_TYPE_REMOVED_METHOD=Error
-ENUM_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-FIELD_ELEMENT_TYPE_ADDED_VALUE=Error
-FIELD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-FIELD_ELEMENT_TYPE_CHANGED_FINAL_TO_NON_FINAL_STATIC_CONSTANT=Error
-FIELD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
-FIELD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
-FIELD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
-FIELD_ELEMENT_TYPE_CHANGED_TYPE=Error
-FIELD_ELEMENT_TYPE_CHANGED_VALUE=Error
-FIELD_ELEMENT_TYPE_REMOVED_TYPE_ARGUMENT=Error
-FIELD_ELEMENT_TYPE_REMOVED_VALUE=Error
-ILLEGAL_EXTEND=Warning
-ILLEGAL_IMPLEMENT=Warning
-ILLEGAL_INSTANTIATE=Warning
-ILLEGAL_OVERRIDE=Warning
-ILLEGAL_REFERENCE=Warning
-INTERFACE_ELEMENT_TYPE_ADDED_FIELD=Error
-INTERFACE_ELEMENT_TYPE_ADDED_METHOD=Error
-INTERFACE_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
-INTERFACE_ELEMENT_TYPE_ADDED_SUPER_INTERFACE_WITH_METHODS=Error
-INTERFACE_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-INTERFACE_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
-INTERFACE_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_FIELD=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_METHOD=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-INVALID_JAVADOC_TAG=Warning
-INVALID_REFERENCE_IN_SYSTEM_LIBRARIES=Warning
-LEAK_EXTEND=Warning
-LEAK_FIELD_DECL=Warning
-LEAK_IMPLEMENT=Warning
-LEAK_METHOD_PARAM=Warning
-LEAK_METHOD_RETURN_TYPE=Warning
-METHOD_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
-METHOD_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-METHOD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-METHOD_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
-METHOD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
-METHOD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
-METHOD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
-METHOD_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
-METHOD_ELEMENT_TYPE_REMOVED_ANNOTATION_DEFAULT_VALUE=Error
-METHOD_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-MISSING_EE_DESCRIPTIONS=Ignore
-TYPE_PARAMETER_ELEMENT_TYPE_ADDED_CLASS_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_ADDED_INTERFACE_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_CLASS_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_INTERFACE_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_CLASS_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_INTERFACE_BOUND=Error
-UNUSED_PROBLEM_FILTERS=Warning
-automatically_removed_unused_problem_filters=false
-eclipse.preferences.version=1
-incompatible_api_component_version=Error
-incompatible_api_component_version_include_major_without_breaking_change=Disabled
-incompatible_api_component_version_include_minor_without_api_change=Disabled
-invalid_since_tag_version=Error
-malformed_since_tag=Error
-missing_since_tag=Error
-report_api_breakage_when_major_version_incremented=Disabled
-report_resolution_errors_api_component=Warning
diff --git a/org.eclipse.tracecompass.lttng2.ust.ui.tests/.settings/org.eclipse.pde.prefs b/org.eclipse.tracecompass.lttng2.ust.ui.tests/.settings/org.eclipse.pde.prefs
deleted file mode 100644 (file)
index 62cfa90..0000000
+++ /dev/null
@@ -1,32 +0,0 @@
-compilers.f.unresolved-features=1
-compilers.f.unresolved-plugins=1
-compilers.incompatible-environment=1
-compilers.p.build=1
-compilers.p.build.bin.includes=1
-compilers.p.build.encodings=2
-compilers.p.build.java.compiler=2
-compilers.p.build.java.compliance=1
-compilers.p.build.missing.output=2
-compilers.p.build.output.library=1
-compilers.p.build.source.library=1
-compilers.p.build.src.includes=1
-compilers.p.deprecated=1
-compilers.p.discouraged-class=1
-compilers.p.internal=1
-compilers.p.missing-packages=2
-compilers.p.missing-version-export-package=2
-compilers.p.missing-version-import-package=2
-compilers.p.missing-version-require-bundle=2
-compilers.p.no-required-att=0
-compilers.p.not-externalized-att=2
-compilers.p.unknown-attribute=1
-compilers.p.unknown-class=1
-compilers.p.unknown-element=1
-compilers.p.unknown-identifier=1
-compilers.p.unknown-resource=1
-compilers.p.unresolved-ex-points=0
-compilers.p.unresolved-import=0
-compilers.s.create-docs=false
-compilers.s.doc-folder=doc
-compilers.s.open-tags=1
-eclipse.preferences.version=1
diff --git a/org.eclipse.tracecompass.lttng2.ust.ui.tests/META-INF/MANIFEST.MF b/org.eclipse.tracecompass.lttng2.ust.ui.tests/META-INF/MANIFEST.MF
deleted file mode 100644 (file)
index f107679..0000000
+++ /dev/null
@@ -1,15 +0,0 @@
-Manifest-Version: 1.0
-Bundle-ManifestVersion: 2
-Bundle-Name: %Bundle-Name
-Bundle-Vendor: %Bundle-Vendor
-Bundle-Version: 1.0.0.qualifier
-Bundle-Localization: plugin
-Bundle-SymbolicName: org.eclipse.tracecompass.lttng2.ust.ui.tests;singleton:=true
-Bundle-ActivationPolicy: lazy
-Bundle-RequiredExecutionEnvironment: JavaSE-1.7
-Require-Bundle: org.junit;bundle-version="4.0.0",
- org.eclipse.ui,
- org.eclipse.core.resources,
- org.eclipse.core.runtime,
- org.eclipse.tracecompass.lttng2.ust.ui
-Export-Package: org.eclipse.tracecompass.lttng2.ust.ui.tests
diff --git a/org.eclipse.tracecompass.lttng2.ust.ui.tests/about.html b/org.eclipse.tracecompass.lttng2.ust.ui.tests/about.html
deleted file mode 100644 (file)
index c258ef5..0000000
+++ /dev/null
@@ -1,28 +0,0 @@
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
-    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml">
-<head>
-<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"/>
-<title>About</title>
-</head>
-<body lang="EN-US">
-<h2>About This Content</h2>
-<p>June 5, 2006</p>    
-<h3>License</h3>
-
-<p>The Eclipse Foundation makes available all content in this plug-in (&quot;Content&quot;).  Unless otherwise 
-indicated below, the Content is provided to you under the terms and conditions of the
-Eclipse Public License Version 1.0 (&quot;EPL&quot;).  A copy of the EPL is available 
-at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>.
-For purposes of the EPL, &quot;Program&quot; will mean the Content.</p>
-
-<p>If you did not receive this Content directly from the Eclipse Foundation, the Content is 
-being redistributed by another party (&quot;Redistributor&quot;) and different terms and conditions may
-apply to your use of any object code in the Content.  Check the Redistributor's license that was 
-provided with the Content.  If no such license exists, contact the Redistributor.  Unless otherwise
-indicated below, the terms and conditions of the EPL still apply to any source code in the Content
-and such source code may be obtained at <a href="http://www.eclipse.org/">http://www.eclipse.org</a>.</p>
-
-</body>
-</html>
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.ust.ui.tests/build.properties b/org.eclipse.tracecompass.lttng2.ust.ui.tests/build.properties
deleted file mode 100644 (file)
index 978a8de..0000000
+++ /dev/null
@@ -1,19 +0,0 @@
-###############################################################################
-# Copyright (c) 2013, 2015 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:
-#     Ericsson - Initial API and implementation
-###############################################################################
-
-source.. = src/
-output.. = bin/
-bin.includes = META-INF/,\
-               .,\
-               plugin.properties,\
-               about.html
-src.includes = about.html
diff --git a/org.eclipse.tracecompass.lttng2.ust.ui.tests/plugin.properties b/org.eclipse.tracecompass.lttng2.ust.ui.tests/plugin.properties
deleted file mode 100644 (file)
index bd43942..0000000
+++ /dev/null
@@ -1,14 +0,0 @@
-###############################################################################
-# Copyright (c) 2013, 2014 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:
-#     Ericsson - Initial API and implementation
-###############################################################################
-
-Bundle-Vendor = Eclipse Trace Compass
-Bundle-Name = Trace Compass LTTng Userspace Tracer Analysis UI Tests Plug-in
diff --git a/org.eclipse.tracecompass.lttng2.ust.ui.tests/pom.xml b/org.eclipse.tracecompass.lttng2.ust.ui.tests/pom.xml
deleted file mode 100644 (file)
index 3c82107..0000000
+++ /dev/null
@@ -1,45 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-   Copyright (C) 2011, 2013 Red Hat Inc., 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
--->
-<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>
-    <artifactId>org.eclipse.tracecompass</artifactId>
-    <groupId>org.eclipse.tracecompass</groupId>
-    <version>1.0.0-SNAPSHOT</version>
-  </parent>
-
-  <artifactId>org.eclipse.tracecompass.lttng2.ust.ui.tests</artifactId>
-  <version>1.0.0-SNAPSHOT</version>
-  <packaging>eclipse-test-plugin</packaging>
-
-  <name>Trace Compass LTTng Userspace Tracer Analysis UI Tests Plug-in</name>
-
-  <build>
-    <plugins>
-      <plugin>
-        <groupId>org.eclipse.tycho</groupId>
-        <artifactId>tycho-surefire-plugin</artifactId>
-        <version>${tycho-version}</version>
-        <configuration>
-          <testSuite>org.eclipse.tracecompass.lttng2.ust.ui.tests</testSuite>
-          <testClass>org.eclipse.tracecompass.lttng2.ust.ui.tests.AllTests</testClass>
-          <useUIHarness>true</useUIHarness>
-          <useUIThread>true</useUIThread>
-          <argLine>${tycho.testArgLine} ${base.ui.test.vmargs}</argLine>
-          <product>org.eclipse.platform.ide</product>
-        </configuration>
-      </plugin>
-    </plugins>
-  </build>
-
-  <groupId>org.eclipse.tracecompass</groupId>
-</project>
diff --git a/org.eclipse.tracecompass.lttng2.ust.ui.tests/src/org/eclipse/tracecompass/lttng2/ust/ui/tests/ActivatorTest.java b/org.eclipse.tracecompass.lttng2.ust.ui.tests/src/org/eclipse/tracecompass/lttng2/ust/ui/tests/ActivatorTest.java
deleted file mode 100644 (file)
index eb6eba1..0000000
+++ /dev/null
@@ -1,60 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2013, 2014 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:
- *   Alexandre Montplaisir - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.ust.ui.tests;
-
-import static org.junit.Assert.assertTrue;
-
-import org.junit.Test;
-
-/**
- * Test suite for the Activator class
- */
-public class ActivatorTest {
-
-    // ------------------------------------------------------------------------
-    // Tests
-    // ------------------------------------------------------------------------
-
-    /**
-     * Test method for {@link org.eclipse.tracecompass.internal.lttng2.ust.ui.Activator#Activator()}.
-     */
-    @Test
-    public void testActivator() {
-        assertTrue(true);
-    }
-
-    /**
-     * Test method for {@link org.eclipse.tracecompass.internal.lttng2.ust.ui.Activator#getDefault()}.
-     */
-    @Test
-    public void testGetDefault() {
-        assertTrue(true);
-    }
-
-    /**
-     * Test method for {@link org.eclipse.tracecompass.internal.lttng2.ust.ui.Activator#start}.
-     */
-    @Test
-    public void testStartBundleContext() {
-        assertTrue(true);
-    }
-
-    /**
-     * Test method for {@link org.eclipse.tracecompass.internal.lttng2.ust.ui.Activator#stop}.
-     */
-    @Test
-    public void testStopBundleContext() {
-        assertTrue(true);
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.ust.ui.tests/src/org/eclipse/tracecompass/lttng2/ust/ui/tests/AllTests.java b/org.eclipse.tracecompass.lttng2.ust.ui.tests/src/org/eclipse/tracecompass/lttng2/ust/ui/tests/AllTests.java
deleted file mode 100644 (file)
index 11575ec..0000000
+++ /dev/null
@@ -1,27 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2013, 2014 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:
- *   Alexandre Montplaisir - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.ust.ui.tests;
-
-import org.junit.runner.RunWith;
-import org.junit.runners.Suite;
-
-/**
- * Run the lttng2.ust.ui unit tests.
- */
-@RunWith(Suite.class)
-@Suite.SuiteClasses({
-    ActivatorTest.class,
-})
-public class AllTests {
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.ust.ui/.classpath b/org.eclipse.tracecompass.lttng2.ust.ui/.classpath
deleted file mode 100644 (file)
index 098194c..0000000
+++ /dev/null
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
-       <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7"/>
-       <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
-       <classpathentry kind="src" path="src"/>
-       <classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/org.eclipse.tracecompass.lttng2.ust.ui/.project b/org.eclipse.tracecompass.lttng2.ust.ui/.project
deleted file mode 100644 (file)
index 9dc8aa4..0000000
+++ /dev/null
@@ -1,34 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
-       <name>org.eclipse.tracecompass.lttng2.ust.ui</name>
-       <comment></comment>
-       <projects>
-       </projects>
-       <buildSpec>
-               <buildCommand>
-                       <name>org.eclipse.jdt.core.javabuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-               <buildCommand>
-                       <name>org.eclipse.pde.ManifestBuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-               <buildCommand>
-                       <name>org.eclipse.pde.SchemaBuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-               <buildCommand>
-                       <name>org.eclipse.pde.api.tools.apiAnalysisBuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-       </buildSpec>
-       <natures>
-               <nature>org.eclipse.pde.PluginNature</nature>
-               <nature>org.eclipse.jdt.core.javanature</nature>
-               <nature>org.eclipse.pde.api.tools.apiAnalysisNature</nature>
-       </natures>
-</projectDescription>
diff --git a/org.eclipse.tracecompass.lttng2.ust.ui/.settings/org.eclipse.core.resources.prefs b/org.eclipse.tracecompass.lttng2.ust.ui/.settings/org.eclipse.core.resources.prefs
deleted file mode 100644 (file)
index 99f26c0..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-eclipse.preferences.version=1
-encoding/<project>=UTF-8
diff --git a/org.eclipse.tracecompass.lttng2.ust.ui/.settings/org.eclipse.core.runtime.prefs b/org.eclipse.tracecompass.lttng2.ust.ui/.settings/org.eclipse.core.runtime.prefs
deleted file mode 100644 (file)
index 5a0ad22..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-eclipse.preferences.version=1
-line.separator=\n
diff --git a/org.eclipse.tracecompass.lttng2.ust.ui/.settings/org.eclipse.jdt.core.prefs b/org.eclipse.tracecompass.lttng2.ust.ui/.settings/org.eclipse.jdt.core.prefs
deleted file mode 100644 (file)
index a2b5e6b..0000000
+++ /dev/null
@@ -1,405 +0,0 @@
-eclipse.preferences.version=1
-org.eclipse.jdt.core.codeComplete.argumentPrefixes=
-org.eclipse.jdt.core.codeComplete.argumentSuffixes=
-org.eclipse.jdt.core.codeComplete.fieldPrefixes=f
-org.eclipse.jdt.core.codeComplete.fieldSuffixes=
-org.eclipse.jdt.core.codeComplete.localPrefixes=
-org.eclipse.jdt.core.codeComplete.localSuffixes=
-org.eclipse.jdt.core.codeComplete.staticFieldPrefixes=
-org.eclipse.jdt.core.codeComplete.staticFieldSuffixes=
-org.eclipse.jdt.core.codeComplete.staticFinalFieldPrefixes=
-org.eclipse.jdt.core.codeComplete.staticFinalFieldSuffixes=
-org.eclipse.jdt.core.compiler.annotation.inheritNullAnnotations=enabled
-org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore
-org.eclipse.jdt.core.compiler.annotation.nonnull=org.eclipse.jdt.annotation.NonNull
-org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=org.eclipse.jdt.annotation.NonNullByDefault
-org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nullable
-org.eclipse.jdt.core.compiler.annotation.nullanalysis=enabled
-org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
-org.eclipse.jdt.core.compiler.codegen.methodParameters=do not generate
-org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
-org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
-org.eclipse.jdt.core.compiler.compliance=1.7
-org.eclipse.jdt.core.compiler.debug.lineNumber=generate
-org.eclipse.jdt.core.compiler.debug.localVariable=generate
-org.eclipse.jdt.core.compiler.debug.sourceFile=generate
-org.eclipse.jdt.core.compiler.doc.comment.support=enabled
-org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=error
-org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
-org.eclipse.jdt.core.compiler.problem.autoboxing=ignore
-org.eclipse.jdt.core.compiler.problem.comparingIdentical=error
-org.eclipse.jdt.core.compiler.problem.deadCode=error
-org.eclipse.jdt.core.compiler.problem.deprecation=error
-org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled
-org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=enabled
-org.eclipse.jdt.core.compiler.problem.discouragedReference=warning
-org.eclipse.jdt.core.compiler.problem.emptyStatement=error
-org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
-org.eclipse.jdt.core.compiler.problem.explicitlyClosedAutoCloseable=error
-org.eclipse.jdt.core.compiler.problem.fallthroughCase=error
-org.eclipse.jdt.core.compiler.problem.fatalOptionalError=disabled
-org.eclipse.jdt.core.compiler.problem.fieldHiding=error
-org.eclipse.jdt.core.compiler.problem.finalParameterBound=error
-org.eclipse.jdt.core.compiler.problem.finallyBlockNotCompletingNormally=error
-org.eclipse.jdt.core.compiler.problem.forbiddenReference=error
-org.eclipse.jdt.core.compiler.problem.hiddenCatchBlock=error
-org.eclipse.jdt.core.compiler.problem.includeNullInfoFromAsserts=disabled
-org.eclipse.jdt.core.compiler.problem.incompatibleNonInheritedInterfaceMethod=error
-org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch=error
-org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=error
-org.eclipse.jdt.core.compiler.problem.invalidJavadoc=warning
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTags=enabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsDeprecatedRef=enabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsNotVisibleRef=enabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsVisibility=protected
-org.eclipse.jdt.core.compiler.problem.localVariableHiding=error
-org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=error
-org.eclipse.jdt.core.compiler.problem.missingDefaultCase=error
-org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=error
-org.eclipse.jdt.core.compiler.problem.missingEnumCaseDespiteDefault=enabled
-org.eclipse.jdt.core.compiler.problem.missingHashCodeMethod=error
-org.eclipse.jdt.core.compiler.problem.missingJavadocComments=warning
-org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsOverriding=disabled
-org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsVisibility=protected
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagDescription=all_standard_tags
-org.eclipse.jdt.core.compiler.problem.missingJavadocTags=warning
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagsMethodTypeParameters=disabled
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagsOverriding=disabled
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagsVisibility=protected
-org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotation=error
-org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotationForInterfaceMethodImplementation=enabled
-org.eclipse.jdt.core.compiler.problem.missingSerialVersion=error
-org.eclipse.jdt.core.compiler.problem.missingSynchronizedOnInheritedMethod=error
-org.eclipse.jdt.core.compiler.problem.noEffectAssignment=error
-org.eclipse.jdt.core.compiler.problem.noImplicitStringConversion=error
-org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=warning
-org.eclipse.jdt.core.compiler.problem.nonnullParameterAnnotationDropped=warning
-org.eclipse.jdt.core.compiler.problem.nullAnnotationInferenceConflict=warning
-org.eclipse.jdt.core.compiler.problem.nullReference=error
-org.eclipse.jdt.core.compiler.problem.nullSpecViolation=error
-org.eclipse.jdt.core.compiler.problem.nullUncheckedConversion=warning
-org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=error
-org.eclipse.jdt.core.compiler.problem.parameterAssignment=error
-org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=error
-org.eclipse.jdt.core.compiler.problem.potentialNullReference=error
-org.eclipse.jdt.core.compiler.problem.potentiallyUnclosedCloseable=warning
-org.eclipse.jdt.core.compiler.problem.rawTypeReference=warning
-org.eclipse.jdt.core.compiler.problem.redundantNullAnnotation=warning
-org.eclipse.jdt.core.compiler.problem.redundantNullCheck=error
-org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=error
-org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=error
-org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore
-org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=error
-org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled
-org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=error
-org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=disabled
-org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled
-org.eclipse.jdt.core.compiler.problem.syntacticNullAnalysisForFields=enabled
-org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=ignore
-org.eclipse.jdt.core.compiler.problem.typeParameterHiding=error
-org.eclipse.jdt.core.compiler.problem.unavoidableGenericTypeProblems=disabled
-org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=warning
-org.eclipse.jdt.core.compiler.problem.unclosedCloseable=error
-org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=ignore
-org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=error
-org.eclipse.jdt.core.compiler.problem.unnecessaryElse=error
-org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=error
-org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=warning
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionExemptExceptionAndThrowable=disabled
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionIncludeDocCommentReference=disabled
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverriding=disabled
-org.eclipse.jdt.core.compiler.problem.unusedExceptionParameter=ignore
-org.eclipse.jdt.core.compiler.problem.unusedImport=error
-org.eclipse.jdt.core.compiler.problem.unusedLabel=error
-org.eclipse.jdt.core.compiler.problem.unusedLocal=error
-org.eclipse.jdt.core.compiler.problem.unusedObjectAllocation=ignore
-org.eclipse.jdt.core.compiler.problem.unusedParameter=error
-org.eclipse.jdt.core.compiler.problem.unusedParameterIncludeDocCommentReference=enabled
-org.eclipse.jdt.core.compiler.problem.unusedParameterWhenImplementingAbstract=disabled
-org.eclipse.jdt.core.compiler.problem.unusedParameterWhenOverridingConcrete=disabled
-org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=error
-org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=error
-org.eclipse.jdt.core.compiler.problem.unusedWarningToken=error
-org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=error
-org.eclipse.jdt.core.compiler.source=1.7
-org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation=0
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_call=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression=16
-org.eclipse.jdt.core.formatter.alignment_for_assignment=0
-org.eclipse.jdt.core.formatter.alignment_for_binary_expression=16
-org.eclipse.jdt.core.formatter.alignment_for_compact_if=16
-org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=80
-org.eclipse.jdt.core.formatter.alignment_for_enum_constants=0
-org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=16
-org.eclipse.jdt.core.formatter.alignment_for_method_declaration=0
-org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16
-org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=80
-org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation=0
-org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_constructor_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_method_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_union_type_in_multicatch=16
-org.eclipse.jdt.core.formatter.blank_lines_after_imports=1
-org.eclipse.jdt.core.formatter.blank_lines_after_package=1
-org.eclipse.jdt.core.formatter.blank_lines_before_field=0
-org.eclipse.jdt.core.formatter.blank_lines_before_first_class_body_declaration=0
-org.eclipse.jdt.core.formatter.blank_lines_before_imports=1
-org.eclipse.jdt.core.formatter.blank_lines_before_member_type=1
-org.eclipse.jdt.core.formatter.blank_lines_before_method=1
-org.eclipse.jdt.core.formatter.blank_lines_before_new_chunk=1
-org.eclipse.jdt.core.formatter.blank_lines_before_package=0
-org.eclipse.jdt.core.formatter.blank_lines_between_import_groups=1
-org.eclipse.jdt.core.formatter.blank_lines_between_type_declarations=1
-org.eclipse.jdt.core.formatter.brace_position_for_annotation_type_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_array_initializer=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_block=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_block_in_case=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_constructor_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_enum_constant=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_enum_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_method_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_switch=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_type_declaration=end_of_line
-org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_block_comment=false
-org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_javadoc_comment=false
-org.eclipse.jdt.core.formatter.comment.format_block_comments=true
-org.eclipse.jdt.core.formatter.comment.format_header=false
-org.eclipse.jdt.core.formatter.comment.format_html=true
-org.eclipse.jdt.core.formatter.comment.format_javadoc_comments=true
-org.eclipse.jdt.core.formatter.comment.format_line_comments=true
-org.eclipse.jdt.core.formatter.comment.format_source_code=true
-org.eclipse.jdt.core.formatter.comment.indent_parameter_description=true
-org.eclipse.jdt.core.formatter.comment.indent_root_tags=true
-org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags=insert
-org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter=insert
-org.eclipse.jdt.core.formatter.comment.line_length=80
-org.eclipse.jdt.core.formatter.comment.new_lines_at_block_boundaries=true
-org.eclipse.jdt.core.formatter.comment.new_lines_at_javadoc_boundaries=true
-org.eclipse.jdt.core.formatter.comment.preserve_white_space_between_code_and_line_comments=false
-org.eclipse.jdt.core.formatter.compact_else_if=true
-org.eclipse.jdt.core.formatter.continuation_indentation=2
-org.eclipse.jdt.core.formatter.continuation_indentation_for_array_initializer=2
-org.eclipse.jdt.core.formatter.disabling_tag=@formatter\:off
-org.eclipse.jdt.core.formatter.enabling_tag=@formatter\:on
-org.eclipse.jdt.core.formatter.format_guardian_clause_on_one_line=false
-org.eclipse.jdt.core.formatter.format_line_comment_starting_on_first_column=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_annotation_declaration_header=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_constant_header=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_declaration_header=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_type_header=true
-org.eclipse.jdt.core.formatter.indent_breaks_compare_to_cases=true
-org.eclipse.jdt.core.formatter.indent_empty_lines=false
-org.eclipse.jdt.core.formatter.indent_statements_compare_to_block=true
-org.eclipse.jdt.core.formatter.indent_statements_compare_to_body=true
-org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_cases=true
-org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_switch=false
-org.eclipse.jdt.core.formatter.indentation.size=4
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_field=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_local_variable=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_method=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_package=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_parameter=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_type=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_label=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_opening_brace_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_at_end_of_file_if_missing=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_finally_in_try_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_while_in_do_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_annotation_declaration=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_anonymous_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_block=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter=insert
-org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_binary_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_paren_in_cast=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_assert=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_case=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_labeled_statement=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_allocation_expression=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_annotation=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_throws=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_constant_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_declarations=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_explicitconstructorcall_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_increments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_inits=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_throws=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_invocation_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_field_declarations=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_local_declarations=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_parameterized_type_reference=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_superinterfaces=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_ellipsis=insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_brace_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_cast=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_catch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_for=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_if=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_parenthesized_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_switch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_synchronized=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_try=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_while=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_try_resources=insert
-org.eclipse.jdt.core.formatter.insert_space_after_unary_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter=insert
-org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_binary_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_brace_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_cast=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_catch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_for=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_if=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_parenthesized_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_switch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_synchronized=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_try=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_while=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_assert=insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_case=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_default=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_labeled_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_throws=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_constant_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_declarations=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_explicitconstructorcall_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_increments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_inits=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_throws=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_invocation_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_field_declarations=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_local_declarations=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_superinterfaces=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_ellipsis=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_annotation_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_anonymous_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_block=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_constructor_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_constant=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_method_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_switch=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation_type_member_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_catch=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_if=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_parenthesized_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_switch=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_synchronized=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_try=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_while=insert
-org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_return=insert
-org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_throw=insert
-org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_semicolon=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_try_resources=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_unary_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_brackets_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_annotation_type_member_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.join_lines_in_comments=true
-org.eclipse.jdt.core.formatter.join_wrapped_lines=false
-org.eclipse.jdt.core.formatter.keep_else_statement_on_same_line=false
-org.eclipse.jdt.core.formatter.keep_empty_array_initializer_on_one_line=false
-org.eclipse.jdt.core.formatter.keep_imple_if_on_one_line=false
-org.eclipse.jdt.core.formatter.keep_then_statement_on_same_line=false
-org.eclipse.jdt.core.formatter.lineSplit=250
-org.eclipse.jdt.core.formatter.never_indent_block_comments_on_first_column=false
-org.eclipse.jdt.core.formatter.never_indent_line_comments_on_first_column=false
-org.eclipse.jdt.core.formatter.number_of_blank_lines_at_beginning_of_method_body=0
-org.eclipse.jdt.core.formatter.number_of_empty_lines_to_preserve=1
-org.eclipse.jdt.core.formatter.put_empty_statement_on_new_line=true
-org.eclipse.jdt.core.formatter.tabulation.char=space
-org.eclipse.jdt.core.formatter.tabulation.size=4
-org.eclipse.jdt.core.formatter.use_on_off_tags=false
-org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false
-org.eclipse.jdt.core.formatter.wrap_before_binary_operator=true
-org.eclipse.jdt.core.formatter.wrap_before_or_operator_multicatch=true
-org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true
diff --git a/org.eclipse.tracecompass.lttng2.ust.ui/.settings/org.eclipse.jdt.ui.prefs b/org.eclipse.tracecompass.lttng2.ust.ui/.settings/org.eclipse.jdt.ui.prefs
deleted file mode 100644 (file)
index 232a3fd..0000000
+++ /dev/null
@@ -1,60 +0,0 @@
-eclipse.preferences.version=1
-editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true
-formatter_profile=_tmf-style
-formatter_settings_version=12
-org.eclipse.jdt.ui.exception.name=e
-org.eclipse.jdt.ui.gettersetter.use.is=true
-org.eclipse.jdt.ui.keywordthis=false
-org.eclipse.jdt.ui.overrideannotation=true
-sp_cleanup.add_default_serial_version_id=true
-sp_cleanup.add_generated_serial_version_id=false
-sp_cleanup.add_missing_annotations=false
-sp_cleanup.add_missing_deprecated_annotations=true
-sp_cleanup.add_missing_methods=false
-sp_cleanup.add_missing_nls_tags=false
-sp_cleanup.add_missing_override_annotations=true
-sp_cleanup.add_missing_override_annotations_interface_methods=true
-sp_cleanup.add_serial_version_id=false
-sp_cleanup.always_use_blocks=true
-sp_cleanup.always_use_parentheses_in_expressions=false
-sp_cleanup.always_use_this_for_non_static_field_access=false
-sp_cleanup.always_use_this_for_non_static_method_access=false
-sp_cleanup.convert_to_enhanced_for_loop=false
-sp_cleanup.correct_indentation=false
-sp_cleanup.format_source_code=false
-sp_cleanup.format_source_code_changes_only=false
-sp_cleanup.make_local_variable_final=false
-sp_cleanup.make_parameters_final=false
-sp_cleanup.make_private_fields_final=true
-sp_cleanup.make_type_abstract_if_missing_method=false
-sp_cleanup.make_variable_declarations_final=false
-sp_cleanup.never_use_blocks=false
-sp_cleanup.never_use_parentheses_in_expressions=true
-sp_cleanup.on_save_use_additional_actions=true
-sp_cleanup.organize_imports=false
-sp_cleanup.qualify_static_field_accesses_with_declaring_class=false
-sp_cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=true
-sp_cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=true
-sp_cleanup.qualify_static_member_accesses_with_declaring_class=false
-sp_cleanup.qualify_static_method_accesses_with_declaring_class=false
-sp_cleanup.remove_private_constructors=true
-sp_cleanup.remove_trailing_whitespaces=true
-sp_cleanup.remove_trailing_whitespaces_all=true
-sp_cleanup.remove_trailing_whitespaces_ignore_empty=false
-sp_cleanup.remove_unnecessary_casts=false
-sp_cleanup.remove_unnecessary_nls_tags=false
-sp_cleanup.remove_unused_imports=false
-sp_cleanup.remove_unused_local_variables=false
-sp_cleanup.remove_unused_private_fields=true
-sp_cleanup.remove_unused_private_members=false
-sp_cleanup.remove_unused_private_methods=true
-sp_cleanup.remove_unused_private_types=true
-sp_cleanup.sort_members=false
-sp_cleanup.sort_members_all=false
-sp_cleanup.use_blocks=true
-sp_cleanup.use_blocks_only_for_return_and_throw=false
-sp_cleanup.use_parentheses_in_expressions=false
-sp_cleanup.use_this_for_non_static_field_access=false
-sp_cleanup.use_this_for_non_static_field_access_only_if_necessary=true
-sp_cleanup.use_this_for_non_static_method_access=false
-sp_cleanup.use_this_for_non_static_method_access_only_if_necessary=true
diff --git a/org.eclipse.tracecompass.lttng2.ust.ui/.settings/org.eclipse.pde.api.tools.prefs b/org.eclipse.tracecompass.lttng2.ust.ui/.settings/org.eclipse.pde.api.tools.prefs
deleted file mode 100644 (file)
index acc3abd..0000000
+++ /dev/null
@@ -1,97 +0,0 @@
-ANNOTATION_ELEMENT_TYPE_ADDED_METHOD_WITHOUT_DEFAULT_VALUE=Error
-ANNOTATION_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-ANNOTATION_ELEMENT_TYPE_REMOVED_FIELD=Error
-ANNOTATION_ELEMENT_TYPE_REMOVED_METHOD=Error
-ANNOTATION_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_API_TYPE=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_API_TYPE=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_TYPE=Error
-API_COMPONENT_ELEMENT_TYPE_REMOVED_TYPE=Error
-API_USE_SCAN_FIELD_SEVERITY=Error
-API_USE_SCAN_METHOD_SEVERITY=Error
-API_USE_SCAN_TYPE_SEVERITY=Error
-CLASS_ELEMENT_TYPE_ADDED_METHOD=Error
-CLASS_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
-CLASS_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-CLASS_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
-CLASS_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-CLASS_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
-CLASS_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
-CLASS_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-CLASS_ELEMENT_TYPE_REMOVED_CONSTRUCTOR=Error
-CLASS_ELEMENT_TYPE_REMOVED_FIELD=Error
-CLASS_ELEMENT_TYPE_REMOVED_METHOD=Error
-CLASS_ELEMENT_TYPE_REMOVED_SUPERCLASS=Error
-CLASS_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-CLASS_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-CONSTRUCTOR_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-CONSTRUCTOR_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-CONSTRUCTOR_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
-CONSTRUCTOR_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-ENUM_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
-ENUM_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-ENUM_ELEMENT_TYPE_REMOVED_ENUM_CONSTANT=Error
-ENUM_ELEMENT_TYPE_REMOVED_FIELD=Error
-ENUM_ELEMENT_TYPE_REMOVED_METHOD=Error
-ENUM_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-FIELD_ELEMENT_TYPE_ADDED_VALUE=Error
-FIELD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-FIELD_ELEMENT_TYPE_CHANGED_FINAL_TO_NON_FINAL_STATIC_CONSTANT=Error
-FIELD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
-FIELD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
-FIELD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
-FIELD_ELEMENT_TYPE_CHANGED_TYPE=Error
-FIELD_ELEMENT_TYPE_CHANGED_VALUE=Error
-FIELD_ELEMENT_TYPE_REMOVED_TYPE_ARGUMENT=Error
-FIELD_ELEMENT_TYPE_REMOVED_VALUE=Error
-ILLEGAL_EXTEND=Warning
-ILLEGAL_IMPLEMENT=Warning
-ILLEGAL_INSTANTIATE=Warning
-ILLEGAL_OVERRIDE=Warning
-ILLEGAL_REFERENCE=Warning
-INTERFACE_ELEMENT_TYPE_ADDED_FIELD=Error
-INTERFACE_ELEMENT_TYPE_ADDED_METHOD=Error
-INTERFACE_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
-INTERFACE_ELEMENT_TYPE_ADDED_SUPER_INTERFACE_WITH_METHODS=Error
-INTERFACE_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-INTERFACE_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error
-INTERFACE_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_FIELD=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_METHOD=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error
-INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-INVALID_JAVADOC_TAG=Warning
-INVALID_REFERENCE_IN_SYSTEM_LIBRARIES=Warning
-LEAK_EXTEND=Warning
-LEAK_FIELD_DECL=Warning
-LEAK_IMPLEMENT=Warning
-LEAK_METHOD_PARAM=Warning
-LEAK_METHOD_RETURN_TYPE=Warning
-METHOD_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error
-METHOD_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error
-METHOD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error
-METHOD_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error
-METHOD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error
-METHOD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error
-METHOD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error
-METHOD_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error
-METHOD_ELEMENT_TYPE_REMOVED_ANNOTATION_DEFAULT_VALUE=Error
-METHOD_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error
-MISSING_EE_DESCRIPTIONS=Ignore
-TYPE_PARAMETER_ELEMENT_TYPE_ADDED_CLASS_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_ADDED_INTERFACE_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_CLASS_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_INTERFACE_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_CLASS_BOUND=Error
-TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_INTERFACE_BOUND=Error
-UNUSED_PROBLEM_FILTERS=Warning
-automatically_removed_unused_problem_filters=false
-eclipse.preferences.version=1
-incompatible_api_component_version=Error
-incompatible_api_component_version_include_major_without_breaking_change=Disabled
-incompatible_api_component_version_include_minor_without_api_change=Disabled
-invalid_since_tag_version=Error
-malformed_since_tag=Error
-missing_since_tag=Error
-report_api_breakage_when_major_version_incremented=Disabled
-report_resolution_errors_api_component=Warning
diff --git a/org.eclipse.tracecompass.lttng2.ust.ui/.settings/org.eclipse.pde.prefs b/org.eclipse.tracecompass.lttng2.ust.ui/.settings/org.eclipse.pde.prefs
deleted file mode 100644 (file)
index d92b94f..0000000
+++ /dev/null
@@ -1,32 +0,0 @@
-compilers.f.unresolved-features=1
-compilers.f.unresolved-plugins=1
-compilers.incompatible-environment=1
-compilers.p.build=1
-compilers.p.build.bin.includes=1
-compilers.p.build.encodings=2
-compilers.p.build.java.compiler=2
-compilers.p.build.java.compliance=1
-compilers.p.build.missing.output=2
-compilers.p.build.output.library=1
-compilers.p.build.source.library=1
-compilers.p.build.src.includes=1
-compilers.p.deprecated=1
-compilers.p.discouraged-class=1
-compilers.p.internal=1
-compilers.p.missing-packages=1
-compilers.p.missing-version-export-package=2
-compilers.p.missing-version-import-package=2
-compilers.p.missing-version-require-bundle=2
-compilers.p.no-required-att=0
-compilers.p.not-externalized-att=1
-compilers.p.unknown-attribute=1
-compilers.p.unknown-class=1
-compilers.p.unknown-element=1
-compilers.p.unknown-identifier=1
-compilers.p.unknown-resource=1
-compilers.p.unresolved-ex-points=0
-compilers.p.unresolved-import=0
-compilers.s.create-docs=false
-compilers.s.doc-folder=doc
-compilers.s.open-tags=1
-eclipse.preferences.version=1
diff --git a/org.eclipse.tracecompass.lttng2.ust.ui/META-INF/MANIFEST.MF b/org.eclipse.tracecompass.lttng2.ust.ui/META-INF/MANIFEST.MF
deleted file mode 100644 (file)
index 5a12739..0000000
+++ /dev/null
@@ -1,21 +0,0 @@
-Manifest-Version: 1.0
-Bundle-ManifestVersion: 2
-Bundle-Name: %Bundle-Name
-Bundle-Vendor: %Bundle-Vendor
-Bundle-Version: 1.0.0.qualifier
-Bundle-Localization: plugin
-Bundle-SymbolicName: org.eclipse.tracecompass.lttng2.ust.ui;singleton:=true
-Bundle-Activator: org.eclipse.tracecompass.internal.lttng2.ust.ui.Activator
-Bundle-ActivationPolicy: lazy
-Bundle-RequiredExecutionEnvironment: JavaSE-1.7
-Require-Bundle: org.eclipse.core.resources,
- org.eclipse.core.runtime,
- org.eclipse.ui,
- org.eclipse.tracecompass.common.core,
- org.eclipse.tracecompass.lttng2.ust.core,
- org.eclipse.tracecompass.tmf.core,
- org.eclipse.tracecompass.tmf.ui,
- org.eclipse.tracecompass.tmf.ctf.core
-Export-Package: org.eclipse.tracecompass.internal.lttng2.ust.ui;x-friends:="org.eclipse.tracecompass.lttng2.ust.ui.tests",
- org.eclipse.tracecompass.internal.lttng2.ust.ui.views.memusage;x-friends:="org.eclipse.tracecompass.lttng2.ust.ui.tests",
- org.eclipse.tracecompass.lttng2.ust.ui.analysis.callstack
diff --git a/org.eclipse.tracecompass.lttng2.ust.ui/about.html b/org.eclipse.tracecompass.lttng2.ust.ui/about.html
deleted file mode 100644 (file)
index c258ef5..0000000
+++ /dev/null
@@ -1,28 +0,0 @@
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
-    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml">
-<head>
-<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"/>
-<title>About</title>
-</head>
-<body lang="EN-US">
-<h2>About This Content</h2>
-<p>June 5, 2006</p>    
-<h3>License</h3>
-
-<p>The Eclipse Foundation makes available all content in this plug-in (&quot;Content&quot;).  Unless otherwise 
-indicated below, the Content is provided to you under the terms and conditions of the
-Eclipse Public License Version 1.0 (&quot;EPL&quot;).  A copy of the EPL is available 
-at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>.
-For purposes of the EPL, &quot;Program&quot; will mean the Content.</p>
-
-<p>If you did not receive this Content directly from the Eclipse Foundation, the Content is 
-being redistributed by another party (&quot;Redistributor&quot;) and different terms and conditions may
-apply to your use of any object code in the Content.  Check the Redistributor's license that was 
-provided with the Content.  If no such license exists, contact the Redistributor.  Unless otherwise
-indicated below, the terms and conditions of the EPL still apply to any source code in the Content
-and such source code may be obtained at <a href="http://www.eclipse.org/">http://www.eclipse.org</a>.</p>
-
-</body>
-</html>
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.ust.ui/build.properties b/org.eclipse.tracecompass.lttng2.ust.ui/build.properties
deleted file mode 100644 (file)
index 1046daa..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-###############################################################################
-# Copyright (c) 2013, 2014 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:
-#     Ericsson - Initial API and implementation
-###############################################################################
-
-source.. = src/
-output.. = bin/
-bin.includes = META-INF/,\
-               icons/,\
-               .,\
-               plugin.xml,\
-               about.html,\
-               plugin.properties
-src.includes = about.html
-additional.bundles = org.eclipse.jdt.annotation
-jars.extra.classpath = platform:/plugin/org.eclipse.jdt.annotation
diff --git a/org.eclipse.tracecompass.lttng2.ust.ui/icons/obj16/garland16.png b/org.eclipse.tracecompass.lttng2.ust.ui/icons/obj16/garland16.png
deleted file mode 100644 (file)
index 74f9751..0000000
Binary files a/org.eclipse.tracecompass.lttng2.ust.ui/icons/obj16/garland16.png and /dev/null differ
diff --git a/org.eclipse.tracecompass.lttng2.ust.ui/plugin.properties b/org.eclipse.tracecompass.lttng2.ust.ui/plugin.properties
deleted file mode 100644 (file)
index 3884ade..0000000
+++ /dev/null
@@ -1,19 +0,0 @@
-###############################################################################
-# Copyright (c) 2013, 2014 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:
-#     Ericsson - Initial API and implementation
-###############################################################################
-
-Bundle-Vendor = Eclipse Trace Compass
-Bundle-Name = Trace Compass LTTng Userspace Tracer Analysis UI Plug-in
-
-tracetype.type.ust = LTTng UST Trace
-memoryusage.view.name = UST Memory Usage
-
-analysis.callstack = LTTng-UST CallStack Analysis
diff --git a/org.eclipse.tracecompass.lttng2.ust.ui/plugin.xml b/org.eclipse.tracecompass.lttng2.ust.ui/plugin.xml
deleted file mode 100644 (file)
index af716b7..0000000
+++ /dev/null
@@ -1,41 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<?eclipse version="3.4"?>
-<plugin>
-   <extension
-         point="org.eclipse.linuxtools.tmf.ui.tracetypeui">
-      <type
-            icon="icons/obj16/garland16.png"
-            tracetype="org.eclipse.linuxtools.lttng2.ust.tracetype">
-      </type>
-   </extension>
-   <extension
-         point="org.eclipse.ui.views">
-      <view
-            category="org.eclipse.linuxtools.lttng2.ui.views.category"
-            class="org.eclipse.tracecompass.internal.lttng2.ust.ui.views.memusage.MemoryUsageView"
-            id="org.eclipse.linuxtools.lttng2.ust.memoryusage"
-            name="%memoryusage.view.name"
-            restorable="true">
-      </view>
-   </extension>
-   <extension
-         point="org.eclipse.linuxtools.tmf.core.analysis">
-      <module
-            analysis_module="org.eclipse.tracecompass.lttng2.ust.ui.analysis.callstack.LttngUstCallStackAnalysis"
-            automatic="false"
-            id="org.eclipse.linuxtools.lttng2.ust.analysis.callstack"
-            name="%analysis.callstack">
-         <tracetype
-               applies="true"
-               class="org.eclipse.tracecompass.lttng2.ust.core.trace.LttngUstTrace">
-         </tracetype>
-      </module>
-      <output
-            class="org.eclipse.tracecompass.tmf.ui.analysis.TmfAnalysisViewOutput"
-            id="org.eclipse.linuxtools.lttng2.ust.memoryusage">
-         <analysisId
-               id="org.eclipse.linuxtools.lttng2.ust.analysis.memory">
-         </analysisId>
-      </output>
-   </extension>
-</plugin>
diff --git a/org.eclipse.tracecompass.lttng2.ust.ui/pom.xml b/org.eclipse.tracecompass.lttng2.ust.ui/pom.xml
deleted file mode 100644 (file)
index d3ab122..0000000
+++ /dev/null
@@ -1,36 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-   Copyright (C) 2011, 2013 Red Hat Inc., 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
--->
-<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>
-    <artifactId>org.eclipse.tracecompass</artifactId>
-    <groupId>org.eclipse.tracecompass</groupId>
-    <version>1.0.0-SNAPSHOT</version>
-  </parent>
-
-  <artifactId>org.eclipse.tracecompass.lttng2.ust.ui</artifactId>
-  <version>1.0.0-SNAPSHOT</version>
-  <packaging>eclipse-plugin</packaging>
-
-  <name>Trace Compass LTTng Userspace Tracer Analysis UI Plug-in</name>
-
- <build>
-    <plugins>
-      <plugin>
-        <groupId>org.eclipse.tycho</groupId>
-        <artifactId>tycho-source-plugin</artifactId>
-      </plugin>
-    </plugins>
-  </build>
-
-  <groupId>org.eclipse.tracecompass</groupId>
-</project>
diff --git a/org.eclipse.tracecompass.lttng2.ust.ui/src/org/eclipse/tracecompass/internal/lttng2/ust/ui/Activator.java b/org.eclipse.tracecompass.lttng2.ust.ui/src/org/eclipse/tracecompass/internal/lttng2/ust/ui/Activator.java
deleted file mode 100644 (file)
index ba48a04..0000000
+++ /dev/null
@@ -1,184 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2013, 2015 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:
- *   Alexandre Montplaisir - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.ust.ui;
-
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.jface.resource.ImageDescriptor;
-import org.eclipse.jface.resource.ImageRegistry;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.ui.plugin.AbstractUIPlugin;
-import org.osgi.framework.BundleContext;
-
-/**
- * The activator class controls the plug-in life cycle
- */
-public class Activator extends AbstractUIPlugin {
-
-    // ------------------------------------------------------------------------
-    // Attributes
-    // ------------------------------------------------------------------------
-
-    /**
-     *  The plug-in ID
-     */
-    public static final String PLUGIN_ID = "org.eclipse.tracecompass.lttng2.ust.ui"; //$NON-NLS-1$
-
-    /**
-     *  The shared instance
-     */
-    private static Activator plugin;
-
-    // ------------------------------------------------------------------------
-    // Constructors
-    // ------------------------------------------------------------------------
-
-    /**
-     * The constructor
-     */
-    public Activator() {
-    }
-
-    // ------------------------------------------------------------------------
-    // Accessors
-    // ------------------------------------------------------------------------
-
-    /**
-     * Returns the shared instance
-     *
-     * @return the shared instance
-     */
-    public static Activator getDefault() {
-        return plugin;
-    }
-
-    // ------------------------------------------------------------------------
-    // AbstractUIPlugin
-    // ------------------------------------------------------------------------
-
-    @Override
-    public void start(BundleContext context) throws Exception {
-        super.start(context);
-        plugin = this;
-    }
-
-    @Override
-    public void stop(BundleContext context) throws Exception {
-        plugin = null;
-        super.stop(context);
-    }
-
-    @Override
-    protected void initializeImageRegistry(ImageRegistry reg) {
-    }
-
-    // ------------------------------------------------------------------------
-    // Operations
-    // ------------------------------------------------------------------------
-
-    /**
-     * Get the image object from a given path
-     *
-     * @param path
-     *            The path to the image file
-     * @return The Image object
-     */
-    public Image getImageFromPath(String path) {
-        return getImageDescripterFromPath(path).createImage();
-    }
-
-    /**
-     * Get the ImageDescriptor from a given path
-     *
-     * @param path
-     *            The path to the image file
-     * @return The ImageDescriptor object
-     */
-    public ImageDescriptor getImageDescripterFromPath(String path) {
-        return AbstractUIPlugin.imageDescriptorFromPlugin(PLUGIN_ID, path);
-    }
-
-    /**
-     * Get the Image from a registry
-     *
-     * @param path
-     *            The path to the image registry
-     * @return The Image object
-     */
-    public Image getImageFromImageRegistry(String path) {
-        Image icon = getImageRegistry().get(path);
-        if (icon == null) {
-            icon = getImageDescripterFromPath(path).createImage();
-            plugin.getImageRegistry().put(path, icon);
-        }
-        return icon;
-    }
-
-    /**
-     * Logs a message with severity INFO in the runtime log of the plug-in.
-     *
-     * @param message A message to log
-     */
-    public void logInfo(String message) {
-        getLog().log(new Status(IStatus.INFO, PLUGIN_ID, message));
-    }
-
-    /**
-     * Logs a message and exception with severity INFO in the runtime log of the plug-in.
-     *
-     * @param message A message to log
-     * @param exception A exception to log
-     */
-    public void logInfo(String message, Throwable exception) {
-        getLog().log(new Status(IStatus.INFO, PLUGIN_ID, message, exception));
-    }
-
-    /**
-     * Logs a message and exception with severity WARNING in the runtime log of the plug-in.
-     *
-     * @param message A message to log
-     */
-    public void logWarning(String message) {
-        getLog().log(new Status(IStatus.WARNING, PLUGIN_ID, message));
-    }
-
-    /**
-     * Logs a message and exception with severity WARNING in the runtime log of the plug-in.
-     *
-     * @param message A message to log
-     * @param exception A exception to log
-     */
-    public void logWarning(String message, Throwable exception) {
-        getLog().log(new Status(IStatus.WARNING, PLUGIN_ID, message, exception));
-    }
-
-    /**
-     * Logs a message and exception with severity ERROR in the runtime log of the plug-in.
-     *
-     * @param message A message to log
-     */
-    public void logError(String message) {
-        getLog().log(new Status(IStatus.ERROR, PLUGIN_ID, message));
-    }
-
-    /**
-     * Logs a message and exception with severity ERROR in the runtime log of the plug-in.
-     *
-     * @param message A message to log
-     * @param exception A exception to log
-     */
-    public void logError(String message, Throwable exception) {
-        getLog().log(new Status(IStatus.ERROR, PLUGIN_ID, message, exception));
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.ust.ui/src/org/eclipse/tracecompass/internal/lttng2/ust/ui/views/memusage/MemoryUsageView.java b/org.eclipse.tracecompass.lttng2.ust.ui/src/org/eclipse/tracecompass/internal/lttng2/ust/ui/views/memusage/MemoryUsageView.java
deleted file mode 100644 (file)
index 5f52380..0000000
+++ /dev/null
@@ -1,40 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014, 2015 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:
- *   Matthew Khouzam - Initial API and implementation
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.ust.ui.views.memusage;
-
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.tracecompass.tmf.ui.viewers.xycharts.TmfXYChartViewer;
-import org.eclipse.tracecompass.tmf.ui.views.TmfChartView;
-
-/**
- * Memory Usage View
- *
- * @author Matthew Khouzam
- */
-public class MemoryUsageView extends TmfChartView {
-
-    /** ID string */
-    public static final String ID = "org.eclipse.linuxtools.lttng2.ust.memoryusage"; //$NON-NLS-1$
-
-    /**
-     * Constructor
-     */
-    public MemoryUsageView() {
-        super(Messages.MemoryUsageView_Title);
-    }
-
-    @Override
-    protected TmfXYChartViewer createChartViewer(Composite parent) {
-        return new MemoryUsageViewer(parent);
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.ust.ui/src/org/eclipse/tracecompass/internal/lttng2/ust/ui/views/memusage/MemoryUsageViewer.java b/org.eclipse.tracecompass.lttng2.ust.ui/src/org/eclipse/tracecompass/internal/lttng2/ust/ui/views/memusage/MemoryUsageViewer.java
deleted file mode 100644 (file)
index a1694bb..0000000
+++ /dev/null
@@ -1,163 +0,0 @@
-/**********************************************************************
- * Copyright (c) 2014 Ericsson, École Polytechnique de Montréal
- *
- * 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:
- *   Bernd Hufmann - Initial API and implementation
- *   Geneviève Bastien - Create and use base class for XY plots
- **********************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.ust.ui.views.memusage;
-
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.tracecompass.internal.lttng2.ust.core.analysis.memory.UstMemoryStrings;
-import org.eclipse.tracecompass.internal.tmf.core.Activator;
-import org.eclipse.tracecompass.lttng2.ust.core.analysis.memory.UstMemoryAnalysisModule;
-import org.eclipse.tracecompass.statesystem.core.ITmfStateSystem;
-import org.eclipse.tracecompass.statesystem.core.exceptions.AttributeNotFoundException;
-import org.eclipse.tracecompass.statesystem.core.exceptions.StateSystemDisposedException;
-import org.eclipse.tracecompass.statesystem.core.exceptions.StateValueTypeException;
-import org.eclipse.tracecompass.statesystem.core.exceptions.TimeRangeException;
-import org.eclipse.tracecompass.statesystem.core.statevalue.ITmfStateValue;
-import org.eclipse.tracecompass.tmf.core.statesystem.TmfStateSystemAnalysisModule;
-import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace;
-import org.eclipse.tracecompass.tmf.core.trace.TmfTraceUtils;
-import org.eclipse.tracecompass.tmf.ui.viewers.xycharts.linecharts.TmfCommonXLineChartViewer;
-
-/**
- * Memory usage view
- *
- * @author Matthew Khouzam
- */
-@SuppressWarnings("restriction")
-public class MemoryUsageViewer extends TmfCommonXLineChartViewer {
-
-    private TmfStateSystemAnalysisModule fModule = null;
-
-    private final Map<Integer, double[]> fYValues = new HashMap<>();
-    private final Map<Integer, Integer> fMemoryQuarks = new HashMap<>();
-    private final Map<Integer, String> fSeriesName = new HashMap<>();
-
-    private static final int BYTES_TO_KB = 1024;
-
-    // Timeout between updates in the updateData thread
-    private static final long BUILD_UPDATE_TIMEOUT = 500;
-
-    /**
-     * Constructor
-     *
-     * @param parent
-     *            parent view
-     */
-    public MemoryUsageViewer(Composite parent) {
-        super(parent, Messages.MemoryUsageViewer_Title, Messages.MemoryUsageViewer_XAxis, Messages.MemoryUsageViewer_YAxis);
-    }
-
-    @Override
-    protected void initializeDataSource() {
-        ITmfTrace trace = getTrace();
-        if (trace != null) {
-            fModule = TmfTraceUtils.getAnalysisModuleOfClass(trace, TmfStateSystemAnalysisModule.class, UstMemoryAnalysisModule.ID);
-            if (fModule == null) {
-                return;
-            }
-            fModule.schedule();
-        }
-    }
-
-    @Override
-    protected void updateData(long start, long end, int nb, IProgressMonitor monitor) {
-        try {
-            if (getTrace() == null || fModule == null) {
-                return;
-            }
-            fModule.waitForInitialization();
-            ITmfStateSystem ss = fModule.getStateSystem();
-            /* Don't wait for the module completion, when it's ready, we'll know */
-            if (ss == null) {
-                return;
-            }
-
-            double[] xvalues = getXAxis(start, end, nb);
-            setXAxis(xvalues);
-
-            boolean complete = false;
-            long currentEnd = start;
-
-            while (!complete && currentEnd < end) {
-                if (monitor.isCanceled()) {
-                    return;
-                }
-                complete = ss.waitUntilBuilt(BUILD_UPDATE_TIMEOUT);
-                currentEnd = ss.getCurrentEndTime();
-                List<Integer> tidQuarks = ss.getSubAttributes(-1, false);
-                long traceStart = getStartTime();
-                long traceEnd = getEndTime();
-                long offset = this.getTimeOffset();
-
-                /* Initialize quarks and series names */
-                for (int quark : tidQuarks) {
-                    fYValues.put(quark, new double[xvalues.length]);
-                    fMemoryQuarks.put(quark, ss.getQuarkRelative(quark, UstMemoryStrings.UST_MEMORY_MEMORY_ATTRIBUTE));
-                    int procNameQuark = ss.getQuarkRelative(quark, UstMemoryStrings.UST_MEMORY_PROCNAME_ATTRIBUTE);
-                    try {
-                        ITmfStateValue procnameValue = ss.querySingleState(start, procNameQuark).getStateValue();
-                        String procname = ""; //$NON-NLS-1$
-                        if (!procnameValue.isNull()) {
-                            procname = procnameValue.unboxStr();
-                        }
-                        fSeriesName.put(quark, new String(procname + ' ' + '(' + ss.getAttributeName(quark) + ')').trim());
-                    } catch (TimeRangeException e) {
-                        fSeriesName.put(quark, '(' + ss.getAttributeName(quark) + ')');
-                    }
-                }
-
-                /*
-                 * TODO: It should only show active threads in the time range.
-                 * If a tid does not have any memory value (only 1 interval in
-                 * the time range with value null or 0), then its series should
-                 * not be displayed.
-                 */
-                double yvalue = 0.0;
-                for (int i = 0; i < xvalues.length; i++) {
-                    if (monitor.isCanceled()) {
-                        return;
-                    }
-                    double x = xvalues[i];
-                    long time = (long) x + offset;
-                    // make sure that time is in the trace range after double to
-                    // long conversion
-                    time = time < traceStart ? traceStart : time;
-                    time = time > traceEnd ? traceEnd : time;
-
-                    for (int quark : tidQuarks) {
-                        try {
-                            yvalue = ss.querySingleState(time, fMemoryQuarks.get(quark)).getStateValue().unboxLong() / BYTES_TO_KB;
-                            fYValues.get(quark)[i] = yvalue;
-                        } catch (TimeRangeException e) {
-                            fYValues.get(quark)[i] = 0;
-                        }
-                    }
-                }
-                for (int quark : tidQuarks) {
-                    setSeries(fSeriesName.get(quark), fYValues.get(quark));
-                }
-                updateDisplay();
-            }
-        } catch (AttributeNotFoundException | StateValueTypeException e) {
-            Activator.logError("Error updating the data of the Memory usage view", e); //$NON-NLS-1$
-        } catch (StateSystemDisposedException e) {
-            /* State system is closing down, no point continuing */
-        }
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.ust.ui/src/org/eclipse/tracecompass/internal/lttng2/ust/ui/views/memusage/Messages.java b/org.eclipse.tracecompass.lttng2.ust.ui/src/org/eclipse/tracecompass/internal/lttng2/ust/ui/views/memusage/Messages.java
deleted file mode 100644 (file)
index 3e3c56d..0000000
+++ /dev/null
@@ -1,40 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2014 École Polytechnique de Montréal
- *
- * 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:
- *   Geneviève Bastien - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.internal.lttng2.ust.ui.views.memusage;
-
-import org.eclipse.osgi.util.NLS;
-
-/**
- * Translatable strings for the ust memory usage view
- *
- * @author Geneviève Bastien
- */
-public class Messages extends NLS {
-    private static final String BUNDLE_NAME = "org.eclipse.tracecompass.internal.lttng2.ust.ui.views.memusage.messages"; //$NON-NLS-1$
-    /** Title of the memory usage xy view */
-    public static String MemoryUsageView_Title;
-
-    /** Title of the memory viewer */
-    public static String MemoryUsageViewer_Title;
-    /** X axis caption */
-    public static String MemoryUsageViewer_XAxis;
-    /** Y axis caption */
-    public static String MemoryUsageViewer_YAxis;
-    static {
-        // initialize resource bundle
-        NLS.initializeMessages(BUNDLE_NAME, Messages.class);
-    }
-
-    private Messages() {
-    }
-}
diff --git a/org.eclipse.tracecompass.lttng2.ust.ui/src/org/eclipse/tracecompass/internal/lttng2/ust/ui/views/memusage/messages.properties b/org.eclipse.tracecompass.lttng2.ust.ui/src/org/eclipse/tracecompass/internal/lttng2/ust/ui/views/memusage/messages.properties
deleted file mode 100644 (file)
index 2de2271..0000000
+++ /dev/null
@@ -1,15 +0,0 @@
-###############################################################################
-# Copyright (c) 2014 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:
-#    Ericsson - Initial API and implementation
-###############################################################################
-MemoryUsageView_Title=Memory Usage
-MemoryUsageViewer_Title=Memory Allocation vs Time
-MemoryUsageViewer_XAxis=Time
-MemoryUsageViewer_YAxis=Usage (KB)
diff --git a/org.eclipse.tracecompass.lttng2.ust.ui/src/org/eclipse/tracecompass/lttng2/ust/ui/analysis/callstack/LttngUstCallStackAnalysis.java b/org.eclipse.tracecompass.lttng2.ust.ui/src/org/eclipse/tracecompass/lttng2/ust/ui/analysis/callstack/LttngUstCallStackAnalysis.java
deleted file mode 100644 (file)
index 6078caa..0000000
+++ /dev/null
@@ -1,53 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2014, 2015 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:
- *   Alexandre Montplaisir - Initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tracecompass.lttng2.ust.ui.analysis.callstack;
-
-import static org.eclipse.tracecompass.common.core.NonNullUtils.checkNotNull;
-
-import org.eclipse.tracecompass.internal.lttng2.ust.core.callstack.LttngUstCallStackProvider;
-import org.eclipse.tracecompass.lttng2.ust.core.trace.LttngUstTrace;
-import org.eclipse.tracecompass.tmf.core.exceptions.TmfAnalysisException;
-import org.eclipse.tracecompass.tmf.core.statesystem.ITmfStateProvider;
-import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace;
-import org.eclipse.tracecompass.tmf.ui.views.callstack.AbstractCallStackAnalysis;
-
-/**
- * Call-stack analysis to populate the TMF CallStack View from UST cyg-profile
- * events.
- *
- * @author Alexandre Montplaisir
- */
-public class LttngUstCallStackAnalysis extends AbstractCallStackAnalysis {
-
-    /**
-     * @since 1.0
-     */
-    @Override
-    public boolean setTrace(ITmfTrace trace) throws TmfAnalysisException {
-        if (!(trace instanceof LttngUstTrace)) {
-            return false;
-        }
-        return super.setTrace(trace);
-    }
-
-    @Override
-    protected LttngUstTrace getTrace() {
-        return (LttngUstTrace) super.getTrace();
-    }
-
-    @Override
-    protected ITmfStateProvider createStateProvider() {
-        return new LttngUstCallStackProvider(checkNotNull(getTrace()));
-    }
-
-}
diff --git a/org.eclipse.tracecompass.lttng2.ust/.project b/org.eclipse.tracecompass.lttng2.ust/.project
deleted file mode 100644 (file)
index d13cfd5..0000000
+++ /dev/null
@@ -1,17 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
-       <name>org.eclipse.tracecompass.lttng2.ust</name>
-       <comment></comment>
-       <projects>
-       </projects>
-       <buildSpec>
-               <buildCommand>
-                       <name>org.eclipse.pde.FeatureBuilder</name>
-                       <arguments>
-                       </arguments>
-               </buildCommand>
-       </buildSpec>
-       <natures>
-               <nature>org.eclipse.pde.FeatureNature</nature>
-       </natures>
-</projectDescription>
diff --git a/org.eclipse.tracecompass.lttng2.ust/.settings/org.eclipse.core.resources.prefs b/org.eclipse.tracecompass.lttng2.ust/.settings/org.eclipse.core.resources.prefs
deleted file mode 100644 (file)
index 99f26c0..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-eclipse.preferences.version=1
-encoding/<project>=UTF-8
diff --git a/org.eclipse.tracecompass.lttng2.ust/.settings/org.eclipse.core.runtime.prefs b/org.eclipse.tracecompass.lttng2.ust/.settings/org.eclipse.core.runtime.prefs
deleted file mode 100644 (file)
index 5a0ad22..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-eclipse.preferences.version=1
-line.separator=\n
diff --git a/org.eclipse.tracecompass.lttng2.ust/build.properties b/org.eclipse.tracecompass.lttng2.ust/build.properties
deleted file mode 100644 (file)
index 475ce21..0000000
+++ /dev/null
@@ -1,16 +0,0 @@
-###############################################################################
-# Copyright (c) 2013, 2015 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:
-#     Ericsson - Initial API and implementation
-###############################################################################
-
-bin.includes = feature.xml,\
-               feature.properties,\
-               p2.inf
-src.includes = sourceTemplateFeature/p2.inf
diff --git a/org.eclipse.tracecompass.lttng2.ust/feature.properties b/org.eclipse.tracecompass.lttng2.ust/feature.properties
deleted file mode 100644 (file)
index 6d02a5e..0000000
+++ /dev/null
@@ -1,22 +0,0 @@
-###############################################################################
-# Copyright (c) 2009, 2014 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:
-#     Ericsson - Initial API and implementation
-###############################################################################
-
-featureName=LTTng Userspace Analysis
-
-description=Plug-ins to integrate LTTng-UST analysis tools into the workbench. \
-Includes the LTTng (Linux Tracing Toolkit), TMF (Tracing and Monitoring Framework) \
-and CTF (Common Trace Format) features.
-
-featureProvider=Eclipse Trace Compass
-
-copyright=Copyright 2013 Ericsson
-
diff --git a/org.eclipse.tracecompass.lttng2.ust/feature.xml b/org.eclipse.tracecompass.lttng2.ust/feature.xml
deleted file mode 100644 (file)
index ebc4015..0000000
+++ /dev/null
@@ -1,64 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- For PDE build, remove "ws" and "arch" -->
-<feature
-      id="org.eclipse.tracecompass.lttng2.ust"
-      label="%featureName"
-      version="1.0.0.qualifier"
-      provider-name="%featureProvider"
-      license-feature="org.eclipse.license"
-      license-feature-version="0.0.0">
-
-   <description>
-      %description
-   </description>
-
-   <copyright>
-      %copyright
-   </copyright>
-
-   <license url="%licenseURL">
-      %license
-   </license>
-
-   <includes
-         id="org.eclipse.tracecompass.lttng2.control"
-         version="0.0.0"
-         name="Linux Tracing Toolkit next generation (LTTng)"/>
-
-   <includes
-         id="org.eclipse.tracecompass.tmf.ctf"
-         version="0.0.0"
-         name="CTF Support for TMF"/>
-
-   <requires>
-      <import plugin="org.eclipse.core.runtime"/>
-      <import plugin="org.eclipse.core.resources"/>
-      <import plugin="org.eclipse.tracecompass.ctf.core" version="1.0.0" match="greaterOrEqual"/>
-      <import plugin="org.eclipse.tracecompass.tmf.core" version="1.0.0" match="greaterOrEqual"/>
-      <import plugin="org.eclipse.ui"/>
-      <import plugin="org.eclipse.ui.ide"/>
-      <import plugin="org.eclipse.tracecompass.tmf.ui" version="1.0.0" match="greaterOrEqual"/>
-      <import plugin="org.eclipse.help"/>
-   </requires>
-
-   <plugin
-         id="org.eclipse.tracecompass.lttng2.ust.core"
-         download-size="0"
-         install-size="0"
-         version="0.0.0"
-         unpack="false"/>
-
-   <plugin
-         id="org.eclipse.tracecompass.lttng2.ust.ui"
-         download-size="0"
-         install-size="0"
-         version="0.0.0"
-         unpack="false"/>
-
-   <plugin
-         id="org.eclipse.tracecompass.doc.user"
-         download-size="0"
-         install-size="0"
-         version="0.0.0"/>
-
-</feature>
diff --git a/org.eclipse.tracecompass.lttng2.ust/p2.inf b/org.eclipse.tracecompass.lttng2.ust/p2.inf
deleted file mode 100644 (file)
index cdae743..0000000
+++ /dev/null
@@ -1 +0,0 @@
-update.matchExp=providedCapabilities.exists(pc | pc.namespace == 'org.eclipse.equinox.p2.iu' && (pc.name == 'org.eclipse.linuxtools.lttng2.ust.feature.group' || pc.name == 'org.eclipse.tracecompass.lttng2.ust.feature.group'))
\ No newline at end of file
diff --git a/org.eclipse.tracecompass.lttng2.ust/pom.xml b/org.eclipse.tracecompass.lttng2.ust/pom.xml
deleted file mode 100644 (file)
index 5d5e840..0000000
+++ /dev/null
@@ -1,63 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-   Copyright (C) 2011, 2013 Red Hat Inc., 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
--->
-<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>
-    <artifactId>org.eclipse.tracecompass</artifactId>
-    <groupId>org.eclipse.tracecompass</groupId>
-    <version>1.0.0-SNAPSHOT</version>
-  </parent>
-
-  <artifactId>org.eclipse.tracecompass.lttng2.ust</artifactId>
-  <groupId>org.eclipse.tracecompass</groupId>
-  <version>1.0.0-SNAPSHOT</version>
-  <packaging>eclipse-feature</packaging>
-
-  <name>Trace Compass LTTng Userspace Tracer Analysis Feature</name>
-
-  <build>
-    <plugins>
-      <plugin>
-        <groupId>org.eclipse.tycho.extras</groupId>
-        <artifactId>tycho-source-feature-plugin</artifactId>
-        <executions>
-          <execution>
-            <id>source-feature</id>
-            <phase>package</phase>
-            <goals>
-              <goal>source-feature</goal>
-            </goals>
-            <configuration>
-              <excludes>
-                <plugin id="org.eclipse.tracecompass.doc.user"/>
-              </excludes>
-            </configuration>
-          </execution>
-        </executions>
-      </plugin>
-      <plugin>
-        <groupId>org.eclipse.tycho</groupId>
-        <artifactId>tycho-p2-plugin</artifactId>
-        <version>${tycho-version}</version>
-        <executions>
-          <execution>
-            <id>attached-p2-metadata</id>
-            <phase>package</phase>
-            <goals>
-              <goal>p2-metadata</goal>
-            </goals>
-          </execution>
-        </executions>
-      </plugin>
-    </plugins>
-  </build>
-</project>
diff --git a/org.eclipse.tracecompass.lttng2.ust/sourceTemplateFeature/p2.inf b/org.eclipse.tracecompass.lttng2.ust/sourceTemplateFeature/p2.inf
deleted file mode 100644 (file)
index 6deed6f..0000000
+++ /dev/null
@@ -1 +0,0 @@
-update.matchExp=providedCapabilities.exists(pc | pc.namespace == 'org.eclipse.equinox.p2.iu' && (pc.name == 'org.eclipse.linuxtools.lttng2.ust.source.feature.group' || pc.name == 'org.eclipse.tracecompass.lttng2.ust.source.feature.group'))
\ No newline at end of file
diff --git a/pom.xml b/pom.xml
index 43e0f23b3bc8502026523a68a292a03d527a1a89..65047227f617439edca7fa288343f87a6759a111 100644 (file)
--- a/pom.xml
+++ b/pom.xml
     <module>ctf</module>
     <module>doc</module>
     <module>gdbtrace</module>
+    <module>lttng</module>
     <module>pcap</module>
     <module>rcp</module>
     <module>statesystem</module>
     <module>org.eclipse.tracecompass.analysis.os.linux.core.tests</module>
     <module>org.eclipse.tracecompass.analysis.os.linux.ui</module>
 
-    <module>org.eclipse.tracecompass.lttng2.control</module>
-    <module>org.eclipse.tracecompass.lttng2.control.core</module>
-    <module>org.eclipse.tracecompass.lttng2.control.core.tests</module>
-    <module>org.eclipse.tracecompass.lttng2.control.ui</module>
-    <module>org.eclipse.tracecompass.lttng2.control.ui.tests</module>
-
-    <module>org.eclipse.tracecompass.lttng2.kernel</module>
-    <module>org.eclipse.tracecompass.lttng2.kernel.core</module>
-    <module>org.eclipse.tracecompass.lttng2.kernel.core.tests</module>
-    <module>org.eclipse.tracecompass.lttng2.kernel.ui</module>
-    <module>org.eclipse.tracecompass.lttng2.kernel.ui.swtbot.tests</module>
-
-    <module>org.eclipse.tracecompass.lttng2.ust</module>
-    <module>org.eclipse.tracecompass.lttng2.ust.core</module>
-    <module>org.eclipse.tracecompass.lttng2.ust.core.tests</module>
-    <module>org.eclipse.tracecompass.lttng2.ust.ui</module>
-    <module>org.eclipse.tracecompass.lttng2.ust.ui.tests</module>
-
     <module>org.eclipse.tracecompass.examples</module>
   </modules>
 
This page took 1.553641 seconds and 5 git commands to generate.