Package org.jboss.jandex

Examples of org.jboss.jandex.ClassInfo.annotations()


        }
        if(info.annotations().get(STATEFUL_ANNOTATION) != null) {
            return SessionType.Stateful;
        } else if(info.annotations().get(STATELESS_ANNOTATION) != null) {
            return SessionType.Stateless;
        } else if(info.annotations().get(SINGLETON_ANNOTATION) != null) {
            return SessionType.Singleton;
        }
        return null;
    }
View Full Code Here


        final Class<SingletonComponentDescription> componentDescriptionType = SingletonComponentDescription.class;
        // Only process EJB deployments and components that are applicable
        if (!EjbDeploymentMarker.isEjbDeployment(deploymentUnit) || !(componentDescriptionType.isAssignableFrom(componentDescription.getClass()))) {
            return;
        }
        final Map<DotName, List<AnnotationInstance>> annotationsOnBean = beanClass.annotations();
        if (annotationsOnBean == null || annotationsOnBean.isEmpty()) {
            return;
        }

        final EEApplicationDescription applicationDescription = deploymentUnit.getAttachment(Attachments.EE_APPLICATION_DESCRIPTION);
View Full Code Here

        continue;
      }

      // logic here assumes an entity is not also a converter...
      AnnotationInstance converterAnnotation = JandexHelper.getSingleAnnotation(
          classInfo.annotations(),
          JPADotNames.CONVERTER
      );
      if ( converterAnnotation != null ) {
        metadataSources.converterDescriptors.add(
            new MetadataSources.ConverterDescriptor(
View Full Code Here

        if (isJSP(endpointClassName)) return false;
        final DotName endpointDotName = DotName.createSimple(endpointClassName);
        final ClassInfo endpointClassInfo = index.getClassByName(endpointDotName);

        if (endpointClassInfo != null) {
            if (endpointClassInfo.annotations().containsKey(WEB_SERVICE_ANNOTATION))
                return true;
            if (endpointClassInfo.annotations().containsKey(WEB_SERVICE_PROVIDER_ANNOTATION))
                return true;
        }
View Full Code Here

        final ClassInfo endpointClassInfo = index.getClassByName(endpointDotName);

        if (endpointClassInfo != null) {
            if (endpointClassInfo.annotations().containsKey(WEB_SERVICE_ANNOTATION))
                return true;
            if (endpointClassInfo.annotations().containsKey(WEB_SERVICE_PROVIDER_ANNOTATION))
                return true;
        }

        return false;
    }
View Full Code Here

        }
        final ClassInfo info = compositeIndex.getClassByName(DotName.createSimple(ejbClass));
        if (info == null) {
            return null;
        }
        if(info.annotations().get(STATEFUL_ANNOTATION) != null) {
            return SessionType.Stateful;
        } else if(info.annotations().get(STATELESS_ANNOTATION) != null) {
            return SessionType.Stateless;
        } else if(info.annotations().get(SINGLETON_ANNOTATION) != null) {
            return SessionType.Singleton;
View Full Code Here

        if (info == null) {
            return null;
        }
        if(info.annotations().get(STATEFUL_ANNOTATION) != null) {
            return SessionType.Stateful;
        } else if(info.annotations().get(STATELESS_ANNOTATION) != null) {
            return SessionType.Stateless;
        } else if(info.annotations().get(SINGLETON_ANNOTATION) != null) {
            return SessionType.Singleton;
        }
        return null;
View Full Code Here

        }
        if(info.annotations().get(STATEFUL_ANNOTATION) != null) {
            return SessionType.Stateful;
        } else if(info.annotations().get(STATELESS_ANNOTATION) != null) {
            return SessionType.Stateless;
        } else if(info.annotations().get(SINGLETON_ANNOTATION) != null) {
            return SessionType.Singleton;
        }
        return null;
    }
View Full Code Here

  public Map<DotName, List<AnnotationInstance>> getIndexedAnnotations(DotName name) {
    Map<DotName, List<AnnotationInstance>> map = indexedClassInfoAnnotationsMap.get( name );
    if ( map == null ) {
      ClassInfo ci = index.getClassByName( name );
      if ( ci == null || ci.annotations() == null ) {
        map = Collections.emptyMap();
      }
      else {
        map = new HashMap<DotName, List<AnnotationInstance>>( ci.annotations() );
        //here we ignore global annotations
View Full Code Here

      ClassInfo ci = index.getClassByName( name );
      if ( ci == null || ci.annotations() == null ) {
        map = Collections.emptyMap();
      }
      else {
        map = new HashMap<DotName, List<AnnotationInstance>>( ci.annotations() );
        //here we ignore global annotations
        for ( DotName globalAnnotationName : DefaultConfigurationHelper.GLOBAL_ANNOTATIONS ) {
          if ( map.containsKey( globalAnnotationName ) ) {
            map.put( globalAnnotationName, Collections.<AnnotationInstance>emptyList() );
          }
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.