gpt4 book ai didi

com.atlassian.jira.workflow.WorkflowManager.workflowExists()方法的使用及代码示例

转载 作者:知者 更新时间:2024-03-26 18:17:05 28 4
gpt4 key购买 nike

本文整理了Java中com.atlassian.jira.workflow.WorkflowManager.workflowExists()方法的一些代码示例,展示了WorkflowManager.workflowExists()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。WorkflowManager.workflowExists()方法的具体详情如下:
包路径:com.atlassian.jira.workflow.WorkflowManager
类名称:WorkflowManager
方法名:workflowExists

WorkflowManager.workflowExists介绍

暂无

代码示例

代码示例来源:origin: com.atlassian.jira.plugins/jira-workflow-sharing-plugin

private String createWorkflowNameFromFilename(String zipFile)
{
  String workflowName = WordUtils.capitalizeFully(FilenameUtils.removeExtension(zipFile).replaceAll("[_:\\\\/*?|<>-]", " "));
  String suggestedName = workflowName;
  if (workflowManager.workflowExists(workflowName))
  {
    int x = 2;
    while (workflowManager.workflowExists(suggestedName))
    {
      suggestedName = i18n.getText("wfshare.import.prefix", String.valueOf(x), workflowName);
      x++;
    }
  }
  return suggestedName;
}

代码示例来源:origin: com.atlassian.jira/jira-core

if (workflowManager.workflowExists(name))

代码示例来源:origin: com.atlassian.jira/jira-core

public void validateCopyWorkflow(final JiraServiceContext jiraServiceContext, final String newWorkflowName)
{
  if (!hasAdminPermission(jiraServiceContext))
  {
    jiraServiceContext.getErrorCollection().addErrorMessage(getI18nBean().getText("admin.workflows.service.error.no.admin.permission"));
    return;
  }
  if (!WorkflowUtil.isAcceptableName(newWorkflowName,"newWorkflowName",jiraServiceContext.getErrorCollection()))
  {
    return;
  }
  try
  {
    if (workflowManager.workflowExists(newWorkflowName))
    {
      jiraServiceContext.getErrorCollection().addError("newWorkflowName",
        getI18nBean().getText("admin.errors.a.workflow.with.this.name.already.exists"));
    }
  }
  catch (final WorkflowException e)
  {
    log.error("Error occurred while accessing workflow information.", e);
    jiraServiceContext.getErrorCollection().addErrorMessage(
      getI18nBean().getText("admin.errors.workflows.error.occurred.accessing.information"));
  }
}

代码示例来源:origin: com.atlassian.jira/jira-core

@RequiresXsrfCheck
public String doAddWorkflow() throws Exception
{
  if (!WorkflowUtil.isAcceptableName(newWorkflowName,"newWorkflowName",this))
  {
    return INPUT;
  }
  else if (workflowManager.workflowExists(newWorkflowName))
  {
    addError("newWorkflowName", getText("admin.errors.a.workflow.with.this.name.already.exists"));
  }
  if (invalidInput())
  { return INPUT; }
  ConfigurableJiraWorkflow newWorkflow = new ConfigurableJiraWorkflow(newWorkflowName, workflowManager);
  newWorkflow.setDescription(description);
  workflowManager.createWorkflow(getLoggedInUser(), newWorkflow);
  UrlBuilder builder = new UrlBuilder("EditWorkflowDispatcher.jspa")
      .addParameter("wfName", newWorkflow.getName())
      .addParameter("atl_token", getXsrfToken());
  return returnCompleteWithInlineRedirect(builder.asUrlString());
}

代码示例来源:origin: com.atlassian.jira/jira-core

if (!newWorkflowName.equals(currentWorkflow.getName()) && workflowManager.workflowExists(newWorkflowName))

28 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com