Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion tmf/org.eclipse.tracecompass.tmf.ui/META-INF/MANIFEST.MF
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: %Bundle-Name
Bundle-Vendor: %Bundle-Vendor
Bundle-Version: 9.1.2.qualifier
Bundle-Version: 9.2.0.qualifier
Bundle-Localization: plugin
Bundle-SymbolicName: org.eclipse.tracecompass.tmf.ui;singleton:=true
Bundle-Activator: org.eclipse.tracecompass.internal.tmf.ui.Activator
Expand Down
2 changes: 1 addition & 1 deletion tmf/org.eclipse.tracecompass.tmf.ui/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
</parent>

<artifactId>org.eclipse.tracecompass.tmf.ui</artifactId>
<version>9.1.2-SNAPSHOT</version>
<version>9.2.0-SNAPSHOT</version>
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
# Verify version consistency across the tmf.ui bundle

echo "=== Checking MANIFEST.MF version in tmf.ui ==="
fd -t f "MANIFEST.MF" tmf/org.eclipse.tracecompass.tmf.ui --exec cat {} \; | grep -i "bundle-version\|implementation-version"

echo -e "\n=== Checking pom.xml in tmf.ui directory ==="
cat -n tmf/org.eclipse.tracecompass.tmf.ui/pom.xml | head -30

echo -e "\n=== Searching for other version references (9.1.2 or 9.2.0) in tmf.ui ==="
rg "9\.[12]\." tmf/org.eclipse.tracecompass.tmf.ui --type xml --type properties

echo -e "\n=== Checking feature.xml files in parent directories that might reference tmf.ui ==="
fd -t f "feature.xml" | head -20

Repository: eclipse-tracecompass/org.eclipse.tracecompass

Length of output: 2844


🏁 Script executed:

#!/bin/bash
# Check feature.xml files that reference the tmf.ui bundle

echo "=== Searching feature.xml files for tmf.ui references ==="
fd -t f "feature.xml" | xargs grep -l "org.eclipse.tracecompass.tmf.ui" 2>/dev/null | while read file; do
  echo -e "\n--- $file ---"
  grep -n "org.eclipse.tracecompass.tmf.ui" "$file" -A 1 -B 1
done

echo -e "\n=== Checking if any feature.xml specifies bundle versions for tmf.ui ==="
fd -t f "feature.xml" | xargs grep "org.eclipse.tracecompass.tmf.ui" 2>/dev/null | grep -E "version|plugin"

Repository: eclipse-tracecompass/org.eclipse.tracecompass

Length of output: 3757


Version bump is consistent across pom.xml and MANIFEST.MF.

The minor version increment from 9.1.2-SNAPSHOT to 9.2.0-SNAPSHOT appropriately reflects the new public APIs (AbstractSelectTreeViewer3, SpecificColumnPatternFilter) and visibility changes. The MANIFEST.MF Bundle-Version is correctly set to 9.2.0.qualifier, and feature.xml imports use "greaterOrEqual" constraints that are compatible with 9.2.0.

No other module POMs require version updates; the parent pom version (11.0.0-SNAPSHOT) intentionally differs from child module versions in this project structure.

Verify that Tycho CI builds successfully with this version bump.

🤖 Prompt for AI Agents
In tmf/org.eclipse.tracecompass.tmf.ui/pom.xml around line 23, the pom version
was bumped to 9.2.0-SNAPSHOT; confirm and ensure Tycho builds succeed by running
the CI/tycho build locally or via CI, verify MANIFEST.MF Bundle-Version is
9.2.0.qualifier and feature.xml imports remain compatible, and if the Tycho
build fails, adjust any module POMs or manifest entries to match the 9.2.0
versioning or fix dependency constraints so the Tycho CI passes.


