Uploaded image for project: 'Solder'
  1. Solder
  2. SOLDER-17

NarrowingBeanBuilder should support reading from Annotated

    Details

    • Type: Feature Request
    • Status: Closed (View Workflow)
    • Priority: Major
    • Resolution: Rejected
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: None
    • Labels:
      None
    • Estimated Difficulty:
      Low

      Description

      Currently, NarrowingBeanBuilder supports reading only from AnnotatedType. However, if you are trying to create a specialized producer method based on information at an injection point, you need to be able to read from the more general Annotated type.

      In fact, the NarrowingBeanBuilder is currently not using any information from AnnotatedType that isn't provide by Annotated, so it's definition worth making more general.

        Gliffy Diagrams

          Activity

          Hide
          dan.j.allen Dan Allen added a comment -

          Shoot, I need this for the Seam Servlet release. For now I've just copied the class into the Seam Servlet impl and modified it.

          Show
          dan.j.allen Dan Allen added a comment - Shoot, I need this for the Seam Servlet release. For now I've just copied the class into the Seam Servlet impl and modified it.
          Hide
          pmuir Pete Muir added a comment -

          Send a pull request, I can merge it.

          Show
          pmuir Pete Muir added a comment - Send a pull request, I can merge it.
          Hide
          dan.j.allen Dan Allen added a comment -

          As I came to understand NarrowingBeanBuilder better, I found I didn't need this feature. The proper pattern is to obtain the type at the injection point, then use BeanManager to create an annotated type. You then use that return value as the AnnotatedType to read from. For now, I'm rejecting until I encounter a case where I really do need it.

          Show
          dan.j.allen Dan Allen added a comment - As I came to understand NarrowingBeanBuilder better, I found I didn't need this feature. The proper pattern is to obtain the type at the injection point, then use BeanManager to create an annotated type. You then use that return value as the AnnotatedType to read from. For now, I'm rejecting until I encounter a case where I really do need it.

            People

            • Assignee:
              dan.j.allen Dan Allen
              Reporter:
              dan.j.allen Dan Allen
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development