Package org.jboss.beans.info.spi

Examples of org.jboss.beans.info.spi.BeanInfo


   @SuppressWarnings("unchecked")
   protected Object unwrapCollection(CollectionValue collectionValue, TypeInfo type)
   {
      try
      {
         BeanInfo collectionInfo;
         // null is not instance of
         if (type instanceof ClassInfo)
         {
            collectionInfo = configuration.getBeanInfo(type);
         }
         else
         {
            MetaType metaType = collectionValue.getMetaType();
            collectionInfo = configuration.getBeanInfo(metaType.getTypeName(), Thread.currentThread().getContextClassLoader());
         }
         ClassInfo classInfo = collectionInfo.getClassInfo();
         Collection collection = (Collection)createNewInstance(collectionInfo);

         TypeInfo componentType = classInfo.getComponentType();
         boolean isObjectTypeInfo = OBJECT_TYPE_INFO.equals(componentType);
View Full Code Here


         String className = tokenizer.nextToken();

         ClassLoader cl = Configurator.getClassLoader((BeanMetaData) null);
         try
         {
            BeanInfo info = getBeanInfo(className, cl);
            BeanMetaData metaData = getBeanMetaData(info, className);
            return Configurator.instantiateAndConfigure(this, info, metaData);
         }
         catch (ClassNotFoundException ignored)
         {
View Full Code Here

    * @throws Throwable for any error
    */
   protected KernelRegistryEntry createKernelRegistryEntry(Kernel kernel, Object object) throws Throwable
   {
      KernelConfig config = kernel.getConfig();
      BeanInfo info = config.getBeanInfo(object.getClass());
      return new BeanKernelRegistryEntry(object, info);
   }
View Full Code Here

      return getDelegate().getKernel();
   }

   public BeanInfo getBeanInfo()
   {
      BeanInfo beanInfo = getDelegate().getBeanInfo();
      return beanInfo != null ? new UnmodifiableBeanInfo(beanInfo) : null;
   }
View Full Code Here

         if (classInfoMap != null)
         {
            modeMap = classInfoMap.get(classInfo);
            if (modeMap != null)
            {
               BeanInfo info = modeMap.get(accessMode);
               if (info != null)
                  return info;
            }
         }

         Set<ConstructorInfo> constructors = getConstructors(classInfo);
         Set<MethodInfo> methods = getMethods(classInfo);
         Set<PropertyInfo> properties;
         if (classInfo.isAnnotation())
            properties = getAnnotationProperties(methods);
         else
            properties = getBeanProperties(methods);
         Set<EventInfo> events = getEvents(classInfo);

         BeanInfo result = createBeanInfo(classAdapter, accessMode, properties, constructors, methods, events);
         if (classInfoMap == null)
         {
            classInfoMap = new WeakHashMap<ClassInfo, Map<BeanAccessMode, BeanInfo>>();
            cache.put(cl, classInfoMap);
         }
View Full Code Here

         throw new NoSuchBeanDefinitionException(name);

      if (context instanceof KernelControllerContext)
      {
         KernelControllerContext kcc = (KernelControllerContext)context;
         BeanInfo beanInfo = kcc.getBeanInfo();
         ClassInfo classInfo = beanInfo.getClassInfo();
         TypeInfoFactory tif = classInfo.getTypeInfoFactory();
         // it's a bean factory
         if (tif.getTypeInfo(AbstractBeanFactory.class).isAssignableFrom(classInfo))
         {
            return getPrototypeClass(kcc);
View Full Code Here

         KernelConfigurator configurator = context.getKernel().getConfigurator();
         return configurator.getClassInfo(type, cl);
      }
      // check properties
      KernelControllerContext context = visitor.getControllerContext();
      BeanInfo beanInfo = context.getBeanInfo();
      PropertyInfo pi = beanInfo.getProperty(getName());
      return applyCollectionOrMapCheck(pi.getType());
   }
View Full Code Here

public class ConfigureAction extends AbstractConfigureAction
{
   protected void installActionInternal(KernelControllerContext context) throws Throwable
   {
      Object object = context.getTarget();
      BeanInfo info = context.getBeanInfo();
      BeanMetaData metaData = context.getBeanMetaData();
      setAttributes(context, object, info, metaData, false);

      installKernelControllerContextAware(context);
   }
View Full Code Here

   protected void uninstallActionInternal(KernelControllerContext context)
   {
      uninstallKernelControllerContextAware(context);

      Object object = context.getTarget();
      BeanInfo info = context.getBeanInfo();
      BeanMetaData metaData = context.getBeanMetaData();
      try
      {
         setAttributes(context, object, info, metaData, true);
      }
View Full Code Here

         String className = tokenizer.nextToken();

         ClassLoader cl = Configurator.getClassLoader((BeanMetaData) null);
         try
         {
            BeanInfo info = getBeanInfo(className, cl);
            BeanMetaData metaData = getBeanMetaData(info, className);
            return Configurator.instantiateAndConfigure(this, info, metaData);
         }
         catch (ClassNotFoundException ignored)
         {
View Full Code Here

TOP

Related Classes of org.jboss.beans.info.spi.BeanInfo

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.