gpt4 book ai didi

org.jboss.wsf.spi.deployment.integration.WebServiceDeployment类的使用及代码示例

转载 作者:知者 更新时间:2024-03-24 20:03:05 24 4
gpt4 key购买 nike

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

WebServiceDeployment介绍

[英]A web service deployment contains WebServiceDeclaration declarations.
[中]web服务部署包含WebServiceDeclaration声明。

代码示例

代码示例来源:origin: org.jboss.ws/jbossws-jboss600M2

/**
* Gets list of JAXWS EJBs meta data.
*
* @param unit deployment unit
* @return list of JAXWS EJBs meta data
*/
public static List<WebServiceDeclaration> getJaxwsEjbs(final DeploymentUnit unit)
{
 final WebServiceDeployment wsDeployment = ASHelper.getRequiredAttachment(unit, WebServiceDeployment.class);
 final List<WebServiceDeclaration> endpoints = new ArrayList<WebServiceDeclaration>();
 final Iterator<WebServiceDeclaration> ejbIterator = wsDeployment.getServiceEndpoints().iterator();
 while (ejbIterator.hasNext())
 {
   final WebServiceDeclaration ejbContainer = ejbIterator.next();
   if (ASHelper.isWebServiceBean(ejbContainer))
   {
    endpoints.add(ejbContainer);
   }
 }
 return endpoints;
}

代码示例来源:origin: org.jboss.ws/jbossws-jboss500x

@Override
public boolean isWebServiceDeployment(DeploymentUnit unit)
{
 WebServiceDeployment webServiceDeployment = unit.getAttachment(WebServiceDeployment.class);
 if (null == webServiceDeployment )
   return false;
 boolean isWebServiceDeployment = false;
 Iterator<WebServiceDeclaration> it = webServiceDeployment.getServiceEndpoints().iterator();
 while (it.hasNext())
 {
   WebServiceDeclaration container = it.next();
   if (isWebServiceBean(container))
   {
    isWebServiceDeployment = true;
    break;
   }
 }
 return isWebServiceDeployment;
}

代码示例来源:origin: org.jboss.ws/jbossws-jboss501CR1

@Override
public boolean isWebServiceDeployment(DeploymentUnit unit)
{
 WebServiceDeployment webServiceDeployment = unit.getAttachment(WebServiceDeployment.class);
 if (null == webServiceDeployment )
   return false;
 boolean isWebServiceDeployment = false;
 Iterator<WebServiceDeclaration> it = webServiceDeployment.getServiceEndpoints().iterator();
 while (it.hasNext())
 {
   WebServiceDeclaration container = it.next();
   if (isWebServiceBean(container))
   {
    isWebServiceDeployment = true;
    break;
   }
 }
 return isWebServiceDeployment;
}

代码示例来源:origin: org.jboss.ws/jbossws-jboss510

/**
* Gets list of JAXWS EJBs meta data.
*
* @param unit deployment unit
* @return list of JAXWS EJBs meta data
*/
public static List<WebServiceDeclaration> getJaxwsEjbs(final DeploymentUnit unit)
{
 final WebServiceDeployment wsDeployment = ASHelper.getRequiredAttachment(unit, WebServiceDeployment.class);
 final List<WebServiceDeclaration> endpoints = new ArrayList<WebServiceDeclaration>();
 final Iterator<WebServiceDeclaration> ejbIterator = wsDeployment.getServiceEndpoints().iterator();
 while (ejbIterator.hasNext())
 {
   final WebServiceDeclaration ejbContainer = ejbIterator.next();
   if (ASHelper.isWebServiceBean(ejbContainer))
   {
    endpoints.add(ejbContainer);
   }
 }
 return endpoints;
}

代码示例来源:origin: org.jboss.ws/jbossws-jboss510x

