private void createFilterGroup() {
    if (fProviderGroup.isEventFilteringSupported(true)) {
      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);
    }
  }
  /**
   * 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.trim().isEmpty()
          || (!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.trim().isEmpty()
          || (!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();
    }

    // initialize filter with null
    fFilterExpression = null;
    if (fProviderGroup.isEventFilteringSupported(true)) {
      String tempFilter = fFilterText.getText();

      if (!tempFilter.trim().isEmpty()) {
        fFilterExpression = tempFilter;
      }
    }

    return true;
  }