import org.eclipse.linuxtools.internal.lttng2.control.core.model.IChannelInfo;
import org.eclipse.linuxtools.internal.lttng2.control.core.model.IEventInfo;
+import org.eclipse.linuxtools.internal.lttng2.control.core.model.TraceChannelOutputType;
import org.eclipse.linuxtools.internal.lttng2.control.core.model.TraceEnablement;
/**
/**
* The Output type of the channel.
*/
- private String fOutputType = ""; //$NON-NLS-1$
+ private TraceChannelOutputType fOutputType = TraceChannelOutputType.UNKNOWN;
/**
* The channel enable state.
*/
fMaxSizeTraceFiles = other.fMaxSizeTraceFiles;
fMaxNumberTraceFiles = other.fMaxNumberTraceFiles;
fBufferType = other.fBufferType;
- fOutputType = (other.fOutputType == null ? null : String.valueOf(other.fOutputType));
+ fOutputType = (other.fOutputType == null ? null : other.fOutputType);
fState = other.fState;
for (Iterator<IEventInfo> iterator = other.fEvents.iterator(); iterator.hasNext();) {
IEventInfo event = iterator.next();
}
@Override
- public String getOutputType() {
+ public TraceChannelOutputType getOutputType() {
return fOutputType;
}
@Override
public void setOutputType(String type) {
+ fOutputType = TraceChannelOutputType.valueOfString(type);
+ }
+
+ @Override
+ public void setOutputType(TraceChannelOutputType type) {
fOutputType = type;
}
output.append(",ReadTimer=");
output.append(fReadTimer);
output.append(",output=");
- output.append(fOutputType);
+ output.append(fOutputType.getInName());
if ((fBufferType != null) && !fBufferType.equals(BufferType.BUFFER_TYPE_UNKNOWN) && !fBufferType.equals(BufferType.BUFFER_SHARED)) {
output.append(",BufferType=");
output.append(fBufferType);