@Override
public boolean isWebServiceDeployment(DeploymentUnit unit)
{
 WebServiceDeployment webServiceDeployment = unit.getAttachment(WebServiceDeployment.class);
 if (null == webServiceDeployment )
   return false;
 boolean isWebServiceDeployment = false;
 Iterator<WebServiceDeclaration> it = webServiceDeployment.getServiceEndpoints().iterator();
 while (it.hasNext())
 {
   WebServiceDeclaration container = it.next();
   if (isWebServiceBean(container))
   {
    isWebServiceDeployment = true;
    break;
   }
 }
 return isWebServiceDeployment;
}

代码示例来源:origin: org.jboss.ws/jbossws-jboss501

/**
* Gets list of JAXWS EJBs meta data.
*
* @param unit deployment unit
* @return list of JAXWS EJBs meta data
*/
public static List<WebServiceDeclaration> getJaxwsEjbs(final DeploymentUnit unit)
{
 final WebServiceDeployment wsDeployment = ASHelper.getRequiredAttachment(unit, WebServiceDeployment.class);
 final List<WebServiceDeclaration> endpoints = new ArrayList<WebServiceDeclaration>();
 final Iterator<WebServiceDeclaration> ejbIterator = wsDeployment.getServiceEndpoints().iterator();
 while (ejbIterator.hasNext())
 {
   final WebServiceDeclaration ejbContainer = ejbIterator.next();
   if (ASHelper.isWebServiceBean(ejbContainer))
   {
    endpoints.add(ejbContainer);
   }
 }
 return endpoints;
}

代码示例来源:origin: org.jboss.ws/jbossws-jboss600x

@Override
public boolean isWebServiceDeployment(DeploymentUnit unit)
{
 WebServiceDeployment webServiceDeployment = unit.getAttachment(WebServiceDeployment.class);
 if (null == webServiceDeployment )
   return false;
 boolean isWebServiceDeployment = false;
 Iterator<WebServiceDeclaration> it = webServiceDeployment.getServiceEndpoints().iterator();
 while (it.hasNext())
 {
   WebServiceDeclaration container = it.next();
   if (isWebServiceBean(container))
   {
    isWebServiceDeployment = true;
    break;
   }
 }
 return isWebServiceDeployment;
}

代码示例来源:origin: org.jboss.ws/jbossws-jboss510

/**
* @see AbstractMetaDataBuilderEJB#buildEnterpriseBeansMetaData(Deployment, EJBArchiveMetaData)
* 
* @param dep webservice deployment
* @param ejbArchiveMD EJB archive meta data
*/
@Override
protected void buildEnterpriseBeansMetaData(final Deployment dep, final EJBArchiveMetaData ejbArchiveMD)
{
 final WebServiceDeployment ejb3Deployment = WSHelper.getRequiredAttachment(dep, WebServiceDeployment.class);
 final List<EJBMetaData> wsEjbsMD = new LinkedList<EJBMetaData>();
 for (final WebServiceDeclaration jbossEjbMD : ejb3Deployment.getServiceEndpoints())
 {
   this.buildEnterpriseBeanMetaData(wsEjbsMD, jbossEjbMD);
 }
 ejbArchiveMD.setEnterpriseBeans(wsEjbsMD);
}

代码示例来源:origin: org.jboss.ws/jbossws-jboss600M2

/**
* @see AbstractMetaDataBuilderEJB#buildEnterpriseBeansMetaData(Deployment, EJBArchiveMetaData)
* 
* @param dep webservice deployment
* @param ejbArchiveMD EJB archive meta data
*/
@Override
protected void buildEnterpriseBeansMetaData(final Deployment dep, final EJBArchiveMetaData ejbArchiveMD)
{
 final WebServiceDeployment ejb3Deployment = WSHelper.getRequiredAttachment(dep, WebServiceDeployment.class);
 final List<EJBMetaData> wsEjbsMD = new LinkedList<EJBMetaData>();
 for (final WebServiceDeclaration jbossEjbMD : ejb3Deployment.getServiceEndpoints())
 {
   this.buildEnterpriseBeanMetaData(wsEjbsMD, jbossEjbMD);
 }
 ejbArchiveMD.setEnterpriseBeans(wsEjbsMD);
}

