-// $Id$
/**
* Copyright (C) 2007 EDIT
* European Distributed Institute of Taxonomy
import org.eclipse.swt.widgets.Shell;
-import eu.etaxonomy.cdm.api.conversation.ConversationHolder;
import eu.etaxonomy.cdm.api.service.IAgentService;
import eu.etaxonomy.cdm.model.agent.Team;
import eu.etaxonomy.cdm.model.common.CdmBase;
* @param team a {@link eu.etaxonomy.cdm.model.agent.Team} object.
* @return a {@link eu.etaxonomy.cdm.model.agent.Team} object.
*/
- public static Team select(Shell shell, ConversationHolder conversation, Team team){
- TeamSelectionDialog dialog = new TeamSelectionDialog(shell, conversation,
+ public static Team select(Shell shell, //ConversationHolder conversation,
+ Team team){
+ TeamSelectionDialog dialog = new TeamSelectionDialog(shell, //conversation,
"Choose Team", false, TeamSelectionDialog.class.getCanonicalName(), team);
return getSelectionFromDialog(dialog);
}
* @param cdmObject a {@link eu.etaxonomy.cdm.model.agent.Team} object.
* @param conversation a {@link eu.etaxonomy.cdm.api.conversation.ConversationHolder} object.
*/
- protected TeamSelectionDialog(Shell shell, ConversationHolder conversation,
+ protected TeamSelectionDialog(Shell shell, //ConversationHolder conversation,
String title, boolean multi, String settings,
Team cdmObject) {
- super(shell, conversation, title, multi, settings, cdmObject);
+ super(shell, //conversation,
+ title, multi, settings, cdmObject);
}
/* (non-Javadoc)
- * @see eu.etaxonomy.taxeditor.dialogs.filteredSelection.AbstractFilteredCdmResourceSelectionDialog#initModel()
+ * @see eu.etaxonomy.taxeditor.dialogs.filteredSelection.AbstractFilteredCdmResourceSelectionDialog#search
*/
/** {@inheritDoc} */
@Override
- protected void initModel() {
- model = CdmStore.getService(IAgentService.class).getTeamUuidAndTitleCache();
+ protected void callService(String pattern) {
+ model = CdmStore.getService(IAgentService.class).getUuidAndTitleCache(Team.class, limitOfInitialElements, pattern);
+
}
/** {@inheritDoc} */
/** {@inheritDoc} */
@Override
- protected String getNewWizardLinkText() {
- return String.format("Create a new <a>%1s</a>", "Team ");
+ protected String[] getNewWizardText() {
+ return new String[]{"New Team"};
}
/** {@inheritDoc} */