+/**********************************************************************
+ * 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
+ **********************************************************************/
package org.eclipse.linuxtools.internal.lttng2.ui.views.control.dialogs;
import org.eclipse.ui.PlatformUI;
-
-final public class TraceControlDialogFactory {
+/**
+ * <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 new connection dialog reference.
*/
private INewConnectionDialog fNewConnectionDialog;
-
+
/**
* The enable channel dialog
*/
private IEnableChannelDialog fEnableChannelDialog;
-
+
/**
* The create session dialog.
*/
private ICreateSessionDialog fCreateSessionDialog;
-
+
/**
* 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.
*/
public void setNewConnectionDialog(INewConnectionDialog newConnectionDialog) {
fNewConnectionDialog = newConnectionDialog;
}
-
+
/**
* @return enable channel dialog
*/
public void setEnableChannelDialog(IEnableChannelDialog createEnableDialog) {
fEnableChannelDialog = createEnableDialog;
}
-
+
/**
* @return create session dialog implementation
*/
public void setGetEventInfoDialog(IGetEventInfoDialog getEventInfoDialog) {
fGetEventInfoDialog = getEventInfoDialog;
}
-
+
/**
* @return the confirmation dialog implementation
*/
}
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
*/
}
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
*/
}
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.
*/
}
return fImportConfirmationDialog;
}
-
+
/**
* Sets the import confirmation dialog implementation.
- * @param confirmDialog - a import confirmation dialog implementation.
+ * @param confirmDialog - a import confirmation dialog implementation.
*/
public void setImportConfirmationDialog(IImportConfirmationDialog confirmDialog) {
fImportConfirmationDialog = confirmDialog;