代码示例来源:origin: org.jboss.ws/jbossws-jboss600M2

/**
* @see org.jboss.webservices.integration.tomcat.AbstractSecurityMetaDataAccessorEJB#getSecurityDomain(Deployment)
*
* @param dep webservice deployment
* @return security domain associated with EJB 3 deployment
*/
public String getSecurityDomain(final Deployment dep)
{
 final WebServiceDeployment wsDeployment = WSHelper.getRequiredAttachment(dep, WebServiceDeployment.class);
 String securityDomain = null;
 final Iterator<WebServiceDeclaration> ejbContainers = wsDeployment.getServiceEndpoints().iterator();
 while (ejbContainers.hasNext())
 {
   final WebServiceDeclaration ejbContainer = ejbContainers.next();
   final SecurityDomain nextSecurityDomain = ejbContainer.getAnnotation(SecurityDomain.class);
   securityDomain = this.getDomain(securityDomain, nextSecurityDomain);
 }
 return super.appendJaasPrefix(securityDomain);
}

代码示例来源:origin: org.jboss.ws/jbossws-jboss501

/**
* @see AbstractMetaDataBuilderEJB#buildEnterpriseBeansMetaData(Deployment, EJBArchiveMetaData)
* 
* @param dep webservice deployment
* @param ejbArchiveMD EJB archive meta data
*/
@Override
protected void buildEnterpriseBeansMetaData(final Deployment dep, final EJBArchiveMetaData ejbArchiveMD)
{
 final WebServiceDeployment ejb3Deployment = WSHelper.getRequiredAttachment(dep, WebServiceDeployment.class);
 final List<EJBMetaData> wsEjbsMD = new LinkedList<EJBMetaData>();
 for (final WebServiceDeclaration jbossEjbMD : ejb3Deployment.getServiceEndpoints())
 {
   this.buildEnterpriseBeanMetaData(wsEjbsMD, jbossEjbMD);
 }
 ejbArchiveMD.setEnterpriseBeans(wsEjbsMD);
}

代码示例来源:origin: org.jboss.ws/jbossws-jboss501

/**
* @see org.jboss.webservices.integration.tomcat.AbstractSecurityMetaDataAccessorEJB#getSecurityDomain(Deployment)
*
* @param dep webservice deployment
* @return security domain associated with EJB 3 deployment
*/
public String getSecurityDomain(final Deployment dep)
{
 final WebServiceDeployment wsDeployment = WSHelper.getRequiredAttachment(dep, WebServiceDeployment.class);
 String securityDomain = null;
 final Iterator<WebServiceDeclaration> ejbContainers = wsDeployment.getServiceEndpoints().iterator();
 while (ejbContainers.hasNext())
 {
   final WebServiceDeclaration ejbContainer = ejbContainers.next();
   final SecurityDomain nextSecurityDomain = ejbContainer.getAnnotation(SecurityDomain.class);
   securityDomain = this.getDomain(securityDomain, nextSecurityDomain);
 }
 return super.appendJaasPrefix(securityDomain);
}

代码示例来源:origin: org.jboss.ws/jbossws-jboss510

/**
* @see org.jboss.webservices.integration.tomcat.AbstractSecurityMetaDataAccessorEJB#getSecurityDomain(Deployment)
*
* @param dep webservice deployment
* @return security domain associated with EJB 3 deployment
*/
public String getSecurityDomain(final Deployment dep)
{
 final WebServiceDeployment wsDeployment = WSHelper.getRequiredAttachment(dep, WebServiceDeployment.class);
 String securityDomain = null;
 final Iterator<WebServiceDeclaration> ejbContainers = wsDeployment.getServiceEndpoints().iterator();
 while (ejbContainers.hasNext())
 {
   final WebServiceDeclaration ejbContainer = ejbContainers.next();
   final SecurityDomain nextSecurityDomain = ejbContainer.getAnnotation(SecurityDomain.class);
   securityDomain = this.getDomain(securityDomain, nextSecurityDomain);
 }
 return super.appendJaasPrefix(securityDomain);
}

