Uploaded image for project: 'WildFly Core'
  1. WildFly Core
  2. WFCORE-795

Attribute groups (and allowedValues) not inherited by further attributes.

XMLWordPrintable

      Take the following attribute defintion: -

          static final SimpleAttributeDefinition PATH = new SimpleAttributeDefinitionBuilder(ElytronDescriptionConstants.PATH, ModelType.STRING, true)
              .setAllowExpression(true)
              .setMinSize(1)
              .setAttributeGroup(ElytronDescriptionConstants.FILE)
              .setFlags(AttributeAccess.Flag.RESTART_RESOURCE_SERVICES)
              .build();
      

      If this is used as a basis for a new attribute: -

          static final SimpleAttributeDefinition PATH =
                  new SimpleAttributeDefinitionBuilder(ElytronDescriptionConstants.PATH, FileAttributeDefinitions.PATH)
                          .setAttributeGroup(ElytronDescriptionConstants.FILE)
                          .setAllowNull(false)
                          .build();
      

      The attribute group was not inherited and needed to be manually set again.

              kkhan1@redhat.com Kabir Khan
              darran.lofthouse@redhat.com Darran Lofthouse
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Created:
                Updated:
                Resolved: