Package org.jboss.metadata

Examples of org.jboss.metadata.BeanMetaData


      jmxName = container.getJmxName();
      jmxNameHash = jmxName.hashCode();
      jmxNameHashInteger = new Integer(jmxNameHash);
      // Create metadata

      BeanMetaData bmd = container.getBeanMetaData();
      boolean isSession = !(bmd instanceof EntityMetaData);
      boolean isStatelessSession = false;
      if(isSession)
      {
         SessionMetaData smd = (SessionMetaData) bmd;
         if(bmd.getRemote() == null)
         {
            isServiceEndpointOnly = true;
            // nothing more to do
            return;
         }
View Full Code Here


   // Interceptor implementation ------------------------------------

   public void create() throws Exception
   {
      super.create();
      BeanMetaData bmd = getContainer().getBeanMetaData();
      exceptionRollback = bmd.getExceptionRollback();
      if (exceptionRollback == false)
         exceptionRollback = bmd.getApplicationMetaData().getExceptionRollback();
   }
View Full Code Here

      // create metadata for all jbosscmp-jdbc-managed cmp entities
      // we do that here in case there is no jbosscmp-jdbc.xml
      Iterator beans = applicationMetaData.getEnterpriseBeans();
      while(beans.hasNext())
      {
         BeanMetaData bean = (BeanMetaData)beans.next();

         // only take entities
         if(bean.isEntity())
         {
            EntityMetaData entity = (EntityMetaData)bean;

            // only take jbosscmp-jdbc-managed CMP entities
            Class pm;
View Full Code Here

      Iterator beans = ejbMetaData.getEnterpriseBeans();

      while (beans.hasNext())
      {
         BeanMetaData bean = (BeanMetaData)beans.next();

         if( bean.isEntity() )
         {
            EntityMetaData entityBean = (EntityMetaData)bean;
            if( metaData.isEJB2x() && entityBean.isCMP1x() )
            {
               // Hook for verifying CMP 1.x Beans in a 2.x JAR: store
               // current state and restore this state after verification
               // of the EJB completes.
               boolean storedSuccess = success;

               verifier.checkEntity( entityBean );

               if( success != storedSuccess )
               {
                  log.warn( "The CMP 1.x EJB '" + entityBean.getEjbName() +
                     "' generated some verification warnings. The Deployer " +
                     "will ignore these warnings but you should check " +
                     "your EJB to be on the safe side of things." );
               }

               success = storedSuccess;
            }
            else
            {
               verifier.checkEntity( entityBean );
            }
         }
         else if( bean.isSession() )
         {
            verifier.checkSession( (SessionMetaData)bean );
         }
         else
         {
View Full Code Here

      this.container = con;
   }

   public void create() throws Exception
   {
      BeanMetaData metaData = container.getBeanMetaData();
      localJndiName = metaData.getLocalJndiName();
   }
View Full Code Here

   }

   public void start()
      throws Exception
   {
      BeanMetaData metaData = container.getBeanMetaData();
      EJBProxyFactoryContainer invokerContainer =
         (EJBProxyFactoryContainer) container;
      localHomeClass = invokerContainer.getLocalHomeClass();
      localClass = invokerContainer.getLocalClass();
      if(localHomeClass == null || localClass == null)
      {
         log.debug(metaData.getEjbName()
            +
            " cannot be Bound, doesn't " +
            "have local and local home interfaces");
         return;
      }

      // this is faster than newProxyInstance
      Class[] intfs = {localClass};
      Class proxyClass = Proxy.getProxyClass(ClassLoaderAction.UTIL.get(localClass), intfs);
      final Class[] constructorParams =
         {InvocationHandler.class};

      proxyClassConstructor = proxyClass.getConstructor(constructorParams);

      Context iniCtx = new InitialContext();
      String beanName = metaData.getEjbName();

      // Set the transaction manager and transaction propagation
      // context factory of the GenericProxy class
      transactionManager =
         (TransactionManager) iniCtx.lookup("java:/TransactionManager");
View Full Code Here

      {
         Invocation inv = new Invocation(timedObjectId.getInstancePk(), method, new Object[]{timer}, null, null, null);
         inv.setValue(InvocationKey.INVOKER_PROXY_BINDING, null, PayloadKey.AS_IS);
         inv.setType(InvocationType.LOCAL);
        
         BeanMetaData bmd = container.getBeanMetaData();
         SecurityIdentityMetaData ejbTimeoutIdentity = bmd.isEntity() ? null : bmd.getEjbTimeoutIdentity();
         if( ejbTimeoutIdentity != null && ejbTimeoutIdentity.getUseCallerIdentity() == false )
         {
            ApplicationMetaData applicationMetaData = bmd.getApplicationMetaData();
            AssemblyDescriptorMetaData assemblyDescriptor = applicationMetaData.getAssemblyDescriptor();
            String roleName = ejbTimeoutIdentity.getRunAsRoleName();
            String principalName = ejbTimeoutIdentity.getRunAsPrincipalName();
            // the run-as principal might have extra roles mapped in the assembly-descriptor
            Set extraRoleNames = assemblyDescriptor.getSecurityRoleNamesByPrincipal(principalName);
View Full Code Here

/*     */   {
/* 160 */     this.jmxName = this.container.getJmxName();
/* 161 */     this.jmxNameHash = this.jmxName.hashCode();
/* 162 */     this.jmxNameHashInteger = new Integer(this.jmxNameHash);
/*     */
/* 165 */     BeanMetaData bmd = this.container.getBeanMetaData();
/* 166 */     boolean isSession = !(bmd instanceof EntityMetaData);
/* 167 */     boolean isStatelessSession = false;
/* 168 */     if (isSession)
/*     */     {
/* 170 */       SessionMetaData smd = (SessionMetaData)bmd;
/* 171 */       if (bmd.getRemote() == null)
/*     */       {
/* 173 */         this.isServiceEndpointOnly = true;
/*     */
/* 175 */         return;
/*     */       }
View Full Code Here

/* 128 */     this.applicationMetaData = applicationMetaData;
/*     */
/* 132 */     Iterator beans = applicationMetaData.getEnterpriseBeans();
/* 133 */     while (beans.hasNext())
/*     */     {
/* 135 */       BeanMetaData bean = (BeanMetaData)beans.next();
/*     */
/* 138 */       if (bean.isEntity())
/*     */       {
/* 140 */         EntityMetaData entity = (EntityMetaData)bean;
/*     */         Class pm;
/*     */         try
/*     */         {
View Full Code Here

/* 127 */     this.container = con;
/*     */   }
/*     */
/*     */   public void create() throws Exception
/*     */   {
/* 132 */     BeanMetaData metaData = this.container.getBeanMetaData();
/* 133 */     this.localJndiName = metaData.getLocalJndiName();
/*     */   }
View Full Code Here

TOP

Related Classes of org.jboss.metadata.BeanMetaData

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.