Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [mylyn-integrators] How to handle dynamic serverities and priorities in a connector - tasklist - legend etc.

Frank Becker schrieb:
Hi Andreas,

in getTaskKindOverlay you can use

try {
BugzillaRepositoryConnector connector = (BugzillaRepositoryConnector) TasksUi.getRepositoryConnector(task.getConnectorKind());
TaskRepository repository1 = TasksUi.getRepositoryManager().getRepository(task.getConnectorKind(),
task.getRepositoryUrl());
IProgressMonitor monitor = null;
RepositoryConfiguration repositoryConfiguration = connector.getRepositoryConfiguration(repository1, false,
monitor);
} catch (CoreException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
but actual I see now way that you can extend the UILegendControl to show the values per repository or product level. I think that you should create a new view in your connector.

Hope this helps.
Hi Frank,

thxs for your advice. It would be the best if the qc-mylyn-connector support the default mylyn-priorities/severities. Then the user must customize the each qc-repo in the settings-page. Maybe this will end in a performance bottleneck since each qc-task in the tasklist must access his repo-configuration to map the correct priority/severity. I will try it :-)

Andreas

Frank

P.S. I will be on vacation until Monday 4 of January.


Am 26.12.2009 um 01:20 schrieb Andreas Höhmann:

Hello folks,

I want add a legend for the qc-mylyn connector to the task list. I found the following code in the bugzilla connector:

 /**
  * Overrides getLegendElements.
  *
  * {@inheritDoc}
  * @see org.eclipse.mylyn.tasks.ui.AbstractRepositoryConnectorUi#getLegendElements()
  */
 @Override
 public List<LegendElement> getLegendElements() {
     List<LegendElement> legendItems = new ArrayList<LegendElement>();
     legendItems.add(LegendElement.createTask("blocker", BugzillaImages.OVERLAY_CRITICAL)); //$NON-NLS-1$
     legendItems.add(LegendElement.createTask("critical", BugzillaImages.OVERLAY_CRITICAL)); //$NON-NLS-1$
     legendItems.add(LegendElement.createTask("major", BugzillaImages.OVERLAY_CRITICAL)); //$NON-NLS-1$
     legendItems.add(LegendElement.createTask("normal", null)); //$NON-NLS-1$
     legendItems.add(LegendElement.createTask("minor", BugzillaImages.OVERLAY_MAJOR)); //$NON-NLS-1$
     legendItems.add(LegendElement.createTask("enhancement", BugzillaImages.OVERLAY_ENHANCEMENT)); //$NON-NLS-1$
     legendItems.add(LegendElement.createTask("trivial", BugzillaImages.OVERLAY_TRIVIAL)); //$NON-NLS-1$
     return legendItems;
 }

This looks like a "hardcoded" severity-mapping ... but in Quality Center (QC) its possible to define the severities for each project, i.e.

1 == BLOCKER and 5 is TRIVIAL
or
1 == TRIVIAL and 5 == BLOCKER
and so on.

And the number of severities is not limited (i.e. it's possible to define 10 severity levels).

Now the question, how can we provide a nice legend for our connector?
What can we do to support a Legend for each configured qc-repository?
I created a "Serverity Mapping Section" on our repo-settingspage, but how can I access these mapping-informations in the getLegendElements()?

Any hint would be helpfull :D

Regards
Andreas

PS: the same problem exists for the priority ... in qc it's also possible to define multiple priorities
_______________________________________________
mylyn-integrators mailing list
mylyn-integrators@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/mylyn-integrators


_______________________________________________ mylyn-integrators mailing list mylyn-integrators@xxxxxxxxxxx https://dev.eclipse.org/mailman/listinfo/mylyn-integrators


Back to the top