Examples of asNestedArray()


Examples of org.jboss.jandex.AnnotationValue.asNestedArray()

    }

    @Override
    public boolean process(AnnotationInstance annotationInstance) {
      AnnotationValue value = annotationInstance.value();
      AnnotationInstance[] indexedAttributeOverridesValues = value.asNestedArray();
      for ( AnnotationInstance ai : indexedAttributeOverridesValues ) {
        child.process( ai );
      }
      return true;
    }
View Full Code Here

Examples of org.jboss.jandex.AnnotationValue.asNestedArray()

    private Properties getActivationConfigProperties(final AnnotationInstance messageBeanAnnotation) {
        final Properties props = new Properties();
        final AnnotationValue activationConfig = messageBeanAnnotation.value("activationConfig");
        if (activationConfig == null)
            return props;
        for (final AnnotationInstance propAnnotation : activationConfig.asNestedArray()) {
            props.put(propAnnotation.value("propertyName").asString(), propAnnotation.value("propertyValue").asString());
        }
        return props;
    }
View Full Code Here

Examples of org.jboss.jandex.AnnotationValue.asNestedArray()

        final List<AnnotationInstance> ejbsAnnotations = index.getAnnotations(EJBS_ANNOTATION_NAME);
        for (AnnotationInstance annotation : ejbsAnnotations) {
            final AnnotationTarget annotationTarget = annotation.target();
            if (annotationTarget instanceof ClassInfo) {
                final AnnotationValue annotationValue = annotation.value();
                final AnnotationInstance[] ejbAnnotations = annotationValue.asNestedArray();
                for (AnnotationInstance ejbAnnotation : ejbAnnotations) {
                    final EJBResourceWrapper annotationWrapper = new EJBResourceWrapper(ejbAnnotation);
                    processClass(deploymentUnit, annotationWrapper, (ClassInfo) annotationTarget, moduleDescription);
                }
            } else {
View Full Code Here

Examples of org.jboss.jandex.AnnotationValue.asNestedArray()

        } else if (isPersistenceUnits(annotation)) {
            // handle PersistenceUnits (array of PersistenceUnit)
            AnnotationValue containedPersistenceUnits = annotation.value("value");
            AnnotationInstance[] arrayPersistenceUnits;
            if (containedPersistenceUnits != null &&
                (arrayPersistenceUnits = containedPersistenceUnits.asNestedArray()) != null) {
                for (int source = 0; source < arrayPersistenceUnits.length; source++) {
                    String injectionTypeName = getClassLevelInjectionType(arrayPersistenceUnits[source]);
                    InjectionSource injectionSource = getBindingSource(deploymentUnit, arrayPersistenceUnits[source], injectionTypeName, classDescription);
                    if (injectionSource != null) {
                        final AnnotationValue nameValue = arrayPersistenceUnits[source].value("name");
View Full Code Here

Examples of org.jboss.jandex.AnnotationValue.asNestedArray()

        } else if (isPersistenceContexts(annotation)) {
            // handle PersistenceContexts (array of PersistenceContext)
            AnnotationValue containedPersistenceContexts = annotation.value("value");
            AnnotationInstance[] arrayPersistenceContexts;
            if (containedPersistenceContexts != null &&
                (arrayPersistenceContexts = containedPersistenceContexts.asNestedArray()) != null) {
                for (int source = 0; source < arrayPersistenceContexts.length; source++) {
                    String injectionTypeName = getClassLevelInjectionType(arrayPersistenceContexts[source]);
                    InjectionSource injectionSource = getBindingSource(deploymentUnit, arrayPersistenceContexts[source], injectionTypeName, classDescription);
                    if (injectionSource != null) {
                        final AnnotationValue nameValue = arrayPersistenceContexts[source].value("name");
View Full Code Here

Examples of org.jboss.jandex.AnnotationValue.asNestedArray()

            PersistenceContextType type = (pcType == null || PersistenceContextType.TRANSACTION.name().equals(pcType.asString()))
                ? PersistenceContextType.TRANSACTION : PersistenceContextType.EXTENDED;

            Map properties;
            AnnotationValue value = annotation.value("properties");
            AnnotationInstance[] props = value != null ? value.asNestedArray() : null;
            if (props != null) {
                properties = new HashMap();
                for (int source = 0; source < props.length; source++) {
                    properties.put(props[source].value("name"), props[source].value("value"));
                }
View Full Code Here

Examples of org.jboss.jandex.AnnotationValue.asNestedArray()

   *
   * @return the element array if not <code>null</code>, else an empty array
   */
  public static AnnotationInstance[] getValueAsArray(AnnotationInstance annotation, String element) {
    AnnotationValue val = annotation.value( element );
    return val == null ? EMPTY_ANNOTATIONS_ARRAY : val.asNestedArray();
  }

  /**
   * Retrieves a jandex annotation element value, converting it to the supplied enumerated type.  If the value is
   * <code>null</code>, the default value specified in the annotation class is retrieved instead.
View Full Code Here

Examples of org.jboss.jandex.AnnotationValue.asNestedArray()

  private void bindUniqueConstraints(AnnotationInstance tableAnnotation, TableSpecification table) {
    AnnotationValue value = tableAnnotation.value( "uniqueConstraints" );
    if ( value == null ) {
      return;
    }
    AnnotationInstance[] uniqueConstraints = value.asNestedArray();
    for ( AnnotationInstance unique : uniqueConstraints ) {
      String name = unique.value( "name" ).asString();
      UniqueKey uniqueKey = table.getOrCreateUniqueKey( name );
      String[] columnNames = unique.value( "columnNames" ).asStringArray();
      if ( columnNames.length == 0 ) {
View Full Code Here

Examples of org.jboss.jandex.AnnotationValue.asNestedArray()

      return type;
    }

    AnnotationValue parameterAnnotationValue = typeAnnotation.value( "parameters" );
    if ( parameterAnnotationValue != null ) {
      AnnotationInstance[] parameterAnnotations = parameterAnnotationValue.asNestedArray();
      for ( AnnotationInstance parameterAnnotationInstance : parameterAnnotations ) {
        typeParameters.put(
            parameterAnnotationInstance.value( "name" ).asString(),
            parameterAnnotationInstance.value( "value" ).asString()
        );
View Full Code Here

Examples of org.jboss.jandex.AnnotationValue.asNestedArray()

    }

    @Override
    public boolean process(AnnotationInstance annotationInstance) {
      AnnotationValue value = annotationInstance.value();
      AnnotationInstance[] indexedAttributeOverridesValues = value.asNestedArray();
      for ( AnnotationInstance ai : indexedAttributeOverridesValues ) {
        child.process( ai );
      }
      return true;
    }
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.