代码示例来源:origin: org.jboss.ws/jbossws-jboss510x

public void addSecurityDomain(JBossWebMetaData jbossWeb, Deployment dep)
{
 String securityDomain = null;
 WebServiceDeployment webServiceDeployment = dep.getAttachment(WebServiceDeployment.class);
 if (webServiceDeployment != null)
 {
   Iterator<WebServiceDeclaration> it = webServiceDeployment.getServiceEndpoints().iterator();
   while (it.hasNext())
   {
    WebServiceDeclaration container = it.next();
    SecurityDomain anSecurityDomain = container.getAnnotation(SecurityDomain.class);
    if (anSecurityDomain != null)
    {
      if (securityDomain != null && !securityDomain.equals(anSecurityDomain.value()))
       throw new IllegalStateException("Multiple security domains not supported");
      securityDomain = anSecurityDomain.value();
    }
   }
 }
 if (securityDomain != null)
 {
   if (securityDomain.startsWith("java:/jaas/") == false)
    securityDomain = "java:/jaas/" + securityDomain;
   jbossWeb.setSecurityDomain(securityDomain);
 }
}

代码示例来源:origin: org.jboss.ws/jbossws-jboss500x

public void addSecurityDomain(JBossWebMetaData jbossWeb, Deployment dep)
{
 String securityDomain = null;
 WebServiceDeployment webServiceDeployment = dep.getAttachment(WebServiceDeployment.class);
 if (webServiceDeployment != null)
 {
   Iterator<WebServiceDeclaration> it = webServiceDeployment.getServiceEndpoints().iterator();
   while (it.hasNext())
   {
    WebServiceDeclaration container = it.next();
    SecurityDomain anSecurityDomain = container.getAnnotation(SecurityDomain.class);
    if (anSecurityDomain != null)
    {
      if (securityDomain != null && !securityDomain.equals(anSecurityDomain.value()))
       throw new IllegalStateException("Multiple security domains not supported");
      securityDomain = anSecurityDomain.value();
    }
   }
 }
 if (securityDomain != null)
 {
   if (securityDomain.startsWith("java:/jaas/") == false)
    securityDomain = "java:/jaas/" + securityDomain;
   jbossWeb.setSecurityDomain(securityDomain);
 }
}

代码示例来源:origin: org.jboss.ws/jbossws-jboss501CR1

public void addSecurityDomain(JBossWebMetaData jbossWeb, Deployment dep)
{
 String securityDomain = null;
 WebServiceDeployment webServiceDeployment = dep.getAttachment(WebServiceDeployment.class);
 if (webServiceDeployment != null)
 {
   Iterator<WebServiceDeclaration> it = webServiceDeployment.getServiceEndpoints().iterator();
   while (it.hasNext())
   {
    WebServiceDeclaration container = it.next();
    SecurityDomain anSecurityDomain = container.getAnnotation(SecurityDomain.class);
    if (anSecurityDomain != null)
    {
      if (securityDomain != null && !securityDomain.equals(anSecurityDomain.value()))
       throw new IllegalStateException("Multiple security domains not supported");
      securityDomain = anSecurityDomain.value();
    }
   }
 }
 if (securityDomain != null)
 {
   if (securityDomain.startsWith("java:/jaas/") == false)
    securityDomain = "java:/jaas/" + securityDomain;
   jbossWeb.setSecurityDomain(securityDomain);
 }
}

代码示例来源:origin: org.jboss.ws/jbossws-jboss600x