<packaging>eclipse-plugin</packaging>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -220,7 +220,7 @@ public String getColumnText(Object element, int columnIndex) {
* @param legendColumnIndex
* index of the legend column (-1 if none)
*/
private AbstractSelectTreeViewer2(Composite parent, TriStateFilteredCheckboxTree checkboxTree,
protected AbstractSelectTreeViewer2(Composite parent, TriStateFilteredCheckboxTree checkboxTree,
int legendIndex, String id) {
super(parent, checkboxTree.getViewer());

Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
/*******************************************************************************
* Copyright (c) 2025 Hong Anh
*
* All rights reserved. This program and the accompanying materials are
* made available under the terms of the Eclipse Public License 2.0 which
* accompanies this distribution, and is available at
* https://www.eclipse.org/legal/epl-2.0/
*
* SPDX-License-Identifier: EPL-2.0
*******************************************************************************/

package org.eclipse.tracecompass.tmf.ui.viewers.tree;

import org.eclipse.swt.SWT;
import org.eclipse.swt.widgets.Composite;
import org.eclipse.tracecompass.tmf.core.model.tree.ITmfTreeDataProvider;
import org.eclipse.tracecompass.tmf.ui.widgets.timegraph.dialogs.SpecificColumnPatternFilter;
import org.eclipse.tracecompass.tmf.ui.widgets.timegraph.dialogs.TriStateFilteredCheckboxTree;

/**
* An abstract tree viewer that supports selection with filtering capabilities.
*
* This viewer extends
* {@link AbstractSelectTreeViewer2}
* to allow filtering based on a specific column index.
*
* @author Hong Anh
* @since 9.2
*/
public abstract class AbstractSelectTreeViewer3 extends AbstractSelectTreeViewer2 {
/**
* Constructor
*
* @param parent
* Parent composite
* @param legendIndex
* index of the legend column (-1 if none)
* @param id
* {@link ITmfTreeDataProvider} ID
* @param indexColumnFilter
* the index of the column to apply the filter on
*/
public AbstractSelectTreeViewer3(Composite parent, int legendIndex, String id, int indexColumnFilter) {
// Initialize the tree viewer with a filtered checkbox tree and column-based filtering
super(parent, new TriStateFilteredCheckboxTree(parent,
SWT.MULTI | SWT.H_SCROLL | SWT.FULL_SELECTION,
new SpecificColumnPatternFilter(indexColumnFilter), true, false), legendIndex, id);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -74,8 +74,8 @@ protected boolean isLeafMatch(Viewer viewer, Object element) {

// Ensure the tree element and its parent(s) match the filter text
for (Predicate<String> p : fPredicates) {
// Retrieve tree element text and make verification. Text is at column 0
String labelText = labelProvider.getColumnText(node, 0);
// Get the text of the element in the specified column and verify against the predicate
String labelText = labelProvider.getColumnText(node, this.getIndexColumnFilter());
if (labelText == null || !p.test(labelText)) {
return false;
}
Expand All @@ -85,4 +85,13 @@ protected boolean isLeafMatch(Viewer viewer, Object element) {
}
return true;
}

/**
* Returns the index of the column used for filtering.
* @return the column index (default is 0)
* @since 9.2
*/
protected int getIndexColumnFilter() {
return 0;
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
/*******************************************************************************
* Copyright (c) 2025 Hong Anh
*
* All rights reserved. This program and the accompanying materials are
* made available under the terms of the Eclipse Public License 2.0 which
* accompanies this distribution, and is available at
* https://www.eclipse.org/legal/epl-2.0/
*
* SPDX-License-Identifier: EPL-2.0
*******************************************************************************/

package org.eclipse.tracecompass.tmf.ui.widgets.timegraph.dialogs;


/**
* A filter that extends {@link MultiTreePatternFilter} to allow filtering
* based on a specific column index.
*
* This implementation enables users to apply multiple patterns (separated by '/')
* while specifying which column of the tree should be used for matching.
*
* @author Hong Anh
* @since 9.2
*/

public class SpecificColumnPatternFilter extends MultiTreePatternFilter {
private int index = 0;

/**
* Creates a new filter with the specified column index.
* @param indexColumnFilter the index of the column to apply the filter on
*/

public SpecificColumnPatternFilter(int indexColumnFilter) {
this.index = indexColumnFilter;
}

/**
* Returns the index of the column used for filtering.
* @return the column index specified during construction
*/
@Override
protected int getIndexColumnFilter() {
return this.index;
}
}