Annotation Type Attribute

    • Optional Element Summary

      Optional Elements 
      Modifier and Type Optional Element Description
      String name
      The name of the attribute.
      boolean optional
      Whether this attribute is optional or mandatory.
      String uri
      The namespace of the attribute.
    • Element Detail

      • uri

        String uri
        The namespace of the attribute. If no namespace is given, the namespace of the Element annotation of the enclosing class is used.
        Returns:
        The namespace of this attribute.
        Default:
        ""
      • name

        String name
        The name of the attribute. If no name is given, the name of the annotated field or method is used.
        Returns:
        the name of this attribute.
        Default:
        ""
      • optional

        boolean optional
        Whether this attribute is optional or mandatory. The default is for an attribute to be mandatory. If the namespace of this attribute is not the same as the namespace of the enclosing class, the attribute must be specified as optional.
        Returns:
        true if this attribute is optional, false if this attribute is mandatory.
        Default:
        false