public void addSecurityDomain(JBossWebMetaData jbossWeb, Deployment dep)
{
 String securityDomain = null;
 WebServiceDeployment webServiceDeployment = dep.getAttachment(WebServiceDeployment.class);
 if (webServiceDeployment != null)
 {
   Iterator<WebServiceDeclaration> it = webServiceDeployment.getServiceEndpoints().iterator();
   while (it.hasNext())
   {
    WebServiceDeclaration container = it.next();
    SecurityDomain anSecurityDomain = container.getAnnotation(SecurityDomain.class);
    if (anSecurityDomain != null)
    {
      if (securityDomain != null && !securityDomain.equals(anSecurityDomain.value()))
       throw new IllegalStateException("Multiple security domains not supported");
      securityDomain = anSecurityDomain.value();
    }
   }
 }
 if (securityDomain != null)
 {
   if (securityDomain.startsWith("java:/jaas/") == false)
    securityDomain = "java:/jaas/" + securityDomain;
   jbossWeb.setSecurityDomain(securityDomain);
 }
}

代码示例来源:origin: org.jboss.ws/jbossws-jboss500x

public void addSecurityRoles(JBossWebMetaData webApp, Deployment dep)
  {
   WebServiceDeployment webServiceDeployment = dep.getAttachment(WebServiceDeployment.class);
   if (webServiceDeployment != null)
   {
     Iterator<WebServiceDeclaration> it = webServiceDeployment.getServiceEndpoints().iterator();
     while (it.hasNext())
     {
      WebServiceDeclaration container = it.next();
      RolesAllowed anRolesAllowed = container.getAnnotation(RolesAllowed.class);
      if (anRolesAllowed != null)
      {
        SecurityRolesMetaData securityRoles = webApp.getSecurityRoles();
        for (String roleName : anRolesAllowed.value())
        {
         SecurityRoleMetaData role = new SecurityRoleMetaData();
         role.setRoleName(roleName);
         securityRoles.add(role);
        }
      }
     }
   }
  }
}

代码示例来源:origin: org.jboss.ws/jbossws-jboss600x

public void addSecurityRoles(JBossWebMetaData webApp, Deployment dep)
  {
   WebServiceDeployment webServiceDeployment = dep.getAttachment(WebServiceDeployment.class);
   if (webServiceDeployment != null)
   {
     Iterator<WebServiceDeclaration> it = webServiceDeployment.getServiceEndpoints().iterator();
     while (it.hasNext())
     {
      WebServiceDeclaration container = it.next();
      RolesAllowed anRolesAllowed = container.getAnnotation(RolesAllowed.class);
      if (anRolesAllowed != null)
      {
        SecurityRolesMetaData securityRoles = webApp.getSecurityRoles();
        for (String roleName : anRolesAllowed.value())
        {
         SecurityRoleMetaData role = new SecurityRoleMetaData();
         role.setRoleName(roleName);
         securityRoles.add(role);
        }
      }
     }
   }
  }
}

代码示例来源:origin: org.jboss.ws/jbossws-jboss510x

public void addSecurityRoles(JBossWebMetaData webApp, Deployment dep)
  {
   WebServiceDeployment webServiceDeployment = dep.getAttachment(WebServiceDeployment.class);
   if (webServiceDeployment != null)
   {
     Iterator<WebServiceDeclaration> it = webServiceDeployment.getServiceEndpoints().iterator();
     while (it.hasNext())
     {
      WebServiceDeclaration container = it.next();
      RolesAllowed anRolesAllowed = container.getAnnotation(RolesAllowed.class);
      if (anRolesAllowed != null)
      {
        SecurityRolesMetaData securityRoles = webApp.getSecurityRoles();
        for (String roleName : anRolesAllowed.value())
        {
         SecurityRoleMetaData role = new SecurityRoleMetaData();
         role.setRoleName(roleName);
         securityRoles.add(role);
        }
      }
     }
   }
  }
}

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