Uploaded image for project: 'Sling'
  1. Sling
  2. SLING-8975

Sling API: Resource.getResourceType should be @Nullable

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Major
    • Resolution: Won't Fix
    • API 2.21.0
    • None
    • API
    • None

    Description

      currently, the getResourceType() method of the Resource interface is marked as @NotNull in the API.

      imho this is wrong:

      • it is not mandatory that every resource has a resource type
      • the JCR resource provider uses the JCR primary type as "fallback" value when no resource type is defined as property, but this is not necessary the case for other resource providers or synthetic resources

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              sseifert Stefan Seifert
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 40m
                  40m