use of org.spf4j.stackmonitor.SampleGraph.SampleKey in project spf4j by zolyfarkas.
the class HotFlameStackPanel method getDetail.
@Override
@Nullable
public String getDetail(final Point location) {
List<SampleKey> tips = search(location.x, location.y, 0, 0);
if (tips.size() >= 1) {
final SampleKey key = tips.get(0);
final AggSample node = completeGraph.getAggNode(key);
StringBuilder sb = new StringBuilder();
sb.append(node).append('-').append(node.getNrSamples()).append("\n invoked from: ");
appendEdgeInfo(completeGraph.getParents(node), sb);
sb.append("\n invoking: ");
appendEdgeInfo(completeGraph.getChildren(node), sb);
return sb.toString();
} else {
return null;
}
}
use of org.spf4j.stackmonitor.SampleGraph.SampleKey in project spf4j by zolyfarkas.
the class HotFlameStackPanel method drill.
@Override
public void drill() {
List<SampleKey> tips = search(xx, yy, 0, 0);
if (tips.size() >= 1) {
SampleKey sample = tips.get(0);
Set<Sample> samples = completeGraph.getSamples(sample);
Iterator<SampleGraph.Sample> iterator = samples.iterator();
SampleNode agg = iterator.next().getNode();
while (iterator.hasNext()) {
agg = SampleNode.aggregate(agg, iterator.next().getNode());
}
updateSamples(sample.getMethod(), agg);
repaint();
}
}
use of org.spf4j.stackmonitor.SampleGraph.SampleKey in project spf4j by zolyfarkas.
the class HotFlameStackPanel method filter.
@Override
public void filter() {
List<SampleKey> tips = search(xx, yy, 0, 0);
if (tips.size() >= 1) {
final SampleKey value = tips.get(0);
updateSamples(getMethod(), getSamples().filteredBy(new EqualsPredicate<>(value.getMethod())));
repaint();
}
}
Aggregations