for (final Literal l : soSortedLiterals)
variablesSubj.add(new ComboItem(l));
QueryRDFTerm queryRDFTerm = new QueryRDFTerm(prefixInstance);
// just in order to set panel of QueryRDFTerm...
queryRDFTerm.draw(new GraphWrapperOperator(queryRDFTerm), AdvancedQueryEditor.this.visualGraphs.get(0));
subjectPanel = new SuggestionPanel(PADDING, queryRDFTerm, variablesSubj, rowPanel);
final int subjectX = PADDING;
final int subjectY = PADDING;
final int subjectWidth = subjectPanel.getPreferredSize().width;
final int subjectHeight = subjectPanel.getPreferredSize().height;
subjectPanel.setBounds(subjectX, subjectY, subjectWidth,
subjectHeight);
rowPanel.add(subjectPanel);
// --- subject - end ---
// --- predicate - begin ---
final LinkedList<ComboItem> variablesPred = new LinkedList<ComboItem>();
variablesPred.add(new ComboItem(this.varPred));
final HashSet<Literal> predLiterals = new HashSet<Literal>();
for (final Bindings b : this.queryResult_preceding)
predLiterals.add(b.get(this.varPred));
final LinkedList<Literal> predSortedLiterals = new LinkedList<Literal>();
predSortedLiterals.addAll(predLiterals);
Collections.sort(predSortedLiterals);
for (final Literal l : predSortedLiterals)
variablesPred.add(new ComboItem(l));
QueryRDFTerm queryRDFTerm2 = new QueryRDFTerm(prefixInstance);
// just in order to set panel of QueryRDFTerm...
queryRDFTerm2.draw(new GraphWrapperOperator(queryRDFTerm2), AdvancedQueryEditor.this.visualGraphs.get(0));
predicatePanelS = new SuggestionPanel(PADDING, queryRDFTerm2, variablesPred, rowPanel);
final int predicateX = subjectX + subjectWidth + SPACING;
final int predicateY = PADDING;
final int predicateWidth = predicatePanelS.getPreferredSize().width;
final int predicateHeight = predicatePanelS.getPreferredSize().height;
predicatePanelS.setBounds(predicateX, predicateY, predicateWidth,
predicateHeight);
rowPanel.add(predicatePanelS);
// --- predicate - end ---
// --- object - begin ---
final AbstractGuiComponent<Operator> objectPanel = this.op.draw(
new GraphWrapperOperator(this.op), PADDING, font);
((JTextField) objectPanel.getComponent(0)).setEditable(false);
objectPanel.setMovable(false);
final int objectX = predicateX + predicateWidth + SPACING;
final int objectY = PADDING;